/* ============================================================
   MALHAFTI DESIGN — Store CSS v5
   Palette: Crème #FDFBF7 | Anthracite #1A1A1A | Or #C2915B
   ============================================================ */

/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --bg:           #FDFBF7;
    --surface:      #F5F0E8;
    --dark:         #1A1A1A;
    --text:         #2D2D2D;
    --muted:        #8A7D6E;
    --accent:       #C2915B;
    --gold:         #C2915B;
    --terracotta:   #B5713A;
    --border-col:   #E8E0D4;
    --white:        #FFFFFF;
    --shadow-sm:    0 2px 8px rgba(0,0,0,0.06);
    --shadow-md:    0 8px 32px rgba(0,0,0,0.10);
    --shadow-lg:    0 20px 60px rgba(0,0,0,0.15);
    --font-body:    'Inter', 'Jost', sans-serif;
    --font-title:   'Cormorant Garamond', serif;
    --transition:   0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --nav-h:        80px;
}

/* Dark Mode Variables */
body.dark-mode {
    --bg:           #121212;
    --surface:      #1E1E1E;
    --dark:         #FDFBF7;
    --text:         #E0E0E0;
    --muted:        #A0A0A0;
    --border-col:   #333333;
    --white:        #1A1A1A;
}

body.dark-mode .navbar {
    background: rgba(18, 18, 18, 0.92);
    border-bottom-color: #333;
}

body.dark-mode .nav-icon:hover { background: #333; }
body.dark-mode .product-card { background: #1E1E1E; border-color: #333; }
body.dark-mode .modal-content { background: #1E1E1E; color: #E0E0E0; }
body.dark-mode .cart-sidebar { background: #121212; border-color: #333; }
body.dark-mode .hero-premium { background: #121212; }

html { scroll-behavior: smooth; font-size: 16px; }

body {
    font-family: var(--font-body);
    background: var(--bg);
    color: var(--text);
    line-height: 1.7;
    overflow-x: hidden;
}

img { display: block; max-width: 100%; }
a { text-decoration: none; color: inherit; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
ul { list-style: none; }

/* ===== LABELS ===== */
.top-label {
    display: block;
    font-family: var(--font-body);
    font-size: 0.72rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--muted);
    margin-bottom: 1rem;
}
.accent-dot { color: var(--accent); }

/* ============================================================
   NAVBAR
   ============================================================ */
.navbar {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: var(--nav-h);
    z-index: 1000;
    background: rgba(253, 251, 247, 0.92);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-col);
    transition: box-shadow var(--transition);
}
.navbar.scrolled { box-shadow: var(--shadow-md); }

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 5%;
    height: 100%;
    display: flex;
    align-items: center;
    gap: 2rem;
}

.brand-logo {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}
.brand-logo img { height: 55px; object-fit: contain; }
.brand-text-fallback {
    font-family: var(--font-title);
    font-size: 1.4rem;
    font-weight: 600;
    letter-spacing: 3px;
    color: var(--dark);
}

.nav-links {
    display: flex;
    gap: 2rem;
    flex: 1;
    justify-content: center;
}
.nav-link {
    font-size: 0.82rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--muted);
    transition: color var(--transition);
    position: relative;
}
.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0; right: 0;
    height: 1px;
    background: var(--accent);
    transform: scaleX(0);
    transition: transform var(--transition);
}
.nav-link:hover, .nav-link.active {
    color: var(--dark);
}
.nav-link:hover::after, .nav-link.active::after { transform: scaleX(1); }

.nav-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
}

.nav-icon {
    width: 42px; height: 42px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.3rem;
    color: var(--dark);
    transition: background var(--transition), color var(--transition);
    position: relative;
}
.nav-icon:hover { background: var(--surface); color: var(--accent); }

.cart-badge {
    position: absolute;
    top: 4px; right: 4px;
    width: 18px; height: 18px;
    border-radius: 50%;
    background: var(--accent);
    color: white;
    font-size: 0.65rem;
    font-weight: 700;
    display: flex; align-items: center; justify-content: center;
    transition: transform 0.2s;
}
.cart-badge.bump { transform: scale(1.5); }

.nav-user-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.82rem;
    color: var(--muted);
}
.nav-logout-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: inherit;
    cursor: pointer;
    padding: 0.4rem 0.6rem;
    border-radius: 4px;
    transition: all var(--transition);
}
.nav-logout-link:hover {
    color: var(--dark);
    background: rgba(0,0,0,0.04);
}
.nav-logout-link * {
    pointer-events: none;
}

/* Hamburger */
.hamburger-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    padding: 6px;
}
.hamburger-btn span {
    width: 22px; height: 2px;
    background: var(--dark);
    transition: var(--transition);
    border-radius: 2px;
}
.hamburger-btn.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger-btn.open span:nth-child(2) { opacity: 0; }
.hamburger-btn.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile Nav */
.mobile-nav {
    display: none;
    flex-direction: column;
    background: var(--bg);
    border-top: 1px solid var(--border-col);
    padding: 1rem 5%;
}
.mobile-nav.open { display: flex; }
.mobile-nav-link {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border-col);
    font-size: 0.9rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: var(--text);
    transition: color var(--transition);
}
.mobile-nav-link:hover { color: var(--accent); }

