/* ─── RESET & TOKENS ─── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:         #080b0f;
  --bg-card:    #0d1117;
  --bg-raised:  #111820;
  --border:     #1e2832;
  --border-lit: #263040;
  --text:       #e2e8f0;
  --text-dim:   #64748b;
  --text-muted: #334155;
  --accent:     #F0A030;
  --accent-dim: rgba(240,160,48,.12);
  --accent-glow:rgba(240,160,48,.22);
  --purple:     #a78bfa;
  --blue:       #60a5fa;
  --orange:     #fb923c;
  --green:      #7AAE8E;
  --radius:     10px;
  --radius-lg:  16px;
  --font-mono:  'JetBrains Mono', monospace;
  --font-sans:  'Inter', sans-serif;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  position: relative;
}

/* Global grid overlay — sits behind everything */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 0;
  background-image:
    linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 60px 60px;
  opacity: .28;
  pointer-events: none;
}

/* Every direct section/nav sits above the grid */
nav, section, footer { position: relative; z-index: 1; }

a { text-decoration: none; color: inherit; }
em { font-style: italic; }
code {
  font-family: var(--font-mono);
  font-size: .85em;
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 1px 6px;
  color: var(--accent);
}

.container { max-width: 1140px; margin: 0 auto; padding: 0 24px; }

/* ─── SCROLLBAR ─── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--border-lit); border-radius: 3px; }

/* ─── NAV ─── */
#navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(8,11,15,.85);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  transition: border-color .3s;
}
#navbar.scrolled { border-color: var(--border-lit); }

.nav-inner {
  max-width: 1140px; margin: 0 auto;
  display: flex; align-items: center; gap: 32px;
  padding: 0 24px; height: 60px;
}

.logo { font-family: var(--font-mono); font-size: 1.15rem; font-weight: 600; letter-spacing: -.5px; display: flex; align-items: center; gap: 8px; }
.logo-dot { color: var(--accent); }
.logo-img { width: 24px; height: 24px; color: var(--accent); flex-shrink: 0; }

.nav-links { display: flex; gap: 28px; margin-left: auto; }
.nav-links a { font-size: .875rem; color: var(--text-dim); transition: color .2s; }
.nav-links a:hover { color: var(--text); }

.btn-primary {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--accent); color: #0d0d1a;
  font-weight: 600; font-size: .85rem;
  padding: 8px 18px; border-radius: 7px;
  transition: opacity .2s, transform .15s;
  white-space: nowrap;
}
.btn-primary:hover { opacity: .85; transform: translateY(-1px); }

.btn-ghost {
  display: inline-flex; align-items: center; gap: 6px;
  border: 1px solid var(--border-lit); color: var(--text-dim);
  font-size: .875rem; font-weight: 500;
  padding: 8px 18px; border-radius: 7px;
  transition: border-color .2s, color .2s;
}
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

.hamburger { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 4px; }
.hamburger span { display: block; width: 22px; height: 2px; background: var(--text-dim); border-radius: 2px; transition: .3s; }

.mobile-menu {
  display: none; flex-direction: column;
  border-top: 1px solid var(--border); padding: 12px 24px 16px;
}
.mobile-menu a { padding: 10px 0; font-size: .9rem; color: var(--text-dim); border-bottom: 1px solid var(--border); }
.mobile-menu a:last-child { border-bottom: none; }
.mobile-menu.open { display: flex; }

/* ─── SECTION LABELS ─── */
.section-label {
  font-family: var(--font-mono); font-size: .75rem; font-weight: 500;
  color: var(--accent); letter-spacing: 1.5px; text-transform: uppercase;
  margin-bottom: 14px;
}
.section-title { font-size: clamp(1.75rem, 4vw, 2.6rem); font-weight: 700; line-height: 1.2; margin-bottom: 16px; }
.section-title em { color: var(--accent); font-style: italic; font-weight: 700; }
.section-sub { color: var(--text-dim); font-size: 1.05rem; max-width: 560px; }

/* ─── HERO ─── */
.hero {
  position: relative; overflow: hidden;
  padding: 140px 0 100px;
  text-align: center;
}

