/* ==========================================================================
   AL-HUDA FRONTEND STYLESHEET
   All frontend styles consolidated from master layout and partials.
   ========================================================================== */

/* ─── 1. CSS VARIABLES ──────────────────────────────────────────────────── */
:root {
    --primary: #6c63ff;
    --primary-dark: #5a52d5;
    --primary-light: #8b85ff;
    --secondary: #ff6584;
    --accent: #43e97b;
    --dark: #1a1a2e;
    --dark-2: #16213e;
    --dark-3: #0f3460;
    --text: #2d3748;
    --text-light: #718096;
    --bg: #f8fafc;
    --bg-card: #ffffff;
    --border: #e2e8f0;
    --gradient-1: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-2: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --gradient-3: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    --gradient-4: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08), 0 1px 2px rgba(0, 0, 0, 0.04);
    --shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.12);
    --shadow-xl: 0 20px 60px rgba(0, 0, 0, 0.15);
    --radius: 16px;
    --radius-sm: 8px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --font-heading: "Playfair Display", serif;
    --font-body: "Inter", sans-serif;
}

/* ─── 2. BASE RESET ─────────────────────────────────────────────────────── */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
html {
    scroll-behavior: smooth;
}
body {
    font-family: var(--font-body);
    color: var(--text);
    background: var(--bg);
    overflow-x: hidden;
    line-height: 1.6;
}

/* ─── 3. SCROLLBAR ──────────────────────────────────────────────────────── */
::-webkit-scrollbar {
    width: 6px;
}
::-webkit-scrollbar-track {
    background: #f1f1f1;
}
::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 3px;
}

/* ─── 4. PAGE LOADER ────────────────────────────────────────────────────── */
#page-loader {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: var(--dark);
    display: flex;
    align-items: center;
    justify-content: center;
    transition:
        opacity 0.5s ease,
        visibility 0.5s ease;
}
#page-loader.hidden {
    opacity: 0;
    visibility: hidden;
}
.loader-logo {
    animation: loaderPulse 1.5s ease-in-out infinite;
}
@keyframes loaderPulse {
    0%,
    100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.7;
    }
}
.loader-dots {
    display: flex;
    gap: 8px;
    margin-top: 20px;
}
.loader-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--primary);
    animation: dotBounce 1.4s ease-in-out infinite;
}
.loader-dot:nth-child(2) {
    animation-delay: 0.2s;
    background: var(--secondary);
}
.loader-dot:nth-child(3) {
    animation-delay: 0.4s;
    background: var(--accent);
}
@keyframes dotBounce {
    0%,
    80%,
    100% {
        transform: scale(0);
        opacity: 0.3;
    }
    40% {
        transform: scale(1);
        opacity: 1;
    }
}

/* ─── 5. BACK TO TOP ────────────────────────────────────────────────────── */
#back-to-top {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 999;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--gradient-1);
    color: #fff;
    border: none;
    cursor: pointer;
    font-size: 18px;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    transform: translateY(10px);
}
#back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
#back-to-top:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-xl);
}

/* ─── 6. TOAST ──────────────────────────────────────────────────────────── */
.toast-custom {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    min-width: 300px;
    max-width: 400px;
    background: #fff;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-xl);
    padding: 16px 20px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    transform: translateX(150%);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border-left: 4px solid var(--primary);
}
.toast-custom.show {
    transform: translateX(0);
}
.toast-custom.success {
    border-color: #10b981;
}
.toast-custom.error {
    border-color: #ef4444;
}
.toast-custom.warning {
    border-color: #f59e0b;
}
.toast-icon {
    font-size: 20px;
    flex-shrink: 0;
}
.toast-body {
    flex: 1;
}
.toast-title {
    font-weight: 600;
    font-size: 14px;
    color: var(--text);
}
.toast-msg {
    font-size: 13px;
    color: var(--text-light);
    margin-top: 2px;
}
.toast-close {
    cursor: pointer;
    color: var(--text-light);
    font-size: 16px;
    flex-shrink: 0;
}

/* ─── 7. CART SIDEBAR ───────────────────────────────────────────────────── */
.cart-sidebar {
    position: fixed;
    top: 0;
    right: -420px;
    width: 420px;
    height: 100vh;
    z-index: 1050;
    background: #fff;
    box-shadow: -5px 0 30px rgba(0, 0, 0, 0.15);
    transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
}
.cart-sidebar.open {
    right: 0;
}
.cart-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1049;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}
.cart-overlay.show {
    opacity: 1;
    visibility: visible;
}
.cart-sidebar-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.cart-sidebar-body {
    flex: 1;
    overflow-y: auto;
    padding: 16px 24px;
}
.cart-sidebar-footer {
    padding: 20px 24px;
    border-top: 1px solid var(--border);
}

/* ─── 8. BUTTONS ────────────────────────────────────────────────────────── */
.btn-primary-custom {
    background: var(--gradient-1);
    color: #fff;
    border: none;
    padding: 12px 28px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}
.btn-primary-custom:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
    color: #fff;
}
.btn-primary-custom.btn-large {
    padding: 15px 36px;
    font-size: 16px;
}

.btn-outline-custom {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
    padding: 10px 24px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}
.btn-outline-custom:hover {
    background: var(--primary);
    color: #fff;
    transform: translateY(-2px);
}

.btn-wishlist {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: #fff;
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    color: var(--text-light);
}
.btn-wishlist:hover,
.btn-wishlist.active {
    color: #ef4444;
    border-color: #ef4444;
    transform: scale(1.1);
}
.btn-wishlist.active {
    background: #fff5f5;
}

/* ─── 9. PRODUCT CARD ───────────────────────────────────────────────────── */
.product-card {
    background: #fff;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border: 1px solid var(--border);
    position: relative;
}
.product-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-xl);
    border-color: transparent;
}

/* Legacy image wrap */
.product-image-wrap {
    position: relative;
    overflow: hidden;
    aspect-ratio: 1;
}
.product-image-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}
.product-card:hover .product-image-wrap img {
    transform: scale(1.08);
}

/* New product card media (featured products style) */
.product-card-media {
    position: relative;
    overflow: hidden;
    aspect-ratio: 1;
    background: #f1f5f9;
}
.product-card-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}
.product-card:hover .product-card-media img {
    transform: scale(1.08);
}

.product-card-overlay {
    position: absolute;
    inset: 0;
    background: rgba(26, 26, 46, 0.7);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    opacity: 0;
    transition: var(--transition);
}
.product-card:hover .product-card-overlay {
    opacity: 1;
}

.product-overlay-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    border: none;
}
.product-overlay-btn:first-child {
    background: #fff;
    color: var(--primary);
}
.product-overlay-btn:first-child:hover {
    background: var(--primary);
    color: #fff;
}
.product-overlay-btn.add-to-cart-btn {
    background: var(--gradient-1);
    color: #fff;
}
.product-overlay-btn.add-to-cart-btn:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}
.product-overlay-btn:disabled {
    background: #e2e8f0;
    color: var(--text-light);
    cursor: not-allowed;
    transform: none;
}

.product-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 4px 10px;
    border-radius: 50px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: #fff;
    z-index: 2;
}
.product-badge.sale {
    background: var(--gradient-2);
}
.product-badge.new {
    background: var(--gradient-4);
    color: #1a1a2e;
}
.product-badge.hot {
    background: var(--gradient-1);
}

.product-wishlist-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #fff;
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    color: var(--text-light);
    font-size: 14px;
    z-index: 2;
}
.product-wishlist-btn:hover,
.product-wishlist-btn.active {
    color: #ef4444;
    border-color: #ef4444;
}
.product-wishlist-btn.active {
    background: #fff5f5;
}

/* Legacy badge styles */
.product-badges {
    position: absolute;
    top: 12px;
    left: 12px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    z-index: 2;
}
.badge-sale {
    background: var(--gradient-2);
    color: #fff;
}
.badge-new {
    background: var(--gradient-4);
    color: #fff;
}
.badge-hot {
    background: var(--gradient-1);
    color: #fff;
}
.product-actions {
    position: absolute;
    top: 12px;
    right: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    opacity: 0;
    transform: translateX(10px);
    transition: var(--transition);
    z-index: 2;
}
.product-card:hover .product-actions {
    opacity: 1;
    transform: translateX(0);
}

/* Product body (legacy) */
.product-body {
    padding: 16px;
}
.product-category {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-light);
    margin-bottom: 6px;
}
.product-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 8px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.product-title a {
    color: inherit;
    text-decoration: none;
}
.product-title a:hover {
    color: var(--primary);
}
.product-price {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}
.price-current {
    font-size: 18px;
    font-weight: 700;
    color: var(--primary);
}
.price-original {
    font-size: 13px;
    color: var(--text-light);
    text-decoration: line-through;
}
.product-rating {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-bottom: 12px;
}
.star {
    color: #f59e0b;
    font-size: 12px;
}
.star.empty {
    color: #d1d5db;
}
.rating-count {
    font-size: 12px;
    color: var(--text-light);
}
.btn-add-cart {
    width: 100%;
    padding: 10px;
    background: var(--gradient-1);
    color: #fff;
    border: none;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    transition: var(--transition);
}
.btn-add-cart:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}
.btn-add-cart:disabled {
    background: #e2e8f0;
    color: var(--text-light);
    cursor: not-allowed;
    transform: none;
}

