@import url('https://fonts.googleapis.com/css2?family=Oswald:wght@200..700&display=swap');

:root {
    --title-font: "Oswald", sans-serif;
    --main-font: "Oswald", sans-serif;

    /* Centralized Title Font Sizes */
    --title-fs-brand-main: clamp(3.2rem, 10vw, 6rem);
    /* Adjusted to a reasonable size */
    --title-fs-brand-sticky: 1.4rem;
    --title-fs-nav: 0.85rem;
    --title-fs-footer: 0.75rem;

    /* Standard Font Sizes */
    --fs-lg: 1.1rem;
    --fs-md: .85rem;
    --fs-sm: 0.65rem;

    --fs-pdp-lg: 1.3rem;
    --fs-pdp-md: 1rem;
    --fs-pdp-sm: .75rem;
}





/* Base Global Typography */
body,
html {
    font-family: var(--main-font);
    font-weight: 300;
    color: #111;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    line-height: 1.5;
}


/* =========================================
   2. GLOBAL RESET & BASE STYLES
   ========================================= */


/* Universal Reset */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* Base Setting (Default: Centers Homepage Character) */
body,
html {
    width: 100%;
    height: 100%;
    /* Fallback */
    height: 100dvh;
    /* Dynamic viewport height for mobile browser bars */
    background-color: #fafafa;

    /* Layout Logic for Homepage */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    /* Push header up and nav down */

    /* Prevent scrolling on Homepage */
    overflow: hidden;

    /* Better support for mobile browsers and safe areas */
    padding-top: env(safe-area-inset-top, 0);
    padding-bottom: env(safe-area-inset-bottom, 0);
}

/* Sub-Page Override (Switches to standard block layout for Shop/Product pages) */
body.sub-page {
    display: block !important;
    align-items: normal !important;
    overflow-y: auto !important;
    /* Enable scrolling for shop/product pages */
}


/* =========================================
   3. HEADER COMPONENTS
   ========================================= */


/* --- A. MAIN HEADER (Homepage) --- */
/* The homepage header is now .home-header (see Section 4A).
   These rules previously targeted header:not(.sticky-header) but
   that interfered with other pages. Styling is now in Section 4. */

#page-title {
    font-family: var(--title-font) !important;
    font-size: var(--fs-lg);
    text-transform: uppercase;
    letter-spacing: 3px;
}

/* --- B. STICKY HEADER (Shop & Product Pages) --- */
/* Fixed position, white background, grid layout */
header.sticky-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 2000;
    background-color: transparent;
    /* Changed from slight opacity white */
    padding: 10px 30px;
    border: none;
    box-shadow: none;

    /* Grid Layout: [Left Controls] [Center Logo] [Right Search/Cart] */
    display: grid;
    /* UPDATE: Force 3 symmetrical columns */
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
}

/* Header Left: Holds Mobile Buttons */
.header-controls-left {
    grid-column: 1;
    display: flex;
    gap: 20px;
    align-items: center;
    justify-content: flex-start;
}

/* Center Column: Logo Link */
header.sticky-header .logo-link {
    grid-column: 2;
    text-align: center;
    text-decoration: none !important;
    color: #000000;
    /* Ensure it doesn't wrap */
    white-space: nowrap;
}

header.sticky-header h1 {
    font-family: var(--title-font) !important;
    font-size: 1.4rem !important;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin: 0;
    display: inline-block;
    padding: 3px;
    font-weight: 500;
}

/* Right Column: Search & Cart Wrapper */
.header-search-wrapper {
    grid-column: 3;
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

/* Cart Button */
#header-cart-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-family: var(--main-font);
    font-weight: 500;
    letter-spacing: 1px;
    margin-left: 15px;
    font-size: 0.75rem;
    text-transform: uppercase;
    transition: opacity 0.2s;
    padding: 5px 8px;
    /* Added padding for larger touch target */
}

/* --- C. SEARCH INPUT STYLING --- */

/* Standard Header Input (Shop Pages) */
.search-input {
    border: none;
    border-bottom: 0px solid transparent;
    background: transparent;
    font-family: var(--main-font);
    font-size: 0.75rem;
    font-weight: 400;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: #000;
    width: 120px;
    padding: 3px;
    outline: none;
    text-align: center;
    transition: 0.3s;
}

.search-input::placeholder {
    color: #000;
    opacity: 1;
}

.search-input:focus,
.search-input:hover {
    border-bottom: 1px solid #000;
}

/* Homepage Nav Specific Input (Bottom Nav) */
.nav-search-input {
    font-family: var(--title-font) !important;
    font-size: var(--title-fs-nav);
    text-transform: uppercase;
    border: none;
    background: transparent;
    text-align: center;
    width: 100px;
    cursor: text;
    color: #000;
    letter-spacing: 1px;
}

.nav-search-input:focus {
    outline: none;
    border-bottom: 1px solid #000;
}



/* =========================================
4. HOMEPAGE TITLE AND CHARACTER AREA
========================================= */


:root {
    --bg-color: #FAFAFA;
    --glitch-text: #111;
    --glitch-red: #ff003c;
    --glitch-blue: #00f0ff;
}

.home-header {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    /* Increased top padding for better spacing */
    padding-top: calc(env(safe-area-inset-top, 20px) + 40px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    pointer-events: none;
    user-select: none;
    z-index: 100;
}

/* --- SHARED STYLES --- */
.home-title,
.home-subtitle {
    font-family: var(--title-font);
    font-weight: 400;
    text-transform: uppercase;
    position: relative;
    color: var(--glitch-text);
    margin: 0;
    display: block;
    width: fit-content;
    letter-spacing: 0.08em;
    /* Refined tracking for Oswald */

    /* PERFORMANCE */
    transform: translate3d(0, 0, 0);
    backface-visibility: hidden;
    perspective: 1000px;
    will-change: transform, opacity;

    /* ANIMATION */
    animation: struggle-to-on 4.5s infinite steps(1);
}

.home-title {
    font-size: clamp(2.1rem, 9vw, 3.1rem);
    /* Scaled up minimum for mobile */
    letter-spacing: 1.5px;
    line-height: 0.95;
    margin-bottom: 5px;
    font-weight: 500;
}

.home-subtitle {
    font-size: 0.85rem;
    /* Smaller subtitle for balanced look */
    letter-spacing: 4px;
    font-weight: 300;
}

/* --- GHOST LAYERS --- */
.home-title::before,
.home-title::after,
.home-subtitle::before,
.home-subtitle::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    pointer-events: none;
    /* Added for safety */
    will-change: transform, opacity;
}

/* Red Channel */
.home-title::before,
.home-subtitle::before {
    color: var(--glitch-red);
    z-index: -1;
    animation: flash-red 4.5s infinite steps(1);
}

/* Blue Channel */
.home-title::after,
.home-subtitle::after {
    color: var(--glitch-blue);
    z-index: -2;
    animation: flash-blue 4.5s infinite steps(1);
}

/* --- HOME ANIMATIONS (Maintained vibe, optimized) --- */

@keyframes struggle-to-on {
    0% {
        opacity: 0;
        transform: translate3d(0, 0, 0);
    }

    /* Spark Phase */
    5% {
        opacity: 0.5;
        transform: translate3d(-3px, 0, 0) skew(-20deg);
    }

    6% {
        opacity: 0;
        transform: translate3d(0, 0, 0);
    }

    8% {
        opacity: 0.7;
        transform: translate3d(3px, 0, 0) skew(10deg);
    }

    9% {
        opacity: 0;
    }

    /* Ignition Phase */
    35% {
        opacity: 1;
        transform: translate3d(0, 0, 0) skew(40deg) scaleY(0.4);
    }

    36% {
        opacity: 1;
        transform: translate3d(-5px, 0, 0) skew(-10deg) scaleY(1.2);
    }

    37% {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }

    /* Stable Phase */
    88% {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }

    /* Crash Phase */
    89% {
        opacity: 0.8;
        transform: translate3d(0, 0, 0) scale(1.1, 0.1);
    }

    90% {
        opacity: 0;
    }

    100% {
        opacity: 0;
    }
}

