/* ================================
   Sabaya Boutique Page
================================ */

.sabaya-boutique-container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 24px 100px;
}

.sabaya-boutique-header {
    text-align: center;
    margin-bottom: 50px;
}

.sabaya-boutique-title {
    font-family: 'Amiri-Regular', serif !important;
    font-size: 36px;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #111111;
    margin-top: 40px;
}

.sabaya-boutique-layout {
    display: flex;
    gap: 48px;
    align-items: flex-start;
}

/* Sidebar */
.sabaya-boutique-sidebar {
    width: 240px;
    flex-shrink: 0;
    position: sticky;
    top: 100px;
}

.sabaya-sidebar-header {
    display: none;
}

.sabaya-filter-widget {
    margin-bottom: 40px;
}

.sabaya-filter-title {
    font-family: 'SweetSansPro-Regular', sans-serif;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 20px;
    border-bottom: 1px solid #eeeeee;
    padding-bottom: 10px;
    color: #111111;
    font-weight: 600;
}

/* Categories List */
.sabaya-category-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sabaya-category-list li {
    margin-bottom: 12px;
}

.sabaya-category-list a {
    text-decoration: none;
    color: #777777;
    font-family: 'SweetSansPro-Regular', sans-serif;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    transition: color 0.25s ease, padding-left 0.25s ease;
    display: inline-block;
}

.sabaya-category-list a:hover,
.sabaya-category-list li.active a {
    color: #111111;
    font-weight: 500;
    padding-left: 4px;
}

/* Sorting Selector */
.sabaya-sort-select {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    font-family: 'SweetSansPro-Regular', sans-serif;
    font-size: 13px;
    color: #111111;
    outline: none;
    cursor: pointer;
    border-radius: 4px;
    transition: border-color 0.2s ease;
    background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg width='10' height='6' viewBox='0 0 10 6' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%23111' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    background-size: 10px;
    padding-right: 32px;
    appearance: none;
}

.sabaya-sort-select:focus {
    border-color: #111111;
}

/* Main Content Area */
.sabaya-boutique-main {
    flex-grow: 1;
    min-width: 0;
}

/* Product Grid */
.sfp-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    padding: 0;
    margin: 0;
}

.sfp-card {
    display: block;
    text-decoration: none;
    color: inherit;
    overflow: hidden;
    position: relative;
    transition: transform 0.3s ease;
}

.sfp-card:hover {
    transform: translateY(-4px);
}

.sfp-card__image {
    width: 100%;
    overflow: hidden;
    aspect-ratio: 3 / 4.45;
    object-fit: cover;
    background: #f5f5f5;
    border-radius: 15px;
}

.sfp-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
    border-radius: 15px;
}

.sfp-card:hover .sfp-card__image img {
    transform: scale(1.04);
}

.sfp-card__info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-top: 14px;
}

.sfp-card__title {
    font-family: 'SweetSansPro-Regular', sans-serif;
    margin: 0;
    font-size: 13px;
    line-height: 1.3;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #111111;
}

.sfp-card__price {
    font-family: 'SweetSansPro-Regular', sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: #111111;
    white-space: nowrap;
}

/* Pagination */
.sabaya-pagination {
    margin-top: 60px;
    text-align: center;
}

.sabaya-pagination ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
    gap: 10px;
}

.sabaya-pagination li a,
.sabaya-pagination li span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border: 1px solid #eeeeee;
    text-decoration: none;
    color: #777777;
    font-family: 'SweetSansPro-Regular', sans-serif;
    font-size: 13px;
    transition: all 0.25s ease;
    border-radius: 4px;
}

.sabaya-pagination li a:hover {
    border-color: #111111;
    color: #111111;
}

.sabaya-pagination li span.current {
    background: #111111;
    color: #ffffff;
    border-color: #111111;
}

/* Empty State */
.sabaya-no-products {
    font-family: 'SweetSansPro-Regular', sans-serif;
    color: #777777;
    text-align: center;
    padding: 60px 0;
}

