/* =====================================================
   Individual Store - Ultra Minimalista
   ===================================================== */

:root {
    --primary: #007bff;
    --primary-dark: #0056b3;
    --dark: #212529;
    --muted: #6c757d;
    --light: #f8f9fa;
    --white: #ffffff;
    --border: #eee;
    --radius: 8px;
}

/* === Layout === */
body {
    background: var(--light);
    font-family: 'Poppins', sans-serif;
}

/* === Sidebar === */
.filter-sidebar {
    background: var(--white);
    padding: 24px;
    border-right: 1px solid var(--border);
    min-height: calc(100vh - 120px);
}

.filter-sidebar h5 {
    font-size: 13px;
    font-weight: 600;
    color: var(--dark);
    margin-bottom: 24px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* === Filtros === */
.filter-card {
    background: transparent;
    border: none;
    padding: 16px 0;
    border-bottom: 1px solid var(--border);
}

.filter-card:last-child {
    border-bottom: none;
}

.filter-header {
    padding: 0;
    border: none;
    background: transparent;
}

.filter-title {
    font-size: 11px;
    font-weight: 600;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 0 0 12px 0;
}

.filter-content {
    padding: 0;
}

.filter-content a {
    display: block;
    color: var(--dark);
    text-decoration: none;
    padding: 6px 0;
    font-size: 13px;
}

.filter-content a:hover {
    color: var(--primary);
}

.filter-content a.fw-bold {
    color: var(--primary) !important;
}

/* === Colores === */
.color-filter {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: inline-block;
    margin: 3px;
    border: 2px solid var(--border);
    cursor: pointer;
    transition: all 0.2s;
}

.color-filter:hover,
.color-filter.active {
    border-color: var(--primary);
    transform: scale(1.1);
}

/* === Búsqueda === */
.search-bar .input-group {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}

.search-bar .form-control {
    border: none;
    padding: 10px 14px;
    font-size: 13px;
}

.search-bar .form-control:focus {
    box-shadow: none;
}

.search-bar .btn {
    border: none;
    background: transparent;
    color: var(--muted);
}

/* === Precio === */
.filter-card .form-control {
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 8px 12px;
    font-size: 13px;
}

.filter-card .form-control:focus {
    border-color: var(--primary);
    box-shadow: none;
}

.filter-card .form-label {
    font-size: 12px;
    color: var(--muted);
}

.filter-card .btn-primary {
    background: var(--dark);
    border: none;
    border-radius: 6px;
    font-size: 13px;
    padding: 8px;
}

.filter-card .btn-primary:hover {
    background: var(--primary);
}

/* === Header Resultados === */
.results-header {
    background: var(--white);
    padding: 16px 20px;
    border-radius: var(--radius);
    margin-bottom: 20px;
    border: 1px solid var(--border);
}

.results-header h5 {
    font-size: 14px;
    font-weight: 500;
    margin: 0;
}

.results-header small {
    color: var(--muted);
}

.results-header .form-select {
    border: 1px solid var(--border);
    border-radius: 6px;
    font-size: 13px;
    padding: 8px 30px 8px 12px;
}

/* === Breadcrumb === */
.breadcrumb {
    background: transparent;
    padding: 0;
    margin-bottom: 16px;
    font-size: 13px;
}

.breadcrumb-item a {
    color: var(--muted);
    text-decoration: none;
}

.breadcrumb-item.active {
    color: var(--dark);
}

.breadcrumb-item + .breadcrumb-item::before {
    content: "›";
    color: #ccc;
}

/* =====================================================
   GRID DE PRODUCTOS
   ===================================================== */

.products-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

@media (max-width: 1200px) {
    .products-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
    .products-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
}

/* === Tarjeta de Producto === */
.product-card {
    background: var(--white);
    border-radius: var(--radius);
    overflow: hidden;
    border: 1px solid var(--border);
    transition: all 0.2s ease;
    cursor: pointer;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    box-shadow: 0 8px 24px rgba(0,0,0,0.08);
    transform: translateY(-2px);
}

/* === Imagen 1:1 === */
.card-img-container {
    position: relative;
    width: 100%;
    padding-top: 100%;
    background: var(--light);
    overflow: hidden;
}

.card-img-top {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.product-card:hover .card-img-top {
    transform: scale(1.03);
}

/* === Info Producto === */
.product-card .card-body {
    padding: 14px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.product-card .card-title {
    font-size: 13px;
    font-weight: 500;
    color: var(--dark);
    margin-bottom: 6px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 36px;
}

/* === Precio === */
.price-container {
    margin-bottom: 8px;
}

.price-main {
    font-size: 16px;
    font-weight: 600;
    color: var(--dark);
}

.price-from {
    font-size: 11px;
    color: var(--muted);
}

/* === Tallas === */
.sizes-preview {
    font-size: 11px;
    color: var(--muted);
    margin-bottom: 8px;
    min-height: 16px;
}

/* === Colores === */
.colors-container {
    margin-bottom: 12px;
    min-height: 36px;
}

.colors-label {
    font-size: 10px;
    color: var(--muted);
    text-transform: uppercase;
    margin-bottom: 4px;
}

.color-thumb {
    display: inline-block;
    cursor: pointer;
}

.color-thumb img {
    width: 22px;
    height: 22px;
    object-fit: cover;
    border: 1px solid var(--border);
    border-radius: 3px;
    transition: all 0.2s;
}

.color-thumb:hover img {
    border-color: var(--primary);
}

/* === Botón === */
.btn-add-cart {
    background: var(--dark);
    color: white;
    border: none;
    padding: 10px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
    margin-top: auto;
    width: 100%;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.btn-add-cart:hover {
    background: var(--primary);
}

.btn-add-cart:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* === Empty State === */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    background: var(--white);
    border-radius: var(--radius);
}

.empty-state i {
    font-size: 40px;
    color: #ddd;
    margin-bottom: 16px;
}

.empty-state h5 {
    font-weight: 500;
    margin-bottom: 8px;
}

.empty-state p {
    color: var(--muted);
    font-size: 14px;
}

/* =====================================================
   MODAL
   ===================================================== */

.modal-content {
    border: none;
    border-radius: 12px;
}

.modal-header {
    border-bottom: 1px solid var(--border);
    padding: 16px 20px;
}

.modal-title {
    font-size: 15px;
    font-weight: 500;
}

.modal-body {
    padding: 20px;
}

#modalProductImage {
    border-radius: var(--radius);
    max-height: 320px;
    width: 100%;
    object-fit: cover;
}

#modalProductPrice {
    font-size: 22px;
    font-weight: 600;
    color: var(--dark) !important;
    margin-bottom: 4px;
}

#modalProductColor {
    font-size: 13px;
}

