/* Genesis - Custom Styles & Animations */
/* A high-tech, institutional trading platform */

/* ========================================
   SMOOTH SCROLLING & CUSTOM CURSOR
   ======================================== */
html.smooth-scroll {
    scroll-behavior: auto;
}

html.smooth-scroll body {
    overflow: hidden;
}

html.smooth-scroll .scroll-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    will-change: transform;
}

/* Hide default cursor */
*, *::before, *::after {
    cursor: none !important;
}

/* Custom cursor - main circle */
.custom-cursor {
    width: 20px;
    height: 20px;
    background: white;
    border-radius: 50%;
    position: fixed;
    pointer-events: none;
    z-index: 99999;
    transform: translate(-50%, -50%);
    transition: width 0.3s ease, height 0.3s ease, opacity 0.3s ease;
    mix-blend-mode: difference;
    opacity: 0;
}

.custom-cursor.active {
    opacity: 1;
}

.custom-cursor.hovering {
    width: 50px;
    height: 50px;
}

/* ========================================
   CSS VARIABLES
   ======================================== */
:root {
    --color-black: #000000;
    --color-white: #ffffff;
    --color-gray-100: #f5f5f5;
    --color-gray-200: #e5e5e5;
    --color-gray-300: #d4d4d4;
    --color-gray-400: #a3a3a3;
    --color-gray-500: #737373;
    --color-gray-600: #525252;
    --color-gray-700: #404040;
    --color-gray-800: #262626;
    --color-gray-900: #171717;
    --color-accent: #ffffff;
    --color-accent-light: #d4d4d4;
    --color-green: #22c55e;
    --color-red: #ef4444;
    --font-display: 'Outfit', 'Inter', -apple-system, sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --transition-smooth: cubic-bezier(0.4, 0, 0.2, 1);
    --transition-bounce: cubic-bezier(0.68, -0.55, 0.265, 1.55);
    --transition-expo: cubic-bezier(0.16, 1, 0.3, 1);
    --letter-spacing-tight: -0.02em;
    --letter-spacing-wide: 0.1em;
}

/* ========================================
   LOADING OVERLAY
   ======================================== */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #030305;
    z-index: 9999;
    pointer-events: none;
}

.loading-overlay.fade-out {
    opacity: 0;
    transition: opacity 0.8s ease;
}

/* ========================================
   NAVBAR
   ======================================== */
.nav-fade-in {
    animation: navFadeIn 0.8s ease 3.2s forwards;
}

@keyframes navFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* ========================================
   HERO SECTION - CINEMATIC
   ======================================== */
.hero-section {
    min-height: 100vh;
    min-height: 100svh;
    background: #010102;
}

/* ========================================
   GENESIS HORIZON BACKGROUND
   ======================================== */

/* Atmospheric Glow - fills space between arcs */
.atmo-glow {
    position: absolute;
    pointer-events: none;
    opacity: 0;
    animation: atmoReveal 2.5s ease-out 0.2s forwards;
}

.atmo-glow-1 {
    width: 120%;
    height: 100%;
    left: -10%;
    top: 0;
    background: radial-gradient(ellipse 70% 45% at 35% 50%,
        rgba(80, 100, 170, 0.18) 0%,
        rgba(70, 95, 165, 0.12) 25%,
        rgba(65, 85, 155, 0.07) 45%,
        rgba(55, 75, 145, 0.03) 65%,
        transparent 85%
    );
    filter: blur(40px);
}

.atmo-glow-2 {
    width: 80%;
    height: 60%;
    left: 0;
    top: 25%;
    background: radial-gradient(ellipse 65% 55% at 25% 50%,
        rgba(95, 125, 200, 0.14) 0%,
        rgba(85, 115, 190, 0.08) 35%,
        rgba(75, 105, 180, 0.03) 60%,
        transparent 80%
    );
    filter: blur(35px);
}