@keyframes flash-red {
    0% {
        opacity: 0;
    }

    /* Spark Sync */
    5% {
        opacity: 0.6;
        transform: translate3d(5px, 0, 0) scaleY(0.2);
    }

    6% {
        opacity: 0;
    }

    /* Ignition Sync */
    35% {
        opacity: 1;
        transform: translate3d(-10px, 0, 0) skew(20deg);
    }

    36% {
        opacity: 0.5;
        transform: translate3d(10px, 0, 0) skew(-10deg);
    }

    37% {
        opacity: 0;
        transform: translate3d(0, 0, 0);
    }

    100% {
        opacity: 0;
    }
}

@keyframes flash-blue {
    0% {
        opacity: 0;
    }

    /* Spark Sync */
    8% {
        opacity: 0.6;
        transform: translate3d(-5px, 0, 0) scaleY(1.5);
    }

    9% {
        opacity: 0;
    }

    /* Ignition Sync */
    35% {
        opacity: 0.8;
        transform: translate3d(0, 5px, 0) scale(1.2, 0.1);
    }

    36% {
        opacity: 0;
    }

    /* Crash Sync */
    89% {
        opacity: 0.5;
        transform: translate3d(0, -5px, 0) skew(20deg);
    }

    90% {
        opacity: 0;
    }

    100% {
        opacity: 0;
    }
}


/* --- STICKY HEADER GLITCH (REFINED & FASTER) --- */
/* Total duration reduced to 3s. Stable state hit at 30% mark (~0.9s real-time) */

.sticky-glitch {
    position: relative;
    display: inline-block;
    animation: sticky-struggle 3s steps(1) forwards;
    will-change: transform, opacity;
}

.sticky-glitch::before,
.sticky-glitch::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    pointer-events: none;
    will-change: transform, opacity;
}

.sticky-glitch::before {
    color: var(--glitch-red);
    z-index: -1;
    animation: sticky-red 3s steps(1) forwards;
}

.sticky-glitch::after {
    color: var(--glitch-blue);
    z-index: -2;
    animation: sticky-blue 3s steps(1) forwards;
}

