/* ncrptz Inn: ledger paper and Benin bronze.
   One bold moment (the hero wordmark); everything else quiet, left-aligned, tabular. */

@font-face {
  font-family: "Anybody";
  src: url("../fonts/anybody.woff2") format("woff2-variations"), url("../fonts/anybody.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 50% 150%;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Atkinson Next";
  src: url("../fonts/atkinson-next.woff2") format("woff2-variations"), url("../fonts/atkinson-next.woff2") format("woff2");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Atkinson Next";
  src: url("../fonts/atkinson-next-italic.woff2") format("woff2-variations"), url("../fonts/atkinson-next-italic.woff2") format("woff2");
  font-weight: 200 800;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Atkinson Mono";
  src: url("../fonts/atkinson-mono.woff2") format("woff2-variations"), url("../fonts/atkinson-mono.woff2") format("woff2");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}

:root {
  --paper: #EEF2EC;
  --paper-2: #E3EAE3;
  --paper-3: #F7F9F5;
  --ink: #10302A;
  --ink-2: #3D5A53;
  --rule: #B7CBC3;
  --rule-2: #8FAAA1;
  --margin: #C4422F;
  --bronze: #A06A1F;
  --bronze-ink: #7A4F12;
  --verdigris: #1E7A5C;
  --on-ink: #EEF2EC;
  --on-bronze: #FFF8EC;
  --shadow: 0 24px 60px rgba(16, 48, 42, .22), 0 2px 6px rgba(16, 48, 42, .12);

  --display: "Anybody", "Arial Narrow", "Helvetica Neue", Arial, sans-serif;
  --body: "Atkinson Next", "Atkinson Hyperlegible", "Segoe UI", system-ui, -apple-system, sans-serif;
  --mono: "Atkinson Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;

  --s--2: .78rem;
  --s--1: .875rem;
  --s-0: 1.0625rem;
  --s-1: 1.33rem;
  --s-2: 1.66rem;
  --s-3: 2.07rem;
  --s-4: 2.6rem;

  --frame: 92rem;
  --gutter: clamp(16px, 3vw, 44px);
  --mw: 9.5rem;
  --mpad: 1.15rem;
  --cpad: 1.9rem;
  --rule-w: 4px;
  --radius: 2px;
  --logo-sage: #A8C1B3;
  --logo-slate: #6C6D71;
  --logo-blue: #45658C;
  --logo-grey: #6C6D71;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #0F2420;
    --paper-2: #15302A;
    --paper-3: #122a25;
    --ink: #E6EEE8;
    --ink-2: #A9BFB7;
    --rule: #2C4A43;
    --rule-2: #3f6058;
    --margin: #E06A52;
    --bronze: #D9A350;
    --bronze-ink: #E8B865;
    --verdigris: #55C79B;
    --on-ink: #0F2420;
    --on-bronze: #1a1206;
    --shadow: 0 24px 60px rgba(0, 0, 0, .5), 0 2px 6px rgba(0, 0, 0, .35);
    --logo-sage: #A8C1B3;
    --logo-slate: #7F8287;
    --logo-blue: #A7C0DE;
    --logo-grey: #A9B6B1;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --logo-sage: #A8C1B3;
  --logo-slate: #7F8287;
  --logo-blue: #A7C0DE;
  --logo-grey: #A9B6B1;
  --paper: #0F2420;
  --paper-2: #15302A;
  --paper-3: #122a25;
  --ink: #E6EEE8;
  --ink-2: #A9BFB7;
  --rule: #2C4A43;
  --rule-2: #3f6058;
  --margin: #E06A52;
  --bronze: #D9A350;
  --bronze-ink: #E8B865;
  --verdigris: #55C79B;
  --on-ink: #0F2420;
  --on-bronze: #1a1206;
  --shadow: 0 24px 60px rgba(0, 0, 0, .5), 0 2px 6px rgba(0, 0, 0, .35);
  color-scheme: dark;
}

@media (prefers-contrast: more) {
  :root { --rule: var(--ink-2); --rule-2: var(--ink); --ink-2: var(--ink); }
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: 5.5rem; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  font-size: var(--s-0);
  line-height: 1.55;
  font-weight: 400;
  font-feature-settings: "kern", "liga";
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: .2em; }
a:hover { text-decoration-color: var(--bronze); }
p { margin: 0 0 1em; }
h1, h2, h3, h4 { margin: 0; font-weight: 700; }
ul, ol { margin: 0; padding: 0; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--bronze); outline-offset: 3px; border-radius: 1px; }
::selection { background: var(--bronze); color: var(--on-bronze); }
.mono { font-family: var(--mono); font-feature-settings: "zero" 1; letter-spacing: -.01em; }
.wrap { overflow-wrap: anywhere; word-break: break-all; }
.nowrap { white-space: nowrap; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.small { font-size: var(--s--1); color: var(--ink-2); }
.narrow { max-width: 62ch; }
.empty { color: var(--ink-2); }
.note { color: var(--ink-2); }
.icon { flex: none; vertical-align: -.18em; }
kbd, .kbd { font-family: var(--mono); font-size: .72rem; line-height: 1; padding: .22rem .38rem; border: 1px solid var(--rule-2); border-bottom-width: 2px; border-radius: 3px; color: var(--ink-2); background: var(--paper-3); white-space: nowrap; }

.skip { position: absolute; left: 1rem; top: -4rem; z-index: 100; background: var(--ink); color: var(--paper); padding: .6rem 1rem; text-decoration: none; }
.skip:focus { top: 1rem; }

/* ---------- the sheet and its ledger margin ---------- */
.sheet {
  position: relative;
  max-width: var(--frame);
  margin: 0 auto;
  padding: 0 var(--gutter);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.sheet::before {
  content: "";
  position: absolute;
  top: 0; bottom: 0;
  left: calc(var(--gutter) + var(--mw));
  width: var(--rule-w);
  border-left: 1px solid var(--margin);
  border-right: 1px solid var(--margin);
  opacity: .78;
  pointer-events: none;
  z-index: 45;
}
main { flex: 1; outline: none; }

.row {
  display: grid;
  grid-template-columns: var(--mw) minmax(0, 1fr);
}
.m {
  padding-right: var(--mpad);
  text-align: right;
  font-size: var(--s--1);
  color: var(--ink-2);
  line-height: 1.4;
  min-width: 0;
}
.c { padding-left: calc(var(--rule-w) + var(--cpad)); min-width: 0; }
.m-note { display: block; font-variant-numeric: tabular-nums; }
.m-note + .m-note { margin-top: .2rem; }
.m-note.ok { color: var(--verdigris); }
.m-note.bad { color: var(--margin); }

.block { padding-block: clamp(3rem, 6vw, 5rem); }
.block-tight { padding-block: clamp(2rem, 4vw, 3rem); }
.page-head { padding-top: clamp(3rem, 8vw, 6rem); padding-bottom: clamp(1.5rem, 3vw, 2.5rem); }
.page-head .m { padding-top: .9rem; }

/* ---------- type ---------- */
.h1 {
  font-family: var(--display);
  font-size: clamp(2.6rem, 6.2vw, 5.2rem);
  font-stretch: 72%;
  font-weight: 780;
  line-height: .96;
  letter-spacing: -.012em;
  margin-bottom: 1.25rem;
  max-width: 22ch;
  text-wrap: balance;
}
.h2 {
  font-family: var(--display);
  font-size: clamp(1.9rem, 3.7vw, 2.9rem);
  font-stretch: 74%;
  font-weight: 740;
  line-height: 1;
  letter-spacing: -.008em;
  margin-bottom: 1.4rem;
  text-wrap: balance;
}
.h3 {
  font-family: var(--display);
  font-size: var(--s-2);
  font-stretch: 80%;
  font-weight: 700;
  line-height: 1.08;
  margin-bottom: .8rem;
}
.h-small {
  font-family: var(--display);
  font-size: var(--s-1);
  font-stretch: 84%;
  font-weight: 680;
  line-height: 1.15;
  margin-bottom: .5rem;
}
.lead { font-size: var(--s-1); line-height: 1.45; max-width: 52ch; color: var(--ink); text-wrap: pretty; }
.lead.narrow { max-width: 52ch; }
.crumb { margin-bottom: .6rem; font-size: var(--s--1); }
.crumb a { color: var(--ink-2); text-decoration: none; }
.crumb a::before { content: "\2190\00a0"; }
.crumb a:hover { color: var(--ink); }
.head-with-link { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.head-with-link .h2, .head-with-link .h3 { margin-bottom: .6rem; }

.prose { max-width: 66ch; font-size: 1.09rem; line-height: 1.62; }
.prose h2 { font-family: var(--display); font-size: var(--s-2); font-stretch: 78%; font-weight: 720; line-height: 1.1; margin: 2.2em 0 .6em; }
.prose h3, .prose h4 { font-family: var(--display); font-size: var(--s-1); font-stretch: 82%; font-weight: 700; margin: 1.8em 0 .5em; }
.prose > :first-child { margin-top: 0; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1.1em; }
.prose li { margin-bottom: .45em; }
.prose li::marker { color: var(--bronze); }
.prose blockquote { margin: 1.5em 0; padding-left: 1.2em; border-left: 3px solid var(--bronze); color: var(--ink-2); }
.prose code { font-family: var(--mono); font-size: .92em; background: var(--paper-2); padding: .08em .3em; border-radius: 2px; }
.prose pre { overflow-x: auto; background: var(--paper-2); padding: 1rem; border-left: 3px solid var(--rule-2); }
.prose pre code { background: none; padding: 0; }
.prose img { margin: 1.5em 0; }
.prose a { color: var(--bronze-ink); font-weight: 600; }
.prose hr { border: 0; border-top: 3px double var(--rule); margin: 2.5em 0; }

/* ---------- buttons & links ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .55rem;
  padding: .82rem 1.3rem;
  background: var(--ink); color: var(--paper);
  border: 1px solid var(--ink);
  border-radius: var(--radius);
  font-family: var(--body); font-weight: 700; font-size: 1rem; line-height: 1.1;
  text-decoration: none; cursor: pointer;
  transition: background-color .15s, color .15s, border-color .15s;
}
.btn:hover { background: var(--bronze-ink); border-color: var(--bronze-ink); color: var(--on-bronze); }
.btn-small { padding: .55rem .9rem; font-size: .92rem; }
.btn-quiet { background: transparent; color: var(--ink); border-color: var(--rule-2); }
.btn-quiet:hover { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.btn-link {
  display: inline; padding: 0; border: 0; background: none; cursor: pointer;
  color: var(--bronze-ink); font-weight: 700;
  text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .28em;
}
.btn-link:hover { text-decoration-thickness: 2px; }
.hero-actions, .cta-actions, .emr-actions { display: flex; align-items: center; gap: 1.1rem 1.6rem; flex-wrap: wrap; margin-top: 1.6rem; }

:root[data-theme="dark"] .btn { background: var(--bronze); border-color: var(--bronze); color: var(--on-bronze); }
:root[data-theme="dark"] .btn:hover { background: var(--ink); border-color: var(--ink); color: var(--paper); }
:root[data-theme="dark"] .btn-quiet { background: transparent; color: var(--ink); border-color: var(--rule-2); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .btn { background: var(--bronze); border-color: var(--bronze); color: var(--on-bronze); }
  :root:not([data-theme="light"]) .btn:hover { background: var(--ink); border-color: var(--ink); color: var(--paper); }
  :root:not([data-theme="light"]) .btn-quiet { background: transparent; color: var(--ink); border-color: var(--rule-2); }
}

/* ---------- header ---------- */
.site-head {
  position: sticky; top: 0; z-index: 40;
  display: grid;
  grid-template-columns: var(--mw) minmax(0, 1fr) auto;
  align-items: center;
  min-height: 4.4rem;
  margin: 0 calc(-1 * var(--gutter));
  padding: 0 var(--gutter);
  background: color-mix(in srgb, var(--paper) 92%, transparent);
  -webkit-backdrop-filter: saturate(1.2) blur(10px);
  backdrop-filter: saturate(1.2) blur(10px);
  border-bottom: 3px double var(--rule);
}
.brand {
  justify-self: end;
  padding-right: var(--mpad);
  display: inline-flex; align-items: baseline; gap: .3rem;
  text-decoration: none; color: var(--ink);
}
.brand { align-items: center; line-height: 0; }
.ncz-logo { display: block; width: auto; overflow: visible; }
.brand-logo { height: 38px; }
.brand:focus-visible { outline-offset: 6px; }
.brand-foot .brand-logo { height: 44px; }
.site-nav { padding-left: calc(var(--rule-w) + var(--cpad)); }
.site-nav ul { list-style: none; display: flex; flex-wrap: wrap; gap: .2rem 1.5rem; }
.site-nav a { text-decoration: none; font-weight: 600; font-size: .98rem; color: var(--ink-2); padding: .3rem 0; border-bottom: 2px solid transparent; }
.site-nav a:hover { color: var(--ink); }
.site-nav a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--bronze); }
.nav-contact { display: none; }
.head-tools { display: flex; align-items: center; gap: .35rem; }
.tool {
  display: inline-flex; align-items: center; gap: .45rem;
  min-height: 2.4rem; min-width: 2.4rem; justify-content: center;
  padding: 0 .6rem;
  background: transparent; border: 1px solid transparent; border-radius: var(--radius);
  color: var(--ink-2); cursor: pointer;
}
.tool:hover { color: var(--ink); border-color: var(--rule); }
.theme-ico { display: none; }
:root:not([data-theme]) .theme-ico[data-ico="auto"],
:root[data-theme="light"] .theme-ico[data-ico="light"],
:root[data-theme="dark"] .theme-ico[data-ico="dark"] { display: inline-flex; }
.nav-toggle { display: none; }

/* ---------- flash ---------- */
.flash { padding: .9rem 0; border-bottom: 1px solid var(--rule); font-weight: 600; }
.flash-ok { color: var(--verdigris); }
.flash-warn { color: var(--bronze-ink); }
.flash-error { color: var(--margin); }

/* ---------- hero ---------- */
.hero { padding-top: clamp(3rem, 11vh, 8rem); padding-bottom: clamp(2.5rem, 6vh, 4rem); }
.hero-m { padding-top: 1.4rem; }
.hero-m p { margin: 0; }
.m-comma { display: none; }
.wordmark {
  font-family: var(--display);
  font-size: clamp(4.4rem, 16.5vw, 13rem);
  line-height: .86;
  font-weight: 820;
  font-stretch: 70%;
  letter-spacing: -.015em;
  margin: 0 0 clamp(1.5rem, 3vw, 2.4rem) -.04em;
  display: flex; align-items: baseline; flex-wrap: nowrap;
  white-space: nowrap;
}
.wm { display: inline-flex; align-items: baseline; }
.ch { display: inline-block; }
.ch.v { display: none; }
.wm-inn {
  font-family: var(--display);
  font-size: .2em;
  font-weight: 560;
  font-stretch: 100%;
  letter-spacing: 0;
  color: var(--bronze-ink);
  margin-left: .28em;
}
.hero-lead { font-size: clamp(1.2rem, 1.9vw, 1.45rem); line-height: 1.45; max-width: 46ch; margin: 0; text-wrap: pretty; }

/* intro state, set before first paint when the animation will play */
.hero-intro .wordmark { font-weight: 300; font-stretch: 100%; }
.hero-intro .ch.v { display: inline-block; }
.hero-intro .wm-inn { opacity: 0; }

/* ---------- live chain strip ---------- */
.chain { padding-bottom: clamp(2rem, 5vw, 4rem); }
.chain-head .c { padding-bottom: .9rem; }
.chain-note { color: var(--ink-2); font-size: var(--s--1); margin: 0; max-width: 70ch; }
.chain-note a { color: var(--bronze-ink); font-weight: 700; }
.chain-list { list-style: none; border-top: 3px double var(--rule); }
.chain-row { position: relative; }
.chain-row::before {
  content: "";
  position: absolute;
  left: calc(var(--mw) + var(--rule-w) / 2 - 5px);
  top: 50%; margin-top: -5px;
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--paper); border: 2px solid var(--bronze);
  z-index: 31;
}
.chain-row:first-child::before { background: var(--bronze); }
.chain-row .m { align-self: center; }
.chain-h { text-decoration: none; color: var(--ink-2); font-size: .9rem; }
.chain-row { border-bottom: 1px solid var(--rule); }
.chain-c {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 6.5rem 10.5rem 10.5rem;
  gap: 1rem; align-items: baseline;
  padding-top: .62rem; padding-bottom: .62rem;
  max-width: 68rem;
  font-size: .96rem;
}
.chain-what { text-decoration: none; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chain-what:hover { text-decoration: underline; }
.chain-id { color: var(--ink-2); font-weight: 400; font-variant-numeric: tabular-nums; }
.chain-time { color: var(--ink-2); font-size: var(--s--1); white-space: nowrap; }
.chain-hash, .chain-prev { font-size: .82rem; color: var(--ink-2); white-space: nowrap; }
.chain-hash .mono { color: var(--ink); }
.chain-k { font-size: .74rem; color: var(--ink-2); margin-right: .15rem; }
.chain-row.is-linked .chain-prev .mono,
.chain-row.is-link-target .chain-hash .mono { color: var(--on-bronze); background: var(--bronze); padding: 0 .2rem; border-radius: 2px; }
.chain-row.is-new { animation: chain-in .6s cubic-bezier(.2, .7, .2, 1) both; }
@keyframes chain-in { from { opacity: 0; transform: translateY(-10px); } }

/* ---------- ruled lists ---------- */
.ruled-list { margin: 0; border-bottom: 1px solid var(--rule); }
.rl-item {
  display: grid;
  grid-template-columns: minmax(11rem, 17rem) minmax(0, 1fr);
  gap: .4rem 2.4rem;
  padding: 1.15rem 0;
  border-top: 1px solid var(--rule);
}
.rl-item dt { font-family: var(--display); font-size: var(--s-1); font-stretch: 82%; font-weight: 700; line-height: 1.2; }
.rl-item dd { margin: 0; color: var(--ink-2); max-width: 60ch; }
.rl-item dd a { color: var(--bronze-ink); font-weight: 600; }
.ruled-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 3rem; border-bottom: 0; }
.ruled-2 .rl-item { grid-template-columns: 1fr; border-top: 1px solid var(--rule); }

