/* KernelBeam — design system v3 "Signal"
   Dark-first, terminal-grade panels, editorial serif display.
   Zero JS. Motion is limited to state and affordance: live-status pulse, hover on clickable elements, anchor smooth scroll. */

@font-face {
  font-family: "Newsreader";
  font-style: normal;
  font-weight: 300 800;
  font-display: swap;
  src: url("/assets/fonts/newsreader.woff2") format("woff2");
  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: 300 800;
  font-display: swap;
  src: url("/assets/fonts/newsreader-italic.woff2") format("woff2");
  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: "IBM Plex Mono";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/plexmono-400.woff2") format("woff2");
  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: "IBM Plex Mono";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/plexmono-500.woff2") format("woff2");
  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;
}

/* ---------- Tokens ---------- */

:root {
  color-scheme: dark;

  --paper: #0e0f11;
  --paper-2: #16171a;
  --panel: #151619;
  --panel-2: #1b1c20;
  --ink: #eceae4;
  --ink-2: #b3b1ab;
  --ink-3: #8e8c87;
  --rule: #26272b;
  --rule-2: #34363b;
  --beam: #e28c4c;
  --beam-2: #f2b077;
  --beam-text: #e9a066;
  --beam-dim: rgba(226, 140, 76, 0.16);
  --live: #5cc78a;

  --font-display: "Newsreader", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  --gutter: 20px;
  --measure: 68ch;
  --section: clamp(72px, 10vw, 136px);
  --radius: 10px;
  --radius-sm: 6px;
  --ease: 180ms cubic-bezier(0.2, 0.7, 0.2, 1);
  --ease-slow: 420ms cubic-bezier(0.2, 0.7, 0.2, 1);
  --shadow-panel: 0 1px 0 rgba(255, 255, 255, 0.03) inset, 0 24px 60px -30px rgba(0, 0, 0, 0.8);
}

@media (min-width: 640px) { :root { --gutter: 32px; } }
@media (min-width: 1200px) { :root { --gutter: 48px; } }

/* Legacy hook from v2: tokens are already dark, keep as no-op */
.band-ink { background: transparent; }

/* ---------- Base ---------- */

*, *::before, *::after { box-sizing: border-box; }

