﻿/* RESET */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    touch-action: manipulation;
}

:root {
    --bg-color: #000000;
    /* Pitch black */
    --text-color: #f0f0f0;
    --accent-color: #ffffff;
    --font-heading: 'Syncopate', sans-serif;
    --font-body: 'Inter', sans-serif;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 100px;
    background-color: var(--bg-color);
    text-size-adjust: 100%;
    -webkit-text-size-adjust: 100%;
    overscroll-behavior: none;
    /* Prevent rubber-band effect showing background */
    /* Ensure background is black to avoid flash */
    /* Offset for fixed header */
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-body);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    overscroll-behavior: none;
    /* Prevent rubber-band effect */
    /* Animation moved to .page-content to avoid stacking context issues for fixed modal */
}

.page-content {
    width: 100%;
    transition: opacity 1.5s ease-out, transform 1.5s ease-out;
}

/* Subpages: Appear from Shadow */
body:not(.home-page) .page-content {
    opacity: 0;
    transform: translateY(100px);
}

body:not(.home-page) .page-content.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Home Page: Lift Up after Intro */
body.home-page .page-content {
    opacity: 1;
    transform: translateY(0);
    /* Start neutral for seamless logo handover */
}

/* RESTRICT LIFT TO DESKTOP ONLY */
@media (min-width: 769px) {
    body.home-page .page-content.lifted {
        transform: translateY(-25vh);
        /* The requested "Transit Up" - much closer to top */
    }
}

/* GLOBAL SCROLLBAR */
::-webkit-scrollbar {
    width: 5px;
    height: 5px;
}

::-webkit-scrollbar-track {
    background: #000;
}

::-webkit-scrollbar-thumb {
    background: #555;
    border-radius: 2px;
}

::-webkit-scrollbar-thumb:hover {
    background: #888;
}

/* Intro Logo - Desktop */
.intro-logo-container {
    width: 280px;
}

/* Intro Logo - Mobile (smaller) */
@media (max-width: 768px) {
    .intro-logo-container {
        width: 140px;
    }
}

/* NAVBAR - DESKTOP DEFAULT */
/* NAVBAR - DESKTOP DEFAULT */
.navbar {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    padding: 2rem 4rem;
    /* Bigger navbar */
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    transition: background 0.3s ease;
    mix-blend-mode: normal;
}

/* Ensure logo stays left within grid */
.navbar .logo {
    justify-self: start;
}

/* Ensure menu stays centered within grid */
.navbar .menu {
    justify-self: center;
}

/* Ensure cart/hamburger stays right within grid */
.navbar .cart-icon,
.navbar .hamburger {
    justify-self: end;
}

.navbar.scrolled {
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    /* Padding stays 1.5rem 3rem */
    mix-blend-mode: normal;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--accent-color);
    text-transform: uppercase;
    /* Desktop: Normal flow */
    position: relative;
    z-index: 1002;
}

/* Desktop: Menu and Cart are adjacent */
.menu {
    display: flex;
    align-items: center;
    gap: 4rem;
}

.menu a {
    color: var(--accent-color);
    text-decoration: none;
    font-family: 'Inter', sans-serif !important;
    font-size: 13px !important;
    line-height: 1 !important;
    text-transform: uppercase !important;
    font-weight: 500 !important;
    letter-spacing: 2px !important;
    position: relative;
    transition: opacity 0.3s;
}

.menu a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 1px;
    bottom: -5px;
    left: 0;
    background-color: var(--accent-color);
    transition: width 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.menu a:hover::after {
    width: 100%;
}

.cart-icon {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    position: relative;
    color: var(--accent-color);
    text-decoration: none;
    margin-left: 2rem;
    /* Spacing from menu on desktop */
}

.cart-icon #cart-count {
    position: absolute;
    top: 48%;
    left: 43%;
    transform: translate(-50%, -50%);
    font-size: 0.65rem;
    font-weight: 600;
    color: #fff;
    pointer-events: none;
    font-family: var(--font-body);
}

