/* GitHub Pages site — same deep-navy AI look as the dashboard. */
:root {
  --bg: #0a0f1e;
  --bg2: #0d1322;
  --card: #141b2e;
  --card2: #101728;
  --border: #2a3550;
  --text: #e8ecf4;
  --muted: #9aa7bd;
  --dim: #9aa7bd;
  --accent: #38bdf8;
  --cyan: #22d3ee;
  --blue: #38bdf8;
  --amber: #f59e0b;
  --amber-text: #fbbf24;
  --green: #34d399;
  --green-text: #6ee7b7;
  --red: #f87171;
  --radius: 16px;
  /* taste-skill moment tokens, mapped to this page's own tokens */
  --ink: var(--text);
  --surface: var(--card);
  --font-display: "Segoe UI", system-ui, -apple-system, sans-serif;
  --display-weight: 700;
  --t-lead: 17px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: "Segoe UI", system-ui, -apple-system, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--cyan); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap { max-width: 1200px; margin: 0 auto; padding: 0; }
@media (max-width: 768px) { .wrap { padding: 0 16px; } }

/* ---------- header ---------- */
header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(10, 15, 30, 0.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
header .wrap { display: flex; align-items: center; gap: 16px; height: 60px; }
.logo {
  width: 34px; height: 34px; border-radius: 10px;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  display: grid; place-items: center; font-size: 18px; color: #fff;
  flex: none;
}
header .name { font-weight: 700; font-size: 16px; letter-spacing: -0.2px; }
header nav { margin-left: auto; display: flex; gap: 20px; font-size: 14px; }
header nav a { color: var(--muted); }
header nav a:hover { color: var(--text); text-decoration: none; }
header .nav-cta { display: none; }
@media (max-width: 900px) {
  header .wrap { flex-wrap: wrap; height: auto; padding-top: 10px; padding-bottom: 10px; }
  header nav { display: flex; order: 3; flex-basis: 100%; margin-left: 0; overflow-x: auto; gap: 10px; padding-top: 10px; }
  header nav a { white-space: nowrap; }
  header nav a:not([href="#sim"]):not([href="#try"]):not(.nav-cta) { display: none; }
  header .nav-cta { display: inline-block; flex: none; padding: 8px 16px; font-size: 14px; }
}

/* ---------- hero ---------- */
.hero {
  padding: 84px 0 64px; min-height: 100svh; display: flex; align-items: center;
  background:
    radial-gradient(700px 420px at 18% 0%, rgba(124, 92, 255, 0.22), transparent 60%),
    radial-gradient(600px 380px at 88% 100%, rgba(34, 211, 238, 0.14), transparent 60%);
}
.hero .badge {
  display: inline-block; font-size: 13px; letter-spacing: 2px; text-transform: uppercase;
  color: var(--cyan); border: 1px solid rgba(34, 211, 238, 0.4);
  border-radius: 999px; padding: 7px 16px; background: rgba(34, 211, 238, 0.08);
}
.hero > .wrap { width: 100%; }
.hero h1 {
  font-size: clamp(38px, 6vw, 60px); line-height: 1.05; letter-spacing: -1.5px;
  margin: 22px 0 18px;
}
.hero h1 span {
  background: linear-gradient(90deg, var(--blue), var(--cyan));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero p.lede { font-size: 20px; color: var(--muted); max-width: 720px; }
.hero p.lede b { color: var(--text); }
.hero .cta { display: flex; gap: 12px; margin-top: 28px; flex-wrap: wrap; }
.btn {
  display: inline-block; padding: 12px 22px; border-radius: 12px;
  font-weight: 600; font-size: 15px; border: 1px solid var(--border);
  background: var(--card); color: var(--text);
}
.btn:hover { text-decoration: none; border-color: var(--accent); }
.btn.primary {
  background: #1d6fb8;
  border: none; color: #fff;
  box-shadow: 0 8px 24px rgba(29, 111, 184, 0.35);
}
.btn.primary:hover { background: #1a63a3; }
.hero .stats { display: flex; gap: 36px; justify-content: space-between; margin-top: 40px; flex-wrap: wrap; }
.hero .stats div { font-size: 14px; color: var(--muted); }
.hero .stats b { display: block; font-size: 28px; color: var(--text); letter-spacing: -0.5px; }

/* ---------- sections ---------- */
section { padding: 64px 0; }
section.alt { background: var(--bg2); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
h2 { font-size: 30px; letter-spacing: -0.8px; margin-bottom: 8px; }
.sub { color: var(--muted); font-size: 17px; max-width: 720px; margin-bottom: 32px; }
h3 { font-size: 19px; margin-bottom: 6px; }
p { color: var(--muted); }
p b, li b { color: var(--text); }

/* plain-english explainer */
.plain { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); gap: 16px; }
.card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 22px;
}
.card .icon { font-size: 26px; margin-bottom: 10px; }
.card p { font-size: 15px; }

/* interactive diagram */
.diagram-box {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 12px; overflow-x: auto;
}
.diagram-box svg { width: 100%; height: auto; display: block; min-width: 720px; }
.diagram-box svg .node-rect { transition: filter 0.25s ease, stroke-width 0.25s ease; }
.diagram-box svg g.node.hl .node-rect {
  filter: drop-shadow(0 0 10px rgba(34, 211, 238, 0.55));
  stroke-width: 3;
}
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); gap: 12px; margin-top: 16px; }
.step {
  text-align: left; cursor: pointer; background: var(--card2);
  border: 1px solid var(--border); border-radius: 12px; padding: 16px 18px;
  color: var(--text); font-family: inherit; font-size: 15px; line-height: 1.5;
}
.step:hover { border-color: var(--accent); }
.step.active { border-color: var(--cyan); background: #12203a; }
.step .num {
  display: inline-grid; place-items: center; width: 26px; height: 26px;
  border-radius: 50%; background: linear-gradient(135deg, var(--blue), var(--cyan));
  color: #fff; font-size: 13px; font-weight: 700; margin-right: 8px; vertical-align: middle;
}
.step .title { font-weight: 700; }
.step p { font-size: 14px; margin-top: 6px; }
.step-detail {
  margin-top: 16px; background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 20px 22px; font-size: 15px;
}
.step-detail b { color: var(--cyan); }

/* agents grid */
.agents { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.agent { border-top: 3px solid var(--blue); }
.agent:nth-child(2) { border-top-color: var(--accent); }
.agent:nth-child(3) { border-top-color: var(--cyan); }
.agent:nth-child(4) { border-top-color: var(--green); }
.agent code { color: var(--cyan); font-size: 13px; }

/* safety section */
.safety { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); gap: 16px; }
.safety .card { border-top: 3px solid var(--amber); }
.safety .card:nth-child(2) { border-top-color: var(--green); }
.safety .card:nth-child(3) { border-top-color: var(--blue); }

/* eval table */
table { width: 100%; border-collapse: collapse; font-size: 15px; }
th, td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--border); }
th { color: var(--dim); font-weight: 600; font-size: 13px; text-transform: uppercase; letter-spacing: 1px; }
td:last-child { font-weight: 700; }
.eval-note { font-size: 14px; margin-top: 14px; }
.eval-note code, code { background: #1b2540; padding: 2px 7px; border-radius: 6px; font-size: 13px; color: #c7d2e8; }

/* quickstart */
pre {
  background: #0d1220; border: 1px solid var(--border); border-radius: 12px;
  padding: 18px 20px; overflow-x: auto; font-size: 14px; line-height: 1.7;
  color: #c7d2e8; margin: 12px 0;
}
pre .c { color: #5b6b8c; }
code { overflow-wrap: anywhere; word-break: break-all; }
@media (max-width: 700px) {
  pre { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 12px; }
}

/* screenshots */
.shots { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
@media (max-width: 820px) { .shots { grid-template-columns: 1fr; } }
.shots figure { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.shots img { width: 100%; display: block; }
.shots figcaption { padding: 12px 16px; font-size: 14px; color: var(--muted); }

/* FAQ */
.faq details {
  background: var(--card); border: 1px solid var(--border);
  border-radius: 12px; padding: 16px 20px; margin-bottom: 10px;
}
.faq summary { cursor: pointer; font-weight: 700; font-size: 16px; color: var(--text); }
.faq summary:hover { color: var(--cyan); }
.faq p { margin-top: 8px; font-size: 15px; }

footer { padding: 40px 0 56px; color: var(--dim); font-size: 14px; text-align: left; }
footer a { color: var(--muted); }

/* ---------- hero entrance (once, on load) ---------- */
@keyframes hero-rise {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}
.hero [data-enter-item] { animation: hero-rise 0.52s cubic-bezier(0.22, 1, 0.36, 1) both; }
.hero [data-enter-item="1"] { animation-delay: 0.05s; }
.hero [data-enter-item="2"] { animation-delay: 0.15s; }
.hero [data-enter-item="3"] { animation-delay: 0.25s; }
.hero [data-enter-item="4"] { animation-delay: 0.35s; }
.hero [data-enter-item="5"] { animation-delay: 0.45s; }
@media (prefers-reduced-motion: reduce) {
  .hero [data-enter-item] { animation: none; }
}

a:focus-visible, button:focus-visible, summary:focus-visible, [tabindex]:focus-visible {
  outline: 2px solid var(--cyan); outline-offset: 2px;
}

/* ---------- live simulation ---------- */
#sim { min-height: 200svh; }
.sim-scenarios { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 16px; }
.sim-scenario {
  cursor: pointer; background: var(--card); border: 1px solid var(--border);
  border-radius: 12px; padding: 12px 22px; color: var(--text);
  font-family: inherit; font-size: 15px; font-weight: 600; line-height: 1.4;
  transition: border-color 150ms ease;
}
.sim-scenario:hover { border-color: var(--blue); }
.sim-scenario.active { border-color: var(--cyan); background: #12203a; }
.sim-panel {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 20px; position: relative;
}
.sim-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 24px; align-items: start; }
.sim-flow { grid-column: 1 / 8; }
.sim-trace { grid-column: 8 / 13; }
@media (max-width: 820px) { .sim-grid { grid-template-columns: 1fr; } .sim-flow, .sim-trace { grid-column: 1 / -1; } }
.sim-flow { position: relative; }
.sim-station {
  display: flex; gap: 12px; align-items: flex-start; position: relative;
  padding: 12px 14px 12px 34px; border: 1px solid var(--border);
  border-radius: 12px; background: var(--card2); margin-bottom: 10px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.sim-station::before {
  content: ""; position: absolute; left: 17px; top: -10px; bottom: 50%;
  width: 2px; background: var(--border);
}
.sim-station:first-child::before { display: none; }
.sim-station.on { border-color: var(--cyan); box-shadow: 0 0 0 1px var(--cyan), 0 0 18px rgba(34, 211, 238, 0.25); }
.sim-station.done { border-color: #2f4a3a; }
.sim-station.holding { border-color: var(--amber); box-shadow: 0 0 0 1px var(--amber), 0 0 18px rgba(245, 158, 11, 0.3); }
.sim-station h3 { font-size: 19px; margin-bottom: 2px; }
.sim-station .sim-note { font-size: 13px; color: var(--muted); }
.sim-station .sim-note b { color: var(--text); }
.sim-station .tech { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 11px; color: var(--dim); text-transform: uppercase; letter-spacing: 1px; }
.sim-particle {
  position: absolute; left: 0; top: 0; width: 14px; height: 14px; margin: -7px 0 0 -7px;
  border-radius: 50%; background: var(--cyan); z-index: 3; pointer-events: none;
  box-shadow: 0 0 12px rgba(34, 211, 238, 0.9);
  transition: transform 0.55s cubic-bezier(0.65, 0, 0.35, 1);
  opacity: 0;
}
.sim-particle.go { opacity: 1; }
.sim-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.sim-chip {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px;
  border: 1px solid var(--border); border-radius: 999px; padding: 5px 11px;
  color: var(--muted); background: var(--bg2); opacity: 0.45;
  transition: opacity 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}
.sim-chip.on { opacity: 1; border-color: var(--cyan); color: var(--text); }
.sim-chip.done { opacity: 1; border-color: var(--green); color: var(--green-text); }
.sim-chip.failed { opacity: 1; border-color: var(--red); color: var(--red); }
.sim-chip.comp { opacity: 1; border-color: var(--amber); color: var(--amber-text); }
.sim-gate-actions { display: flex; gap: 10px; margin-top: 10px; }
.sim-gate-actions .btn { padding: 10px 18px; font-size: 14px; cursor: pointer; }
.sim-gate-actions .btn:disabled { opacity: 0.4; cursor: default; }
.btn.approve { background: var(--green); border: none; color: #06130c; }
.btn.reject { background: transparent; border-color: var(--red); color: var(--red); }
.sim-narration { min-height: 1.6em; font-size: 15px; color: var(--text); margin: 4px 0 16px; }
.sim-controls { display: flex; gap: 10px; flex-wrap: wrap; }
.sim-controls .btn { cursor: pointer; }
.sim-controls .btn:disabled { opacity: 0.4; cursor: default; }
.sim-trace {
  background: #0d1220; border: 1px solid var(--border); border-radius: 12px;
  padding: 14px 16px; min-height: 320px;
}
.sim-trace-title { font-size: 13px; text-transform: uppercase; letter-spacing: 1px; color: var(--muted); margin-bottom: 10px; font-weight: 600; }
.sim-trace ol { list-style: none; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12.5px; line-height: 1.9; color: #c7d2e8; }
.sim-trace li b { color: var(--cyan); font-weight: 600; }
.sim-trace li .t-ms { color: var(--dim); white-space: nowrap; }
.sim-trace li.fail b { color: var(--red); }
.sim-trace li.comp b { color: var(--amber-text); }
.sim-trace li.ok b { color: var(--green-text); }
.sim-trace .t-empty { color: var(--dim); font-size: 13px; }
@media (prefers-reduced-motion: reduce) {
  .sim-particle { transition: none; }
  .sim-station, .sim-chip { transition: none; }
}

/* ---------- architecture layers ---------- */
#layers { --p-bg: var(--bg2); }
.layers { display: grid; gap: 12px; }
.layer {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 18px 20px;
  display: grid; grid-template-columns: 190px 1fr; gap: 4px 20px;
  transition: border-color 150ms ease;
}
.layer:hover, .layer:focus-within { border-color: var(--blue); }
.layer h3 { font-size: 19px; }
.layer .tech { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; color: var(--cyan); }
.layer p { font-size: 15px; }
.layer .why { color: var(--dim); transition: color 150ms ease; }
.layer:hover .why, .layer:focus-within .why { color: var(--text); }
@media (max-width: 700px) { .layer { grid-template-columns: 1fr; } }

/* ---------- statement ---------- */
.statement { text-align: left; padding: 96px 0; min-height: 100svh; display: grid; place-items: center; }
.statement .mo-la__sub { max-width: 720px; }
.statement h2 { font-size: clamp(40px, 7vw, 76px); line-height: 1.05; letter-spacing: -2px; }
.statement p { max-width: 560px; margin: 18px auto 0; font-size: 17px; }
