/* ==========================================================================
   STOREFRONT STYLES — storefront.css
   Customer-facing book store pages
   ========================================================================== */

/* ==========================================================================
   1. STORE HEADER
   ========================================================================== */
.store-header {
    background: var(--color-white);
    padding: var(--space-3) var(--space-4);
    position: sticky;
    top: 0;
    z-index: var(--z-sticky);
    box-shadow: var(--shadow-xs);
    display: flex;
    align-items: center;
    gap: var(--space-3);
}

.store-header-logo {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    text-decoration: none;
    flex-shrink: 0;
}
.store-header-logo-icon {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-md);
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-light));
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-gold);
}
.store-header-logo-icon svg {
    width: 20px;
    height: 20px;
}
.store-header-logo-text {
    font-size: var(--text-lg);
    font-weight: var(--font-bold);
    color: var(--color-primary);
    letter-spacing: var(--tracking-tight);
}
.store-header-logo-text span {
    color: var(--color-gold);
}

.store-header-search {
    flex: 1;
    max-width: 400px;
    position: relative;
}
.store-header-search .form-control {
    height: 40px;
    border-radius: var(--radius-full);
    padding-left: 40px;
    font-size: var(--text-sm);
    background: var(--gray-50);
    border-color: transparent;
}
.store-header-search .form-control:focus {
    background: var(--color-white);
    border-color: var(--color-gold);
}
.store-header-search .search-icon {
    position: absolute;
    left: var(--space-3);
    top: 50%;
    transform: translateY(-50%);
    color: var(--gray-400);
    pointer-events: none;
}
.store-header-search .search-icon svg {
    width: 18px;
    height: 18px;
}

.store-header-actions {
    display: flex;
    align-items: center;
    gap: var(--space-1);
}

@media (max-width: 576px) {
    .store-header-search {
        display: none;
    }
    .store-header.search-active .store-header-logo,
    .store-header.search-active .store-header-actions {
        display: none;
    }
    .store-header.search-active .store-header-search {
        display: block;
        max-width: none;
    }
}

/* ==========================================================================
   2. HERO SECTION
   ========================================================================== */
.hero-section {
    padding: var(--space-5) var(--space-4);
    margin-bottom: var(--space-2);
}

.hero-banner {
    border-radius: var(--radius-2xl);
    overflow: hidden;
    position: relative;
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-light));
    min-height: 200px;
}
.hero-banner-bg {
    position: absolute;
    inset: 0;
    opacity: 0.15;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23C5993A' fill-opacity='0.3'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}
.hero-banner-content {
    position: relative;
    z-index: 1;
    padding: var(--space-8) var(--space-6);
    color: var(--color-white);
}
.hero-banner-label {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-1) var(--space-3);
    background: rgba(197, 153, 58, 0.2);
    border: 1px solid rgba(197, 153, 58, 0.3);
    border-radius: var(--radius-full);
    font-size: var(--text-xs);
    font-weight: var(--font-semibold);
    color: var(--color-gold-light);
    margin-bottom: var(--space-4);
    letter-spacing: var(--tracking-wide);
}
.hero-banner-title {
    font-size: var(--text-2xl);
    font-weight: var(--font-bold);
    color: var(--color-white);
    margin-bottom: var(--space-2);
    max-width: 300px;
    line-height: var(--leading-tight);
}
.hero-banner-desc {
    font-size: var(--text-sm);
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: var(--space-5);
    max-width: 280px;
}
.hero-banner-cta {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-3) var(--space-5);
    background: var(--color-gold);
    color: var(--color-primary);
    font-weight: var(--font-semibold);
    border-radius: var(--radius-full);
    font-size: var(--text-sm);
    text-decoration: none;
    transition: all var(--transition-normal);
    border: none;
    cursor: pointer;
}
.hero-banner-cta:hover {
    background: var(--color-gold-light);
    box-shadow: var(--shadow-gold);
    color: var(--color-primary);
}

