:root {
  --bg: #0a0a0f;
  --card: #14141d;
  --border: #262633;
  --fg: #f5f5f7;
  --muted: #9a9aad;
  --violet: #8b5cf6;
  --pink: #f472b6;
  --blue: #60a5fa;
  --radius: 14px;
  --font-ui: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", Menlo, Consolas, monospace;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-ui);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
code { font-family: var(--font-mono); font-size: 0.9em; color: var(--blue); }

.container { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.container.narrow { max-width: 780px; }
.mono { font-family: var(--font-mono); }
.muted { color: var(--muted); }
.detail { color: var(--muted); font-size: 0.82rem; letter-spacing: 0.02em; }

.kicker {
  color: var(--violet);
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  margin-bottom: 14px;
}

h1, h2, h3 { line-height: 1.15; font-weight: 800; letter-spacing: -0.02em; }
h1 { font-size: clamp(2.3rem, 6vw, 4rem); margin: 10px 0 18px; }
h2 { font-size: clamp(1.7rem, 4vw, 2.6rem); margin-bottom: 14px; }
h3 { font-size: 1.15rem; margin-bottom: 8px; }

.grad {
  background: linear-gradient(92deg, var(--violet), var(--pink) 55%, var(--blue));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ---------- Nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(10, 10, 15, 0.78);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: 1120px; margin: 0 auto; padding: 0 24px;
  height: 64px; display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; }
.brand img { border-radius: 8px; }
.wordmark { font-size: 1.1rem; letter-spacing: -0.01em; }
.version-chip {
  font-family: var(--font-mono); font-size: 0.68rem;
  color: var(--muted); border: 1px solid var(--border);
  padding: 3px 8px; border-radius: 999px; white-space: nowrap;
}
.nav-links { display: flex; align-items: center; gap: 24px; font-size: 0.92rem; }
.nav-links a { color: var(--muted); transition: color .15s; }
.nav-links a:hover { color: var(--fg); }
.nav-gh { font-family: var(--font-mono); font-size: 0.85rem; }

.hamburger {
  display: none; background: none; border: none; cursor: pointer;
  flex-direction: column; gap: 5px; padding: 8px;
}
.hamburger span { width: 22px; height: 2px; background: var(--fg); transition: transform .2s, opacity .2s; }
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 720px) {
  .hamburger { display: flex; }
  .nav-links {
    position: absolute; top: 64px; left: 0; right: 0;
    flex-direction: column; align-items: flex-start; gap: 4px;
    background: var(--bg); border-bottom: 1px solid var(--border);
    padding: 12px 24px 20px;
    display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 8px 0; width: 100%; }
}

/* ---------- Hero ---------- */
.hero { position: relative; padding: 96px 0 72px; text-align: center; overflow: hidden; }
.hero-glow {
  position: absolute; inset: -200px 0 auto 0; height: 700px; pointer-events: none;
  background:
    radial-gradient(ellipse 55% 50% at 42% 18%, rgba(139, 92, 246, 0.22), transparent 70%),
    radial-gradient(ellipse 45% 40% at 62% 22%, rgba(244, 114, 182, 0.14), transparent 70%);
}
.hero .container { position: relative; }
.hero .sub { max-width: 640px; margin: 0 auto 30px; color: var(--muted); font-size: 1.08rem; }
.hero .sub strong { color: var(--fg); }

.cta-row { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin-bottom: 56px; }
.btn {
  display: inline-block; padding: 13px 26px; border-radius: 12px;
  font-weight: 600; font-size: 0.95rem; border: 1px solid transparent;
  transition: transform .15s, box-shadow .15s, background .15s;
}
.btn-primary {
  background: linear-gradient(92deg, var(--violet), var(--pink));
  color: #fff;
  box-shadow: 0 6px 24px rgba(244, 114, 182, 0.28), 0 6px 24px rgba(139, 92, 246, 0.25);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 10px 32px rgba(244, 114, 182, 0.38), 0 10px 32px rgba(139, 92, 246, 0.3); }
.btn-ghost { border-color: var(--border); color: var(--fg); background: var(--card); }
.btn-ghost:hover { border-color: var(--violet); }
.btn-sm { padding: 9px 16px; font-size: 0.85rem; }

/* ---------- Terminal framing ---------- */
.term {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden; text-align: left;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}
.term-bar {
  display: flex; align-items: center; gap: 8px;
  padding: 11px 16px; border-bottom: 1px solid var(--border);
}
.dot { width: 11px; height: 11px; border-radius: 50%; }
.dot.r { background: #ff5f57; } .dot.y { background: #febc2e; } .dot.g { background: #28c840; }
.term-title { margin-left: 8px; font-size: 0.75rem; color: var(--muted); }
.term-shot { width: 100%; }

/* ---------- Trio ---------- */
.trio { padding: 24px 0 8px; }
.trio-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.trio-card h3 { font-size: 1.05rem; }
.trio-card h3::before { content: "— "; color: var(--violet); }
.trio-card p { color: var(--muted); font-size: 0.93rem; }

/* ---------- Sections ---------- */
.section { padding: 96px 0; }
.section-sub { color: var(--muted); max-width: 620px; margin-bottom: 36px; }

/* ---------- Cards ---------- */
.card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 26px;
  transition: border-color .2s, transform .2s;
}
a.card:hover { border-color: var(--violet); transform: translateY(-3px); }
.card p { color: var(--muted); font-size: 0.94rem; }
.tag {
  display: inline-block; font-size: 0.68rem; letter-spacing: 0.14em;
  color: var(--violet); border: 1px solid rgba(139, 92, 246, 0.4);
  border-radius: 6px; padding: 3px 8px; margin-bottom: 14px;
}

.bento { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 40px; }

/* ---------- Steps ---------- */
.steps { list-style: none; margin-top: 40px; display: flex; flex-direction: column; gap: 28px; }
.step {
  display: flex; gap: 24px; align-items: flex-start;
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 26px;
}
.step-num { font-size: 1.4rem; font-weight: 600; color: var(--pink); flex-shrink: 0; }
.step p { color: var(--muted); font-size: 0.95rem; margin-bottom: 6px; }
.step p.detail { margin-bottom: 0; }

/* ---------- Screenshots ---------- */
.shots { display: grid; grid-template-columns: 1fr; gap: 24px; margin-top: 40px; }
@media (min-width: 860px) {
  .shots { grid-template-columns: repeat(2, 1fr); }
  .shots .term:first-child { grid-column: 1 / -1; }
}

/* ---------- Protocol ---------- */
.proto-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 40px; }
.proto h3 { font-size: 1.05rem; }
.inline-link { display: inline-block; margin-top: 14px; font-family: var(--font-mono); font-size: 0.8rem; color: var(--blue); }
.code-block {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: var(--bg); border: 1px solid var(--border); border-radius: 10px;
  padding: 12px 14px; margin-top: 16px;
}
.code-block code { color: var(--fg); font-size: 0.82rem; overflow-x: auto; white-space: nowrap; }
.copy-btn {
  background: var(--card); color: var(--muted); border: 1px solid var(--border);
  border-radius: 8px; padding: 5px 12px; font-size: 0.72rem; cursor: pointer;
  transition: color .15s, border-color .15s; flex-shrink: 0;
}
.copy-btn:hover { color: var(--fg); border-color: var(--violet); }
.copy-btn.copied { color: var(--blue); border-color: var(--blue); }

