:root {
    --bg-color: #0a0a0f;
    --surface-color: #161621;
    --primary-color: #4f46e5;
    --primary-hover: #6366f1;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --gradient-start: #38bdf8;
    --gradient-end: #818cf8;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3 { font-family: 'Outfit', sans-serif; }

.gradient-text {
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Navbar */
.navbar {
    display: flex; justify-content: space-between; align-items: center;
    padding: 1.5rem 5%; background: rgba(10, 10, 15, 0.8);
    backdrop-filter: blur(10px); position: fixed; width: 100%; z-index: 100;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}
.logo { font-size: 1.5rem; font-weight: 900; }
.logo span { color: var(--gradient-start); }
.nav-links a { color: var(--text-muted); text-decoration: none; margin: 0 1.5rem; font-weight: 500; transition: 0.3s; }
.nav-links a:hover { color: var(--text-main); }
.nav-dropdown { position: relative; display: inline-block; padding-bottom: 20px; margin-bottom: -20px; z-index: 200; }
.nav-dropdown-content { position: absolute; background: rgba(20,20,30,0.95); min-width: 130px; box-shadow: 0px 8px 24px rgba(0,0,0,0.6); padding: 0.5rem; border-radius: 8px; border: 1px solid rgba(255,255,255,0.1); top: 100%; left: 0; opacity: 0; pointer-events: none; transform: translateY(10px); transition: 0.2s; display: flex; flex-direction: column; gap: 0.2rem; margin-top: 0;}
.nav-dropdown:hover .nav-dropdown-content { opacity: 1; pointer-events: all; transform: translateY(0); }
.nav-dropdown-content a { margin: 0; padding: 0.5rem 1rem; border-radius: 4px; }
.nav-dropdown-content a:hover { background: rgba(255,255,255,0.08); }

/* Buttons */
.btn-primary {
    background: var(--primary-color); color: white; padding: 0.8rem 1.8rem;
    border-radius: 50px; text-decoration: none; font-weight: 600; border: none; cursor: pointer; transition: 0.3s;
}
.btn-primary:hover { background: var(--primary-hover); box-shadow: 0 0 20px rgba(79, 70, 229, 0.4); }
.btn-secondary { background: rgba(255,255,255,0.1); color: white; padding: 0.8rem 1.8rem; border-radius: 50px; text-decoration: none; font-weight: 600; transition: 0.3s; }
.btn-secondary:hover { background: rgba(255,255,255,0.2); }
.btn-primary.small { padding: 0.5rem 1.2rem; font-size: 0.9rem; }

/* Hero */
.hero {
    min-height: 100vh; display: flex; align-items: center; justify-content: space-between;
    padding: 8rem 5% 4rem; gap: 4rem;
    background: radial-gradient(circle at top right, rgba(79, 70, 229, 0.15), transparent 50%);
}
.hero-content { flex: 1.2; }
.badge { display: inline-block; padding: 0.4rem 1rem; background: rgba(56, 189, 248, 0.1); color: var(--gradient-start); border-radius: 50px; font-size: 0.85rem; font-weight: 600; margin-bottom: 1.5rem; border: 1px solid rgba(56, 189, 248, 0.2); }
.hero-title { font-size: 4rem; line-height: 1.1; margin-bottom: 1.5rem; }
.hero-subtitle { font-size: 1.2rem; color: var(--text-muted); margin-bottom: 2.5rem; max-width: 90%; }
.hero-cta { display: flex; gap: 1rem; }
.hero-visual { flex: 1; perspective: 1000px; }

/* Mockup */
.software-mockup {
    background: #1e1e2d; border-radius: 12px; border: 1px solid rgba(255,255,255,0.1);
    box-shadow: 0 25px 50px -12px rgba(0,0,0,0.5); overflow: hidden;
    transform: rotateY(-5deg) rotateX(2deg); transition: 0.5s;
}
.software-mockup:hover { transform: rotateY(0) rotateX(0); }
.mockup-header { background: rgba(0,0,0,0.5); padding: 0.8rem 1rem; display: flex; align-items: center; gap: 0.5rem; border-bottom: 1px solid rgba(255,255,255,0.05); }
.dot { width: 12px; height: 12px; border-radius: 50%; }
.dot.red { background: #ff5f56; } .dot.yellow { background: #ffbd2e; } .dot.green { background: #27c93f; }
.mockup-title { color: #888; font-size: 0.8rem; margin-left: auto; margin-right: auto; font-family: monospace;}

.mockup-body { display: flex; height: 380px; }
.sidebar { width: 45%; background: rgba(0,0,0,0.2); border-right: 1px solid rgba(255,255,255,0.05); padding: 1rem; display: flex; flex-direction: column; gap: 1rem; overflow-y: auto;}
.chat-bubble { padding: 0.8rem; border-radius: 8px; font-size: 0.85rem; line-height: 1.4;}
.chat-bubble.ai { background: rgba(79, 70, 229, 0.15); color: #cbd5e1; border-left: 3px solid var(--primary-color);}
.chat-bubble.user { background: rgba(255,255,255,0.05); text-align: right; align-self: flex-end; color: #fff;}

.timeline-area { flex: 1; display: flex; flex-direction: column; background: #161621;}
.video-preview { flex: 2; background: #000; border-bottom: 1px solid rgba(255,255,255,0.05); display: flex; align-items: center; justify-content: center;}
.play-btn { width: 40px; height: 40px; background: rgba(255,255,255,0.2); border-radius: 50%; display: flex; align-items: center; justify-content: center; color: white; padding-left: 3px; cursor: pointer;}
.timeline-tracks { flex: 1.2; padding: 1rem; display: flex; flex-direction: column; gap: 0.8rem; background: rgba(0,0,0,0.3);}
.track { height: 24px; border-radius: 4px; background: rgba(255,255,255,0.05); width: 100%; position: relative; display: flex; align-items: center;}
.track span { font-size: 0.65rem; color: #fff; z-index: 2; position: absolute; left: 10px; opacity: 0.8;}
.track::after { content:''; position:absolute; height:100%; border-radius:4px; z-index: 1;}
.block-1::after { width: 80%; left: 5%; background: linear-gradient(90deg, #4f46e5, #818cf8); opacity: 0.5;}
.block-2::after { width: 60%; left: 15%; background: linear-gradient(90deg, #0ea5e9, #38bdf8); opacity: 0.5;}
.block-3::after { width: 90%; left: 0%; background: linear-gradient(90deg, #10b981, #34d399); opacity: 0.5;}

/* Sections */
.features, .technology { padding: 6rem 5%; }
.section-title { font-size: 2.8rem; margin-bottom: 1.5rem; text-align: center;}
.section-title.left { text-align: left; }

.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 2rem; }
.feature-card { background: var(--surface-color); padding: 2rem; border-radius: 12px; border: 1px solid rgba(255,255,255,0.05); transition: 0.3s; }
.feature-card:hover { transform: translateY(-5px); border-color: rgba(255,255,255,0.1); }
.icon { font-size: 2rem; margin-bottom: 1rem; display: inline-block;}
.feature-card h3 { font-size: 1.3rem; margin-bottom: 0.8rem; }
.feature-card p { color: var(--text-muted); font-size: 0.95rem; line-height: 1.5;}

.tech-content h3 { font-size: 1.5rem; margin-bottom: 1rem; color: var(--text-main);}
.tech-content p { color: var(--text-muted); font-size: 1.05rem;}

/* CTA */
.cta-section { padding: 6rem 5%; text-align: center; background: linear-gradient(0deg, rgba(79, 70, 229, 0.1) 0%, transparent 100%); }
.cta-section h2 { font-size: 3rem; margin-bottom: 1rem; }
.cta-section p { color: var(--text-muted); margin-bottom: 2rem; font-size: 1.1rem;}
.waitlist-form { display: flex; justify-content: center; gap: 1rem; max-width: 500px; margin: 0 auto; }
.waitlist-form input { flex: 1; padding: 1rem 1.5rem; border-radius: 50px; border: 1px solid rgba(255,255,255,0.2); background: rgba(0,0,0,0.5); color: white; outline: none; }
.waitlist-form input:focus { border-color: var(--primary-color); }

footer { text-align: center; padding: 2rem; border-top: 1px solid rgba(255,255,255,0.05); color: var(--text-muted); }

@media (max-width: 768px) {
    .hero { flex-direction: column; padding-top: 6rem;}
    .hero-title { font-size: 2.5rem; }
    .nav-links { display: none; }
    .software-mockup { transform: none; }
    .mockup-body { flex-direction: column; height: auto;}
    .sidebar { width: 100%; height: 250px;}
    .timeline-area { height: 300px;}
    #ide-demo > div:last-child { flex-direction: column !important; height: auto !important; }
    #chat-sidebar { width: 100% !important; height: 320px !important; }
}

/* IDE Demo Animations */
@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

@keyframes fadeSlideUp {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.4); }
}

/* Chat scrollbar */
#chat-messages::-webkit-scrollbar { width: 4px; }
#chat-messages::-webkit-scrollbar-track { background: transparent; }
#chat-messages::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 4px; }
#chat-messages::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.2); }
#ai-messages::-webkit-scrollbar { width: 3px; }
#ai-messages::-webkit-scrollbar-track { background: transparent; }
#ai-messages::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.08); border-radius:3px; }

/* Timeline rows/labels */
.tl-label {
    flex: 1; display: flex; align-items: center;
    padding: 0 0.6rem; font-size: 0.62rem; color: #2a2a3a;
    font-weight: 500; border-bottom: 1px solid rgba(255,255,255,0.03);
    white-space: nowrap;
}
.tl-row {
    position: absolute; left: 0; right: 0; height: 22px;
    display: flex; align-items: center; gap: 2px;
}

/* Timeline clip blocks */
.tl-clip {
    height: 100%; border-radius: 3px; position: absolute;
    display: flex; align-items: center; overflow: hidden;
    cursor: default; transition: filter 0.2s, box-shadow 0.2s;
    border: 1px solid rgba(255,255,255,0.08);
}
.tl-clip:hover { filter: brightness(1.15); }
.tl-clip.selected {
    box-shadow: 0 0 0 1.5px rgba(79,70,229,0.8);
    filter: brightness(1.1);
}
.tl-clip-label {
    font-size: 0.55rem; color: rgba(255,255,255,0.65);
    padding: 0 0.35rem; white-space: nowrap; overflow: hidden;
    text-overflow: ellipsis; pointer-events: none;
}
/* Clip resize handle */
.tl-clip::after {
    content: ''; position: absolute; right: 0; top: 0; bottom: 0;
    width: 4px; background: rgba(255,255,255,0.15); cursor: ew-resize;
}

/* Media bin items */
.media-clip:hover { background: rgba(255,255,255,0.04) !important; border-color: rgba(255,255,255,0.07) !important; }
.media-clip.active  { background: rgba(79,70,229,0.12) !important; border-color: rgba(79,70,229,0.3) !important; }

/* Inspector rows */
.inspector-row {
    display: flex; justify-content: space-between; align-items: center;
    padding: 0.25rem 0; border-bottom: 1px solid rgba(255,255,255,0.03);
}
.inspector-label { color: #2a2a3a; font-size: 0.62rem; }
.inspector-value { color: #555; font-size: 0.62rem; font-family: monospace; }

/* Mouse cursor animation */
@keyframes cursorClick {
    0%   { transform: translate(-4px,-4px) scale(1); }
    40%  { transform: translate(-4px,-4px) scale(0.85); }
    100% { transform: translate(-4px,-4px) scale(1); }
}
@keyframes rippleOut {
    0%   { width: 4px; height: 4px; opacity: 0.9; border-width: 2px; }
    100% { width: 28px; height: 28px; opacity: 0; border-width: 1px; }
}

/* ═══════════════════════════════════════
   HOW IT WORKS — Remotion-style
   ═══════════════════════════════════════ */
.hiw-step {
    display: flex;
    align-items: center;
    gap: 4rem;
    margin-bottom: 5rem;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}
.hiw-step.visible { opacity: 1; transform: translateY(0); }
.hiw-step.reverse { flex-direction: row-reverse; }
.hiw-visual { flex: 0 0 450px; display: flex; justify-content: center; }
.hiw-visual-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    transition: transform 0.3s ease;
    filter: drop-shadow(0 20px 40px rgba(0,0,0,0.6));
}
.hiw-visual-container:hover { transform: translateY(-4px) scale(1.02); }
.hiw-code-float {
    background: rgba(15, 15, 23, 0.8);
    padding: 0.6rem 1.2rem;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.1);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    backdrop-filter: blur(8px);
    margin-top: -1rem;
    z-index: 10;
}
.hiw-code-float code {
    font-size: 0.85rem;
    color: #818cf8;
    font-family: 'JetBrains Mono', monospace;
}
.hiw-text { flex: 1; }
.hiw-text h3 {
    font-size: 1.6rem;
    margin-bottom: 1rem;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 0.8rem;
}
.hiw-num {
    font-size: 0.85rem;
    color: var(--primary-color);
    font-weight: 800;
    font-family: monospace;
    background: rgba(79,70,229,0.15);
    padding: 0.2rem 0.55rem;
    border-radius: 6px;
}
.hiw-text p {
    color: var(--text-muted);
    font-size: 1.05rem;
    line-height: 1.75;
    margin-bottom: 1.2rem;
}
.hiw-tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}
.hiw-tags span {
    padding: 0.3rem 0.7rem;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 20px;
    font-size: 0.78rem;
    color: var(--text-muted);
}

@media (max-width: 800px) {
    .hiw-step, .hiw-step.reverse { flex-direction: column; gap: 2rem; }
    .hiw-visual { flex: none; width: 100%; max-width: 380px; }
}

/* ═══════════════════════════════════════
   ROADMAP
   ═══════════════════════════════════════ */
.roadmap-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    position: relative;
}
.roadmap-line {
    display: none;
}
.roadmap-item {
    position: relative;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}
.roadmap-item.visible { opacity: 1; transform: translateY(0); }
.roadmap-dot {
    display: none;
}
.roadmap-card {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.06);
    padding: 1.5rem 1.8rem;
    border-radius: 12px;
    transition: transform 0.3s ease, border-color 0.3s ease;
}
.roadmap-card:hover { transform: translateX(4px); border-color: rgba(255,255,255,0.12); }
.roadmap-card.active { border-color: rgba(245,158,11,0.3); background: rgba(245,158,11,0.04); }
.roadmap-badge {
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
    margin-bottom: 0.6rem;
    background: rgba(255,255,255,0.05);
    color: var(--text-muted);
}
.roadmap-badge.done { background: rgba(79,70,229,0.15); color: #a5b4fc; }
.roadmap-badge.active { background: rgba(245,158,11,0.15); color: #fbbf24; }
.roadmap-card h3 {
    font-size: 1.15rem;
    margin-bottom: 0.7rem;
    color: var(--text-main);
}
.roadmap-card ul {
    list-style: none;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}
.roadmap-card ul li {
    color: var(--text-muted);
    font-size: 0.9rem;
    padding-left: 1.2rem;
    position: relative;
}
.roadmap-card ul li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: #555;
}
.roadmap-item.done .roadmap-card ul li::before { color: #4f46e5; }
.roadmap-item.active .roadmap-card ul li::before { color: #f59e0b; }

/* Footer responsive */
@media (max-width: 800px) {
    footer > div:first-child { grid-template-columns: 1fr 1fr !important; }
}
@media (max-width: 500px) {
    footer > div:first-child { grid-template-columns: 1fr !important; }
}
