@import url("design-tokens.06fd854a2d20.css");
/* castellan.us: one stylesheet for every page. No trackers. */
/* The fonts come from this site, under fonts/, with their licenses beside
   them: the Latin subset of each variable font, on the weight axis only.
   No page asks a third party for anything. */
@font-face {
  font-family: "Newsreader";
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url(fonts/newsreader-latin-wght-normal.62981321d9a3.woff2) format("woff2-variations");
  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: "Newsreader";
  font-style: italic;
  font-weight: 200 800;
  font-display: swap;
  src: url(fonts/newsreader-latin-wght-italic.48bc8861b9b2.woff2) format("woff2-variations");
  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: "Public Sans";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(fonts/public-sans-latin-wght-normal.5ed4d31c988e.woff2) format("woff2-variations");
  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: "JetBrains Mono";
  font-style: normal;
  font-weight: 100 800;
  font-display: swap;
  src: url(fonts/jetbrains-mono-latin-wght-normal.18be452724bf.woff2) format("woff2-variations");
  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;
}
:root {
  /* The deck page's slide styles read these names. */
  --paper: var(--surface);
  --night: var(--bg);
  --night2: var(--raise);
  --night-line: var(--line);
  --night-ink: var(--ink);
  --night-muted: var(--muted);
  --ink2: var(--ink);
  --line-soft: var(--line);
  --rose: var(--accent);
  --wine: var(--button);
  --serif: var(--display);
  color-scheme: dark;
}

html { -webkit-text-size-adjust: 100%; background: var(--ground); }
body { margin: 0; color: var(--ink); font-family: var(--text); font-size: var(--body); line-height: 1.6; }
/* The glow sits in a fixed layer behind the page so it never stretches with
   a long page and never scrolls. Nothing else paints under the content. */
body::before { content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(58% 46% at 50% 38%, var(--glow-wine), transparent 100%),
    radial-gradient(42% 38% at 12% 16%, var(--glow-blue), transparent 100%),
    radial-gradient(46% 42% at 90% 88%, var(--glow-violet), transparent 100%),
    radial-gradient(36% 30% at 80% 8%, var(--glow-blue), transparent 100%),
    linear-gradient(180deg, var(--ground) 0%, var(--ground-2) 100%); }