/* Hide Default WooCommerce Banner */
.woocommerce.archive .ast-archive-entry-banner,
.post-type-archive-product .ast-archive-entry-banner {
    display: none !important;
}

/* ================================
   Mobile Filter Responsive Drawer
================================ */

@media (max-width: 991px) {
    .sabaya-boutique-layout {
        flex-direction: column;
    }

    /* Transform Sidebar into Drawer */
    .sabaya-boutique-sidebar {
        position: fixed !important;
        top: 0;
        right: 0;
        width: 85%;
        max-width: 320px;
        height: 100%;
        background: #ffffff;
        z-index: 100000;
        padding: 32px 24px;
        box-shadow: -4px 0 25px rgba(0, 0, 0, 0.15);
        transform: translateX(100%);
        transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
        overflow-y: auto;
    }

    .sabaya-boutique-sidebar.is-open {
        transform: translateX(0);
    }

    /* Sidebar Drawer Header */
    .sabaya-sidebar-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 32px;
        border-bottom: 1px solid #eeeeee;
        padding-bottom: 16px;
    }

    .sabaya-sidebar-header h3 {
        margin: 0;
        font-family: 'SweetSansPro-Regular', sans-serif;
        font-size: 15px;
        text-transform: uppercase;
        letter-spacing: 0.08em;
        color: #111111;
    }

    .sabaya-sidebar-close {
        background: none;
        border: none;
        padding: 6px;
        cursor: pointer;
        color: #111111;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: transform 0.2s ease;
    }

    .sabaya-sidebar-close:hover {
        transform: rotate(90deg);
    }

    /* Mobile toggle bar */
    .sabaya-boutique-mobile-bar {
        display: flex;
        justify-content: center;
        margin-bottom: 30px;
        width: 100%;
    }

    .sabaya-filter-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 12px;
        background: #111111;
        color: #ffffff;
        border: none;
        padding: 14px 24px;
        border-radius: 8px;
        font-family: 'SweetSansPro-Regular', sans-serif;
        font-size: 12px;
        font-weight: 600;
        text-transform: uppercase;
        letter-spacing: 0.06em;
        cursor: pointer;
        width: 100%;
        max-width: 320px;
        transition: background 0.3s ease;
    }

    .sabaya-filter-toggle:hover {
        background: #333333;
    }

    /* Dark Overlay */
    .sabaya-sidebar-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.4);
        z-index: 99999;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.4s ease, visibility 0.4s ease;
    }

    .sabaya-sidebar-overlay.is-visible {
        opacity: 1;
        visibility: visible;
    }

    /* Grid adaptation for tablets */
    .sfp-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }
}

@media (max-width: 768px) {
    .sabaya-boutique-title {
        font-size: 28px;
        margin-top: 30px;
    }

    .sabaya-boutique-header {
        margin-bottom: 30px;
    }

    .sfp-grid {
        gap: 16px;
    }

    .sfp-card__title {
        font-size: 12px;
    }

    .sfp-card__price {
        font-size: 12px;
    }
}

@media (min-width: 992px) {
    .sabaya-boutique-mobile-bar,
    .sabaya-sidebar-overlay,
    .sabaya-boutique-sidebar {
        display: none !important;
    }
    
    .sabaya-boutique-layout {
        display: block;
    }
}

/* ================================
   Desktop Dropdowns / Horizontal Filters
   ================================ */

.sabaya-boutique-desktop-filters {
    display: none;
    position: sticky;
    top: 59px; /* Sit flush below the scrolled header */
    z-index: 999;
    background: #ffffff;
    border-top: 1px solid #eeeeee;
    border-bottom: 1px solid #eeeeee;
    padding: 14px 0;
    margin-bottom: 40px;
    gap: 30px;
}

@media (min-width: 992px) {
    .sabaya-boutique-desktop-filters {
        display: flex;
        align-items: center;
    }
}

.sabaya-dropdown {
    position: relative;
}