@keyframes atmoReveal {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Arc Base */
.arc {
    position: absolute;
    border-radius: 50%;
    border-style: solid;
    border-color: transparent;
    pointer-events: none;
    clip-path: inset(0 100% 0 0);
    animation: arcSweepIn 4s cubic-bezier(0.25, 0.1, 0.25, 1) forwards;
}

.arc-glow {
    position: absolute;
    border-radius: 50%;
    border-style: solid;
    border-color: transparent;
    pointer-events: none;
    clip-path: inset(0 100% 0 0);
    animation: arcSweepIn 4.3s cubic-bezier(0.25, 0.1, 0.25, 1) forwards;
}

@keyframes arcSweepIn {
    0% {
        clip-path: inset(0 100% 0 0);
        opacity: 0;
    }
    5% {
        opacity: 1;
    }
    100% {
        clip-path: inset(0 0% 0 0);
        opacity: 1;
    }
}

/* Arc Head - Traveling bright point */
.arc-head {
    position: absolute;
    width: 250%;
    height: 120vh;
    left: -30%;
    border-radius: 50%;
    pointer-events: none;
}

.arc-head::before {
    content: '';
    position: absolute;
    width: 15px;
    height: 15px;
    background: radial-gradient(circle,
        rgba(255, 255, 255, 1) 0%,
        rgba(230, 240, 255, 0.9) 30%,
        rgba(180, 210, 255, 0.5) 60%,
        transparent 100%
    );
    border-radius: 50%;
    box-shadow:
        0 0 10px 5px rgba(255, 255, 255, 0.9),
        0 0 30px 15px rgba(200, 220, 255, 0.6),
        0 0 60px 30px rgba(160, 190, 250, 0.3);
    opacity: 0;
}

/* Upper arc head - travels along upper arc */
.arc-head-upper {
    top: -88vh;
}

.arc-head-upper::before {
    bottom: -7px;
    left: 50%;
    transform: translateX(-50%);
    animation: headTravelUpper 4s cubic-bezier(0.25, 0.1, 0.25, 1) 1.2s forwards;
}

@keyframes headTravelUpper {
    0% {
        left: 0%;
        opacity: 0;
    }
    3% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        left: 100%;
        opacity: 0;
    }
}

/* Lower arc head - travels along lower arc */
.arc-head-lower {
    bottom: -88vh;
}

.arc-head-lower::before {
    top: -7px;
    left: 50%;
    transform: translateX(-50%);
    animation: headTravelLower 4s cubic-bezier(0.25, 0.1, 0.25, 1) 1.3s forwards;
}

@keyframes headTravelLower {
    0% {
        left: 0%;
        opacity: 0;
    }
    3% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        left: 100%;
        opacity: 0;
    }
}

/* ===== UPPER ARC SYSTEM ===== */

/* Primary upper arc - brightest, closer to center */
.arc-upper-1 {
    width: 250%;
    height: 120vh;
    left: -30%;
    top: -88vh;
    border-width: 2px;
    border-bottom-color: rgba(220, 230, 255, 1);
    box-shadow: 
        0 0 6px rgba(210, 225, 255, 1),
        0 0 20px rgba(180, 205, 255, 0.8),
        0 0 40px rgba(150, 180, 250, 0.5),
        0 0 60px rgba(130, 160, 240, 0.25);
    animation-delay: 1.2s;
    animation-duration: 4s;
}

/* Secondary upper arc - slightly wider */
.arc-upper-2 {
    width: 260%;
    height: 125vh;
    left: -32%;
    top: -92vh;
    border-width: 1px;
    border-bottom-color: rgba(190, 210, 255, 0.45);
    box-shadow: 
        0 0 4px rgba(180, 200, 255, 0.4),
        0 0 12px rgba(160, 185, 250, 0.2);
    animation-delay: 1.35s;
    animation-duration: 4.2s;
}

/* Tertiary upper arc - outer glow line */
.arc-upper-3 {
    width: 270%;
    height: 130vh;
    left: -35%;
    top: -96vh;
    border-width: 1px;
    border-bottom-color: rgba(160, 185, 250, 0.2);
    animation-delay: 1.5s;
    animation-duration: 4.3s;
}

/* Upper glow layers - big soft bloom */
.arc-upper-glow-1 {
    width: 250%;
    height: 120vh;
    left: -30%;
    top: -88vh;
    border-width: 50px;
    border-bottom-color: rgba(120, 155, 230, 0.2);
    filter: blur(18px);
    animation-delay: 1.2s;
    animation-duration: 4.2s;
}

.arc-upper-glow-2 {
    width: 250%;
    height: 120vh;
    left: -30%;
    top: -88vh;
    border-width: 120px;
    border-bottom-color: rgba(100, 140, 220, 0.12);
    filter: blur(45px);
    animation-delay: 1.2s;
    animation-duration: 4.5s;
}