/* ============================================================
   HERO
   ============================================================ */
.hero-premium {
    min-height: 100dvh;
    padding-top: var(--nav-h);
    display: grid;
    grid-template-columns: 1fr 1fr;
    overflow: hidden;
}

.hero-content-luxe {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 6rem 5% 6rem 8%;
}

.hero-content-luxe h1 {
    font-family: var(--font-title);
    font-size: clamp(3rem, 5vw, 5rem);
    font-weight: 700;
    line-height: 1.1;
    color: var(--dark);
    margin-bottom: 1.5rem;
}

.hero-content-luxe p {
    font-family: 'Cormorant Garamond', serif;
    font-style: italic;
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--muted);
    max-width: 440px;
    margin-bottom: 2.5rem;
    line-height: 1.5;
}

.hero-btns {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.hero-image-side {
    position: relative;
    background: var(--dark);
    overflow: hidden;
}
.hero-side-label {
    position: absolute;
    top: 50%;
    right: -30px;
    transform: translateY(-50%) rotate(90deg);
    font-size: 0.65rem;
    letter-spacing: 4px;
    text-transform: uppercase;
    color: rgba(255,255,255,0.4);
    z-index: 2;
}
.hero-img-container {
    width: 100%; height: 100%;
    overflow: hidden;
}
.hero-img-container img {
    width: 100%; 
    height: 100%;
    object-fit: cover;
    opacity: 0;
    animation: fadeInHero 1.5s ease forwards;
    transition: transform 8s ease;
}
@keyframes fadeInHero {
    from { opacity: 0; transform: scale(1.05); }
    to { opacity: 1; transform: scale(1); }
}
.hero-img-container:hover img { transform: scale(1.05); }
.hero-img-placeholder {
    width: 100%; height: 100%;
    background: linear-gradient(135deg, #2a2a2a 0%, #1a1a1a 50%, #3a2f1f 100%);
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn-luxe {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.9rem 2rem;
    background: var(--dark);
    color: var(--bg);
    font-size: 0.8rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    transition: background var(--transition), transform var(--transition);
}
.btn-luxe:hover {
    background: var(--accent);
    transform: translateY(-2px);
}

.btn-outline-hero {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.9rem 2rem;
    border: 1px solid var(--dark);
    color: var(--dark);
    font-size: 0.8rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    transition: all var(--transition);
}
.btn-outline-hero:hover {
    background: var(--dark);
    color: var(--bg);
    transform: translateY(-2px);
}

/* ============================================================
   TICKER
   ============================================================ */
.ticker-bar {
    background: var(--dark);
    padding: 0.85rem 0;
    overflow: hidden;
}
.ticker-content {
    display: flex;
    animation: ticker-scroll 25s linear infinite;
    white-space: nowrap;
    width: max-content;
}
.ticker-item {
    padding: 0 3rem;
    font-size: 0.72rem;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    color: rgba(255,255,255,0.65);
}
.ticker-item span { color: var(--accent); margin-right: 0.5rem; }
@keyframes ticker-scroll {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
}

/* ============================================================
   COLLECTION SECTION
   ============================================================ */
.collection-section, .catalogue-section {
    padding: 7rem 5%;
    max-width: 1500px;
    margin: 0 auto;
}
.section-header {
    text-align: center;
    margin-bottom: 3.5rem;
}
.section-header h2 {
    font-family: var(--font-title);
    font-size: clamp(2rem, 4vw, 3.5rem);
    font-weight: 600;
    color: var(--dark);
}
.section-header h2 em { font-style: italic; color: var(--accent); }

/* Category tabs */
.cat-tabs {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}
.cat-tab {
    padding: 0.5rem 1.4rem;
    border: 1px solid var(--border-col);
    font-size: 0.78rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--muted);
    transition: all var(--transition);
    border-radius: 2px;
}
.cat-tab:hover, .cat-tab.active {
    background: var(--dark);
    color: var(--bg);
    border-color: var(--dark);
}

/* Product Grid */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
}
.catalogue-grid {
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}

/* Product Card */
.product-card {
    background: var(--white);
    border: 1px solid var(--border-col);
    transition: transform var(--transition), box-shadow var(--transition);
    cursor: pointer;
}
.product-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
}

.product-image-wrapper {
    position: relative;
    aspect-ratio: 3/4;
    overflow: hidden;
    background: var(--surface);
}
.product-img {
    width: 100%; height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.4,0,0.2,1);
}
.product-card:hover .product-img { transform: scale(1.06); }

.product-img-placeholder {
    width: 100%; height: 100%;
    display: flex; align-items: center; justify-content: center;
    font-size: 4rem;
    color: var(--border-col);
    background: var(--surface);
}

.product-badge {
    position: absolute;
    top: 1rem; left: 1rem;
    padding: 0.25rem 0.75rem;
    background: rgba(253,251,247,0.9);
    font-size: 0.65rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--muted);
    z-index: 2;
}