/* Hero carousel / swiper */
.hero-swiper {
    position: relative;
}
.hero-swiper-dots {
    display: flex;
    justify-content: center;
    gap: var(--space-2);
    margin-top: var(--space-4);
}
.hero-swiper-dot {
    width: 8px;
    height: 8px;
    border-radius: var(--radius-full);
    background: var(--gray-300);
    border: none;
    cursor: pointer;
    transition: all var(--transition-fast);
    padding: 0;
}
.hero-swiper-dot.active {
    width: 24px;
    background: var(--color-gold);
}

@media (min-width: 768px) {
    .hero-banner-title {
        font-size: var(--text-3xl);
        max-width: 400px;
    }
    .hero-banner-content {
        padding: var(--space-12) var(--space-8);
    }
}

/* ==========================================================================
   3. CATEGORY CHIPS
   ========================================================================== */
.category-chips {
    display: flex;
    gap: var(--space-2);
    padding: 0 var(--space-4) var(--space-4);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    -ms-overflow-style: none;
}
.category-chips::-webkit-scrollbar {
    display: none;
}

.category-chip {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-2) var(--space-4);
    background: var(--color-white);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-full);
    font-size: var(--text-sm);
    font-weight: var(--font-medium);
    color: var(--gray-700);
    white-space: nowrap;
    cursor: pointer;
    transition: all var(--transition-fast);
    text-decoration: none;
    flex-shrink: 0;
    min-height: 40px;
    touch-action: manipulation;
}
.category-chip:hover {
    border-color: var(--gray-300);
    color: var(--color-primary);
}
.category-chip.active {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: var(--color-white);
}
.category-chip svg {
    width: 16px;
    height: 16px;
}
.category-chip-count {
    font-size: var(--text-xs);
    color: var(--gray-400);
}
.category-chip.active .category-chip-count {
    color: rgba(255, 255, 255, 0.7);
}

/* ==========================================================================
   4. SECTION HEADER
   ========================================================================== */
.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 var(--space-4);
    margin-bottom: var(--space-4);
}
.section-title {
    font-size: var(--text-xl);
    font-weight: var(--font-bold);
    color: var(--color-primary);
}
.section-link {
    font-size: var(--text-sm);
    font-weight: var(--font-semibold);
    color: var(--color-gold-dark);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: var(--space-1);
    transition: color var(--transition-fast);
}
.section-link:hover {
    color: var(--color-gold);
}
.section-link svg {
    width: 16px;
    height: 16px;
}

/* ==========================================================================
   5. BOOK GRID
   ========================================================================== */
.book-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-4);
    padding: 0 var(--space-4);
    margin-bottom: var(--space-8);
}

@media (min-width: 576px) {
    .book-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 768px) {
    .book-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: var(--space-5);
    }
}

@media (min-width: 992px) {
    .book-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (min-width: 1200px) {
    .book-grid {
        grid-template-columns: repeat(5, 1fr);
    }
}

/* Horizontal scroll row */
.book-scroll-row {
    display: flex;
    gap: var(--space-4);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding: 0 var(--space-4) var(--space-4);
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    -ms-overflow-style: none;
}
.book-scroll-row::-webkit-scrollbar {
    display: none;
}
.book-scroll-row .card-book {
    min-width: 150px;
    max-width: 170px;
    flex-shrink: 0;
    scroll-snap-align: start;
}

@media (min-width: 768px) {
    .book-scroll-row .card-book {
        min-width: 180px;
        max-width: 200px;
    }
}

/* ==========================================================================
   6. BOOK DETAIL PAGE
   ========================================================================== */
.book-detail {
    padding-bottom: calc(var(--bottom-nav-height) + 80px + env(safe-area-inset-bottom));
}

.book-detail-header {
    position: relative;
    padding: var(--space-6) var(--space-4);
    background: linear-gradient(180deg, var(--color-primary) 0%, var(--color-primary-light) 60%, var(--color-bg) 100%);
}

.book-detail-back {
    position: absolute;
    top: var(--space-4);
    left: var(--space-4);
    width: 40px;
    height: 40px;
    border-radius: var(--radius-full);
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-white);
    text-decoration: none;
    transition: all var(--transition-fast);
    border: none;
    cursor: pointer;
}
.book-detail-back:hover {
    background: rgba(255, 255, 255, 0.25);
}

