/* daemons.here — v2 */

@font-face {
  font-family: "DM Sans";
  src: url("fonts/dmsans-latin.woff2") format("woff2");
  font-weight: 100 1000;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "DM Sans";
  src: url("fonts/dmsans-latin-ext.woff2") format("woff2");
  font-weight: 100 1000;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face { font-family: "DM Mono"; src: url("fonts/dmmono-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "DM Mono"; src: url("fonts/dmmono-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }

:root {
  --bg: #0d0d0d;
  --bg-2: #121212;
  --bg-3: #181818;
  --fg: #ecebe6;
  --fg-2: #c9c7c0;
  --muted: #8b8983;
  --dim: #5d5b57;
  --line: #262625;
  --line-2: #343432;
  --accent: #ff4f1f;       /* signal red-orange, used sparingly */
  --accent-soft: rgba(255, 79, 31, .14);
  --sans: "DM Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "DM Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --ease: cubic-bezier(.62, .02, .28, 1);
  --wrap: 1180px;
  --pad: clamp(20px, 5.5vw, 80px);
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
html { background: var(--bg); }
/* black-paper grain (assets/grain.svg, one static tile): it is the page BACKGROUND itself, painted
   by the body under every element. Text, faces, scribbles, buttons and form fields are always drawn
   on top of it; panels, cards, buttons and inputs have opaque fills, so no grain shows inside them. */
body {
  margin: 0;
  background: var(--bg); /* GRAIN-OFF (compare): was url("grain.svg") 0 0 / 320px 320px repeat */
  color: var(--fg);
  font: 400 17px/1.55 var(--sans);
  font-optical-sizing: auto;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
::selection { background: var(--accent); color: #0d0d0d; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

.skip { position: absolute; left: 12px; top: -60px; z-index: 50; background: var(--fg); color: var(--bg); padding: 8px 12px; border-radius: 8px; }
.skip:focus { top: 12px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.defs { position: absolute; width: 0; height: 0; }
.muted { color: var(--muted); }

/* cursor trail (main.js §4): above everything, never catches the pointer */
#trail { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 40; pointer-events: none; }
main, .nav, .foot { position: relative; z-index: 1; }

/* ---------- nav ---------- */
.nav {
  display: flex; justify-content: space-between; align-items: flex-start; gap: 24px;
  padding: 34px var(--pad) 0;
  position: absolute; top: 0; left: 0; right: 0; z-index: 5;
}
.wordmark { font-weight: 600; font-size: 16px; letter-spacing: -.01em; text-decoration: none; }
.dict { margin: 10px 0 0; font-size: 13.5px; color: var(--muted); line-height: 1.4; }
.dict .hw { color: var(--fg); }
.dict .br { color: var(--dim); }
.dict .ai { color: var(--accent); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.dict i { font-style: italic; }
.nav nav { display: flex; gap: clamp(18px, 3vw, 40px); padding-top: 18px; }
.nav nav a { text-decoration: none; text-transform: uppercase; font-size: 14px; letter-spacing: .02em; color: var(--fg-2); transition: color .2s; }
.nav nav a:hover { color: var(--fg); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 56px; padding: 0 34px;
  border: 1px solid var(--line-2); border-radius: 12px;
  background: #121212;
  font-weight: 600; font-size: 15px; letter-spacing: .02em; text-transform: uppercase; text-decoration: none;
  cursor: pointer; transition: border-color .25s, background .25s, color .25s;
}
.btn:hover { border-color: var(--fg-2); background: #161616; }
.btn:disabled { opacity: .5; cursor: progress; }
.btn--small { min-height: 40px; padding: 0 16px; font-size: 12.5px; border-radius: 9px; }
.btn--accent { border-color: var(--accent); color: var(--accent); }
.btn--accent:hover { background: var(--accent); color: #0d0d0d; border-color: var(--accent); }

.tag { font: 500 12px/1.3 var(--mono); text-transform: uppercase; letter-spacing: .12em; color: var(--fg-2); margin: 0; }
.tag--dim { color: var(--dim); }
.kicker { font: 500 12px/1.3 var(--mono); text-transform: uppercase; letter-spacing: .14em; color: var(--muted); margin: 0 0 18px; display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.pill { border: 1px solid var(--line-2); border-radius: 99px; padding: 3px 10px; color: var(--fg-2); }

.batch { display: inline-flex; align-items: center; gap: 10px; font: 500 12px/1 var(--mono); text-transform: uppercase; letter-spacing: .14em; color: var(--muted); margin: 26px 0 0; }
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 0 rgba(255, 79, 31, .5); animation: pulse 2.4s infinite; flex: none; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(255, 79, 31, .45); } 70% { box-shadow: 0 0 0 9px rgba(255, 79, 31, 0); } 100% { box-shadow: 0 0 0 0 rgba(255, 79, 31, 0); } }

/* ---------- hero ---------- */
.hero {
  position: relative; min-height: 100vh;
  padding: clamp(170px, 24vh, 240px) var(--pad) 120px;
  display: flex; flex-direction: column; align-items: center; text-align: center;
  overflow: hidden;
}
#field { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
.hero-copy { position: relative; z-index: 1; max-width: 1180px; display: flex; flex-direction: column; align-items: center; }
h1 {
  margin: 0; font-weight: 400; letter-spacing: -.055em; line-height: .98;
  font-size: clamp(46px, 7.6vw, 112px);
}
h1 span { display: block; }
h1 .l1 { color: #f3f2ee; text-shadow: 0 0 22px rgba(255, 255, 255, .14); }
h1 .l2 { color: var(--fg); margin-top: .06em; }
.lede { max-width: 620px; margin: 38px auto 0; color: var(--fg-2); font-size: clamp(16.5px, 1.45vw, 20px); line-height: 1.5; }
.cta-row { margin-top: 40px; }

.daemon { margin: 0; position: relative; }
.daemon .lean { transition: transform .45s cubic-bezier(.2, .8, .2, 1); will-change: transform; transform-origin: 50% 55%; }
/* referenced paths (<use href="file.svg#id">) don't inherit the file's root styling */
.knot use, .ln use { fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; }
.knot { display: block; width: 100%; height: auto; overflow: visible; color: var(--fg); }
.knot use, .knot .kp, .knot .kt { stroke-width: calc(var(--sw, 1.5) + var(--boost, 0) * 1px); transition: stroke-width .35s; }

.daemon--hero { position: relative; z-index: 1; width: min(460px, 82vw); margin-top: 70px; --sw: 1.15; }
.daemon--hero figcaption, .daemon--side figcaption { display: flex; gap: 14px; justify-content: center; margin-top: 10px; }

/* draw-in: only hidden when JS is around to reveal it */
.js .knot use, .js [data-draw] .ln use {
  stroke-dasharray: 1 1.05;
  stroke-dashoffset: 1.03;
  transition: stroke-dashoffset var(--dur, 2.6s) var(--ease) var(--delay, 0s), stroke-width .35s;
}
.js .is-drawn .knot use, .js [data-draw].is-drawn .ln use { stroke-dashoffset: 0; }
/* after drawing: boil (hand-drawn jitter) */
.is-alive .knot { animation: boil .42s steps(1) infinite, twitch 3.7s steps(1) infinite; }
@keyframes boil { 0% { filter: url(#boil-0); } 33% { filter: url(#boil-1); } 66% { filter: url(#boil-2); } }
@keyframes twitch {
  0% { transform: translate(0, 0) rotate(0); }
  21% { transform: translate(.4px, -.3px) rotate(.25deg); }
  47% { transform: translate(-.3px, .2px) rotate(-.2deg); }
  73% { transform: translate(.2px, .4px) rotate(.1deg); }
}
.is-paused .knot { animation-play-state: paused; }

/* ---------- sections ---------- */
.section { position: relative; padding: clamp(100px, 13vw, 170px) var(--pad); }
.wrap { max-width: var(--wrap); margin: 0 auto; }
.sec-head { max-width: 760px; margin-bottom: clamp(48px, 6vw, 80px); }
h2 { margin: 0; font-weight: 400; font-size: clamp(34px, 4.6vw, 64px); letter-spacing: -.045em; line-height: 1.02; }
h3 { margin: 0; font-weight: 500; font-size: 20px; letter-spacing: -.02em; line-height: 1.25; }
.sec-sub { color: var(--fg-2); max-width: 620px; margin: 24px 0 0; }
.section p { text-wrap: pretty; }

/* use cases */
.cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.card {
  border: 1px solid var(--line); border-radius: 16px; background: #0f0f0f;
  padding: 22px 22px 26px; display: flex; flex-direction: column; gap: 10px;
  transition: border-color .3s;
}
.card:hover { border-color: var(--line-2); }
.card .daemon { width: 78%; margin: 0 auto 8px; --sw: 1.7; }
.card p:not(.tag) { margin: 0; color: var(--muted); font-size: 15.5px; }

/* split layout */
.split { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.split-copy > p { color: var(--fg-2); margin: 22px 0 0; max-width: 480px; }
.split-copy h2 + p { margin-top: 30px; }
.punch { color: var(--fg) !important; font-weight: 500; }
.daemon--side { width: 230px; margin-top: 40px; --sw: 1.6; }
.daemon--side figcaption { justify-content: flex-start; flex-wrap: wrap; gap: 6px 14px; }

/* keys panel */
.panel { border: 1px solid var(--line-2); border-radius: 18px; background: #101010; padding: 8px 0 0; box-shadow: 0 30px 80px -40px rgba(0, 0, 0, .8); }
.panel-head { padding: 20px 24px 16px; border-bottom: 1px solid var(--line); }
.panel-head h3 { font-size: 18px; }
.panel-sub { margin: 6px 0 0; color: var(--dim); font-size: 13px; }
.keys { list-style: none; margin: 0; padding: 0; }
.key { display: flex; align-items: center; gap: 16px; justify-content: space-between; padding: 16px 24px; border-bottom: 1px solid var(--line); transition: opacity .3s; }
.key-name { margin: 0; font-weight: 500; display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; }
.kind { font: 400 11px/1 var(--mono); text-transform: uppercase; letter-spacing: .1em; color: var(--dim); }
.key-meta { margin: 6px 0 0; display: flex; flex-wrap: wrap; gap: 4px 16px; color: var(--muted); font-size: 13.5px; }
.key-actions { display: flex; align-items: center; gap: 12px; flex: none; }
.revoke {
  border: 1px solid var(--line-2); background: transparent; border-radius: 8px; padding: 7px 12px; cursor: pointer;
  font: 500 11.5px/1 var(--mono); text-transform: uppercase; letter-spacing: .1em; color: var(--fg-2);
  transition: border-color .2s, color .2s; min-width: 92px;
}
.revoke:hover { border-color: var(--accent); color: var(--accent); }
.key.is-revoked .key-main { opacity: .38; text-decoration: line-through; text-decoration-color: var(--dim); }
.key.is-revoked .revoke { color: var(--fg); border-color: var(--line-2); }
.key.is-revoked .revoke:hover { border-color: var(--fg-2); color: var(--fg); }
.switch {
  position: relative; width: 38px; height: 22px; border-radius: 99px; border: 1px solid var(--line-2); background: #1b1b1b;
  cursor: pointer; padding: 0; flex: none; transition: background .25s, border-color .25s;
}
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 14px; height: 14px; border-radius: 50%; background: var(--dim); transition: transform .25s, background .25s; }
.switch[aria-checked="true"] { border-color: var(--fg-2); }
.switch[aria-checked="true"]::after { transform: translateX(16px); background: var(--fg); }
.switch:disabled { opacity: .3; cursor: not-allowed; }
.switch--legend { display: inline-block; vertical-align: middle; border-color: var(--fg-2); cursor: default; transform: scale(.8); }
.switch--legend::after { transform: translateX(16px); background: var(--fg); }
.switch-legend { margin: 0; padding: 12px 24px; color: var(--dim); font: 400 12px/1 var(--mono); text-transform: uppercase; letter-spacing: .08em; text-align: right; border-bottom: 1px solid var(--line); }
.log { padding: 18px 24px 22px; }
.log-title { margin: 0 0 10px; font: 500 11px/1 var(--mono); text-transform: uppercase; letter-spacing: .14em; color: var(--dim); }
.log-list { list-style: none; margin: 0; padding: 0; font: 400 12.5px/1.5 var(--mono); color: var(--muted); display: grid; gap: 8px; }
.log-list li { display: grid; grid-template-columns: 1fr auto; gap: 16px; }
.log-list .who { color: var(--fg-2); text-transform: uppercase; letter-spacing: .06em; margin-right: 8px; }
.log-list .when { color: var(--dim); white-space: nowrap; }
.log-list li.is-new { animation: logIn .5s var(--ease); }
.log-list li.is-new .who { color: var(--accent); }
@keyframes logIn { from { opacity: 0; transform: translateY(-6px); } }

/* connect */
.connectors { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.conn {
  width: 100%; text-align: left; display: grid; grid-template-columns: 1fr auto; grid-template-rows: auto auto; gap: 4px 12px; align-items: center;
  padding: 18px 18px; border: 1px solid var(--line); border-radius: 14px; background: #0f0f0f; cursor: pointer;
  transition: border-color .25s, background .25s;
}
.conn:hover { border-color: var(--line-2); background: #141414; }
.conn-name { font-weight: 500; font-size: 17px; }
.conn-ex { grid-row: 2; color: var(--dim); font-size: 13px; }
.conn-state { grid-row: 1 / span 2; grid-column: 2; font: 500 11px/1 var(--mono); text-transform: uppercase; letter-spacing: .1em; color: var(--muted); border: 1px solid var(--line-2); border-radius: 99px; padding: 6px 10px; white-space: nowrap; }
.conn.is-busy .conn-state { color: var(--fg-2); }
.conn.is-on { border-color: var(--line-2); }
.conn.is-on .conn-state { color: var(--fg); border-color: var(--fg-2); }
.mcp { margin-top: 28px; padding: 22px; border: 1px dashed var(--line-2); border-radius: 14px; max-width: 640px; }
.mcp label { display: block; margin-bottom: 12px; }
.mcp-row { display: flex; gap: 10px; }
.mcp input {
  flex: 1; min-width: 0; height: 40px; padding: 0 14px; border-radius: 9px; border: 1px solid var(--line-2); background: #111;
  font: 400 14px/1 var(--mono);
}
.mcp input::placeholder { color: var(--dim); }
.mcp-status { margin: 10px 0 0; font: 400 12.5px/1.4 var(--mono); color: var(--muted); min-height: 1em; }
.mcp-status[data-state="error"] { color: var(--accent); }
.mcp-list { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 8px; }
.mcp-list li { display: flex; justify-content: space-between; gap: 12px; align-items: center; font: 400 13px/1.3 var(--mono); color: var(--fg-2); border-top: 1px solid var(--line); padding-top: 10px; }
.mcp-list li span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mcp-list button { background: none; border: 0; color: var(--dim); cursor: pointer; font: inherit; text-transform: uppercase; letter-spacing: .08em; font-size: 11px; }
.mcp-list button:hover { color: var(--fg); }

/* tunnel */
.tunnel { margin: 0; }
.tunnel svg, .crew-art svg { display: block; width: 100%; height: auto; overflow: visible; }
.ln { color: var(--fg); }
.ln use { stroke-width: 1.6; }
.ln--dim { color: var(--dim); }
.ln--dim use { stroke-width: 1.3; }
.ln--accent { color: var(--accent); }
.tunnel-legend { display: grid; grid-template-columns: 1fr 1fr 1fr; margin-top: 16px; }
.tunnel-legend .tag:nth-child(2) { text-align: center; }
.tunnel-legend .tag:nth-child(3) { text-align: right; }

/* crew */
.crew-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(32px, 5vw, 72px); align-items: center; }
.crew-knots use { stroke-width: 1.7; }
.crew-art .ln--dim use { stroke-width: 1.5; }
.crew-labels text { font: 500 19px var(--mono); letter-spacing: .14em; fill: var(--muted); text-anchor: middle; }
.crew-labels .you { fill: var(--bg); stroke: var(--accent); stroke-width: 1.5; }
.crew-labels .you-t { fill: var(--accent); font-size: 18px; }
.crew-points { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; }
.crew-points li { color: var(--muted); padding-left: 22px; position: relative; }
.crew-points li::before { content: ""; position: absolute; left: 0; top: .72em; width: 10px; height: 1px; background: var(--dim); }
.crew-points b { color: var(--fg); font-weight: 500; }

.chat { margin-top: clamp(56px, 7vw, 90px); max-width: 720px; border: 1px solid var(--line-2); border-radius: 18px; background: #101010; overflow: hidden; }
.chat-head { display: flex; gap: 14px; align-items: center; padding: 14px 20px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.voice { margin-left: auto; display: inline-flex; gap: 8px; align-items: center; font: 400 11.5px/1 var(--mono); text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.voice .dot { width: 6px; height: 6px; }
.msgs { list-style: none; margin: 0; padding: 18px 20px 22px; display: grid; gap: 14px; }
.msg { display: grid; grid-template-columns: 76px 1fr; gap: 14px; align-items: baseline; }
.msg .from { font: 500 11.5px/1.4 var(--mono); text-transform: uppercase; letter-spacing: .1em; color: var(--fg-2); }
.msg p { margin: 0; color: var(--fg-2); font-size: 15.5px; }
.msg--you .from { color: var(--fg); }
.msg--you p { color: var(--fg); }
.msg--approval { grid-template-columns: 1fr; gap: 8px; border: 1px solid var(--accent); border-radius: 12px; padding: 14px 16px; background: var(--accent-soft); }
.msg--approval .from { color: var(--accent); }
.msg--approval p { color: var(--fg); }
.msg--approval.is-done { border-color: var(--line-2); background: transparent; }
.msg--approval.is-done .from { color: var(--muted); }
.approve-actions { display: flex; gap: 10px; margin-top: 6px; }
.msg.is-new { animation: logIn .5s var(--ease); }

/* preorder */
.split--form { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
.split-copy > .batch--big { margin: 0 0 28px; }
.batch--big { margin: 0 0 24px; font-size: 12.5px; color: var(--fg-2); border: 1px solid var(--line-2); border-radius: 99px; padding: 9px 14px; }
.form { border: 1px solid var(--line-2); border-radius: 18px; background: #101010; padding: clamp(22px, 3vw, 34px); display: grid; gap: 22px; }
.field { margin: 0; padding: 0; border: 0; min-width: 0; display: grid; gap: 10px; }
.field > label, .field legend { font-size: 14px; color: var(--fg-2); padding: 0; margin-bottom: 0; }
.field legend { margin-bottom: 10px; }
.req { font: 400 11px/1 var(--mono); text-transform: uppercase; letter-spacing: .1em; color: var(--dim); margin-left: 6px; }
.form input[type="email"], .form input[type="text"], .form textarea, .form select, .chip--inline input {
  width: 100%; border: 1px solid var(--line-2); background: #111; border-radius: 10px; padding: 12px 14px; font-size: 16px;
  transition: border-color .2s;
}
.form textarea { resize: vertical; min-height: 90px; }
.form input:hover, .form textarea:hover, .form select:hover { border-color: #4a4a47; }
.form input:focus, .form textarea:focus, .form select:focus { outline: none; border-color: var(--fg-2); }
.form input::placeholder, .form textarea::placeholder { color: var(--dim); }
.form [aria-invalid="true"] { border-color: var(--accent) !important; }
.select { position: relative; }
.select::after { content: ""; position: absolute; right: 16px; top: 50%; width: 7px; height: 7px; border-right: 1.5px solid var(--muted); border-bottom: 1.5px solid var(--muted); transform: translateY(-70%) rotate(45deg); pointer-events: none; }
.form select { appearance: none; padding-right: 40px; cursor: pointer; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { position: relative; cursor: pointer; }
.chip input[type="checkbox"], .chip input[type="radio"] { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.chip span { display: inline-block; padding: 9px 14px; border: 1px solid var(--line-2); border-radius: 99px; font-size: 14.5px; color: var(--fg-2); transition: all .2s; }
.chip:hover span { border-color: #4a4a47; }
.chip input:checked + span { border-color: var(--fg); color: var(--bg); background: var(--fg); }
.chip input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.chip--inline { display: inline-flex; align-items: center; gap: 10px; cursor: default; }
.chip--inline .chip-label { border: 0; padding: 0; color: var(--muted); font-size: 13.5px; }
.chip--inline input { width: 84px; padding: 8px 12px; font-size: 15px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
/* signature field: decorative, optional. Drawing inside it does not scroll the page.
   Round 8: like the signature line on a paper document — right-hand side of the hero content,
   the line level with the "№ 01 · Clerk" caption. Absolutely placed, so it adds no height. */
.hero-stage { position: relative; z-index: 1; width: 100%; max-width: var(--wrap); display: flex; flex-direction: column; align-items: center; }
.sign { display: grid; gap: 8px; user-select: none; -webkit-user-select: none; text-align: right; }
.sign--hero {
  position: absolute; z-index: 1; right: 30px;
  width: clamp(260px, 25vw, 340px);
  top: calc(100% - 68px);            /* pad bottom 12px below the caption's bottom: the line sits just under the caption */
}
.sign--hero .sign-pad { height: 80px; }
html:not(.js) .sign { display: none; }
.sign-pad { position: relative; height: 92px; touch-action: none; cursor: crosshair; }
.sign-ink { position: absolute; inset: 0; width: 100%; height: 100%; display: block; pointer-events: none; }
/* the baseline + ✕: same nervous pen as the daemons (stroke, width, draw-in, boil) */
.sign-rule { position: absolute; left: 0; bottom: 0; width: 100%; height: 34px; overflow: visible; pointer-events: none; color: var(--fg); }
.sign-rule path { fill: none; stroke: currentColor; stroke-width: var(--sw, 2.6px); stroke-linecap: round; stroke-linejoin: round; }
.js .sign-rule path { stroke-dasharray: 1 1.05; stroke-dashoffset: 1.03; transition: stroke-dashoffset var(--dur) var(--ease) var(--delay, 0s); }
.js .sign-rule .sign-base { --dur: 1.1s; }
.js .sign-rule .sign-x1 { --dur: .2s; --delay: 1.05s; transition-timing-function: cubic-bezier(.4, 0, .6, 1); }
.js .sign-rule .sign-x2 { --dur: .2s; --delay: 1.33s; transition-timing-function: cubic-bezier(.4, 0, .6, 1); }
.sign.is-drawn .sign-rule path { stroke-dashoffset: 0; }
.sign.is-alive .sign-rule { animation: boil .42s steps(1) infinite; }
.daemon--hero.is-paused ~ .sign .sign-rule { animation-play-state: paused; }
.sign-meta { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 20px; }
.sign-label { margin-left: auto; font: 500 11.5px/1 var(--mono); text-transform: uppercase; letter-spacing: .14em; color: var(--fg-2); }
.sign-clear { background: none; border: 0; padding: 4px 0; margin: -4px 0; cursor: pointer; font: 400 11.5px/1 var(--mono); text-transform: lowercase; letter-spacing: .08em; color: var(--muted); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--dim); }
.sign-clear:hover { color: var(--accent); text-decoration-color: var(--accent); }
.sign-clear[hidden] { display: none; }
.sign-note { margin: 0; font-size: 12.5px; color: var(--dim); }
/* narrower than ~1100px the line would run into the knot: it drops just below the caption instead, still on the right */
@media (max-width: 1100px) {
  .sign--hero { position: relative; top: auto; right: auto; align-self: flex-end; width: min(340px, 70%); margin-top: 10px; }
}
/* the pact, as seen from the form: a tiny mono caps line by the submit button, only once sealed */
.pact-ok { font: 500 11.5px/1 var(--mono); text-transform: uppercase; letter-spacing: .14em; color: var(--accent); white-space: nowrap; }
html:not(.js) .pact-ok { display: none; }
.form { scroll-margin-top: 32px; }
.form-foot { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.status { margin: 0; font-size: 14.5px; color: var(--muted); }
.status[data-state="ok"] { color: var(--fg); }
.status[data-state="error"] { color: var(--accent); }

/* footer */
.foot { display: flex; gap: 24px; justify-content: space-between; align-items: center; flex-wrap: wrap; padding: 28px var(--pad) 34px; border-top: 1px solid var(--line); font-size: 13px; color: var(--fg-2); }
.foot nav { display: flex; gap: 22px; }
.foot nav a { text-decoration: none; color: var(--muted); }
.foot nav a:hover { color: var(--fg); }

/* ---------- faces: ASCII horns + eyes on every daemon (built by main.js) ---------- */
.daemon .lean { position: relative; container-type: inline-size; }
.art-box { position: relative; container-type: inline-size; }
.face {
  position: absolute; z-index: 2; pointer-events: none; user-select: none;
  display: flex; flex-direction: column; align-items: center;
  /* --k = knot width as a share of the container; the face scales with the knot */
  font: 500 clamp(var(--fmin, 12px), calc(var(--k, 1) * 8.5cqi), 28px)/1 var(--mono);
  white-space: pre; letter-spacing: 0; color: var(--accent);
  /* anchor = centre of the eyes row */
  transform: translate(-50%, -1.73em);
  text-shadow: none;  /* no halo/glow: lines may cross the face */
}
.face-h, .face-e { display: block; will-change: transform; }
.face-h { transform-origin: 50% 173%; }  /* rotates around the face centre */
.face-e { margin-top: .26em; }  /* a clear gap between horns and eyes */
.art-box .face { --fmin: 11px; }
/* horns + eyes pop in after the body has drawn (--fd: draw end + a fixed per-daemon pause, set by main.js) */
.js .face-h, .js .face-e { opacity: 0; scale: .35; }
.js .is-drawn .face-h, .js .is-drawn .face-e {
  opacity: 1; scale: 1;
  transition: opacity .22s ease-out var(--fd, 2.9s), scale .5s cubic-bezier(.3, 1.7, .5, 1) var(--fd, 2.9s);
}
.js .is-drawn .face-e { transition-delay: calc(var(--fd, 2.9s) + 90ms); }

/* crew: impulses along the connectors, YOU line flashes when someone asks */
.impulses use { fill: none; stroke: var(--accent); stroke-width: 2.4; stroke-linecap: round; stroke-dasharray: .03 3; stroke-dashoffset: 1; opacity: 0; }
.impulses use.is-ask { stroke-width: 3; stroke-dasharray: .05 3; }
.crew-art .ln--accent use.is-asked { animation: askLine 1.3s ease-out; }
@keyframes askLine { 0%, 40%, 80% { stroke-width: 1.6; opacity: 1; } 15%, 55% { stroke-width: 3.6; opacity: 1; } 28%, 68% { opacity: .45; } }
.crew-labels .you { transition: fill .5s; }
.crew-labels .you.is-asked { fill: rgba(255, 79, 31, .22); transition: fill .12s; }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .connectors { grid-template-columns: repeat(2, 1fr); }
  .split, .split--form, .crew-grid { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .nav { flex-direction: column; gap: 0; padding-top: 22px; }
  .dict { font-size: 12.5px; max-width: 330px; }
  .nav nav { padding-top: 16px; gap: 20px; }
  .nav nav a { font-size: 12.5px; }
  .hero { padding-top: 200px; padding-bottom: 80px; }
  h1 { letter-spacing: -.05em; }
  .lede { margin-top: 28px; }
  .daemon--hero { margin-top: 48px; }
  .sign--hero { width: 70%; margin-top: -10px; }   /* tucked up close under the caption */
  .sign--hero .sign-pad { height: 64px; }
  .cards { grid-template-columns: 1fr; }
  .card .daemon { width: 58%; }
  .key { flex-direction: column; align-items: stretch; gap: 12px; padding: 16px 18px; }
  .key-actions { justify-content: space-between; }
  .panel-head, .log, .switch-legend { padding-left: 18px; padding-right: 18px; }
  .log-list li { grid-template-columns: 1fr; gap: 2px; }
  .connectors { grid-template-columns: 1fr; }
  .tunnel-legend { grid-template-columns: 1fr; gap: 6px; }
  .tunnel-legend .tag:nth-child(n) { text-align: left; }
  .crew-labels text { font-size: 30px; }
  .crew-labels .you-t { font-size: 24px; }
  .crew-art .face { --fmin: 9px; letter-spacing: -.04em; }
  /* the bigger mobile labels would touch RUNNER's / WARDEN's horns: nudge them aside */
  .crew-labels text:nth-of-type(1) { transform: translate(-34px, -6px); }
  .crew-labels text:nth-of-type(3) { transform: translate(36px, 0); }
  .msg { grid-template-columns: 1fr; gap: 4px; }
  .daemon--side { width: 180px; }
  .foot { flex-direction: column; align-items: flex-start; gap: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  .daemon .lean { transition: none; }
  .is-alive .knot { animation: none; }
  .dot { animation: none; }
  .js .knot use, .js [data-draw] .ln use { transition: none; stroke-dashoffset: 0; }
  .impulses { display: none; }
  .js .is-drawn .face-h, .js .is-drawn .face-e { transition: none; }
  #trail { display: none; }
  .js .sign-rule path { transition: none; stroke-dashoffset: 0; }
  .sign.is-alive .sign-rule { animation: none; }
}
/* ---------- round 9: "↻ another daemon" — swap the hero daemon through two ASCII portals (main.js §10) ---------- */
.daemon--hero figcaption { flex-wrap: wrap; align-items: baseline; row-gap: 6px; }
.another {
  background: none; border: 0; padding: 4px 2px; margin: -4px 0; cursor: pointer;
  font: 500 11.5px/1.3 var(--mono); text-transform: uppercase; letter-spacing: .12em;
  color: var(--muted); transition: color .2s;
}
.another:hover, .another:focus-visible { color: var(--accent); }
.another:disabled { color: var(--dim); cursor: default; }
html:not(.js) .another { display: none; }
/* the inline knot path (replaces the <use> on the first swap) and the thread to a portal */
.knot .kp, .knot .kt { fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; }
.portal text { font-family: var(--mono); font-weight: 500; fill: var(--fg); text-anchor: middle; dominant-baseline: central; }
.portal text.pa { fill: var(--accent); }
/* while swapping: no lean/twitch/boil (the filter region would clip the thread and the portals) */
.daemon--hero.is-swapping .lean { transform: none !important; transition: none; }
.daemon--hero.is-swapping .knot { animation: none; }
.js .daemon--hero.face-off .face-h, .js .daemon--hero.face-off .face-e { opacity: 0; scale: .35; transition: opacity .14s ease-in, scale .2s ease-in; }
/* phones: the button gets its own row under the caption, and the signature pad starts just below it
   (round 8 tucked the pad up with -10px; that would now cover the button) */
@media (max-width: 760px) {
  .another { flex-basis: 100%; }
  .sign--hero { margin-top: 6px; }
}
.dict .ety { color: var(--muted); }
h1 .are { font-style: normal; color: var(--accent); }

/* ---------- round 11: "It lives where you already talk." — one chat hopping between messengers ---------- */
h2 .h2b { font-weight: 600; letter-spacing: -.05em; }
#anywhere .sec-sub + .sec-sub { margin-top: 14px; }
.hops {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; align-items: start;
  --av: 42px;
}
.hop { border: 1px solid var(--line-2); background: #101010; min-width: 0; }
/* each frame a slightly different kind of messenger window (no logos: just the label) */
.hop--bubbles { border-radius: 22px; }
.hop--rows { border-radius: 8px; margin-top: 46px; }
.hop--server { border-radius: 14px; margin-top: 18px; }
.hop--mail { border-radius: 4px; margin-top: 64px; }
.hop-head { display: flex; gap: 10px; align-items: baseline; justify-content: space-between; margin: 0; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.hop--mail .hop-head { border-bottom-style: dashed; }
.hop-msgs { list-style: none; margin: 0; padding: 16px 14px 18px; display: grid; gap: 12px; }
.hm { display: flex; gap: 10px; align-items: flex-start; min-width: 0; }
.hm > div { min-width: 0; }
.hm p { margin: 0; font-size: 14.5px; line-height: 1.42; color: var(--fg-2); overflow-wrap: anywhere; }
.hm-from { display: block; margin-bottom: 3px; font: 500 10.5px/1.3 var(--mono); text-transform: uppercase; letter-spacing: .12em; color: var(--muted); }
/* the daemon's avatar: Clerk's horns + eyes, red ASCII */
.av {
  flex: none; width: var(--av); height: var(--av); border: 1px solid var(--line-2); border-radius: 50%;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px;
  font: 500 10px/1 var(--mono); white-space: pre; color: var(--accent); background: var(--bg-2);
}
.av span:last-child { letter-spacing: .02em; }
.hop--rows .av, .hop--mail .av { border-radius: 9px; }
.av--blank { border-color: transparent; background: none; height: 1px; }
.av--you { font-size: 9.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--fg-2); }
/* Telegram-ish: speech bubbles, you on the right */
.hop--bubbles .hm p { padding: 9px 13px; border-radius: 16px 16px 16px 5px; background: var(--bg-3); border: 1px solid var(--line); }
.hop--bubbles .hm--you { justify-content: flex-end; }
.hop--bubbles .hm--you p { border-radius: 16px 16px 5px 16px; background: var(--fg); color: var(--bg); border-color: var(--fg); }
.hop--bubbles .hm--d .av { align-self: flex-end; }
.hm--you p { color: var(--fg); }
/* a screenshot sent as a file */
.shot { display: grid; width: 150px; max-width: 100%; border: 1px solid var(--line-2); border-radius: 6px; overflow: hidden; background: var(--bg-2); }
.shot-bar { display: flex; gap: 4px; padding: 5px 7px; border-bottom: 1px solid var(--line); }
.shot-bar i { width: 4px; height: 4px; border-radius: 50%; background: var(--dim); }
.shot-body { position: relative; display: grid; gap: 5px; padding: 9px 8px 10px; }
.shot-body i { display: block; height: 3px; border-radius: 2px; background: var(--line-2); }
.shot-body i:nth-child(1) { width: 70%; background: var(--dim); }
.shot-body i:nth-child(2) { width: 88%; }
.shot-body i:nth-child(3) { width: 52%; }
.shot-body b { position: absolute; right: 9px; bottom: 6px; font: 500 15px/1 var(--mono); color: var(--fg); }
.shot-name { padding: 5px 8px; border-top: 1px solid var(--line); font: 400 10.5px/1.2 var(--mono); color: var(--muted); }
/* asks before anything sensitive */
.hm-ask { display: flex; gap: 6px; margin-top: 8px; }
.hm-btn { font: 500 10.5px/1 var(--mono); text-transform: uppercase; letter-spacing: .1em; padding: 6px 10px; border: 1px solid var(--line-2); border-radius: 99px; color: var(--muted); }
.hm-btn--on { border-color: var(--accent); color: var(--accent); }
.hop--server .hm--you { margin-top: 2px; }
/* typing: three loose dashes, like the hero field's */
.typing { display: flex; gap: 10px; align-items: center; height: var(--av); }
.typing .av { opacity: .7; }
.typing-dashes { display: inline-flex; gap: 4px; align-items: center; padding: 0 2px; }
.typing-dashes i { display: block; width: 8px; height: 1.8px; border-radius: 1px; background: var(--muted); animation: dash 1.05s ease-in-out infinite; }
.typing-dashes i:nth-child(1) { rotate: -14deg; }
.typing-dashes i:nth-child(2) { rotate: 9deg; animation-delay: .17s; }
.typing-dashes i:nth-child(3) { rotate: -4deg; animation-delay: .34s; }
@keyframes dash { 0%, 100% { opacity: .25; translate: 0 0; } 40% { opacity: 1; translate: 0 -2.5px; } }
/* one by one when scrolled into view (main.js §11); without JS or with reduced motion all of it is just there */
.js .hops.is-armed .hm:not(.is-in) { display: none; }
.js .hops.is-armed .hm.is-in { animation: hmIn .45s var(--ease) both; }
@keyframes hmIn { from { opacity: 0; translate: 0 8px; } to { opacity: 1; translate: 0 0; } }
.js .hops.is-armed .hop { transition: border-color .4s; }
.js .hops.is-armed .hop.is-live { border-color: #4a4a47; }
@media (max-width: 1080px) {
  .hops { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hop--rows, .hop--server, .hop--mail { margin-top: 0; }
  .hop:nth-child(even) { margin-top: 36px; }
}
@media (max-width: 760px) {
  .hops { grid-template-columns: 1fr; gap: 14px; max-width: 460px; }
  .hop:nth-child(even) { margin-top: 0; }
  .hop:nth-child(odd) { margin-right: 18px; }
  .hop:nth-child(even) { margin-left: 18px; }
}
@media (prefers-reduced-motion: reduce) {
  .typing-dashes i { animation: none; opacity: .7; }
  .js .hops.is-armed .hm.is-in { animation: none; }
}

/* preorder: "a gang of [− N +] daemons" */
.gang-size { display: inline-flex; align-items: center; gap: 10px; flex-wrap: nowrap; }
.gang-size .chip-label { color: var(--muted); font-size: 14.5px; }
.stepper { display: inline-flex; align-items: center; border: 1px solid var(--line-2); border-radius: 99px; background: var(--bg-2); }
.stepper .step {
  width: 34px; height: 38px; display: grid; place-items: center; padding: 0; border: 0; background: none; cursor: pointer;
  font: 500 16px/1 var(--mono); color: var(--fg-2); border-radius: 99px; transition: color .2s;
}
@media (hover: hover) { .stepper .step:hover:not(:disabled) { color: var(--accent); } }
.stepper .step:disabled { color: var(--dim); cursor: default; }
.stepper input {
  width: 3ch; padding: 0; border: 0; background: none; text-align: center; color: var(--fg);
  font: 500 15px/1 var(--mono); -moz-appearance: textfield; appearance: textfield;
}
.stepper input::-webkit-outer-spin-button, .stepper input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.stepper input:focus { outline: none; }
.stepper:focus-within { outline: 2px solid var(--accent); outline-offset: 2px; }
.lede--mem { margin-top: .6em; color: var(--fg-2); }
.lede-aside { margin: .5em auto 0; max-width: 62ch; font: 400 13px/1.4 var(--mono); letter-spacing: .02em; color: var(--muted); }
/* Max 14052: tunnel + gang drawings ~1.7x faster */
.js .tunnel .knot use, .js .tunnel .ln use, .js .crew-art .knot use, .js .crew-art .ln use {
  transition: stroke-dashoffset calc(var(--dur, 2.6s) * .6) var(--ease) calc(var(--delay, 0s) * .6), stroke-width .35s;
}
.crew-art .ln--accent use.is-asked { animation-duration: .8s; }
.price { margin: .2em 0 .8em; font-size: 1.15rem; color: var(--fg); }
.price-num { font-weight: 600; color: var(--accent); }
.price-note { font: 400 .8em/1 var(--mono); text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }

/* legal */
.consent{max-width:62ch;margin:14px 0 0;font-size:13px;line-height:1.55;color:var(--muted,#8a8984)}
.consent a,.legal a{color:inherit;text-decoration:underline;text-underline-offset:3px}
.foot-legal{flex-basis:100%;font-size:12px}
.legal{max-width:720px;margin:0 auto;padding:56px 20px 64px;line-height:1.65;color:var(--fg)}
.legal h1{font-size:clamp(28px,4vw,40px);margin:24px 0 6px;letter-spacing:-.01em}
.legal h2{font-size:19px;margin:36px 0 10px}
.legal p,.legal li{color:#c9c8c2;font-size:16px}
.legal ul{padding-left:20px}
.legal-meta{font-family:"DM Mono",ui-monospace,monospace;font-size:12px;letter-spacing:.08em;text-transform:uppercase;color:#8a8984!important}
.legal-back{font-family:"DM Mono",ui-monospace,monospace;font-size:13px}
.legal-dot{color:#ff4f1f}
