/* ================================================
   QVEEX Landing Page — Design System
   Deep Black · Silver Accents · Glassmorphism
   ================================================ */

/* ---------- Reset & Base ---------- */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg: #09090b;
    --bg-card: rgba(18, 18, 22, 0.72);
    --border-card: rgba(255, 255, 255, 0.06);
    --text-primary: #f0f0f0;
    --text-secondary: #a1a1aa;
    --accent-silver: #c4c4cc;
    --accent-teal: #5eead4;
    --accent-teal-bright: #2dd4bf;
    --blur: 24px;
    --radius: 18px;
    --transition: 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

html {
    scroll-behavior: auto;
    overflow-x: hidden;
    background: var(--bg);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--text-primary);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    color: inherit;
    text-decoration: none;
}

/* ---------- Loader ---------- */
#loader {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg);
    transition: opacity 0.6s ease, visibility 0.6s ease;
}

#loader.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.loader-inner {
    text-align: center;
    width: 260px;
}

.loader-logo {
    font-size: 2rem;
    font-weight: 600;
    letter-spacing: 0.25em;
    color: var(--accent-silver);
    margin-bottom: 28px;
}

.loader-bar-track {
    width: 100%;
    height: 2px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 2px;
    overflow: hidden;
}

.loader-bar-fill {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, var(--accent-teal), var(--accent-silver));
    border-radius: 2px;
    transition: width 0.15s ease-out;
}

.loader-percent {
    margin-top: 14px;
    font-size: 0.82rem;
    font-weight: 300;
    letter-spacing: 0.12em;
    color: var(--text-secondary);
}

/* ---------- Hero ---------- */
#hero {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    z-index: 1;
    overflow: hidden;
    will-change: transform;
    background: var(--bg);
}

#heroCanvas {
    width: 100%;
    height: 100%;
    display: block;
}

/* Vignette overlay — blends animation edges into dark bg */
.vignette-overlay {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 1;
    background: radial-gradient(ellipse 70% 65% at center,
            transparent 40%,
            rgba(9, 9, 11, 0.4) 70%,
            rgba(9, 9, 11, 0.85) 90%,
            var(--bg) 100%);
}

/* Scroll spacer — room for 240-frame scrubbing */
#scrollSpacer {
    position: relative;
    z-index: 0;
    height: 500vh;
    pointer-events: none;
}

/* Transition spacer — room for canvas to scroll away (reduced) */
#transitionSpacer {
    position: absolute;
    z-index: 0;
    height: 70vh;
    pointer-events: none;
}

/* ---------- Hero Navigation Bar ---------- */
.hero-nav {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 3;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    padding: 36px 48px;
    pointer-events: none;
    opacity: 0;
    transition: opacity 1.8s ease-in-out;
}

.hero-nav.visible {
    opacity: 1;
}

.hero-nav>* {
    pointer-events: auto;
}

/* ---------- Brand Bar (inside nav, left side) ---------- */
.brand-bar {
    pointer-events: none;
}

.brand-name {
    font-size: clamp(1.6rem, 3vw, 2.4rem);
    font-weight: 300;
    letter-spacing: 0.3em;
    margin-bottom: 6px;
    background: linear-gradient(135deg, #ffffff 0%, var(--accent-silver) 60%, var(--accent-teal) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.brand-tagline {
    font-size: clamp(0.8rem, 1.2vw, 1rem);
    font-weight: 300;
    color: var(--text-secondary);
    letter-spacing: 0.08em;
}

/* ---------- Hero CTA Button (top-right) ---------- */
.btn-cta-hero {
    display: inline-block;
    margin-top: 6px;
    padding: 12px 32px;
    font-size: 0.82rem;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--bg);
    background: linear-gradient(135deg, var(--accent-teal) 0%, var(--accent-teal-bright) 100%);
    border: none;
    border-radius: 100px;
    cursor: pointer;
    text-decoration: none;
    transition: box-shadow 0.4s ease, transform 0.2s ease, background 0.3s ease;
    box-shadow: 0 0 20px rgba(94, 234, 212, 0.25), 0 0 60px rgba(94, 234, 212, 0.08);
}