.book-detail-cover {
    width: 180px;
    aspect-ratio: 2 / 3;
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-2xl);
    margin: 0 auto var(--space-5);
}
.book-detail-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.book-detail-info {
    text-align: center;
    padding: 0 var(--space-4);
}
.book-detail-title {
    font-size: var(--text-2xl);
    font-weight: var(--font-bold);
    color: var(--color-white);
    margin-bottom: var(--space-2);
}
.book-detail-author {
    font-size: var(--text-base);
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: var(--space-4);
}

.book-detail-meta {
    display: flex;
    justify-content: center;
    gap: var(--space-6);
    margin-bottom: var(--space-5);
}
.book-detail-meta-item {
    text-align: center;
}
.book-detail-meta-value {
    font-size: var(--text-lg);
    font-weight: var(--font-bold);
    color: var(--color-white);
}
.book-detail-meta-label {
    font-size: var(--text-xs);
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wider);
}

.book-detail-price-section {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-4);
    padding: var(--space-5);
}
.book-detail-price {
    font-size: var(--text-3xl);
    font-weight: var(--font-bold);
    color: var(--color-gold);
}
.book-detail-price-old {
    font-size: var(--text-lg);
    color: var(--gray-400);
    text-decoration: line-through;
}

.book-detail-body {
    padding: 0 var(--space-4);
}

.book-detail-section {
    margin-bottom: var(--space-6);
}
.book-detail-section-title {
    font-size: var(--text-lg);
    font-weight: var(--font-bold);
    color: var(--color-primary);
    margin-bottom: var(--space-3);
}
.book-detail-description {
    font-size: var(--text-base);
    color: var(--gray-600);
    line-height: var(--leading-relaxed);
}

/* Sticky buy bar */
.book-detail-buy-bar {
    position: fixed;
    bottom: var(--bottom-nav-height);
    left: 0;
    right: 0;
    background: var(--color-white);
    padding: var(--space-3) var(--space-4);
    box-shadow: 0 -4px 20px rgba(10, 22, 40, 0.1);
    display: flex;
    align-items: center;
    gap: var(--space-3);
    z-index: var(--z-sticky);
    padding-bottom: calc(var(--space-3) + env(safe-area-inset-bottom));
}
.book-detail-buy-bar .price {
    font-size: var(--text-xl);
}
.book-detail-buy-bar .btn {
    flex: 1;
}

@media (min-width: 768px) {
    .book-detail-header {
        display: flex;
        align-items: flex-start;
        gap: var(--space-8);
        padding: var(--space-10) var(--space-8);
    }
    .book-detail-cover {
        width: 240px;
        margin: 0;
    }
    .book-detail-info {
        text-align: left;
        padding: 0;
        flex: 1;
    }
    .book-detail-meta {
        justify-content: flex-start;
    }
}

/* ==========================================================================
   7. CART PAGE
   ========================================================================== */
.cart-page {
    padding: var(--space-4);
    padding-bottom: calc(var(--bottom-nav-height) + 100px + env(safe-area-inset-bottom));
}

.cart-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--space-5);
}
.cart-count {
    font-size: var(--text-sm);
    color: var(--gray-500);
}

.cart-list {
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
    margin-bottom: var(--space-6);
}