/* HAMBURGER - Hidden on Desktop */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 6px;
    z-index: 1001;
}

.hamburger span {
    width: 30px;
    height: 2px;
    background: var(--accent-color);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active span:nth-child(2) {
    transform: rotate(-45deg) translate(5px, -5px);
}


/* HERO SECTION */
.hero {
    height: 100vh;
    /* Fallback */
    height: var(--app-height, 100vh);
    width: 100%;
    position: relative;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #000;
}

/* Replaced hero-image/hero-content with global hero-logo */
/* Replaced hero-image/hero-content with global hero-logo */
.hero-logo {
    z-index: 5;
    width: 280px !important;
    /* Force size */
    max-width: 280px !important;
    height: auto;
    display: flex;
    justify-content: center;
}

/* CART ANIMATIONS */
@keyframes shakeCart {
    0% {
        transform: rotate(0deg);
    }

    25% {
        transform: rotate(-10deg);
    }

    50% {
        transform: rotate(10deg);
    }

    75% {
        transform: rotate(-5deg);
    }

    100% {
        transform: rotate(0deg);
    }
}

@keyframes dropInItem {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.2);
    }

    100% {
        transform: scale(1);
    }
}

.cart-icon:hover svg,
.cart-icon:hover #cart-count {
    animation: shakeCart 0.4s ease-in-out;
}

/* Class added via JS when items > 0 */
.cart-icon.has-items svg {
    /* Subtle heartbeat or shake to show it's active */
    animation: dropInItem 1s ease infinite;
    /* Or something more distinct like a recurring shake */
    animation: shakeCart 2s ease infinite;
    animation-delay: 1s;
    /* Pause between shakes */
}

/* Refined active shake for items inside */
@keyframes shakeCartActive {

    0%,
    100% {
        transform: rotate(0deg);
    }

    10% {
        transform: rotate(-10deg);
    }

    20% {
        transform: rotate(10deg);
    }

    30% {
        transform: rotate(-10deg);
    }

    40% {
        transform: rotate(10deg);
    }

    50% {
        transform: rotate(0deg);
    }

    /* Check 60-100% wait */
}

.cart-icon.has-items svg,
.cart-icon.has-items #cart-count {
    animation: shakeCartActive 3s ease infinite;
}

.cart-icon.has-items svg {
    stroke: #fff;
}

/* refined stroke width for 24px box */
.cart-icon svg {
    width: 36px;
    height: 36px;
    stroke: #888;
    stroke-width: 1.5;
}

/* When items are added, change to white */
.cart-icon.has-items svg {
    stroke: #fff;
}

.cart-icon .bag-body {
    transition: fill 0.3s ease;
}

/* Fill the BAG BODY with solid semi-transparent white */
.cart-icon.has-items .bag-body {
    fill: rgba(255, 255, 255, 0.5);
}

.footer-logo-container img {
    width: 60px;
    height: auto;
    filter: none;
    opacity: 0.8;
}

.hero-logo img {
    width: 100%;
    height: auto;
    filter: none;
}

@keyframes fadeLogoInOut {
    0% {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
        filter: blur(5px);
    }

    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

/* Intro Pulse Keyframes */
@keyframes pulseIntro {
    0% {
        opacity: 0.5;
        transform: scale(0.95);
    }

    50% {
        opacity: 1;
        transform: scale(1.05);
    }

    100% {
        opacity: 0.5;
        transform: scale(0.95);
    }
}

/* PRODUCTS */
/* PRODUCTS - HORIZONTAL SCROLL */
.products {
    width: 100%;
    padding: 2rem 0;
    background: transparent;
    /* Transparent to overlay if needed */
    position: relative;
    z-index: 10;
    margin-top: -30vh;
    /* PULL UP into view to overlap Hero */
    margin-bottom: 30vh;
    /* Compensation space at bottom */
}

.products-container {
    display: flex;
    overflow-x: auto;
    gap: 1rem;
    padding: 2rem 3rem;
    /* Padding for the scroll container */
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    cursor: grab;
}

.products-container::-webkit-scrollbar {
    height: 6px;
}

.products-container::-webkit-scrollbar-track {
    background: #111;
}

.products-container::-webkit-scrollbar-thumb {
    background: #333;
    border-radius: 3px;
}

.products-container::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Dynamic Product Card */
.product-card {
    flex: 0 0 280px;
    /* Fixed width for cards */
    cursor: pointer;
    position: relative;
    background: var(--bg-color);
    display: flex;
    flex-direction: column;
    /* Removed overflow hidden to allow hover effects if needed, but keeping for image containment */
    overflow: hidden;
}

.image-container {
    width: 100%;
    aspect-ratio: 2/3;
    position: relative;
    overflow: hidden;
}

.image-container img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    transition: opacity 0.5s ease, transform 0.8s ease;
    opacity: 0;
}