.out-of-stock-badge {
    position: absolute;
    top: 1rem; right: 1rem;
    padding: 0.25rem 0.75rem;
    background: rgba(26,26,26,0.85);
    color: white;
    font-size: 0.65rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    z-index: 2;
}

.play-btn {
    position: absolute;
    bottom: 1rem; left: 1rem;
    width: 38px; height: 38px;
    border-radius: 50%;
    background: rgba(253,251,247,0.9);
    display: flex; align-items: center; justify-content: center;
    font-size: 1.1rem;
    color: var(--dark);
    z-index: 3;
    transition: background var(--transition);
}
.play-btn:hover { background: var(--accent); color: white; }

.card-hover-overlay {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    padding: 1rem;
    background: linear-gradient(to top, rgba(26,26,26,0.85) 0%, transparent 100%);
    transform: translateY(100%);
    transition: transform var(--transition);
    display: flex;
}
.product-card:hover .card-hover-overlay { transform: translateY(0); }

.btn-add-cart {
    width: 100%;
    padding: 0.7rem;
    background: var(--accent);
    color: white;
    font-size: 0.78rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    transition: background var(--transition);
    display: flex; align-items: center; justify-content: center; gap: 0.5rem;
}
.btn-add-cart:hover { background: var(--terracotta); }
.btn-add-cart:disabled {
    background: rgba(255,255,255,0.3);
    cursor: not-allowed;
}

.product-details {
    padding: 1.2rem;
    border-top: 1px solid var(--border-col);
}
.product-name {
    font-family: var(--font-title);
    font-size: 1.15rem;
    font-weight: 400;
    color: var(--dark);
    margin-bottom: 0.25rem;
}
.product-price {
    font-size: 0.95rem;
    color: var(--accent);
    font-weight: 600;
    letter-spacing: 0.5px;
}

/* See All Button */
.see-all-container {
    text-align: center;
    margin-top: 4rem;
}
.btn-see-all {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 3rem;
    border: 1px solid var(--dark);
    font-size: 0.82rem;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    color: var(--dark);
    transition: all var(--transition);
}
.btn-see-all:hover {
    background: var(--dark);
    color: var(--bg);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* ============================================================
   PAGE HEADER (Collections page)
   ============================================================ */
.page-header {
    padding: calc(var(--nav-h) + 5rem) 5% 3rem;
    max-width: 1500px;
    margin: 0 auto;
}
.page-header h1 {
    font-family: var(--font-title);
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 300;
    color: var(--dark);
    margin-bottom: 0.5rem;
}
.page-header h1 em { font-style: italic; color: var(--accent); }
.page-header p { color: var(--muted); font-size: 0.9rem; }

/* Sort */
.catalogue-filters {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.catalogue-search {
    position: relative;
    flex: 1;
    min-width: 250px;
    max-width: 400px;
}

.catalogue-search i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--muted);
    font-size: 1.1rem;
    pointer-events: none;
}

.catalogue-search input {
    width: 100%;
    padding: 0.7rem 1rem 0.7rem 2.8rem;
    border: 1px solid var(--border-col);
    background: var(--bg);
    border-radius: 0;
    font-size: 0.85rem;
    color: var(--dark);
    transition: all var(--transition);
}

.catalogue-search input:focus {
    border-color: var(--dark);
    outline: none;
    box-shadow: 0 4px 12px rgba(0,0,0,0.03);
}

.catalogue-search input::placeholder {
    color: var(--muted);
    opacity: 0.6;
}

.catalogue-filters .cat-tabs { margin-bottom: 0; justify-content: flex-start; }
.sort-select-wrap select {
    padding: 0.5rem 1rem;
    border: 1px solid var(--border-col);
    background: var(--bg);
    font-size: 0.82rem;
    color: var(--muted);
    outline: none;
    cursor: pointer;
}

/* Pagination */
.pagination-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 4rem;
    flex-wrap: wrap;
}
.page-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.4rem;
    border: 1px solid var(--border-col);
    font-size: 0.82rem;
    color: var(--muted);
    transition: all var(--transition);
}
.page-btn:hover:not(:disabled) {
    border-color: var(--dark);
    color: var(--dark);
}
.page-btn:disabled { opacity: 0.35; cursor: not-allowed; }
#page-indicators {
    display: flex;
    gap: 0.5rem;
}
.page-dot {
    width: 32px; height: 32px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 0.82rem;
    border: 1px solid var(--border-col);
    color: var(--muted);
    cursor: pointer;
    transition: all var(--transition);
}
.page-dot.active {
    background: var(--dark);
    color: var(--bg);
    border-color: var(--dark);
}