p, h1, h2, h3, ul, ol, figure { margin: 0; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { color: var(--ink); }
:focus-visible { outline: 3px solid var(--sky); outline-offset: 3px; border-radius: var(--radius-chip); }
code { font-family: var(--mono); font-size: 0.9em; }
.vh { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
/* Skip to content: the first tab stop on every page, shown only while focused. */
.skip { position: absolute; left: 16px; top: -100px; z-index: 5; padding: 12px 18px; border-radius: var(--radius-control); background: var(--sky); color: var(--on-button); font-weight: 600; text-decoration: none; }
.skip:focus { top: 16px; }
main:focus { outline: none; }
/* A link inside running text gets a 44px tall tap area without moving the lines around it. */
main p a:not(.btn), main li a:not(.btn) { padding-block: 14px; }

/* Type: display, text, ui */
h1, h2, .display { font-family: var(--display); font-weight: 500; text-wrap: balance; }
h1 { font-size: var(--displayLg); line-height: 1.08; }
h2 { font-size: var(--displayMd); line-height: 1.15; }
h3 { font-family: var(--text); font-size: var(--displaySm); font-weight: 650; line-height: 1.35; }
.lead { font-size: 21px; color: var(--muted); max-width: 720px; }
.muted { color: var(--muted); }
.small { font-size: 16px; }
.ui, .btn, .nav-links, .menu-nav, .foot-links, th { font-family: var(--text); font-size: var(--ui); font-weight: 600; letter-spacing: 0; }
.mono { font-family: var(--mono); }

/* Layout */
.wrap { max-width: 1160px; margin: 0 auto; padding-left: 24px; padding-right: 24px; }
.sec { max-width: 1160px; margin: 0 auto; padding: 80px 24px; display: flex; flex-direction: column; gap: 24px; }
.sec + .sec:not(.band) { padding-top: 0; }
.sec.band + .sec { padding-top: 80px; }
.sec.band { padding-top: 64px; padding-bottom: 64px; }
.sec.band { max-width: none; background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.sec.band > * { width: 100%; max-width: 1160px; margin-left: auto; margin-right: auto; }
.page-hero { padding-top: 72px; padding-bottom: 48px; }
.measure { max-width: 720px; }
.cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 20px; }
.split { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 56px; align-items: center; }
.stack { display: flex; flex-direction: column; gap: 16px; }

/* Shared controls use the same semantic palette and radii as the workspace. */
.btn, .cs-btn { display:inline-flex; align-items:center; justify-content:center; min-height:48px; padding:0 22px; border:1px solid transparent; border-radius:var(--radius-control); line-height:1.2; text-decoration:none; box-sizing:border-box; opacity:1; }
.btn-accent, .btn-accent:hover, .cs-btn--primary, .cs-btn--primary:hover { background:var(--keepPrimary); color:var(--on-button); }
.btn-accent:hover { filter:brightness(1.08); }
.btn-quiet, .btn-quiet:hover, .cs-btn--secondary, .cs-btn--secondary:hover { background:transparent; color:var(--ink); border-color:var(--line-strong); }
.btn-quiet:hover { background:var(--raise); }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* Header and navigation */
.site-header { background: rgba(13, 11, 17, 0.78); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.nav { padding-top: 16px; padding-bottom: 16px; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 28px; }
/* The one lockup: the C mark, the drawn name, and the pixel knight. */
.brand { display: flex; align-items: center; gap: 10px; min-height: 44px; text-decoration: none; color: var(--ink); margin-right: auto; }
.brand:hover { color: var(--ink); }
.brand .mark { width: 34px; height: 34px; flex: none; }
.brand .word { height: 28px; width: auto; aspect-ratio: 3944 / 724; display: block; }
.knight-px { width: 30px; height: 30px; flex: none; display: block; }
/* On the night ground the mark's offset goes near black and its face a step brighter. */
.m-off { fill: #0f1013; }
.m-face { fill: var(--markFace); }
.m-rim { fill: var(--markRim); }
.nav-links { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 24px; }
.nav-links a:not(.btn) { text-decoration: none; color: var(--ink); padding: 10px 0; }
.nav-links a:not(.btn):hover { color: var(--accent); }
.nav-links a[aria-current="page"]:not(.btn) { color: var(--accent); text-decoration: underline; text-underline-offset: 8px; }
.nav-links .btn, .cs-btn { min-height: 44px; padding: 0 18px; }
.btn[aria-current="page"] { box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px var(--accent); }
.menu { display: none; }

/* Panels and tables */
.panel, .cs-panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-panel); padding: 28px; display: flex; flex-direction: column; gap: 12px; }
.panel h2, .cs-panel h2 { overflow-wrap: anywhere; }
.panel.raised { background: var(--raise); }
.table-box { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius-panel); background: var(--surface); }
.table-box table { width: 100%; border-collapse: collapse; font-size: 17px; }
.table-box th { text-align: left; padding: 14px 20px; color: var(--muted); border-bottom: 1px solid var(--line); vertical-align: top; }
.table-box tbody th { color: var(--ink); white-space: nowrap; }
.table-box td { padding: 14px 20px; vertical-align: top; border-bottom: 1px solid var(--line); }
.table-box tr:last-child td { border-bottom: 0; }
.table-box td:first-child { font-weight: 600; }
.table-box .mono { font-weight: 500; }
/* Gateway comparison */
.versus { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius-panel); overflow: hidden; font-size: 17px; }
.versus div { background: var(--surface); padding: 14px 20px; }
.versus .vh-col { background: var(--raise); color: var(--muted); font-weight: 600; font-size: 16px; }
.versus .vh-col.us { color: var(--accent); }
/* Terminal blocks */
.term { background: var(--pixel-night); border: 1px solid var(--line); border-radius: var(--radius-panel); padding: 20px 24px; font-family: var(--mono); font-size: 15px; line-height: 1.8; overflow-x: auto; }
.term div { overflow-wrap: anywhere; }
.term .pr, .term .note { color: var(--muted); }
.nowrap { white-space: nowrap; }

/* The hero's request card: what the demo's gatehouse shows. */
.request { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-panel); padding: 24px; display: flex; flex-direction: column; gap: 14px; }
.request-head { display: flex; align-items: center; gap: 14px; }
.request-title { font-family: var(--display); font-size: 24px; line-height: 1.25; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; font-family: var(--mono); font-size: 14px; }
.chip, .cs-chip { padding: 4px 10px; border-radius: var(--radius-chip); background: var(--raise); border: 1px solid var(--line); }
.chip.off { color: var(--muted); text-decoration: line-through; }