/* ===== LOWER ARC SYSTEM ===== */

/* Primary lower arc - reflection */
.arc-lower-1 {
    width: 250%;
    height: 120vh;
    left: -30%;
    bottom: -88vh;
    border-width: 2px;
    border-top-color: rgba(180, 200, 255, 0.6);
    box-shadow: 
        0 0 5px rgba(170, 195, 255, 0.6),
        0 0 15px rgba(150, 180, 250, 0.4),
        0 0 35px rgba(130, 160, 240, 0.2);
    animation-delay: 1.3s;
    animation-duration: 4s;
}

/* Secondary lower arc */
.arc-lower-2 {
    width: 270%;
    height: 130vh;
    left: -35%;
    bottom: -96vh;
    border-width: 1px;
    border-top-color: rgba(150, 175, 245, 0.2);
    animation-delay: 1.5s;
    animation-duration: 4.3s;
}

/* Lower glow layers */
.arc-lower-glow-1 {
    width: 250%;
    height: 120vh;
    left: -30%;
    bottom: -88vh;
    border-width: 45px;
    border-top-color: rgba(115, 150, 225, 0.14);
    filter: blur(16px);
    animation-delay: 1.3s;
    animation-duration: 4.2s;
}

.arc-lower-glow-2 {
    width: 250%;
    height: 120vh;
    left: -30%;
    bottom: -88vh;
    border-width: 100px;
    border-top-color: rgba(95, 135, 215, 0.09);
    filter: blur(40px);
    animation-delay: 1.3s;
    animation-duration: 4.5s;
}

/* ===== HORIZON SYSTEM ===== */
.horizon-system {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    transform: translateY(-50%);
}

/* Primary horizon line - visible immediately */
.horizon-line-1 {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg,
        rgba(230, 240, 255, 0.95) 0%,
        rgba(210, 225, 255, 0.8) 8%,
        rgba(180, 200, 255, 0.55) 20%,
        rgba(150, 175, 250, 0.35) 35%,
        rgba(130, 155, 240, 0.18) 50%,
        rgba(110, 140, 225, 0.08) 70%,
        rgba(100, 125, 210, 0.02) 85%,
        transparent 100%
    );
    opacity: 0;
    animation: horizonFadeIn 0.8s ease-out forwards;
}

/* Secondary horizon line - visible immediately */
.horizon-line-2 {
    position: absolute;
    top: 0;
    left: 0;
    width: 70%;
    height: 1px;
    background: linear-gradient(90deg,
        rgba(255, 255, 255, 0.4) 0%,
        rgba(230, 240, 255, 0.25) 15%,
        rgba(200, 220, 255, 0.1) 40%,
        transparent 100%
    );
    opacity: 0;
    animation: horizonFadeIn 0.8s ease-out 0.1s forwards;
}

@keyframes horizonFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Soft wide glow */
.horizon-glow-soft {
    position: absolute;
    top: 50%;
    left: 0;
    width: 60%;
    height: 120px;
    transform: translateY(-50%);
    background: linear-gradient(90deg,
        rgba(130, 160, 230, 0.12) 0%,
        rgba(120, 150, 220, 0.06) 30%,
        rgba(110, 140, 210, 0.02) 60%,
        transparent 100%
    );
    filter: blur(35px);
    opacity: 0;
    animation: glowFadeIn 0.8s ease-out 0.3s forwards;
}

/* Intense tight glow */
.horizon-glow-intense {
    position: absolute;
    top: 50%;
    left: 0;
    width: 40%;
    height: 50px;
    transform: translateY(-50%);
    background: linear-gradient(90deg,
        rgba(160, 185, 245, 0.2) 0%,
        rgba(145, 170, 235, 0.1) 25%,
        rgba(130, 155, 225, 0.03) 55%,
        transparent 100%
    );
    filter: blur(15px);
    opacity: 0;
    animation: glowFadeIn 0.8s ease-out 0.2s forwards;
}

@keyframes glowFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* ===== FLARE - Animated ===== */
.horizon-flare {
    position: absolute;
    top: 0;
    left: 5%;
    opacity: 0;
    animation: flareFadeIn 0.8s ease-out 0.2s forwards, flareMove 20s ease-in-out 1s infinite;
}