/* ---------- work table ---------- */
.work-table { container-type: inline-size; container-name: work; }
.work-colhead { font-size: var(--s--2); color: var(--ink-2); }
.work-colhead .m { align-self: end; padding-bottom: .5rem; }
.work-colhead { border-bottom: 3px double var(--rule); }
.work-colhead .work-c { padding-top: 0; padding-bottom: .5rem; }
.work-list { list-style: none; }
.work-row { border-bottom: 1px solid var(--rule); }
.work-c {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(12rem, 17rem) 7rem;
  gap: .6rem 2.2rem;
  align-items: start;
  padding-top: 1.35rem; padding-bottom: 1.35rem;
}
.work-row .m { padding-top: 1.55rem; }
.work-year { font-variant-numeric: tabular-nums; }
.work-title { font-family: var(--display); font-size: clamp(1.4rem, 2.2vw, 1.75rem); font-stretch: 76%; font-weight: 740; line-height: 1.05; margin-bottom: .45rem; }
.work-title a { text-decoration: none; }
.work-title a::after { content: ""; position: absolute; inset: 0; }
.work-row { position: relative; }
.work-row:hover .work-title a, .work-row:focus-within .work-title a { text-decoration: underline; text-decoration-color: var(--bronze); text-decoration-thickness: 2px; }
.work-sum { color: var(--ink-2); margin: 0; max-width: 64ch; font-size: .98rem; }
.work-meta { font-size: var(--s--1); color: var(--ink-2); padding-top: .25rem; }
.work-sector { margin: 0 0 .35rem; }
.work-cat { color: var(--ink); font-weight: 700; }
.work-sec::before { content: ", "; }
.work-stack { list-style: none; display: inline; }
.work-stack li { display: inline; white-space: nowrap; }
.work-stack li:not(:last-child)::after { content: ","; }
.work-status { margin: 0; padding-top: .25rem; font-size: var(--s--1); font-weight: 700; white-space: nowrap; }
.work-status::before, .status-dot {
  content: ""; display: inline-block; width: .55rem; height: .55rem; border-radius: 50%;
  margin-right: .45rem; vertical-align: .05em; background: var(--rule-2);
}
.status-dot { content: none; }
.status-live::before, .status-dot.status-live { background: var(--verdigris); }
.status-delivered::before, .status-dot.status-delivered { background: var(--ink-2); }
.status-in-progress::before, .status-dot.status-in-progress { background: var(--bronze); }
.status-planned::before, .status-dot.status-planned { background: transparent; box-shadow: inset 0 0 0 1.5px var(--rule-2); }
.status-dot.status-failed { background: var(--margin); }
.work-row[hidden] { display: none; }