/* Diagrams: inline SVG in the page's own colours, drawn by scripts/site_art.py
   with the cast members and the house icons. Nothing in a diagram moves. */
.diagram { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-panel); padding: 24px; }
.diagram svg { display: block; width: 100%; height: auto; }
.dg-tall { display: none !important; }
figcaption { font-size: 16px; color: var(--muted); }
.diagram figcaption { margin-top: 16px; }
.dg text { font-family: var(--text); fill: var(--ink); font-size: 15px; }
.dg .t-title { font-size: 17px; font-weight: 650; }
/* Phone cards are one row. The title has to fit beside the badge and the character.
   Flow characters are 64px tall, nearest neighbor, with the step number under them. */
.dg-tall .px { image-rendering: pixelated; shape-rendering: crispEdges; }
.dg-tall .t-title { font-size: 14px; }
.dg-tall .t-muted { font-size: 13px; }
.dg .t-muted { fill: var(--muted); font-size: 14px; }
.dg .t-accent { fill: var(--accent); font-weight: 650; }
.dg .box { fill: var(--raise); stroke: var(--line-strong); stroke-width: 1.5; }
.dg .zone { fill: none; stroke: var(--line-strong); stroke-width: 1.5; stroke-dasharray: 6 5; }
.dg .keep { fill: var(--pixel-night); stroke: var(--accent); stroke-width: 2; }
.dg .line { fill: none; stroke: var(--muted); stroke-width: 2; }
.dg .line.ok { stroke: var(--sky); }
.dg .line.no { stroke: var(--accent); stroke-dasharray: 5 5; }
.dg .arrow { fill: var(--muted); }
.dg .arrow.ok { fill: var(--sky); }
.dg .arrow.no { fill: var(--accent); }
.dg .num { fill: var(--bg); stroke: var(--line-strong); stroke-width: 1.5; }
.dg .num-t { font-family: var(--mono); font-size: 13px; text-anchor: middle; }
.dg .ctrl { fill: var(--bg); stroke: var(--sky); stroke-width: 1.5; }
.dg .ctrl-t { fill: var(--sky); font-size: 13px; font-weight: 600; }
.steps { list-style: none; padding: 0; counter-reset: step; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 12px 24px; }
.steps li { counter-increment: step; position: relative; padding-left: 48px; display: flex; flex-direction: column; gap: 4px; }
.steps li::before { content: counter(step); position: absolute; left: 0; top: -2px; width: 32px; height: 32px; border-radius: 50%; border: 1.5px solid var(--line-strong); display: grid; place-items: center; font-family: var(--mono); font-size: 14px; color: var(--ink); }
.steps p { color: var(--muted); font-size: 17px; }

