:root {
    --bg-dark: #07070b;
    --bg-darker: #040406;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --accent-primary: #00f0ff;
    --accent-purple: #b026ff;
    --glass-bg: rgba(255, 255, 255, 0.02);
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-hover: rgba(255, 255, 255, 0.05);
}

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

html {
    scroll-snap-type: y proximity;
    scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
        scroll-snap-type: none;
    }
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

code, pre {
    font-family: 'JetBrains Mono', monospace;
}

/* Background Glow Effects */
.bg-glow {
    position: absolute;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(0, 240, 255, 0.15) 0%, rgba(0, 0, 0, 0) 70%);
    border-radius: 50%;
    z-index: -1;
    pointer-events: none;
    filter: blur(50px);
}

.bg-glow-1 {
    top: -200px;
    left: -200px;
}

.bg-glow-2 {
    bottom: 20%;
    right: -200px;
    background: radial-gradient(circle, rgba(176, 38, 255, 0.1) 0%, rgba(0, 0, 0, 0) 70%);
}

/* Utility Classes */
.glass-panel {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 16px;
}

.text-accent { color: var(--accent-primary); }
.text-purple { color: var(--accent-purple); }
.accent { color: var(--accent-primary); }
.bg-darker { background-color: var(--bg-darker); }

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    font-size: 1rem;
    border: none;
}

.btn-primary {
    background-color: var(--text-main);
    color: var(--bg-dark);
}
.btn-primary:hover {
    background-color: var(--accent-primary);
    box-shadow: 0 0 20px rgba(0, 240, 255, 0.4);
    transform: translateY(-2px);
}

