:root {
  --ink: #14121a;
  --ink-2: #1c1924;
  --surface: #211f2b;
  --surface-2: #2a2735;
  --line: #362f45;
  --ember: #ff6a3d;
  --ember-2: #ffb27a;
  --violet: #7c5cff;
  --violet-2: #b8a6ff;
  --paper: #f5f3ff;
  --mist: #b3aec4;
  --mist-dim: #837d97;
  --radius: 10px;
}
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --ink: #14121a;
  }
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--ink);
  color: var(--paper);
  font-family: 'Inter', -apple-system, sans-serif;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, .display {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin: 0;
}
code, pre, .mono { font-family: 'JetBrains Mono', monospace; }
a { color: inherit; }
img, svg { max-width: 100%; }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 28px; }

/* ---------- Nav ---------- */
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
}
.nav .wrap { display: flex; align-items: center; justify-content: space-between; width: 100%; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand svg { width: 22px; height: 22px; }
.brand-name { font-family: 'Space Grotesk', sans-serif; font-weight: 700; font-size: 17px; }
.nav-links { display: flex; gap: 30px; }
.nav-links a { text-decoration: none; color: var(--mist); font-size: 14.5px; }
.nav-links a:hover { color: var(--paper); }
.nav-cta {
  text-decoration: none;
  background: var(--paper);
  color: var(--ink);
  padding: 9px 18px;
  border-radius: 7px;
  font-size: 14px;
  font-weight: 600;
}
.nav-mobile-hide { display: flex; }
@media (max-width: 760px) { .nav-mobile-hide { display: none; } }

/* ---------- Hero ---------- */
.hero { padding: 90px 0 70px; }
.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 56px;
  align-items: center;
}
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; } }

.eyebrow-line {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 22px;
  color: var(--ember-2);
  font-size: 14px;
}
.eyebrow-line .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ember); box-shadow: 0 0 12px var(--ember); }

.hero h1 {
  font-size: clamp(34px, 4.6vw, 54px);
  line-height: 1.08;
  max-width: 620px;
}
.hero h1 .accent { color: var(--ember); }
.hero p.lede {
  margin-top: 22px;
  max-width: 480px;
  font-size: 17.5px;
  color: var(--mist);
}
.hero-ctas { display: flex; gap: 14px; margin-top: 32px; flex-wrap: wrap; }
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 22px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
}
.btn-primary { background: var(--ember); color: #1a0e07; }
.btn-primary:hover { background: var(--ember-2); }
.btn-ghost { border-color: var(--line); color: var(--paper); background: transparent; }
.btn-ghost:hover { border-color: var(--mist-dim); }

.hero-note { margin-top: 18px; font-size: 13.5px; color: var(--mist-dim); }

/* Terminal mock */
.term {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 30px 70px -30px rgba(0,0,0,0.6);
}
.term-bar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
}
.term-bar span { width: 10px; height: 10px; border-radius: 50%; background: #4a465a; }
.term-title { margin-left: 8px; font-size: 12.5px; color: var(--mist-dim); }
.term-body { padding: 20px 20px 24px; font-size: 13.5px; }
.term-body .l { margin: 0 0 8px; white-space: pre-wrap; }
.term-prompt { color: var(--violet-2); }
.term-out { color: var(--mist); }
.term-ok { color: #6be3a6; }
.term-ember { color: var(--ember-2); }

/* ---------- Section shared ---------- */
section { padding: 80px 0; border-top: 1px solid var(--line); }
.section-head { max-width: 620px; margin-bottom: 46px; }
.section-head h2 { font-size: clamp(26px, 3.2vw, 36px); }
.section-head p { margin-top: 14px; color: var(--mist); font-size: 16px; }

/* ---------- Pipeline ---------- */
.pipeline {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  align-items: stretch;
}
@media (max-width: 860px) { .pipeline { grid-template-columns: 1fr; } }
.pipe-step {
  padding: 26px 22px;
  border: 1px solid var(--line);
  border-left: none;
  background: var(--surface);
  position: relative;
}
.pipe-step:first-child { border-left: 1px solid var(--line); border-radius: var(--radius) 0 0 var(--radius); }
.pipe-step:last-child { border-radius: 0 var(--radius) var(--radius) 0; }
@media (max-width: 860px) {
  .pipe-step { border-left: 1px solid var(--line); border-top: none; border-radius: 0 !important; }
  .pipe-step:first-child { border-top: 1px solid var(--line); border-radius: var(--radius) var(--radius) 0 0 !important; }
  .pipe-step:last-child { border-radius: 0 0 var(--radius) var(--radius) !important; }
}
.pipe-num { font-family: 'JetBrains Mono', monospace; font-size: 12px; color: var(--ember-2); }
.pipe-step h3 { margin-top: 10px; font-size: 16.5px; }
.pipe-step p { margin-top: 8px; font-size: 14px; color: var(--mist); }
.pipe-arrow {
  display: none;
  position: absolute;
  right: -11px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--mist-dim);
  z-index: 2;
}
@media (min-width: 861px) { .pipe-step:not(:last-child) .pipe-arrow { display: block; } }

/* ---------- Rendering split ---------- */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
}
@media (max-width: 860px) { .split { grid-template-columns: 1fr; } }
.split-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface);
}
.split-head { padding: 18px 22px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; }
.split-head h3 { font-size: 16.5px; }
.tag { font-size: 11.5px; padding: 3px 9px; border-radius: 20px; }
.tag-static { background: rgba(124,92,255,0.18); color: var(--violet-2); }
.tag-server { background: rgba(255,106,61,0.18); color: var(--ember-2); }
.split-code { padding: 18px 22px; font-size: 13px; overflow-x: auto; }
.split-code .c1 { color: var(--mist-dim); }
.split-code .c2 { color: var(--violet-2); }
.split-code .c3 { color: var(--ember-2); }
.split-foot { padding: 16px 22px; color: var(--mist); font-size: 14px; border-top: 1px solid var(--line); }