/* Hero gets an extra radial accent glow on top of the global grid */
.hero-glow {
  position: absolute; top: -80px; left: 50%; transform: translateX(-50%);
  width: 700px; height: 500px;
  background: radial-gradient(ellipse, rgba(240,160,48,.14) 0%, transparent 68%);
  pointer-events: none; z-index: 0;
}

.hero .container { position: relative; z-index: 1; }

.badge {
  display: inline-block;
  background: var(--accent-dim); border: 1px solid rgba(240,160,48,.3);
  color: var(--accent); font-family: var(--font-mono); font-size: .75rem;
  padding: 5px 14px; border-radius: 99px; margin-bottom: 28px;
}

.hero-title {
  font-size: clamp(2.2rem, 6vw, 4rem);
  font-weight: 800; line-height: 1.1;
  letter-spacing: -.02em; margin-bottom: 20px;
}
.hero-title .accent { color: var(--accent); display: block; }

.hero-sub { font-size: 1.1rem; color: var(--text-dim); margin: 0 auto 36px; max-width: 580px; }

.hero-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin-bottom: 52px; }
.hero-actions .btn-primary { font-size: .95rem; padding: 11px 26px; }
.hero-actions .btn-ghost { font-size: .95rem; padding: 11px 26px; }

.hero-code-wrap {
  max-width: 680px; margin: 0 auto;
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: 0 24px 80px rgba(0,0,0,.6), 0 0 0 1px var(--border);
  text-align: left;
}