@keyframes flareFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes flareMove {
    0% { left: 5%; }
    50% { left: 35%; }
    100% { left: 5%; }
}

.flare-core {
    position: absolute;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
    width: 10px;
    height: 10px;
    background: radial-gradient(circle, 
        rgba(255, 255, 255, 1) 0%, 
        rgba(245, 250, 255, 1) 25%,
        rgba(220, 235, 255, 0.9) 45%,
        rgba(190, 215, 255, 0.5) 65%,
        transparent 100%
    );
    border-radius: 50%;
    box-shadow: 
        0 0 10px 5px rgba(255, 255, 255, 1),
        0 0 30px 15px rgba(225, 240, 255, 0.95),
        0 0 70px 35px rgba(180, 210, 255, 0.6),
        0 0 140px 70px rgba(150, 185, 250, 0.35),
        0 0 220px 110px rgba(130, 165, 245, 0.15);
}

/* Right streak */
.flare-core::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 100%;
    width: 400px;
    height: 2px;
    transform: translateY(-50%);
    background: linear-gradient(90deg,
        rgba(255, 255, 255, 1) 0%,
        rgba(240, 248, 255, 0.9) 3%,
        rgba(210, 230, 255, 0.6) 12%,
        rgba(180, 205, 255, 0.35) 28%,
        rgba(155, 185, 250, 0.15) 48%,
        rgba(135, 165, 240, 0.05) 70%,
        transparent 100%
    );
}

/* Left streak */
.flare-core::after {
    content: '';
    position: absolute;
    top: 50%;
    right: 100%;
    width: 200px;
    height: 2px;
    transform: translateY(-50%);
    background: linear-gradient(270deg,
        rgba(255, 255, 255, 1) 0%,
        rgba(240, 248, 255, 0.8) 6%,
        rgba(210, 230, 255, 0.4) 20%,
        rgba(180, 205, 255, 0.15) 45%,
        transparent 100%
    );
}

/* Vignette */
.vignette {
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 80% 80% at 50% 50%,
        transparent 0%,
        transparent 50%,
        rgba(0, 0, 0, 0.3) 100%
    );
    pointer-events: none;
}

/* Hero Title */
.hero-title {
    font-size: clamp(3.5rem, 18vw, 14rem);
}

/* Hero CTA - Cosmic themed */
.hero-cta {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.875rem 1.75rem;
    border-radius: 9999px;
    background: linear-gradient(180deg, rgba(140, 160, 220, 0.08) 0%, rgba(100, 120, 180, 0.02) 100%);
    border: 1px solid rgba(140, 160, 220, 0.2);
    color: rgba(255,255,255,0.9);
    transition: all 0.3s ease;
    box-shadow: 
        inset 0 1px 0 rgba(200, 210, 255, 0.1),
        0 2px 12px rgba(100, 120, 180, 0.15),
        0 4px 20px rgba(0,0,0,0.3);
}

.hero-cta:hover {
    border-color: rgba(160, 180, 240, 0.35);
    background: linear-gradient(180deg, rgba(140, 160, 220, 0.12) 0%, rgba(100, 120, 180, 0.04) 100%);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 
        inset 0 1px 0 rgba(200, 210, 255, 0.15),
        0 4px 20px rgba(100, 120, 180, 0.25),
        0 8px 30px rgba(0,0,0,0.4);
}

/* Nav CTA */
.nav-cta {
    background: linear-gradient(180deg, rgba(255,255,255,0.04) 0%, rgba(255,255,255,0.01) 100%);
    border: 1px solid rgba(255,255,255,0.12);
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.05);
}

.nav-cta:hover {
    border-color: rgba(255,255,255,0.2);
    background: linear-gradient(180deg, rgba(255,255,255,0.06) 0%, rgba(255,255,255,0.02) 100%);
}

/* Nav Links with Active State */
.nav-link {
    position: relative;
    padding-bottom: 2px;
}

.nav-link-active::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    transform: translateX(-50%);
    width: 12px;
    height: 1px;
    background: rgba(255,255,255,0.5);
    box-shadow: 0 0 6px rgba(255,255,255,0.2);
}