.image-container img.active {
    opacity: 1;
}

.product-card:hover .image-container img.active {
    transform: scale(1.03);
}

.product-info {
    padding: 1rem 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.product-info h3 {
    font-family: var(--font-body);
    font-weight: 400;
    font-size: 0.8rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 70%;
}

.price {
    font-family: var(--font-body);
    font-size: 0.8rem;
    color: #888;
    font-weight: 300;
}

/* =========================================
   MODAL & LIGHTBOX STYLES (SIDEBAR LAYOUT) - REVISED
   ========================================= */

/* The Modal Background */
.modal {
    display: none;
    /* Hidden by default */
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    background-color: rgba(0, 0, 0, 0.95);
    /* Blacker background */
    align-items: center;
    justify-content: center;
}

/* Modal Content Wrapper (The Box) */
/* Modal Content Wrapper (The Box) */
.modal-layout {
    display: flex !important;
    flex-direction: row !important;
    /* FORCE ROW FOR DESKTOP */
    width: 95vw;
    height: 80vh;
    max-height: 900px;
    max-width: 1400px;
    background: #000;

    /* FIXED CENTERING - Viewport Relative */
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    margin: 0;
    z-index: 2005;
    /* Above overlay */

    box-shadow: 0 0 20px rgba(255, 255, 255, 0.1);
}

/* 1. Left: Image Container */
.modal-image-container {
    flex: 1;
    /* Takes available space */
    height: 100%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000;
    overflow: hidden;
}

#modal-image {
    max-height: 100%;
    max-width: 100%;
    object-fit: contain;
    transition: transform 0.1s ease-out;
}

/* 2. Right: Sidebar */
.modal-sidebar {
    width: 400px;
    /* Fixed width for details */
    padding: 2.5rem;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    background: #000;
    color: #fff;
    border-left: 1px solid #222;
    overflow-y: auto;
    flex-shrink: 0;
    /* Prevent shrinking */
}

/* Header */
.modal-header {
    margin-bottom: 2rem;
    text-align: left;
}

#modal-title {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Mobile: smaller product title */
@media (max-width: 768px) {
    #modal-title {
        font-size: 1.3rem;
        letter-spacing: 0.5px;
    }
}

#modal-price {
    font-family: var(--font-body);
    font-size: 1.2rem;
    color: #aaa;
}

#modal-description {
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: #ccc;
    margin: 1rem 0;
    line-height: 1.6;
    max-width: 100%;
    white-space: pre-line;
}

/* Controls */
.modal-controls {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.control-group-stacked {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    align-items: flex-start;
}

.control-group-stacked label {
    font-family: var(--font-body);
    font-size: 0.8rem;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Size Dropdown */
.select-wrapper {
    position: relative;
    width: 100%;
    border: 1px solid #fff;
    background: #000;
}

#size-select {
    width: 100%;
    padding: 12px;
    background: #000;
    border: none;
    color: #fff;
    font-family: var(--font-body);
    font-size: 0.9rem;
    appearance: none;
    border-radius: 0;
    cursor: pointer;
}

#size-select option {
    background: #000;
    color: #fff;
}