/* Product body (new featured style) */
.product-card-body {
    padding: 16px;
}
.product-card-category {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-light);
    margin-bottom: 6px;
}
.product-card-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 8px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.product-card-title a {
    color: inherit;
    text-decoration: none;
}
.product-card-title a:hover {
    color: var(--primary);
}
.product-card-rating {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 10px;
}
.stars {
    display: flex;
    gap: 2px;
}
.stars::before {
    content: "★★★★★";
    color: #f59e0b;
    font-size: 12px;
}
.product-card-price {
    display: flex;
    align-items: center;
    gap: 8px;
}
.price-old {
    font-size: 13px;
    color: var(--text-light);
    text-decoration: line-through;
}

/* ─── 10. SECTION HEADINGS ──────────────────────────────────────────────── */
.section-heading {
    text-align: center;
    margin-bottom: 48px;
}
.section-tag {
    display: inline-block;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--primary);
    font-weight: 700;
    background: rgba(108, 99, 255, 0.08);
    padding: 5px 14px;
    border-radius: 50px;
    margin-bottom: 12px;
}
.section-sub {
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--primary);
    font-weight: 600;
    margin-bottom: 10px;
}
.section-title {
    font-family: var(--font-heading);
    font-size: clamp(28px, 4vw, 42px);
    font-weight: 700;
    color: var(--dark);
    line-height: 1.2;
}
.section-desc {
    color: var(--text-light);
    font-size: 16px;
    margin-top: 12px;
}

/* ─── 11. PAGE BANNER ───────────────────────────────────────────────────── */
.page-banner {
    background: var(--dark);
    background-image: linear-gradient(
        135deg,
        var(--dark) 0%,
        var(--dark-3) 100%
    );
    padding: 60px 0;
    position: relative;
    overflow: hidden;
}
.page-banner::before {
    content: "";
    position: absolute;
    inset: 0;
    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='%23ffffff' fill-opacity='0.03'%3E%3Ccircle cx='30' cy='30' r='30'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}
.page-banner-title {
    font-family: var(--font-heading);
    font-size: 42px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 12px;
}
.page-banner .breadcrumb {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 50px;
    padding: 8px 20px;
    display: inline-flex;
}
.page-banner .breadcrumb-item a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
}
.page-banner .breadcrumb-item.active,
.page-banner .breadcrumb-item + .breadcrumb-item::before {
    color: rgba(255, 255, 255, 0.5);
}

/* ─── 12. UTILITIES ─────────────────────────────────────────────────────── */
.text-primary-custom {
    color: var(--primary) !important;
}
.bg-gradient-primary {
    background: var(--gradient-1) !important;
}
.rounded-custom {
    border-radius: var(--radius) !important;
}
.shadow-custom {
    box-shadow: var(--shadow) !important;
}
.fw-600 {
    font-weight: 600;
}
.flex-1 {
    flex: 1;
}

/* ─── 13. HEADER ────────────────────────────────────────────────────────── */
.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
}
.topbar {
    background: var(--dark);
    padding: 8px 0;
    font-size: 12px;
}
.topbar-link {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: color 0.2s;
}
.topbar-link:hover {
    color: #fff;
}
.topbar-social a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 11px;
    transition: all 0.2s;
    margin-left: 4px;
}
.topbar-social a:hover {
    background: var(--primary);
    color: #fff;
}
.navbar-main {
    background: #fff;
    padding: 0;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.06);
}
.navbar-main .container {
    min-height: 70px;
}
.navbar-brand-custom {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    padding: 12px 0;
}
.brand-logo {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    object-fit: cover;
}
.brand-text {
    line-height: 1.1;
}
.brand-name {
    font-family: var(--font-heading);
    font-size: 22px;
    font-weight: 700;
    color: var(--dark);
    display: block;
}
.brand-tagline {
    font-size: 11px;
    color: var(--text-light);
    letter-spacing: 0.5px;
}

/* Desktop Nav */
.nav-menu {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
    gap: 4px;
}
.nav-item-custom {
    position: relative;
}
.nav-link-custom {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 24px 14px;
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    transition: color 0.2s;
    white-space: nowrap;
}
.nav-link-custom:hover,
.nav-link-custom.active {
    color: var(--primary);
}
.nav-link-custom::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 14px;
    right: 14px;
    height: 2px;
    background: var(--primary);
    transform: scaleX(0);
    transition: transform 0.2s;
    border-radius: 1px;
}
.nav-link-custom:hover::after,
.nav-link-custom.active::after {
    transform: scaleX(1);
}

/* Mega Dropdown */
.mega-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: #fff;
    border-radius: var(--radius);
    box-shadow: var(--shadow-xl);
    padding: 24px;
    min-width: 640px;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    pointer-events: none;
    border: 1px solid var(--border);
    z-index: 100;
}
.nav-item-custom:hover .mega-menu {
    opacity: 1;
    visibility: visible;
    pointer-events: all;
}
.mega-col h6 {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-light);
    margin-bottom: 12px;
    font-weight: 600;
}
.mega-col a {
    display: block;
    color: var(--text);
    text-decoration: none;
    font-size: 14px;
    padding: 6px 0;
    transition: color 0.2s;
}
.mega-col a:hover {
    color: var(--primary);
    padding-left: 4px;
}
.mega-featured {
    background: var(--gradient-1);
    border-radius: var(--radius-sm);
    padding: 16px;
    color: #fff;
}
.mega-featured h5 {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 4px;
}
.mega-featured p {
    font-size: 12px;
    opacity: 0.8;
    margin-bottom: 12px;
}

/* Header actions */
.header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}
.action-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--bg);
    border: 1px solid var(--border);
    color: var(--text);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    position: relative;
    font-size: 16px;
}
.action-btn:hover {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
    transform: translateY(-2px);
}
.action-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--gradient-2);
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #fff;
}
.customer-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--primary);
    cursor: pointer;
}
.customer-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: #fff;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-xl);
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    border: 1px solid var(--border);
    z-index: 100;
    overflow: hidden;
}
.customer-dropdown.show {
    opacity: 1;
    visibility: visible;
}
.customer-dropdown a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    color: var(--text);
    text-decoration: none;
    font-size: 14px;
    transition: background 0.15s;
}
.customer-dropdown a:hover {
    background: var(--bg);
    color: var(--primary);
}
.customer-dropdown .divider {
    height: 1px;
    background: var(--border);
    margin: 4px 0;
}

/* Search Bar */
.search-overlay {
    position: fixed;
    inset: 0;
    z-index: 1200;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-top: 15vh;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}
.search-overlay.show {
    opacity: 1;
    visibility: visible;
}
.search-box {
    width: 90%;
    max-width: 680px;
    position: relative;
    transform: translateY(-30px);
    transition: transform 0.4s ease;
}
.search-overlay.show .search-box {
    transform: translateY(0);
}
.search-input {
    width: 100%;
    padding: 20px 60px 20px 24px;
    background: #fff;
    border: none;
    border-radius: 50px;
    font-size: 20px;
    font-family: var(--font-body);
    outline: none;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}
.search-submit {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: var(--gradient-1);
    color: #fff;
    border: none;
    cursor: pointer;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.search-close {
    color: rgba(255, 255, 255, 0.7);
    font-size: 24px;
    cursor: pointer;
    margin-top: 20px;
    display: inline-block;
}

/* Mobile menu */
.hamburger {
    width: 40px;
    height: 40px;
    background: none;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    transition: var(--transition);
}
.hamburger span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text);
    transition: var(--transition);
    border-radius: 1px;
}
.hamburger.open span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}
.hamburger.open span:nth-child(2) {
    opacity: 0;
}
.hamburger.open span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}
.mobile-menu {
    position: fixed;
    top: 0;
    left: -100%;
    width: 80%;
    max-width: 320px;
    height: 100vh;
    background: #fff;
    z-index: 1100;
    overflow-y: auto;
    box-shadow: 5px 0 30px rgba(0, 0, 0, 0.15);
    transition: left 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
.mobile-menu.open {
    left: 0;
}
.mobile-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1099;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}
.mobile-overlay.show {
    opacity: 1;
    visibility: visible;
}

