/* ======================== TOKENS ======================== */
:root {
    --bg-primary: #050a14;
    --bg-card: rgba(15, 23, 42, 0.7);
    --bg-card-hover: rgba(20, 30, 55, 0.8);
    --text-primary: #e2e8f0;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --accent: #f59e0b;
    --accent-glow: rgba(245, 158, 11, 0.3);
    --accent-2: #10b981;
    --border: rgba(51, 65, 85, 0.5);
    --border-glow: rgba(245, 158, 11, 0.2);
    --radius-lg: 20px;
    --radius-md: 12px;
    --radius-sm: 8px;
    --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* ======================== RESET ======================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
    font-family: var(--font);
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}
a { color: var(--accent); text-decoration: none; transition: opacity 0.2s; }
a:hover { opacity: 0.85; }

/* ======================== LAYOUT ======================== */
.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* ======================== NAV ======================== */
#navbar {
    position: fixed; top: 0; left: 0; right: 0;
    z-index: 100;
    background: rgba(5, 10, 20, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    transition: background 0.3s;
}
.nav-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0.75rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.logo {
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--text-primary);
}
.logo span { color: var(--accent); }
.nav-links {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}
.nav-links a {
    color: var(--text-secondary);
    font-size: 0.88rem;
    font-weight: 500;
    transition: color 0.2s;
}
.nav-links a:hover { color: var(--text-primary); opacity: 1; }
.nav-cta {
    background: var(--accent) !important;
    color: #000 !important;
    padding: 0.4rem 1rem;
    border-radius: var(--radius-sm);
    font-weight: 600 !important;
}
.nav-cta:hover { opacity: 0.9 !important; }

/* ======================== HERO ======================== */
#hero {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 9rem 1.5rem 4rem;
    overflow: hidden;
}
.hero-bg {
    position: absolute; inset: 0;
    background:
        radial-gradient(ellipse 80% 60% at 50% 30%, rgba(245, 158, 11, 0.08) 0%, transparent 70%),
        radial-gradient(ellipse 50% 40% at 20% 60%, rgba(16, 185, 129, 0.05) 0%, transparent 60%);
}
.hero-content {
    position: relative;
    text-align: center;
    max-width: 720px;
}
.hero-badge {
    display: inline-block;
    padding: 0.35rem 1rem;
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid var(--border-glow);
    font-size: 0.8rem;
    color: var(--accent);
    font-weight: 500;
    margin-bottom: 1.5rem;
}
#hero h1 {
    font-size: clamp(2.2rem, 5vw, 3.6rem);
    font-weight: 900;
    line-height: 1.15;
    margin-bottom: 1.25rem;
    letter-spacing: -0.02em;
}
.gradient-text {
    background: linear-gradient(135deg, #f59e0b, #ef4444, #ec4899, #8b5cf6, #3b82f6, #10b981);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.hero-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 560px;
    margin: 0 auto 2rem;
    line-height: 1.7;
}
.hero-actions {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    margin-bottom: 3rem;
}
.hero-stats {
    display: flex;
    gap: 2rem;
    justify-content: center;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
}
.stat { text-align: center; }
.stat-value {
    display: block;
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--accent);
    font-variant-numeric: tabular-nums;
}
.stat-label {
    font-size: 0.78rem;
    color: var(--text-muted);
    font-weight: 500;
}

/* ======================== BUTTONS ======================== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.7rem 1.5rem;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.95rem;
    font-family: var(--font);
    cursor: pointer;
    border: none;
    transition: all 0.25s ease;
}
.btn-primary {
    background: linear-gradient(135deg, var(--accent), #d97706);
    color: #000;
    box-shadow: 0 4px 20px var(--accent-glow);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 30px var(--accent-glow);
    opacity: 1;
    color: #000;
}
.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border);
}
.btn-ghost:hover {
    color: var(--text-primary);
    border-color: var(--text-muted);
    opacity: 1;
}

/* ======================== SECTIONS ======================== */
section { padding: 5rem 0; }
.section-header {
    text-align: center;
    margin-bottom: 3rem;
}
.section-header h2 {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 0.75rem;
    letter-spacing: -0.01em;
}
.section-header p {
    font-size: 1.05rem;
    color: var(--text-secondary);
    max-width: 520px;
    margin: 0 auto;
    line-height: 1.6;
}