/* The cast: pixel art on a night tile, and the services table. */
.px-defs { position: absolute; width: 0; height: 0; overflow: hidden; }
.cast-art { position: relative; background: var(--pixel-night); border-radius: var(--radius-control); display: flex; align-items: flex-end; justify-content: center; gap: 8px; padding: 12px; }
.cast-art svg, .cast-figure svg { display: block; max-width: 100%; height: auto; }
.cast-figure { display: block; }
.cast-hero { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 48px; align-items: center; }
.cast-hero .cast-art { padding: 24px; min-height: 280px; }
.cast-table td:first-child { width: 208px; }
.cast-table .cast-art { width: 80px; min-height: 72px; box-sizing: border-box; padding: 8px; flex-wrap: wrap; justify-content: flex-start; }
.cast-table .cast-art.wide { width: 208px; }
.cast-table [data-voice-art] { display: block; }
.cast-table .role { display: block; color: var(--muted); font-weight: 500; font-size: 15px; }
.cast-table tbody th { white-space: normal; text-align: left; font-size: 17px; color: var(--ink); padding: 14px 20px; border-bottom: 1px solid var(--line); vertical-align: top; }
.cast-table tbody th { width: 200px; }
/* The RAIDERS wordmark: the AI letters in red. */
.ai { color: #ff6b78; }
.envoy-name { white-space: nowrap; }
.envoy-mark { display: inline-block; width: 1em; height: 1em; margin-right: 0.25em; vertical-align: -0.14em; }
.envoy-mark svg { display: block; width: 1em; height: 1em; }
/* A speaking character's line, added by entrance/voices.js as a button in
   its row: a click plays the line. */
.bubble { display: inline-block; margin: 8px 0 0; padding: 6px 12px; border: 1px solid var(--line-strong); border-radius: var(--radius-control); background: var(--raise); color: var(--ink); font: 500 15px/1.3 var(--text); cursor: pointer; text-align: left; }
.bubble::before { content: "\201C"; }
.bubble::after { content: "\201D"; }
.bubble:hover { border-color: var(--accent); }
.bubble.speak { border-color: var(--accent); }
.cast-hero .bubble { position: absolute; top: 16px; left: 50%; translate: -50% 0; margin: 0; }
.cast-hero .cast-art:has(.bubble) { padding-top: 64px; }

/* The privacy policy: one panel of plain sections, at reading width. */
.legal { max-width: 820px; padding: 40px; gap: 36px; }
.legal section { display: flex; flex-direction: column; gap: 12px; }
.legal h2 { font-size: 28px; }
.legal ul { padding-left: 22px; display: flex; flex-direction: column; gap: 8px; }
.legal li::marker { color: var(--accent); }

/* Footer: the lockup, one list of links, the copyright line. */
.site-footer { border-top: 1px solid var(--line); background: rgba(13, 11, 17, 0.6); }
.foot { padding-top: 32px; padding-bottom: 32px; display: flex; flex-wrap: wrap; gap: 12px 32px; align-items: center; color: var(--muted); font-size: 15px; }
.foot-brand { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; text-decoration: none; color: var(--ink); }
.foot-brand .mark { width: 28px; height: 28px; }
.foot-brand .word { height: 22px; width: auto; aspect-ratio: 3944 / 724; display: block; }
.foot-brand .knight-px { width: 24px; height: 24px; }
.foot-links { margin-left: auto; display: flex; flex-wrap: wrap; gap: 0 24px; }
.foot-links a { display: inline-flex; align-items: center; min-height: 44px; text-decoration: none; color: var(--muted); }
.foot-links a:hover, .foot-links a[aria-current="page"] { color: var(--ink); }
.foot-links a[aria-current="page"] { text-decoration: underline; text-underline-offset: 6px; }
.foot-copy { flex-basis: 100%; font-size: 14px; }

/* Phones: one column. */
@media (max-width: 720px) {
  body { font-size: 17px; }
  .wrap { padding-left: 16px; padding-right: 16px; }
  .sec { padding: 48px 16px; gap: 20px; }
  .sec.band + .sec { padding-top: 48px; }
  .sec.band { padding-top: 40px; padding-bottom: 40px; }
  .page-hero { padding-top: 40px; padding-bottom: 32px; }
  .split, .cast-hero { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  .lead { font-size: 19px; }
  .panel, .diagram { padding: 18px; }
  /* A phone shows the one column version of a diagram that has one, and
     scrolls the others sideways at a size that stays legible. */
  .dg-wide:has(+ .dg-tall) { display: none !important; }
  .dg-tall { display: block !important; max-width: 400px; margin: 0 auto; }
  .diagram { overflow-x: auto; }
  .diagram svg:not(.dg-tall) { min-width: 760px; }
  .legal { padding: 22px; }
  .legal h2 { font-size: 24px; }
  .cta-row { flex-direction: column; }
  .cta-row .btn, .cs-btn { width: 100%; }
  .table-box table { font-size: 16px; }
  .table-box th, .table-box td, .cast-table tbody th { padding: 12px 14px; }
  .stack-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .stack-table tr, .stack-table td, .stack-table tbody th { display: block; width: auto !important; }
  .stack-table tr { padding: 12px 14px; border-bottom: 1px solid var(--line); }
  .stack-table tr:last-child { border-bottom: 0; }
  .stack-table td, .stack-table tbody th { padding: 4px 0; border: 0; }
  .versus { font-size: 15px; }
  .versus div { padding: 12px 14px; }
  .foot { flex-direction: column; align-items: stretch; gap: 8px; padding: 28px 16px; }
  .foot-links { margin: 8px 0 0; display: flex; flex-direction: column; align-items: stretch; gap: 0; }
  .foot-links a { border-top: 1px solid var(--line); }
}

/* Phones, and any screen under 500px tall such as a phone on its side: a
   sticky header with the brand and a menu button that opens a full screen
   menu. Focus moved backwards scrolls clear of the sticky header. */
@media (max-width: 720px), (max-height: 500px) {
  html { scroll-padding-top: 88px; }
  .site-header { position: sticky; top: 0; z-index: 2; }
  .nav { padding: 10px 16px; gap: 12px; flex-wrap: nowrap; }
  .brand { gap: 8px; }
  .brand .mark { width: 28px; height: 28px; }
  .brand .word { height: 23px; }
  .brand .knight-px { width: 24px; height: 24px; }
  .nav-links { display: none; }
  .menu { display: block; }
  .menu summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: center; width: 48px; height: 48px; box-sizing: border-box; border: 1px solid var(--line-strong); border-radius: var(--radius-control); color: var(--ink); position: relative; z-index: 4; background: var(--bg); }
  .menu summary::-webkit-details-marker { display: none; }
  .menu .ico-close, .menu[open] .ico-open, .menu .lbl-close, .menu[open] .lbl-open { display: none; }
  .menu[open] .ico-close, .menu[open] .lbl-close { display: inline; }
  /* The header blurs the ground, and that blur traps a fixed descendant inside
     the header bar, so the open state showed the X and none of the links.
     While the menu is open the header itself covers the viewport, with no
     blur, and the link list is positioned against that header. */
  .site-header:has(.menu[open]) { position: fixed; inset: 0; z-index: 40; height: 100dvh; overflow: hidden; background: var(--bg); -webkit-backdrop-filter: none; backdrop-filter: none; }
  .menu:not([open]) .menu-panel { display: none; }
  .menu-panel { background: var(--bg); display: flex; flex-direction: column; }
  .menu[open] .menu-panel { position: absolute; top: 72px; left: 0; right: 0; bottom: 0; overflow-y: auto; z-index: 2; }
  .menu-head { display: none; }
  .menu-nav { padding: 8px 16px 24px; display: flex; flex-direction: column; }
  .menu-nav a { display: flex; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 20px; line-height: 1.2; text-decoration: none; color: var(--ink); min-height: 48px; box-sizing: border-box; }
  .menu-nav a:hover, .menu-nav a[aria-current="page"]:not(.btn) { color: var(--accent); }
  .menu-nav a.btn, .cs-btn { margin-top: 16px; width: 100%; border-bottom: 0; color: var(--on-button); background-color: var(--button); opacity: 1; justify-content: center; }
  .menu-nav a.btn:hover { color: var(--on-button); background-color: var(--button); filter: brightness(1.08); }
  body:has(.menu[open]) { overflow: hidden; }
}
/* A phone on its side: the links stay in one column so each row is a full tap target. */
@media (max-height: 500px) {
  .menu-nav a { padding: 8px 0; font-size: 18px; }
}
.h-card { font-size: 28px; }
.dg .no-x { fill: none; stroke: var(--accent); stroke-width: 3; }
/* Diagram figures: the house icons take the accent, a tree snapshot lights one node. */
.dg .ico { color: var(--accent); }
.dg .mini { fill: var(--raise); stroke: var(--line-strong); stroke-width: 1; }
.dg .mini.lit { fill: var(--accent); stroke: var(--accent); }
.dg-mini { width: 148px; height: 40px; display: block; }
.dg-mini .line { stroke-width: 1.5; }
.diagram svg.dg-mini, td .dg-mini { min-width: 0; }

/* Round two: the hero scene, the phone, the roles, the threats, the principles. */
.hero { gap: 32px; }
.hero h1 { font-size: clamp(40px, 5.2vw, 68px); max-width: 1000px; }
.hero-art { background: var(--pixel-night); border: 1px solid var(--line); border-radius: var(--radius-panel); overflow: hidden; }
.hero-scene { display: block; width: 100%; height: auto; }
@media (prefers-reduced-motion: no-preference) {
  .hero-scene .cs-star { animation: hero-twinkle 2.4s step-end infinite; }
  .hero-banner { animation: hero-banner 0.8s step-end infinite; }
  .hero-torch { animation: hero-torch 0.5s step-end infinite; }
  .hero-late { animation-delay: -0.3s; }
}
/* The entrance bundle also supplies castle animation classes used by this art. */
@media (prefers-reduced-motion: reduce) {
  .hero-scene, .hero-scene * { animation: none !important; transition: none !important; }
}
@keyframes hero-twinkle { 0%, 100% { opacity: 1; } 50% { opacity: 0.25; } }
@keyframes hero-banner { 0%, 100% { transform: translateX(0); } 50% { transform: translateX(-10px); } }
@keyframes hero-torch { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-8px); } 50% { transform: translateX(-16px); } 75% { transform: translateX(-24px); } }
.with-icon { display: flex; align-items: center; gap: 10px; }
.ico-inline { color: var(--accent); flex: none; width: 24px; height: 24px; }
.chips { list-style: none; padding: 0; }
.layers { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.layers .scene { grid-column: 1 / -1; display: flex; flex-direction: column; gap: 10px; align-items: center; }
.layers .scene .cast-art { padding: 20px; width: 100%; box-sizing: border-box; }
.layers .scene svg { width: min(100%, 420px); height: auto; }
/* The phone: the demo's Gatehouse on a phone, the real screen in a phone frame. */
.phone { justify-self: center; width: min(100%, 320px); margin: 0; border-radius: 44px; background: #0f1013; padding: 12px; box-shadow: 0 0 0 1px var(--line-strong), 0 24px 48px rgba(0, 0, 0, 0.45); }
/* The cast's roles: portrait, name and product, two sentences, and where it stands in the tree. */
.roles { list-style: none; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.role { display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 20px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-panel); padding: 16px; }
.role-art { align-self: start; min-height: 120px; }
.role-art.wide { flex-wrap: wrap; gap: 6px; }
.role-art.wide svg { width: 48px; height: auto; }
.role-body { display: flex; flex-direction: column; gap: 8px; }
.role-body h3 { font-size: 21px; }
.role-product { display: flex; align-items: center; gap: 8px; color: var(--accent); font-weight: 600; font-size: 15px; }
.role-body .dg-mini { margin-top: 4px; }
/* The threats: the battle with each enemy numbered, and the list beside it. */
.threats { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 24px; align-items: start; }
.threats-art { position: relative; background: var(--pixel-night); border: 1px solid var(--line); border-radius: var(--radius-panel); overflow: hidden; }
.threats-art .hero-scene { display: block; width: 100%; height: auto; }
.threat-badge { position: absolute; width: 28px; height: 28px; margin: -14px 0 0 -14px; border-radius: 50%; background: var(--accent); color: var(--on-button); font: 700 14px/28px var(--mono); text-align: center; box-shadow: 0 0 0 3px var(--pixel-night); }
.threat-list { list-style: none; padding: 0; display: flex; flex-direction: column; gap: 14px; }
.threat-list li { display: grid; grid-template-columns: 32px minmax(0, 1fr); gap: 12px; }
.threat-list .num-t { width: 28px; height: 28px; border-radius: 50%; background: var(--accent); color: var(--on-button); font: 700 14px/28px var(--mono); text-align: center; }
.threat-list h3 { font-size: 19px; margin-bottom: 4px; }
.threat-list p { color: var(--muted); font-size: 16px; }
/* Security: the three principles, and the controls as two columns. */
.principles .panel h2 { font-size: 22px; }
.principles .bullets { color: var(--muted); font-size: 16px; }
.controls th[scope="row"] { display: grid; grid-template-columns: auto auto minmax(0, 1fr); align-items: center; column-gap: 10px; row-gap: 4px; width: 340px; white-space: normal; }
.controls th[scope="row"] .role { display: block; grid-column: 3; padding: 0; background: none; border: 0; color: var(--muted); font-weight: 500; font-size: 14px; }
.ctrl-mark { width: 24px; height: 24px; border-radius: 50%; border: 1.5px solid var(--sky); color: var(--sky); font: 600 12px/22px var(--mono); text-align: center; box-sizing: border-box; }
.controls .bullets { color: var(--muted); font-size: 16px; gap: 4px; }
/* Build your defenses: the features that compound. */
.features { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 16px; }
.feature .cast-art { min-height: 112px; }
.feature .bullets { color: var(--muted); font-size: 16px; }
@media (max-width: 720px) {
  .hero { gap: 20px; }
  .layers { grid-template-columns: minmax(0, 1fr); }
  .role { grid-template-columns: minmax(0, 1fr); }
  .role-art { min-height: 96px; }
  .threats { grid-template-columns: minmax(0, 1fr); }
  .controls th[scope="row"] { width: auto; }
}
/* The demo's real screens, taken by web/scripts/site-shots.mjs. */
.shots { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 16px; }
.shots.two { grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); }
.shot { display: flex; flex-direction: column; gap: 10px; }
.shot img, .shot-img { display: block; width: 100%; height: auto; border: 1px solid var(--line); border-radius: var(--radius-panel); background: var(--pixel-night); }
.shot figcaption { margin-top: 8px; }
.panel .shot-img { margin-bottom: 4px; }
.phone-shot { display: block; width: 100%; height: auto; border-radius: 34px; }
.phone figcaption { margin-top: 12px; text-align: center; }

/* The products' glass emblems beside headings, names and table rows. */
img.emblem { width: 40px; height: 40px; flex: none; display: inline-block; vertical-align: middle; border-radius: 50%; box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4); }
h2.with-icon img.emblem { width: 52px; height: 52px; }
.role-product img.emblem { width: 34px; height: 34px; }
th img.emblem { width: 34px; height: 34px; }