/* ─── 14. HERO SECTION ──────────────────────────────────────────────────── */
.hero-section {
    position: relative;
    height: 100vh;
    min-height: 600px;
    overflow: hidden;
}
.hero-swiper {
    width: 100%;
    height: 100%;
}
.hero-slide {
    position: relative;
    display: flex;
    align-items: center;
    background-size: cover;
    background-position: center;
}
.hero-slide::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        105deg,
        rgba(26, 26, 46, 0.82) 0%,
        rgba(26, 26, 46, 0.35) 60%,
        transparent 100%
    );
    z-index: 1;
}
.hero-content {
    position: relative;
    z-index: 2;
    max-width: 620px;
}
.hero-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #fff;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    padding: 8px 18px;
    border-radius: 50px;
    margin-bottom: 22px;
}
.hero-title {
    font-family: var(--font-heading);
    font-size: clamp(2.4rem, 6vw, 5rem);
    font-weight: 700;
    color: #fff;
    line-height: 1.1;
    margin-bottom: 20px;
}
.hero-title .accent {
    background: var(--gradient-2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.hero-desc {
    color: rgba(255, 255, 255, 0.82);
    font-size: 1.1rem;
    line-height: 1.7;
    margin-bottom: 36px;
    max-width: 480px;
}
.hero-actions {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}
.hero-btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: var(--gradient-1);
    color: #fff;
    font-weight: 600;
    font-size: 0.95rem;
    padding: 14px 32px;
    border-radius: 50px;
    border: none;
    text-decoration: none;
    transition: var(--transition);
    box-shadow: 0 8px 30px rgba(108, 99, 255, 0.4);
}
.hero-btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(108, 99, 255, 0.5);
    color: #fff;
}
.hero-btn-outline {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: transparent;
    color: #fff;
    font-weight: 600;
    font-size: 0.95rem;
    padding: 14px 32px;
    border-radius: 50px;
    border: 2px solid rgba(255, 255, 255, 0.5);
    text-decoration: none;
    transition: var(--transition);
    backdrop-filter: blur(4px);
}
.hero-btn-outline:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: #fff;
    color: #fff;
    transform: translateY(-3px);
}
.hero-stats {
    display: flex;
    gap: 32px;
    margin-top: 48px;
}
.hero-stat-num {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 700;
    color: #fff;
    line-height: 1;
}
.hero-stat-label {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.65);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 4px;
}
.hero-swiper .swiper-pagination-bullet {
    background: rgba(255, 255, 255, 0.5);
    opacity: 1;
    width: 8px;
    height: 8px;
    transition: all 0.3s;
}
.hero-swiper .swiper-pagination-bullet-active {
    background: #fff;
    width: 28px;
    border-radius: 4px;
}
.swiper-button-next.hero-nav,
.swiper-button-prev.hero-nav {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #fff;
    transition: var(--transition);
}
.swiper-button-next.hero-nav::after,
.swiper-button-prev.hero-nav::after {
    font-size: 16px;
    font-weight: 700;
}
.swiper-button-next.hero-nav:hover,
.swiper-button-prev.hero-nav:hover {
    background: rgba(255, 255, 255, 0.3);
}
.scroll-indicator {
    position: absolute;
    bottom: 32px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.72rem;
    letter-spacing: 1px;
    text-transform: uppercase;
}
.scroll-mouse {
    width: 24px;
    height: 38px;
    border: 2px solid rgba(255, 255, 255, 0.4);
    border-radius: 12px;
    display: flex;
    justify-content: center;
    padding-top: 6px;
}
.scroll-dot {
    width: 4px;
    height: 8px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 2px;
    animation: scrollDot 1.6s ease-in-out infinite;
}
@keyframes scrollDot {
    0%,
    100% {
        transform: translateY(0);
        opacity: 1;
    }
    50% {
        transform: translateY(10px);
        opacity: 0.3;
    }
}

/* Trust Bar */
.trust-bar {
    background: var(--dark);
    padding: 14px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.trust-item {
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.82rem;
    font-weight: 500;
}
.trust-item i {
    color: var(--accent);
    font-size: 1rem;
}

/* ─── 15. CATEGORIES SECTION ────────────────────────────────────────────── */
.categories-section {
    padding: 80px 0;
    background: var(--bg);
}
.cat-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}
.cat-grid .cat-card-lg {
    grid-row: span 2;
}
.cat-card {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius);
    cursor: pointer;
    background: #1a1a1a;
    height: 260px;
    transition: var(--transition);
}
.cat-card-lg {
    height: 540px;
}
.cat-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}
.cat-card:hover img {
    transform: scale(1.08);
}
.cat-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(26, 26, 46, 0.88) 0%,
        rgba(26, 26, 46, 0.2) 50%,
        transparent 100%
    );
    transition: var(--transition);
}
.cat-card:hover::after {
    background: linear-gradient(
        to top,
        rgba(108, 99, 255, 0.65) 0%,
        rgba(26, 26, 46, 0.3) 60%,
        transparent 100%
    );
}
.cat-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 28px 24px;
    z-index: 2;
    transform: translateY(8px);
    transition: var(--transition);
}
.cat-card:hover .cat-info {
    transform: translateY(0);
}
.cat-name {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 6px;
}
.cat-count {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.65);
    margin-bottom: 14px;
}
.cat-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #fff;
    font-size: 0.82rem;
    font-weight: 600;
    text-decoration: none;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.25);
    padding: 7px 16px;
    border-radius: 50px;
    transition: var(--transition);
    opacity: 0;
    transform: translateY(6px);
}
.cat-card:hover .cat-link {
    opacity: 1;
    transform: translateY(0);
}
.cat-link:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

/* ─── 16. FEATURED PRODUCTS ─────────────────────────────────────────────── */
.featured-section {
    padding: 80px 0;
    background: #f8fafc;
}
.products-tabs {
    display: flex;
    gap: 8px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 32px;
    margin-bottom: 48px;
}
.tab-pill {
    padding: 9px 22px;
    border-radius: 50px;
    border: 2px solid var(--border);
    background: transparent;
    color: var(--text-light);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}
.tab-pill.active,
.tab-pill:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}
.feat-swiper {
    padding-bottom: 50px !important;
}
.feat-swiper .swiper-pagination-bullet {
    background: var(--primary);
}
.feat-swiper .swiper-pagination-bullet-active {
    width: 24px;
    border-radius: 4px;
}

/* ─── 17. BANNER SECTION ────────────────────────────────────────────────── */
.banner-section {
    padding: 80px 0;
    background: var(--bg);
    overflow: hidden;
}
.banner-inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-xl);
    min-height: 500px;
}
.banner-left {
    background: var(--gradient-1);
    padding: 60px 56px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    overflow: hidden;
}
.banner-left::before {
    content: "";
    position: absolute;
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 50%;
    top: -60px;
    right: -60px;
}
.banner-left::after {
    content: "";
    position: absolute;
    width: 200px;
    height: 200px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 50%;
    bottom: -40px;
    left: -40px;
}
.banner-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    padding: 7px 16px;
    border-radius: 50px;
    margin-bottom: 24px;
    width: fit-content;
}
.banner-title {
    font-family: var(--font-heading);
    font-size: clamp(2rem, 4vw, 3rem);
    color: #fff;
    font-weight: 700;
    line-height: 1.15;
    margin-bottom: 20px;
}
.banner-desc {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 36px;
}
.banner-features {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin-bottom: 36px;
}
.banner-feature {
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.875rem;
}
.banner-feature i {
    color: var(--accent);
    font-size: 1rem;
}
.banner-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: #fff;
    color: var(--primary);
    font-weight: 700;
    font-size: 0.95rem;
    padding: 14px 32px;
    border-radius: 50px;
    text-decoration: none;
    transition: var(--transition);
    width: fit-content;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}
.banner-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.2);
    color: var(--primary);
}
.banner-right {
    position: relative;
    overflow: hidden;
    min-height: 400px;
}
.banner-right img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.7s ease;
}
.banner-right:hover img {
    transform: scale(1.04);
}
.banner-right-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to right,
        rgba(102, 126, 234, 0.5) 0%,
        transparent 60%
    );
}
.mini-banners {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 20px;
}
.mini-banner {
    position: relative;
    height: 200px;
    border-radius: var(--radius);
    overflow: hidden;
    cursor: pointer;
}
.mini-banner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}
.mini-banner:hover img {
    transform: scale(1.06);
}
.mini-banner::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        135deg,
        rgba(26, 26, 46, 0.7) 0%,
        transparent 70%
    );
}
.mini-banner-info {
    position: absolute;
    bottom: 20px;
    left: 20px;
    z-index: 2;
}
.mini-banner-name {
    font-family: var(--font-heading);
    color: #fff;
    font-size: 1.1rem;
    font-weight: 700;
}
.mini-banner-cta {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.8rem;
    margin-top: 4px;
}

/* ─── 18. NEWSLETTER SECTION ────────────────────────────────────────────── */
.newsletter-section {
    padding: 80px 0;
    background: var(--gradient-1);
    position: relative;
    overflow: hidden;
}
.newsletter-section::before {
    content: "";
    position: absolute;
    width: 500px;
    height: 500px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.06);
    top: -150px;
    right: -100px;
}
.newsletter-section::after {
    content: "";
    position: absolute;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.04);
    bottom: -80px;
    left: -60px;
}
.newsletter-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.18);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    padding: 7px 18px;
    border-radius: 50px;
    margin-bottom: 20px;
}
.newsletter-title {
    font-family: var(--font-heading);
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    color: #fff;
    font-weight: 700;
    margin-bottom: 16px;
}
.newsletter-desc {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.05rem;
    margin-bottom: 40px;
}
.newsletter-form {
    display: flex;
    gap: 0;
    max-width: 560px;
    margin: 0 auto 16px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 50px;
    padding: 6px 6px 6px 24px;
}
.newsletter-input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    color: #fff;
    font-size: 0.95rem;
}
.newsletter-input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}
.newsletter-submit {
    background: #fff;
    color: var(--primary);
    font-weight: 700;
    font-size: 0.875rem;
    border: none;
    padding: 12px 28px;
    border-radius: 50px;
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
}
.newsletter-submit:hover {
    background: var(--dark);
    color: #fff;
}
.newsletter-note {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.8rem;
}
.newsletter-stats {
    display: flex;
    gap: 48px;
    justify-content: center;
    margin-top: 48px;
    flex-wrap: wrap;
}
.nl-stat-num {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 700;
    color: #fff;
    line-height: 1;
}
.nl-stat-label {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.65);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 4px;
}

