:root {
    scroll-behavior: smooth;
    /* Colors */
    --bg-color: #050505;
    --bg-secondary: #0a0a0a;
    --text-main: #ffffff;
    --text-secondary: #a1a1aa;

    --accent-primary: #6366f1;
    --accent-secondary: #a855f7;
    --accent-glow: #3b82f6;

    /* Typography */
    --font-heading: 'Space Grotesk', sans-serif;
    --font-body: 'Inter', sans-serif;

    /* Spacing */
    --container-padding: 2rem;

    /* Effects */
    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);
    --card-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.5);
    --glow-shadow: 0 0 40px rgba(99, 102, 241, 0.2);
    --cursor-size: 20px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-color);
    color: var(--text-main);
    overflow-x: hidden;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Custom Cursor (Disabled for performance) */
.cursor {
    display: none;
}

.cursor-dot {
    display: none;
}

.cursor.hovered {
    display: none;
}

/* Base Animations */
@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale3d(0.95, 0.95, 1) translate3d(0, 20px, 0);
    }

    to {
        opacity: 1;
        transform: scale3d(1, 1, 1) translate3d(0, 0, 0);
    }
}

/* Background Effects */
.background-effects {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}

.noise-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.03;
    /* Reduced opacity for subtler effect */
    background: url('data:image/svg+xml;utf8,%3Csvg viewBox="0 0 200 200" xmlns="http://www.w3.org/2000/svg"%3E%3Cfilter id="noiseFilter"%3E%3CfeTurbulence type="fractalNoise" baseFrequency="0.65" numOctaves="3" stitchTiles="stitch"/%3E%3C/filter%3E%3Crect width="100%25" height="100%25" filter="url(%23noiseFilter)"/%3E%3C/svg%3E');
    pointer-events: none;
}

.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    /* Original blur value */
    opacity: 0.25;
    will-change: auto;
    transform: translate3d(0, 0, 0);
}

.orb-1 {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--accent-primary) 0%, var(--accent-primary) 20%, transparent 70%);
    top: -200px;
    left: -100px;
   /* animation: float 20s ease-in-out infinite;*/
}

.orb-2 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--accent-secondary) 0%, var(--accent-secondary) 20%, transparent 70%);
    bottom: -100px;
    right: -100px;
    /*animation: float 25s ease-in-out infinite reverse;*/все
}

.grid-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
    background-size: 40px 40px;
    mask-image: radial-gradient(circle at center, black 30%, transparent 80%);
}

@keyframes float {

    0%,
    100% {
        transform: translate3d(0, 0, 0);
    }

    25% {
        transform: translate3d(20px, 30px, 0);
    }

    50% {
        transform: translate3d(-20px, 50px, 0);
    }

    75% {
        transform: translate3d(-30px, 20px, 0);
    }
}

/* Layout */
#app {
    width: 100%;
    min-height: 100vh;
    position: relative;
    max-width: 100vw;
    overflow: hidden;
}

.screen {
    display: none;
    /* Changed via JS */
    min-height: 100vh;
    padding: var(--container-padding);
    padding-top: 120px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0;
}

/* Active screen animation handled by JS/CSS class */
.screen.active {
    display: flex;
    animation: fadeInScreen 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes fadeInScreen {
    from {
        opacity: 0;
        transform: scale3d(0.98, 0.98, 1);
        filter: blur(10px);
    }

    to {
        opacity: 1;
        transform: scale3d(1, 1, 1);
        filter: blur(0);
    }
}

#quiz-container,
#lead-form {
    justify-content: flex-start;
}

/* Typography */
h1,
h2,
h3 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1;
    letter-spacing: -0.02em;
}