@container work (max-width: 760px) {
  .work-c { grid-template-columns: minmax(0, 1fr) auto; }
  .work-meta { grid-column: 1 / -1; grid-row: 2; padding-top: 0; }
  .work-status { grid-column: 2; grid-row: 1; padding-top: .35rem; }
  .work-colhead .work-c span:nth-child(2) { display: none; }
}
@container work (max-width: 480px) {
  .work-c { grid-template-columns: minmax(0, 1fr); }
  .work-stack li { white-space: normal; }
  .work-status { grid-column: 1; grid-row: auto; padding-top: 0; }
  .work-colhead { display: none; }
}

.filter-row .c { padding-bottom: 1.4rem; }
.filters { display: flex; flex-wrap: wrap; gap: .4rem 1.6rem; }
.filters a { text-decoration: none; font-weight: 600; color: var(--ink-2); padding: .3rem 0; border-bottom: 2px solid transparent; }
.filters a:hover { color: var(--ink); }
.filters a[aria-current="true"] { color: var(--ink); border-bottom-color: var(--bronze); }
.filters .count { font-size: var(--s--2); font-weight: 400; color: var(--ink-2); font-variant-numeric: tabular-nums; margin-left: .1rem; }

.cursor-preview {
  position: fixed; left: 0; top: 0; z-index: 50;
  width: 280px; aspect-ratio: 16 / 10;
  pointer-events: none; opacity: 0;
  transition: opacity .18s;
  box-shadow: var(--shadow);
  background: var(--paper-2);
}
.cursor-preview img { width: 100%; height: 100%; object-fit: cover; }
.cursor-preview.on { opacity: 1; }

/* ---------- project & facts ---------- */
.facts { margin: 0 0 1rem; max-width: 46rem; }
.facts > div { display: grid; grid-template-columns: 9.5rem minmax(0, 1fr); gap: 1rem; padding: .6rem 0; border-top: 1px solid var(--rule); }
.facts > div:last-child { border-bottom: 1px solid var(--rule); }
.facts dt { color: var(--ink-2); font-size: var(--s--1); padding-top: .12rem; }
.facts dd { margin: 0; }
.facts dd a { color: var(--bronze-ink); font-weight: 600; }
.facts dd a .icon { margin-left: .3rem; }
.facts-block { max-width: none; }
.facts-block dd.mono { font-size: .9rem; }
.facts-tight > div { padding: .4rem 0; }
.figure { margin: 2rem 0; }
.figure img { width: 100%; max-height: 72vh; object-fit: cover; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr)); gap: 6px; margin-top: 2rem; }
.gallery img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }
.byline { color: var(--ink-2); font-size: var(--s--1); }

.pager { padding-block: 2.5rem 1rem; }
.pager-c { display: flex; justify-content: space-between; gap: 2rem; border-top: 3px double var(--rule); padding-top: 1.2rem; }
.pager a { text-decoration: none; display: flex; flex-direction: column; max-width: 46%; }
.pager-next { text-align: right; margin-left: auto; }
.pager-k { font-size: var(--s--1); color: var(--ink-2); }
.pager-t { font-family: var(--display); font-stretch: 80%; font-weight: 700; font-size: var(--s-1); line-height: 1.15; }
.pager a:hover .pager-t { text-decoration: underline; text-decoration-color: var(--bronze); }