/* Duel Versus Visualization */
.duel-versus {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    padding: 1.5rem 2rem;
    background: linear-gradient(180deg, rgba(20, 25, 40, 0.5) 0%, rgba(10, 15, 25, 0.7) 100%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(140, 160, 220, 0.1);
    border-radius: 20px;
    box-shadow: 
        0 4px 30px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.duel-trader {
    display: flex;
    align-items: center;
    gap: 0.875rem;
}

.trader-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 500;
    position: relative;
}

.trader-avatar::before {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: 50%;
    padding: 2px;
    background: conic-gradient(
        from 180deg,
        transparent 0deg,
        transparent 200deg,
        rgba(140, 160, 220, 0.4) 260deg,
        rgba(180, 190, 250, 0.8) 300deg,
        rgba(140, 160, 220, 0.3) 340deg,
        transparent 360deg
    );
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    animation: avatarRimRotate 8s linear infinite;
}

.trader-avatar-1 {
    background: linear-gradient(135deg, rgba(52, 211, 153, 0.15) 0%, rgba(52, 211, 153, 0.05) 100%);
    color: rgba(52, 211, 153, 0.9);
}

.trader-avatar-1::before {
    background: conic-gradient(
        from 180deg,
        transparent 0deg,
        transparent 200deg,
        rgba(52, 211, 153, 0.4) 260deg,
        rgba(110, 231, 183, 0.8) 300deg,
        rgba(52, 211, 153, 0.3) 340deg,
        transparent 360deg
    );
}

.trader-avatar-2 {
    background: linear-gradient(135deg, rgba(140, 160, 220, 0.12) 0%, rgba(140, 160, 220, 0.04) 100%);
    color: rgba(255, 255, 255, 0.7);
}

@keyframes avatarRimRotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.trader-info {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.trader-name {
    font-size: 14px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.9);
    letter-spacing: -0.01em;
}

.trader-pnl {
    font-size: 13px;
    font-family: ui-monospace, SFMono-Regular, 'SF Mono', Menlo, monospace;
    font-weight: 500;
}

.versus-badge {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(140, 160, 220, 0.08);
    border: 1px solid rgba(140, 160, 220, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.versus-badge span {
    font-size: 10px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.4);
    letter-spacing: 0.05em;
}

/* Progress Bar */
.duel-progress {
    margin-top: 1rem;
    height: 3px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 2px;
    overflow: hidden;
    position: relative;
}

.duel-progress-fill {
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 52%;
    background: linear-gradient(90deg, rgba(52, 211, 153, 0.6) 0%, rgba(52, 211, 153, 0.8) 100%);
    border-radius: 2px;
    animation: progressPulse 3s ease-in-out infinite;
}

@keyframes progressPulse {
    0%, 100% { opacity: 0.8; }
    50% { opacity: 1; }
}

/* Hero Title Animation - Sleek reveal */
.hero-title-container {
    opacity: 0;
    animation: titleReveal 1.2s cubic-bezier(0.16, 1, 0.3, 1) 0.8s forwards;
}

@keyframes titleReveal {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
        filter: blur(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

/* Hero Content Animations - Staggered with blur */
.hero-animate {
    opacity: 0;
    transform: translateY(25px);
    filter: blur(8px);
    animation: heroReveal 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.hero-animate-2 { animation-delay: 1.6s; }
.hero-animate-3 { animation-delay: 1.9s; }
.hero-animate-4 { animation-delay: 2.2s; }
.hero-animate-5 { animation-delay: 2.5s; }
.hero-animate-6 { animation-delay: 2.8s; }
.hero-animate-7 { animation-delay: 3.1s; }
.hero-animate-8 { animation-delay: 3.4s; }
/* Accent scaling utilities */
.scale-25 { transform: scale(0.25); }
.scale-50 { transform: scale(0.5); }
.scale-75 { transform: scale(0.75); }
.scale-125 { transform: scale(1.25); }
.scale-150 { transform: scale(1.5); }
.scale-200 { transform: scale(2); }

/* Background gradients */
.bg-gradient-radial {
    background: radial-gradient(circle at center, var(--tw-gradient-stops));
}

@keyframes heroReveal {
    from {
        opacity: 0;
        transform: translateY(25px);
        filter: blur(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
        filter: blur(0);
    }
}

/* MASSIVE Genesis text for hero - keeping for reference */
.genesis-massive {
    font-family: var(--font-display);
    font-size: clamp(6rem, 20vw, 22rem);
    font-weight: 600;
    letter-spacing: -0.03em;
    line-height: 0.85;
    color: var(--color-white);
    opacity: 0;
    animation: genesisLargeReveal 1s var(--transition-smooth) 3.4s forwards;
    white-space: nowrap;
}

@keyframes genesisLargeReveal {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* ========================================
   MOBILE RESPONSIVE STYLES
   ======================================== */

/* Hide custom cursor on touch devices */
@media (hover: none) and (pointer: coarse) {
    *, *::before, *::after {
        cursor: auto !important;
    }
    
    .custom-cursor {
        display: none !important;
    }
}

/* Small phones (320px - 374px) */
@media (max-width: 374px) {
    .genesis-massive {
        font-size: clamp(2.5rem, 15vw, 4rem);
    }
    
    .hero-title {
        font-size: 2.75rem !important;
    }
    
    .aurora-beam-2,
    .aurora-beam-3 {
        display: none;
    }
    
}

/* Standard phones (375px - 639px) */
@media (max-width: 639px) {
    .genesis-massive {
        font-size: clamp(3rem, 16vw, 5rem);
        white-space: normal;
        line-height: 0.9;
    }
    
    .hero-section {
        min-height: 100svh;
    }
    
    .hero-title {
        font-size: 3rem !important;
    }
    
    /* Arcs on mobile */
    .arc-upper-1, .arc-upper-glow-1, .arc-upper-glow-2 {
        width: 350%;
        height: 100vh;
        left: -80%;
        top: -72vh;
    }
    
    .arc-upper-2, .arc-upper-3 {
        display: none;
    }
    
    .arc-lower-1, .arc-lower-glow-1, .arc-lower-glow-2 {
        width: 350%;
        height: 100vh;
        left: -80%;
        bottom: -72vh;
    }
    
    .arc-lower-2 {
        display: none;
    }
    
    .horizon-flare {
        left: 8%;
    }
    
    .flare-core::before {
        width: 180px;
    }
    
    .flare-core::after {
        width: 70px;
    }
    
    .horizon-glow-soft {
        width: 90%;
    }
    
    .atmo-glow-1 {
        width: 120%;
        left: -10%;
    }
    
    .atmo-glow-2 {
        width: 90%;
    }
    
    /* Duel versus on mobile */
    .duel-versus {
        padding: 1.25rem 1rem;
        gap: 0.75rem;
        border-radius: 16px;
    }
    
    .trader-avatar {
        width: 40px;
        height: 40px;
        font-size: 11px;
    }
    
    .trader-name {
        font-size: 12px;
    }
    
    .trader-pnl {
        font-size: 11px;
    }
    
    .versus-badge {
        width: 28px;
        height: 28px;
    }
    
    .versus-badge span {
        font-size: 8px;
    }
    
    /* Section padding adjustments */
    section {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }
    
    section.py-32 {
        padding-top: 4rem !important;
        padding-bottom: 4rem !important;
    }
    
    /* Problem/Solution grid */
    .grid.lg\\:grid-cols-2.gap-0 {
        grid-template-columns: 1fr;
    }
    
    .grid.lg\\:grid-cols-2.gap-0 > div {
        padding: 2rem !important;
    }
    
    /* How it works steps */
    .grid.md\\:grid-cols-3 {
        grid-template-columns: 1fr;
    }
    
    .grid.md\\:grid-cols-3 > div {
        border-right: none !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    }
    
    .grid.md\\:grid-cols-3 > div:last-child {
        border-bottom: none;
    }
    
    /* Settlement example */
    .grid.md\\:grid-cols-2.gap-8 {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    /* Duration grid */
    .grid.md\\:grid-cols-2.lg\\:grid-cols-4 {
        grid-template-columns: repeat(2, 1fr);
    }
    
    /* Contract values grid */
    .grid.grid-cols-2.md\\:grid-cols-4 {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .grid.grid-cols-2.md\\:grid-cols-4 > div {
        padding: 1rem !important;
    }
    
    .grid.grid-cols-2.md\\:grid-cols-4 .text-xl {
        font-size: 0.95rem;
    }
    
    /* Benefits grid */
    .grid.md\\:grid-cols-2.lg\\:grid-cols-3 {
        grid-template-columns: 1fr;
    }
    
    /* Comparison section */
    .grid.lg\\:grid-cols-2.gap-px {
        grid-template-columns: 1fr;
    }
    
    .grid.lg\\:grid-cols-2.gap-px > div {
        padding: 2rem !important;
        border-left: none !important;
    }
    
    /* Capital flow grid */
    .grid.lg\\:grid-cols-4 {
        grid-template-columns: repeat(2, 1fr);
    }
    
    /* Proprietary teaser grid */
    .grid.lg\\:grid-cols-2.gap-16 {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    /* Stats grid */
    .grid.grid-cols-3 {
        grid-template-columns: 1fr;
    }
    
    .grid.grid-cols-3 > div {
        padding: 1.25rem !important;
    }
    
    /* Typography adjustments - but NOT for hero h1 */
    section:not(.hero-section) .text-4xl,
    section:not(.hero-section) .text-5xl {
        font-size: 1.75rem !important;
    }
    
    section:not(.hero-section) .text-6xl,
    section:not(.hero-section) .text-7xl,
    section:not(.hero-section) .text-8xl {
        font-size: 2.5rem !important;
    }
    
    .text-3xl {
        font-size: 1.5rem !important;
    }
    
    .text-2xl {
        font-size: 1.25rem !important;
    }
    
    /* Section headers */
    .mb-20 {
        margin-bottom: 2rem !important;
    }
    
    .mb-24 {
        margin-bottom: 3rem !important;
    }
    
    /* CTA buttons - but not hero ones */
    section:not(.hero-section) .flex.flex-col.sm\\:flex-row {
        gap: 0.75rem;
    }
    
    section:not(.hero-section) .flex.flex-col.sm\\:flex-row a {
        width: 100%;
        justify-content: center;
        padding: 1rem 1.5rem;
    }
    
    /* Loading screen logo */
    .genesis-logo {
        font-size: clamp(2.5rem, 15vw, 6rem);
    }
}

/* Tablets and larger phones (640px - 767px) */
@media (min-width: 640px) and (max-width: 767px) {
    .genesis-massive {
        font-size: clamp(4rem, 14vw, 7rem);
    }
    
    .hero-title {
        font-size: 5rem !important;
    }
    
    section.py-32 {
        padding-top: 5rem !important;
        padding-bottom: 5rem !important;
    }
    
    section:not(.hero-section) .text-4xl,
    section:not(.hero-section) .text-5xl {
        font-size: 2.25rem !important;
    }
    
    section:not(.hero-section) .text-6xl,
    section:not(.hero-section) .text-7xl {
        font-size: 3.5rem !important;
    }
    
    /* Stats grid on tablet */
    .grid.grid-cols-3 {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Medium tablets (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
    .genesis-massive {
        font-size: clamp(5rem, 16vw, 10rem);
    }
    
    .hero-title {
        font-size: 6.5rem !important;
    }
    
    section.py-32 {
        padding-top: 6rem !important;
        padding-bottom: 6rem !important;
    }
    
    /* Two column layout for comparison */
    .grid.lg\\:grid-cols-2.gap-px {
        grid-template-columns: 1fr;
    }
    
    /* Capital flow stays 2x2 on tablet */
    .grid.lg\\:grid-cols-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Large tablets / small laptops (1024px+) */
@media (min-width: 1024px) {
    .genesis-massive {
        font-size: clamp(6rem, 18vw, 18rem);
    }
    
    .hero-title {
        font-size: 9rem !important;
    }
    
}

/* Extra large screens (1280px+) */
@media (min-width: 1280px) {
    .hero-title {
        font-size: 12rem !important;
    }
    
}

/* Ultra wide screens (1536px+) */
@media (min-width: 1536px) {
    .hero-title {
        font-size: 14rem !important;
    }
    
}

/* ========================================
   SCROLL REVEAL ANIMATIONS
   ======================================== */
.section-reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: all 1s var(--transition-expo);
}

.section-reveal.active {
    opacity: 1;
    transform: translateY(0);
}

.stagger-1 { transition-delay: 0.05s; }
.stagger-2 { transition-delay: 0.1s; }
.stagger-3 { transition-delay: 0.15s; }
.stagger-4 { transition-delay: 0.2s; }
.stagger-5 { transition-delay: 0.25s; }
.stagger-6 { transition-delay: 0.3s; }

/* ========================================
   MARQUEE
   ======================================== */
.marquee-container {
    overflow: hidden;
    white-space: nowrap;
}

.marquee-content {
    display: inline-block;
    animation: marquee 30s linear infinite;
}

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

/* ========================================
   BUTTONS
   ======================================== */
.btn-primary {
    background: var(--color-white);
    color: var(--color-black);
    padding: 0.75rem 2rem;
    border-radius: 9999px;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-primary:hover {
    background: rgba(255, 255, 255, 0.9);
    transform: translateY(-2px);
}

.btn-secondary {
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: var(--color-white);
    padding: 0.75rem 2rem;
    border-radius: 9999px;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: transparent;
}

.btn-secondary:hover {
    border-color: rgba(255, 255, 255, 0.6);
    background: rgba(255, 255, 255, 0.05);
}

/* ========================================
   CARDS
   ======================================== */
.pricing-card,
.feature-card {
    border: 1px solid rgba(255, 255, 255, 0.2);
    background: transparent;
    transition: all 0.3s ease;
}

.pricing-card:hover,
.feature-card:hover {
    border-color: rgba(255, 255, 255, 0.4);
    background: rgba(255, 255, 255, 0.02);
}

/* ========================================
   PILLS
   ======================================== */
.pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 9999px;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.pill-accent {
    border-color: rgba(255, 255, 255, 0.4);
}

/* ========================================
   UTILITIES
   ======================================== */
.font-display {
    font-family: var(--font-display);
}

.font-body {
    font-family: var(--font-body);
}

/* Loading state */
body.loading {
    overflow: hidden;
}

/* Smooth transitions */
* {
    transition-timing-function: var(--transition-smooth);
}

/* ========================================
   MOBILE MENU ANIMATIONS
   ======================================== */
.mobile-menu-animate {
    animation: slideDown 0.3s ease forwards;
}

@keyframes slideDownMenu {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.mobile-menu-item {
    animation: fadeInUp 0.3s ease forwards;
    opacity: 0;
}

.mobile-menu-item:nth-child(1) { animation-delay: 0.05s; }
.mobile-menu-item:nth-child(2) { animation-delay: 0.1s; }
.mobile-menu-item:nth-child(3) { animation-delay: 0.15s; }
.mobile-menu-item:nth-child(4) { animation-delay: 0.2s; }

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

/* ========================================
   TOUCH DEVICE IMPROVEMENTS
   ======================================== */
@media (hover: none) and (pointer: coarse) {
    /* Increase tap targets */
    a, button {
        min-height: 44px;
        min-width: 44px;
    }
    
    /* Remove hover effects that may cause issues on touch */
    .btn-primary:hover,
    .btn-secondary:hover {
        transform: none;
    }
    
    /* Active states for touch feedback */
    .btn-primary:active {
        background: rgba(255, 255, 255, 0.8);
    }
    
    .btn-secondary:active {
        background: rgba(255, 255, 255, 0.1);
        border-color: rgba(255, 255, 255, 0.5);
    }
}

/* Safe area padding for notched devices */
@supports (padding: max(0px)) {
    .hero-section {
        padding-top: max(5rem, env(safe-area-inset-top) + 4rem);
    }
    
    nav {
        padding-top: env(safe-area-inset-top);
    }
    
    section:last-of-type {
        padding-bottom: max(4rem, env(safe-area-inset-bottom) + 2rem);
    }
}

/* Prevent text size adjustment on orientation change */
html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

/* Smoother scrolling on iOS */
@supports (-webkit-overflow-scrolling: touch) {
    body {
        -webkit-overflow-scrolling: touch;
    }
}

/* Fix for 100vh on mobile browsers */
@media (max-width: 768px) {
    .hero-section {
        min-height: 100svh;
    }
}

/* Ensure videos don't break layout on mobile */
video {
    max-width: 100%;
    height: auto;
}

/* Better button sizing on mobile */
@media (max-width: 639px) {
    .btn-primary,
    .btn-secondary {
        padding: 0.875rem 1.5rem;
        font-size: 0.875rem;
    }
}

/* Hide scrollbar utility */
.scrollbar-hide {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.scrollbar-hide::-webkit-scrollbar {
    display: none;
}

/* Prevent horizontal overflow on body */
html, body {
    overflow-x: hidden;
    max-width: 100vw;
}

/* Fix any potential overflow issues */
.overflow-hidden {
    overflow: hidden !important;
}