@keyframes sticky-struggle {
    0% {
        opacity: 0;
    }

    /* 1. Quick Spark (Immediate) */
    2% {
        opacity: 0.5;
        transform: translate3d(-2px, 0, 0) skew(-15deg);
    }

    4% {
        opacity: 0;
    }

    6% {
        opacity: 0.8;
        transform: translate3d(2px, 0, 0) skew(10deg);
    }

    8% {
        opacity: 0;
    }

    /* 2. Failed Boot Attempt (Shortened gap) */
    15% {
        opacity: 0;
    }

    16% {
        opacity: 1;
        transform: translate3d(-4px, 0, 0) skew(-20deg) scaleY(1.4);
    }

    18% {
        opacity: 0;
    }

    /* 3. Successful Boot (Happens much earlier now: at 28%) */
    28% {
        opacity: 1;
        transform: translate3d(0, 0, 0) skew(40deg) scaleY(0.4);
    }

    29% {
        opacity: 1;
        transform: translate3d(-5px, 0, 0) skew(-10deg) scaleY(1.2);
    }

    /* 4. Stabilize */
    30% {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }

    100% {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

@keyframes sticky-red {
    0% {
        opacity: 0;
    }

    /* Spark Sync (2%) */
    2% {
        opacity: 0.6;
        transform: translate3d(4px, 0, 0) scaleY(0.3);
    }

    4% {
        opacity: 0;
    }

    /* Fail Sync (16%) */
    16% {
        opacity: 1;
        transform: translate3d(-8px, 0, 0) skew(20deg);
    }

    18% {
        opacity: 0;
    }

    /* Success Sync (28%) */
    28% {
        opacity: 0.8;
        transform: translate3d(5px, 0, 0) skew(-15deg);
    }

    30% {
        opacity: 0;
    }

    100% {
        opacity: 0;
    }
}

@keyframes sticky-blue {
    0% {
        opacity: 0;
    }

    /* Spark Sync (6%) */
    6% {
        opacity: 0.6;
        transform: translate3d(-4px, 0, 0) scaleY(1.5);
    }

    8% {
        opacity: 0;
    }

    /* Fail Sync (16%) */
    16% {
        opacity: 0.8;
        transform: translate3d(0, 4px, 0) scale(1.3, 0.2);
    }

    18% {
        opacity: 0;
    }

    /* Success Sync (28%) */
    28% {
        opacity: 0.7;
        transform: translate3d(-5px, 0, 0) skew(10deg);
    }

    30% {
        opacity: 0;
    }

    100% {
        opacity: 0;
    }
}

/* --- B. STAGE AREA --- */
.stage {
    flex: 1;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    /* Lowered to sit slightly above nav */
    overflow: hidden;
    padding-bottom: 30px;
    /* Shifted character up on desktop */
    padding-top: 50px;
    /* Increased space from title */
    transition: all 0.3s ease;
}

@media (max-width: 768px) {
    .stage {
        padding-top: 90px !important;
        /* Increased space from brand name */
        padding-bottom: 20px !important;
        /* Reduced space from nav to shift character down */
        display: flex !important;
        justify-content: center !important;
        align-items: flex-end !important;
    }

    .character-box {
        /* Maximize size on mobile while respecting header/nav */
        height: 90dvh !important;
        /* Increased size for mobile */
        max-height: calc(100dvh - 135px) !important;
        /* Reduced max-height to shift character down */
        margin-top: 0 !important;
    }

    .home-nav {
        padding: 10px 25px calc(env(safe-area-inset-bottom, 0px) + 10px) !important;
        /* Reduced bottom padding to let nav sit lower */
    }
}

/* --- C. CHARACTER LAYOUT --- */
.character-box {
    position: relative;
    height: 85vh;
    max-height: calc(100vh - 170px);
    aspect-ratio: 412 / 754;
    margin-top: 40px;
    /* Extra distance from brand name */
}

.base-character {
    width: 100%;
    height: 100%;
    display: block;
}

/* --- D. SVG CLOTHING OVERLAYS --- */
.clothing-link {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.clothing-link path {
    pointer-events: auto !important;
    cursor: pointer;
    fill: #000 !important;
}

.clothing-link:hover {
    opacity: 0.3 !important;
}

/* --- E. HOME NAVIGATION (Bottom Buttons) --- */
.home-nav {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    padding: 10px 25px calc(env(safe-area-inset-bottom, 0px) + 20px);
    z-index: 100;
}

.nav-btn {
    font-family: var(--title-font) !important;
    text-decoration: none;
    color: #000;
    font-size: clamp(0.5rem, 3vw, 0.75rem);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    background: transparent;
    cursor: pointer;
    display: inline-block;
    position: relative;
    color: #111;
    /* softer base black */
    transition: all 0.25s ease-out;
}

/* Standard Nav Buttons (Polished Monospace) */
.nav-btn {
    letter-spacing: 0.05em;
    font-weight: 400;
}

.nav-btn:hover {
    opacity: 0.7;
    transform: translateY(-1px);
}




/* =========================================
   5. SHARED LAYOUTS (WRAPPERS)
   ========================================= */


/* --- A. SHOP PAGE WRAPPER (Symmetrical) --- */
.sub-page-wrapper {
    display: grid;
    grid-template-columns: 140px 1fr 140px;
    /* Equal sidebar widths */
    width: 100%;
    max-width: 100%;
    gap: 30px;
    margin: 0 auto;
    padding: 60px 30px 0;
}

.content-area {
    width: 100%;
}

/* --- B. PRODUCT DETAIL WRAPPER (Asymmetrical) --- */
.product-page-wrapper {
    display: grid;
    grid-template-columns: 140px 1fr 350px;
    /* Consistent left sidebar */
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    padding: 60px 30px 0;
    gap: 40px;
}

/* --- CATEGORY TITLES (SHOP PAGE) --- */
.sub-header {
    width: 100%;
    padding: 10px 0 15px;
    text-align: left;
    padding-left: 40px;
    grid-column: 1 / -1;
}

.sub-header h1 {
    font-family: var(--title-font) !important;
    font-size: 1.4rem;
    /* Standard title size for shop category */
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin: 0;
}

/* =========================================
   6. SIDEBAR & FILTERING SYSTEM
   ========================================= */

/* --- A. UNIVERSAL SIDEBAR BASICS --- */
.sidebar {
    position: sticky;
    top: 65px;
    height: fit-content;
    z-index: 10;
    width: 100%;
    /* Fill the 140px column */
    box-sizing: border-box;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    width: 100%;
}

/* --- B. MAIN NAVIGATION LINKS (Home, Shop All) --- */
.sidebar-nav-top {
    display: block;
    font-family: var(--main-font);
    font-size: var(--fs-md);
    font-weight: 500;
    text-transform: uppercase;
    color: #000;
    letter-spacing: 1.5px;
    margin-bottom: 15px;
    text-decoration: none;
    transition: opacity 0.2s ease;
    cursor: default;
}

a.sidebar-nav-top:hover {
    opacity: 0.6;
    cursor: pointer;
}

/* Universal spacing for Home link in both sidebar modes */
.sidebar-nav-top[href="index.html"] {
    margin-bottom: 45px;
    /* More separation between Home and Shop All */
}

/* Special spacing for Home link */
.product-page-wrapper .sidebar-nav a[href="index.html"] {
    font-weight: 600 !important;
    margin-bottom: 45px;
    /* More separation between Home and Shop All */
}

/* --- C. SECTION LABELS (Categories, Brands, etc.) --- */
.sidebar-label {
    display: block;
    font-family: var(--main-font);
    font-size: var(--fs-md);
    font-weight: 500;
    text-transform: uppercase;
    color: #000;
    letter-spacing: 1.5px;
    margin-bottom: 15px;
    text-decoration: none;
    transition: opacity 0.2s ease;
    cursor: default;
}

/* Subsequent labels get breathing room */
.sidebar-label {
    margin-top: 35px;
}

.sidebar-sub-label {
    display: block;
    font-family: var(--main-font);
    font-size: var(--fs-sm);
    font-weight: 300;
    text-transform: uppercase;
    color: #000;
    opacity: 0.6;
    letter-spacing: 0.5px;
    margin-top: 35px;
    /* More space to prevent touching grid buttons */
    margin-bottom: 12px;
    cursor: default;
    text-align: inherit;
    line-height: 1.5;
}

/* --- D. SIDEBAR LINKS (Categories, Brands, Sort) --- */
/* These are the main links that appear in the sidebar */
.sidebar-link,
.sort-link,
summary {
    display: block;
    font-family: var(--main-font);
    font-size: var(--fs-sm);
    font-weight: 300;
    text-transform: uppercase;
    color: #000;
    text-decoration: none;
    line-height: 1.5;
    letter-spacing: 0.5px;
    padding: 8px 0;
    margin-bottom: 15px;
    cursor: pointer;
    transition: opacity 0.2s ease;
    list-style: none;
    outline: none;
}

.sort-link:hover,
summary:hover {
    opacity: 0.6;
}

/* Accordion Specifics */
details {
    width: 100%;
    margin-bottom: 0px;
    /* Remove extra margin to match direct brand links */
}

summary::-webkit-details-marker {
    display: none;
}

.accordion-content {
    display: flex;
    flex-direction: column;
    padding-left: 12px;
    margin-bottom: 15px;
    border-left: 1px solid #eeeeee;
}

/* --- E. ACCORDION SYSTEM (For Categories dropdown) --- */
/* Categories are wrapped in details/summary for accordion functionality */

/* --- F. ACCORDION SUB-ITEMS (Sub-categories, Types) --- */
/* These are the items inside the accordion dropdown */
.lvl-2,
.lvl-3 {
    font-family: var(--main-font);
    font-size: var(--fs-sm);
    font-weight: 300;
    color: #000;
    display: block;
    padding: 3px 0;
    margin-bottom: 4px;
    text-decoration: none;
    cursor: pointer;
    transition: color 0.2s;
    text-transform: capitalize;
    letter-spacing: 0.3px;
    line-height: 1.5;
    /* Different style for sub-items */
}

.lvl-2:hover,
.lvl-3:hover {
    text-decoration: underline;
}

/* --- B. LEFT SIDEBAR (CATEGORIES, BRANDS) --- */
.left-sidebar {
    padding-left: 0;
    /* Handled by wrapper */
}

.left-sidebar .sidebar-nav {
    align-items: flex-start;
    text-align: left;
}

.left-sidebar .sidebar-label {
    text-align: left;
}

/* --- C. RIGHT SIDEBAR (SORT, SIZES) --- */
.right-sidebar {
    padding-right: 0;
    /* Handled by wrapper */
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    text-align: right;
}

.right-sidebar .sidebar-nav {
    align-items: flex-end;
    text-align: right;
}

.right-sidebar .sidebar-label {
    text-align: right;
    width: auto;
}

/* C1. SORT SECTION Specifics */
#sort-sidebar {
    margin-bottom: 40px;
}

#sort-sidebar .sort-link {
    text-align: right;
    width: 100%;
}

/* C2. SIZES SECTION Specifics */
#right-sidebar-sizes {
    margin-top: 20px;
}

.size-grid-container {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    /* Slightly more gap */
    width: 90px;
    /* Slightly wider for the new padding */
    margin-top: 10px;
    align-self: flex-end;
}

.sidebar-size-link {
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--main-font);
    font-size: var(--fs-sm);
    font-weight: 500;
    border: none;
    background: #f7f7f7;
    /* Very light subtle background */
    padding: 8px 4px;
    text-decoration: none;
    color: #000;
    transition: all 0.2s ease;
}

.sidebar-size-link:hover {
    background: #000;
    color: #fff;
}

.sidebar-size-link.active-bold {
    background: #000;
    color: #fff;
    border: none;
}

.active-bold {
    font-weight: 900 !important;
}

/* --- D. FILTER CHIPS --- */
.filter-chip {
    display: inline-flex;
    align-items: center;
    font-family: var(--main-font);
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    padding: 8px 16px;
    border: 1px solid #e0e0e0;
    border-radius: 100px;
    cursor: pointer;
    background: #fff;
    margin-left: 10px;
    transition: all 0.2s ease;
    line-height: 1.5;
    /* Larger for better touch targets */
}

.filter-chip span {
    margin-left: 8px;
    font-size: 0.8rem;
    /* Larger X for easier removal */
}

.filter-chip:hover {
    background: #000;
    color: #fff;
    border-color: #000;
}

/* --- E. ANIMATIONS --- */
@keyframes sweep {
    0% {
        opacity: 0;
        transform: translateY(-5px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

details[open] summary~* {
    animation: sweep 0.25s ease-in-out;
}


/* =========================================
   7. PRODUCT GRID & CARDS
   ========================================= */

/* SKELETON UI & INFINITE SCROLL */
.product-skeleton {
    display: flex;
    flex-direction: column;
    width: 100%;
    margin-bottom: 30px;
}

.skeleton-image {
    width: 100%;
    aspect-ratio: 2 / 3;
    background: #eeeeee;
    position: relative;
    overflow: hidden;
}

.skeleton-text {
    height: 12px;
    background: #eeeeee;
    margin-top: 15px;
    width: 60%;
    position: relative;
    overflow: hidden;
}

.skeleton-shimmer::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.5), transparent);
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    0% {
        transform: translateX(-100%);
    }

    100% {
        transform: translateX(100%);
    }
}