.select-arrow {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #fff;
    pointer-events: none;
    font-size: 0.7rem;
}

/* Quantity */
.qty-selector {
    display: flex;
    align-items: center;
    border: 1px solid #333;
    background: #000;
}

.qty-btn {
    width: 40px;
    height: 40px;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.qty-btn:hover {
    background: #222;
}

#qty-input {
    width: 50px;
    height: 40px;
    background: transparent;
    border: none;
    color: #fff;
    text-align: center;
    font-family: var(--font-body);
    font-size: 1rem;
    appearance: none;
}

/* Add Button */
.add-btn {
    width: 100%;
    padding: 1rem;
    background: #000;
    color: #fff;
    border: 1px solid #fff;
    font-family: var(--font-heading);
    font-weight: 700;
    letter-spacing: 2px;
    cursor: pointer;
    transition: all 0.3s;
    text-transform: uppercase;
}

.add-btn:hover {
    background: #fff;
    color: #000;
}

/* Thumbnails */
.modal-thumbnails-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin-top: auto;
    width: 100%;
    background: transparent;
    border: none;
    padding: 0;
}

.modal-thumbnails-grid img {
    width: 100%;
    aspect-ratio: 2/3;
    object-fit: cover;
    cursor: pointer;
    opacity: 0.5;
    transition: opacity 0.3s;
    border: 1px solid transparent;
}

.modal-thumbnails-grid img.active,
.modal-thumbnails-grid img:hover {
    opacity: 1;
    border-color: #fff;
}

/* Navigation Buttons (Arrows) - positioned on the image side */
.nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.5);
    font-size: 3rem;
    cursor: pointer;
    z-index: 2010;
    padding: 1rem;
    transition: color 0.3s;
    touch-action: manipulation;
}

.nav-btn:hover {
    color: #fff;
    opacity: 1;
}

.prev-btn {
    left: 1rem;
}

.next-btn {
    /* Position at right edge of image area (before sidebar) */
    /* Modal width is 95vw max 1400px, sidebar is 400px */
    /* So image area ends at: 100% - 400px */
    right: calc(400px + 1rem);
}

.close-modal {
    position: absolute;
    top: 20px;
    right: 30px;
    color: #fff;
    font-size: 40px;
    font-weight: 300;
    cursor: pointer;
    z-index: 2010;
}

/* --- MOBILE MODAL (Responsive Override) --- */
@media (max-width: 900px) {
    .modal-layout {
        flex-direction: column !important;
        width: 100% !important;
        height: 100% !important;
        max-width: none !important;
        max-height: none !important;
        /* Override desktop max-height */
        margin: 0;
        border-radius: 0;

        /* Mobile Full Screen Fixed */
        position: fixed;
        top: 0;
        left: 0;
        transform: none;
    }

    .modal-image-container {
        height: 50%;
        /* Top half */
        flex: none;
    }

    .modal-sidebar {
        width: 100%;
        height: 50%;
        /* Bottom half */
        flex: 1;
        border-left: none;
        border-top: 1px solid #222;
        padding: 1.5rem;
    }

    .modal-thumbnails-grid {
        display: none;
        /* Hide thumbs on mobile */
    }

    .close-modal {
        top: 10px;
        right: 20px;
        color: #fff;
        text-shadow: 0 0 5px #000;
    }

    .nav-btn {
        display: block !important;
        position: absolute;
        top: 25%;
        /* Center of top half (image) */
        transform: translateY(-50%);
        font-size: 3rem;
        /* Large arrows */
        padding: 10px;
        color: rgba(255, 255, 255, 0.4);
        /* Grey */
        background: transparent;
        z-index: 2020;
        /* Ensure above modal content */
        pointer-events: auto;
    }

    .prev-btn {
        left: 0;
    }

    .next-btn {
        right: 0;
        /* Reset for mobile - no sidebar offset needed */
    }

    .nav-btn:hover {
        color: rgba(255, 255, 255, 0.8);
    }
}