.gradient-text {
    background: linear-gradient(135deg, #fff 30%, var(--accent-glow) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

/* Reveal Text Animation */
.word {
    display: inline-block;
    overflow: hidden;
    vertical-align: bottom;
}

.char {
    display: inline-block;
    transform: translate3d(0, 100%, 0);
    opacity: 0;
    animation: revealChar 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    will-change: transform, opacity;
}

@keyframes revealChar {
    to {
        transform: translate3d(0, 0, 0);
        opacity: 1;
    }
}

/* Header */
.main-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1.5rem 3rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;
    transition: padding 0.4s ease;
}

.main-header.scrolled {
    padding: 1rem 3rem;
    background: rgba(5, 5, 5, 0.6);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.logo {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.8rem;
    color: var(--text-main);
    letter-spacing: -1px;
    mix-blend-mode: overlay;
    transition: transform 0.3s;
    will-change: transform;
}

.logo:hover {
    transform: scale3d(1.05, 1.05, 1);
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 2.5rem;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: var(--text-main);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 100%;
    height: 1px;
    background: var(--accent-primary);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-link:hover::after {
    transform: scaleX(1);
    transform-origin: left;
}

/* Buttons */
.btn-primary {
    position: relative;
    background: var(--text-main);
    color: black;
    border: none;
    padding: 1.2rem 3rem;
    font-size: 1.1rem;
    font-weight: 700;
    border-radius: 100px;
    cursor: none;
    /* Custom cursor handles this */
    overflow: hidden;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 1;
    will-change: transform;
    transform: translateZ(0);
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary));
    z-index: -1;
    transition: opacity 0.3s ease;
    opacity: 0;
}

.btn-primary:hover {
    transform: scale3d(1.05, 1.05, 1);
    color: white;
}

.btn-primary:hover::before {
    opacity: 1;
}

.btn-glow {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.4) 0%, transparent 70%);
    transform: scale3d(0, 0, 1);
    transition: transform 0.6s ease;
    pointer-events: none;
    will-change: transform;
}

.btn-primary:hover .btn-glow {
    transform: scale3d(1, 1, 1);
    transition: transform 0.6s ease;
}

.btn-secondary {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--glass-border);
    padding: 1rem 2.5rem;
    font-size: 1rem;
    font-weight: 500;
    border-radius: 100px;
    cursor: none;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    color: var(--text-main);
    border-color: var(--text-main);
}

.btn-secondary.hidden {
    display: none;
}

/* Welcome Screen */
#welcome .content-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
    gap: 5%;
}

.text-block {
    flex: 1;
    text-align: left;
    max-width: 650px;
}

.hero-tagline {
    font-size: 0.9rem;
    color: var(--accent-primary);
    text-transform: uppercase;
    letter-spacing: 4px;
    margin-bottom: 2rem;
    font-weight: 700;
    display: block;
}

.hero-title {
    font-size: clamp(3.5rem, 6vw, 5.5rem);
    margin-bottom: 2rem;
    letter-spacing: -2px;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 4rem;
    line-height: 1.6;
    max-width: 90%;
}

.video-container {
    width: 100%;
    max-width: 350px;
    aspect-ratio: 9/16;
    border-radius: 40px;
    position: relative;
    overflow: hidden;
    box-shadow: 20px 20px 60px rgba(0, 0, 0, 0.5);
    background: #000;
}

.video-container:hover {
    /* Animation removed */
}

.hero-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.2);
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.3s;
    will-change: opacity;
}

.play-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.3s ease;
    will-change: transform;
    transform: translateZ(0);
}

.play-icon:hover {
    transform: scale3d(1.2, 1.2, 1);
    background: var(--text-main);
}

.play-icon:hover::after {
    border-color: transparent transparent transparent black;
}

.play-icon::after {
    content: '';
    border-style: solid;
    border-width: 10px 0 10px 18px;
    border-color: transparent transparent transparent white;
    margin-left: 4px;
    transition: border-color 0.3s;
}

/* Quiz Container */
.progress-bar-container {
    width: 100%;
    max-width: 600px;
    margin-bottom: 4rem;
    text-align: center;
}

.progress-bar {
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    margin-bottom: 1rem;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: var(--text-main);
    width: 100%;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
    box-shadow: 0 0 20px var(--text-main);
    will-change: transform;
}

.step-indicator {
    color: var(--text-secondary);
    font-family: var(--font-heading);
    letter-spacing: 1px;
}

.quiz-content {
    width: 100%;
    max-width: 900px;
}