#sentinel {
    grid-column: 1 / -1;
    height: 1px;
    width: 100%;
    margin-bottom: 50px;
}


.product-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    padding-left: 10px;
    /* Reduced since wrapper handles edge spacing */
    padding-right: 10px;
    gap: 20px;
    width: 100%;
}

.product-image-wrapper {
    width: 100%;
    aspect-ratio: 2 / 3;
    background-color: #fafafa;
    overflow: hidden;
    position: relative;
    border-radius: 2px;
    box-shadow: none;
}

.product-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    /* Prevents cropping */
    display: block;
}

.product-info {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 55px 0 45px;
    padding-left: 20px;
    padding-right: 20px;
    font-family: var(--main-font);
    font-weight: 300;
    font-size: var(--fs-sm);
    letter-spacing: 0.3px;
    text-transform: uppercase;
    line-height: 1.6;
    color: #000;
}

.product-brand {
    font-family: var(--main-font);
    font-size: var(--fs-md) !important;
    font-weight: 600 !important;
    text-transform: uppercase;
    color: #000;
    letter-spacing: 0.12em;
    display: block;
    margin-bottom: 4px;
}

.product-name {
    font-size: var(--fs-md);
    font-weight: 300;
    text-align: left;
    max-width: 100%;
    letter-spacing: 0.5px;
    color: #666;
    text-transform: capitalize;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.5;
    max-height: 3em;
    margin-bottom: 4px;
}

.info-left {
    display: flex;
    flex-direction: column;
    max-width: 85%;
    min-height: 80px;
    /* Ensure consistent height for price alignment */
}

.info-right {
    display: flex;
    flex-direction: column;
    text-align: right;
    justify-content: flex-start;
    min-height: 80px;
    /* Match info-left height for price alignment */
}

.product-size {
    font-size: 0.8rem;
    color: #000;
    font-weight: 500;
    /* Medium weight */
    letter-spacing: 1px;
}

.product-price {
    font-size: var(--fs-md);
    color: #000;
    font-weight: 400;
    letter-spacing: 0px;
    display: block;
}

/* =========================================
   8. PRODUCT DETAIL PAGE (PDP) - UPDATED
   ========================================= */

.product-gallery {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

.gallery-stage {
    max-width: 500px;
    width: 100%;
    margin: 0 auto;
    position: relative;
    aspect-ratio: 2 / 3;
    /* Matches standard 2:3 product import ratio */
    /* CHANGED: Set to visible so arrows can sit outside the box */
    overflow: visible;
    box-shadow: none;
}

.main-stage-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    /* Prevents cropping */
    display: block;
    transition: opacity 0.2s ease-in-out;
    opacity: 1;
    /* Ensure image respects corners even with overflow visible */
    border-radius: 2px;
}

.main-stage-img.fade-out {
    opacity: 0.8;
}

/* --- DESKTOP NAVIGATION ARROWS --- */
.gallery-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 2rem;
    /* Larger for better clickability */
    color: #000;
    opacity: 0.4;
    transition: all 0.3s ease;
    z-index: 10;
    padding: 20px;
    /* Large touch target */
}

.gallery-nav-btn:hover {
    opacity: 1;
    transform: translateY(-50%) scale(1.1);
}

/* Push arrows outside the container */
.gallery-nav-btn.prev {
    left: -70px;
}

.gallery-nav-btn.next {
    right: -70px;
}

/* --- THUMBNAILS (PREMIUM LIFT ANIMATION) --- */
.thumbnail-strip {
    display: flex;
    justify-content: flex-start;
    gap: 15px;
    /* Increased gap slightly */
    margin-top: 30px;
    flex-wrap: nowrap;
    padding-bottom: 15px;
    /* Space for the shadow drop */
    overflow-x: auto;
    scroll-behavior: smooth;
    max-width: 635px;
    /* exactly 10 previews on desktop */
    margin-left: auto;
    margin-right: auto;
    /* Hide scrollbar */
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.thumbnail-strip::-webkit-scrollbar {
    display: none;
}

.thumb-btn {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    /* Transition for transform and shadow */
    transition: transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1), opacity 0.3s ease;
    opacity: 0.6;
}

.thumb-btn img {
    width: 50px;
    height: 50px;
    object-fit: cover;
    display: block;
    border-radius: 2px;
    /* Base shadow */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    transition: box-shadow 0.3s ease;
}

.thumb-btn:hover {
    opacity: 0.9;
}

/* Active State: Lift and Float */
.thumb-btn.active-thumb {
    opacity: 1;
    transform: translateY(-5px);
    /* The Lift */
}

.thumb-btn.active-thumb img {
    /* The premium shadow effect */
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
    border: none;
    /* Removed the black border */
}

@media (max-width: 768px) {
    .gallery-nav-btn {
        display: none !important;
    }

    .gallery-stage {
        /* On mobile, we might want to contain it if it's full width */
        overflow: hidden;
        box-shadow: none;
        /* Flatter look on mobile */
    }

    .thumbnail-strip {
        max-width: 375px;
        /* exactly 6 previews on mobile */
        padding-bottom: 0px;
    }
}

.product-page-wrapper .left-sidebar {
    position: sticky;
    top: 80px;
    padding-top: 0px;
}

.product-page-wrapper .sidebar-nav a[href="index.html"] {
    font-weight: 600 !important;
    margin-bottom: 45px;
    /* More separation between Home and Shop All */
}

.detail-brand {
    font-family: var(--main-font);
    font-size: var(--fs-pdp-md) !important;
    font-weight: 700 !important;
    text-transform: uppercase;
    color: #000;
    letter-spacing: 2.5px;
    display: block;
    margin-top: 200px;
    margin-bottom: 5px;
}

.detail-title {
    font-family: var(--title-font) !important;
    font-size: var(--fs-pdp-lg);
    text-transform: uppercase;
    margin-bottom: 5px;
    margin-top: 0px;
    font-weight: 400;
    letter-spacing: 0px;
    color: #000;
}

.detail-price {
    font-size: var(--fs-pdp-md);
    color: #000;
    margin-bottom: 20px;
    font-weight: 400;
    letter-spacing: 2.5px;
}

.detail-description {
    font-size: var(--fs-pdp-sm);
    line-height: 1.8;
    color: #000;
    margin-bottom: 20px;
    letter-spacing: 0.5px;
}