/* Grid Loading */
.grid-loading {
    grid-column: 1/-1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    padding: 5rem;
    color: var(--muted);
}
.spinner {
    width: 40px; height: 40px;
    border: 2px solid var(--border-col);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ============================================================
   CART SIDEBAR
   ============================================================ */
.cart-sidebar {
    position: fixed;
    top: 0; right: 0;
    width: min(420px, 100dvw);
    height: 100dvh;
    background: var(--bg);
    z-index: 2000;
    display: flex;
    flex-direction: column;
    box-shadow: -10px 0 50px rgba(0,0,0,0.15);
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.4,0,0.2,1);
    border-left: 1px solid var(--border-col);
}
.cart-sidebar.open { transform: translateX(0); }

.cart-overlay {
    position: fixed;
    inset: 0;
    background: rgba(26,26,26,0.5);
    backdrop-filter: blur(4px);
    z-index: 1999;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition);
}
.cart-overlay.open { opacity: 1; pointer-events: all; }

.cart-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem 1.75rem;
    border-bottom: 1px solid var(--border-col);
}
.cart-header h2 {
    font-family: var(--font-title);
    font-size: 1.4rem;
    font-weight: 400;
    display: flex; align-items: center; gap: 0.5rem;
    color: var(--dark);
}
.close-cart {
    width: 38px; height: 38px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.3rem;
    color: var(--muted);
    transition: background var(--transition);
}
.close-cart:hover { background: var(--surface); color: var(--dark); }

.cart-items {
    flex: 1;
    overflow-y: auto;
    padding: 1rem 1.75rem;
}
.cart-items::-webkit-scrollbar { width: 4px; }
.cart-items::-webkit-scrollbar-thumb { background: var(--border-col); border-radius: 4px; }

.empty-cart-msg {
    text-align: center;
    padding: 3rem 0;
    color: var(--muted);
    font-size: 0.9rem;
}

/* Cart Item */
.cart-item-card {
    display: flex;
    gap: 1rem;
    padding: 1rem 0;
    border-bottom: 1px solid var(--border-col);
}
.cart-item-img {
    width: 70px; height: 90px;
    object-fit: cover;
    background: var(--surface);
    flex-shrink: 0;
}
.cart-item-info { flex: 1; }
.cart-item-name {
    font-family: var(--font-title);
    font-size: 1rem;
    font-weight: 400;
    margin-bottom: 0.25rem;
}
.cart-item-price { font-size: 0.85rem; color: var(--accent); font-weight: 600; }
.cart-item-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.5rem;
}
.qty-btn {
    width: 28px; height: 28px;
    border: 1px solid var(--border-col);
    display: flex; align-items: center; justify-content: center;
    font-size: 0.9rem;
    color: var(--dark);
    transition: all var(--transition);
}
.qty-btn:hover { background: var(--dark); color: var(--bg); border-color: var(--dark); }
.qty-display {
    font-size: 0.85rem;
    font-weight: 600;
    min-width: 24px;
    text-align: center;
}
.cart-item-remove {
    font-size: 1rem;
    color: var(--muted);
    margin-left: auto;
    transition: color var(--transition);
}
.cart-item-remove:hover { color: #e74c3c; }

.cart-footer {
    padding: 1.25rem 1.75rem;
    border-top: 1px solid var(--border-col);
    background: var(--surface);
}
.cart-total-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}
.cart-total-row span:first-child { font-size: 0.82rem; color: var(--muted); text-transform: uppercase; letter-spacing: 1px; }
.cart-total-row span:last-child { font-family: var(--font-title); font-size: 1.4rem; color: var(--dark); }
.cart-shipping-note {
    font-size: 0.78rem;
    color: var(--muted);
    display: flex; align-items: center; gap: 0.4rem;
    margin-bottom: 1rem;
}

.btn-checkout-main {
    width: 100%;
    padding: 1rem;
    background: var(--dark);
    color: var(--bg);
    font-size: 0.82rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    display: flex; align-items: center; justify-content: center; gap: 0.75rem;
    transition: background var(--transition);
}
.btn-checkout-main:hover:not(:disabled) { background: var(--accent); }
.btn-checkout-main:disabled { opacity: 0.5; cursor: not-allowed; }

/* ============================================================
   MODALS
   ============================================================ */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(26,26,26,0.65);
    backdrop-filter: blur(6px);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    overflow-y: auto;
}

.modal-close-btn {
    position: absolute;
    top: 1rem; right: 1rem;
    width: 36px; height: 36px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.2rem;
    color: var(--muted);
    transition: all var(--transition);
    background: var(--surface);
}
.modal-close-btn:hover { background: var(--dark); color: var(--bg); }

/* Checkout Modal */
.checkout-modal-box {
    background: var(--bg);
    width: min(640px, 100%);
    position: relative;
    padding: 3rem;
    border: 1px solid var(--border-col);
    box-shadow: var(--shadow-lg);
    max-height: 90dvh;
    overflow-y: auto;
}
.checkout-modal-header {
    text-align: center;
    margin-bottom: 2.5rem;
}
.checkout-modal-header h2 {
    font-family: var(--font-title);
    font-size: 2rem;
    font-weight: 300;
    color: var(--dark);
}
.checkout-modal-header h2 em { font-style: italic; color: var(--accent); }