/* === Tallas Modal === */
.size-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.size-option {
    min-width: 48px;
    padding: 10px 12px;
    text-align: center;
    border: 1px solid var(--border);
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    background: var(--white);
    transition: all 0.2s;
}

.size-option:hover {
    border-color: var(--dark);
}

.size-option.selected {
    background: var(--dark);
    color: white;
    border-color: var(--dark);
}

.modal-footer {
    border-top: 1px solid var(--border);
    padding: 14px 20px;
}

.modal-footer .btn-secondary {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--dark);
    border-radius: 6px;
    font-size: 13px;
}

.modal-footer .btn-primary {
    background: var(--dark);
    border: none;
    border-radius: 6px;
    font-size: 13px;
}

.modal-footer .btn-primary:hover {
    background: var(--primary);
}

.modal-footer .btn-primary:disabled {
    background: #ccc;
}

/* === Responsive === */
@media (max-width: 991px) {
    .filter-sidebar {
        min-height: auto;
        border-right: none;
        border-bottom: 1px solid var(--border);
        margin-bottom: 20px;
    }
}

@media (max-width: 576px) {
    .product-card .card-body { padding: 10px; }
    .product-card .card-title { font-size: 12px; min-height: 34px; }
    .price-main { font-size: 14px; }
    .btn-add-cart { padding: 8px; font-size: 11px; }
}

/* === Alerts === */
.alert {
    border: none;
    border-radius: var(--radius);
    font-size: 13px;
}