/* Scroll Reveal Animation */
.scroll-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.scroll-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered delay for each element */
.scroll-reveal:nth-child(1) {
    transition-delay: 0s;
}

.scroll-reveal:nth-child(2) {
    transition-delay: 0.1s;
}

.scroll-reveal:nth-child(3) {
    transition-delay: 0.2s;
}

.scroll-reveal:nth-child(4) {
    transition-delay: 0.3s;
}

.scroll-reveal:nth-child(5) {
    transition-delay: 0.4s;
}

.scroll-reveal:nth-child(6) {
    transition-delay: 0.5s;
}

.scroll-reveal:nth-child(7) {
    transition-delay: 0.6s;
}

/* ABOUT SECTION */
.about-section {
    background: var(--bg-color);
    padding: 8rem 2rem;
    display: flex;
    justify-content: center;
}

.about-wrapper {
    max-width: 800px;
    text-align: center;
}

.about-wrapper h2 {
    font-family: var(--font-heading);
    font-size: 2rem;
    margin-bottom: 3rem;
    letter-spacing: 2px;
}

.about-wrapper h3 {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    margin-top: 4rem;
    margin-bottom: 2rem;
    letter-spacing: 1px;
    color: #888;
}

.about-wrapper p {
    font-size: 1rem;
    line-height: 1.8;
    color: #ccc;
    font-weight: 300;
}

/* Mobile: smaller text for about page */
@media (max-width: 768px) {
    .about-wrapper h2 {
        font-size: 1.2rem;
    }

    .about-wrapper p {
        font-size: 0.8rem;
        line-height: 1.6;
    }

    .about-wrapper h3 {
        font-size: 0.9rem;
    }
}

/* FOOTER */
.footer {
    background: var(--bg-color);
    padding: 4rem 2rem;
    border-top: 1px solid #111;
    text-align: center;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.footer-links a {
    color: #888;
    text-decoration: none;
    font-size: 0.75rem;
    letter-spacing: 1px;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--accent-color);
}

/* MOBILE SPLASH DEFAULT HIDDEN on Desktop */
.mobile-splash {
    display: none;
}

/* --- TABLET RESPONSIVE (768px - 1024px) --- */
@media (min-width: 769px) and (max-width: 1024px) {
    .menu {
        gap: 2rem;
    }

    .menu a {
        font-size: 11px !important;
        letter-spacing: 1px !important;
    }

    .logo img {
        height: 28px !important;
    }

    .navbar {
        padding: 1rem 1.5rem;
    }
}