/* ---------- Perf table ---------- */
.perf-table { width: 100%; border-collapse: collapse; margin-top: 6px; }
.perf-table th, .perf-table td {
  text-align: left;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  font-size: 14.5px;
}
.perf-table thead th { color: var(--mist-dim); font-weight: 500; font-size: 13px; }
.perf-table td.metric { color: var(--paper); font-weight: 500; }
.perf-table td.num { font-family: 'JetBrains Mono', monospace; }
.perf-table td.win { color: var(--ember-2); }
.perf-note { margin-top: 14px; font-size: 13px; color: var(--mist-dim); }

/* ---------- Feature grid ---------- */
.feat-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
@media (max-width: 860px) { .feat-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .feat-grid { grid-template-columns: 1fr; } }
.feat {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  background: var(--surface);
}
.feat h4 { font-size: 15.5px; margin-bottom: 8px; }
.feat p { font-size: 13.5px; color: var(--mist); margin: 0; }

/* ---------- Pricing ---------- */
.pricing-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
@media (max-width: 760px) { .pricing-grid { grid-template-columns: 1fr; } }
.plan {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 32px;
  background: var(--surface);
}
.plan.pro { border-color: var(--ember); background: linear-gradient(160deg, var(--surface), #2c1f22); }
.plan-top { display: flex; justify-content: space-between; align-items: baseline; }
.plan-name { font-family: 'Space Grotesk', sans-serif; font-size: 19px; font-weight: 600; }
.plan-price { font-family: 'Space Grotesk', sans-serif; font-size: 15px; color: var(--mist); }
.plan-price b { font-size: 26px; color: var(--paper); }
.plan-desc { margin-top: 10px; color: var(--mist); font-size: 14.5px; }
.plan ul { list-style: none; margin: 24px 0 0; padding: 0; }
.plan li { display: flex; gap: 10px; padding: 8px 0; font-size: 14.5px; border-top: 1px solid var(--line); }
.plan li:first-child { border-top: none; }
.check { color: var(--ember-2); flex-shrink: 0; }
.plan .btn { margin-top: 26px; width: 100%; justify-content: center; }

/* ---------- Wizard preview ---------- */
.wizard-shot {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--paper);
  color: var(--ink);
}
.wizard-topbar { background: #efedf9; padding: 10px 18px; font-size: 12px; color: #6b6580; border-bottom: 1px solid #ded9ee; }
.wizard-body { padding: 34px; }
.wizard-steps { display: flex; gap: 6px; margin-bottom: 24px; }
.wizard-steps i { flex: 1; height: 4px; border-radius: 2px; background: #e3ddfb; }
.wizard-steps i.on { background: var(--violet); }
.wizard-body h4 { font-family: 'Space Grotesk', sans-serif; font-size: 19px; margin-bottom: 8px; }
.wizard-body p { color: #6b6580; font-size: 14px; margin: 0 0 20px; }
.wz-row { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; border: 1px solid #e3ddfb; border-radius: 8px; margin-bottom: 10px; font-size: 14px; }
.wz-status { font-size: 11.5px; padding: 3px 10px; border-radius: 20px; background: #eafaf0; color: #1a9a56; font-weight: 600; }

/* ---------- CTA ---------- */
.cta-band {
  border-top: 1px solid var(--line);
  padding: 90px 0;
  text-align: left;
}
.cta-band .wrap { display: flex; justify-content: space-between; align-items: center; gap: 30px; flex-wrap: wrap; }
.cta-band h2 { font-size: clamp(26px, 3.4vw, 38px); max-width: 520px; }

/* ---------- Footer ---------- */
footer { border-top: 1px solid var(--line); padding: 40px 0; }
footer .wrap { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; }
.foot-links { display: flex; gap: 24px; }
.foot-links a { text-decoration: none; color: var(--mist); font-size: 13.5px; }
.foot-copy { color: var(--mist-dim); font-size: 13px; }

/* Fallback page/post styles for non-front-page templates */
.post-list { max-width: 720px; margin: 0 auto; }
.post-card { margin-bottom: 32px; }
.post-card h2 a { color: var(--paper); text-decoration: none; }
.page-content { color: var(--mist); line-height: 1.7; }