.cart-item {
    display: flex;
    gap: var(--space-4);
    padding: var(--space-4);
    background: var(--color-white);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-sm);
    position: relative;
    animation: fadeInUp 0.3s ease;
}
.cart-item-cover {
    width: 70px;
    aspect-ratio: 2 / 3;
    border-radius: var(--radius-md);
    overflow: hidden;
    flex-shrink: 0;
}
.cart-item-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.cart-item-info {
    flex: 1;
    min-width: 0;
}
.cart-item-title {
    font-size: var(--text-base);
    font-weight: var(--font-semibold);
    color: var(--color-primary);
    margin-bottom: var(--space-1);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.cart-item-author {
    font-size: var(--text-sm);
    color: var(--gray-500);
    margin-bottom: var(--space-2);
}
.cart-item-price {
    font-size: var(--text-lg);
    font-weight: var(--font-bold);
    color: var(--color-gold-dark);
}
.cart-item-remove {
    position: absolute;
    top: var(--space-3);
    right: var(--space-3);
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-full);
    color: var(--gray-400);
    cursor: pointer;
    transition: all var(--transition-fast);
    background: none;
    border: none;
}
.cart-item-remove:hover {
    background: var(--color-danger-light);
    color: var(--color-danger);
}
.cart-item-remove svg {
    width: 18px;
    height: 18px;
}

/* Quantity controls */
.cart-quantity {
    display: inline-flex;
    align-items: center;
    gap: 0;
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-md);
    overflow: hidden;
    margin-top: var(--space-2);
}
.cart-quantity-btn {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gray-50);
    border: none;
    cursor: pointer;
    color: var(--gray-600);
    transition: all var(--transition-fast);
    touch-action: manipulation;
}
.cart-quantity-btn:hover {
    background: var(--gray-100);
    color: var(--color-primary);
}
.cart-quantity-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}
.cart-quantity-value {
    width: 44px;
    text-align: center;
    font-weight: var(--font-semibold);
    font-size: var(--text-base);
    border-left: 1px solid var(--gray-200);
    border-right: 1px solid var(--gray-200);
    height: 36px;
    line-height: 36px;
}

/* Cart summary */
.cart-summary {
    position: fixed;
    bottom: var(--bottom-nav-height);
    left: 0;
    right: 0;
    background: var(--color-white);
    padding: var(--space-4);
    box-shadow: 0 -4px 20px rgba(10, 22, 40, 0.1);
    z-index: var(--z-sticky);
    padding-bottom: calc(var(--space-4) + env(safe-area-inset-bottom));
}
.cart-summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: var(--space-2);
    font-size: var(--text-sm);
    color: var(--gray-600);
}
.cart-summary-total {
    display: flex;
    justify-content: space-between;
    font-size: var(--text-lg);
    font-weight: var(--font-bold);
    color: var(--color-primary);
    margin-bottom: var(--space-4);
    padding-top: var(--space-3);
    border-top: 1px solid var(--gray-200);
}

/* ==========================================================================
   8. CHECKOUT PAGE
   ========================================================================== */
.checkout-page {
    padding: var(--space-4);
    max-width: 600px;
    margin: 0 auto;
    padding-bottom: calc(var(--bottom-nav-height) + var(--space-8) + env(safe-area-inset-bottom));
}

.checkout-section {
    background: var(--color-white);
    border-radius: var(--radius-xl);
    padding: var(--space-5);
    margin-bottom: var(--space-4);
    box-shadow: var(--shadow-sm);
}
.checkout-section-title {
    font-size: var(--text-md);
    font-weight: var(--font-bold);
    color: var(--color-primary);
    margin-bottom: var(--space-4);
    display: flex;
    align-items: center;
    gap: var(--space-2);
}
.checkout-section-title .step-number {
    width: 28px;
    height: 28px;
    border-radius: var(--radius-full);
    background: var(--color-primary);
    color: var(--color-white);
    font-size: var(--text-sm);
    font-weight: var(--font-bold);
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Payment methods */
.payment-methods {
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
}
.payment-method {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    padding: var(--space-4);
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all var(--transition-fast);
}
.payment-method:hover {
    border-color: var(--gray-300);
}
.payment-method.active {
    border-color: var(--color-gold);
    background: rgba(197, 153, 58, 0.05);
}
.payment-method-icon {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    background: var(--gray-100);
    display: flex;
    align-items: center;
    justify-content: center;
}
.payment-method-name {
    font-weight: var(--font-semibold);
    color: var(--color-primary);
    font-size: var(--text-base);
}
.payment-method-desc {
    font-size: var(--text-xs);
    color: var(--gray-500);
}

/* ==========================================================================
   9. LIBRARY PAGE
   ========================================================================== */
.library-tabs {
    display: flex;
    gap: var(--space-1);
    padding: var(--space-3) var(--space-4);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
.library-tabs::-webkit-scrollbar {
    display: none;
}

.library-tab {
    padding: var(--space-2) var(--space-4);
    font-size: var(--text-sm);
    font-weight: var(--font-medium);
    color: var(--gray-500);
    border-radius: var(--radius-full);
    background: none;
    border: 1px solid transparent;
    cursor: pointer;
    transition: all var(--transition-fast);
    white-space: nowrap;
    flex-shrink: 0;
}
.library-tab:hover {
    color: var(--color-primary);
    background: var(--gray-100);
}
.library-tab.active {
    background: var(--color-primary);
    color: var(--color-white);
    font-weight: var(--font-semibold);
}

.library-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-4);
    padding: var(--space-4);
}

