/* Custom CSS Variables for Theme */
:root {
    --bg-color: #0B0E14;
    --bg-color-rgb: 11, 14, 20;
    --text-primary: #F3F4F6;
    --text-secondary: #9CA3AF;
    --text-muted: #6B7280;

    /* Brand Gradients & Colors */
    --accent-blue: #00D2FF;
    --accent-purple: #3A7BD5;
    --accent-pink: #FF007A;

    --brand-gradient: linear-gradient(135deg, var(--accent-blue) 0%, var(--accent-purple) 100%);
    --brand-gradient-hover: linear-gradient(135deg, #33DBFF 0%, #689FE3 100%);

    /* Layout */
    --font-sans: 'Inter', -apple-system, sans-serif;
    --font-mono: 'Fira Code', monospace;
    --container-width: 1200px;
    --nav-height: 80px;

    /* Borders & Glassmorphism */
    --border-color: rgba(255, 255, 255, 0.1);
    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: 1px solid rgba(255, 255, 255, 0.08);
    --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    --glass-blur: blur(12px);

    /* Animations */
    --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-medium: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-sans);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color var(--transition-fast);
}

ul {
    list-style: none;
}

/* Layout Utilities */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
}

.gradient-text {
    background: var(--brand-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

/* Typography */
h1,
h2,
h3,
h4 {
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.section-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    margin-bottom: 16px;
}

.section-subtitle {
    font-size: clamp(1.1rem, 2vw, 1.25rem);
    color: var(--text-secondary);
    max-width: 600px;
}

.center {
    text-align: center;
    margin: 0 auto 64px auto;
    max-width: 800px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Glassmorphism Utilities */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: var(--glass-border);
    border-radius: 24px;
    box-shadow: var(--glass-shadow);
    overflow: hidden;
}

.glass-panel {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0.01) 100%);
    backdrop-filter: var(--glass-blur);
    border: var(--glass-border);
    border-radius: 20px;
    transition: transform var(--transition-medium), box-shadow var(--transition-medium);
}

.glass-panel:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5), inset 0 0 0 1px rgba(255, 255, 255, 0.2);
}

/* Buttons */
.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 99px;
    font-weight: 500;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all var(--transition-fast);
    border: none;
    outline: none;
}

.btn-primary {
    background: var(--brand-gradient);
    color: white;
    box-shadow: 0 4px 15px rgba(58, 123, 213, 0.3);
}

.btn-primary:hover {
    background: var(--brand-gradient-hover);
    box-shadow: 0 6px 20px rgba(58, 123, 213, 0.5);
    transform: translateY(-2px);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
}

.btn-ghost:hover {
    color: var(--text-primary);
}

.btn-large {
    padding: 16px 32px;
    font-size: 1.1rem;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--nav-height);
    background: rgba(11, 14, 20, 0.7);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    z-index: 1000;
    transition: background var(--transition-fast);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 800;
    font-size: 1.4rem;
    letter-spacing: -0.03em;
}

.logo-icon {
    font-size: 2rem;
    color: var(--accent-blue);
    background: var(--brand-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-links {
    display: flex;
    gap: 32px;
}

.nav-link {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.nav-link:hover {
    color: var(--text-primary);
}

.nav-cta {
    display: flex;
    gap: 16px;
    align-items: center;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.5rem;
    cursor: pointer;
}

/* Hero Section */
.hero {
    position: relative;
    padding: calc(var(--nav-height) + 80px) 0 100px;
    min-height: 100vh;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.hero-bg-blur {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.15;
    z-index: 0;
}

.glow-1 {
    top: 10%;
    left: -10%;
    width: 60vw;
    height: 60vw;
    background: var(--accent-blue);
}

.glow-2 {
    bottom: -20%;
    right: -10%;
    width: 50vw;
    height: 50vw;
    background: var(--accent-purple);
}

.hero-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 64px;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-content {
    max-width: 600px;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 16px;
    background: rgba(0, 210, 255, 0.1);
    border: 1px solid rgba(0, 210, 255, 0.2);
    border-radius: 99px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--accent-blue);
    margin-bottom: 24px;
}

.badge-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent-blue);
    box-shadow: 0 0 10px var(--accent-blue);
}

.hero-title {
    font-size: clamp(3rem, 6vw, 4.5rem);
    margin-bottom: 24px;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 40px;
}

.hero-cta {
    display: flex;
    gap: 16px;
    margin-bottom: 48px;
}

.hero-stats {
    display: flex;
    gap: 24px;
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.stat-item i {
    color: #10B981;
    /* Emerald green */
}

/* Editor Mockup */
.editor-card {
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.6), 0 0 40px rgba(0, 210, 255, 0.1);
    transform-style: preserve-3d;
    transform: perspective(1000px);
}

.editor-card * {
    transform-style: preserve-3d;
}

.editor-header {
    background: rgba(0, 0, 0, 0.4);
    padding: 12px 16px;
    display: flex;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transform: translateZ(30px);
}

.window-controls {
    display: flex;
    gap: 8px;
}

.window-controls span {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #FF5F56;
}

.window-controls span:nth-child(2) {
    background: #FFBD2E;
}

.window-controls span:nth-child(3) {
    background: #27C93F;
}

.window-title {
    flex-grow: 1;
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-muted);
    font-family: var(--font-mono);
}