.quiz-step {
    display: none;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

.quiz-step.active {
    display: flex;
}

.question-title {
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 3rem;
    text-align: center;
    background: linear-gradient(to bottom, #fff, #999);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.options-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    width: 100%;
}

.option-card {
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02));
    border: 1px solid var(--glass-border);
    padding: 3rem 2rem;
    border-radius: 24px;
    color: var(--text-main);
    text-align: center;
    font-size: 1.5rem;
    font-weight: 500;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    position: relative;
    overflow: hidden;
    will-change: transform;
    transform: translateZ(0);
}

/* Spotlight effect handled by JS, but base hover: */
.option-card:hover {
    border-color: var(--accent-primary);
    transform: translate3d(0, -5px, 0);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.option-card.selected {
    background: var(--accent-primary);
    border-color: var(--accent-primary);
    box-shadow: 0 0 30px rgba(99, 102, 241, 0.4);
}

.quiz-controls {
    width: 100%;
    max-width: 800px;
    display: flex;
    justify-content: flex-start;
    margin-top: 2rem;
}

/* Form */
.form-container {
    background: rgba(10, 10, 10, 0.7);
    border: 1px solid var(--glass-border);
    padding: 2rem;
    border-radius: 32px;
    width: 100%;
    max-width: 550px;
    backdrop-filter: blur(20px);
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.5);
    margin: auto;
}

.form-title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    text-align: center;
}

.form-subtitle {
    color: var(--text-secondary);
    text-align: center;
    margin-bottom: 2.5rem;
}

.input-group {
    position: relative;
    margin-bottom: 1.5rem;
}

.input-group label {
    position: absolute;
    left: 1.2rem;
    top: 1.2rem;
    color: var(--text-secondary);
    pointer-events: none;
    transition: all 0.3s ease;
    background: transparent;
}

/* Float label */
.input-group input:focus~label,
.input-group input:not(:placeholder-shown)~label {
    top: -0.6rem;
    left: 1rem;
    font-size: 0.8rem;
    color: var(--accent-primary);
    background: var(--bg-color);
    padding: 0 0.4rem;
}

.input-group input {
    width: 100%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 1.2rem;
    border-radius: 16px;
    color: white;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    outline: none;
}

.input-group input:focus {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

.full-width {
    width: 100%;
    margin-top: 2rem;
}

.input-group.error input {
    border-color: #ef4444;
}

.input-group.error label {
    color: #ef4444;
}

/* Thank You */
.thank-you-content {
    text-align: center;
}

.thank-you-title {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.thank-you-text {
    font-size: 1.2rem;
    color: var(--text-secondary);
}

.success-icon {
    width: 100px;
    height: 100px;
    background: var(--accent-primary);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 3rem;
    margin: 0 auto 2rem;
    box-shadow: 0 0 40px rgba(99, 102, 241, 0.5);
}

.success-icon::after {
    content: '✓';
    color: white;
}

/* Mobile Menus */
.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: var(--bg-color);
    z-index: 101;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.mobile-menu.active {
    opacity: 1;
    pointer-events: auto;
}

.mobile-menu-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
}

.mobile-link {
    font-size: 1.5rem;
    color: var(--text-main);
    text-decoration: none;
}

/* Hide mobile button on desktop by default */
.mobile-btn {
    display: none;
}

/* Mobile Responsive */
@media (max-width: 768px) {

    .cursor,
    .cursor-dot {
        display: none !important;
    }

    * {
        cursor: auto !important;
    }

    .main-header {
        padding: 1rem 1.5rem;
    }

    #welcome {
        padding-top: 100px;
    }

    #welcome .content-wrapper {
        flex-direction: column;
        gap: 3rem;
    }

    .text-block,
    .visual-block {
        max-width: 100%;
        width: 100%;
        text-align: center;
    }

    .hero-title {
        font-size: 3rem;
    }

    .hero-subtitle {
        margin: 0 auto 2rem;
    }

    .desktop-btn {
        display: none;
    }

    .mobile-btn {
        display: inline-block;
        margin-top: 40px;
    }

    .video-container {
        transform: none;
        width: 100%;
        max-width: 300px;
        margin: 0 auto;
    }

    .options-grid {
        grid-template-columns: 1fr;
    }

    /* Reveal text fallback for mobile */
    .char {
        animation: none;
        opacity: 1;
        transform: none;
    }
}