.btn-secondary {
    background: transparent;
    color: var(--text-main);
    border: 1px solid var(--glass-border);
}
.btn-secondary:hover {
    background: var(--glass-hover);
    border-color: var(--text-muted);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--glass-border);
    color: var(--text-main);
    padding: 8px 16px;
    font-size: 0.9rem;
}
.btn-outline:hover {
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

.btn-ghost {
    background: transparent;
    color: var(--text-muted);
    border: none;
    padding: 12px 18px;
}
.btn-ghost:hover {
    color: var(--text-main);
}

.btn-lg {
    padding: 14px 32px;
    font-size: 1.05rem;
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 5%;
    z-index: 1000;
    border-radius: 0;
    border-top: none;
    border-left: none;
    border-right: none;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-logo {
    width: 28px;
    height: 28px;
    border-radius: 7px;
    flex-shrink: 0;
}

.hero-logo {
    width: 72px;
    height: 72px;
    border-radius: 18px;
    margin-bottom: 1.5rem;
    box-shadow: 0 0 32px rgba(0, 240, 255, 0.25);
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}
.nav-links a:not(.btn) {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}
.nav-links a:not(.btn):hover {
    color: var(--text-main);
}

/* Snap wrapper — full-viewport section that content centers within */
.snap-section {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    scroll-snap-align: start;
}

/* Inner content container — constrains width and provides padding */
.section {
    padding: 5rem 5%;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

.section-header {
    text-align: center;
    margin-bottom: 2.5rem;
}
.section-header h2 {
    font-size: 2rem;
    margin-bottom: 0.6rem;
    font-weight: 800;
}
.section-header p {
    color: var(--text-muted);
    font-size: 1.05rem;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0 5%;
    position: relative;
    padding-top: 5rem;
}

.hero-content {
    max-width: 800px;
}

.badge {
    display: inline-block;
    padding: 6px 12px;
    background: rgba(176, 38, 255, 0.1);
    color: var(--accent-purple);
    border: 1px solid rgba(176, 38, 255, 0.3);
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 2rem;
}

.hero-title {
    font-size: 4.5rem;
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -1.5px;
    margin-bottom: 1.5rem;
    background: linear-gradient(to right, #fff, #a5b4fc);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-muted);
    margin-bottom: 3rem;
    max-width: 90%;
    margin-left: auto;
    margin-right: auto;
}

.install-card {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
    border-radius: 12px;
    margin-bottom: 3rem;
    min-width: 300px;
}

.install-code {
    font-size: 1.1rem;
    color: var(--accent-primary);
}

.copy-btn {
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    transition: color 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}
.copy-btn:hover {
    color: var(--text-main);
}

.hero-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.feature-card {
    padding: 1.4rem 1.6rem;
    transition: transform 0.2s ease, border-color 0.2s;
}
.feature-card:hover {
    transform: translateY(-3px);
    border-color: rgba(0, 240, 255, 0.25);
}

.feature-card-header {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    margin-bottom: 0.5rem;
}

.feature-icon {
    font-size: 1.3rem;
    line-height: 1;
    flex-shrink: 0;
}

.feature-card h3 {
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
}

.feature-card p {
    color: var(--text-muted);
    font-size: 0.88rem;
    line-height: 1.55;
    margin: 0;
}

/* Quick Start Section */
.quickstart-container {
    display: grid;
    grid-template-columns: 1fr 1.4fr;
    gap: 3rem;
    align-items: start;
}

.quickstart-text h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    font-weight: 800;
}
.quickstart-text p {
    color: var(--text-muted);
    font-size: 1.1rem;
    margin-bottom: 2rem;
}
.benefit-list {
    list-style: none;
}
.benefit-list li {
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.05rem;
}
.benefit-list li::before {
    content: "✓";
    color: var(--accent-primary);
    font-weight: bold;
}

.code-window {
    border-radius: 12px;
    overflow: hidden;
}
.code-header {
    background: rgba(0, 0, 0, 0.3);
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--glass-border);
}
.mac-buttons {
    display: flex;
    gap: 8px;
}
.mac-buttons span {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #4b5563;
}
.mac-buttons span:nth-child(1) { background: #ff5f56; }
.mac-buttons span:nth-child(2) { background: #ffbd2e; }
.mac-buttons span:nth-child(3) { background: #27c93f; }

.code-title {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    color: var(--text-muted);
}
.code-window pre {
    padding: 20px;
    margin: 0;
    overflow-x: auto;
    font-size: 0.9rem;
    color: #e5e7eb;
}
.copy-code {
    font-size: 0.8rem;
    padding: 4px 8px;
    border: 1px solid var(--glass-border);
    border-radius: 4px;
}

/* Explainer Section */
.explainer-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 800px;
    margin: 0 auto 3rem;
    position: relative;
    padding: 0 20px;
}

.step-progress-bar {
    position: absolute;
    top: 24px;
    left: 40px;
    right: 40px;
    height: 2px;
    background: var(--glass-border);
    z-index: 1;
}

.step-item {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    background: var(--bg-dark);
    padding: 0 10px;
}

.step-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--bg-darker);
    border: 2px solid var(--glass-border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    transition: all 0.3s ease;
}

.step-item.active .step-icon {
    background: var(--accent-primary);
    border-color: #22d3ee;
    color: var(--bg-dark);
    box-shadow: 0 0 20px rgba(0, 240, 255, 0.4);
}

.step-item.past .step-icon {
    background: #10b981;
    border-color: #34d399;
    color: white;
}

.step-item span {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-muted);
    transition: color 0.3s;
}

.step-item.active span {
    color: var(--accent-primary);
}

.explainer-card {
    max-width: 1000px;
    margin: 0 auto;
    min-height: 550px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.explainer-content {
    flex-grow: 1;
    display: flex;
    gap: 3rem;
    padding: 3rem;
}

.step-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.step-info h3 {
    font-size: 1.75rem;
    font-weight: 800;
}

.step-info p {
    color: var(--text-muted);
    line-height: 1.7;
}

.step-visual {
    flex: 1.2;
    background: #020617;
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 350px;
}

.explainer-footer {
    padding: 1.5rem 3rem;
    background: rgba(0, 0, 0, 0.2);
    border-top: 1px solid var(--glass-border);
    display: flex;
    justify-content: space-between;
}

/* Specific Visualization Styles */
.scatter-container {
    width: 256px;
    height: 256px;
    border-left: 2px solid #334155;
    border-bottom: 2px solid #334155;
    position: relative;
}

.scatter-point {
    position: absolute;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    transition: all 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.gaussian-curve-container {
    width: 100%;
    height: 100%;
    position: relative;
    padding: 20px;
}

.centroid-marker {
    position: absolute;
    bottom: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: all 0.4s ease;
}

.centroid-dot {
    width: 12px;
    height: 12px;
    background: #34d399;
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(52, 211, 153, 0.8);
}

.centroid-line {
    width: 1px;
    height: 40px;
    background: rgba(52, 211, 153, 0.3);
}

.data-point {
    position: absolute;
    width: 8px;
    height: 8px;
    background: white;
    border-radius: 50%;
    box-shadow: 0 0 8px rgba(255, 255, 255, 0.8);
    transition: all 0.6s ease-in-out;
}

.residual-vector-container {
    padding: 40px;
}

.comparison-chart {
    background: rgba(15, 23, 42, 0.5);
    padding: 1.5rem;
    border-radius: 12px;
    border: 1px solid #1e293b;
    margin-top: 2rem;
}

@media (max-width: 900px) {
    .explainer-content {
        flex-direction: column;
        padding: 2rem;
    }
    .explainer-nav span {
        display: none;
    }
}

/* Ecosystem Grid */
.ecosystem-grid {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.eco-featured {
    background: linear-gradient(135deg, rgba(0,240,255,0.07) 0%, rgba(176,38,255,0.05) 100%);
    border: 1px solid rgba(0,240,255,0.18);
    border-radius: 20px;
    padding: 2.25rem 2.5rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
    align-items: center;
    transition: border-color 0.2s;
}
.eco-featured:hover {
    border-color: rgba(0,240,255,0.35);
}

.eco-featured-text {}
.eco-featured-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: rgba(0,240,255,0.1);
    border: 1px solid rgba(0,240,255,0.25);
    border-radius: 20px;
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--accent-primary);
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin-bottom: 1rem;
}
.eco-featured h3 {
    font-size: 1.7rem;
    font-weight: 800;
    margin-bottom: 0.75rem;
}
.eco-featured p {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.65;
    margin-bottom: 1.25rem;
}
.eco-featured-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}
.eco-pill {
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 20px;
    padding: 0.2rem 0.75rem;
    font-size: 0.78rem;
    color: var(--text-muted);
    font-family: 'JetBrains Mono', monospace;
}

.eco-featured-code {
    background: rgba(0,0,0,0.4);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 14px;
    overflow: hidden;
}
.eco-featured-code .code-header {
    background: rgba(255,255,255,0.03);
    padding: 0.6rem 1rem;
    font-size: 0.78rem;
    color: var(--text-muted);
    border-bottom: 1px solid rgba(255,255,255,0.07);
    font-family: 'JetBrains Mono', monospace;
}
.eco-featured-code pre {
    padding: 1.25rem;
    margin: 0;
    font-size: 0.82rem;
    line-height: 1.65;
    color: #e2e8f0;
    overflow-x: auto;
}

.eco-integrations {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
}

.eco-card {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 16px;
    padding: 1.75rem;
    display: flex;
    flex-direction: column;
    transition: border-color 0.2s, transform 0.2s;
}
.eco-card:hover {
    border-color: rgba(255,255,255,0.18);
    transform: translateY(-3px);
}

.eco-icon-wrap {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    margin-bottom: 1rem;
    flex-shrink: 0;
}
.eco-icon-wrap.green  { background: rgba(52,211,153,0.12); }
.eco-icon-wrap.blue   { background: rgba(96,165,250,0.12); }
.eco-icon-wrap.purple { background: rgba(167,139,250,0.12); }

.eco-card h3 {
    font-size: 1.05rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.eco-card p {
    color: var(--text-muted);
    font-size: 0.85rem;
    line-height: 1.6;
    flex-grow: 1;
    margin-bottom: 1.25rem;
}

.eco-import {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.72rem;
    background: rgba(0,0,0,0.3);
    border: 1px solid rgba(255,255,255,0.07);
    border-radius: 8px;
    padding: 0.5rem 0.75rem;
    color: var(--accent-primary);
    margin-bottom: 1rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.eco-link {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.82rem;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: color 0.2s;
}
.eco-link:hover {
    color: var(--accent-primary);
}

/* Footer */
.footer {
    border-top: 1px solid var(--glass-border);
    padding: 4rem 5% 2rem;
    margin-top: 4rem;
}
.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    margin-bottom: 3rem;
}
.footer-brand p {
    color: var(--text-muted);
    margin-top: 1rem;
    max-width: 300px;
}
.footer-col h4 {
    margin-bottom: 1.5rem;
}
.footer-col a {
    display: block;
    color: var(--text-muted);
    text-decoration: none;
    margin-bottom: 0.8rem;
}
.footer-col a:hover {
    color: var(--accent-primary);
}
.footer-bottom {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Hero is also a snap section */
.hero.snap-section {
    scroll-snap-align: start;
}

/* Animations — spring ease-out for a polished feel */
.fade-in-up {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.65s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.65s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: opacity, transform;
}
.fade-in-up.visible {
    opacity: 1;
    transform: translateY(0);
}

.fade-in-left {
    opacity: 0;
    transform: translateX(-32px);
    transition: opacity 0.65s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.65s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: opacity, transform;
}
.fade-in-left.visible {
    opacity: 1;
    transform: translateX(0);
}

.fade-in-right {
    opacity: 0;
    transform: translateX(32px);
    transition: opacity 0.65s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.65s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: opacity, transform;
}
.fade-in-right.visible {
    opacity: 1;
    transform: translateX(0);
}

/* ── Config Advisor Banner (now inside .section, no outer padding needed) ── */
.advisor-banner {
    background: linear-gradient(135deg, rgba(99,102,241,0.12) 0%, rgba(0,240,255,0.06) 100%);
    border: 1px solid rgba(99,102,241,0.2);
    border-radius: 12px;
    padding: 2rem 2.5rem;
    margin-bottom: 3rem;
}
.advisor-banner-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    flex-wrap: wrap;
}
.advisor-banner-text h3 {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}
.advisor-banner-text p {
    color: var(--text-muted);
    max-width: 520px;
    line-height: 1.6;
}

/* Responsive */
@media (max-width: 900px) {
    .quickstart-container {
        grid-template-columns: 1fr;
    }
    .hero-title {
        font-size: 3rem;
    }
    .benchmark-grid { grid-template-columns: 1fr; }
    .features-grid { grid-template-columns: repeat(2, 1fr); }
    .eco-featured { grid-template-columns: 1fr; }
    .eco-integrations { grid-template-columns: repeat(2, 1fr); }
    .advisor-banner-inner { flex-direction: column; text-align: center; }
    .advisor-banner-text p { max-width: 100%; }
}
@media (max-width: 600px) {
    .features-grid { grid-template-columns: 1fr; }
    .eco-integrations { grid-template-columns: 1fr; }
    .quickstart-container { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
}