/* Learning progression, with the existing product emblems. */
.growth-hero { max-width: 46rem; color: var(--ink2); }
.growth-section > .lead { max-width: 52rem; }
.growth-path { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; list-style: none; padding: 0; margin: 32px 0; }
.growth-step { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; border-top: 3px solid var(--accent); min-width: 0; }
.growth-step:nth-child(2) { border-top-color: #c9a66b; }
.growth-step:nth-child(3) { border-top-color: #8eb9a7; }
.growth-rank { font-family: var(--mono); font-size: 12px; letter-spacing: .08em; color: var(--muted); }
.growth-step h3 { font-family: var(--serif); font-size: 28px; line-height: 1.15; }
.growth-step p { color: var(--ink2); }
.growth-takeaway { border-left: 3px solid var(--accent); padding: 12px 20px; margin-bottom: 20px; max-width: 52rem; }
@media (max-width: 720px) { .growth-path { grid-template-columns: minmax(0, 1fr); gap: 16px; } }

.growth-squires { display: flex; align-items: center; gap: 24px; margin: 24px 0; }
.growth-squires > .emblem { width: 80px; height: 80px; flex: 0 0 80px; }
.growth-squires h3 { font-family: var(--serif); font-size: 28px; margin-bottom: 8px; }
.growth-squires p { color: var(--ink2); max-width: 48rem; }
@media (max-width: 480px) { .growth-squires { align-items: flex-start; gap: 16px; } .growth-squires > .emblem { width: 48px; height: 48px; flex-basis: 48px; } }

/* Marketing proof uses fictional fixture records only. */
.proof-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(min(100%,280px),1fr)); gap:24px; }
.proof-shot { width:100%; height:auto; border:1px solid var(--line-strong); border-radius:var(--radius-panel); display:block; }
.proof-grid figure { display:grid; gap:12px; align-content:start; }
.proof-grid figcaption { color:var(--muted); font-size:16px; }
.room-list { display:grid; grid-template-columns:repeat(auto-fit,minmax(min(100%,260px),1fr)); gap:16px; padding:0; list-style:none; }
.room-list li { padding:20px; border:1px solid var(--line); border-radius:var(--radius-panel); background:var(--surface); }
.hero .cta-row { margin-top:0; }
.hero .entry-note { font-size:16px; color:var(--muted); }
.not-found { min-height:55vh; text-align:center; align-items:center; }
.not-found .knight-px { width:112px; height:112px; image-rendering:pixelated; }
@media (max-width:1100px) and (min-width:721px) { .nav-links { gap:4px 14px; } .nav { gap:12px; } }