.size-selector {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.size-btn {
    border: 1px solid #000;
    background: transparent;
    padding: 8px 12px;
    cursor: pointer;
    font-family: var(--main-font);
    text-transform: uppercase;
    font-size: 0.8rem;
    transition: all 0.2s ease;
}

.size-btn:hover,
.size-btn.selected {
    background: #000;
    color: #ffffff;
}

.add-cart-btn {
    background-color: #000000;
    color: #ffffff;
    border: none;
    padding: 12px 8px;
    width: 100%;
    text-transform: uppercase;
    font-family: var(--main-font);
    font-size: 0.8rem;
    letter-spacing: 2px;
    cursor: pointer;
    transition: opacity 0.3s;
}

.add-cart-btn:hover {
    opacity: 0.8;
}

/* --- PRODUCT TECHNICALITIES (ACCORDIONS) --- */
.product-technicalities {
    margin-top: 50px;
    border: none;
}

.product-technicalities details {
    border: none;
    width: 100%;
    margin-bottom: 15px;
    /* Added space between closed dropdowns */
}

.product-technicalities details:last-of-type {
    margin-bottom: 0;
}

.product-technicalities summary {
    padding: 10px 0;
    font-family: var(--main-font);
    font-size: var(--fs-pdp-sm);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    list-style: none;
    transition: opacity 0.2s ease;
}

.product-technicalities summary:hover {
    opacity: 0.6;
}

.product-technicalities summary::-webkit-details-marker {
    display: none;
}

/* Custom Chevron Arrow Icon */
.product-technicalities summary::after {
    content: '';
    width: 8px;
    height: 8px;
    border-right: 1.5px solid #000;
    border-bottom: 1.5px solid #000;
    transform: rotate(45deg);
    /* Points Down */
    transition: transform 0.3s ease;
    display: inline-block;
    margin-right: 5px;
    margin-top: -4px;
    /* Adjust for centering */
}

.product-technicalities details[open] summary::after {
    transform: rotate(-135deg);
    /* Points Up */
}

.product-technicalities .tech-content {
    padding-bottom: 25px;
    font-family: var(--main-font);
    font-size: var(--fs-pdp-sm);
    line-height: 1.6;
    color: #444;
    max-width: 95%;
    text-transform: none;
    /* Keep text natural but clean */
    letter-spacing: 0.5px;
}

.product-technicalities details[open] .tech-content {
    animation: techFadeIn 0.4s ease-out;
}

@keyframes techFadeIn {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}


@media (max-width: 900px) {
    .product-technicalities {
        margin-top: 30px;
    }
}



/* =========================================
   9. CART DRAWER UI
   ========================================= */

#sidebar-dimmer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(2px);
    z-index: 3000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

#sidebar-dimmer.active {
    opacity: 1;
    pointer-events: all;
}

.cart-drawer {
    position: fixed;
    top: 0;
    right: -660px;
    width: 650px;
    height: 100%;
    background: #fafafa;
    z-index: 5000;
    /* Highest priority drawer */
    display: flex;
    flex-direction: column;
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.1);
    transition: right 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.cart-drawer.active {
    right: 0;
}

.cart-header {
    padding: 30px;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fafafa;
}

.cart-title {
    font-family: var(--title-font) !important;
    font-size: var(--fs-lg);
    font-weight: 400;
    letter-spacing: 3px;
    text-transform: uppercase;
}

.close-cart-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.4rem;
    font-family: var(--main-font);
    font-weight: 400;
    color: #000;
    transition: opacity 0.2s;
    padding: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-sidebar-btn {
    display: none;
    /* Hidden on Desktop */
}

.mobile-only {
    display: none !important;
}

.desktop-only {
    display: inline-block;
}

.close-cart-btn:hover {
    opacity: 0.6;
}

.cart-items-wrapper {
    flex: 1;
    overflow-y: auto;
    padding: 0 30px;
}

.cart-item {
    display: flex;
    gap: 20px;
    padding: 30px 0;
    border-bottom: 1px solid #f0f0f0;
}

.cart-item:last-child {
    border-bottom: none;
}

.cart-item-img {
    width: 90px;
    aspect-ratio: 2 / 3;
    background: #f9f9f9;
    flex-shrink: 0;
    position: relative;
    overflow: hidden;
}

.cart-item-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.cart-item:hover .cart-item-img img {
    transform: scale(1.05);
}

.cart-item-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    font-family: var(--main-font);
}

.cart-info-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 5px;
}

.cart-item-name {
    font-size: var(--fs-md);
    font-weight: 400;
    text-transform: uppercase;
    line-height: 1.4;
    max-width: 280px;
    letter-spacing: 0px;
}

.cart-item-price {
    font-size: var(--fs-md);
    color: #000;
    font-weight: 600;
    letter-spacing: 2.5px;
}

.cart-info-bottom {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}

.cart-item-size {
    font-size: var(--fs-sm);
    color: #000;
    text-transform: uppercase;
    letter-spacing: 0px;
}

.remove-btn {
    background: none;
    border: none;
    font-size: var(--fs-sm);
    font-family: var(--main-font);
    color: #000;
    text-transform: uppercase;
    text-decoration: underline;
    cursor: pointer;
    padding: 0;
    transition: color 0.2s;
}

.remove-btn:hover {
    color: #d00000;
}

.cart-footer {
    padding: 30px;
    border-top: 1px solid #f0f0f0;
    background: #fafafa;
    margin-top: auto;
}

.cart-total-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    font-family: var(--main-font);
}

.cart-total-label {
    font-size: var(--fs-md);
    text-transform: uppercase;
    color: #000;
    font-weight: 600;
    letter-spacing: 2.5px;
}

.cart-total-amount {
    font-size: var(--fs-lg);
    font-weight: 400;
    letter-spacing: 2.5px;
}

.checkout-btn {
    width: 100%;
    background: #000000;
    color: #ffffff;
    border: 1px solid #000000;
    padding: 18px;
    font-family: var(--main-font);
    letter-spacing: 2px;
    text-transform: uppercase;
    font-size: var(--fs-sm);
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
}