/* ---------- integrity ---------- */
.integ { display: flex; flex-direction: column; align-items: flex-end; gap: .25rem; padding-top: .7rem; font-size: var(--s--1); }
.integ-block { color: var(--ink-2); text-decoration: none; font-size: .82rem; }
.integ-block:hover { color: var(--ink); text-decoration: underline; }
.integ-state { display: inline-flex; align-items: center; gap: .3rem; font-weight: 700; }
.integ-ok .integ-state { color: var(--verdigris); }
.integ-bad .integ-state { color: var(--margin); }
.integ-btn { background: none; border: 0; padding: 0; cursor: pointer; color: var(--bronze-ink); font-size: .82rem; font-weight: 600; text-decoration: underline; text-underline-offset: .2em; text-align: right; }
.integ-out { font-size: .78rem; color: var(--ink-2); max-width: 9rem; }
.integ-out.ok { color: var(--verdigris); }
.integ-out.bad { color: var(--margin); }
.tamper {
  display: flex; gap: .9rem; align-items: flex-start;
  margin: 0 0 1.4rem; padding: 1rem 1.1rem;
  border: 1px solid var(--margin); border-left-width: 4px;
  background: color-mix(in srgb, var(--margin) 9%, var(--paper));
  color: var(--ink); max-width: 46rem;
}
.tamper .icon { color: var(--margin); margin-top: .1rem; }
.tamper p { margin: 0 0 .4rem; }
.tamper p:last-child { margin: 0; }
.tamper-t { font-weight: 800; }
.tamper a { color: var(--margin); font-weight: 700; }

/* ---------- journals: shelf ---------- */
.shelf-wrap { padding-bottom: clamp(2rem, 5vw, 3.5rem); }
.shelf-hint { color: var(--ink-2); font-size: var(--s--1); margin-bottom: 1.4rem; }
.shelf {
  display: flex; align-items: flex-end; gap: 5px;
  height: clamp(17rem, 34vw, 24rem);
  overflow-x: auto; overflow-y: visible;
  padding: 1.2rem 2px 0;
  scrollbar-width: thin;
}
.spine {
  --h: 90%; --w: 4.4rem;
  flex: none;
  height: var(--h); width: var(--w);
  display: flex; flex-direction: column; align-items: center; justify-content: space-between;
  padding: 1.3rem 0 1.2rem;
  border: 0; border-radius: 2px 2px 0 0;
  cursor: pointer; text-align: left;
  transition: transform .26s cubic-bezier(.2, .7, .2, 1);
  position: relative;
}
.spine::before, .spine::after {
  content: ""; position: absolute; left: 0; right: 0; height: 4px;
  border-top: 1px solid currentColor; border-bottom: 1px solid currentColor; opacity: .55;
}
.spine::before { top: .55rem; }
.spine::after { bottom: .5rem; }
.spine:hover { transform: translateY(-6px); }
.spine[aria-expanded="true"] { transform: translateY(-16px); }
.spine-t {
  writing-mode: vertical-rl;
  font-family: var(--display); font-stretch: 68%; font-weight: 760;
  font-size: 1.12rem; line-height: 1.05;
  max-height: calc(100% - 3.6rem);
  overflow: hidden; text-overflow: ellipsis;
  margin-top: .2rem;
}
.spine-c {
  writing-mode: vertical-rl;
  font-size: .72rem; line-height: 1; font-weight: 700; letter-spacing: .04em; opacity: .85;
  white-space: nowrap; max-height: 3rem; overflow: hidden;
}
.tone-0 { background-color: var(--ink); color: var(--paper); }
.tone-1 { background-color: var(--bronze); color: var(--on-bronze); }
.tone-2 { background-color: var(--verdigris); color: var(--paper); }
.tone-3 { background-color: var(--margin); color: #fff6f2; }
.tone-4 { background-color: var(--paper-3); color: var(--ink); box-shadow: inset 0 0 0 1px var(--rule-2); }
:root[data-theme="dark"] .tone-2, :root[data-theme="dark"] .tone-3 { color: #0F2420; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .tone-2, :root:not([data-theme="light"]) .tone-3 { color: #0F2420; } }
.shelf-board { height: 9px; background: var(--ink); border-bottom: 3px solid var(--bronze); margin-bottom: 1.8rem; }
.shelf-panel { max-width: 50rem; min-height: 9rem; }
.sp-meta { color: var(--ink-2); font-size: var(--s--1); margin-bottom: .3rem; display: flex; gap: 1rem; flex-wrap: wrap; }
.sp-status { font-weight: 700; color: var(--ink); }
.sp-status::before { content: ""; display: inline-block; width: .5rem; height: .5rem; border-radius: 50%; margin-right: .4rem; background: var(--rule-2); }
.sp-status.status-live::before { background: var(--verdigris); }
.sp-status.status-in-progress::before { background: var(--bronze); }
.sp-status.status-delivered::before { background: var(--ink-2); }
.sp-title { font-family: var(--display); font-size: var(--s-3); font-stretch: 74%; font-weight: 760; line-height: 1; margin-bottom: .7rem; }
.sp-title a { text-decoration: none; }
.sp-title a:hover { text-decoration: underline; text-decoration-color: var(--bronze); }
.sp-sum { color: var(--ink-2); font-size: 1.05rem; max-width: 62ch; }
.sp-item.is-in { animation: fade-up .35s ease both; }
@keyframes fade-up { from { opacity: 0; transform: translateY(6px); } }

.shelf-mini { height: 13rem; padding: 0; gap: 4px; text-decoration: none; border-bottom: 7px solid var(--ink); align-self: end; overflow: hidden; }
.shelf-mini .spine { width: 2.9rem; padding: .95rem 0 .8rem; cursor: pointer; justify-content: flex-start; }
.shelf-mini .spine::before { top: .35rem; height: 3px; }
.shelf-mini .spine::after { bottom: .35rem; height: 3px; }
.shelf-mini .spine-t { font-size: .86rem; margin-top: 0; max-height: calc(100% - .4rem); }
.shelf-mini:hover .spine { transform: none; }
.shelf-mini:hover .spine:nth-child(2) { transform: translateY(-6px); }
.jt-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 3rem; align-items: end; }

/* ---------- pipeline (journal services, a real sequence) ---------- */
.pipeline { list-style: none; border-bottom: 1px solid var(--rule); }
.pipe-row .m { padding-top: .6rem; }
.pipe-n { font-family: var(--display); font-size: clamp(2.2rem, 4vw, 3.2rem); font-stretch: 60%; font-weight: 300; line-height: 1; color: var(--bronze-ink); font-variant-numeric: tabular-nums; }
.pipe-row { border-top: 1px solid var(--rule); }
.pipe-c { padding-top: 1.2rem; padding-bottom: 1.2rem; display: grid; grid-template-columns: minmax(12rem, 20rem) minmax(0, 1fr); gap: .3rem 2.4rem; }
.pipe-t { font-family: var(--display); font-size: var(--s-1); font-stretch: 80%; font-weight: 720; line-height: 1.15; }
.pipe-d { margin: 0; color: var(--ink-2); max-width: 58ch; }

/* ---------- steps (ledger explainer, a real sequence) ---------- */
.steps { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 2.4rem; margin: 2rem 0 1.6rem; counter-reset: none; }
.step { padding: 1.1rem 0 1.4rem; border-top: 1px solid var(--rule); position: relative; }
.step-n { display: block; font-family: var(--display); font-size: 2.4rem; font-stretch: 60%; font-weight: 300; line-height: 1; color: var(--bronze-ink); margin-bottom: .6rem; }
.step-t { font-family: var(--display); font-size: var(--s-1); font-stretch: 82%; font-weight: 720; margin-bottom: .35rem; }
.step-d { color: var(--ink-2); margin: 0; font-size: .98rem; }

/* ---------- EMR ---------- */
.emr-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr); gap: 3rem; align-items: center; }
.receipt {
  --zz: 12px;
  justify-self: center;
  width: min(100%, 17.5rem);
  padding: 1.4rem 1.3rem calc(1.4rem + var(--zz));
  background: var(--paper-3);
  color: var(--ink);
  font-family: var(--mono);
  font-size: .82rem; line-height: 1.5;
  border-top: 1px dashed var(--rule-2);
  -webkit-mask: conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) 50% / var(--zz) 100%;
          mask: conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) 50% / var(--zz) 100%;
  transform: rotate(-1.2deg);
}
.receipt p { margin: 0; }
.rc-head { font-weight: 700; font-size: .95rem; text-align: center; }
.rc-sub { text-align: center; color: var(--ink-2); padding-bottom: .7rem; border-bottom: 1px dashed var(--rule-2); margin-bottom: .7rem !important; }
.rc-lines, .rc-feats, .rc-next { list-style: none; padding: 0; }
.rc-lines li { display: flex; justify-content: space-between; gap: 1rem; }
.rc-feats li { padding-left: 1.1em; text-indent: -1.1em; }
.rc-feats li::before { content: "+ "; color: var(--bronze-ink); }
.rc-next { counter-reset: n; }
.rc-next li { counter-increment: n; padding-left: 1.4em; text-indent: -1.4em; }
.rc-next li::before { content: counter(n) ". "; color: var(--bronze-ink); }
.rc-hash { margin-top: .8rem !important; padding-top: .7rem; border-top: 1px dashed var(--rule-2); color: var(--ink-2); word-spacing: .2em; }
.rc-foot { text-align: center; padding-top: .5rem; font-weight: 700; }
.sub-receipt { transform: none; justify-self: stretch; width: auto; position: sticky; top: 6rem; }
.sub-receipt .rc-feats { padding-bottom: .8rem; border-bottom: 1px dashed var(--rule-2); margin-bottom: .6rem; }