@media (min-width: 576px) {
    .library-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 768px) {
    .library-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.library-book {
    position: relative;
    cursor: pointer;
}
.library-book-cover {
    width: 100%;
    aspect-ratio: 2 / 3;
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    margin-bottom: var(--space-3);
    position: relative;
}
.library-book-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Reading/listening progress */
.library-book-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: rgba(0, 0, 0, 0.3);
}
.library-book-progress-bar {
    height: 100%;
    background: var(--color-gold);
    border-radius: 0 var(--radius-full) var(--radius-full) 0;
    transition: width var(--transition-slow);
}

.library-book-progress-badge {
    position: absolute;
    bottom: var(--space-2);
    right: var(--space-2);
    padding: 2px var(--space-2);
    background: rgba(10, 22, 40, 0.7);
    backdrop-filter: blur(4px);
    border-radius: var(--radius-sm);
    font-size: 10px;
    font-weight: var(--font-semibold);
    color: var(--color-white);
}

.library-book-title {
    font-size: var(--text-sm);
    font-weight: var(--font-semibold);
    color: var(--color-primary);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: var(--leading-snug);
}
.library-book-type {
    margin-top: var(--space-1);
}

/* ==========================================================================
   10. ORDER HISTORY
   ========================================================================== */
.order-card {
    background: var(--color-white);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    margin-bottom: var(--space-4);
}
.order-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-4);
    background: var(--gray-50);
    border-bottom: 1px solid var(--gray-100);
}
.order-card-id {
    font-size: var(--text-sm);
    font-weight: var(--font-semibold);
    color: var(--color-primary);
}
.order-card-date {
    font-size: var(--text-xs);
    color: var(--gray-500);
}
.order-card-body {
    padding: var(--space-4);
}
.order-card-items {
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
}
.order-card-item {
    display: flex;
    align-items: center;
    gap: var(--space-3);
}
.order-card-item-cover {
    width: 48px;
    aspect-ratio: 2 / 3;
    border-radius: var(--radius-sm);
    overflow: hidden;
    flex-shrink: 0;
}
.order-card-item-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.order-card-item-title {
    font-size: var(--text-sm);
    font-weight: var(--font-medium);
    color: var(--color-primary);
    flex: 1;
}
.order-card-item-price {
    font-size: var(--text-sm);
    font-weight: var(--font-semibold);
    color: var(--color-gold-dark);
}

.order-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-4);
    border-top: 1px solid var(--gray-100);
}
.order-card-total-label {
    font-size: var(--text-sm);
    color: var(--gray-500);
}
.order-card-total-value {
    font-size: var(--text-lg);
    font-weight: var(--font-bold);
    color: var(--color-primary);
}

/* ==========================================================================
   11. FILTER SIDEBAR (Mobile: bottom sheet)
   ========================================================================== */
.filter-section {
    margin-bottom: var(--space-6);
}
.filter-section-title {
    font-size: var(--text-base);
    font-weight: var(--font-bold);
    color: var(--color-primary);
    margin-bottom: var(--space-3);
}

