:root {
  --canvas: #ffffff;
  --band: #f8fafd;
  --edge: #e5edf5;
  --ink: #061b31;
  --subdued: #64748d;
  --body: #50617a;
  --action: #533afd;
  --action-edge: #b9b9f9;
  --night: #0d1738;
  --night-edge: #182659;
  --night-copy: #839bc8;
  --ok: #0e9f6e;
  --sans: "Inter", "SF Pro Display", system-ui, sans-serif;
  --mono: "Source Code Pro", ui-monospace, monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--canvas); color: var(--ink); font: 300 16px/1.4 var(--sans); -webkit-font-smoothing: antialiased; }
a { color: var(--action); text-decoration: none; }
h1, h2, h3, p { margin: 0; }
.mono { font-family: var(--mono); }
.ink { color: var(--ink); }
.soft { color: var(--subdued); }

/* Rail frame: 1266px with 1px side rails, carried through every band. */
.rail { width: min(1266px, 100%); margin: 0 auto; padding: 0 16px; border-left: 1px solid var(--edge); border-right: 1px solid var(--edge); position: relative; }

.btn {
  display: inline-flex; align-items: center; gap: 8px; height: 48px; padding: 0 24px; border-radius: 4px;
  background: var(--action); color: #fff; font: 400 16px/1 var(--sans); border: 1px solid var(--action); cursor: pointer;
  transition: background-color .3s cubic-bezier(.25,1,.5,1);
}
.btn:hover { background: #4330e8; }
.btn.ghost { background: transparent; color: var(--action); border-color: var(--action-edge); }
.btn.ghost:hover { background: #f4f3ff; }
.btn.small { height: 40px; padding: 0 16px; font-size: 14px; }
.link { background: none; border: 0; padding: 0; cursor: pointer; color: var(--action); font: 400 16px/1 var(--sans); }
.link:hover { text-decoration: underline; text-underline-offset: 3px; }

/* Nav */
.nav { position: absolute; top: 0; left: 0; right: 0; z-index: 5; }
.nav-in { height: 76px; display: flex; align-items: center; justify-content: space-between; border-color: transparent; }
.wordmark { color: var(--ink); font: 500 19px/1 var(--sans); letter-spacing: -0.02em; }
.nav nav { display: flex; gap: 32px; }
.nav nav a { color: var(--ink); font: 400 14px/1 var(--sans); }
.nav nav a:hover { color: var(--action); }

/* Hero */
.hero { position: relative; overflow: hidden; }
/* Anchored to the bottom edge so the ribbon always runs into the next section, never stops mid-air. */
.ribbon { position: absolute; bottom: 0; right: -12%; height: 112%; width: auto; max-width: none; pointer-events: none; mix-blend-mode: multiply; }
.hero-in { padding-top: 196px; padding-bottom: 132px; }
.eyebrow { font: 400 14px/1.4 var(--sans); color: var(--ink); margin-bottom: 40px; padding-left: calc(100% / 12); }
.hero h1 { font: 300 48px/1.15 var(--sans); letter-spacing: -0.02em; max-width: 700px; padding-left: calc(100% / 12); position: relative; }
.actions { display: flex; gap: 8px; margin-top: 40px; flex-wrap: wrap; }
.hero .actions { padding-left: calc(100% / 12); }

h2 { font: 300 32px/1.1 var(--sans); letter-spacing: -0.02em; max-width: 860px; }

/* Demo */
.demo { padding: 96px 0; border-top: 1px solid var(--edge); }
.tabs { display: flex; gap: 8px; margin: 40px 0 24px; }
.tab { height: 40px; padding: 0 16px; border-radius: 4px; border: 1px solid var(--edge); background: #fff; color: var(--body); font: 400 14px/1 var(--sans); cursor: pointer; }
.tab.on { border-color: var(--action); color: var(--action); background: #f6f5ff; }
.stage { border-radius: 6px; overflow: hidden; padding: 56px 48px; background: #fbe9dd url("brand/stage.jpg") center / cover no-repeat; }
.window {
  border-radius: 6px; background: rgba(248, 250, 253, 0.55); outline: 1px solid rgba(229, 237, 245, 0.6);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); box-shadow: 0 15px 35px rgba(23, 23, 23, 0.08); padding: 0 12px 12px;
}
.chrome { height: 40px; display: flex; align-items: center; gap: 6px; }
.chrome i { width: 10px; height: 10px; border-radius: 50%; background: rgba(6, 27, 49, 0.14); }
.address { margin: 0 auto; transform: translateX(-24px); font-size: 12px; color: var(--subdued); background: rgba(255, 255, 255, 0.7); padding: 4px 18px; border-radius: 4px; }
.panes { display: grid; grid-template-columns: 1fr 1fr 1.25fr; gap: 12px; }
.pane { background: #fff; border-radius: 6px; box-shadow: 0 3px 6px rgba(23, 23, 23, 0.06); padding: 16px; height: 384px; display: flex; flex-direction: column; min-width: 0; }
.pane-head { display: flex; justify-content: space-between; align-items: baseline; font: 400 14px/1 var(--sans); color: var(--ink); padding-bottom: 12px; border-bottom: 1px solid var(--edge); margin-bottom: 12px; }
.tag { font-size: 11.5px; color: var(--subdued); }
.code { margin: 0; font: 400 12px/1.65 var(--mono); color: var(--ink); white-space: pre; overflow: hidden; }
.code .c { color: #8a97ab; }
.code .k { color: var(--action); }
.facts { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 14px; font-size: 14px; color: var(--body); }
.facts b { display: block; font-weight: 400; color: var(--ink); font-size: 15px; }
.txs { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; font-size: 12px; overflow: hidden; }
.txs li { display: grid; grid-template-columns: 58px 1fr auto; gap: 8px; padding: 6px 8px; border-radius: 4px; color: var(--body); }
.txs li .n { color: var(--ink); }
.txs li.now { background: #f1efff; color: var(--action); }
.txs li.now .n { color: var(--action); }
.txs li.load { color: var(--subdued); }
.out { flex: 1; min-height: 0; overflow: hidden; font-size: 11.5px; line-height: 1.55; color: var(--ink); white-space: pre; display: flex; flex-direction: column; justify-content: flex-end; }
.out div.new { color: var(--action); }
.status { display: flex; justify-content: space-between; align-items: center; padding: 12px 4px 0; font: 400 13px/1 var(--sans); color: var(--body); }
.status .ok { color: var(--ok); }
.details { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 48px; color: var(--body); }
.details b { font-weight: 400; color: var(--ink); }

/* Use cases */
.use { padding: 96px 0; background: var(--band); border-top: 1px solid var(--edge); }
.cases { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 56px; border-top: 1px solid var(--edge); }
.cases article { padding: 32px 24px 8px 0; display: flex; flex-direction: column; gap: 14px; align-items: flex-start; }
.cases article + article { padding-left: 24px; border-left: 1px solid var(--edge); }
.case-label { font: 400 14px/1 var(--sans); color: var(--action); }
.cases h3 { font: 300 22px/1.15 var(--sans); letter-spacing: -0.01em; }
.metric { font: 300 48px/1.03 var(--sans); letter-spacing: -0.02em; color: var(--ink); }
.metric small { font-size: 16px; color: var(--subdued); letter-spacing: 0; }
.cap { color: var(--body); }

/* Night */
.night { background: var(--night); color: #fff; padding: 96px 0; }
.night .rail { border-color: var(--night-edge); }
.night .ink { color: #fff; }
.night .soft { color: var(--night-copy); }
.diagram { display: grid; grid-template-columns: 1fr 64px 1fr 64px 1fr; align-items: center; margin: 56px 0 64px; }
.node { border: 1px solid var(--night-edge); border-radius: 6px; padding: 20px; background: rgba(255, 255, 255, 0.02); display: flex; flex-direction: column; gap: 10px; min-height: 168px; }
.node-k { font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: #a99bff; }
.node-v { font-size: 18px; line-height: 1.3; color: #fff; }
.node-n { margin-top: auto; font-size: 12.5px; color: var(--night-copy); }
.wire { height: 0; border-top: 1px dashed #4a5aa8; position: relative; }
.wire::after { content: ""; position: absolute; right: -1px; top: -4px; border: 4px solid transparent; border-left-color: #4a5aa8; }
.metrics { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--night-edge); }
.metrics div { padding: 36px 16px; border-right: 1px solid var(--night-edge); display: flex; flex-direction: column; gap: 12px; }
.metrics div:last-child { border-right: 0; }
.night .metric { color: #fff; }
.night .cap { color: var(--night-copy); }

/* Closing */
.closing { background: var(--band); padding: 96px 0; border-top: 1px solid var(--edge); }
.closing-in { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.closing h2 { max-width: 520px; }
.cmd { margin: 0; background: #fff; border: 1px solid var(--edge); border-radius: 6px; padding: 20px 22px; font-size: 13px; line-height: 1.9; color: var(--ink); white-space: pre-wrap; word-break: break-word; }
.cmd span { color: var(--subdued); user-select: none; }

.foot { border-top: 1px solid var(--edge); }
.foot-in { display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; padding-top: 32px; padding-bottom: 32px; font-size: 14px; color: var(--subdued); }

@media (max-width: 900px) {
  .nav nav { display: none; }
  /* On phones the ribbon lives below the buttons, never behind the headline. */
  .ribbon { height: 260px; right: -30%; }
  .hero-in { padding-top: 132px; padding-bottom: 290px; }
  .eyebrow, .hero h1, .hero .actions { padding-left: 0; }
  .hero h1 { font-size: 36px; }
  h2 { font-size: 26px; }
  .stage { padding: 20px 10px; }
  .panes { grid-template-columns: 1fr; }
  .pane { height: auto; min-height: 0; }
  .pane .txs, .pane .out { max-height: 230px; }
  .out { min-height: 200px; font-size: 10.5px; }
  .code { font-size: 11px; }
  .details, .cases, .metrics, .closing-in { grid-template-columns: 1fr; }
  .cases article + article { border-left: 0; padding-left: 0; border-top: 1px solid var(--edge); }
  .diagram { grid-template-columns: 1fr; gap: 0; }
  .wire { width: 0; height: 32px; border-top: 0; border-left: 1px dashed #4a5aa8; margin-left: 24px; }
  .wire::after { display: none; }
  .metrics div { border-right: 0; border-bottom: 1px solid var(--night-edge); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
.out.wrap { white-space: pre-wrap; word-break: break-all; }
.nav .btn.ghost { background: #fff; }
.nav .btn.ghost:hover { background: #f4f3ff; }

/* Icons: brand logos from Simple Icons, interface icons from Lucide, inlined by app.js. */
.ic { display: inline-flex; width: 1.15em; height: 1.15em; vertical-align: -0.2em; flex: none; }
.ic svg { width: 100%; height: 100%; }
.ic:not(.brand) svg { stroke-width: 1.75; }
.btn .ic, .link .ic, .tab .ic { margin-right: 2px; }
.wordmark { display: inline-flex; align-items: center; gap: 8px; }
.wordmark .ic { width: 20px; height: 20px; }
.eyebrow { display: flex; align-items: center; gap: 8px; }
.eyebrow .ic { width: 16px; height: 16px; }

/* Hero logo rail */
.logos { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 22px; margin-top: 56px; padding-left: calc(100% / 12); color: var(--body); font: 400 15px/1 var(--sans); max-width: 560px; }
.logos-label { color: var(--subdued); font-weight: 300; }
.logo { display: inline-flex; align-items: center; gap: 8px; color: var(--ink); }
.logo .ic { width: 22px; height: 22px; }

/* How it works */
.steps { padding: 96px 0; border-top: 1px solid var(--edge); }
.flow { list-style: none; margin: 56px 0 0; padding: 0; display: grid; grid-template-columns: 1fr 48px 1fr 48px 1fr; align-items: stretch; }
.flow > li:not(.arrow) { border: 1px solid var(--edge); border-radius: 6px; padding: 28px 24px; display: flex; flex-direction: column; gap: 12px; position: relative; background: #fff; }
.flow .arrow { display: flex; align-items: center; justify-content: center; color: var(--action-edge); }
.flow .arrow .ic { width: 26px; height: 26px; }
.flow-ic { width: 52px; height: 52px; border-radius: 6px; display: grid; place-items: center; background: #f4f3ff; color: var(--action); }
.flow-ic .ic { width: 28px; height: 28px; }
.flow-ic.sol { background: #f5f3ff; }
.flow-ic.ok { background: #ecfdf5; color: var(--ok); }
.flow-n { position: absolute; top: 24px; right: 24px; color: var(--subdued); font-size: 13px; }
.flow h3 { font: 400 22px/1.15 var(--sans); letter-spacing: -0.01em; }
.flow p { color: var(--body); }
.flow-logos { display: flex; align-items: center; gap: 12px; margin-top: auto; padding-top: 8px; font-size: 12.5px; color: var(--subdued); }
.flow-logos .ic { width: 22px; height: 22px; }
.flow-logos.mono .ic { width: 16px; height: 16px; margin-right: -6px; }
.flow-logos.ok { color: var(--ok); }

/* Demo additions */
.tab { display: inline-flex; align-items: center; gap: 8px; }
.tab .ic { width: 16px; height: 16px; }
.ph { display: inline-flex; align-items: center; gap: 8px; }
.ph .ic { width: 16px; height: 16px; }
.ph-n { width: 20px; height: 20px; border-radius: 50%; background: var(--action); color: #fff; font-size: 11px; display: grid; place-items: center; }
.cmds { list-style: none; margin: 14px 0 0; padding: 0; display: flex; flex-direction: column; gap: 6px; font: 400 12px/1.35 var(--mono); }
.cmds li { display: grid; grid-template-columns: 18px 1fr; gap: 6px; padding: 6px 8px; border-radius: 4px; color: var(--subdued); }
.cmds li .ic { width: 15px; height: 15px; }
.cmds li.done { color: var(--ink); }
.cmds li.done .ic { color: var(--ok); }
.cmds li.now { background: #f1efff; color: var(--action); }
.prog-head { display: flex; align-items: center; gap: 10px; font: 400 14px/1.3 var(--sans); color: var(--ink); }
.prog-head .ic { width: 28px; height: 28px; }
.prog-head small { display: block; color: var(--subdued); font-size: 12.5px; font-weight: 300; }
.txs li.type { color: var(--ok); }
.txs li.type .n { color: var(--ok); }
.txs li .ic { width: 13px; height: 13px; margin-right: 4px; }
.out .cmd-line { color: var(--action); }
.status { gap: 12px; }
.status .link { display: inline-flex; align-items: center; gap: 4px; font-size: 14px; }
.legend { display: flex; flex-wrap: wrap; gap: 8px 28px; margin-top: 18px; font-size: 12.5px; color: var(--subdued); }
.legend .ic { width: 15px; height: 15px; margin-right: 6px; }
.case-label { display: inline-flex; align-items: center; gap: 8px; }
.case-label .ic { width: 20px; height: 20px; }
.node-k { display: inline-flex; align-items: center; gap: 8px; }
.node-k .ic { width: 18px; height: 18px; }

@media (max-width: 900px) {
  .logos { padding-left: 0; margin-top: 40px; }
  .flow { grid-template-columns: 1fr; gap: 0; }
  .flow .arrow { height: 40px; transform: rotate(90deg); }
}

.scrub { display: block; width: 100%; margin: 12px 0 2px; accent-color: var(--action); }

/* Site footer, shared by every page (web/partials/footer.html). */
.sfoot { border-top: 1px solid var(--edge); background: var(--canvas); }
.sfoot-in { max-width: 1266px; margin: 0 auto; padding: 56px 24px 40px; display: grid; grid-template-columns: 1.6fr repeat(4, 1fr); gap: 32px; }
.sfoot .wordmark { display: inline-flex; align-items: center; gap: 9px; }
.sfoot-brand p { margin-top: 14px; color: var(--body); font-size: 14px; max-width: 260px; }
.sfoot-brand .sfoot-note { margin-top: 6px; color: var(--subdued); }
.sfoot nav { display: flex; flex-direction: column; gap: 10px; }
.sfoot nav p { font: 500 12px/1 var(--sans); letter-spacing: .06em; text-transform: uppercase; color: var(--subdued); margin-bottom: 4px; }
.sfoot nav a { color: var(--ink); font: 400 14px/1.3 var(--sans); }
.sfoot nav a:hover { color: var(--action); }
.sfoot-bottom { max-width: 1266px; margin: 0 auto; padding: 20px 24px 32px; border-top: 1px solid var(--edge); display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; font-size: 12px; line-height: 1.5; color: var(--subdued); }
.sfoot-bottom span:last-child { max-width: 760px; }
@media (max-width: 900px) {
  .sfoot-in { grid-template-columns: 1fr 1fr; padding: 40px 16px 28px; }
  .sfoot-brand { grid-column: 1 / -1; }
  .sfoot-bottom { padding: 16px 16px 28px; }
}
.honest { padding-top: 24px; padding-bottom: 24px; font-size: 13px; color: var(--subdued); border-top: 1px solid var(--edge); }
.wordmark .lockup { display: block; height: 24px; width: auto; }
.sfoot .wordmark .lockup { height: 22px; }