.checkout-form-inner {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}
.chk-field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
}
.chk-field {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}
.chk-field label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--muted);
}
.chk-field input, .chk-field textarea, .chk-field select {
    padding: 0.8rem 1rem;
    border: 1px solid var(--border-col);
    background: var(--bg);
    font-family: inherit;
    font-size: 0.9rem;
    color: var(--text);
    transition: border-color var(--transition);
    resize: none;
    outline: none;
}
.chk-field input:focus, .chk-field textarea:focus {
    border-color: var(--accent);
}

.chk-order-summary {
    background: var(--surface);
    padding: 1rem;
    border: 1px solid var(--border-col);
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.chk-order-line {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    color: var(--text);
}
.chk-total-line {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-top: 1px solid var(--border-col);
}
.chk-total-line span:first-child { font-size: 0.82rem; color: var(--muted); text-transform: uppercase; letter-spacing: 1px; }
.chk-total-line span:last-child { font-family: var(--font-title); font-size: 1.6rem; color: var(--dark); }

.btn-validate-order {
    padding: 1.1rem;
    background: var(--accent);
    color: white;
    font-size: 0.82rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    display: flex; align-items: center; justify-content: center; gap: 0.75rem;
    transition: background var(--transition), transform var(--transition);
    margin-top: 0.5rem;
}
.btn-validate-order:hover { background: var(--terracotta); transform: translateY(-2px); }

/* Order Success */
.order-success-box {
    text-align: center;
    padding: 2rem;
}
.order-success-box i {
    font-size: 4rem;
    color: #27ae60;
    display: block;
    margin-bottom: 1rem;
}
.order-success-box h3 {
    font-family: var(--font-title);
    font-size: 2rem;
    font-weight: 300;
    margin-bottom: 0.75rem;
}
.order-success-box p {
    color: var(--muted);
    margin-bottom: 2rem;
}

/* Video Modal */
.video-modal-box {
    background: #000;
    width: min(800px, 95dvw);
    position: relative;
    border-radius: 12px;
    overflow: hidden;
}

/* Auth Modal */
.auth-modal-box {
    background: var(--bg);
    width: min(440px, 100%);
    padding: 3rem;
    position: relative;
    border: 1px solid var(--border-col);
    box-shadow: var(--shadow-lg);
}
.auth-tabs-header {
    display: flex;
    gap: 2rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--border-col);
    padding-bottom: 1rem;
}
.auth-tab {
    font-size: 0.82rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--muted);
    transition: color var(--transition);
    padding-bottom: 0.5rem;
    border-bottom: 2px solid transparent;
}
.auth-tab.active {
    color: var(--dark);
    border-bottom-color: var(--accent);
}
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}
.auth-field {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}
.auth-field label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--muted);
}
.auth-field input {
    padding: 0.8rem 1rem;
    border: 1px solid var(--border-col);
    background: var(--bg);
    font-family: inherit;
    font-size: 0.9rem;
    color: var(--text);
    outline: none;
    transition: border-color var(--transition);
}
.auth-field input:focus { border-color: var(--accent); }

/* ============================================================
   HERITAGE SECTION
   ============================================================ */
.heritage-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 70vh;
}
.heritage-image {
    position: relative;
    background: url('/static/heritage_detail.png') center/contain no-repeat #000;
    min-height: 500px;
    overflow: hidden;
}
.heritage-img-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.4), transparent);
    pointer-events: none;
}
.heritage-content {
    padding: 6rem 5%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: var(--surface);
}
.heritage-content h2 {
    font-family: var(--font-title);
    font-size: clamp(2rem, 3.5vw, 3rem);
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    color: var(--dark);
}
.heritage-content h2 em { font-style: italic; color: var(--accent); }
.heritage-content p {
    font-family: 'Cormorant Garamond', serif;
    font-style: italic;
    font-weight: 600;
    font-size: 1.4rem;
    color: var(--muted);
    line-height: 1.5;
    margin-bottom: 1.25rem;
}

/* ============================================================
   SAVOIR-FAIRE
   ============================================================ */
.savoir-faire {
    padding: 7rem 5%;
    background: var(--dark);
    text-align: center;
}
.savoir-faire-header { margin-bottom: 4rem; }
.savoir-faire-header h2 {
    font-family: var(--font-title);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 300;
    color: var(--bg);
}
.savoir-faire-header h2 em { font-style: italic; color: var(--accent); }
.savoir-faire-header .top-label { color: rgba(255,255,255,0.45); }

.sf-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 4rem;
    max-width: 900px;
    margin: 0 auto;
}
.sf-item { text-align: left; }
.sf-number {
    display: block;
    font-family: var(--font-title);
    font-size: 3.5rem;
    font-weight: 300;
    color: var(--accent);
    line-height: 1;
    margin-bottom: 1rem;
}
.sf-item h3 {
    font-family: var(--font-title);
    font-size: 1.4rem;
    font-weight: 400;
    color: var(--bg);
    margin-bottom: 0.75rem;
}
.sf-item p { color: rgba(255,255,255,0.5); font-size: 0.88rem; line-height: 1.8; }