.filter-options {
    display: flex;
    flex-direction: column;
    gap: var(--space-1);
}

.filter-option {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    padding: var(--space-2) 0;
    cursor: pointer;
    font-size: var(--text-sm);
    color: var(--gray-700);
}
.filter-option-count {
    margin-left: auto;
    font-size: var(--text-xs);
    color: var(--gray-400);
}

.filter-price-range {
    padding: var(--space-2) 0;
}
.filter-price-inputs {
    display: flex;
    gap: var(--space-3);
    align-items: center;
}
.filter-price-inputs .form-control {
    height: 40px;
    font-size: var(--text-sm);
}
.filter-price-separator {
    color: var(--gray-400);
    font-weight: var(--font-medium);
}

/* Active filters bar */
.active-filters {
    display: flex;
    gap: var(--space-2);
    flex-wrap: wrap;
    padding: var(--space-3) var(--space-4);
}
.active-filter {
    display: inline-flex;
    align-items: center;
    gap: var(--space-1);
    padding: var(--space-1) var(--space-3);
    background: rgba(197, 153, 58, 0.1);
    border: 1px solid rgba(197, 153, 58, 0.2);
    border-radius: var(--radius-full);
    font-size: var(--text-xs);
    font-weight: var(--font-medium);
    color: var(--color-gold-dark);
}
.active-filter-remove {
    width: 16px;
    height: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border-radius: var(--radius-full);
    background: none;
    border: none;
    color: var(--color-gold-dark);
    font-size: 12px;
    padding: 0;
    transition: all var(--transition-fast);
}
.active-filter-remove:hover {
    background: var(--color-gold);
    color: var(--color-primary);
}
.active-filters-clear {
    font-size: var(--text-xs);
    font-weight: var(--font-semibold);
    color: var(--color-danger);
    cursor: pointer;
    background: none;
    border: none;
    padding: var(--space-1) var(--space-2);
    transition: color var(--transition-fast);
}
.active-filters-clear:hover {
    color: var(--color-danger-dark);
}

/* ==========================================================================
   12. SEARCH RESULTS
   ========================================================================== */
.search-results-header {
    padding: var(--space-4);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.search-results-count {
    font-size: var(--text-sm);
    color: var(--gray-500);
}
.search-results-count strong {
    color: var(--color-primary);
}

.search-results-sort {
    display: flex;
    align-items: center;
    gap: var(--space-2);
}
.search-results-sort select {
    height: 36px;
    font-size: var(--text-sm);
    padding: 0 var(--space-8) 0 var(--space-3);
    border-radius: var(--radius-md);
    border: 1px solid var(--gray-200);
    background: var(--color-white);
    color: var(--gray-700);
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='M2.5 4.5L6 8L9.5 4.5' stroke='%235C6478' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
}

/* No results */
.search-no-results {
    text-align: center;
    padding: var(--space-12) var(--space-6);
}
.search-no-results-icon {
    width: 80px;
    height: 80px;
    border-radius: var(--radius-full);
    background: var(--gray-100);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto var(--space-4);
    color: var(--gray-400);
    font-size: 32px;
}
.search-no-results-title {
    font-size: var(--text-xl);
    font-weight: var(--font-bold);
    color: var(--color-primary);
    margin-bottom: var(--space-2);
}
.search-no-results-message {
    font-size: var(--text-base);
    color: var(--gray-500);
}

/* ==========================================================================
   13. BROWSE PAGE
   ========================================================================== */
.browse-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-4) var(--space-4) var(--space-3);
}

.browse-sort {
    flex-shrink: 0;
}

.store-page-content {
    padding-top: var(--space-2);
}

/* ==========================================================================
   14. CATEGORIES GRID
   ========================================================================== */
.categories-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-4);
}

@media (min-width: 576px) {
    .categories-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 768px) {
    .categories-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.category-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-5);
    border-radius: var(--radius-xl);
    color: var(--color-white);
    text-decoration: none;
    min-height: 100px;
    transition: all var(--transition-normal);
    overflow: hidden;
    position: relative;
}