/* --- MOBILE RESPONSIVE -- */
@media (max-width: 768px) {
    .navbar {
        display: flex;
        /* Force Flexbox on mobile */
        background-color: #000 !important;
        mix-blend-mode: normal !important;
        padding: 1rem 1.5rem;
        /* Flex setup for 3 items: Hamburger, Logo, Cart */
        justify-content: space-between;
        align-items: center;
        height: 80px;
        /* Fixed height for header */
    }

    /* 1. HAMBURGER: Left */
    .hamburger {
        display: flex;
        order: 1;
        /* First item */
        position: static;
        /* Let flex handle it */
    }

    /* 2. LOGO: Center (Absolute) */
    .logo {
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
        order: 2;
        /* Doesn't matter if absolute, but good for logic */
    }

    /* 3. CART: Right */
    .cart-icon {
        margin-left: 0;
        order: 3;
        /* Last item */
    }

    /* 4. MENU: Drawer (Hidden) */
    .menu {
        position: fixed;
        top: 0;
        right: -100%;
        height: 100vh;
        width: 100%;
        background: var(--bg-color);
        flex-direction: column;
        justify-content: center;
        transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
        padding: 2rem;
        z-index: 1000;
    }

    .menu.active {
        right: 0;
    }

    /* Hide Cart INSIDE Menu if we put it back? No, it's outside now. */
    /* Ensure other links are large */
    .menu a {
        font-family: var(--font-heading);
        font-size: 1.5rem;
    }

    /* Fix Splash under header */
    .mobile-splash {
        display: flex;
        position: relative;
        height: 100vh;
        /* Fallback */
        height: var(--app-height, 100vh);
        min-height: var(--app-height, 100vh);
        width: 100%;
        overflow: hidden;
        justify-content: center;
        align-items: flex-end;
        padding-bottom: 30%;
        margin-top: 0;
        padding-top: 80px;
        /* Clear header */
        background-color: var(--bg-color);
        z-index: 10;
        /* Ensure splash is above hero but below header */
        touch-action: pan-y;
    }

    .mobile-splash-bg {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        z-index: 1;
        overflow: hidden;
    }

    .mobile-splash-bg img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        object-position: center center;
        opacity: 0.7;
        filter: grayscale(20%) brightness(0.8);
    }

    /* Fog / Gradient Overlay */
    .mobile-splash-bg::after {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: linear-gradient(to bottom, rgba(0, 0, 0, 0.3) 0%, rgba(0, 0, 0, 0.5) 50%, rgba(0, 0, 0, 0.9) 100%);
        z-index: 2;
    }

    /* Fix Image Fit - Start below header */
    .mobile-splash-bg {
        top: 80px;
        /* Offset for header */
        height: calc(100% - 80px);
    }

    .mobile-splash-bg img {
        position: absolute;
        top: 0;
        left: 0;
    }

    .mobile-splash-content {
        position: relative;
        z-index: 5;
        text-align: center;
        width: 100%;
        margin-bottom: 2rem;
    }

    .collection-title {
        font-family: var(--font-body);
        font-size: 0.9rem;
        color: rgba(255, 255, 255, 0.7);
        margin-bottom: 0.5rem;
        font-weight: 300;
        letter-spacing: 1px;
    }

    .shop-link {
        font-family: var(--font-body);
        font-size: 1.1rem;
        color: #ffffff !important;
        /* Force White */
        text-decoration: underline;
        text-underline-offset: 5px;
        letter-spacing: 2px;
        cursor: pointer;
        animation: pulse 2s ease-in-out infinite;
    }

    @keyframes pulse {

        0%,
        100% {
            opacity: 1;
            transform: scale(1);
        }

        50% {
            opacity: 0.7;
            transform: scale(1.05);
        }
    }

    .hero-logo {
        width: 140px;
    }

    /* Disable desktop hero on mobile */
    .hero {
        display: none;
    }

    /* Stack Products Vertical */
    .products-container {
        padding: 2rem 1rem;
        gap: 3rem;
        flex-direction: column;
        overflow-x: hidden;
        overflow-y: visible;
        height: auto;
        cursor: default;
    }

    .product-card {
        flex: 0 0 auto;
        width: 100%;
        max-width: 400px;
        margin: 0 auto;
    }

    /* Modal Mobile Styles Removed - Handled Globally by .modal-layout media query */
    .modal-content,
    #product-modal .modal-thumbnails,
    .modal-info-overlay {
        /* Reset or Ignore */
    }

    /* Gallery Navigation Buttons */
    .gallery-btn {
        position: absolute;
        top: 50%;
        transform: translateY(-50%);
        background: rgba(0, 0, 0, 0.5);
        color: white;
        border: none;
        font-size: 2rem;
        padding: 1rem;
        cursor: pointer;
        z-index: 10;
        transition: background 0.3s ease, opacity 0.3s;
        opacity: 0;
        height: auto;
        border-radius: 5px;
    }

    .products:hover .gallery-btn {
        opacity: 1;
    }

    .prev-btn-gal {
        left: 10px;
    }

    .next-btn-gal {
        right: 10px;
    }

    @media (max-width: 768px) {
        .gallery-btn {
            display: none;
        }
    }


    /* Products Section Entrance Animation */
    .products {
        opacity: 0;
        /* Hidden initially */
        transform: translateY(100px);
        /* Start lower for longer "rise" */
        animation: slideUpShop 3s ease-out forwards;
        /* Slower animation (3s) */
        animation-delay: 2.2s;
        /* Starts after intro fade (2s) */
    }

    @keyframes slideUpShop {
        0% {
            opacity: 0;
            transform: translateY(100px);
        }

        100% {
            opacity: 1;
            transform: translateY(0);
        }
    }

    /* Mobile specific adjustments */
    @media (max-width: 768px) {
        .products {
            animation-delay: 2s;
        }
    }

    /* Global Fade In Animation */
    @keyframes fadeInPage {
        0% {
            opacity: 0;
            transform: translateY(20px);
        }

        100% {
            opacity: 1;
            transform: translateY(0);
        }
    }

    .fade-in-page {
        opacity: 0;
        animation: fadeInPage 1.5s ease-out forwards;
    }

    /* Footer Styling Fixes */
    .footer {
        display: flex;
        flex-direction: column;
        align-items: center;
        /* Centers everything horizontally */
        justify-content: center;
        gap: 2rem;
        padding-bottom: 2rem;
    }

    .footer-links {
        flex-direction: column;
        gap: 1rem;
        margin-bottom: 0;
    }

    .footer-logo-container {
        margin-top: 2rem;
        opacity: 0.8;
        display: flex;
        justify-content: center;
        width: 100%;
    }

    .footer img {
        width: 60px;
        /* Increased from 30px */
        height: auto;
        display: block;
        margin: 0 auto;
        filter: none;
        /* Logo already white with shadows */
    }

    /* Ensure Hero/Intro Logo is also white */
    /* Ensure Hero/Intro Logo uses proper coloring */
    /* Logo emblem is already white with shadows, no filter needed */
    #intro-overlay img {
        filter: none;
    }

    /* Hero logo is back to symbol (logo-emblem.png). Already white with shadows, no filter needed. */
    .hero-logo img {
        filter: none;
        width: 100%;
        /* Fill container */
    }

    /* Update hero-logo container width to match content */
    .hero-logo {
        width: 220px;
        /* Symbol size */
    }

    /* Navbar Logo: valldea-text-logo.png is mostly white. Ensure no filter interferes. */
    .logo img {
        filter: none;
    }
}