.editor-body {
    position: relative;
    aspect-ratio: 16/10;
    overflow: hidden;
}

.editor-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.7;
}

.ai-typing-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) translateZ(60px);
    width: 85%;
    background: rgba(11, 14, 20, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(8px);
}

.ai-prompt {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--accent-blue);
    font-size: 0.95rem;
    font-weight: 500;
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.1);
}

.code-typing pre {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: #E5E7EB;
    line-height: 1.5;
    margin: 0;
}

.language-python {
    color: #fff;
}

.cursor-blink {
    animation: blink 1s step-end infinite;
}

@keyframes blink {
    50% {
        opacity: 0;
    }
}

/* Animations */
.fade-up {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeUp 0.8s forwards;
}

@keyframes fadeUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.scroll-reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: all 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.scroll-reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Coding Maze Section */
.maze-section {
    height: 400vh;
    /* Enables long scrolling */
    position: relative;
    background-color: var(--bg-color);
    z-index: 2;
}

.maze-sticky {
    position: sticky;
    top: 0;
    height: 100vh;
    width: 100%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.maze-perspective {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    perspective: 1200px;
    perspective-origin: 50% 50%;
    background: radial-gradient(circle at center, rgba(11, 14, 20, 0) 0%, rgba(11, 14, 20, 0.8) 70%, rgba(11, 14, 20, 1) 100%);
    z-index: 1;
}

.maze-scene {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    transform: translate(-50%, -50%) translateZ(0px);
    will-change: transform;
}

.maze-wall {
    position: absolute;
    background: rgba(11, 14, 20, 0.7);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(0, 210, 255, 0.15);
    border-radius: 8px;
    padding: 24px;
    box-shadow: 0 0 30px rgba(0, 210, 255, 0.05), inset 0 0 20px rgba(0, 210, 255, 0.05);
    color: rgba(230, 230, 250, 0.7);
    font-family: var(--font-mono);
    font-size: 0.85rem;
    line-height: 1.5;
    overflow: hidden;
    white-space: pre-wrap;
}

.maze-wall pre {
    margin: 0;
}

.maze-wall .keyword {
    color: #FF416C;
    font-weight: bold;
}

.maze-wall .function {
    color: #00D2FF;
}

.maze-wall .string {
    color: #10B981;
}

.maze-wall .comment {
    color: #6B7280;
    font-style: italic;
}

.maze-overlay {
    position: relative;
    z-index: 10;
    text-align: center;
    max-width: 800px;
    padding: 0 24px;
    pointer-events: none;
    background: rgba(11, 14, 20, 0.7);
    backdrop-filter: blur(12px);
    border-radius: 20px;
    padding: 30px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.fade-in-out {
    opacity: 1;
    transition: opacity 0.5s ease;
}

/* Ticker Section */
.ticker-section {
    padding: 40px 0;
    border-bottom: 1px solid var(--border-color);
    border-top: 1px solid var(--border-color);
    background: rgba(255, 255, 255, 0.01);
    overflow: hidden;
}

.ticker-title {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 24px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.ticker-container {
    width: 100%;
    overflow: hidden;
}

.ticker-track {
    display: flex;
    width: max-content;
    animation: ticker 30s linear infinite;
}

.ticker-track:hover {
    animation-play-state: paused;
}

.ticker-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-secondary);
    padding: 0 40px;
    opacity: 0.6;
    transition: opacity var(--transition-fast);
}

.ticker-item:hover {
    opacity: 1;
    color: var(--text-primary);
}

.ticker-item i {
    font-size: 1.8rem;
}

@keyframes ticker {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* Features Grid */
.features {
    padding: 120px 0;
    position: relative;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
}

.feature-card {
    padding: 40px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.feature-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin-bottom: 8px;
    color: white;
}

.bg-gradient-1 {
    background: linear-gradient(135deg, #00D2FF, #3A7BD5);
    box-shadow: 0 4px 20px rgba(0, 210, 255, 0.3);
}

.bg-gradient-2 {
    background: linear-gradient(135deg, #FF416C, #FF4B2B);
    box-shadow: 0 4px 20px rgba(255, 65, 108, 0.3);
}

.bg-gradient-3 {
    background: linear-gradient(135deg, #8E2DE2, #4A00E0);
    box-shadow: 0 4px 20px rgba(142, 45, 226, 0.3);
}

.bg-gradient-4 {
    background: linear-gradient(135deg, #f12711, #f5af19);
    box-shadow: 0 4px 20px rgba(241, 39, 17, 0.3);
}

.feature-title {
    font-size: 1.5rem;
}

.feature-desc {
    color: var(--text-secondary);
}

/* How It Works */
.how-it-works {
    padding: 120px 0;
}

.workflow-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 64px;
    align-items: center;
}

.steps-list {
    margin-top: 48px;
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.step-item {
    display: flex;
    gap: 24px;
    opacity: 0.5;
    transition: opacity var(--transition-medium);
    cursor: pointer;
}

.step-item:hover {
    opacity: 0.8;
}

.step-item.active {
    opacity: 1;
}

.step-number {
    font-size: 1.2rem;
    font-weight: 800;
    font-family: var(--font-mono);
    color: var(--accent-blue);
    padding-top: 4px;
}

.step-text h4 {
    font-size: 1.25rem;
    margin-bottom: 8px;
}

.step-text p {
    color: var(--text-secondary);
}

.visual-box {
    padding: 24px;
    transform-style: preserve-3d;
    transform: perspective(1000px);
}

.visual-box * {
    transform-style: preserve-3d;
}

.mock-terminal {
    background: #000;
    border-radius: 12px;
    overflow: hidden;
    font-family: var(--font-mono);
    border: 1px solid #333;
    transform: translateZ(50px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
}

.term-header {
    background: #111;
    padding: 12px;
    display: flex;
    gap: 8px;
    align-items: center;
    border-bottom: 1px solid #333;
}

.term-header span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #555;
}

.term-title {
    margin-left: auto;
    margin-right: auto;
    font-size: 0.8rem;
    color: #888;
}

.term-body {
    padding: 24px;
    font-size: 0.9rem;
    color: #eee;
    line-height: 1.8;
    min-height: 250px;
}

.term-line {
    margin-bottom: 4px;
}

.prompt {
    color: #50fa7b;
}

.cmd {
    color: #f8f8f2;
}

.loading {
    color: #8be9fd;
}

.success {
    color: #50fa7b;
}

/* CTA Section */
.cta-section {
    padding: 120px 0;
    position: relative;
    text-align: center;
}

.cta-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(58, 123, 213, 0.15) 0%, rgba(0, 0, 0, 0) 70%);
    z-index: 0;
}

.cta-box {
    padding: 64px 40px;
    position: relative;
    z-index: 1;
    max-width: 800px;
    margin: 0 auto;
}

.cta-title {
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 16px;
}

.cta-text {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 40px;
}

.cta-form {
    display: flex;
    gap: 16px;
    justify-content: center;
    margin-bottom: 16px;
}

.glass-input {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 99px;
    padding: 0 24px;
    color: white;
    font-family: var(--font-sans);
    min-width: 300px;
    outline: none;
    transition: all var(--transition-fast);
}

.glass-input:focus {
    border-color: var(--accent-blue);
    background: rgba(255, 255, 255, 0.1);
}

.form-subtext {
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* Footer */
.footer {
    border-top: 1px solid var(--border-color);
    padding: 80px 0 40px;
    background: rgba(0, 0, 0, 0.2);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 64px;
    margin-bottom: 64px;
}

.footer-desc {
    color: var(--text-secondary);
    margin: 24px 0;
    max-width: 300px;
}

.social-links {
    display: flex;
    gap: 16px;
}

.social-links a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: var(--text-secondary);
}

.social-links a:hover {
    background: var(--brand-gradient);
    color: white;
}

.footer-links h4 {
    margin-bottom: 24px;
    font-size: 1.1rem;
}

.footer-links a {
    display: block;
    color: var(--text-secondary);
    margin-bottom: 12px;
}

.footer-links a:hover {
    color: var(--text-primary);
}

.footer-bottom {
    text-align: center;
    color: var(--text-muted);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 32px;
}

/* Responsive */
@media (max-width: 992px) {
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-content {
        margin: 0 auto;
    }

    .hero-cta {
        justify-content: center;
    }

    .hero-stats {
        justify-content: center;
    }

    .workflow-container {
        grid-template-columns: 1fr;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 40px;
    }

    /* Center Badge */
    .badge {
        margin-left: auto;
        margin-right: auto;
    }
}

@media (max-width: 768px) {

    .nav-links,
    .nav-cta {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
    }

    .cta-form {
        flex-direction: column;
    }

    .glass-input {
        min-width: 100%;
        padding: 16px 24px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }
}