/* ---------- Download ---------- */
.dl-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 40px; }
.dl { text-align: center; padding: 34px 22px; }
.dl-icon { display: block; font-size: 1.8rem; margin-bottom: 12px; color: var(--violet); }
.dl p.detail { margin-bottom: 18px; }
.build { margin-top: 28px; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px 26px; }
.build h3 { font-size: 0.85rem; letter-spacing: 0.12em; color: var(--muted); }

/* ---------- Roadmap ---------- */
.roadmap { padding: 64px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.road-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 20px; }
.road-item h4 { font-size: 1rem; margin-bottom: 6px; }
.road-item h4::before { content: "→ "; color: var(--pink); }
.road-item p { color: var(--muted); font-size: 0.9rem; }

/* ---------- FAQ ---------- */
.faq { margin-top: 32px; display: flex; flex-direction: column; gap: 12px; }
.faq-item {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 0 22px;
}
.faq-item summary {
  list-style: none; cursor: pointer; padding: 18px 0;
  font-weight: 600; font-size: 1rem;
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.chev {
  width: 9px; height: 9px; flex-shrink: 0;
  border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted);
  transform: rotate(45deg); transition: transform .2s;
}
.faq-item[open] .chev { transform: rotate(225deg); }
.faq-item p { color: var(--muted); font-size: 0.94rem; padding: 0 0 18px; }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--border); padding: 56px 0 32px; }
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px; margin-bottom: 40px;
}
.footer-brand img { border-radius: 7px; margin-bottom: 10px; }
.footer-brand .muted { font-size: 0.88rem; margin: 8px 0 12px; }
.footer-col h5 { font-size: 0.72rem; letter-spacing: 0.18em; color: var(--muted); margin-bottom: 14px; }
.footer-col a { display: block; color: var(--muted); font-size: 0.9rem; padding: 4px 0; transition: color .15s; }
.footer-col a:hover { color: var(--fg); }
.footer-bottom { border-top: 1px solid var(--border); padding-top: 24px; }
.footer-bottom p { font-size: 0.82rem; }

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .6s ease, transform .6s ease; }
.reveal.visible { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: .08s; }
.reveal.d2 { transition-delay: .16s; }
.reveal.d3 { transition-delay: .24s; }
.reveal.d4 { transition-delay: .32s; }
.reveal.d5 { transition-delay: .40s; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .card, .copy-btn { transition: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .bento, .proto-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 720px) {
  .section { padding: 64px 0; }
  .hero { padding: 64px 0 48px; }
  .trio-grid, .bento, .proto-grid, .dl-grid, .road-grid { grid-template-columns: 1fr; }
  .step { flex-direction: column; gap: 12px; }
  .version-chip { display: none; }
  .footer-grid { grid-template-columns: 1fr; gap: 24px; }
}