html {
  background: var(--paper);
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: 96px;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(1200px 600px at 80% -10%, rgba(226, 140, 76, 0.07), transparent 60%),
    var(--paper);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

h1 { font-size: clamp(40px, 6vw, 76px); line-height: 1.0; }
h2 { font-size: clamp(30px, 3.6vw, 46px); line-height: 1.06; }
h3 { font-size: 24px; line-height: 1.2; }

p { margin: 0; }
p + p { margin-top: 1em; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; height: auto; }
ul, ol, dl { margin: 0; padding: 0; }

:focus-visible {
  outline: 2px solid var(--beam);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

::selection { background: var(--beam); color: #0e0f11; }

.prose a, .doc-body a, .lead a, .card p a, .spec a {
  text-decoration: underline;
  text-decoration-color: var(--rule-2);
  text-underline-offset: 0.18em;
  text-decoration-thickness: 1px;
  transition: text-decoration-color var(--ease), color var(--ease);
}
.prose a:hover, .doc-body a:hover, .lead a:hover, .card p a:hover, .spec a:hover {
  color: var(--beam-2);
  text-decoration-color: var(--beam);
}

/* ---------- Utilities ---------- */

.container { width: min(1240px, 100% - 2 * var(--gutter)); margin-inline: auto; }

.mono, .kicker, .label, .badge {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  line-height: 1.4;
}

.kicker { display: flex; align-items: center; gap: 12px; color: var(--ink-3); }
.kicker .num { color: var(--beam-text); }
.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 9px;
  border: 1px solid var(--rule-2);
  border-radius: 999px;
  background: var(--panel-2);
  color: var(--ink-2);
  font-size: 11px;
}
.badge.live { border-color: rgba(92, 199, 138, 0.4); color: var(--live); }

.dot {
  position: relative;
  width: 7px; height: 7px;
  border-radius: 999px;
  background: var(--beam);
  color: var(--beam);
  flex: none;
}
.dot.live { background: var(--live); color: var(--live); }
/* Pulse only on a genuinely live state (app currently on the App Store) */
.dot.live::after {
  content: "";
  position: absolute; inset: -4px;
  border-radius: 999px;
  border: 1px solid currentColor;
  opacity: 0;
  animation: pulse 2.2s ease-out infinite;
}

.lead {
  max-width: 34em;
  color: var(--ink-2);
  font-size: clamp(17px, 1.5vw, 20px);
  line-height: 1.55;
}

.visually-hidden {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute; top: 8px; left: 8px; z-index: 100;
  padding: 10px 14px;
  background: var(--beam); color: #0e0f11;
  font-family: var(--font-mono); font-size: 13px;
  border-radius: var(--radius-sm);
  transform: translateY(-200%);
}
.skip-link:focus { transform: none; }

/* ---------- Buttons ---------- */

.btn {
  position: relative;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 44px; padding: 0 18px;
  border: 1px solid var(--rule-2);
  border-radius: var(--radius-sm);
  color: var(--ink);
  background: var(--panel-2);
  font-family: var(--font-mono); font-size: 13px; font-weight: 500;
  letter-spacing: 0.06em; text-transform: uppercase;
  transition: background-color var(--ease), border-color var(--ease), transform var(--ease), box-shadow var(--ease);
}
.btn:hover { border-color: var(--ink-3); background: #22242a; transform: translateY(-1px); }
.btn.primary {
  color: #0e0f11;
  border-color: transparent;
  background: linear-gradient(120deg, var(--beam-2), var(--beam) 55%, #c9702f);
  box-shadow: 0 0 0 1px rgba(226, 140, 76, 0.3), 0 10px 30px -12px rgba(226, 140, 76, 0.7);
}
.btn.primary:hover { box-shadow: 0 0 0 1px rgba(226, 140, 76, 0.5), 0 14px 36px -12px rgba(226, 140, 76, 0.9); }
.btn .arr { transition: transform var(--ease); }
.btn:hover .arr { transform: translateX(3px); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Masthead ---------- */

.masthead {
  position: sticky; top: 0; z-index: 50;
  border-bottom: 1px solid var(--rule);
  background: rgba(14, 15, 17, 0.72);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
}
.masthead-inner {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 8px 24px; min-height: 64px; padding: 10px 0;
}
.brand {
  display: inline-flex; align-items: center; gap: 12px;
  font-family: var(--font-display); font-size: 24px; font-weight: 500;
  letter-spacing: -0.01em; line-height: 1;
}
.brand-mark {
  display: inline-block; width: 11px; height: 11px;
  border: 1.5px solid var(--ink);
  background: linear-gradient(135deg, var(--beam) 50%, transparent 50%);
  box-shadow: 0 0 12px rgba(226, 140, 76, 0.5);
}
.site-nav ul { display: flex; flex-wrap: wrap; gap: 4px 6px; list-style: none; }
.site-nav a, .section-bar a {
  position: relative;
  display: inline-flex; align-items: center; min-height: 40px; padding: 0 10px;
  border-radius: var(--radius-sm);
  font-family: var(--font-mono); font-size: 12.5px; font-weight: 500;
  letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--ink-2);
  transition: color var(--ease), background-color var(--ease);
}
.site-nav a:hover, .section-bar a:hover { color: var(--ink); background: var(--panel-2); }
.site-nav a[aria-current="page"], .section-bar a[aria-current="page"] { color: var(--beam-2); background: var(--beam-dim); }

.section-bar { border-bottom: 1px solid var(--rule); background: var(--paper); }
.section-bar-inner {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 0 24px; min-height: 48px;
}
.crumb {
  display: inline-flex; align-items: center; gap: 10px; min-height: 44px;
  font-family: var(--font-mono); font-size: 12.5px; letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--ink-3);
}
.crumb a { color: var(--ink-3); }
.crumb strong { font-weight: 500; color: var(--ink); }
.section-bar ul { display: flex; flex-wrap: wrap; gap: 0 4px; list-style: none; }

/* ---------- Hero ---------- */

.hero {
  position: relative;
  overflow: hidden;
  padding: clamp(64px, 9vw, 128px) 0 clamp(56px, 7vw, 96px);
  border-bottom: 1px solid var(--rule);
}
.hero::before {
  content: "";
  position: absolute; inset: 0;
  background-image:
    linear-gradient(var(--rule) 1px, transparent 1px),
    linear-gradient(90deg, var(--rule) 1px, transparent 1px);
  background-size: 88px 88px;
  background-position: center top;
  opacity: 0.6;
  -webkit-mask-image: radial-gradient(120% 90% at 50% 0%, #000 30%, transparent 80%);
  mask-image: radial-gradient(120% 90% at 50% 0%, #000 30%, transparent 80%);
  pointer-events: none;
}
.hero .container { position: relative; }
.hero .kicker { margin-bottom: 26px; }
.hero h1 { max-width: 13em; }
.hero .lead { margin-top: 22px; }
.hero .actions { margin-top: 34px; }
h1 .accent, h2 .accent {
  font-style: italic; font-weight: 300;
  background: linear-gradient(120deg, var(--beam-2), var(--beam));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

.hero-grid { display: grid; gap: 48px; align-items: center; }
@media (min-width: 1024px) {
  .hero-grid { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 64px; }
}
.hero.home h1 { font-size: clamp(46px, 7.2vw, 104px); line-height: 0.98; max-width: 10em; }

/* Console panel (hero right) */
.console {
  position: relative;
  border: 1px solid var(--rule-2);
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  box-shadow: var(--shadow-panel), 0 0 80px -30px rgba(226, 140, 76, 0.35);
  font-family: var(--font-mono);
  font-size: 12.5px;
  overflow: hidden;
}
.console::before {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.05), transparent 40%);
  pointer-events: none;
}
.console-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--rule);
  color: var(--ink-3); letter-spacing: 0.06em; text-transform: uppercase; font-size: 11px;
}
.console-bar .dots { display: flex; gap: 6px; }
.console-bar .dots i { width: 9px; height: 9px; border-radius: 999px; background: var(--rule-2); }
.console-rows { list-style: none; padding: 6px 0; }
.console-rows li {
  display: grid; grid-template-columns: 130px minmax(0, 1fr) auto;
  gap: 12px; align-items: center;
  padding: 10px 14px;
  border-bottom: 1px solid var(--rule);
}
.console-rows li:last-child { border-bottom: 0; }
.console-rows .k { color: var(--ink-3); letter-spacing: 0.06em; text-transform: uppercase; font-size: 11px; }
.console-rows .v { color: var(--ink); overflow-wrap: anywhere; }
.console-rows .s { display: inline-flex; align-items: center; gap: 8px; color: var(--ink-3); font-size: 11px; letter-spacing: 0.06em; text-transform: uppercase; }
.console-rows .s .dot { width: 6px; height: 6px; }
@media (max-width: 480px) {
  .console-rows li { grid-template-columns: 96px minmax(0, 1fr); }
  .console-rows .s { display: none; }
}

/* ---------- Sections ---------- */

.section { position: relative; padding: var(--section) 0; border-bottom: 1px solid var(--rule); }
.section:last-of-type { border-bottom: 0; }
.section-head { position: relative; isolation: isolate; display: grid; gap: 20px 48px; margin-bottom: clamp(32px, 4.5vw, 56px); }
.section-head .kicker { margin-bottom: 18px; }
.section-head p { max-width: 34em; color: var(--ink-2); }
@media (min-width: 960px) {
  .section-head { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: end; }
}
.section-head[data-num]::before {
  content: attr(data-num);
  position: absolute; right: -0.04em; top: -0.5em; z-index: -1;
  font-family: var(--font-display); font-size: clamp(120px, 16vw, 220px); font-weight: 300;
  line-height: 1; letter-spacing: -0.05em;
  color: transparent;
  -webkit-text-stroke: 1px var(--rule-2);
  pointer-events: none; user-select: none;
}

/* ---------- Cards ---------- */

.cards { display: grid; gap: 16px; list-style: none; }
.cards.two { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.cards.three { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.cards.four { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }

.card {
  position: relative;
  display: flex; flex-direction: column; gap: 14px;
  padding: 22px;
  border: 1px solid var(--rule-2);
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  box-shadow: var(--shadow-panel);
  transition: transform var(--ease-slow), border-color var(--ease), box-shadow var(--ease-slow);
  overflow: hidden;
}
.card::before {
  content: "";
  position: absolute; inset: 0;
  background: radial-gradient(600px 200px at 20% -20%, rgba(226, 140, 76, 0.16), transparent 60%);
  opacity: 0; transition: opacity var(--ease-slow);
  pointer-events: none;
}
a.card:hover { transform: translateY(-3px); border-color: rgba(226, 140, 76, 0.45); box-shadow: var(--shadow-panel), 0 30px 60px -30px rgba(226, 140, 76, 0.35); }
a.card:hover::before { opacity: 1; }
.card > * { position: relative; }
.card .top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.card h3 { font-size: 26px; }
.card p { color: var(--ink-2); font-size: 15px; line-height: 1.55; }
.card .meta { display: flex; flex-wrap: wrap; gap: 6px 14px; font-family: var(--font-mono); font-size: 11.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); }
.card .price-line { margin-top: auto; padding-top: 14px; border-top: 1px solid var(--rule); display: flex; align-items: baseline; justify-content: space-between; gap: 12px; font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); }
.card .price-line strong { font-family: var(--font-display); font-size: 24px; font-weight: 400; letter-spacing: -0.01em; text-transform: none; color: var(--ink); }
.card .go { display: inline-flex; align-items: center; gap: 8px; color: var(--beam-2); font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; }
.card .go .arr { transition: transform var(--ease); }
a.card:hover .go .arr { transform: translateX(4px); }
a.card { color: inherit; }
.card .icon { width: 56px; height: 56px; border-radius: 14px; box-shadow: 0 8px 24px -8px rgba(0, 0, 0, 0.8); }

/* Pricing cards */
.pricing { display: grid; gap: 16px; list-style: none; }
@media (min-width: 900px) { .pricing { grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: stretch; } }
.pricing .card { padding: 26px; gap: 18px; }
.pricing .amount { display: flex; align-items: baseline; gap: 8px; font-family: var(--font-display); font-size: clamp(38px, 3.6vw, 52px); line-height: 1; letter-spacing: -0.025em; }
.pricing .amount small { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); }
.pricing .sub { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); }
.pricing ul.list { list-style: none; display: grid; gap: 10px; }
.pricing ul.list li { display: grid; grid-template-columns: 14px minmax(0, 1fr); gap: 10px; color: var(--ink-2); font-size: 14.5px; line-height: 1.5; }
.pricing ul.list li::before { content: "▸"; color: var(--beam); font-family: var(--font-mono); line-height: 1.5; }
.pricing .actions { margin-top: auto; }
.pricing .btn { width: 100%; }