.demo { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); border: 1px solid var(--rule-2); background: var(--paper-3); margin-top: 1.6rem; }
.demo-appt { padding: 1.3rem; border-right: 1px solid var(--rule); }
.demo-trail { padding: 1.3rem; min-width: 0; }
.demo-k { font-size: var(--s--1); color: var(--ink-2); margin: 0 0 .6rem; }
.demo-row { display: flex; flex-wrap: wrap; align-items: center; gap: .7rem 1rem; }
.demo-row select { font: inherit; font-weight: 700; padding: .5rem .6rem; border: 1px solid var(--rule-2); border-radius: var(--radius); background: var(--paper); color: var(--ink); }
.demo-what { flex: 1 1 12rem; }
.demo-trail-head { display: flex; justify-content: space-between; gap: 1rem; align-items: baseline; }
.demo-state { margin: 0 0 .6rem; font-weight: 700; font-size: var(--s--1); color: var(--verdigris); }
.demo-state.bad { color: var(--margin); }
.demo-lines { list-style: none; border-top: 1px solid var(--rule); max-height: 19rem; overflow-y: auto; }
.demo-line {
  display: grid; grid-template-columns: 2rem 4.6rem minmax(0, 1fr) auto;
  gap: .25rem .8rem; align-items: baseline;
  padding: .5rem 0; border-bottom: 1px solid var(--rule);
  font-size: .9rem;
}
.demo-line .dl-n { font-family: var(--mono); color: var(--ink-2); }
.demo-line .dl-t { font-family: var(--mono); font-size: .8rem; color: var(--ink-2); }
.demo-line .dl-h { grid-column: 3 / -1; font-family: var(--mono); font-size: .76rem; color: var(--ink-2); overflow-wrap: anywhere; }
.demo-line .dl-x { background: none; border: 0; color: var(--bronze-ink); font-size: .8rem; font-weight: 600; text-decoration: underline; cursor: pointer; padding: 0; }
.demo-line.is-new { animation: chain-in .45s ease both; }
.demo-line.is-bad { background: color-mix(in srgb, var(--margin) 10%, transparent); }
.demo-line.is-bad .dl-h { color: var(--margin); }
.demo-line .dl-why { grid-column: 3 / -1; color: var(--margin); font-size: .82rem; font-weight: 700; }
.demo-tools { margin: .8rem 0 0; font-size: var(--s--1); }

.plans-table-wrap { overflow-x: auto; margin: 1.8rem 0 1rem; }
.plans-table { width: 100%; border-collapse: collapse; min-width: 40rem; }
.plans-table th, .plans-table td { padding: .7rem 1rem; text-align: left; vertical-align: top; border-bottom: 1px solid var(--rule); }
.plans-table thead th { vertical-align: top; border-bottom: 3px double var(--rule); padding-top: 1.3rem; padding-bottom: 1.2rem; font-weight: 400; }
.plans-table thead th:first-child { width: 34%; }
.plans-table tbody th { font-weight: 400; color: var(--ink); }
.plans-table td { text-align: center; width: 22%; }
.plans-table td .icon { color: var(--verdigris); display: inline-block; }
.plans-table .is-hl { background: var(--paper-2); }
.plans-table thead .is-hl { box-shadow: inset 0 4px 0 var(--bronze); }
.pt-name { display: block; font-family: var(--display); font-size: var(--s-2); font-stretch: 76%; font-weight: 760; line-height: 1.05; }
.pt-price { display: block; font-weight: 800; font-size: 1.12rem; margin: .35rem 0 .3rem; }
.pt-blurb { display: block; color: var(--ink-2); font-size: .9rem; line-height: 1.4; margin-bottom: .9rem; min-height: 4.2em; }
.plans-stack .pt-blurb { min-height: 0; }
.pt-cap td { text-align: left; font-weight: 700; font-size: .92rem; line-height: 1.35; }
.pt-cap th { color: var(--ink-2); }
.pt-no { display: inline-block; width: .9rem; height: 1px; background: var(--rule-2); vertical-align: middle; }
.plans-stack { display: none; }
.ps-plan { padding: 1.3rem 0 1.5rem; border-top: 1px solid var(--rule); }
.ps-plan.is-hl { border-top: 4px solid var(--bronze); padding-left: 1rem; padding-right: 1rem; background: var(--paper-2); }
.ps-feats { list-style: none; margin: 0 0 1.1rem; }
.ps-feats li { display: flex; gap: .5rem; padding: .22rem 0; }
.ps-feats .icon { color: var(--verdigris); margin-top: .2rem; }

.faq { border-bottom: 1px solid var(--rule); max-width: 52rem; }
.faq details { border-top: 1px solid var(--rule); }
.faq summary {
  list-style: none; cursor: pointer;
  display: flex; justify-content: space-between; gap: 1rem; align-items: baseline;
  padding: 1rem 0;
  font-family: var(--display); font-size: var(--s-1); font-stretch: 82%; font-weight: 700;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-family: var(--body); font-weight: 400; font-size: 1.4rem; line-height: 1; color: var(--bronze-ink); transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { color: var(--ink-2); max-width: 62ch; padding-bottom: .6rem; }

/* ---------- forms ---------- */
.form { max-width: 38rem; }
.field { margin: 0 0 1.25rem; border: 0; padding: 0; min-width: 0; }
.field label, .field legend { display: block; font-weight: 700; margin-bottom: .35rem; padding: 0; }
.hint { color: var(--ink-2); font-size: var(--s--1); margin: -.15rem 0 .45rem; }
input[type="text"], input[type="email"], input[type="tel"], input[type="number"], input[type="search"], input[type="url"], textarea, select {
  width: 100%;
  font: inherit; color: var(--ink);
  padding: .72rem .85rem;
  background: var(--paper-3);
  border: 1px solid var(--rule-2);
  border-radius: var(--radius);
  transition: border-color .15s, box-shadow .15s;
}
textarea { resize: vertical; min-height: 7rem; line-height: 1.5; }
textarea.mono { font-family: var(--mono); font-size: .88rem; word-break: break-all; }
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--bronze); box-shadow: 0 0 0 3px color-mix(in srgb, var(--bronze) 28%, transparent); }
.has-err input, .has-err textarea { border-color: var(--margin); }
.err { color: var(--margin); font-size: var(--s--1); font-weight: 700; margin: .35rem 0 0; }
.form-err { color: var(--margin); font-weight: 700; border-left: 4px solid var(--margin); padding: .5rem .8rem; background: color-mix(in srgb, var(--margin) 8%, transparent); }
.form-ok { display: flex; gap: .5rem; align-items: center; color: var(--verdigris); font-weight: 700; border-left: 4px solid var(--verdigris); padding: .6rem .8rem; background: color-mix(in srgb, var(--verdigris) 9%, transparent); }
.form-actions { margin-top: 1.6rem; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.choices { display: flex; flex-wrap: wrap; gap: .5rem; }
.choice { position: relative; display: inline-flex !important; margin: 0 !important; font-weight: 600 !important; cursor: pointer; }
.choice input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.choice span { display: inline-block; padding: .45rem .8rem; border: 1px solid var(--rule-2); border-radius: var(--radius); background: var(--paper-3); }
.choice:hover span { border-color: var(--ink-2); }
.choice:has(input:checked) span { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.choice:has(input:focus-visible) span { outline: 2px solid var(--bronze); outline-offset: 2px; }
.sub-grid, .contact-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, .8fr); gap: 3.5rem; align-items: start; }
.contact-direct { padding-top: .3rem; }
.contact-lines { list-style: none; margin: 0 0 1.4rem; }
.contact-lines li { padding: .5rem 0; border-top: 1px solid var(--rule); }
.contact-lines li:last-child { border-bottom: 1px solid var(--rule); }
.contact-lines a { display: inline-flex; align-items: center; gap: .6rem; text-decoration: none; font-weight: 600; }
.contact-lines a:hover { color: var(--bronze-ink); }
.contact-who { font-weight: 700; }
.contact-who span, .contact-addr { color: var(--ink-2); font-weight: 400; }
.order-status { font-weight: 800; font-size: var(--s-1); }
.note-box { margin-top: 1rem; padding: 1rem 1.1rem; border-left: 3px solid var(--bronze); background: var(--paper-2); max-width: 46rem; }