/* ======================== STEPS ======================== */
.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
}
.step-card {
    position: relative;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 2rem 1.5rem;
    transition: all 0.3s ease;
    overflow: hidden;
}
.step-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-glow);
    transform: translateY(-4px);
}
.step-icon {
    font-size: 2rem;
    margin-bottom: 0.75rem;
}
.step-number {
    position: absolute;
    top: 1rem;
    right: 1.25rem;
    font-size: 3rem;
    font-weight: 900;
    color: rgba(245, 158, 11, 0.07);
    line-height: 1;
}
.step-card h3 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}
.step-card p {
    font-size: 0.88rem;
    color: var(--text-secondary);
    line-height: 1.55;
}

/* ======================== APP PREVIEW ======================== */
.screenshots-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
    align-items: center;
    margin-top: 1rem;
}
.app-screenshot {
    width: 100%;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
    transition: transform 0.3s, border-color 0.3s;
}
.app-screenshot:hover {
    transform: translateY(-5px);
    border-color: var(--border-glow);
}

/* ======================== FEATURES ======================== */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}
.feature-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.75rem;
    transition: all 0.3s ease;
}
.feature-card:hover {
    background: var(--bg-card-hover);
    transform: translateY(-3px);
    border-color: var(--border-glow);
}
.feature-highlight {
    grid-column: 1 / -1;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.06), rgba(16, 185, 129, 0.04));
    border-color: var(--border-glow);
}
.feature-icon {
    font-size: 1.8rem;
    margin-bottom: 0.75rem;
}
.feature-card h3 {
    font-size: 1.05rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}
.feature-card p {
    font-size: 0.88rem;
    color: var(--text-secondary);
    line-height: 1.55;
}

/* ======================== LIVE NODES MAP ======================== */
.map-wrapper {
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--border);
    background: var(--bg-card);
}
#nodes-map {
    height: 320px;
    width: 100%;
}

/* ======================== GET STARTED ======================== */
.cta-card {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.08), rgba(16, 185, 129, 0.05));
    border: 1px solid var(--border-glow);
    border-radius: var(--radius-lg);
    padding: 3rem 2.5rem;
    text-align: center;
}
.cta-card h2 {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 0.75rem;
}
.cta-card > p {
    color: var(--text-secondary);
    max-width: 480px;
    margin: 0 auto 2rem;
    font-size: 1rem;
}
.cta-steps {
    max-width: 500px;
    margin: 0 auto 2rem;
    text-align: left;
}
.cta-step {
    margin-bottom: 0.75rem;
}
.cta-step code {
    display: block;
    padding: 0.6rem 1rem;
    border-radius: var(--radius-sm);
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid var(--border);
    font-family: 'SF Mono', 'Fira Code', monospace;
    font-size: 0.82rem;
    color: var(--accent);
    word-break: break-all;
}

/* ======================== FOOTER ======================== */
footer {
    padding: 3rem 0 2rem;
    border-top: 1px solid var(--border);
}
.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 2rem;
}
.footer-brand p {
    margin-top: 0.25rem;
    font-size: 0.85rem;
    color: var(--text-muted);
}
.footer-links {
    display: flex;
    gap: 1.25rem;
}
.footer-links a {
    color: var(--text-muted);
    font-size: 0.85rem;
    font-weight: 500;
}
.footer-links a:hover { color: var(--text-primary); }
.footer-bottom {
    text-align: center;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(51, 65, 85, 0.3);
}
.footer-bottom p {
    font-size: 0.78rem;
    color: var(--text-muted);
}

/* ======================== MOBILE ======================== */
@media (max-width: 640px) {
    .nav-links a:not(.nav-cta) { display: none; }
    .hero-stats { flex-direction: column; gap: 1rem; }
    .hero-actions { flex-direction: column; align-items: center; }
    .steps-grid { grid-template-columns: 1fr; }
    .screenshots-grid { grid-template-columns: 1fr; gap: 1.5rem; }
    .features-grid { grid-template-columns: 1fr; }
    .feature-highlight { grid-column: 1; }
    .footer-inner { flex-direction: column; gap: 1.5rem; }
    .cta-card { padding: 2rem 1.25rem; }
    #nodes-map { height: 280px; }
}