/* Numbered statements */
.statements { display: grid; gap: 16px; list-style: none; }
@media (min-width: 900px) { .statements { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.statements li { padding: 22px; border: 1px solid var(--rule-2); border-radius: var(--radius); background: var(--panel); }
.statements .num { display: block; margin-bottom: 16px; font-family: var(--font-display); font-size: 30px; font-weight: 300; color: var(--beam-text); }
.statements h3 { margin-bottom: 10px; font-size: 22px; }
.statements p { color: var(--ink-2); font-size: 15px; }

/* Definition rows */
.defs { border-top: 1px solid var(--rule-2); }
.defs > div { display: grid; gap: 8px 48px; padding: 22px 0; border-bottom: 1px solid var(--rule); }
.defs dt { font-family: var(--font-display); font-size: 24px; line-height: 1.2; }
.defs dd { margin: 0; max-width: 40em; color: var(--ink-2); }
@media (min-width: 768px) { .defs > div { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); } }

/* Directory */
.directory { display: grid; gap: 16px; list-style: none; }
.directory-row {
  display: grid; grid-template-columns: 56px minmax(0, 1fr); gap: 16px 20px;
  padding: 22px;
  border: 1px solid var(--rule-2); border-radius: var(--radius);
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  box-shadow: var(--shadow-panel);
}
.directory-row .icon { width: 56px; height: 56px; border-radius: 14px; }
.directory-row .meta { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-bottom: 8px; font-family: var(--font-mono); font-size: 11.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); }
.directory-row .status { display: inline-flex; align-items: center; gap: 8px; color: var(--live); }
.directory-row h3 { font-size: 28px; }
.directory-row h3 a:hover { color: var(--beam-2); }
.directory-row .desc { max-width: 44em; margin-top: 6px; color: var(--ink-2); font-size: 15px; }
.directory-row .links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; list-style: none; grid-column: 1 / -1; }
.directory-row .links a {
  display: inline-flex; align-items: center; min-height: 36px; padding: 0 12px;
  border: 1px solid var(--rule-2); border-radius: var(--radius-sm);
  font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--ink-2);
  transition: color var(--ease), border-color var(--ease), background-color var(--ease);
}
.directory-row .links a:hover { color: var(--ink); border-color: var(--ink-3); background: var(--panel-2); }
@media (min-width: 768px) {
  .directory-row { grid-template-columns: 64px minmax(0, 1fr); }
  .directory-row .icon { width: 64px; height: 64px; }
  .directory-row .links { grid-column: 2; }
}
@media (min-width: 960px) {
  .directory-row { grid-template-columns: 72px minmax(0, 1fr) auto; align-items: start; gap: 0 32px; }
  .directory-row .icon { width: 72px; height: 72px; }
  .directory-row .links { grid-column: 3; flex-direction: column; margin-top: 0; }
}