.proof-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
.proof-grid .permission-proof { grid-column:1 / -1; grid-row:1; }
.proof-grid figure:not(.permission-proof) .proof-shot { max-width:390px; }
@media(max-width:600px) { .proof-grid { grid-template-columns:minmax(0,1fr); } }

/* Shared component roles use the canonical Graphite palette. */
.cs-btn--quiet {background:transparent;color:var(--muted);border-color:transparent}
.cs-btn--seal {background:var(--sealSoft);color:var(--seal);border-color:var(--seal)}
.cs-btn--danger {background:var(--deniedSoft);color:var(--denied);border-color:currentColor}
.cs-panel--raised {background:var(--raise)}
.cs-panel--inset {background:var(--bg)}
.cs-panel--gate,.cs-panel--request {border-color:var(--seal)}
.cs-chip--ok {color:var(--ok);background:var(--okSoft)}
.cs-chip--attention {color:var(--attention);background:var(--attentionSoft)}
.cs-chip--seal {color:var(--seal);background:var(--sealSoft)}
.cs-chip--denied {color:var(--denied);background:var(--deniedSoft)}
.cs-chip--muted {color:var(--muted);background:var(--raise)}
.home-product-proof {width:min(100%,320px);justify-self:center;margin:0}
.home-product-proof img {display:block;width:100%;height:auto;border:1px solid var(--line);border-radius:var(--radius-panel)}
.home-product-proof figcaption {font-size:.875rem;color:var(--muted);margin-top:12px}