.code-bar {
  display: flex; align-items: center; gap: 6px;
  padding: 10px 16px; border-bottom: 1px solid var(--border);
  background: var(--bg-raised);
}
.dot { width: 11px; height: 11px; border-radius: 50%; }
.dot.r { background: #ff5f57; }
.dot.y { background: #febc2e; }
.dot.g { background: #28c840; }
.code-bar-label { font-family: var(--font-mono); font-size: .72rem; color: var(--text-dim); margin-left: 6px; }

pre {
  font-family: var(--font-mono); font-size: .82rem;
  line-height: 1.75; padding: 20px 24px;
  overflow-x: auto; tab-size: 2;
}

/* syntax colors */
.c-dim    { color: var(--text-muted); }
.c-green  { color: var(--green); }
.c-purple { color: var(--purple); }
.c-blue   { color: var(--blue); }
.c-orange { color: var(--orange); }
.c-accent { color: var(--accent); }

/* ─── FEATURES ─── */
.features { padding: 100px 0; border-top: 1px solid var(--border); }

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-top: 56px;
}

.feature-card {
  background: var(--bg-card);
  padding: 32px 28px;
  transition: background .2s;
}
.feature-card:hover { background: var(--bg-raised); }

.feature-icon {
  width: 40px; height: 40px;
  display: flex; align-items: center; justify-content: center;
  background: var(--accent-dim); border: 1px solid rgba(240,160,48,.2);
  border-radius: 9px; margin-bottom: 16px;
  color: var(--accent);
}
.feature-icon svg { flex-shrink: 0; }
.feature-card h3 { font-size: 1rem; font-weight: 600; margin-bottom: 10px; }
.feature-card p { font-size: .875rem; color: var(--text-dim); line-height: 1.65; }

/* ─── HOW IT WORKS ─── */
.how-it-works { padding: 100px 0; border-top: 1px solid var(--border); }

.tabs-wrap { margin-top: 52px; }

.tabs {
  display: flex; gap: 2px;
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 8px; padding: 4px;
  width: fit-content; margin-bottom: 24px;
}

.tab {
  background: none; border: none; cursor: pointer;
  font-family: var(--font-sans); font-size: .85rem; font-weight: 500;
  color: var(--text-dim); padding: 8px 18px; border-radius: 6px;
  transition: background .15s, color .15s;
}
.tab.active, .tab:hover { background: var(--bg-raised); color: var(--text); }
.tab.active { color: var(--accent); }

.tab-pane { display: none; }
.tab-pane.active { display: block; }

.tab-pane-inner {
  display: grid; grid-template-columns: 1fr 1.2fr; gap: 48px;
  align-items: start;
}

.tab-pane-text h3 { font-size: 1.3rem; font-weight: 700; margin-bottom: 12px; }
.tab-pane-text p  { font-size: .9rem; color: var(--text-dim); line-height: 1.7; margin-bottom: 20px; }

.check-list { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.check-list li {
  font-size: .875rem; color: var(--text-dim);
  padding-left: 20px; position: relative;
}
.check-list li::before {
  content: '✓';
  position: absolute; left: 0;
  color: var(--accent); font-weight: 700;
}

.code-block-wrap {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: 0 8px 40px rgba(0,0,0,.4);
}

/* ─── DOCS ─── */
.docs-section { padding: 100px 0; border-top: 1px solid var(--border); }

.docs-layout { display: grid; grid-template-columns: 220px 1fr; gap: 48px; margin-top: 52px; }

.docs-sidebar {
  position: sticky; top: 80px; height: fit-content;
  display: flex; flex-direction: column; gap: 28px;
}

.docs-nav-label {
  font-family: var(--font-mono); font-size: .7rem; font-weight: 600;
  color: var(--text-muted); letter-spacing: 1.2px; text-transform: uppercase;
  margin-bottom: 8px;
}

.docs-nav-group { display: flex; flex-direction: column; gap: 0; }

.docs-nav-link {
  font-size: .85rem; color: var(--text-dim);
  padding: 6px 10px; border-radius: 6px;
  border-left: 2px solid transparent;
  transition: background .15s, color .15s, border-color .15s;
}
.docs-nav-link:hover { background: var(--bg-raised); color: var(--text); }
.docs-nav-link.active { color: var(--accent); border-left-color: var(--accent); background: var(--accent-dim); }

.docs-content {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 40px 44px;
  min-height: 500px;
}

.docs-content h2 { font-size: 1.6rem; font-weight: 700; margin-bottom: 8px; }
.docs-content h3 { font-size: 1.1rem; font-weight: 600; margin: 28px 0 10px; color: var(--text); }
.docs-content p  { font-size: .9rem; color: var(--text-dim); line-height: 1.75; margin-bottom: 14px; }
.docs-content ul { list-style: disc; padding-left: 20px; display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.docs-content ul li { font-size: .875rem; color: var(--text-dim); }
.docs-content pre { margin: 16px 0; border-radius: 8px; background: var(--bg-raised); border: 1px solid var(--border); }

.docs-breadcrumb {
  font-family: var(--font-mono); font-size: .72rem; color: var(--text-muted);
  margin-bottom: 16px; display: flex; align-items: center; gap: 8px;
}
.docs-breadcrumb span { color: var(--accent); }

.docs-table { width: 100%; border-collapse: collapse; margin: 16px 0; font-size: .83rem; }
.docs-table th, .docs-table td { padding: 10px 14px; text-align: left; border: 1px solid var(--border); }
.docs-table th { background: var(--bg-raised); color: var(--text); font-weight: 600; }
.docs-table td { color: var(--text-dim); }
.docs-table td:first-child { font-family: var(--font-mono); color: var(--accent); }

/* ─── ROADMAP ─── */
.roadmap { padding: 100px 0; border-top: 1px solid var(--border); }

.roadmap-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 16px; margin-top: 52px; }

.roadmap-phase {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 28px 24px;
  transition: border-color .2s;
}
.roadmap-phase:hover { border-color: var(--border-lit); }
.roadmap-phase.active { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent-glow), 0 0 40px var(--accent-dim); }
.roadmap-phase.done { border-color: var(--border-lit); opacity: .8; }

.phase-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.phase-badge { font-family: var(--font-mono); font-size: .7rem; font-weight: 600; color: var(--text-muted); }
.phase-tag { font-size: .7rem; color: var(--accent); font-weight: 500; background: var(--accent-dim); padding: 2px 8px; border-radius: 99px; }

.roadmap-phase h3 { font-size: .95rem; font-weight: 700; margin-bottom: 14px; }
.roadmap-phase ul { list-style: none; display: flex; flex-direction: column; gap: 7px; }
.roadmap-phase ul li { font-size: .82rem; color: var(--text-dim); padding-left: 16px; position: relative; }
.roadmap-phase ul li::before { content: '·'; position: absolute; left: 4px; color: var(--text-muted); }
.roadmap-phase.done ul li::before { content: '✓'; color: var(--accent); left: 0; }

/* ─── CTA ─── */
.cta-section { padding: 100px 0; border-top: 1px solid var(--border); }

.cta-inner {
  position: relative; overflow: hidden;
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 72px 64px;
  text-align: center;
}

.cta-glow {
  position: absolute; top: -100px; left: 50%; transform: translateX(-50%);
  width: 500px; height: 300px;
  background: radial-gradient(ellipse, rgba(240,160,48,.11) 0%, transparent 70%);
  pointer-events: none;
}

.cta-inner h2 { font-size: clamp(1.8rem, 4vw, 2.8rem); font-weight: 800; margin-bottom: 16px; }
.cta-inner p  { font-size: 1rem; color: var(--text-dim); max-width: 480px; margin: 0 auto 36px; }

.cta-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.cta-actions .btn-primary { font-size: .95rem; padding: 11px 28px; }
.cta-actions .btn-ghost   { font-size: .95rem; padding: 11px 28px; }

/* ─── FOOTER ─── */
.footer {
  border-top: 1px solid var(--border);
  padding: 60px 0 32px;
}

.footer-inner {
  display: grid; grid-template-columns: 1.4fr 1fr; gap: 64px;
  margin-bottom: 48px;
}

.footer-brand .logo { font-size: 1rem; margin-bottom: 10px; }
.footer-brand p { font-size: .85rem; color: var(--text-dim); line-height: 1.7; }

.footer-cols { display: grid; grid-template-columns: repeat(3,1fr); gap: 32px; }

.footer-col { display: flex; flex-direction: column; gap: 10px; }
.footer-col-label { font-family: var(--font-mono); font-size: .7rem; font-weight: 600; color: var(--text-muted); letter-spacing: 1.2px; text-transform: uppercase; margin-bottom: 4px; }
.footer-col a { font-size: .85rem; color: var(--text-dim); transition: color .2s; }
.footer-col a:hover { color: var(--accent); }

.footer-bottom {
  display: flex; justify-content: space-between;
  border-top: 1px solid var(--border); padding-top: 20px;
  font-size: .8rem; color: var(--text-muted);
}

/* ─── ANIMATIONS ─── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

.hero .container > * { animation: fadeUp .6s ease both; }
.hero .container > *:nth-child(1) { animation-delay: .05s; }
.hero .container > *:nth-child(2) { animation-delay: .12s; }
.hero .container > *:nth-child(3) { animation-delay: .18s; }
.hero .container > *:nth-child(4) { animation-delay: .25s; }
.hero .container > *:nth-child(5) { animation-delay: .32s; }

/* ─── RESPONSIVE ─── */
@media (max-width: 1024px) {
  .features-grid { grid-template-columns: repeat(2,1fr); }
  .roadmap-grid  { grid-template-columns: repeat(2,1fr); }
  .tab-pane-inner { grid-template-columns: 1fr; gap: 28px; }
  .docs-layout { grid-template-columns: 180px 1fr; gap: 32px; }
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-cta   { display: none; }
  .hamburger { display: flex; margin-left: auto; }

  .hero { padding: 110px 0 72px; }
  .features-grid { grid-template-columns: 1fr; }
  .roadmap-grid  { grid-template-columns: 1fr; }

  .docs-layout { grid-template-columns: 1fr; }
  .docs-sidebar { position: static; }

  .footer-inner { grid-template-columns: 1fr; gap: 32px; }
  .footer-cols  { grid-template-columns: repeat(2,1fr); }

  .cta-inner { padding: 48px 28px; }

  .tabs { flex-wrap: wrap; width: 100%; }
}

@media (max-width: 480px) {
  .footer-cols { grid-template-columns: 1fr; }
  .docs-content { padding: 28px 20px; }
}