.btn-cta-hero:hover {
    box-shadow: 0 0 30px rgba(94, 234, 212, 0.4), 0 0 80px rgba(94, 234, 212, 0.15);
    transform: scale(1.05);
}

.btn-cta-hero:active {
    transform: scale(0.97);
}

/* ---------- Scroll Hint ---------- */
.scroll-hint {
    position: absolute;
    bottom: 36px;
    left: 50%;
    transform: translateX(-%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    opacity: 0;
    transition: opacity 0.8s ease;
    z-index: 3;
}

.scroll-hint.visible {
    opacity: 1;
}

.scroll-hint-line {
    width: 1px;
    height: 48px;
    background: linear-gradient(to bottom, transparent, var(--accent-silver));
    animation: scrollPulse 2s ease-in-out infinite;
}

.scroll-hint span {
    font-size: 0.7rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--text-secondary);
}

@keyframes scrollPulse {

    0%,
    100% {
        opacity: 0.3;
        transform: scaleY(0.6);
    }

    50% {
        opacity: 1;
        transform: scaleY(1);
    }
}

/* ---------- CTA ---------- */
#cta {
    position: relative;
    z-index: 10;
    text-align: center;
    padding: 80px 6% 100px;
    background: var(--bg);
}

.cta-inner {
    max-width: 600px;
    margin: 0 auto;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}

.cta-inner.in-view {
    opacity: 1;
    transform: translateY(0);
}

#cta h2 {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 300;
    margin-bottom: 12px;
    letter-spacing: 0.04em;
}

#cta p {
    font-size: 1.05rem;
    color: var(--text-secondary);
    margin-bottom: 40px;
    font-weight: 300;
}

/* Main CTA Button — prominent teal, eye-catching */
.btn-cta {
    display: inline-block;
    padding: 18px 56px;
    font-size: 0.92rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--bg);
    background: linear-gradient(135deg, var(--accent-teal) 0%, var(--accent-teal-bright) 100%);
    border: none;
    border-radius: 100px;
    cursor: pointer;
    text-decoration: none;
    transition: box-shadow 0.4s ease, transform 0.2s ease;
    box-shadow: 0 0 30px rgba(94, 234, 212, 0.3), 0 0 80px rgba(94, 234, 212, 0.1);
}

.btn-cta:hover {
    box-shadow: 0 0 40px rgba(94, 234, 212, 0.5), 0 0 100px rgba(94, 234, 212, 0.2);
    transform: scale(1.05);
}

.btn-cta:active {
    transform: scale(0.97);
}

/* ---------- Footer ---------- */
#footer {
    position: relative;
    z-index: 10;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    background: var(--bg);
}

.footer-inner {
    max-width: 860px;
    margin: 0 auto;
    padding: 64px 6% 40px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
}

.footer-col h3 {
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--accent-silver);
    margin-bottom: 18px;
}

.footer-col address,
.footer-col p {
    font-style: normal;
    font-size: 0.88rem;
    font-weight: 300;
    line-height: 1.8;
    color: var(--text-secondary);
}

.footer-col a {
    color: var(--accent-teal);
    transition: color 0.3s ease;
}

.footer-col a:hover {
    color: #99f6e4;
}

.footer-bottom {
    grid-column: 1 / -1;
    text-align: center;
    padding-top: 32px;
    border-top: 1px solid rgba(255, 255, 255, 0.04);
}

.footer-bottom p {
    font-size: 0.76rem;
    color: rgba(255, 255, 255, 0.25);
    letter-spacing: 0.06em;
}

/* ---------- Responsive ---------- */
@media (max-width: 680px) {
    .footer-inner {
        grid-template-columns: 1fr;
        gap: 36px;
    }

    .hero-nav {
        padding: 24px 20px;
    }

    .btn-cta-hero {
        padding: 10px 20px;
        font-size: 0.72rem;
    }
}