.sabaya-dropdown-trigger {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    font-family: 'SweetSansPro-Regular', sans-serif;
    font-size: 13px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #111111;
    transition: color 0.25s ease;
}

.sabaya-dropdown-trigger:hover,
.sabaya-dropdown.is-open .sabaya-dropdown-trigger {
    color: #777777;
}

.sabaya-dropdown-trigger svg {
    transition: transform 0.3s ease;
}

.sabaya-dropdown.is-open .sabaya-dropdown-trigger svg {
    transform: rotate(180deg);
}

.sabaya-dropdown-menu {
    position: absolute;
    top: calc(100% + 14px);
    left: 0;
    min-width: 260px;
    background: #ffffff;
    border: 1px solid #eeeeee;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
    border-radius: 4px;
    padding: 20px;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s ease;
}

.sabaya-dropdown.is-open .sabaya-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.sabaya-dropdown-menu-scroll {
    max-height: 240px;
    overflow-y: auto;
    margin-bottom: 16px;
    padding-right: 8px;
}

/* Scrollbar styles */
.sabaya-dropdown-menu-scroll::-webkit-scrollbar {
    width: 4px;
}
.sabaya-dropdown-menu-scroll::-webkit-scrollbar-track {
    background: #f5f5f5;
}
.sabaya-dropdown-menu-scroll::-webkit-scrollbar-thumb {
    background: #cccccc;
    border-radius: 2px;
}
.sabaya-dropdown-menu-scroll::-webkit-scrollbar-thumb:hover {
    background: #999999;
}

/* Custom Checkboxes */
.sabaya-checkbox-label {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    cursor: pointer;
    font-family: 'SweetSansPro-Regular', sans-serif;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #555555;
    user-select: none;
    transition: color 0.2s ease;
}

.sabaya-checkbox-label:last-child {
    margin-bottom: 0;
}

.sabaya-checkbox-label:hover {
    color: #111111;
}

.sabaya-checkbox-label input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.sabaya-checkbox-custom {
    height: 18px;
    width: 18px;
    background-color: #ffffff;
    border: 1px solid #cccccc;
    border-radius: 3px;
    position: relative;
    transition: background-color 0.2s ease, border-color 0.2s ease;
    flex-shrink: 0;
}

.sabaya-checkbox-label:hover input ~ .sabaya-checkbox-custom {
    border-color: #111111;
}

.sabaya-checkbox-label input:checked ~ .sabaya-checkbox-custom {
    background-color: #111111;
    border-color: #111111;
}

.sabaya-checkbox-custom::after {
    content: "";
    position: absolute;
    display: none;
    left: 6px;
    top: 2px;
    width: 4px;
    height: 9px;
    border: solid #ffffff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.sabaya-checkbox-label input:checked ~ .sabaya-checkbox-custom::after {
    display: block;
}

.sabaya-dropdown-actions {
    border-top: 1px solid #eeeeee;
    padding-top: 14px;
}

.sabaya-btn-apply {
    width: 100%;
    background: #111111;
    color: #ffffff;
    border: none;
    padding: 10px 16px;
    font-family: 'SweetSansPro-Regular', sans-serif;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.25s ease;
}

.sabaya-btn-apply:hover {
    background: #333333;
}

/* Sort Links */
.sabaya-sort-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sabaya-sort-links li {
    margin-bottom: 12px;
}

.sabaya-sort-links li:last-child {
    margin-bottom: 0;
}

.sabaya-sort-links a {
    text-decoration: none;
    font-family: 'SweetSansPro-Regular', sans-serif;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #555555;
    transition: color 0.2s ease;
    display: block;
}

.sabaya-sort-links a:hover,
.sabaya-sort-links a.active {
    color: #111111;
    font-weight: 500;
}


/* Hide Cart Page Title (Astra Theme context) */
.woocommerce-cart .entry-title,
.woocommerce-cart .ast-archive-entry-banner,
.woocommerce-cart .ast-single-post-order,
.woocommerce-cart .entry-header {
    display: none !important;
}