.checkout-btn:hover {
    background-color: #333333;
    transform: translateY(-1px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

@media (max-width: 600px) {
    .cart-drawer {
        width: 100%;
        right: -100%;
    }

    .cart-header,
    .cart-items-wrapper,
    .cart-footer {
        padding: 20px;
    }

    .cart-item {
        padding: 20px 0;
    }

    .cart-item-name {
        max-width: 200px;
        font-size: 11px;
    }
}


/* =========================================
   10. MOBILE & RESPONSIVE UTILITIES
   ========================================= */

/* --- A. ICON BUTTON STYLES (New) --- */

/* Reset button default styles for icon containers */
.icon-btn {
    background: transparent;
    border: none;
    padding: 5px;
    /* Touch target size */
    cursor: pointer;
    display: none;
    /* Hidden on Desktop by default */
    align-items: center;
    justify-content: center;
}

/* Hover state only for desktop testing or slight feedback */
.icon-btn:hover {
    opacity: 0.6;
}

/* 1. Hamburger Icon (Menu) */
.icon-burger {
    display: block;
    width: 22px;
    height: 14px;
    position: relative;
    border-top: 2px solid #000;
    border-bottom: 2px solid #000;
}

.icon-burger::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    height: 2px;
    background: #000;
    transform: translateY(-50%);
}

/* 2. Sliders Icon (Sort) */
.icon-sliders {
    display: block;
    width: 22px;
    height: 16px;
    position: relative;
}

/* Slider Lines */
.icon-sliders::before,
.icon-sliders::after {
    content: '';
    position: absolute;
    left: 0;
    width: 100%;
    height: 1px;
    background: #000;
}

.icon-sliders::before {
    top: 3px;
}

.icon-sliders::after {
    bottom: 3px;
}

/* Slider Dots (Pseudo-elements of the icon span) */
/* Requires a slight trick using box-shadow to create dots without extra HTML,
   or using background-image. Let's use radial-gradient for cleanest CSS only solution */
.icon-sliders {
    background-image:
        radial-gradient(circle, #000 2px, transparent 2.5px),
        radial-gradient(circle, #000 2px, transparent 2.5px);
    background-position:
        30% 4px,
        /* Dot 1 position */
        70% bottom 4px;
    /* Dot 2 position */
    background-repeat: no-repeat;
}


/* --- B. TABLET BREAKPOINT (Max-Width: 900px) --- */
/* --- B. TABLET & MOBILE VIEW (Reordering Content) --- */
@media (max-width: 900px) {
    .product-page-wrapper {
        /* 1. Main Layout: Flex Column */
        display: flex;
        flex-direction: column;
        padding-left: 20px;
        padding-right: 20px;
    }

    /* 2. Images: Order 1 (Appear First) */
    .product-gallery {
        order: 1;
        width: 100%;
        display: flex;
        flex-direction: column;
        /* 3. Spacing: Gap between bottom of thumbs and Product Title */
        margin-bottom: 0px;
    }

    /* 4. Info/Cart Btn: Order 2 (Appear Second) */
    .product-details-sidebar {
        order: 2;
        position: static;
        width: 100%;
        margin-bottom: 40px;
        display: flex;
        flex-direction: column;
    }

    .add-cart-btn {
        order: -1;
        margin-bottom: 30px;
    }

    #size-container {
        order: -2;
        margin-top: -15px;
    }
}

/* --- C. MOBILE BREAKPOINT (Max-Width: 600px) --- */
@media (max-width: 600px) {

    .icon-btn.mobile-menu-btn {
        display: flex;
        position: absolute;
        left: 20px;
        top: 20px;
        /* Aligned with brand name center */
        z-index: 2002;
    }

    /* Shrink Hamburger Icon Slightly */
    .icon-burger {
        width: 18px;
        height: 12px;
    }

    /* 4. SORT BUTTON: Right side, directly underneath Cart */
    .icon-btn.mobile-sort-btn {
        display: flex;
        position: absolute;
        right: 20px;
        top: 55px;
        /* Sitting clearly below the Cart, aligned to right */
        z-index: 2002;
    }

    /* 2. Hide Search Bar & Cart Label */
    .header-search-wrapper .search-input,
    #header-cart-btn .cart-label {
        display: none;
    }

    #header-cart-btn {
        background: none;
        border: none;
        padding: 5px;
        cursor: pointer;
        font-family: var(--main-font);
        font-size: 1rem;
        /* Slightly bigger */
        font-weight: 800;
        /* Bolder */
        letter-spacing: 1px;
        display: flex;
        align-items: center;
        gap: 2px;
    }

    /* Shrink the (0) cart count */
    #header-cart-btn .cart-count {
        font-size: 0.75rem;
    }

    /* STICKY HEADER REFACTOR FOR MOBILE */
    header.sticky-header {
        padding: 10px 20px 45px;
        /* Reduced top padding, kept bottom for second row button */
        grid-template-columns: 1fr auto 1fr;
        background: none;
    }

    header.sticky-header h1 {
        font-size: 1.3rem !important;
    }

    .header-controls-left {
        display: contents;
        /* Allows children to be positioned absolutely relative to header */
    }

    /* 5. Category Title Alignment */
    .sub-header {
        padding-left: 20px !important;
        padding-top: 15px;
        padding-bottom: 15px;
        /* Aligns with product info text on mobile */
    }

    .sub-header h1 {
        font-size: 1.1rem !important;
        font-weight: 500;
        /* Consistent with desktop weight */
    }

    /* 6. Shop Page Layout */
    .sub-page-wrapper {
        grid-template-columns: 1fr;
        /* Less padding needed now that buttons are in header */
        padding-top: 60px;
        padding-left: 0px;
        padding-right: 0px;
        gap: 0;
    }

    /* 6. Product Grid */
    .product-grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
        padding-left: 5px;
        padding-right: 5px;
    }

    .product-info {
        padding: 25px 8px 30px;
        padding-left: 10px;
        font-size: 11px;
    }

    .product-brand {
        font-size: 12px !important;
    }

    .product-name {
        font-size: 11px !important;
        /* Smaller than the brand name on mobile */
    }

    .info-left {
        max-width: 80%;
        min-height: 50px;
    }

    .info-right {
        min-height: 50px;
    }

    /* --- SIDEBAR CLOSE BUTTONS --- */
    .close-sidebar-btn {
        background: none;
        border: none;
        cursor: pointer;
        font-family: var(--main-font);
        color: #000;
        position: absolute;
        top: 20px;
        z-index: 3505;
        padding: 5px;
        display: flex;
        /* Visible on Mobile Drawer */
        align-items: center;
        justify-content: center;
        transition: opacity 0.2s;
    }

    .close-sidebar-btn svg,
    .close-cart-btn svg {
        width: 28px;
        height: 28px;
    }

    .close-cart-btn {
        font-size: 1.8rem !important;
        /* Touch target scale */
    }

    .mobile-only {
        display: flex !important;
    }

    .desktop-only {
        display: none !important;
    }

    .close-sidebar-btn:hover {
        opacity: 0.6;
    }

    .left-close {
        left: 20px;
    }

    .right-close {
        right: 20px;
    }

    /* 7. SIDEBAR DRAWERS */
    .sidebar.left-sidebar,
    .sidebar.right-sidebar {
        display: flex !important;
        flex-direction: column;
        justify-content: flex-start;
        position: fixed;
        top: 0;
        height: 100dvh;
        width: 45%;
        /* Slightly wider for ease of use */
        max-width: 320px;
        background-color: #fafafa;
        z-index: 3500;
        padding: 80px 30px 40px;
        /* Adjusted top padding */
        overflow-y: auto;
        box-shadow: 20px 0 50px rgba(0, 0, 0, 0.1);
        transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    }

    .sidebar.left-sidebar {
        left: 0;
        transform: translateX(-100%);
        border-right: 1px solid #eeeeee;
        align-items: flex-start;
        text-align: left;
    }

    .sidebar.right-sidebar {
        right: 0;
        transform: translateX(100%);
        border-left: 1px solid #eeeeee;
        align-items: flex-end;
        text-align: right;
    }

    .sidebar.left-sidebar.active,
    .sidebar.right-sidebar.active {
        transform: translateX(0) !important;
    }

    /* Mobile Typography Adjustments */
    .sidebar.left-sidebar .sidebar-label,
    .sidebar.right-sidebar .sidebar-label {
        font-size: 0.85rem;
        margin-top: 35px;
    }

    .sidebar.left-sidebar .sidebar-link,
    .sidebar.right-sidebar .sort-link {
        font-size: 0.75rem;
        padding: 12px 0;
        /* Larger hit areas */
    }

    .sidebar.right-sidebar .size-grid-container {
        width: 120px;
        /* Slightly larger grid on mobile */
        gap: 12px;
    }

    .sidebar.right-sidebar .sidebar-size-link {
        padding: 12px 0;
        font-size: 0.7rem;
    }

    /* Enhanced swipe gesture support */
    .sidebar.left-sidebar,
    .sidebar.right-sidebar {
        -webkit-overflow-scrolling: touch;
        touch-action: pan-y;
    }

    .sidebar.left-sidebar.swiping,
    .sidebar.right-sidebar.swiping {
        transition: none !important;
    }

    /* Visual feedback during swipe */
    .sidebar.left-sidebar.active.swipe-left,
    .sidebar.right-sidebar.active.swipe-right {
        opacity: 0.8;
    }


    /* --- MOBILE SEARCH IN DRAWER --- */
    /* --- MOBILE SEARCH IN DRAWER --- */

    /* 1. Default State: HIDDEN (This keeps it off the Desktop sidebar) */
    .mobile-search-container {
        display: none;
    }

    /* 2. Mobile State: VISIBLE (Only under 768px) */
    @media (max-width: 768px) {
        .mobile-search-container {
            display: block;
            width: 100%;
            margin-bottom: 25px;
            padding-bottom: 15px;
            border-bottom: 1px solid #eee;
        }

        .mobile-search-input {
            width: 100%;
            display: block;
            text-align: left;
            font-family: var(--main-font);
            font-size: var(--fs-md);
            font-weight: 700;
            letter-spacing: 1.5px;
            padding: 10px 5px;
            border: none;
            border-bottom: 1px solid #000;
            background: transparent;
            outline: none;
            border-radius: 0;
            color: #000;
        }

        .mobile-search-input::placeholder {
            color: #000;
            text-transform: uppercase;
            font-size: var(--fs-md);
            font-weight: 700;
        }
    }
}


/* =========================================
   11. LIGHTBOX OVERLAY
   ========================================= */