.keybox { display: flex; align-items: flex-start; gap: .5rem; margin: 0 0 1rem; padding: .7rem .8rem; background: var(--paper-3); border: 1px solid var(--rule); max-width: 52rem; }
.keybox code { flex: 1; min-width: 0; font-size: .84rem; overflow-wrap: anywhere; word-break: break-all; line-height: 1.5; }
.keybox .tool { flex: none; font-size: .85rem; font-weight: 600; color: var(--bronze-ink); border-color: var(--rule); }
.keybox .tool.done { color: var(--verdigris); }
.keys { margin: 0; }
.keys dt { font-weight: 700; margin-bottom: .35rem; }
.k-alg { font-weight: 400; color: var(--ink-2); font-size: var(--s--1); margin-left: .4rem; }
.keys dd { margin: 0 0 1.2rem; }

.result { margin-top: 1.8rem; padding: 1.2rem 1.3rem; border: 1px solid var(--rule-2); border-left-width: 4px; max-width: 46rem; }
.result-ok { border-color: var(--verdigris); }
.result-bad { border-color: var(--margin); }
.result-t { display: flex; align-items: center; gap: .55rem; font-family: var(--display); font-size: var(--s-2); font-stretch: 78%; font-weight: 760; margin-bottom: .4rem; }
.result-ok .result-t { color: var(--verdigris); }
.result-bad .result-t { color: var(--margin); }

/* ---------- ledger ---------- */
.verify { border-left: 4px solid var(--bronze); padding: 1.2rem 0 1.2rem 1.4rem; max-width: 54rem; }
.verify .h3 { margin-bottom: .5rem; }
.verify-one { border-left: 0; padding: 0; }
.meter { height: 6px; background: var(--paper-2); box-shadow: inset 0 0 0 1px var(--rule); margin: 1rem 0 .8rem; overflow: hidden; }
.meter span { display: block; height: 100%; width: 0; background: var(--bronze); transition: width .15s linear; }
.meter.ok span { background: var(--verdigris); }
.meter.bad span { background: var(--margin); }
.verify-msg { font-weight: 700; margin: 0 0 .5rem; }
.verify-msg.ok { color: var(--verdigris); }
.verify-msg.bad { color: var(--margin); }
.verify-log { list-style: none; font-size: .9rem; color: var(--ink-2); }
.verify-log li { padding: .22rem 0; display: flex; gap: .5rem; align-items: baseline; }
.verify-log li .icon { align-self: center; }
.verify-log li.ok .icon { color: var(--verdigris); }
.verify-log li.bad { color: var(--margin); font-weight: 600; }
.how-verify { margin-top: 1.4rem; max-width: 54rem; }
.how-verify summary { cursor: pointer; font-weight: 700; color: var(--bronze-ink); }
.how-verify pre { background: var(--paper-2); padding: .9rem; font-size: .8rem; white-space: pre-wrap; }