/* Spec sheet */
.spec { border: 1px solid var(--rule-2); border-radius: var(--radius); background: var(--panel); overflow: hidden; }
.spec > div { display: grid; gap: 6px 32px; padding: 16px 20px; border-bottom: 1px solid var(--rule); }
.spec > div:last-child { border-bottom: 0; }
.spec dt { font-family: var(--font-mono); font-size: 11.5px; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); padding-top: 4px; }
.spec dd { margin: 0; color: var(--ink); font-size: 15px; }
@media (min-width: 768px) { .spec > div { grid-template-columns: 180px minmax(0, 1fr); } }

/* Public KernelBeam legal pages */
.legal-copy { width: min(78ch, calc(100% - 2 * var(--gutter))); margin: 0 auto; padding: clamp(42px, 7vw, 88px) 0 clamp(72px, 10vw, 128px); }
.legal-identity { display: flex; align-items: center; gap: 16px; margin-bottom: 30px; }
.legal-identity img { display: block; width: 64px; height: 64px; border: 1px solid var(--rule-2); border-radius: 14px; box-shadow: 0 8px 24px -8px rgba(0,0,0,.8); }
.legal-identity .kicker { margin: 0 0 4px; }
.legal-identity strong { font-family: var(--font-display); font-size: 27px; font-weight: 500; }
.legal-copy h1 { margin: 0 0 18px; font-family: var(--font-display); font-size: clamp(42px, 7vw, 68px); font-weight: 400; line-height: 1; letter-spacing: -.025em; }
.legal-copy h2 { margin: 42px 0 12px; font-family: var(--font-display); font-size: 29px; font-weight: 450; }
.legal-copy p, .legal-copy li { color: var(--ink-2); font-size: 16px; line-height: 1.75; }
.legal-copy p { margin: 14px 0; }
.legal-copy ul { padding-left: 24px; }
.legal-copy li { margin: 9px 0; }
.legal-copy a { color: var(--beam-2); text-decoration-thickness: 1px; text-underline-offset: 4px; }
.legal-updated { margin-top: 38px !important; color: var(--ink-3) !important; font-family: var(--font-mono); font-size: 12px !important; letter-spacing: .04em; }
.legal-page-nav { display: flex; flex-wrap: wrap; gap: 12px 22px; margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--rule); font-family: var(--font-mono); font-size: 12px; }