.lightbox-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 4000;
    background-color: rgba(246, 246, 246, 0.95);
    backdrop-filter: blur(8px);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s cubic-bezier(0.25, 1, 0.5, 1);
}

.lightbox-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.lightbox-content {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.lightbox-image {
    max-width: 90vw;
    max-height: 85vh;
    width: auto;
    height: auto;
    object-fit: contain;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
    opacity: 0;
    transform: scale(0.98);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.lightbox-image.loaded {
    opacity: 1;
    transform: scale(1);
}

.lightbox-close {
    position: absolute;
    top: 30px;
    right: 40px;
    background: none;
    border: none;
    font-family: var(--main-font);
    font-size: 1rem;
    cursor: pointer;
    color: #000;
    z-index: 4002;
    transition: opacity 0.2s;
}

.lightbox-close:hover {
    opacity: 0.6;
}

.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    font-family: var(--main-font);
    font-size: 2rem;
    color: #000;
    cursor: pointer;
    padding: 20px;
    z-index: 4002;
    opacity: 0.5;
    transition: opacity 0.2s;
}

.lightbox-prev:hover,
.lightbox-next:hover {
    opacity: 1;
}

.lightbox-prev {
    left: 20px;
}

.lightbox-next {
    right: 20px;
}

@media (max-width: 600px) {

    .lightbox-prev,
    .lightbox-next {
        display: none;
    }

    .lightbox-close {
        top: 20px;
        right: 20px;
    }
}

/* =========================================
   12. FOOTER
   ========================================= */

.site-footer {
    width: 100%;
    padding: 40px 20px;
    margin-top: auto;
    border-top: 1px solid #eee;
    background-color: #f4f4f4;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 10;
    position: relative;
    text-align: center;
}

/* Wrapper for the row of links */
.footer-links {
    display: flex;
    flex-wrap: wrap;
    /* Allows wrapping on mobile */
    justify-content: center;
    gap: 15px 30px;
    /* Row Gap: 15px, Column Gap: 30px */
    max-width: 1200px;
    margin-bottom: 25px;
    line-height: 1.8;
    /* Breathable line height for wrapping */
}

/* Individual Link Styling */
.footer-links a {
    font-family: var(--main-font);
    font-size: var(--fs-sm);
    text-transform: uppercase;
    color: #000;
    text-decoration: none;
    letter-spacing: 1px;
    transition: opacity 0.2s;
    white-space: nowrap;
}

.footer-links a:hover {
    opacity: 0.5;
}

/* Copyright Text */
.footer-text {
    font-family: var(--title-font) !important;
    font-size: var(--title-fs-footer);
    text-transform: uppercase;
    color: #000;
    letter-spacing: 1px;
    opacity: 0.8;
}

/* Mobile Optimization */
@media (max-width: 600px) {
    .site-footer {
        padding: 30px 10px 20px;
        /* Slight extra padding at bottom for mobile aesthetic */
        overflow: hidden;
    }

    .footer-links {
        gap: 12px 15px;
        /* Slightly tighter gap on small screens */
        width: 100%;
        max-width: 100%;
        justify-content: center;
        flex-wrap: wrap;
    }

    .footer-links a {
        /* Optional: Scale down slightly if 0.6rem feels too big on very small phones, 
           but 0.6rem is usually fine. */
        font-size: clamp(0.5rem, 2.5vw, 0.65rem);
        white-space: normal;
        text-align: center;
    }
}

/* =========================================
   13. MOBILE SEARCH BAR FIX
   ========================================= */

/* 1. FORCE HIDE ON DESKTOP (Global Rule) */
.mobile-search-container {
    display: none !important;
}

/* 2. SHOW ON MOBILE (Only under 768px) */
@media (max-width: 768px) {
    .mobile-search-container {
        display: block !important;
        width: 100%;
        margin-bottom: 25px;
        padding-bottom: 15px;
        border-bottom: 1px solid #eee;
    }

    .mobile-search-input {
        width: 100%;
        display: block;
        text-align: right;
        font-family: var(--main-font);
        font-size: 0.8rem;
        padding: 10px 5px;
        border: none;
        border-bottom: 1px solid #000;
        background: transparent;
        outline: none;
        border-radius: 0;
        color: #000;
    }
}

/* =========================================
   14. MOBILE INTERACTION FIXES (V12 - High-Tempo Stagger)
   ========================================= */

@media (hover: none) {

    .clothing-link,
    .clothing-link path {
        -webkit-tap-highlight-color: transparent;
        -webkit-touch-callout: none;
        -webkit-user-select: none;
        user-select: none;
    }

    /* 1. The Ping Animation */
    /* Total cycle is 4s. The "active" ping is roughly 0.8s long */
    @keyframes staggeredPing {
        0% {
            opacity: 0.02;
        }

        10% {
            opacity: 0.18;
        }

        /* Soft Peak */
        20% {
            opacity: 0.02;
        }

        /* Return to rest */
        100% {
            opacity: 0.02;
        }

        /* Mandatory silence */
    }

    .clothing-link {
        opacity: 1 !important;
    }

    .clothing-link path {
        pointer-events: auto !important;
        fill: #000 !important;
        stroke: rgba(0, 0, 0, 0.15);
        stroke-width: 1px;
        stroke-dasharray: 4 2;
        opacity: 0.02;

        animation-name: staggeredPing;
        animation-duration: 4s;
        /* Faster total loop */
        animation-iteration-count: infinite;
        animation-timing-function: ease-in-out;
        animation-fill-mode: both;
    }

    /* 2. Tightened Forced Delays */
    /* Spaced exactly 1s apart to ensure zero overlap in a 4s cycle */

    /* Hat */
    .clothing-link:nth-of-type(1) path {
        animation-delay: 0s;
    }

    /* Pants (Shuffled) */
    .clothing-link:nth-of-type(3) path {
        animation-delay: 1s;
    }

    /* Top (Shuffled) */
    .clothing-link:nth-of-type(2) path {
        animation-delay: 2s;
    }

    /* Shoes (Shuffled) */
    .clothing-link:nth-of-type(4) path {
        animation-delay: 3s;
    }

    /* 3. Active State */
    .clothing-link:active path {
        animation: none !important;
        opacity: 0.4 !important;
        stroke: #000000;
    }
}

/* Fix for Task 2: Remove large gap on mobile product page */
@media (max-width: 768px) {
    .detail-brand {
        margin-top: 5px !important;
    }

    #size-container {
        margin-top: -30px;
    }

    .selection-wrapper {
        margin-bottom: 0px !important;
    }
}

/* =========================================
   15. PREMIUM DROPDOWNS (NEW)
   ========================================= */

.selection-wrapper {
    display: flex;
    gap: 15px;
    width: 100%;
    margin-bottom: 25px;
    position: relative;
    /* Context for z-index */
    z-index: 20;
}

.dropdown-container {
    position: relative;
    flex: 1;
    /* Both take equal width */
}

/* The clickable box */
.dropdown-trigger {
    width: 98%;
    background: #fafafa;
    padding: 5px 5px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    /* Text left, arrow right */
    align-items: center;
    transition: all 0.2s ease;
    user-select: none;
}

.dropdown-trigger:hover {
    background-color: #fafafa;
}

/* Typography - Same typography as .product-technicalities summary */
.dropdown-label,
.dropdown-value {
    font-family: var(--main-font);
    font-size: var(--fs-pdp-sm);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #000;
}

.dropdown-value {
    margin-left: 10px;
}

/* Arrow Icon (CSS Only) */
.dropdown-arrow {
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 5px solid #000;
    transition: transform 0.3s ease;
}

/* Active State (Open) */
.dropdown-container.active .dropdown-arrow {
    transform: rotate(180deg);
}

.dropdown-container.active .dropdown-options-list {
    display: block;
    animation: fadeIn 0.2s ease;
}