.diagram picture,.diagram img {display:block;width:100%;height:auto}

/* Shared control and ledger polish. Marketing retains its existing art. */
.cs-btn--secondary,.btn-quiet,.btn-quiet:hover {border:1px solid var(--line-strong);border-radius:var(--radius-control);color:var(--ink);background:transparent}
.cs-btn--quiet {border-color:transparent;background:transparent;color:var(--muted)}
.cs-btn--quiet:hover {text-decoration:underline;text-underline-offset:4px}
:focus-visible {outline:3px solid var(--sky);outline-offset:3px}
.table-box {scroll-padding-top:48px}
.table-box thead th {position:sticky;top:0;background:var(--surface);z-index:1}
.table-box tbody tr:hover {background:color-mix(in srgb,var(--keepPrimary) 6%,var(--surface))}
.table-box :is(td,th) {font-variant-numeric:tabular-nums}
@media(prefers-reduced-motion:no-preference) {
 .btn {transition:transform var(--duration-fast) var(--ease-out),box-shadow var(--duration-fast) var(--ease-out),background-color var(--duration-fast) var(--ease-out)}
 .btn:active {transform:scale(.98)}
 .panel,.request {transition:transform var(--duration-fast) var(--ease-out),box-shadow var(--duration-fast) var(--ease-out)}
 .menu[open] .menu-panel {animation:cs-menu-enter var(--duration-med) var(--ease-out)}
}
@media(hover:hover) and (prefers-reduced-motion:no-preference) {.panel:hover,.request:hover {transform:translateY(-1px);box-shadow:var(--shadow-lift-sm)}}
@supports (color:oklch(50% .1 30)) {.btn-accent:hover,.cs-btn--primary:hover {background:color-mix(in oklch,var(--keepPrimary-oklch) 94%,white);color:var(--on-button);filter:none}}
@keyframes cs-menu-enter {from{opacity:0;transform:translateY(-8px)}to{opacity:1;transform:translateY(0)}}
@media(prefers-reduced-motion:reduce) {*,*::before,*::after{transition:none!important;scroll-behavior:auto!important}}