/* ─── 19. FOOTER ────────────────────────────────────────────────────────── */
.site-footer {
    background: var(--dark);
    color: rgba(255, 255, 255, 0.75);
    font-size: 14px;
}
.footer-top {
    padding: 72px 0 48px;
}
.footer-brand-name {
    font-family: var(--font-heading);
    font-size: 28px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 12px;
}
.footer-desc {
    line-height: 1.8;
    margin-bottom: 24px;
}
.footer-social a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s;
    margin-right: 8px;
}
.footer-social a:hover {
    background: var(--primary);
    color: #fff;
    transform: translateY(-2px);
}
.footer-heading {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #fff;
    font-weight: 700;
    margin-bottom: 20px;
}
.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}
.footer-links li {
    margin-bottom: 10px;
}
.footer-links a {
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.footer-links a:hover {
    color: #fff;
    padding-left: 4px;
}
.footer-contact-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 14px;
}
.footer-contact-icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: rgba(108, 99, 255, 0.2);
    color: var(--primary-light);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 14px;
}
.footer-newsletter-form {
    display: flex;
    gap: 0;
    border-radius: 50px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
}
.footer-newsletter-input {
    flex: 1;
    background: transparent;
    border: none;
    padding: 12px 16px;
    color: #fff;
    font-family: var(--font-body);
    outline: none;
    font-size: 14px;
}
.footer-newsletter-input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}
.footer-newsletter-btn {
    background: var(--gradient-1);
    color: #fff;
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    flex-shrink: 0;
    font-weight: 600;
    font-size: 13px;
    transition: opacity 0.2s;
}
.footer-newsletter-btn:hover {
    opacity: 0.9;
}
.footer-divider {
    border-color: rgba(255, 255, 255, 0.08) !important;
}
.payment-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 6px;
    font-size: 20px;
    margin-right: 6px;
    margin-bottom: 6px;
}
.footer-bottom {
    padding: 20px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}
.footer-bottom-links a {
    color: rgba(255, 255, 255, 0.5);
    text-decoration: none;
    font-size: 13px;
    margin-left: 20px;
    transition: color 0.2s;
}
.footer-bottom-links a:hover {
    color: #fff;
}

/* ─── 20. RESPONSIVE ────────────────────────────────────────────────────── */
@media (max-width: 991px) {
    .nav-desktop {
        display: none;
    }
    .hamburger {
        display: flex;
    }
    .mega-menu {
        display: none;
    }
}
@media (min-width: 992px) {
    .mobile-menu,
    .mobile-overlay {
        display: none;
    }
}
@media (max-width: 768px) {
    .cart-sidebar {
        width: 100%;
        right: -100%;
    }
    .page-banner-title {
        font-size: 28px;
    }
    .hero-stats {
        gap: 20px;
    }
    .hero-stat-num {
        font-size: 1.5rem;
    }
    .swiper-button-next.hero-nav,
    .swiper-button-prev.hero-nav {
        display: none;
    }
    .banner-inner {
        grid-template-columns: 1fr;
    }
    .mini-banners {
        grid-template-columns: 1fr;
    }
}
@media (max-width: 992px) {
    .cat-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 576px) {
    .cat-grid {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }
    .cat-card,
    .cat-card-lg {
        height: 180px;
    }
    .newsletter-form {
        flex-direction: column;
        border-radius: var(--radius);
        padding: 10px;
        gap: 8px;
    }
    .newsletter-input {
        padding: 10px 12px;
    }
    .newsletter-submit {
        border-radius: var(--radius);
    }
    .newsletter-stats {
        gap: 24px;
    }
}

/* ==========================================================================
   21. COMPREHENSIVE MOBILE & RESPONSIVE DESIGN SYSTEM
   Full web + mobile responsive overhaul — all breakpoints covered.
   ========================================================================== */

/* ── 21A. MOBILE BOTTOM NAVIGATION BAR ──────────────────────────────────── */
.mobile-bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1080;
    background: #fff;
    border-top: 1px solid var(--border);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.08);
    padding: 0;
    padding-bottom: env(safe-area-inset-bottom, 0px);
}
.mobile-bottom-nav-inner {
    display: flex;
    align-items: stretch;
    height: 60px;
}
.mobile-nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    text-decoration: none;
    color: var(--text-light);
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.3px;
    transition: color 0.2s;
    position: relative;
    cursor: pointer;
    border: none;
    background: none;
    padding: 4px 2px;
    -webkit-tap-highlight-color: transparent;
}
.mobile-nav-item i {
    font-size: 18px;
    transition:
        transform 0.2s,
        color 0.2s;
}
.mobile-nav-item.active,
.mobile-nav-item:active {
    color: var(--primary);
}
.mobile-nav-item.active i {
    transform: translateY(-2px);
}
.mobile-nav-item::before {
    content: "";
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 28px;
    height: 3px;
    background: var(--gradient-1);
    border-radius: 0 0 3px 3px;
    transition: transform 0.2s;
}
.mobile-nav-item.active::before {
    transform: translateX(-50%) scaleX(1);
}
.mobile-nav-badge {
    position: absolute;
    top: 6px;
    right: calc(50% - 14px);
    min-width: 16px;
    height: 16px;
    border-radius: 8px;
    background: var(--gradient-2);
    color: #fff;
    font-size: 9px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 3px;
    border: 2px solid #fff;
}
@media (max-width: 991px) {
    .mobile-bottom-nav {
        display: block;
    }
    /* Add padding to body so content is not hidden behind bottom nav */
    body {
        padding-bottom: calc(60px + env(safe-area-inset-bottom, 0px));
    }
    /* Adjust back-to-top button above bottom nav */
    #back-to-top {
        bottom: calc(72px + env(safe-area-inset-bottom, 0px));
    }
}

/* ── 21B. HEADER / TOPBAR ────────────────────────────────────────────────── */
@media (max-width: 991px) {
    .topbar {
        display: none !important;
    }
    .navbar-main .container {
        min-height: 60px;
        padding: 0 16px;
    }
    .brand-name {
        font-size: 18px;
    }
    .brand-tagline {
        display: none;
    }
    /* Tighten header action buttons on mobile */
    .header-actions {
        gap: 4px;
    }
    .action-btn {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }
    .action-badge {
        width: 16px;
        height: 16px;
        font-size: 9px;
    }
    /* Customer notification panel full width on mobile */
    #cust-notif-panel {
        width: calc(100vw - 32px) !important;
        max-width: 360px !important;
        right: -60px !important;
    }
}
@media (max-width: 575px) {
    .navbar-main .container {
        padding: 0 12px;
    }
    .brand-logo {
        width: 36px;
        height: 36px;
    }
    .brand-name {
        font-size: 16px;
    }
}

/* ── 21C. MOBILE MENU ENHANCEMENTS ──────────────────────────────────────── */
.mobile-menu {
    display: flex;
    flex-direction: column;
}
.mobile-menu-search {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
}
.mobile-menu-search-input {
    width: 100%;
    padding: 10px 16px;
    border: 1.5px solid var(--border);
    border-radius: 50px;
    font-size: 14px;
    outline: none;
    background: var(--bg);
    transition: var(--transition);
}
.mobile-menu-search-input:focus {
    border-color: var(--primary);
    background: #fff;
}
.mobile-nav-group {
    padding: 8px 0;
    border-bottom: 1px solid var(--border);
}
.mobile-nav-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 13px 20px;
    color: var(--text);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition:
        background 0.15s,
        color 0.15s;
    -webkit-tap-highlight-color: transparent;
}
.mobile-nav-link:hover,
.mobile-nav-link:active {
    background: rgba(108, 99, 255, 0.05);
    color: var(--primary);
}
.mobile-nav-link .nav-icon {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: rgba(108, 99, 255, 0.08);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    flex-shrink: 0;
}
.mobile-nav-link .chevron {
    font-size: 10px;
    color: var(--text-light);
    transition: transform 0.2s;
}
.mobile-nav-sub {
    background: var(--bg);
    overflow: hidden;
    max-height: 0;
    transition: max-height 0.3s ease;
}
.mobile-nav-sub.open {
    max-height: 400px;
}
.mobile-nav-sub a {
    display: block;
    padding: 10px 20px 10px 56px;
    color: var(--text-light);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.15s;
}
.mobile-nav-sub a:hover {
    color: var(--primary);
}