/* GALLERY NAVIGATION ARROWS */
.gallery-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: #666;
    /* Grey */
    font-size: 3rem;
    /* Larger arrow char */
    font-weight: 300;
    cursor: pointer;
    z-index: 20;
    padding: 0 20px;
    transition: color 0.3s ease;
    font-family: var(--font-body);
}

.gallery-btn:hover {
    color: #fff;
}

.prev-btn-gal {
    left: 0;
}

.next-btn-gal {
    right: 0;
}

/* --- CART SIDEBAR --- */
.cart-sidebar {
    position: fixed;
    top: 0;
    right: 0;
    width: 350px;
    height: 100vh;
    height: 100dvh;
    /* Dynamic viewport height for mobile browsers */
    background: #000;
    z-index: 2005;
    /* Above Modal */
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
    border-left: 1px solid #333;
}

.cart-sidebar.open {
    transform: translateX(0);
}

.cart-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    height: 100dvh;
    /* Dynamic viewport height for mobile browsers */
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    z-index: 2004;
    /* Below Sidebar, Above content */
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease;
}

.cart-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Cart Header */
.cart-header {
    padding: 1.5rem;
    border-bottom: 1px solid #333;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cart-header h2 {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    margin: 0;
    color: #fff;
    text-transform: uppercase;
    display: flex;
    align-items: baseline;
    gap: 10px;
    white-space: nowrap;
    flex-wrap: nowrap;
}

@media (max-width: 400px) {
    .cart-header {
        padding: 1rem;
        /* Reduce padding to gain space */
    }

    .cart-header h2 {
        font-size: 0.9rem;
        /* Smaller font */
        gap: 4px;
        letter-spacing: -0.5px;
        /* Tighter spacing */
    }

    .cart-header-count {
        font-size: 0.8rem;
        white-space: nowrap;
        /* Force no wrap */
    }
}

