/**
 * Breinco Archive Styles
 * Minimal functional CSS for archive pages
 */

 :root {
    --text-color: #393C41;
    --color-bleu: #00B2FF;
    --color-grey: #e5e5e5;
    --color-grey-50: #5C5E62;
    --color-grey-30: #B4B4B5;
}

/* ===========================
   Container & Layout
   =========================== */

.breinco-archive-container {
    display: flex;
    gap: 80px;
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px 24px;
}

/* ===========================
   Sidebar Navigation
   =========================== */

.breinco-archive-sidebar {
    flex: 0 0 280px;
    width: 280px;
}

.archive h2.breinco-category-menu-title {
    margin: 0;
    font-size: 1.125rem;
    font-weight: 300;
    a {
        text-decoration: none;
    }
}

.breinco-category-menu {
    position: sticky;
    top: 20px;
}

.breinco-category-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.breinco-category-item {
    margin-bottom: 0;
    border-bottom: 1px solid var(--color-grey);
}

.breinco-category-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 0;
}

.breinco-category-link {
    flex: 1;
    font-size: 16px;
    font-weight: 300;
    color: var(--text-color);
    text-decoration: none;
    transition: color 0.2s ease;
}

.breinco-category-link:hover {
    color: var(--color-bleu);
}

.breinco-category-link.active {
    color: var(--color-bleu);
}

.breinco-category-toggle {
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px 10px;
    font-size: 20px;
    line-height: 1;
    color: var(--color-grey-50);
    transition: color 0.2s ease, transform 0.2s ease;
}

.breinco-category-toggle:hover {
    color: var(--color-bleu);
}

.breinco-category-item.open .breinco-category-toggle {
    transform: rotate(0deg);
}

.toggle-icon {
    display: inline-block;
    font-weight: 200;
    font-family: 'Poppins', sans-serif;
}

/* Subcategory List */

.breinco-subcategory-list {
    list-style: none;
    padding: 0 0 10px 20px;
    margin: 0;
    overflow: hidden;
}

.breinco-subcategory-item {
    margin-bottom: 8px;
}

.breinco-subcategory-link {
    font-size: 14px;
    color: var(--color-grey-50);
    text-decoration: none;
    transition: color 0.2s ease;
    display: block;
    padding: 4px 0;
}

.breinco-subcategory-link:hover {
    color: var(--color-bleu);
}

.breinco-subcategory-link.active {
    color: var(--color-bleu);
    font-weight: 600;
}

/* ===========================
   Main Content Area
   =========================== */

.breinco-archive-main {
    flex: 1;
    min-width: 0;
}

.breinco-archive-header {
    margin-bottom: 40px;
}

.breinco-archive-title {
    font-size: 1.5rem;
    font-weight: 300;
    margin: 0 0 16px 0;
    color: var(--text-color);
}

.breinco-archive-description {
    font-size: 16px;
    line-height: 1.6;
    color: var(--color-grey-50);
}

/* ===========================
   Subcategory Grid
   =========================== */

.breinco-subcategory-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px 60px;
}

.breinco-subcategory-card {
    position: relative;
    overflow: hidden;
    padding-bottom: 10px;
    border-bottom: 1px solid;
}

.breinco-subcategory-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.breinco-subcategory-image {
    width: 100%;
    aspect-ratio: 387 / 181;
    overflow: hidden;
    background: #f5f5f5;
    margin-bottom: 10px;
}

.breinco-subcategory-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.breinco-subcategory-placeholder- {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.breinco-subcategory-placeholder- .breinco-subcategory-name {
    color: #fff;
    font-size: 18px;
    font-weight: 600;
    text-align: center;
    padding: 20px;
}

.archive h2.breinco-subcategory-title {
    font-size: 1rem;
    font-weight: 300;
    margin: 10px 0 20px 0;
    color: var(--text-color);
    text-align: left;
    line-height: 1.1;
    a {
        text-decoration: none;
    }
}

.breinco-subcategory-view-more {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.875rem;
    font-weight: 400;
    color: var(--text-color);
    text-decoration: none;
}

.breinco-subcategory-view-more span {
    text-decoration: none;
}

.breinco-subcategory-view-more:hover span {
    text-decoration: none;
}

.breinco-subcategory-icon {
    width: 20px;
    height: 20px;
    display: block;
}

/* ===========================
   Product Grid
   =========================== */

.breinco-product-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px 60px;
}

.breinco-product-card {
    background: #fff;
    overflow: hidden;
    border-bottom: 1px solid var(--text-color);
    padding-bottom: 10px;
}

.breinco-product-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.breinco-product-image {
    position: relative;
    width: 100%;
    padding-bottom: 100%; /* 1:1 aspect ratio */
    overflow: hidden;
    background: #f5f5f5;
}

/* Badge "New" para productos nuevos */
.breinco-product-image .new-product {
    position: absolute;
    top: 10px;
    left: 0;
    background-color: #ADE5FD;
    color: var(--color-bleu, #00B2FF);
    padding: 2px 12px;
    font-size: 0.875rem;
    z-index: 10;
    text-transform: uppercase;
}

.breinco-product-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.breinco-product-placeholder {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--color-grey);
    display: flex;
    align-items: center;
    justify-content: center;
}

.breinco-product-placeholder .no-image-text {
    color: #999;
    font-size: 14px;
}

.breinco-product-content {
    padding: 10px 0 0 0;
}

.breinco-product-category {
    font-size: 0.75rem;
    font-weight: 300;
    color: var(--color-grey-30);
    margin: 0 0 8px 0;
}

.archive h2.breinco-product-title {
    font-size: 16px;
    font-weight: 300;
    margin: 0 0 20px 0;
    color: var(--text-color);
    line-height: 1.1;
    a {
        text-decoration: none;
    }
}

.breinco-product-link-text {
    color: var(--color-bleu);
    font-size: 14px;
    font-weight: 500;
    text-decoration: underline;
}

.breinco-product-card:hover .breinco-product-link-text {
    text-decoration: none;
}

.breinco-product-view-more {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 400;
    color: var(--text-color);
    text-decoration: none;
}

.breinco-product-view-more span {
    text-decoration: none;
}

.breinco-product-view-more:hover span {
    text-decoration: none;
}

.breinco-product-icon {
    width: 20px;
    height: 20px;
    display: block;
}

/* ===========================
   Empty States
   =========================== */

.breinco-no-results {
    font-size: 16px;
    color: var(--color-grey-50);
    text-align: center;
    padding: 60px 20px;
}

/* ===========================
   Responsive Design
   =========================== */

@media (max-width: 1024px) {
    .breinco-archive-container {
        gap: 30px;
        padding: 24px;
    }
    
    .breinco-archive-sidebar {
        flex: 0 0 240px;
        width: 240px;
    }

    .breinco-product-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px 30px;
    }
}

@media (max-width: 768px) {
    .breinco-archive-container {
        flex-direction: column;
        gap: 30px;
    }
    
    .breinco-archive-sidebar {
        flex: 0 0 auto;
        width: 100%;
    }
    
    .breinco-category-menu {
        position: static;
    }
    
    .breinco-subcategory-grid,
    .breinco-product-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 20px;
    }
    
    .breinco-archive-title {
        font-size: 28px;
    }
}

@media (max-width: 480px) {
    .breinco-subcategory-grid,
    .breinco-product-grid {
        grid-template-columns: 1fr;
    }
    
    .breinco-archive-container {
        padding: 24px;
    }
}