/* ── 21D. HERO SECTION RESPONSIVE ────────────────────────────────────────── */
@media (max-width: 991px) {
    .hero-section {
        height: 85vh;
        min-height: 500px;
    }
    .hero-stats {
        gap: 24px;
        margin-top: 32px;
        flex-wrap: wrap;
    }
}
@media (max-width: 767px) {
    .hero-section {
        height: 75vh;
        min-height: 460px;
    }
    .hero-slide::before {
        background: rgba(26, 26, 46, 0.72);
    }
    .hero-content {
        max-width: 100%;
        padding: 0 4px;
    }
    .hero-tag {
        font-size: 0.7rem;
        padding: 6px 14px;
        margin-bottom: 14px;
    }
    .hero-title {
        font-size: clamp(1.8rem, 8vw, 2.8rem);
        margin-bottom: 14px;
    }
    .hero-desc {
        font-size: 0.92rem;
        margin-bottom: 24px;
        max-width: 100%;
    }
    .hero-btn-primary,
    .hero-btn-outline {
        padding: 12px 22px;
        font-size: 0.88rem;
    }
    .hero-actions {
        gap: 10px;
    }
    .hero-stats {
        gap: 16px;
        margin-top: 24px;
    }
    .hero-stat-num {
        font-size: 1.3rem;
    }
    .hero-stat-label {
        font-size: 0.7rem;
    }
}
@media (max-width: 575px) {
    .hero-section {
        height: 70vh;
        min-height: 420px;
    }
    .hero-title {
        font-size: clamp(1.6rem, 7vw, 2.2rem);
    }
    .hero-desc {
        display: none;
    }
    .hero-stats {
        display: none;
    }
    .scroll-indicator {
        display: none;
    }
    .hero-actions {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    .hero-btn-primary,
    .hero-btn-outline {
        width: 100%;
        max-width: 220px;
        justify-content: center;
    }
}

/* ── 21E. TRUST BAR ──────────────────────────────────────────────────────── */
@media (max-width: 767px) {
    .trust-bar {
        padding: 10px 0;
    }
    .trust-item {
        font-size: 0.75rem;
        gap: 6px;
    }
    .trust-item i {
        font-size: 0.85rem;
    }
}
@media (max-width: 575px) {
    .trust-bar .col-6 {
        text-align: center !important;
    }
    .trust-item {
        justify-content: center;
    }
}

/* ── 21F. CATEGORY SECTION ───────────────────────────────────────────────── */
@media (max-width: 991px) {
    .categories-section {
        padding: 56px 0;
    }
    .cat-grid {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: auto;
    }
    .cat-card-lg {
        grid-row: span 1;
        height: 240px;
    }
    .cat-grid .cat-card:first-child {
        grid-column: span 2;
    }
}
@media (max-width: 575px) {
    .categories-section {
        padding: 40px 0;
    }
    .cat-grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }
    .cat-grid .cat-card:first-child {
        grid-column: span 2;
        height: 180px;
    }
    .cat-card {
        height: 150px;
    }
    .cat-card-lg {
        height: 180px;
    }
    .cat-name {
        font-size: 1rem;
    }
    .cat-count {
        display: none;
    }
    .cat-link {
        opacity: 1;
        transform: none;
        font-size: 0.72rem;
        padding: 5px 12px;
    }
    .cat-info {
        padding: 16px;
    }
}

/* ── 21G. FEATURED PRODUCTS / PRODUCT CARDS ──────────────────────────────── */
@media (max-width: 991px) {
    .featured-section {
        padding: 56px 0;
    }
    .products-tabs {
        gap: 6px;
        margin-top: 24px;
        margin-bottom: 32px;
    }
    .tab-pill {
        padding: 7px 16px;
        font-size: 0.8rem;
    }
}
@media (max-width: 575px) {
    .featured-section {
        padding: 40px 0;
    }
    .products-tabs {
        gap: 6px;
        margin-bottom: 24px;
        overflow-x: auto;
        flex-wrap: nowrap;
        justify-content: flex-start;
        padding-bottom: 4px;
    }
    .tab-pill {
        flex-shrink: 0;
        font-size: 0.78rem;
        padding: 6px 14px;
    }
    /* Swiper slides show 2 on mobile */
    .feat-swiper .swiper-slide {
        width: 200px !important;
    }
    .product-card-title {
        font-size: 13px;
    }
    .price-current {
        font-size: 15px;
    }
}

/* ── 21H. BANNER SECTION ─────────────────────────────────────────────────── */
@media (max-width: 991px) {
    .banner-section {
        padding: 56px 0;
    }
    .banner-inner {
        grid-template-columns: 1fr;
        min-height: auto;
    }
    .banner-left {
        padding: 40px 32px;
        order: 1;
    }
    .banner-right {
        order: 0;
        min-height: 280px;
    }
}
@media (max-width: 767px) {
    .banner-left {
        padding: 32px 24px;
    }
    .banner-features {
        grid-template-columns: 1fr;
        gap: 10px;
        margin-bottom: 24px;
    }
    .mini-banners {
        grid-template-columns: 1fr;
        gap: 12px;
        margin-top: 16px;
    }
    .mini-banner {
        height: 160px;
    }
}
@media (max-width: 575px) {
    .banner-right {
        min-height: 220px;
    }
    .mini-banners {
        grid-template-columns: 1fr 1fr;
    }
    .mini-banner {
        height: 130px;
    }
    .mini-banner-name {
        font-size: 0.9rem;
    }
}

/* ── 21I. NEWSLETTER SECTION ─────────────────────────────────────────────── */
@media (max-width: 767px) {
    .newsletter-section {
        padding: 56px 0;
    }
    .newsletter-title {
        font-size: clamp(1.4rem, 5vw, 2rem);
    }
    .newsletter-desc {
        font-size: 0.92rem;
        margin-bottom: 28px;
    }
    .newsletter-stats {
        gap: 28px;
    }
    .nl-stat-num {
        font-size: 1.5rem;
    }
}
@media (max-width: 575px) {
    .newsletter-section {
        padding: 40px 0;
    }
    .newsletter-form {
        flex-direction: column;
        border-radius: var(--radius);
        padding: 10px;
        gap: 8px;
    }
    .newsletter-input {
        padding: 10px 12px;
        font-size: 0.875rem;
        color: #fff;
    }
    .newsletter-submit {
        border-radius: 50px;
        padding: 12px;
    }
    .newsletter-stats {
        gap: 20px;
    }
    .newsletter-tag {
        font-size: 0.7rem;
    }
}

/* ── 21J. FOOTER ─────────────────────────────────────────────────────────── */
@media (max-width: 991px) {
    .footer-top {
        padding: 48px 0 32px;
    }
    .footer-brand-name {
        font-size: 22px;
    }
}
@media (max-width: 767px) {
    .footer-top {
        padding: 40px 0 28px;
    }
    .payment-icon {
        padding: 5px 8px;
        font-size: 16px;
        margin-right: 4px;
        margin-bottom: 4px;
    }
}
@media (max-width: 575px) {
    .footer-top {
        padding: 36px 0 24px;
    }
    .footer-bottom {
        padding: 16px 0;
    }
    .footer-bottom .container {
        flex-direction: column;
        text-align: center;
        gap: 12px;
    }
    .footer-bottom-links {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 8px;
    }
    .footer-bottom-links a {
        margin-left: 0;
        font-size: 12px;
    }
    .footer-social a {
        width: 34px;
        height: 34px;
        font-size: 12px;
    }
}

/* ── 21K. CART SIDEBAR IMPROVEMENTS ─────────────────────────────────────── */
@media (max-width: 575px) {
    .cart-sidebar-header {
        padding: 16px 18px;
    }
    .cart-sidebar-body {
        padding: 12px 16px;
    }
    .cart-sidebar-footer {
        padding: 16px 18px;
    }
}

/* ── 21L. PRODUCTS INDEX PAGE ────────────────────────────────────────────── */
@media (max-width: 991px) {
    /* Filter panel becomes a slide-in overlay on mobile */
    .filter-sidebar {
        position: fixed;
        top: 0;
        left: -100%;
        width: 300px;
        height: 100vh;
        z-index: 1090;
        overflow-y: auto;
        transition: left 0.35s cubic-bezier(0.4, 0, 0.2, 1);
        background: #fff;
        box-shadow: 4px 0 20px rgba(0, 0, 0, 0.12);
        padding: 24px 20px;
    }
    .filter-sidebar.open {
        left: 0;
    }
    .products-section-layout {
        grid-template-columns: 1fr;
    }
    .filter-toggle-btn {
        display: flex;
    }
}
@media (max-width: 575px) {
    .products-toolbar {
        flex-wrap: wrap;
        gap: 8px;
        padding: 10px 14px;
    }
    .toolbar-count {
        font-size: 0.82rem;
        order: 0;
        flex: 1;
    }
    .view-toggle {
        order: 1;
    }
    .toolbar-sort {
        order: 2;
        width: 100%;
    }
    .toolbar-sort select {
        width: 100%;
        font-size: 0.82rem;
    }
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    .product-card-body {
        padding: 10px 10px 12px;
    }
    .product-card-title {
        font-size: 12px;
    }
    .product-card-category {
        font-size: 10px;
    }
    .price-current {
        font-size: 14px;
    }
    .price-old {
        font-size: 11px;
    }
    .page-banner {
        padding: 36px 0;
    }
    .page-banner-title {
        font-size: 22px;
        margin-bottom: 8px;
    }
}