.cart-header-count {
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: #888;
    text-transform: lowercase;
    font-weight: 300;
}

.close-cart {
    background: none;
    border: none;
    color: #fff;
    font-size: 1.5rem;
    cursor: pointer;
}

/* Cart Body */
.cart-body {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem;
}

.empty-cart-msg {
    color: #888;
    text-align: center;
    margin-top: 2rem;
    font-size: 0.9rem;
}

/* Cart Item */
.cart-item {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid #222;
    padding-bottom: 1rem;
}

.cart-item img {
    width: 70px;
    height: 90px;
    object-fit: cover;
    border-radius: 4px;
}

.cart-item-details {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.cart-item-title {
    font-size: 0.9rem;
    font-weight: 500;
    color: #fff;
    margin-bottom: 0.2rem;
}

.cart-item-meta {
    font-size: 0.8rem;
    color: #888;
}

.cart-item-price {
    font-size: 0.9rem;
    color: #fff;
    margin-top: 0.5rem;
}

/* Qty Control in Cart */
.cart-qty-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.cart-qty-btn {
    width: 20px;
    height: 20px;
    background: #333;
    border: none;
    color: #fff;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border-radius: 2px;
}

.cart-remove-btn {
    background: none;
    border: none;
    color: #ff4444;
    font-size: 0.8rem;
    cursor: pointer;
    margin-top: 5px;
    align-self: flex-start;
}

/* Cart Footer */
.cart-footer {
    padding: 1.5rem;
    padding-bottom: calc(1.5rem + env(safe-area-inset-bottom, 0px));
    border-top: 1px solid #333;
    background: #050505;
}

.cart-subtotal {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
    font-size: 1rem;
    font-weight: 500;
}

.checkout-btn {
    display: block;
    width: 100%;
    padding: 1rem;
    background: #fff;
    color: #000;
    border: none;
    font-family: var(--font-heading);
    font-weight: 700;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.3s ease;
    text-align: center;
    text-decoration: none;
    box-sizing: border-box;
}

.checkout-btn:hover {
    background: #ccc;
}

/* MOBILE CART - Bottom sheet style */
@media (max-width: 768px) {
    .cart-sidebar {
        width: 100%;
        height: auto !important;
        max-height: 70vh;
        /* Only take 70% of screen */
        top: auto !important;
        bottom: 0 !important;
        right: 0;
        left: 0;
        border-left: none;
        border-top: 1px solid #333;
        border-radius: 20px 20px 0 0;
        transform: translateY(100%);
        /* Slide from bottom */
        display: flex;
        flex-direction: column;
    }

    .cart-sidebar.open {
        transform: translateY(0);
    }

    .cart-header {
        border-radius: 20px 20px 0 0;
    }

    .cart-body {
        flex: 1;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        min-height: 100px;
        max-height: 40vh;
    }

    .cart-footer {
        flex-shrink: 0;
        padding: 1rem 1.5rem 1.5rem !important;
    }
}

/* FLYING ANIMATION PARTICLE */
.flying-img {
    position: fixed;
    z-index: 9999;
    width: 100px;
    /* Start size */
    height: auto;
    object-fit: cover;
    pointer-events: none;
    transition: all 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

/* Fix Chrome Autofill White Background */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
input:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 30px #000 inset !important;
    -webkit-text-fill-color: #fff !important;
    transition: background-color 5000s ease-in-out 0s;
}

/* INTRO FADE IN ANIMATION */
@keyframes introFadeIn {
    0% {
        opacity: 0;
    }

    100% {
        opacity: 1;
    }
}

/* MOBILE HOMEPAGE ANIMATION */
@media (max-width: 768px) {
    body.home-page .page-content {
        opacity: 0;
        transform: translateY(50px);
        transition: opacity 1.5s ease-out, transform 1.5s ease-out;
    }

    body.home-page .page-content.mobile-visible {
        opacity: 1;
        transform: translateY(0);
    }
}