.ledger-table { container-type: inline-size; container-name: lt; }
.lt-list { list-style: none; }
.lt-head { font-size: var(--s--2); color: var(--ink-2); }
.lt-head .m { align-self: end; padding-bottom: .5rem; }
.lt-head { border-bottom: 3px double var(--rule); }
.lt-head .lt-c { padding-bottom: .5rem; padding-top: 0; }
.lt-row { border-bottom: 1px solid var(--rule); }
.lt-c {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 10.5rem 10rem 10rem;
  gap: 1rem; align-items: baseline;
  padding-top: .55rem; padding-bottom: .55rem;
  font-size: .95rem;
}
.lt-row .m { padding-top: .55rem; }
.lt-row .m a { color: var(--ink-2); text-decoration: none; font-size: .88rem; }
.lt-row .m a:hover { color: var(--ink); text-decoration: underline; }
.lt-what { text-decoration: none; font-weight: 600; min-width: 0; }
.lt-what:hover { text-decoration: underline; }
.lt-actor { font-weight: 400; color: var(--ink-2); font-size: var(--s--2); margin-left: .5rem; }
.lt-c time { color: var(--ink-2); font-size: var(--s--1); white-space: nowrap; }
.lt-hash, .lt-prev { font-size: .82rem; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lt-hash { color: var(--ink); }
@container lt (max-width: 820px) {
  .lt-c { grid-template-columns: minmax(0, 1fr) auto; }
  .lt-prev { display: none; }
  .lt-c time { grid-row: 2; grid-column: 1; }
  .lt-hash { grid-row: 1 / span 2; grid-column: 2; align-self: center; }
  .lt-head .lt-c span:nth-child(4) { display: none; }
}

.table-scroll { overflow-x: auto; }
.data-table { border-collapse: collapse; width: 100%; font-size: .94rem; min-width: 34rem; }
.data-table th, .data-table td { text-align: left; padding: .55rem .8rem .55rem 0; border-bottom: 1px solid var(--rule); vertical-align: top; }
.data-table thead th { font-size: var(--s--2); color: var(--ink-2); font-weight: 400; border-bottom: 3px double var(--rule); }
.data-table a { color: var(--bronze-ink); font-weight: 600; margin-right: .6rem; }
.witness-list { list-style: none; }
.witness-list li { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: .3rem 1.4rem; padding: .7rem 0; border-top: 1px solid var(--rule); align-items: baseline; }
.witness-list li:last-child { border-bottom: 1px solid var(--rule); }
.w-peer { font-weight: 700; }
.w-state { display: inline-flex; gap: .35rem; align-items: center; font-weight: 700; }
.witness-list .ok .w-state { color: var(--verdigris); }
.witness-list .bad .w-state { color: var(--margin); }
.w-seen, .w-note { color: var(--ink-2); font-size: var(--s--1); }
.w-note { grid-column: 1 / -1; }

/* ---------- stack lab ---------- */
.lab { border-top: 1px solid var(--rule); padding-block: clamp(2.2rem, 5vw, 3.6rem); }
.lab:last-of-type { border-bottom: 1px solid var(--rule); }
.lab .m { padding-top: .4rem; }
.lab-c { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 2.4rem; align-items: start; }
.lab-copy p { color: var(--ink-2); max-width: 46ch; }
.lab-demo { min-width: 0; }
.lab-word {
  --w: 72; --g: 800;
  font-family: var(--display);
  font-size: clamp(3.4rem, 9vw, 7rem);
  font-stretch: calc(var(--w) * 1%);
  font-weight: var(--g);
  line-height: .9; margin: 0 0 1.2rem;
  white-space: nowrap; overflow: hidden;
}
.sliders { display: grid; gap: .9rem; max-width: 28rem; }
.sliders label { display: grid; grid-template-columns: 4.5rem 3.4rem 1fr; align-items: center; gap: .6rem; font-weight: 600; font-size: .95rem; }
.sliders output { font-family: var(--mono); font-size: .85rem; color: var(--ink-2); }
input[type="range"] { accent-color: var(--bronze); width: 100%; }
.cq-box {
  container-type: inline-size;
  resize: horizontal; overflow: hidden;
  min-width: 13rem; max-width: 100%; width: 100%;
  border: 1px dashed var(--rule-2);
  padding: 1rem 1.1rem 1.6rem;
  background: var(--paper-3);
  position: relative;
}
.cq-item { display: grid; grid-template-columns: 1fr; gap: .2rem; }
.cq-year { color: var(--ink-2); font-size: var(--s--1); }
.cq-title { font-family: var(--display); font-stretch: 78%; font-weight: 740; font-size: 1.3rem; line-height: 1.1; }
.cq-meta { color: var(--ink-2); font-size: var(--s--1); }
.cq-status { font-weight: 700; font-size: var(--s--1); }
.cq-status::before { content: ""; display: inline-block; width: .5rem; height: .5rem; border-radius: 50%; background: var(--verdigris); margin-right: .4rem; }
.cq-width { position: absolute; right: .6rem; bottom: .3rem; margin: 0; font-size: .72rem; color: var(--ink-2); }
@container (min-width: 30rem) {
  .cq-item { grid-template-columns: 3.4rem minmax(0, 1fr) auto; align-items: baseline; column-gap: 1.2rem; }
  .cq-meta { grid-column: 2; }
  .cq-status { grid-column: 3; grid-row: 1; }
}
@container (min-width: 40rem) {
  .cq-item { grid-template-columns: 3.4rem minmax(0, 1fr) 12rem 5rem; }
  .cq-meta { grid-column: 3; grid-row: 1; }
  .cq-status { grid-column: 4; }
  .cq-title { font-size: 1.6rem; }
}
.lab-label { display: block; font-weight: 700; font-size: .95rem; margin: 0 0 .35rem; }
.hash-out { margin: 0; padding: .7rem .8rem; background: var(--paper-2); font-size: .9rem; overflow-wrap: anywhere; word-break: break-all; min-height: 3.2rem; }
[data-lab-hash] input { margin-bottom: 1rem; }
.prefs { margin: 0; }
.prefs > div { display: grid; grid-template-columns: 9rem 1fr; gap: 1rem; padding: .55rem 0; border-top: 1px solid var(--rule); }
.prefs > div:last-child { border-bottom: 1px solid var(--rule); }
.prefs dt { color: var(--ink-2); }
.prefs dd { margin: 0; font-weight: 700; }
.prefs dd.flash-change { animation: pref-flash .8s ease; }
@keyframes pref-flash { from { color: var(--bronze); } }

.stack-words { list-style: none; display: flex; flex-wrap: wrap; gap: .1rem 0; margin: .4rem 0 1.4rem; max-width: 70rem; }
.stack-words li { font-family: var(--display); font-stretch: 78%; font-weight: 600; font-size: clamp(1.1rem, 1.8vw, 1.45rem); color: var(--ink-2); }
.stack-words li:not(:last-child)::after { content: "/"; color: var(--rule-2); font-weight: 300; margin: 0 .55rem; }

/* ---------- insights ---------- */
.post-list { list-style: none; border-top: 3px double var(--rule); }
.post-row .m { padding-top: 1.5rem; }
.post-row { border-bottom: 1px solid var(--rule); }
.post-row .c { padding-top: 1.3rem; padding-bottom: 1.4rem; }
.post-t { font-family: var(--display); font-size: clamp(1.5rem, 2.6vw, 2.1rem); font-stretch: 76%; font-weight: 740; line-height: 1.05; margin-bottom: .5rem; max-width: 30ch; }
.post-t-sm { font-size: var(--s-1); }
.post-t a { text-decoration: none; }
.post-t a:hover { text-decoration: underline; text-decoration-color: var(--bronze); }
.post-x { color: var(--ink-2); margin: 0; max-width: 64ch; }

/* ---------- about ---------- */
.person { max-width: 46rem; border-top: 3px double var(--rule); padding-top: 1.3rem; }
.person-name { font-family: var(--display); font-size: var(--s-3); font-stretch: 74%; font-weight: 780; line-height: 1; margin-bottom: .2rem; }
.person-role { color: var(--bronze-ink); font-weight: 700; margin-bottom: 1rem; }

/* ---------- CTA ---------- */
.cta-t { font-family: var(--display); font-size: clamp(2rem, 4.6vw, 3.6rem); font-stretch: 72%; font-weight: 760; line-height: 1; max-width: 22ch; margin-bottom: .8rem; text-wrap: balance; }
.cta .narrow { color: var(--ink-2); }

/* ---------- error ---------- */
.err-code { display: block; font-family: var(--display); font-size: clamp(3rem, 7vw, 6rem); font-stretch: 58%; font-weight: 300; line-height: .9; color: var(--margin); }

/* ---------- footer ---------- */
.site-foot { border-top: 3px double var(--rule); margin-top: clamp(3rem, 8vw, 6rem); font-size: .95rem; }
.foot-main { padding-top: 2.4rem; padding-bottom: 2rem; }
.brand-foot { padding-right: 0; }
.foot-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.6rem 2.4rem; }
.foot-grid p { margin: 0; }
.foot-name { font-weight: 800; }
.foot-role { color: var(--bronze-ink); font-weight: 600; }
.foot-addr { color: var(--ink-2); margin-top: .4rem !important; }
.foot-links { list-style: none; }
.foot-links li { padding: .18rem 0; }
.foot-links a { text-decoration: none; display: inline-flex; gap: .45rem; align-items: center; color: var(--ink); }
.foot-links a:hover { text-decoration: underline; text-decoration-color: var(--bronze); }
.foot-ledger { padding-bottom: 2.4rem; color: var(--ink-2); font-size: var(--s--1); }
.foot-ledger .c { border-top: 1px solid var(--rule); padding-top: 1rem; }
.foot-ledger .m { padding-top: 1rem; }
.foot-ledger a { color: var(--ink); }
.foot-height { text-decoration: none; color: var(--ink-2) !important; }
.foot-small { margin-top: .4rem; }

/* ---------- command palette ---------- */
.palette { position: fixed; inset: 0; z-index: 90; }
.palette[hidden] { display: none; }
.palette-backdrop { position: absolute; inset: 0; background: color-mix(in srgb, var(--ink) 35%, transparent); }
.palette-box {
  position: relative;
  width: min(40rem, calc(100vw - 2rem));
  margin: 12vh auto 0;
  background: var(--paper);
  border: 1px solid var(--rule-2);
  box-shadow: var(--shadow);
  max-height: 70vh;
  display: flex; flex-direction: column;
}
.palette.is-open .palette-box { animation: pal-in .16s ease-out; }
@keyframes pal-in { from { opacity: 0; transform: translateY(-8px) scale(.99); } }
.palette-field { display: flex; align-items: center; gap: .7rem; padding: .9rem 1rem; border-bottom: 3px double var(--rule); color: var(--ink-2); }
input[type="search"]::-webkit-search-cancel-button { -webkit-appearance: none; appearance: none; }
.palette-field input { border: 0; background: none; padding: .2rem 0; font-size: 1.15rem; box-shadow: none !important; color: var(--ink); }
.palette-list { list-style: none; overflow-y: auto; padding: .4rem 0; }
.palette-list li a { display: flex; justify-content: space-between; gap: 1rem; align-items: baseline; padding: .6rem 1rem .6rem calc(1rem - 3px); text-decoration: none; border-left: 3px solid transparent; }
.palette-list li a .pk { color: var(--ink-2); font-size: var(--s--1); white-space: nowrap; }
.palette-list li a .pd { display: block; color: var(--ink-2); font-size: var(--s--1); font-weight: 400; }
.palette-list li a .pt { font-weight: 600; }
.palette-list li[aria-selected="true"] a { background: var(--paper-2); border-left-color: var(--bronze); }
.palette-list mark { background: none; color: var(--bronze-ink); font-weight: 800; }
.palette-empty { padding: 1rem; color: var(--ink-2); margin: 0; }

/* ---------- scroll progress & view transitions ---------- */
.scroll-progress { display: none; }
@supports (animation-timeline: scroll()) {
  .scroll-progress {
    display: block; position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 60;
    background: var(--bronze); transform-origin: 0 50%; transform: scaleX(0);
    animation: progress-grow linear both; animation-timeline: scroll(root block);
  }
  @keyframes progress-grow { to { transform: scaleX(1); } }
}
@view-transition { navigation: auto; }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: .26s; }
::view-transition-group(page-title) { animation-duration: .35s; animation-timing-function: cubic-bezier(.2, .7, .2, 1); }

/* ---------- responsive ---------- */
@media (max-width: 1100px) {
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .chain-c { grid-template-columns: minmax(0, 1fr) 6rem 9.5rem; }
  .chain-prev { display: none; }
}

