/**
 * GDP Distro & Cigar Lounge - Core Styling, Typography & Cinematic Motion Engine
 */

/* 1. Global Typography & Readability Enforcement */
* {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

.font-mono {
    font-feature-settings: "tnum" on, "zero" on;
}

.text-xs {
    font-size: 0.775rem !important;
    line-height: 1.15rem !important;
}

.text-sm {
    font-size: 0.875rem !important;
    line-height: 1.35rem !important;
}

/* Lenis Smooth Scroll */
html.lenis {
    height: auto;
}

.lenis.lenis-smooth {
    scroll-behavior: auto;
}

.lenis.lenis-smooth [data-lenis-prevent] {
    overscroll-behavior: contain;
}

.lenis.lenis-stopped {
    overflow: hidden;
}

body {
    background-color: #0A0A0A;
    color: #fff;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

#canvas-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

#canvas {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.6;
}

.overlay-vignette {
    position: fixed;
    inset: 0;
    background: radial-gradient(circle at center, transparent 0%, rgba(0,0,0,0.4) 50%, #000 100%);
    z-index: 1;
    pointer-events: none;
}

.section-pin {
    position: relative;
    width: 100%;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.char {
    display: inline-block;
    opacity: 0;
    transform: translateY(20px);
}

.aura-card {
    background: rgba(15, 15, 15, 0.4);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(197, 160, 89, 0.1);
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.aura-card:hover {
    border-color: rgba(197, 160, 89, 0.4);
    background: rgba(20, 20, 20, 0.6);
    transform: translateY(-5px);
}

/* =========================================================================
   2. Cinematic Scroll-Driven Category Cards & Extended Bleed Parallax
   ========================================================================= */

.category-cinematic-card {
    position: relative;
    overflow: hidden;
    background: #121212;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 1.25rem;
    transition: border-color 0.4s ease, box-shadow 0.4s ease;
    will-change: transform, opacity;
}

.category-cinematic-card:hover {
    border-color: rgba(197, 160, 89, 0.7) !important;
    box-shadow: 0 16px 40px -10px rgba(197, 160, 89, 0.25);
}

/* Crystal-Clear Image Layer with Extended Bounds for Deep Parallax */
.cinematic-product-img {
    position: absolute;
    top: -15%;
    left: 0;
    width: 100%;
    height: 130%;
    object-fit: cover;
    image-rendering: -webkit-optimize-contrast;
    filter: contrast(106%) brightness(100%) saturate(106%);
    will-change: transform;
    transform-origin: center center;
    pointer-events: none;
    z-index: 0;
}

/* Horizontal Scroll Section */
.horizontal-section-wrapper {
    position: relative;
    height: 100vh;
    min-height: 700px;
    overflow: hidden;
    z-index: 10;
}

.horizontal-scroll-container {
    display: flex;
    height: 100%;
    width: fit-content;
    align-items: center;
    padding: 0 5vw;
}

.product-card-large {
    width: 80vw;
    max-width: 460px;
    height: 65vh;
    min-height: 480px;
    max-height: 580px;
    margin-right: 4vw;
    flex-shrink: 0;
    position: relative;
    overflow: hidden;
    border-radius: 16px;
    border: 1px solid rgba(197, 160, 89, 0.25);
    background: rgba(15, 15, 15, 0.95);
    backdrop-filter: blur(16px);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.product-card-large img {
    width: 100%;
    height: 45%;
    object-fit: cover;
    image-rendering: -webkit-optimize-contrast;
}

/* Custom Scrollbar */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: #000; }
::-webkit-scrollbar-thumb { background: #C5A059; border-radius: 3px; }

/* Hide Scrollbar helper */
.hide-scrollbar::-webkit-scrollbar { display: none; }
.hide-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }

/* Custom Gold Scrollbar for Drawers and Modals */
.custom-gold-scrollbar::-webkit-scrollbar {
    width: 5px;
    height: 5px;
}
.custom-gold-scrollbar::-webkit-scrollbar-track {
    background: rgba(20, 20, 20, 0.6);
    border-radius: 4px;
}
.custom-gold-scrollbar::-webkit-scrollbar-thumb {
    background: rgba(197, 160, 89, 0.4);
    border-radius: 4px;
    border: 1px solid rgba(197, 160, 89, 0.2);
}
.custom-gold-scrollbar::-webkit-scrollbar-thumb:hover {
    background: rgba(197, 160, 89, 0.8);
}
.custom-gold-scrollbar {
    scrollbar-width: thin;
    scrollbar-color: rgba(197, 160, 89, 0.4) rgba(20, 20, 20, 0.6);
}

/* Loader */
#loader {
    position: fixed;
    inset: 0;
    background: #000;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: opacity 0.5s ease-out;
}

.technical-divider {
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(197, 160, 89, 0.5), transparent);
    margin: 2rem 0;
}

/* =========================================================================
   3. Global Smooth Scrolling & Accessibility Motion Enforcement (Req 8)
   ========================================================================= */
@media (prefers-reduced-motion: no-preference) {
    html {
        scroll-behavior: smooth;
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto !important;
    }
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* =========================================================================
   4. Video Framing & Hardware Acceleration (Req 1 & 2)
   ========================================================================= */
.video-sticky-frame {
    position: sticky;
    top: 0;
    width: 100%;
    height: 100vh;
    height: 100svh;
    overflow: hidden;
    transform: translateZ(0);
    will-change: transform;
    z-index: 0;
}

.video-element-framed {
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
    transform: translateZ(0);
}

/* =========================================================================
   5. Scroll-Triggered Heading & Item Reveal Animations (Req 1 & 2)
   ========================================================================= */
.scroll-reveal-item {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: opacity, transform;
}

.scroll-reveal-item.is-revealed {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

/* Stagger delays for bullet points and cards */
.scroll-reveal-delay-1 { transition-delay: 0.08s; }
.scroll-reveal-delay-2 { transition-delay: 0.16s; }
.scroll-reveal-delay-3 { transition-delay: 0.24s; }
.scroll-reveal-delay-4 { transition-delay: 0.32s; }

/* =========================================================================
   6. Category Filter Button Hover & Active States (Req 5)
   ========================================================================= */
.category-nav-chip {
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    user-select: none;
    outline: none;
}

.category-nav-chip:hover {
    transform: translateY(-2px);
    border-color: rgba(197, 160, 89, 0.6) !important;
    box-shadow: 0 6px 16px -2px rgba(197, 160, 89, 0.18);
}

.category-nav-chip:focus-visible {
    outline: 2px solid #C5A059 !important;
    outline-offset: 2px;
}

.category-nav-chip.is-active {
    background-color: #C5A059 !important;
    color: #000000 !important;
    border-color: #C5A059 !important;
    font-weight: 700 !important;
    box-shadow: 0 8px 20px -3px rgba(197, 160, 89, 0.35);
}

/* =========================================================================
   7. Universal WCAG 2.1 AA Keyboard Focus Visibility & Contrast Safeguards
   ========================================================================= */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 2px solid #C5A059 !important;
    outline-offset: 2px !important;
}

/* Elevate muted text opacity across dark themes to guarantee 4.5:1 contrast */
.text-white\/40 {
    color: rgba(255, 255, 255, 0.65) !important;
}

.text-white\/50 {
    color: rgba(255, 255, 255, 0.75) !important;
}