.split { display: grid; gap: 40px 64px; }
.split .kicker { margin-bottom: 16px; }
.split h2 { margin-bottom: 14px; }
.split p { color: var(--ink-2); max-width: 34em; }
@media (min-width: 960px) {
  .split { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); align-items: start; }
  .split.wide-visual { grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); }
}

/* Price block (inline) */
.price { margin-top: 28px; padding: 22px; border: 1px solid var(--rule-2); border-radius: var(--radius); background: var(--panel); }
.price .amount { display: block; font-family: var(--font-display); font-size: clamp(40px, 4.6vw, 60px); line-height: 1; letter-spacing: -0.025em; }
.price .amount small { font-size: 0.4em; color: var(--ink-3); margin-left: 0.4em; }
.price .terms { display: flex; flex-wrap: wrap; gap: 6px 20px; margin-top: 12px; list-style: none; font-family: var(--font-mono); font-size: 11.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); }

/* Schematic */
.schematic { border: 1px solid var(--rule-2); border-radius: var(--radius); background: var(--panel); padding: 14px; box-shadow: var(--shadow-panel); }
.schematic-window { border: 1px solid var(--rule); border-radius: var(--radius-sm); background: var(--paper); overflow: hidden; }
.schematic-titlebar { display: flex; justify-content: space-between; gap: 16px; padding: 10px 14px; border-bottom: 1px solid var(--rule); font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); }
.schematic-body { display: grid; }
.schematic-side { padding: 12px 14px; border-bottom: 1px solid var(--rule); font-family: var(--font-mono); font-size: 12px; color: var(--ink-3); }
.schematic-side ul { display: flex; flex-wrap: wrap; gap: 4px 16px; list-style: none; }
.schematic-side li[aria-current] { color: var(--ink); }
.schematic-side li[aria-current]::before { content: "\25A0\00a0"; color: var(--beam); }
.schematic-rows { list-style: none; }
.schematic-rows li { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 10px 14px; border-bottom: 1px solid var(--rule); }
.schematic-rows li:last-child { border-bottom: 0; }
.schematic-rows li > span:not(.glyph):not(.state) { min-width: 0; overflow-wrap: anywhere; }
.schematic-rows .glyph { display: grid; place-items: center; width: 30px; height: 30px; border: 1px solid var(--rule-2); border-radius: 6px; font-family: var(--font-mono); font-size: 12px; color: var(--ink-2); }
.schematic-rows strong { display: block; font-weight: 500; font-size: 14px; line-height: 1.3; }
.schematic-rows span.sub { display: block; color: var(--ink-3); font-size: 12.5px; line-height: 1.35; }
.schematic-rows .state { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); padding: 4px 8px; border: 1px solid var(--rule-2); border-radius: 999px; }
.schematic-rows li.protected .state { color: var(--beam-2); border-color: rgba(226, 140, 76, 0.5); background: var(--beam-dim); }
.schematic-search { margin: 12px 14px 0; padding: 9px 12px; border: 1px solid var(--rule-2); border-radius: var(--radius-sm); font-family: var(--font-mono); font-size: 12px; color: var(--ink-3); }
@media (min-width: 768px) {
  .schematic-body.with-side { grid-template-columns: 170px minmax(0, 1fr); }
  .schematic-body.with-side .schematic-side { border-bottom: 0; border-right: 1px solid var(--rule); }
  .schematic-body.with-side .schematic-side ul { flex-direction: column; gap: 10px; }
}
@media (max-width: 480px) {
  .schematic-rows li { grid-template-columns: 30px minmax(0, 1fr); }
  .schematic-rows .state { display: none; }
}