@media (max-width: 899px) {
  :root { --mw: 0px; --gutter: 14px; --cpad: 16px; --mpad: 0px; }
  .sheet { padding-right: 16px; padding-left: var(--gutter); }
  .row { grid-template-columns: minmax(0, 1fr); }
  .m { text-align: left; padding-left: calc(var(--rule-w) + var(--cpad)); padding-right: 0; }
  .m:empty { display: none; }
  .page-head .m { padding-top: 0; margin-bottom: .6rem; display: flex; gap: .3rem 1rem; flex-wrap: wrap; }
  .page-head .m-note + .m-note { margin-top: 0; }
  .site-head { grid-template-columns: auto 1fr auto; margin: 0 -16px 0 calc(-1 * var(--gutter)); padding: 0 16px 0 var(--gutter); min-height: 3.8rem; }
  .brand { justify-self: start; padding-left: calc(var(--rule-w) + var(--cpad)); }
  .brand-logo { height: 30px; }
  .brand-foot .brand-logo { height: 44px; }
  .site-nav { position: absolute; top: 100%; left: 0; right: 0; padding: .5rem 16px 1rem calc(var(--gutter) + var(--rule-w) + var(--cpad)); background: var(--paper); border-bottom: 3px double var(--rule); display: none; }
  .site-nav.open { display: block; }
  .site-nav ul { flex-direction: column; gap: 0; }
  .site-nav li a { display: block; padding: .7rem 0; font-size: 1.1rem; border-bottom: 1px solid var(--rule); }
  .site-nav a[aria-current="page"] { border-bottom-color: var(--rule); color: var(--bronze-ink); }
  .nav-contact { display: block; }
  .nav-toggle { display: inline-flex; }
  .kbd[data-kbd] { display: none; }
  .head-tools { gap: 0; grid-column: 3; justify-self: end; }

  /* rows that keep a slim margin for their numbers */
  .chain-row, .lt-row, .work-row, .post-row, .pipe-row { grid-template-columns: 3.6rem minmax(0, 1fr); }
  .chain-row .m, .lt-row .m, .work-row .m, .post-row .m, .pipe-row .m { padding-left: calc(var(--rule-w) + 8px); text-align: left; display: block; font-size: .8rem; }
  .chain-row .c, .lt-row .c, .work-row .c, .post-row .c, .pipe-row .c { padding-left: .6rem; }
  .chain-row::before { left: calc(var(--rule-w) / 2 - 4px); width: 8px; height: 8px; margin-top: -4px; }
  .work-colhead, .lt-head { display: none; }
  .post-row .m time { font-size: .76rem; line-height: 1.3; }
  .pipe-row .m { padding-top: 1.1rem; }
  .pipe-n { font-size: 1.9rem; }

  .chain-c { grid-template-columns: minmax(0, 1fr) auto; gap: .1rem .8rem; }
  .chain-time { grid-column: 2; grid-row: 1; }
  .chain-hash { grid-column: 1 / -1; }
  .rl-item { grid-template-columns: 1fr; }
  .ruled-2 { grid-template-columns: 1fr; }
  .pipe-c { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .jt-grid, .emr-grid, .sub-grid, .contact-grid, .lab-c { grid-template-columns: 1fr; gap: 2rem; }
  .shelf-mini { height: 10rem; }
  .demo { grid-template-columns: 1fr; }
  .demo-appt { border-right: 0; border-bottom: 1px solid var(--rule); }
  .sub-receipt { position: static; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .foot-who { grid-column: 1 / -1; }
  .brand-foot { padding-left: 0; }
  .site-foot .m:has(.brand-foot) { padding-bottom: 1rem; }
  .facts > div { grid-template-columns: 7rem minmax(0, 1fr); }
  .integ { align-items: flex-start; padding-top: 0; margin-bottom: 1rem; flex-direction: row; flex-wrap: wrap; gap: .3rem .9rem; }
  .integ-out { max-width: none; }
  .wordmark { margin-left: -.03em; }
  .hero { padding-top: 2.6rem; }
  .hero .m { display: flex; gap: .3em; margin-bottom: .6rem; }
  .hero .m .m-comma { display: inline; }
  .wordmark { font-size: clamp(4.4rem, 21vw, 13rem); }
  .demo-line { grid-template-columns: 1.4rem minmax(0, 1fr) auto; }
  .demo-line .dl-n { grid-column: 1; grid-row: 1; }
  .demo-line .dl-w { grid-column: 2; grid-row: 1; }
  .demo-line .dl-x { grid-column: 3; grid-row: 1; }
  .demo-line .dl-t { grid-column: 2; grid-row: 2; }
  .demo-line .dl-h, .demo-line .dl-why { grid-column: 2 / -1; }
  .witness-list li { grid-template-columns: 1fr; }
  .shelf { height: 18rem; }
  .spine { --w: 3.6rem !important; }
  .spine-t { font-size: 1rem; }
}

@media (max-width: 720px) {
  .plans-table-wrap { display: none; }
  .plans-stack { display: block; }
}

@media (max-width: 420px) {
  .foot-grid { grid-template-columns: 1fr; }
  .facts > div { grid-template-columns: 1fr; gap: .1rem; }
  .btn { padding: .78rem 1.1rem; }
}

/* ---------- motion preferences ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  @view-transition { navigation: none; }
  .scroll-progress { display: none; }
  .spine:hover, .spine[aria-expanded="true"] { transform: none; }
  .spine[aria-expanded="true"] { box-shadow: inset 0 -5px 0 var(--bronze); }
}

/* ---------- print ---------- */
@media print {
  .site-head, .scroll-progress, .palette, .head-tools, .cursor-preview, .hero-actions, .cta { display: none !important; }
  .sheet::before { display: none; }
  body { background: #fff; color: #000; }
}

/* hero: last letter swap for the intro */
.l-s { display: none; }
.hero-intro .l-s { display: inline; }
.hero-intro .l-z { display: none; }

/* ---------- walkthrough videos ---------- */
.vid { margin: 0 0 1.5rem; max-width: 60rem; }
.vid-frame { position: relative; aspect-ratio: 16 / 10; background: #0b1c19; border: 1px solid var(--rule); overflow: hidden; }
.vid-frame video, .vid-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; background: #0b1c19; object-fit: contain; }
.vid-embed { position: absolute; inset: 0; }
.vid-embed img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .55; }
.vid-play { position: absolute; inset: 0; width: 100%; display: grid; place-content: center; justify-items: center; gap: .35rem; border: 0; cursor: pointer; color: #EEF2EC; background: linear-gradient(transparent 40%, rgba(11, 28, 25, .55)); font-family: var(--body); text-align: center; padding: 1rem; }
.vid-play-ico { width: 4rem; height: 4rem; display: grid; place-items: center; border-radius: 50%; background: var(--bronze); color: #10302A; transition: transform .15s ease; }
.vid-play:hover .vid-play-ico, .vid-play:focus-visible .vid-play-ico { transform: scale(1.06); }
.vid-play-t { font-weight: 700; font-size: 1.05rem; }
.vid-play-n { font-size: .82rem; opacity: .85; }
.vid-cap { margin-top: .5rem; font-size: .9rem; color: var(--ink-2); }
.vid-row .c { padding-top: .25rem; }

.work-watch { margin: .45rem 0 0; font-size: .9rem; }
.work-watch a { display: inline-flex; align-items: center; gap: .35rem; font-weight: 700; color: var(--bronze-ink); text-underline-offset: .2em; }
.work-watch .icon { color: var(--bronze); }

.walks { padding-bottom: 1.25rem; }
.walks .h3 { margin: 0 0 .9rem; }
.walks-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 17rem), 1fr)); gap: 1.25rem; }
.walk { display: grid; gap: .3rem; color: inherit; text-decoration: none; }
.walk-img { position: relative; display: block; aspect-ratio: 16 / 10; background: var(--paper-2); border: 1px solid var(--rule); overflow: hidden; }
.walk-img img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .25s ease; }
.walk-play { position: absolute; left: .7rem; bottom: .7rem; width: 2.6rem; height: 2.6rem; border-radius: 50%; display: grid; place-items: center; background: var(--bronze); color: #10302A; }
.walk-t { font-family: var(--display); font-stretch: 82%; font-weight: 700; font-size: 1.15rem; line-height: 1.15; }
.walk-s { font-size: .88rem; color: var(--bronze-ink); text-decoration: underline; text-underline-offset: .2em; }
.walk:hover .walk-img img, .walk:focus-visible .walk-img img { transform: scale(1.025); }
.walk:focus-visible { outline: 2px solid var(--bronze); outline-offset: 4px; }
@media (prefers-reduced-motion: reduce) { .walk-img img, .vid-play-ico { transition: none; } }
