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

:root {
  --bg:         #0d0d0d;
  --bg-alt:     #111111;
  --bg-card:    #171717;
  --border:     #252525;
  --text:       #ededed;
  --text-muted: #888;
  --accent:     #6c63ff;
  --accent-hover: #5b53e6;
  --radius:     12px;
  --font:       'Inter', system-ui, sans-serif;
  --font-mono:  'JetBrains Mono', monospace;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }

.icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

/* ── Layout ───────────────────────────────────────────── */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ── Buttons ──────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  justify-content: center;
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 500;
  font-family: var(--font);
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  border: 1.5px solid transparent;
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.btn-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); }

.btn-outline {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}
.btn-outline:hover { border-color: #555; }

.btn-lg { padding: 13px 28px; font-size: 1rem; border-radius: 10px; }

/* ── Nav ──────────────────────────────────────────────── */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(13, 13, 13, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}

.logo {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.5px;
  color: var(--text);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
}

.nav-links a:not(.btn) {
  font-size: 0.9rem;
  color: var(--text-muted);
  transition: color 0.15s;
}
.nav-links a:not(.btn):hover { color: var(--text); }

/* ── Hero ─────────────────────────────────────────────── */
.hero {
  padding: 100px 0 80px;
  border-bottom: 1px solid var(--border);
}

.hero-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 24px;
}

.github-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 0.82rem;
  color: var(--text-muted);
  transition: border-color 0.15s, color 0.15s;
}
.github-badge:hover { border-color: #555; color: var(--text); }

.hero h1 {
  font-size: clamp(2.4rem, 6vw, 4rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -1.5px;
}

.hero-sub {
  max-width: 580px;
  color: var(--text-muted);
  font-size: 1.1rem;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}

/* ── Code Block ───────────────────────────────────────── */
.hero-code {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  text-align: left;
}

.code-label {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-muted);
  padding: 10px 16px 6px;
  border-bottom: 1px solid var(--border);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.hero-code pre {
  padding: 16px;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  line-height: 1.8;
  overflow-x: auto;
}

.c-method  { color: #7dd3fc; }
.c-key     { color: #ededed; }
.c-prop    { color: #a5f3fc; }
.c-str     { color: #86efac; }
.c-comment { color: #555; }

/* ── Sections ─────────────────────────────────────────── */
.section { padding: 96px 0; }
.section-alt { background: var(--bg-alt); }

.section-title {
  text-align: center;
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.75px;
  margin-bottom: 12px;
}

.section-sub {
  text-align: center;
  color: var(--text-muted);
  font-size: 1rem;
  margin-bottom: 60px;
}

/* ── Demo Video ───────────────────────────────────────── */
.demo-video-wrap {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  background: #000;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6);
  max-width: 900px;
  margin: 0 auto;
  position: relative;
  aspect-ratio: 16 / 9;
}

.demo-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

/* ── Why ──────────────────────────────────────────────── */
.why-inner {
  max-width: 680px;
  margin: 0 auto;
}

.why-text h2 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.75px;
  margin-bottom: 24px;
}

.why-text p {
  color: var(--text-muted);
  font-size: 1.05rem;
  line-height: 1.8;
  margin-bottom: 16px;
}

.why-sig {
  color: var(--text) !important;
  font-weight: 500;
  margin-top: 8px;
}

/* ── Steps ────────────────────────────────────────────── */
.steps {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

.step {
  flex: 1;
  min-width: 220px;
  max-width: 300px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
}

.step-number {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(108, 99, 255, 0.15);
  border: 1px solid rgba(108, 99, 255, 0.35);
  color: #a09aff;
  font-weight: 700;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.step h3 { font-size: 1rem; font-weight: 600; margin-bottom: 8px; }
.step p  { font-size: 0.9rem; color: var(--text-muted); line-height: 1.6; }

.step-arrow {
  color: var(--border);
  font-size: 1.5rem;
  align-self: center;
  flex-shrink: 0;
}

/* ── Features ─────────────────────────────────────────── */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  transition: border-color 0.2s;
}
.feature-card:hover { border-color: #333; }

.feature-icon { font-size: 1.75rem; margin-bottom: 14px; }
.feature-card h3 { font-size: 1rem; font-weight: 600; margin-bottom: 8px; }
.feature-card p  { font-size: 0.9rem; color: var(--text-muted); line-height: 1.6; }

/* ── Stack ────────────────────────────────────────────── */
.stack-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--border);
}

.stack-item {
  background: var(--bg-card);
  padding: 24px 28px;
  transition: background 0.15s;
}
.stack-item:hover { background: #1c1c1c; }

.stack-name {
  font-weight: 600;
  font-size: 0.95rem;
  margin-bottom: 4px;
}

.stack-desc {
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* ── Self Host ────────────────────────────────────────── */
.self-host-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.self-host-text h2 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.75px;
  margin-bottom: 16px;
}

.self-host-text p {
  color: var(--text-muted);
  font-size: 1rem;
  line-height: 1.75;
  margin-bottom: 28px;
}

.self-host-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.self-host-code {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.self-host-code pre {
  padding: 20px;
  font-family: var(--font-mono);
  font-size: 0.83rem;
  line-height: 1.9;
  overflow-x: auto;
}

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

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-links {
  display: flex;
  gap: 24px;
}
.footer-links a {
  font-size: 0.875rem;
  color: var(--text-muted);
  transition: color 0.15s;
}
.footer-links a:hover { color: var(--text); }

.footer-copy {
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* ── Responsive ───────────────────────────────────────── */
@media (max-width: 800px) {
  .self-host-inner {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

@media (max-width: 700px) {
  .nav-links a:not(.btn) { display: none; }
  .step-arrow { display: none; }
  .steps { flex-direction: column; align-items: center; }
  .step { max-width: 100%; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
}