/* ── 21M. PRODUCT DETAIL PAGE ────────────────────────────────────────────── */
@media (max-width: 991px) {
    .product-detail-section {
        padding: 32px 0 48px;
    }
}
@media (max-width: 767px) {
    .product-detail-section .row.g-5 {
        gap: 24px !important;
    }
    .gallery-thumbs {
        gap: 8px;
    }
    .thumb-img {
        width: 60px;
        height: 60px;
    }
    .product-detail-title {
        font-size: clamp(1.3rem, 4vw, 1.8rem);
    }
    .info-pills {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }
    .info-pill {
        padding: 10px 12px;
        gap: 8px;
    }
    .info-pill-title {
        font-size: 0.78rem;
    }
    .info-pill-sub {
        font-size: 0.7rem;
    }
    .custom-tabs {
        overflow-x: auto;
        flex-wrap: nowrap;
        gap: 0;
    }
    .custom-tab {
        flex-shrink: 0;
        font-size: 0.82rem;
        padding: 10px 18px;
    }
}
@media (max-width: 575px) {
    .product-detail-section {
        padding: 24px 0 120px; /* extra bottom for sticky cta */
    }
    .gallery-thumbs {
        gap: 6px;
    }
    .thumb-img {
        width: 52px;
        height: 52px;
    }
    .size-btns {
        gap: 6px;
    }
    .size-btn {
        width: 40px;
        height: 40px;
        font-size: 0.8rem;
    }
    .color-btn {
        width: 30px;
        height: 30px;
    }
    /* Hide desktop add-to-cart buttons row (replaced by sticky CTA) */
    .product-desktop-cta {
        display: none;
    }
}

/* ── 21N. STICKY MOBILE ADD-TO-CART BAR (Product Detail Page) ───────────── */
.mobile-sticky-cta {
    display: none;
    position: fixed;
    bottom: calc(60px + env(safe-area-inset-bottom, 0px));
    left: 0;
    right: 0;
    z-index: 1070;
    background: #fff;
    border-top: 1px solid var(--border);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.1);
    padding: 12px 16px;
}
.mobile-sticky-cta-inner {
    display: flex;
    gap: 10px;
    align-items: center;
}
.mobile-sticky-cta-price {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--dark);
    flex: 1;
}
.mobile-sticky-cta-price small {
    display: block;
    font-size: 0.7rem;
    color: var(--text-light);
    font-family: var(--font-body);
    font-weight: 400;
    margin-top: -2px;
}
.mobile-sticky-btn-cart {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: var(--gradient-1);
    color: #fff;
    font-weight: 700;
    font-size: 0.9rem;
    padding: 12px 16px;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    -webkit-tap-highlight-color: transparent;
}
.mobile-sticky-btn-wishlist {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    border: 2px solid var(--border);
    background: #fff;
    color: var(--text-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    cursor: pointer;
    transition: var(--transition);
    flex-shrink: 0;
    -webkit-tap-highlight-color: transparent;
}
.mobile-sticky-btn-wishlist.active {
    color: #ef4444;
    border-color: #ef4444;
    background: #fff5f5;
}
@media (max-width: 575px) {
    .mobile-sticky-cta {
        display: block;
    }
}

/* ── 21O. CART PAGE ──────────────────────────────────────────────────────── */
@media (max-width: 767px) {
    .cart-section {
        padding: 32px 0 56px;
    }
    .cart-steps {
        margin-bottom: 32px;
        gap: 0;
    }
    .cart-card-header {
        padding: 16px 18px;
    }
    .cart-item-row {
        grid-template-columns: 72px 1fr;
        grid-template-rows: auto auto auto;
        gap: 8px 12px;
        padding: 16px 18px;
    }
    .cart-item-img {
        width: 72px;
        height: 72px;
        border-radius: 10px;
        grid-row: span 3;
    }
    .cart-item-name {
        font-size: 0.88rem;
        margin-bottom: 2px;
    }
    .cart-item-row > :nth-child(3) {
        grid-column: 2;
    }
    .cart-item-row > :nth-child(4) {
        grid-column: 2;
        display: flex;
        align-items: center;
        gap: 12px;
    }
    .cart-item-row > :nth-child(5) {
        grid-column: 2;
    }
    .cart-item-price {
        font-size: 0.95rem;
    }
    .summary-card {
        position: relative;
        top: 0;
    }
}
@media (max-width: 575px) {
    .cart-section {
        padding: 24px 0 40px;
    }
    .cart-steps {
        gap: 0;
    }
    .step-line {
        width: 28px;
    }
    .summary-card {
        padding: 20px 18px;
    }
    .btn-checkout {
        font-size: 0.92rem;
        padding: 14px;
    }
}

/* ── 21P. CHECKOUT PAGE ──────────────────────────────────────────────────── */
@media (max-width: 767px) {
    .checkout-section {
        padding: 32px 0 56px;
    }
    .checkout-card {
        padding: 22px 18px;
    }
    .payment-tabs {
        flex-direction: column;
        gap: 8px;
    }
    .payment-tab {
        min-width: 0;
        justify-content: flex-start;
        padding: 12px 16px;
        text-align: left;
    }
    .order-summary-card {
        position: relative;
        top: 0;
        padding: 20px 18px;
    }
}
@media (max-width: 575px) {
    .checkout-section {
        padding: 24px 0 40px;
    }
    .checkout-card {
        padding: 18px 14px;
        border-radius: var(--radius-sm);
    }
    .checkout-card-title {
        font-size: 1rem;
    }
    .form-row {
        grid-template-columns: 1fr;
        gap: 12px;
    }
}

/* ── 21Q. ABOUT / CONTACT / AUTH PAGES ───────────────────────────────────── */
@media (max-width: 767px) {
    .page-banner {
        padding: 40px 0;
    }
    .page-banner-title {
        font-size: 26px;
    }
}
@media (max-width: 575px) {
    .page-banner {
        padding: 32px 0;
    }
    .page-banner-title {
        font-size: 22px;
    }
}

/* ── 21R. SECTION HEADINGS RESPONSIVE ───────────────────────────────────── */
@media (max-width: 767px) {
    .section-heading {
        margin-bottom: 32px;
    }
    .section-title {
        font-size: clamp(22px, 5vw, 32px);
    }
    .section-desc {
        font-size: 14px;
    }
}
@media (max-width: 575px) {
    .section-heading {
        margin-bottom: 24px;
    }
    .section-tag {
        font-size: 11px;
        padding: 4px 12px;
    }
}

/* ── 21S. SEARCH OVERLAY ─────────────────────────────────────────────────── */
@media (max-width: 767px) {
    .search-overlay {
        padding-top: 8vh;
        align-items: flex-start;
    }
    .search-box {
        width: 100%;
    }
    .search-input {
        font-size: 16px;
        padding: 16px 56px 16px 20px;
    }
    .search-submit {
        width: 40px;
        height: 40px;
        font-size: 15px;
    }
    .search-close {
        font-size: 20px;
    }
}

/* ── 21T. FILTER SIDEBAR OVERLAY BACKDROP ───────────────────────────────── */
.filter-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1089;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}
.filter-overlay.show {
    opacity: 1;
    visibility: visible;
}
@media (max-width: 991px) {
    .filter-overlay {
        display: block;
    }
}

/* ── 21U. PRODUCT CARD MOBILE QUICK ACTIONS ──────────────────────────────── */
@media (max-width: 575px) {
    /* Always show wishlist button on mobile (no hover) */
    .product-wishlist-btn {
        opacity: 1;
    }
    /* Overlay only shows on tap on mobile */
    .product-card-overlay {
        opacity: 0;
        pointer-events: none;
    }
    /* Mobile tap hint */
    .product-card::after {
        display: none;
    }
}

/* ── 21V. SWIPER / CAROUSEL ──────────────────────────────────────────────── */
@media (max-width: 575px) {
    .feat-swiper {
        padding-bottom: 40px !important;
    }
    .swiper-pagination {
        bottom: 4px !important;
    }
}

/* ── 21W. GENERAL SPACING ON MOBILE ─────────────────────────────────────── */
@media (max-width: 767px) {
    .container {
        padding-left: 16px;
        padding-right: 16px;
    }
}
@media (max-width: 575px) {
    .container {
        padding-left: 14px;
        padding-right: 14px;
    }
    /* Reduce section padding on mobile */
    section {
        scroll-margin-top: 70px;
    }
    .cart-section,
    .checkout-section,
    .product-detail-section,
    .product-tabs-section,
    .related-section {
        scroll-margin-top: 70px;
    }
}

/* ── 21X. SCROLL-SNAP FOR MOBILE PRODUCT GRID ────────────────────────────── */
@media (max-width: 575px) {
    .related-section .swiper-slide {
        width: 180px !important;
    }
}

/* ── 21Y. TOUCH TARGET MINIMUM SIZES ────────────────────────────────────── */
@media (max-width: 991px) {
    button,
    a,
    input[type="button"],
    input[type="submit"] {
        min-height: 38px;
    }
    .size-btn {
        min-width: 44px;
        min-height: 44px;
    }
    .color-btn {
        min-width: 36px;
        min-height: 36px;
    }
}

/* ── 21Z. TYPOGRAPHY FLUID SCALING ──────────────────────────────────────── */
@media (max-width: 575px) {
    html {
        font-size: 15px;
    }
}
@media (max-width: 375px) {
    html {
        font-size: 14px;
    }
    .hero-title {
        font-size: 1.6rem;
    }
    .product-detail-title {
        font-size: 1.2rem;
    }
}

/* ── 21AA. BODY PADDING FOR MOBILE BOTTOM NAV ────────────────────────────── */
/* Ensure last section is not hidden behind mobile bottom nav + sticky footer */
@media (max-width: 991px) {
    .site-footer {
        margin-bottom: 0;
    }
    /* Additional bottom space when footer is visible */
    .footer-bottom {
        padding-bottom: calc(16px + env(safe-area-inset-bottom, 0px));
    }
}

