:root {
    --primary: #B20000;
    --accent: #B5894B;
    --dark: #1A1A1A;
    /* Dark mode tokens */
    --bg-main: #1A1A1A;
    --bg-surface: #222222;
    --bg-card: rgba(255, 255, 255, 0.04);
    --bg-card-hover: rgba(255, 255, 255, 0.08);
    --text-primary: #ffffff;
    --text-secondary: #aaaaaa;
    --text-muted: #666666;
    --border: rgba(255, 255, 255, 0.08);
    --nav-bg: rgba(26, 26, 26, 0.85);
    --footer-bg: #111111;
    --mobile-menu-bg: rgba(18, 18, 18, 0.98);
    --input-bg: #2d2d2d;
    --input-border: rgba(255, 255, 255, 0.1);
}

/* ===== LIGHT MODE ===== */
body.light-mode {
    --bg-main: #F9F8F6;
    --bg-surface: #EFEAE4;
    --bg-card: rgba(0, 0, 0, 0.03);
    --bg-card-hover: rgba(0, 0, 0, 0.07);
    --text-primary: #1A1A1A;
    --text-secondary: #444444;
    --text-muted: #666666;
    --border: rgba(0, 0, 0, 0.08);
    --nav-bg: rgba(249, 248, 246, 0.93);
    --footer-bg: #EFEAE4;
    --mobile-menu-bg: rgba(249, 248, 246, 0.99);
    --input-bg: #EFEAE4;
    --input-border: rgba(0, 0, 0, 0.12);
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: var(--bg-main);
    color: var(--text-primary);
    overflow-x: hidden;
    transition: background-color 0.4s ease, color 0.4s ease;
}

h1,
h2,
h3,
.brand-font {
    font-family: 'Righteous', cursive;
}

/* === THEME SWITCH === */
.theme-switch {
    position: relative;
    display: inline-block;
    width: 52px;
    height: 26px;
    flex-shrink: 0;
}

.theme-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.theme-slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background: linear-gradient(135deg, #1e2240, #2a2d4a);
    border-radius: 26px;
    transition: .35s;
    border: 1px solid rgba(255, 255, 255, 0.18);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 5px;
}

.theme-slider .t-sun {
    color: #fbbf24;
    font-size: 10px;
    opacity: 0;
    transition: .3s;
    z-index: 1;
}

.theme-slider .t-moon {
    color: #c4cfe8;
    font-size: 10px;
    opacity: 1;
    transition: .3s;
    z-index: 1;
}

.theme-slider::after {
    content: '';
    position: absolute;
    height: 20px;
    width: 20px;
    right: 3px;
    top: 2px;
    background: #e2e8f0;
    border-radius: 50%;
    transition: .35s;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
}

.theme-switch input:checked+.theme-slider {
    background: linear-gradient(135deg, #fde68a, #fbbf24);
    border-color: rgba(0, 0, 0, 0.12);
}

.theme-switch input:checked+.theme-slider::after {
    right: auto;
    left: 3px;
    background: #fff7e6;
}

.theme-switch input:checked+.theme-slider .t-sun {
    opacity: 1;
}

.theme-switch input:checked+.theme-slider .t-moon {
    opacity: 0;
}

/* Loader */
#loader {
    position: fixed;
    inset: 0;
    background-color: #1a1a1a;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.8s ease, visibility 0.8s ease;
}

.loader-container {
    position: relative;
    width: 220px;
    height: 160px;
    margin-bottom: 20px;
}

.logo-bg {
    width: 100%;
    height: 100%;
    opacity: 0.1;
    filter: grayscale(1) brightness(0.5);
    object-fit: contain;
}

.logo-wrapper {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 0%;
    overflow: hidden;
    animation: fillAnimation 2s ease-in-out forwards;
}

.logo-fill {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 220px;
    height: 160px;
    object-fit: contain;
    filter: drop-shadow(0 0 15px rgba(178, 0, 0, 0.6));
}

@keyframes fillAnimation {
    0% { height: 0%; }
    100% { height: 100%; }
}

/* Navbar */
.nav-glass {
    background: var(--nav-bg);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    transition: background 0.4s ease;
}