/* Link list */
.linklist { display: grid; gap: 12px; list-style: none; }
.linklist a {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px 24px; align-items: center;
  padding: 20px 22px;
  border: 1px solid var(--rule-2); border-radius: var(--radius); background: var(--panel);
  transition: transform var(--ease-slow), border-color var(--ease), background-color var(--ease);
}
.linklist a:hover { transform: translateY(-2px); border-color: rgba(226, 140, 76, 0.45); background: var(--panel-2); }
.linklist h3 { font-size: 24px; }
.linklist p { grid-column: 1; margin-top: 4px; max-width: 40em; color: var(--ink-2); font-size: 15px; }
.linklist .arrow { grid-row: 1 / span 2; grid-column: 2; font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--beam-2); }

/* ---------- Documents ---------- */

.doc-head { padding: clamp(48px, 6vw, 88px) 0 clamp(32px, 4vw, 48px); border-bottom: 1px solid var(--rule); }
.doc-head .kicker { margin-bottom: 22px; }
.doc-head h1 { font-size: clamp(34px, 4.4vw, 56px); max-width: 16em; }
.doc-head .lead { margin-top: 18px; font-size: 16px; }
.doc { display: grid; gap: 40px 64px; padding: clamp(40px, 5vw, 72px) 0 var(--section); }
.doc-toc { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.04em; }
.doc-toc .label { display: block; margin-bottom: 12px; color: var(--ink-3); }
.doc-toc ol { list-style: none; border: 1px solid var(--rule-2); border-radius: var(--radius); background: var(--panel); overflow: hidden; }
.doc-toc li { border-bottom: 1px solid var(--rule); }
.doc-toc li:last-child { border-bottom: 0; }
.doc-toc a { display: flex; align-items: center; min-height: 40px; padding: 6px 14px; color: var(--ink-2); line-height: 1.35; transition: color var(--ease), background-color var(--ease); }
.doc-toc a:hover { color: var(--beam-2); background: var(--panel-2); }
.doc-body { max-width: var(--measure); }
.doc-body h2 { margin: 44px 0 14px; font-size: 26px; scroll-margin-top: 96px; }
.doc-body h2:first-child { margin-top: 0; }
.doc-body p, .doc-body li { color: var(--ink-2); }
.doc-body ul { padding-left: 20px; }
.doc-body li + li { margin-top: 8px; }
.doc-body .notice { margin: 24px 0; padding: 16px 18px; border: 1px solid rgba(226, 140, 76, 0.4); border-left-width: 3px; border-radius: var(--radius-sm); background: var(--beam-dim); color: var(--ink-2); }
.doc-body .lang-block + .lang-block { margin-top: 72px; padding-top: 48px; border-top: 1px solid var(--rule-2); }
.doc-body .lang-block h1 { font-size: clamp(30px, 3.6vw, 44px); margin-bottom: 8px; scroll-margin-top: 96px; }
.doc-body .lang-block .lead { margin-bottom: 8px; }
.doc-body .lang-block .kicker { margin-bottom: 18px; }
.doc-body .lang-block h2 { margin-top: 36px; }
.doc-body [lang="zh-Hans"] h1, .doc-body [lang="zh-Hans"] h2,
.doc-body [lang="ja"] h1, .doc-body [lang="ja"] h2,
.doc-body [lang="vi"] h1, .doc-body [lang="vi"] h2 { font-family: var(--font-display), "PingFang SC", "Hiragino Sans", "Noto Serif CJK SC", serif; }
@media (min-width: 960px) {
  .doc { grid-template-columns: minmax(0, 3fr) minmax(0, 9fr); }
  .doc-toc { position: sticky; top: 88px; align-self: start; }
}