/* ============================================================
   NEWSLETTER
   ============================================================ */
.newsletter-luxe {
    padding: 7rem 5%;
    text-align: center;
    background: var(--surface);
}
.newsletter-luxe h2 {
    font-family: var(--font-title);
    font-size: clamp(2rem, 4vw, 3.5rem);
    font-weight: 600;
    color: var(--dark);
    margin-bottom: 2.5rem;
}
.newsletter-luxe h2 em { font-style: italic; color: var(--accent); }
.newsletter-form {
    display: flex;
    max-width: 460px;
    margin: 0 auto;
    border: 1px solid var(--border-col);
    overflow: hidden;
}
.newsletter-form input {
    flex: 1;
    padding: 1rem 1.25rem;
    border: none;
    background: var(--bg);
    font-family: inherit;
    font-size: 0.9rem;
    color: var(--text);
    outline: none;
}
.newsletter-form button {
    padding: 1rem 1.75rem;
    background: var(--dark);
    color: var(--bg);
    font-size: 0.75rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    transition: background var(--transition);
    white-space: nowrap;
}
.newsletter-form button:hover { background: var(--accent); }

/* ============================================================
   FOOTER
   ============================================================ */
.footer-premium {
    background: var(--dark);
    color: rgba(255,255,255,0.65);
}
.footer-top {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 4rem;
    padding: 5rem 8%;
    max-width: 1500px;
    margin: 0 auto;
}
.footer-brand {}
.footer-logo { 
    height: 80px; 
    object-fit: contain; 
    margin-bottom: 0.5rem; 
    filter: drop-shadow(0 0 8px rgba(255,255,255,0.15));
}
.footer-brand-name {
    font-family: var(--font-title);
    font-size: 1.4rem;
    letter-spacing: 3px;
    color: var(--bg);
    display: block;
    margin-bottom: 0.5rem;
}
.footer-tagline { font-size: 0.85rem; line-height: 1.6; margin-bottom: 1.5rem; }
.footer-socials { display: flex; gap: 0.75rem; }
.social-link {
    width: 36px; height: 36px;
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 1rem;
    color: rgba(255,255,255,0.5);
    transition: all var(--transition);
}
.social-link:hover {
    background: var(--accent);
    border-color: var(--accent);
    color: white;
}

.footer-col h4 {
    font-size: 0.72rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--bg);
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}
.footer-col ul { display: flex; flex-direction: column; gap: 0.75rem; }
.footer-col a {
    font-size: 0.85rem;
    transition: color var(--transition);
}
.footer-col a:hover { color: var(--accent); }

.contact-list li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.85rem;
}
.contact-list i { color: var(--accent); font-size: 1rem; }

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.08);
    padding: 1.5rem 8%;
    text-align: center;
    font-size: 0.75rem;
    letter-spacing: 1px;
    text-transform: uppercase;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
    .hero-premium { grid-template-columns: 1fr; min-height: auto; }
    .hero-image-side { display: none; }
    .hero-content-luxe { padding: 6rem 6% 4rem; text-align: center; align-items: center; }
    .heritage-section { grid-template-columns: 1fr; }
    .heritage-image { min-height: 250px; }
    .footer-top { grid-template-columns: 1fr 1fr; gap: 3rem; }
}

@media (max-width: 768px) {
    .nav-links { display: none; }
    .hamburger-btn { display: flex; }
    .hero-content-luxe { padding: 4rem 5%; }
    .sf-grid { grid-template-columns: 1fr; gap: 2rem; max-width: 400px; }
    .product-grid { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1.25rem; }
    .footer-top { grid-template-columns: 1fr; gap: 2.5rem; }
    .chk-field-row { grid-template-columns: 1fr; }
    .catalogue-filters { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 480px) {
    .product-grid { grid-template-columns: 1fr 1fr; gap: 0.75rem; }
    .cart-sidebar { width: 100dvw; }
    .checkout-modal-box { padding: 2rem 1.5rem; }
}

/* ===== EXTENDED FEATURES ===== */
/* Dark Mode Variables */
body.dark-mode {
    --bg: #121212;
    --surface: #1E1E1E;
    --dark: #FDFBF7;
    --text: #E0E0E0;
    --muted: #A0A0A0;
    --border-col: #333333;
}
body.dark-mode .navbar {
    background: rgba(18, 18, 18, 0.92);
}
body.dark-mode .product-card, body.dark-mode .cart-item-img {
    background: #1E1E1E;
}

/* Footer Dark Mode Overrides */
body.dark-mode .footer-premium {
    background: #0A0A0A;
    color: var(--muted);
}
body.dark-mode .footer-brand-name,
body.dark-mode .footer-col h4 {
    color: var(--accent);
}
body.dark-mode .footer-col a {
    color: #A0A0A0;
}
body.dark-mode .footer-col a:hover {
    color: var(--accent);
}
body.dark-mode .footer-bottom {
    background: #050505;
    border-top-color: #222222;
}

body.dark-mode .ticker-bar {
    background: #0A0A0A;
}
body.dark-mode .ticker-item {
    color: rgba(255,255,255,0.6);
}

/* Savoir-Faire Dark Mode Fix - Forced Visibility */
body.dark-mode section.savoir-faire {
    background: #0f0f0f !important;
    border-top: 1px solid #1a1a1a;
}
body.dark-mode .savoir-faire-header h2 {
    color: #f5f5f5 !important;
}
body.dark-mode .savoir-faire-header .top-label {
    color: var(--accent) !important;
}
body.dark-mode .sf-item h3 {
    color: #ffffff !important;
}
body.dark-mode .sf-item p {
    color: #b0b0b0 !important;
    opacity: 1 !important;
}
body.dark-mode .sf-number {
    color: var(--accent) !important;
}

/* Newsletter Dark Mode Fix */
body.dark-mode .newsletter-luxe {
    background: #0D0D0D;
}
body.dark-mode .newsletter-luxe h2 {
    color: #FFFFFF;
}
/* Lang Dropdown */
.lang-dropdown {
    position: relative;
    display: inline-block;
}
.lang-menu {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--bg);
    min-width: 60px;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border-col);
    z-index: 1000;
}
.lang-dropdown:hover .lang-menu { display: block; }
.lang-menu a {
    color: var(--text);
    padding: 10px 15px;
    text-decoration: none;
    display: block;
    text-align: center;
    font-size: 0.8rem;
    transition: background 0.3s;
}
.lang-menu a:hover { background: var(--surface); color: var(--accent); }