/* The List */
.dropdown-options-list {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: #fafafa;
    border: 1px solid #000;
    border-top: none;
    max-height: 200px;
    overflow-y: auto;
    z-index: 50;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.dropdown-option {
    padding: 12px 15px;
    cursor: pointer;
    font-family: var(--main-font);
    font-size: var(--fs-sm);
    transition: background 0.2s;
    border-bottom: 1px solid #f0f0f0;
}

.dropdown-option:last-child {
    border-bottom: none;
}

.dropdown-option:hover {
    background-color: #f0f0f0;
}

.dropdown-option.selected {
    background-color: #000;
    color: #ffffff;
}

/* Locked State (Single Item) */
.dropdown-trigger.locked {
    cursor: default;
    background-color: #fafafa;
    opacity: 0.8;
}

.dropdown-trigger.locked .dropdown-arrow {
    display: none;
    /* Hide arrow if locked */
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile Touch Targets */
@media (max-width: 600px) {

    .dropdown-trigger,
    .dropdown-option {
        padding: 15px;
        /* Larger hit area */
    }
}

/* =========================================
   16. LEGAL & INFO PAGES
   ========================================= */

/* A specific wrapper for text pages: Sidebar (left) + Content (center) */
.legal-page-wrapper {
    display: grid;
    grid-template-columns: 140px 1fr;
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    padding: 80px 30px 0;
    gap: 40px;
}

.legal-container {
    max-width: 800px;
    width: 100%;
    margin: 0 auto;
    /* Centers the text column */
    padding: 40px 20px 100px;
    font-family: var(--main-font);
    color: #000;
}

.legal-container h1 {
    font-family: var(--title-font) !important;
    font-size: var(--fs-pdp-lg);
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: 50px;
    text-align: center;
    font-weight: 400;
}

.legal-container h2 {
    font-size: var(--fs-pdp-md);
    text-transform: uppercase;
    margin-top: 40px;
    margin-bottom: 15px;
    letter-spacing: 3px;
    font-weight: 700;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
}

.legal-container p {
    font-size: var(--fs-pdp-sm);
    line-height: 1.8;
    margin-bottom: 25px;
    color: #000;
}

.legal-container ul {
    list-style-type: disc;
    padding-left: 20px;
    margin-bottom: 25px;
}

.legal-container li {
    font-size: var(--fs-pdp-sm);
    line-height: 1.8;
    margin-bottom: 10px;
    color: #000;
}

/* Mobile Responsiveness for Legal Pages */
@media (max-width: 900px) {
    .legal-page-wrapper {
        display: block;
        /* Stack layout */
        padding-left: 0;
        padding-right: 0;
    }

    .legal-container {
        padding-top: 20px;
        padding-left: 25px;
        padding-right: 25px;
    }
}

/* =========================================
   17. CENTERED PAGES (CONTACT & REVIEWS)
   ========================================= */

/* A wrapper similar to product-page, but focused on a center column */
.centered-page-wrapper {
    display: grid;
    grid-template-columns: 140px 1fr 140px;
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    padding: 80px 30px 0;
    gap: 40px;
    min-height: 60vh;
}

.center-column {
    max-width: 800px;
    width: 100%;
    margin: 0 auto;
    padding: 40px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* --- CONTACT FORM STYLES --- */
.contact-form-wrapper {
    width: 100%;
    max-width: 500px;
    margin-bottom: 60px;
}

.minimal-input,
.minimal-textarea {
    width: 100%;
    border: none;
    border-bottom: 1px solid #ccc;
    background: transparent;
    padding: 15px 0;
    font-family: var(--main-font);
    font-size: var(--fs-pdp-sm);
    color: #000;
    margin-bottom: 30px;
    outline: none;
    transition: border-color 0.3s ease;
    border-radius: 0;
}

.minimal-input:focus,
.minimal-textarea:focus {
    border-bottom: 1px solid #000;
}

.minimal-textarea {
    resize: none;
    min-height: 100px;
}

.submit-btn {
    background-color: #000;
    color: #ffffff;
    border: none;
    padding: 15px 40px;
    font-family: var(--main-font);
    text-transform: uppercase;
    font-size: var(--fs-sm);
    letter-spacing: 2px;
    cursor: pointer;
    transition: opacity 0.3s;
    width: 100%;
}

.submit-btn:hover {
    opacity: 0.8;
}

/* --- SOCIALS SECTION --- */
.socials-section {
    text-align: center;
    border-top: 1px solid #eee;
    padding-top: 40px;
    width: 100%;
    max-width: 500px;
}

.socials-label {
    display: block;
    font-family: var(--main-font);
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 20px;
    color: #000;
}

.social-link-row {
    display: flex;
    justify-content: center;
    gap: 30px;
}

.social-text-link {
    text-decoration: none;
    color: #000;
    font-family: var(--main-font);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
}

.social-text-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 1px;
    bottom: -2px;
    left: 0;
    background-color: #000;
    transition: width 0.3s ease;
}

.social-text-link:hover::after {
    width: 100%;
}

/* --- BROWSER WINDOW UI (REVIEWS) --- */
.windows-container {
    display: flex;
    gap: 30px;
    width: 100%;
    margin-bottom: 80px;
    flex-wrap: wrap;
    justify-content: center;
}

.browser-window {
    flex: 1;
    min-width: 300px;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    background: #fafafa;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.browser-window:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
}

.browser-header {
    background: #f9f9f9;
    padding: 10px 15px;
    display: flex;
    gap: 6px;
    border-bottom: 1px solid #eee;
}

.browser-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: #d1d1d1;
}

.browser-dot.red {
    background-color: #ff5f56;
}

.browser-dot.yellow {
    background-color: #ffbd2e;
}

.browser-dot.green {
    background-color: #27c93f;
}

.browser-content {
    padding: 40px 20px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.platform-logo {
    font-family: var(--title-font);
    font-size: 1.5rem;
    margin-bottom: 15px;
    letter-spacing: 1px;
}

.platform-stat {
    font-family: var(--main-font);
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 5px;
}

.platform-sub {
    font-family: var(--main-font);
    font-size: 0.75rem;
    color: #000;
    text-transform: uppercase;
    margin-bottom: 25px;
}

.verify-btn {
    text-decoration: none;
    font-family: var(--main-font);
    font-size: 0.7rem;
    text-transform: uppercase;
    border: 1px solid #000;
    padding: 10px 20px;
    color: #000;
    transition: all 0.2s;
}

.verify-btn:hover {
    background: #000;
    color: #ffffff;
}

/* --- DIRECT REVIEWS GRID --- */
.reviews-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    width: 100%;
    margin-bottom: 60px;
}

.review-card {
    background: #fcfcfc;
    padding: 30px;
    border: 1px solid #eee;
}

.review-text {
    font-family: var(--main-font);
    font-size: 0.85rem;
    font-style: italic;
    line-height: 1.6;
    margin-bottom: 15px;
    color: #000;
}

.review-author {
    font-family: var(--main-font);
    font-size: 0.7rem;
    text-transform: uppercase;
    color: #000;
    letter-spacing: 1px;
}

/* --- REVIEW MODAL --- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(5px);
    z-index: 5000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.modal-box {
    width: 90%;
    max-width: 500px;
    background: #fafafa;
    border: 1px solid #000;
    padding: 40px;
    position: relative;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.1);
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    cursor: pointer;
    font-family: var(--main-font);
    font-size: 1rem;
}

/* Mobile Responsiveness for Centered Pages */
@media (max-width: 900px) {
    .centered-page-wrapper {
        display: block;
        padding-left: 0;
        padding-right: 0;
    }

    .reviews-grid {
        grid-template-columns: 1fr;
    }

    .windows-container {
        flex-direction: column;
        align-items: center;
    }

    .browser-window {
        width: 100%;
        max-width: 400px;
    }
}