/* ---------- Contact strip ---------- */

.contact-strip {
  display: grid; gap: 24px 48px;
  padding: clamp(28px, 4vw, 48px);
  border: 1px solid var(--rule-2); border-radius: var(--radius);
  background:
    radial-gradient(600px 300px at 0% 0%, rgba(226, 140, 76, 0.14), transparent 60%),
    linear-gradient(180deg, var(--panel-2), var(--panel));
  box-shadow: var(--shadow-panel);
}
.contact-strip .email { font-family: var(--font-display); font-size: clamp(21px, 6.4vw, 40px); line-height: 1.1; word-break: break-word; transition: color var(--ease); }
.contact-strip .email:hover { color: var(--beam-2); }
.contact-strip p { max-width: 34em; color: var(--ink-2); }
@media (min-width: 960px) { .contact-strip { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: center; } }

/* ---------- Footer ---------- */

.footer { border-top: 1px solid var(--rule); padding: 56px 0 64px; background: linear-gradient(180deg, transparent, rgba(226, 140, 76, 0.04)); }
.footer-inner { display: grid; gap: 24px 48px; font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.04em; color: var(--ink-3); }
.footer-brand { display: flex; flex-direction: column; gap: 12px; }
.footer-brand .brand { font-size: clamp(32px, 4vw, 44px); }
.footer-brand .brand .brand-mark { width: 14px; height: 14px; }
.footer nav ul { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; }
.footer nav a { display: inline-flex; align-items: center; min-height: 36px; padding: 0 10px; border-radius: var(--radius-sm); color: var(--ink-2); text-transform: uppercase; letter-spacing: 0.06em; transition: color var(--ease), background-color var(--ease); }
.footer nav a:hover { color: var(--ink); background: var(--panel-2); }
@media (min-width: 960px) {
  .footer-inner { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); align-items: start; }
  .footer nav ul { justify-content: flex-end; }
}

/* ---------- Keyframes ---------- */

@keyframes pulse { 0% { opacity: 0.8; transform: scale(0.6); } 100% { opacity: 0; transform: scale(1.9); } }

/* ---------- Motion off ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
    .dot::after { display: none; }
}