/* ── 21AB. IMPROVED MOBILE FORMS ─────────────────────────────────────────── */
@media (max-width: 575px) {
    .form-input {
        font-size: 16px; /* prevents iOS zoom on focus */
        padding: 11px 14px;
    }
    select.form-input {
        font-size: 16px;
    }
    .coupon-input input {
        font-size: 16px;
    }
    .newsletter-menu-search-input,
    .search-input {
        font-size: 16px;
    }
}

/* ── 21AC. IMPROVED BUTTONS ON MOBILE ───────────────────────────────────── */
@media (max-width: 575px) {
    .btn-primary-custom {
        padding: 11px 22px;
        font-size: 14px;
    }
    .btn-primary-custom.btn-large {
        padding: 13px 28px;
        font-size: 15px;
    }
    .btn-outline-custom {
        padding: 9px 20px;
        font-size: 14px;
    }
    .hero-btn-primary,
    .hero-btn-outline {
        padding: 11px 20px;
        font-size: 0.86rem;
    }
    .banner-btn {
        padding: 12px 24px;
        font-size: 0.875rem;
    }
}

/* ── 21AD. MOBILE FILTER CLOSE BUTTON ───────────────────────────────────── */
.filter-close-btn {
    display: none;
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1px solid var(--border);
    background: #fff;
    color: var(--text-light);
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 14px;
}
@media (max-width: 991px) {
    .filter-card {
        position: relative;
    }
    .filter-close-btn {
        display: flex;
    }
}

/* ── 21AE. SMOOTH IMAGE LOADING ─────────────────────────────────────────── */
img[loading="lazy"] {
    background: var(--bg);
}
.product-card-media img,
.product-image-wrap img,
.cat-card img,
.gallery-main img {
    background-color: #f1f5f9;
}

/* ── 21AF. MOBILE PRODUCT DETAIL GALLERY ────────────────────────────────── */
@media (max-width: 575px) {
    .gallery-main {
        border-radius: var(--radius-sm);
    }
    .gallery-thumbs {
        scroll-snap-type: x mandatory;
        scrollbar-width: none;
    }
    .gallery-thumbs::-webkit-scrollbar {
        display: none;
    }
    .thumb-img {
        scroll-snap-align: start;
    }
}

/* ── 21AG. ACCESSIBILITY & FOCUS STATES ─────────────────────────────────── */
:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}
button:focus-visible,
a:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* ── 21AH. PRINT STYLES ──────────────────────────────────────────────────── */
@media print {
    .site-header,
    .mobile-bottom-nav,
    .mobile-sticky-cta,
    .back-to-top,
    #back-to-top,
    .trust-bar,
    .site-footer {
        display: none !important;
    }
    body {
        padding-bottom: 0 !important;
    }
}

/* ── 21AI. LANDSCAPE PHONE FIX ───────────────────────────────────────────── */
@media (max-width: 767px) and (orientation: landscape) {
    .hero-section {
        height: 100vh;
        min-height: 350px;
    }
    .hero-title {
        font-size: 2rem;
    }
    .hero-desc {
        display: none;
    }
    .mobile-bottom-nav {
        display: none;
    }
    body {
        padding-bottom: 0;
    }
}

/* ── 21AJ. WIDE SCREEN OPTIMIZATIONS ─────────────────────────────────────── */
@media (min-width: 1400px) {
    .hero-title {
        font-size: 5.5rem;
    }
    .container {
        max-width: 1320px;
    }
    .cat-grid {
        grid-template-columns: repeat(5, 1fr);
    }
    .cat-card-lg {
        grid-column: span 1;
        grid-row: span 2;
        height: 540px;
    }
    .cat-card {
        height: 260px;
    }
}

/* End of Comprehensive Responsive Section */

/* ==========================================================================
   SHARED PAGE COMPONENTS
   Styles common across cart, checkout, product pages — declared once here.
   ========================================================================== */

/* ─── Breadcrumb ─────────────────────────────────────────────────────────── */
.breadcrumb-custom {
    display: flex;
    align-items: center;
    gap: 6px;
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 0.875rem;
    color: #64748b;
}
.breadcrumb-custom a {
    color: #64748b;
    text-decoration: none;
    transition: color 0.2s;
}
.breadcrumb-custom a:hover {
    color: var(--primary);
}
.breadcrumb-custom .sep::before {
    content: "/";
    color: #cbd5e1;
}

/* ─── Checkout / Cart Steps ──────────────────────────────────────────────── */
.cart-steps {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin-bottom: 48px;
}
.cart-step {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-light);
}
.cart-step.active {
    color: var(--primary);
}
.cart-step.done {
    color: var(--accent);
}

.step-num {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 2px solid currentColor;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.85rem;
    transition: var(--transition);
}
.cart-step.active .step-num {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}
.cart-step.done .step-num {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}
.step-line {
    width: 80px;
    height: 2px;
    background: var(--border);
    margin: 0 8px;
}
@media (max-width: 576px) {
    .step-line {
        width: 32px;
    }
    .cart-step span:last-child {
        display: none;
    }
}

/* ─── Shared Summary Row / Total ─────────────────────────────────────────── */
.summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
}
.summary-divider {
    border: none;
    border-top: 1px solid var(--border);
    margin: 8px 0;
}
.summary-total {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--dark);
}

/* ─── Cart page ──────────────────────────────────────────────────────────── */
.cart-section {
    padding: 60px 0 80px;
}

.cart-card {
    background: #fff;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
}
.cart-card-header {
    padding: 20px 28px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.cart-item-row {
    display: grid;
    grid-template-columns: 100px 1fr auto auto auto;
    gap: 20px;
    align-items: center;
    padding: 20px 28px;
    border-bottom: 1px solid var(--border);
    transition: var(--transition);
}
.cart-item-row:hover {
    background: var(--bg);
}
.cart-item-row:last-child {
    border-bottom: none;
}
.cart-item-img {
    width: 100px;
    height: 100px;
    border-radius: 12px;
    object-fit: cover;
}
.cart-item-name {
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--dark);
    margin-bottom: 6px;
}
.cart-item-meta {
    font-size: 0.8rem;
    color: var(--text-light);
}
.cart-item-price {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--dark);
}
.cart-qty-box {
    display: flex;
    align-items: center;
    border: 1px solid var(--border);
    border-radius: 8px;
    overflow: hidden;
    width: fit-content;
}
.cart-qty-btn {
    width: 34px;
    height: 34px;
    border: none;
    background: #f8f8f8;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    transition: var(--transition);
}
.cart-qty-btn:hover {
    background: var(--primary);
    color: #fff;
}
.cart-qty-input {
    width: 44px;
    text-align: center;
    border: none;
    outline: none;
    font-size: 0.9rem;
    font-weight: 600;
}
.cart-remove {
    background: none;
    border: none;
    color: var(--text-light);
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: var(--transition);
}
.cart-remove:hover {
    color: var(--secondary);
    background: #fff5f5;
}
.cart-subtotal {
    font-family: var(--font-heading);
    font-size: 1.05rem;
    font-weight: 700;
}
@media (max-width: 768px) {
    .cart-item-row {
        grid-template-columns: 80px 1fr;
        grid-template-rows: auto auto;
        gap: 12px;
    }
    .cart-item-row > :nth-child(3),
    .cart-item-row > :nth-child(4),
    .cart-item-row > :nth-child(5) {
        grid-column: 2;
    }
}
.summary-card {
    background: #fff;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 28px;
    position: sticky;
    top: 90px;
}
.coupon-input {
    display: flex;
    border: 2px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
}
.coupon-input input {
    flex: 1;
    border: none;
    outline: none;
    padding: 10px 16px;
    font-size: 0.875rem;
}
.coupon-apply {
    background: var(--primary);
    color: #fff;
    border: none;
    padding: 10px 20px;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}
.coupon-apply:hover {
    background: var(--primary-dark);
}
.discount-badge {
    background: #f0fdf4;
    color: #16a34a;
    border: 1px solid #bbf7d0;
    border-radius: 8px;
    padding: 8px 14px;
    font-size: 0.82rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.btn-checkout {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    background: var(--gradient-1);
    color: #fff;
    font-weight: 700;
    font-size: 1rem;
    padding: 16px;
    border-radius: 14px;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    box-shadow: 0 8px 24px rgba(108, 99, 255, 0.3);
}
.btn-checkout:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 36px rgba(108, 99, 255, 0.4);
    color: #fff;
}
.trust-badge {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.75rem;
    color: var(--text-light);
}

/* ─── Checkout page ──────────────────────────────────────────────────────── */
.checkout-section {
    padding: 60px 0 80px;
}