body.light-mode .nav-link { color: #1A1A1A !important; }
body.light-mode .nav-link:hover { color: var(--primary) !important; }
body.light-mode .nav-brand-text { color: #1A1A1A !important; }
body.light-mode .lang-border { border-color: rgba(0, 0, 0, 0.15) !important; }
body.light-mode .lang-sep { color: #999 !important; }
body.light-mode #mobile-menu-btn { color: #1A1A1A !important; }

/* Hero Video */
.hero-video-container {
    position: relative;
    height: 100vh;
    width: 100%;
    overflow: hidden;
}

#hero-video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    transform: translate(-50%, -50%);
    object-fit: cover;
    filter: brightness(0.4);
}

/* Review Slider */
.review-card {
    background: var(--bg-card);
    backdrop-filter: blur(5px);
    border: 1px solid var(--border);
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.review-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
}

.review-card h4 { color: var(--text-primary); }
.review-card p { color: var(--text-secondary); }

@keyframes slide {
    0% { transform: translateX(0) }
    100% { transform: translateX(-50%) }
}

.animate-scroll {
    display: flex;
    width: calc(250px * 10);
    animation: slide 30s linear infinite;
}

/* Mobile Menu */
#mobile-menu {
    transform: translateX(100%);
    transition: transform 0.3s ease-in-out;
    background: var(--mobile-menu-bg) !important;
}

#mobile-menu.active { transform: translateX(0); }
#mobile-menu a { color: var(--text-primary) !important; }
#mobile-menu #close-menu { color: var(--text-primary) !important; opacity: 1 !important; visibility: visible !important; }
body.light-mode #mobile-menu .lang-btn { border-color: rgba(0, 0, 0, 0.15) !important; color: #1A1A1A !important; }

/* Section backgrounds */
.section-main { background-color: var(--bg-main); }
.section-surface { background-color: var(--bg-surface); }

/* Theme Helpers */
.theme-text { color: var(--text-primary); }
.text-white-forced { color: white !important; }
body.light-mode h1, body.light-mode h2, body.light-mode h3, body.light-mode h4 { color: var(--text-primary); }

/* Social Icons */
.social-icon { background-color: var(--bg-surface); color: var(--text-secondary); transition: all 0.3s ease; }
body.light-mode .social-icon { background-color: rgba(0,0,0,0.05); color: var(--text-primary); }
.social-icon:hover { background-color: var(--primary) !important; color: white !important; }

/* Modern Scrollbar */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(150, 150, 150, 0.3); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: rgba(150, 150, 150, 0.5); }

.hide-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }
.hide-scrollbar::-webkit-scrollbar { display: none; }

/* Cards & Images */
.card-bg { background-color: var(--bg-surface); }
.img-bg { background-color: var(--bg-main); }
.product-img { mix-blend-mode: normal; }
body.light-mode .product-img { mix-blend-mode: multiply; }

/* Icon Filters */
.category-icon, .ingredient-icon {
    filter: invert(1) brightness(2);
    transition: all 0.3s ease;
}
body.light-mode .category-icon, body.light-mode .ingredient-icon {
    filter: brightness(0);
}
.menu-category-btn.active .category-icon {
    filter: invert(12%) sepia(85%) saturate(7400%) hue-rotate(3deg) brightness(90%) contrast(115%) !important;
    transform: scale(1.1);
}

/* Gallery & Lightbox */
.gallery-item { position: relative; cursor: pointer; overflow: hidden; border-radius: 1rem; }
.gallery-overlay {
    position: absolute; inset: 0; background: rgba(178, 0, 0, 0.7);
    display: flex; align-items: center; justify-content: center;
    opacity: 0; transition: all 0.3s ease;
}
.gallery-item:hover .gallery-overlay { opacity: 1; }

#lightbox {
    display: none; position: fixed; inset: 0; z-index: 1000;
    background: rgba(0,0,0,0.95); align-items: center; justify-content: center; padding: 20px;
}
#lightbox.active { display: flex; }
#lightbox-img { max-width: 95%; max-height: 85vh; border-radius: 1rem; box-shadow: 0 0 50px rgba(0,0,0,0.5); transition: transform 0.3s ease; }

/* Red Icon Utility */
.red-icon {
    filter: invert(12%) sepia(85%) saturate(7400%) hue-rotate(3deg) brightness(90%) contrast(115%) !important;
}