/* Search Overlay */
.search-overlay {
    position: fixed;
    inset: 0;
    background: rgba(26,26,26,0.95);
    backdrop-filter: blur(10px);
    z-index: 4000;
    display: flex;
    justify-content: center;
    padding-top: 15vh;
}
.search-container {
    width: 80%;
    max-width: 800px;
    position: relative;
}
.search-container input {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 2px solid var(--accent);
    color: white;
    font-size: 2.5rem;
    font-family: var(--font-title);
    outline: none;
    padding: 1rem 0;
    margin-bottom: 2rem;
}
.close-search {
    position: absolute;
    top: 0; right: 0;
    width: 50px; height: 50px;
    color: white;
    font-size: 2.5rem;
}
.search-results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.5rem;
    max-height: 50vh;
    overflow-y: auto;
}
.search-results-grid .product-card { background: white; color: black; }

/* WhatsApp Float */
.wa-float {
    position: fixed;
    width: 60px;
    height: 60px;
    bottom: 30px;
    left: 30px;
    background-color: #25d366;
    color: #FFF;
    border-radius: 50px;
    text-align: center;
    font-size: 35px;
    box-shadow: 2px 2px 10px rgba(0,0,0,0.2);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s;
}
.wa-float:hover { transform: scale(1.1); color: #FFF; }

/* Payment & RTL */
.payment-shipping-section { margin-top: 1rem; border-top: 1px solid var(--border-col); padding-top: 1rem; }
.payment-options { display: flex; flex-direction: column; gap: 0.5rem; }
.payment-label { display: flex; align-items: center; gap: 0.5rem; font-size: 0.9rem; cursor: pointer; }

/* Card Payment Section */
#card-info-section {
    margin-top: 1.5rem;
    padding: 1.5rem;
    background: #fcfcfc;
    border: 1px solid var(--border-col);
    border-radius: 4px;
    animation: slideDown 0.4s ease;
}
body.dark-mode #card-info-section {
    background: #181818;
    border-color: #333;
}
.card-fields-container {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}
.card-input-wrapper {
    position: relative;
}
.card-input-wrapper i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--muted);
    font-size: 1.1rem;
}
.card-input-wrapper input {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 2.8rem;
    border: 1px solid var(--border-col);
    background: var(--bg);
    font-size: 0.9rem;
    color: var(--text);
    transition: border-color 0.3s;
}
.card-input-wrapper input:focus {
    border-color: var(--dark);
    outline: none;
}
.card-row-dual {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Payment Processing Animation */
.payment-processing-overlay {
    position: fixed;
    inset: 0;
    background: rgba(253, 251, 247, 0.98);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(10px);
}
body.dark-mode .payment-processing-overlay { background: rgba(18, 18, 18, 0.98); }

.spinner-luxury {
    width: 50px;
    height: 50px;
    border: 2px solid var(--border-col);
    border-top: 2px solid var(--accent);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 2rem;
}
.processing-text {
    font-family: var(--font-title);
    font-size: 1.5rem;
    color: var(--dark);
    letter-spacing: 2px;
    text-transform: uppercase;
}

/* ============================================================
   PREMIUM FEATURES: FAVORITES & SALES
   ============================================================ */
.fav-btn {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: var(--muted);
    z-index: 10;
    transition: all var(--transition);
    box-shadow: var(--shadow-sm);
}
.fav-btn:hover {
    transform: scale(1.1);
    color: #e74c3c;
}
.fav-btn.active {
    color: #e74c3c;
    background: var(--white);
}

.product-badge.sale {
    background: var(--accent) !important;
    color: white !important;
}

.old-price {
    text-decoration: line-through;
    color: var(--muted);
    font-size: 0.85rem;
    margin-right: 0.5rem;
}
.sale-price {
    color: var(--dark);
    font-weight: 600;
}

/* ============================================================
   ARABIC RTL SUPPORT (Unified & Fixed)
   ============================================================ */
body.rtl {
    direction: rtl;
    text-align: right;
    font-family: 'Amiri', serif;
}

body.rtl .hero-content-luxe h1,
body.rtl .hero-content-luxe p,
body.rtl .section-header h2,
body.rtl .heritage-content h2,
body.rtl .heritage-content p,
body.rtl .savoir-faire-header h2,
body.rtl .newsletter-luxe h2,
body.rtl .footer-brand-name,
body.rtl .checkout-modal-header h2 {
    font-family: 'Amiri', serif;
    font-weight: 700;
}

/* Nav Fixes */
body.rtl .brand-logo { margin-right: 0; }
body.rtl .nav-links { margin-right: 0; }
body.rtl .nav-actions { margin-left: 0; }
body.rtl .lang-menu { right: auto; left: 0; }

/* Hero Fixes */
body.rtl .hero-content-luxe { padding: 6rem 8% 6rem 5%; } /* Swapped padding */
body.rtl .hero-side-label { right: auto; left: -30px; }

/* Section Specifics */
body.rtl .heritage-content { padding: 6rem 5%; }
body.rtl .sf-item { text-align: right; }

/* Card & Badges */
body.rtl .fav-btn { right: auto; left: 1rem; }
body.rtl .product-badge { left: auto; right: 1rem; }
body.rtl .out-of-stock-badge { right: auto; left: 1rem; }
body.rtl .product-badge.sale { right: auto; left: 1rem; }

/* Cart & Modals */
body.rtl .cart-sidebar { right: auto; left: 0; transform: translateX(-100%); border-left: none; border-right: 1px solid var(--border-col); }
body.rtl .cart-sidebar.open { transform: translateX(0); }
body.rtl .modal-close-btn { right: auto; left: 1rem; }
body.rtl .cart-item-remove { margin-left: 0; margin-right: auto; }

/* Icons & Arrows */
body.rtl .bx-right-arrow-alt, 
body.rtl .bx-chevron-right { transform: rotate(180deg); display: inline-block; }
body.rtl .bx-chevron-left { transform: rotate(180deg); display: inline-block; }

/* Ticker Fix */
body.rtl .ticker-content { animation: ticker-scroll-rtl 25s linear infinite; }
@keyframes ticker-scroll-rtl {
    from { transform: translateX(0); }
    to { transform: translateX(50%); }
}

/* Favorites Filter */
body.rtl .btn-fav-filter i { margin-right: 0; margin-left: 0.25rem; }

/* Mobile Adjustments */
@media (max-width: 1024px) {
    body.rtl .hero-content-luxe { padding: 6rem 5% 4rem; text-align: center; }
}

/* Fix flex containers that were manually reversed (Removing the mistake) */
/* The natural 'direction: rtl' will handle most of these correctly now */
body.rtl .hero-btns,
body.rtl .nav-links,
body.rtl .nav-actions,
body.rtl .footer-top {
    flex-direction: row; /* Ensure it stays row, direction:rtl handles the rest */
}

/* Grid columns naturally swap with direction: rtl */
body.rtl .hero-premium,
body.rtl .heritage-section,
body.rtl .footer-top,
body.rtl .sf-grid {
    direction: rtl;
}

/* ============================================================
   PRODUCT DETAIL MODAL (LIGHTBOX)
   ============================================================ */
.product-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(10px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    animation: fadeIn 0.3s ease;
}

.product-modal-content {
    background: var(--bg-dark);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    max-width: 1000px;
    width: 100%;
    max-height: 90vh;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.product-modal-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    height: 100%;
}

.product-modal-image {
    background: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.product-modal-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.product-modal-image img:hover {
    transform: scale(1.05);
}

.product-modal-info {
    padding: 3rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: var(--card-bg);
}

.product-modal-info h2 {
    font-size: 2.5rem;
    font-family: 'Amiri', serif;
    margin-bottom: 0.5rem;
    color: var(--text-bright);
}

.modal-cat-tag {
    font-size: 0.9rem;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 1.5rem;
}

.modal-price {
    font-size: 1.8rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: var(--text-bright);
}

.modal-description {
    line-height: 1.6;
    color: var(--text-dim);
    margin-bottom: 2rem;
    font-size: 1.1rem;
}

.btn-add-modal {
    background: var(--accent);
    color: white;
    padding: 1.2rem 2.5rem;
    border: none;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    font-size: 1.1rem;
}

.btn-add-modal:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(181, 149, 107, 0.3);
}

@media (max-width: 850px) {
    .product-modal-body {
        grid-template-columns: 1fr;
        overflow-y: auto;
    }
    .product-modal-info {
        padding: 2rem;
    }
    .product-modal-info h2 {
        font-size: 1.8rem;
    }
}