.checkout-card {
    background: #fff;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 32px;
    margin-bottom: 24px;
}
.checkout-card-title {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.checkout-card-title i {
    color: var(--primary);
}

.form-group-label {
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-light);
    margin-bottom: 8px;
    display: block;
}
.form-input {
    width: 100%;
    padding: 12px 16px;
    border: 1.5px solid var(--border);
    border-radius: 10px;
    font-size: 0.9rem;
    outline: none;
    transition: var(--transition);
    background: #fff;
}
.form-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(108, 99, 255, 0.1);
}
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}
@media (max-width: 576px) {
    .form-row {
        grid-template-columns: 1fr;
    }
}
.payment-tabs {
    display: flex;
    gap: 12px;
    margin-bottom: 28px;
    flex-wrap: wrap;
}
.payment-tab {
    flex: 1;
    min-width: 140px;
    padding: 14px;
    border: 2px solid var(--border);
    border-radius: 12px;
    background: #fff;
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text);
}
.payment-tab.active {
    border-color: var(--primary);
    background: rgba(108, 99, 255, 0.04);
    color: var(--primary);
}
.payment-tab i {
    font-size: 1.2rem;
}
.stripe-element-wrapper {
    border: 1.5px solid var(--border);
    border-radius: 10px;
    padding: 14px 16px;
    transition: var(--transition);
}
.stripe-element-wrapper.focused {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(108, 99, 255, 0.1);
}

/* ==========================================================================
   SECTION 22: REMAINING PAGE RESPONSIVE IMPROVEMENTS
   Contact, About, Track Order, Size Guide, Legal, Customer Portal, Sitemap
   ========================================================================== */

/* ── 22A. CONTACT PAGE ───────────────────────────────────────────────────── */
@media (max-width: 575px) {
    .contact-form {
        padding: 20px 16px;
    }
    .contact-info {
        padding: 20px 16px;
    }
    .contact-form button[type="submit"] {
        width: 100%;
    }
}

/* ── 22B. ABOUT PAGE ─────────────────────────────────────────────────────── */
.value-card {
    transition: transform 0.3s ease;
}
@media (max-width: 575px) {
    .value-card {
        padding: 20px 16px !important;
    }
    .value-card .value-icon i {
        font-size: 48px !important;
    }
}

/* ── 22C. ABOUT CTA — STACK BUTTONS ON MOBILE ───────────────────────────── */
@media (max-width: 575px) {
    section.cta .btn.me-3,
    section.cta .btn-lg {
        display: block;
        width: 100%;
        margin-right: 0 !important;
        margin-bottom: 12px;
    }
    section.cta .btn-lg:last-child {
        margin-bottom: 0;
    }
}

/* ── 22D. PAGE HEADER SECTIONS (About/Contact/Track/Size Guide) ──────────── */
.page-header {
    padding-top: 3rem;
    padding-bottom: 3rem;
}
@media (max-width: 767px) {
    .page-header {
        padding-top: 2rem;
        padding-bottom: 2rem;
    }
    .page-header h1 {
        font-size: 1.75rem;
    }
}
@media (max-width: 575px) {
    .page-header {
        padding-top: 1.5rem;
        padding-bottom: 1.5rem;
    }
    .page-header h1 {
        font-size: 1.5rem;
    }
    .page-header .lead {
        font-size: 0.95rem;
    }
}

/* ── 22E. TRACK ORDER PAGE ───────────────────────────────────────────────── */
@media (max-width: 575px) {
    .track-order-section .card-body.p-5 {
        padding: 24px 20px !important;
    }
    .order-timeline {
        padding-left: 36px;
    }
}

/* ── 22F. SIZE GUIDE PAGE ────────────────────────────────────────────────── */
@media (max-width: 575px) {
    #sizeTabs {
        gap: 6px !important;
    }
    #sizeTabs .nav-link {
        font-size: 0.8rem;
        padding: 7px 12px;
    }
    #sizeTabs .nav-link i {
        display: none;
    }
}

/* ── 22G. LEGAL PAGES (Privacy, Terms, Cookie Policy) ───────────────────── */
@media (max-width: 575px) {
    .legal-body {
        font-size: 0.9rem;
    }
    .legal-intro {
        padding: 16px 18px;
    }
    .legal-section h2 {
        font-size: 1.2rem;
    }
    .legal-section h3 {
        font-size: 1rem;
    }
    .legal-contact-box {
        padding: 16px !important;
    }
}

/* ── 22H. CUSTOMER AUTH PAGES ────────────────────────────────────────────── */
@media (max-width: 575px) {
    .auth-right {
        padding: 40px 20px !important;
    }
    .auth-form {
        max-width: 100% !important;
    }
    .auth-logo {
        font-size: 1.5rem !important;
        margin-bottom: 24px !important;
    }
}

/* ── 22I. CUSTOMER DASHBOARD ─────────────────────────────────────────────── */
@media (max-width: 575px) {
    .cp-main {
        padding: 12px !important;
    }
    .cp-card {
        padding: 16px !important;
        border-radius: 12px !important;
    }
    .page-header h1 {
        font-size: 1.4rem !important;
    }
}

/* ── 22J. CUSTOMER ORDERS TABLE ─────────────────────────────────────────── */
@media (max-width: 575px) {
    .order-row {
        grid-template-columns: 1fr !important;
        gap: 10px !important;
    }
    .filter-bar {
        gap: 6px;
    }
    .filter-btn {
        padding: 5px 12px;
        font-size: 0.75rem;
    }
}

/* ── 22K. CUSTOMER WISHLIST GRID ─────────────────────────────────────────── */
@media (max-width: 400px) {
    .wl-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)) !important;
        gap: 12px !important;
    }
}

/* ── 22L. SITEMAP PAGE ───────────────────────────────────────────────────── */
@media (max-width: 575px) {
    .sitemap-group {
        margin-bottom: 24px;
    }
}

/* ── 22M. NEWSLETTER SECTION ─────────────────────────────────────────────── */
@media (max-width: 767px) {
    .newsletter-form {
        flex-direction: column !important;
        gap: 12px;
    }
    .newsletter-form input,
    .newsletter-form button {
        width: 100% !important;
        border-radius: 10px !important;
    }
}

/* ── 22N. HOME PARTIALS ─────────────────────────────────────────────────── */
/* Fashion banner stacking */
@media (max-width: 767px) {
    .fashion-banner .row {
        gap: 16px;
    }
}

/* ── 22O. PRODUCT CARDS — MIN HEIGHT TEXT AREA ───────────────────────────── */
@media (max-width: 575px) {
    .product-card-title {
        font-size: 0.85rem;
    }
    .product-card-category {
        font-size: 0.72rem;
    }
    .price-current {
        font-size: 1rem;
    }
}

/* ── 22P. MOBILE SWIPER OVERFLOW FIX ─────────────────────────────────────── */
.swiper-container,
.swiper {
    overflow: hidden;
}
@media (max-width: 575px) {
    .feat-swiper,
    .related-swiper {
        margin: 0 -4px;
        padding: 0 4px;
    }
}

/* ── 22Q. IMPROVED SCROLL BEHAVIOUR ──────────────────────────────────────── */
@media (max-width: 991px) {
    html {
        scroll-behavior: smooth;
    }
}

/* ── 22R. CONTACT FAQ ACCORDION ──────────────────────────────────────────── */
@media (max-width: 575px) {
    .faq-section .accordion-button {
        font-size: 0.9rem;
        padding: 12px 16px;
    }
    .faq-section .accordion-body {
        font-size: 0.875rem;
        padding: 12px 16px;
    }
}

/* ── 22S. MAP SECTION ────────────────────────────────────────────────────── */
@media (max-width: 575px) {
    .map-container #map {
        height: 280px !important;
    }
}

/* ── 22T. BREADCRUMB OVERFLOW ────────────────────────────────────────────── */
.breadcrumb {
    flex-wrap: wrap;
}
@media (max-width: 575px) {
    .breadcrumb {
        font-size: 0.8rem;
    }
}

/* ── 22U. GLOBAL SECTION PADDING ─────────────────────────────────────────── */
@media (max-width: 575px) {
    section.py-5 {
        padding-top: 2.5rem !important;
        padding-bottom: 2.5rem !important;
    }
    section.py-5.pb-4 {
        padding-bottom: 2rem !important;
    }
}

/* ── 22V. CARD BODY PADDING ──────────────────────────────────────────────── */
@media (max-width: 575px) {
    .card-body.p-4 {
        padding: 20px !important;
    }
    .card-body.p-5 {
        padding: 24px 20px !important;
    }
}

/* End of Section 22 */
.stripe-element-wrapper.focused {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(108, 99, 255, 0.1);
}
#cardErrors {
    color: #e53e3e;
    font-size: 0.82rem;
    margin-top: 8px;
    display: none;
}
.order-summary-card {
    background: #fff;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 28px;
    position: sticky;
    top: 90px;
}
.order-item-row {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}
.order-item-row:last-child {
    border-bottom: none;
}
.order-item-img {
    width: 64px;
    height: 64px;
    border-radius: 10px;
    object-fit: cover;
    flex-shrink: 0;
}
.order-item-qty {
    position: absolute;
    top: -6px;
    right: -6px;
    background: var(--primary);
    color: #fff;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 0.7rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}
.btn-place-order {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    background: var(--gradient-1);
    color: #fff;
    font-weight: 700;
    font-size: 1.05rem;
    padding: 17px;
    border-radius: 14px;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 8px 24px rgba(108, 99, 255, 0.3);
}
.btn-place-order:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 36px rgba(108, 99, 255, 0.4);
}
.btn-place-order:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}
.secure-note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-size: 0.78rem;
    color: var(--text-light);
    margin-top: 12px;
}