@media(min-width:721px) and (min-height:501px) {.table-box:not(.sl-table) {max-height:min(70dvh,48rem);overflow:auto}}
@media print {.table-box {max-height:none!important;overflow:visible!important}}

/* Stageshow-informed composition: quiet depth, readable hierarchy, short feedback. */
.home-context-proof {min-width:0;width:100%;align-self:center}
.site-header {box-shadow:0 1px 0 var(--edge-light)}
.hero h1,.page-hero h1 {letter-spacing:-.025em}
.sec>h2,.stack>h2 {letter-spacing:-.018em}
.panel,.cs-panel,.request,.table-box,.diagram {box-shadow:inset 0 1px 0 var(--edge-light)}
.sec.band {background:color-mix(in srgb,var(--surface) 65%,var(--ground))}
.btn-accent,.cs-btn--primary {box-shadow:inset 0 1px 0 rgba(255,255,255,.15),0 3px 8px rgba(0,0,0,.16)}
@media(prefers-reduced-motion:no-preference){
 .btn,.cs-btn {transition:background-color 120ms ease-out,transform 120ms ease-out,box-shadow 180ms var(--ease-settle)}
 .btn:active,.cs-btn:active {transform:translateY(1px)}
 .menu[open] .menu-panel {animation:cs-menu-enter var(--duration-enter) var(--ease-settle)}
}