.category-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
    color: var(--color-white);
}

.category-card-content {
    position: relative;
    z-index: 1;
}

.category-card-name {
    font-size: var(--text-md);
    font-weight: var(--font-bold);
    color: var(--color-white);
    margin-bottom: var(--space-1);
    line-height: var(--leading-snug);
}

.category-card-count {
    font-size: var(--text-xs);
    color: rgba(255, 255, 255, 0.6);
    font-weight: var(--font-medium);
}

.category-card-icon {
    position: absolute;
    right: var(--space-3);
    bottom: var(--space-3);
}

/* ==========================================================================
   15. ORDER DETAIL TIMELINE
   ========================================================================== */
.order-timeline {
    display: flex;
    gap: var(--space-1);
    margin-top: var(--space-3);
}

.order-timeline-step {
    flex: 1;
    text-align: center;
}

.order-timeline-bar {
    height: 4px;
    border-radius: var(--radius-full);
    background: var(--gray-200);
    margin-bottom: var(--space-2);
}

.order-timeline-bar.active {
    background: var(--color-gold);
}

.order-timeline-label {
    font-size: var(--text-xs);
    text-transform: capitalize;
}

/* ==========================================================================
   16. PAGE TRANSITIONS
   ========================================================================== */
.page-transition-enter {
    opacity: 0;
    transform: translateY(10px);
}
.page-transition-enter-active {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

/* Page load animation for content blocks */
.store-page-content > * {
    animation: fadeInUp 0.4s ease backwards;
}
.store-page-content > *:nth-child(1) { animation-delay: 0s; }
.store-page-content > *:nth-child(2) { animation-delay: 0.08s; }
.store-page-content > *:nth-child(3) { animation-delay: 0.16s; }
.store-page-content > *:nth-child(4) { animation-delay: 0.24s; }
.store-page-content > *:nth-child(5) { animation-delay: 0.32s; }

/* ==========================================================================
   14. PROFILE PAGE
   ========================================================================== */
.profile-header {
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-light));
    padding: var(--space-8) var(--space-4) var(--space-6);
    text-align: center;
    border-radius: 0 0 var(--radius-2xl) var(--radius-2xl);
    margin-bottom: var(--space-6);
}
.profile-avatar {
    width: 80px;
    height: 80px;
    border-radius: var(--radius-full);
    margin: 0 auto var(--space-3);
    border: 3px solid var(--color-gold);
    overflow: hidden;
    background: var(--color-primary-lighter);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-gold);
    font-size: var(--text-2xl);
    font-weight: var(--font-bold);
}
.profile-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.profile-name {
    font-size: var(--text-xl);
    font-weight: var(--font-bold);
    color: var(--color-white);
    margin-bottom: var(--space-1);
}
.profile-email {
    font-size: var(--text-sm);
    color: rgba(255, 255, 255, 0.6);
}

.profile-menu {
    padding: 0 var(--space-4);
}
.profile-menu-group {
    background: var(--color-white);
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    margin-bottom: var(--space-4);
}
.profile-menu-item {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    padding: var(--space-4) var(--space-5);
    text-decoration: none;
    color: var(--gray-800);
    font-weight: var(--font-medium);
    transition: background var(--transition-fast);
    border-bottom: 1px solid var(--gray-50);
    touch-action: manipulation;
}
.profile-menu-item:last-child {
    border-bottom: none;
}
.profile-menu-item:hover,
.profile-menu-item:active {
    background: var(--gray-50);
}
.profile-menu-item-icon {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-lg);
    background: var(--gray-100);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-600);
    flex-shrink: 0;
}
.profile-menu-item-text {
    flex: 1;
    font-size: var(--text-base);
}
.profile-menu-item-arrow {
    color: var(--gray-400);
}
.profile-menu-item-arrow svg {
    width: 18px;
    height: 18px;
}
.profile-menu-item.danger {
    color: var(--color-danger);
}
.profile-menu-item.danger .profile-menu-item-icon {
    background: var(--color-danger-light);
    color: var(--color-danger);
}
