/* ==========================================================================
   COMPONENTS
   Every component here draws from the tokens in brand.css. Nothing in this
   file sets a font size, a color value or a spacing literal of its own, so
   a change to the system reaches the whole site from one place.
   ========================================================================== */

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

body {
  margin: 0; background: var(--bg); color: var(--text);
  /* clip, not hidden: hidden would make body a scroll container and break
     the sticky header. The large mark bleeds to the edge and stops there. */
  overflow-x: clip;
  font-family: var(--font-body);
  font-size: var(--text-md); line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased;
  font-variant-numeric: tabular-nums;
}
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }

/* Two fixed layers of material, both inert: a wash of brand light at the top
   of the page, and a fine grain over everything so large flat areas have a
   surface instead of being empty. Subtle enough to read as paper, not as a
   texture effect. */
.wash, .grain {
  position: fixed; inset: 0; pointer-events: none; z-index: 0;
}
.wash  { background: var(--glow); }
.grain {
  opacity: var(--grain); mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.82' numOctaves='3'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---- One definition for every display size ----------------------------- */
h1, h2, h3 {
  font-family: var(--font-display); font-weight: 600; margin: 0;
  line-height: var(--lh-display); letter-spacing: var(--track-display);
  font-optical-sizing: auto;
}
/* ---- One definition for every mono label ------------------------------- */
.mark__name, .tick, .hero__kicker, .row__meta,
.job__role, .matrix dt {
  font-family: var(--font-mono); font-size: var(--text-xs);
  line-height: var(--lh-label); letter-spacing: var(--track-label);
  text-transform: uppercase;
}

/* ---------- Shell and axis ---------------------------------------------- */
.shell {
  position: relative; width: 100%; max-width: var(--shell);
  margin-inline: auto; padding-inline: var(--gutter);
  z-index: 1;
}
.spine { position: absolute; top: 0; bottom: 0;
         left: calc(var(--gutter) + var(--spine));
         width: 1px; background: var(--spine-dim); z-index: 0; }
/* Full height, so the gradient maps to the whole page rather than being
   squashed into whatever has been drawn so far; clip-path reveals it down to
   the reader's position. The hue at any depth is that section's hue. */
/* The inked length used to end in a hard horizontal cut against an almost
   invisible track, which is exactly what a scrollbar thumb looks like. The
   track is now legible, so the line reads as a full-length rule being inked
   in, and the leading end is feathered over 56px so there is no thumb edge
   to see. clip-path still does the actual reveal: where mask is unsupported
   the result is the old hard edge rather than no line at all. */
.spine__drawn {
  position: absolute; inset: 0; width: 1px;
  background: linear-gradient(to bottom,
    var(--h-mint) 0%, var(--h-teal) 26%, var(--h-azure) 44%,
    var(--h-violet) 64%, var(--h-amber) 86%);
  clip-path: inset(0 0 calc(100% - var(--progress, 0%)) 0);
  -webkit-mask-image: linear-gradient(to bottom, #000 0,
    #000 max(0px, calc(var(--progress, 0%) - 56px)), transparent var(--progress, 0%));
  mask-image: linear-gradient(to bottom, #000 0,
    #000 max(0px, calc(var(--progress, 0%) - 56px)), transparent var(--progress, 0%));
  transition: clip-path 90ms linear;
}
/* The spine and its branches occupy the left margin. Without the same margin
   on the right, the whole column sits off-center by that amount — at 1500px
   the content began 130px from the left edge and ended 40px from the right. */
.bay { position: relative; z-index: 1;
       margin-inline: calc(var(--spine) + var(--branch)); }

/* A branch and its node. --node-y is the optical center of the block's FIRST
   line, so the node can never slide off the thing it points at. */
.node { position: relative; --node-y: 0.55rem; }
.node::before {
  content: ""; position: absolute; top: var(--node-y);
  left: calc(-1 * var(--branch)); width: var(--branch); height: 1px;
  background: var(--spine-dim);
  transform: scaleX(0); transform-origin: left center;
  transition: transform .55s var(--ease), background var(--dur) var(--ease);
}
.node::after {
  content: ""; position: absolute; top: calc(var(--node-y) - 3px);
  left: calc(-1 * var(--branch) - 3px); width: 6px; height: 6px;
  background: var(--bg); border: 1px solid var(--line-strong);
  transform: rotate(45deg) scale(0);
  transition: transform .4s var(--ease) .3s, background var(--dur) var(--ease),
              border-color var(--dur) var(--ease);
}
.node.is-live::before { transform: scaleX(1); background: var(--accent); }
.node.is-live::after  { transform: rotate(45deg) scale(1);
                        background: var(--accent); border-color: var(--accent);
                        animation: ping .9s var(--ease) .42s; }
@keyframes ping { from { box-shadow: 0 0 0 0 var(--accent); }
                  to   { box-shadow: 0 0 0 9px transparent; } }
/* Display type's first line sits lower than a label's, and it is fluid, so
   the offset is derived rather than written as a fixed rem. */
.job__grid .node { --node-y: calc(var(--d-1) * 0.54); }
/* The plate's numeral is the first line of a section head, and it is fluid. */
.sec__head.node { --node-y: calc(var(--d-base) * 1.21); }
/* .close and .hero ARE the section, so their first line sits one whole
   --gap-sec below the top of the node. Leaving that out put the Contact
   branch 52-92px above the numeral it points at, depending on the width. */
.close.node { --node-y: calc(var(--gap-sec) + var(--d-base) * 1.21); }
.hero.node { --node-y: calc(var(--gap-sec) + 0.55rem); }

/* ---------- Header ------------------------------------------------------- */
/* Opaque by default. The translucent version depends entirely on the blur
   behind it being applied — without it the header is 86% glass with sharp
   body text legible straight through it, which is what happens wherever
   backdrop-filter is unsupported or switched off for want of a GPU. */
.top { position: sticky; top: 0; z-index: 50;
       background: var(--bg);
       border-bottom: 1px solid var(--line); }
@supports ((backdrop-filter: blur(12px)) or (-webkit-backdrop-filter: blur(12px))) {
  /* 94%, not 86%: the blur is an enhancement, and plenty of machines report
     support for backdrop-filter while never compositing it. At 86% a dense
     paragraph scrolling under the header stayed legible straight through it,
     which read as the menu disappearing. */
  .top { background: color-mix(in srgb, var(--bg) 94%, transparent);
         -webkit-backdrop-filter: blur(12px) saturate(1.2);
         backdrop-filter: blur(12px) saturate(1.2); }
}
.top__in { display: flex; align-items: center; gap: var(--sp-5);
           padding-block: var(--sp-4); }
.mark { display: flex; align-items: center; gap: var(--sp-3); flex: none; }
.mark svg { width: 34px; height: 34px; color: var(--text); }
.mark__name { color: var(--text-muted); }
.ticks { display: flex; gap: var(--sp-5); margin-left: auto; align-items: center; }
.tick { display: flex; align-items: baseline; gap: var(--sp-2);
        color: var(--text-muted); padding-block: var(--sp-2);
        transition: color var(--dur) var(--ease); }
.tick:hover, .tick[aria-current="true"] { color: var(--text); }
/* The current section is marked with a rule under its name rather than a
   number beside it. A numbered menu reads as a table of contents for a
   document, not as the navigation of a site. */
.tick__word { display: inline; position: relative; padding-bottom: var(--sp-1); }
.tick[aria-current="true"] .tick__word::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0;
  height: 2px; background: var(--accent);
}
.top__act { display: flex; gap: var(--sp-2); align-items: center; }

.btn { display: inline-flex; align-items: center; gap: var(--sp-2);
       font-family: var(--font-body); font-size: var(--text-sm); font-weight: 500;
       line-height: 1; letter-spacing: 0;
       padding: .72rem 1.05rem; border: 1px solid var(--line-strong);
       color: var(--text); background: transparent; cursor: pointer;
       transition: border-color var(--dur) var(--ease), color var(--dur) var(--ease),
                   background var(--dur) var(--ease); }
.btn:hover { border-color: var(--accent); color: var(--accent);
             background: color-mix(in srgb, var(--accent) 10%, transparent); }
.btn--solid { background: var(--accent); border-color: var(--accent);
              color: var(--accent-ink); }
.btn--solid:hover { background: var(--accent); color: var(--accent-ink);
                    filter: brightness(1.08); }
.btn svg { width: 15px; height: 15px; }

/* ==========================================================================
   COMPOSITION
   The page was typeset, not composed: no focal point, no change of scale, no
   depth, nothing to remember. These three devices fix that without adding a
   single decorative element — each one is made of something already true.
   ========================================================================== */

/* ---- 1. The section address, set as a plate.
   A 12px label told you where you were. A 90px outlined numeral makes the
   page editorial, gives the eye somewhere to land, and costs no new ink: it
   is the same number the spine already uses for the tap. */
.plate { display: flex; align-items: flex-end; gap: var(--sp-3);
         margin-bottom: var(--sp-4); }
.plate__n {
  font-family: var(--font-display); font-weight: 700;
  font-size: calc(var(--d-base) * 3.1); line-height: .78;
  letter-spacing: var(--track-hero);
  color: var(--line-strong);
  transition: color .8s var(--ease), -webkit-text-stroke-color .8s var(--ease);
}
/* Outlined where it is supported; a solid hairline-gray numeral where it is
   not, rather than an invisible one. */
@supports (-webkit-text-stroke: 1px red) {
  .plate__n { color: transparent; -webkit-text-stroke: 1.5px var(--line-strong); }
  .is-live .plate__n { -webkit-text-stroke-color: var(--accent); }
}
.is-live .plate__n { color: var(--accent); }
.plate__w { font-family: var(--font-mono); font-size: var(--text-xs);
            line-height: var(--lh-label); letter-spacing: var(--track-label);
            text-transform: uppercase; color: var(--text-dim);
            padding-bottom: .5rem; }
/* A tick, not a rule across the whole column. */
.plate__rule { width: clamp(32px, 6vw, 88px); flex: none; height: 1px;
               background: var(--line); margin-bottom: .85rem; }

/* From 900px the number hangs in the margin next to the heading, so there is
   no separate row for it to leave empty. */
@media (min-width: 900px) {
  .sec__head {
    display: grid; align-items: start;
    grid-template-columns: minmax(0, 6.5rem) minmax(0, 1fr);
    column-gap: var(--gap-col);
  }
  .plate { grid-row: 1 / span 2; flex-direction: column; align-items: flex-start;
           gap: var(--sp-2); margin-bottom: 0; }
  .plate__w { padding-bottom: 0; }
  .plate__rule { display: none; }
  .sec__title, .sec__lede { grid-column: 2; }
  .sec__lede { margin-top: var(--sp-4); }
}

/* ---------- Section scaffold -------------------------------------------- */
.sec { padding-block: var(--gap-sec); position: relative; }
.sec + .sec { border-top: 1px solid var(--line); }
.sec__head { margin-bottom: calc(var(--gap-head) * 0.72); }
.sec__title { font-size: var(--d-3); max-width: 30ch; }
.sec__lede { margin-top: var(--sp-4); color: var(--text-muted);
             font-size: var(--text-lg); line-height: var(--lh-snug);
             letter-spacing: var(--track-text); max-width: 58ch; }

/* ---------- Hero -------------------------------------------------------- */
.hero { padding-block: var(--gap-sec); }
.hero__kicker { color: var(--accent); margin-bottom: var(--sp-6);
                display: flex; align-items: center; gap: var(--sp-3); }
.hero__kicker::after { content: ""; flex: 1; height: 1px;
                       background: var(--line); max-width: 180px; }
.hero__name { font-size: var(--d-5); font-weight: 700;
              line-height: var(--lh-hero); letter-spacing: var(--track-hero);
              margin-bottom: var(--sp-5);
              display: flex; flex-direction: column; align-items: flex-start; }
/* The surname is set on its own line and left alone. Two attempts at a mark
   beside it — a chevron, then a rule that lifted — both read as decoration
   stuck to a name, which is what they were. The name carries itself. */
.hero__name span { display: inline-block; }
.hero__role { font-family: var(--font-mono); font-size: var(--text-sm);
              line-height: var(--lh-label); letter-spacing: 0;
              color: var(--text-muted); margin-bottom: var(--sp-6); }
.hero__role b { color: var(--text); font-weight: 500; }
.hero__lede { font-size: var(--text-xl); line-height: var(--lh-snug);
              letter-spacing: var(--track-text); color: var(--text); max-width: 44ch; }
.hero__lede + .hero__lede { margin-top: var(--sp-4); font-size: var(--text-md);
                            line-height: var(--lh-body); letter-spacing: 0;
                            color: var(--text-muted); max-width: var(--measure); }
.hero__act { display: flex; flex-wrap: wrap; gap: var(--sp-3); margin-top: var(--sp-6); }

.hero .hero__lede { max-width: 46ch; }

/* ---------- Matrix: one component, used for every key/value block -------
   The hero facts, the skills table and the about facts are the same object.
   Three uses, one definition: that is what keeps a page looking designed
   rather than assembled. */
.matrix { margin-top: var(--gap-head); border-top: 1px solid var(--line); }
.matrix div { position: relative;
              display: grid; grid-template-columns: 11rem 1fr; gap: var(--sp-5);
              padding-block: var(--sp-4); border-bottom: 1px solid var(--line); }
.matrix dt { color: var(--text-dim); padding-top: .2em; }
.matrix dd { margin: 0; font-size: var(--text-md); color: var(--text); }
.matrix dd em { font-style: normal; color: var(--text-muted); }
.matrix mark { background: none; color: var(--amber); font-weight: 500; }

/* ---------- A statement, set large. One per section at most. ------------ */
.statement { font-family: var(--font-display); font-weight: 500;
             font-size: var(--d-4); line-height: var(--lh-statement);
             letter-spacing: var(--track-display);
             max-width: 34ch; margin-bottom: var(--gap-head); }
.statement b { font-weight: 600; color: var(--accent); }

/* ---------- Prose blocks ------------------------------------------------ */
.blocks { display: grid; gap: var(--gap-col) var(--gap-col); }
@media (min-width: 1000px) { .blocks { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.block__label { display: block; font-family: var(--font-mono);
                font-size: var(--text-xs); line-height: var(--lh-label);
                letter-spacing: var(--track-label); text-transform: uppercase;
                color: var(--accent); margin-bottom: var(--sp-3);
                padding-bottom: var(--sp-3); border-bottom: 1px solid var(--line); }
.block p { color: var(--text-muted); max-width: 56ch; }
.block p + p { margin-top: var(--sp-4); }
.block b { color: var(--text); font-weight: 600; }

/* ---------- Scrollbars ---------------------------------------------------
   Three things on this site scroll inside themselves: the console, a wide
   figure and the token table. Left alone, the browser paints its default bar
   — a bright slab down the side of a dark terminal, which is the loudest
   thing on the page and belongs to no part of the design. Thin, in the line
   color, on no track. */
.sh__out, .wfig__scroll, .tbl {
  scrollbar-width: thin;
  scrollbar-color: var(--line-strong) transparent;
}
.sh__out::-webkit-scrollbar,
.wfig__scroll::-webkit-scrollbar,
.tbl::-webkit-scrollbar { width: 8px; height: 8px; }
.sh__out::-webkit-scrollbar-track,
.wfig__scroll::-webkit-scrollbar-track,
.tbl::-webkit-scrollbar-track { background: transparent; }
.sh__out::-webkit-scrollbar-thumb,
.wfig__scroll::-webkit-scrollbar-thumb,
.tbl::-webkit-scrollbar-thumb { background: var(--line-strong); }
.sh__out::-webkit-scrollbar-thumb:hover,
.wfig__scroll::-webkit-scrollbar-thumb:hover,
.tbl::-webkit-scrollbar-thumb:hover { background: var(--accent); }

/* ---------- The highlight ------------------------------------------------
   A hovered item's tint bleeds a little past the item's own box — wider than
   the text, taller than the padding — so it reads as the whole thing being
   picked out rather than a rectangle drawn exactly around the content. It
   sits on a negative layer, so every separator rule on the page still draws
   on top of it instead of being painted over. One definition for the work
   rows, the resume and contact cards, and every key/value line. */
.row::before, .doc::before, .matrix div::before {
  content: ""; position: absolute; z-index: -1; pointer-events: none;
  /* Sideways bleed stays under --branch, the gap between the content column
     and the spine, so a highlight never reaches across and tints the line. */
  inset: calc(-1 * var(--sp-2)) calc(-1 * var(--sp-3));
  background: transparent;
  transition: background var(--dur) var(--ease);
}
.row:hover::before, .doc:hover::before, .matrix div:hover::before {
  background: color-mix(in srgb, var(--accent) 5%, var(--surface));
}

/* ---------- Work register ----------------------------------------------- */
.reg { border-top: 1px solid var(--line); }
/* The register carried its own 01..07 inside a section already titled 01, so
   the page ran two numbering systems one inside the other. The section keeps
   its number, because that is the address the whole page is built on; the
   items under it are identified by their titles, which is what gets read. */
.row { position: relative;
       display: grid; grid-template-columns: minmax(0, 1fr);
       gap: var(--sp-4) var(--gap-col); align-items: start;
       padding-block: var(--gap-row); border-bottom: 1px solid var(--line);
       transition: background var(--dur) var(--ease); }
@media (min-width: 900px) {
  .row { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.25fr); }
  .row__text { grid-column: 2; grid-row: 1; }
  .row__tags { grid-column: 2; grid-row: 2; margin-top: calc(-1 * var(--sp-2)); }
}
@media (min-width: 1240px) {
  .row { grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr) 10rem; }
  .row__tags { grid-column: 3; grid-row: 1; margin-top: 0; }
}
.row__title { font-size: var(--d-1); }
.row__meta { display: block; margin-top: var(--sp-3); color: var(--accent); }
.row__text { color: var(--text-muted); font-size: var(--text-md);
             line-height: var(--lh-body); max-width: 54ch; }
.row__text b { color: var(--text); font-weight: 600; }
.row__tags { display: flex; flex-wrap: wrap; gap: var(--sp-2); }
.row__tags span { font-family: var(--font-mono); font-size: var(--text-xs);
                  line-height: var(--lh-label); letter-spacing: 0;
                  color: var(--text-dim); border: 1px solid var(--line);
                  padding: .2rem .45rem; }
/* Two rows carry the weight; one step up, never two, and never up to the
   section title's size. */
.row--lead .row__title { font-size: var(--d-2); }
.row--lead .row__text { font-size: var(--text-lg); line-height: var(--lh-snug);
                        letter-spacing: var(--track-text); color: var(--text); }
/* The one interaction on the page: a row draws its own rule, left to right,
   because it is a segment of the same line — not a card lifting off a page. */
.row::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px;
              height: 1px; background: var(--accent); transform: scaleX(0);
              transform-origin: left center; transition: transform .45s var(--ease); }
.row:hover::after { transform: scaleX(1); }

/* ---------- Public work: the register, with an install line -------------- */
.row__install { grid-column: 1; display: inline-flex; align-items: center;
                gap: var(--sp-2); margin-top: var(--sp-3);
                padding: var(--sp-2) var(--sp-3);
                background: var(--bg-sunken); border: 1px solid var(--line);
                font-family: var(--font-mono); font-size: var(--text-sm);
                color: var(--text); max-width: 100%; overflow-x: auto;
                white-space: nowrap; }
.row__install::before { content: "$"; color: var(--accent); flex: none; }
/* A workflow reference is a YAML key, not a shell command: no prompt. */
.row__install--yaml::before { content: ">"; }

/* Where to go and get it. Underlined on hover from the left, like the row's
   own rule, so the two gestures agree. */
.row__links { grid-column: 1; display: flex; flex-wrap: wrap; gap: var(--sp-4);
              margin-top: var(--sp-3); }
.row__links a { position: relative; font-family: var(--font-mono);
                font-size: var(--text-xs); line-height: var(--lh-label);
                letter-spacing: var(--track-label); text-transform: uppercase;
                color: var(--text-dim);
                transition: color var(--dur) var(--ease); }
.row__links a::after { content: ""; position: absolute; left: 0; right: 0;
                       bottom: -3px; height: 1px; background: var(--accent);
                       transform: scaleX(0); transform-origin: left center;
                       transition: transform var(--dur) var(--ease); }
.row__links a:hover { color: var(--accent); }
.row__links a:hover::after { transform: scaleX(1); }

/* A closing line under a register, set apart from the rows it follows. */
.sec__after { margin-top: var(--gap-head); color: var(--text-muted);
              font-size: var(--text-md); max-width: 62ch; }
.sec__after a { color: var(--accent);
                box-shadow: inset 0 -1px 0 color-mix(in srgb, var(--accent) 40%, transparent); }
.sec__after a:hover { box-shadow: inset 0 -1px 0 var(--accent); }

/* ---------- Path -------------------------------------------------------- */
.job { padding-block: var(--gap-row); }
.job + .job { border-top: 1px solid var(--line); }
.job__grid { display: grid; grid-template-columns: minmax(0, 20rem) minmax(0, 1fr);
             gap: var(--gap-col); align-items: start; }
.job__co { font-size: var(--d-1); }
.job__when { display: block; margin-top: var(--sp-2);
             font-family: var(--font-mono); font-size: var(--text-sm);
             line-height: var(--lh-label); letter-spacing: 0; color: var(--text-dim); }
.job__role { color: var(--accent); margin-bottom: var(--sp-4); }
.job__role + .job__role { margin-top: var(--sp-5); }
.job__list li { position: relative; padding-left: var(--sp-5);
                color: var(--text-muted); font-size: var(--text-md);
                line-height: var(--lh-body); max-width: var(--measure); }
.job__list li + li { margin-top: var(--sp-3); }
.job__list li::before { content: ""; position: absolute; left: 0; top: .78em;
                        width: 10px; height: 1px; background: var(--line-strong); }
.job__list b { color: var(--text); font-weight: 600; }

/* ---------- Documents --------------------------------------------------- */
.docs { border-top: 1px solid var(--line); }
.doc { position: relative; display: grid; grid-template-columns: 1fr;
       gap: var(--sp-3) var(--gap-col); align-items: center;
       padding-block: var(--gap-row); border-bottom: 1px solid var(--line);
       transition: background var(--dur) var(--ease); }
@media (min-width: 760px) {
  .doc { grid-template-columns: minmax(0, 1fr) 14rem auto; }
}
.doc__name { font-size: var(--text-md); font-weight: 600; color: var(--text); }
.doc__for { display: block; margin-top: var(--sp-1); font-size: var(--text-sm);
            color: var(--text-muted); }
.doc__specs { display: flex; flex-wrap: wrap; gap: var(--sp-2);
              font-family: var(--font-mono); font-size: var(--text-xs);
              letter-spacing: 0; color: var(--text-dim); }
.doc__specs span { border: 1px solid var(--line); padding: .2rem .45rem; }

/* ---------- Close: the line leaves the page ----------------------------- */
.close { padding-block: var(--gap-sec) calc(var(--gap-sec) + clamp(72px, 10vw, 130px)); }
.close__title { font-size: var(--d-3); max-width: 26ch; margin-bottom: var(--sp-5); }
.close__text { color: var(--text-muted); font-size: var(--text-lg);
               line-height: var(--lh-snug); letter-spacing: var(--track-text);
               max-width: 52ch; margin-bottom: var(--sp-7); }

footer { border-top: 1px solid var(--line); padding-block: var(--sp-6);
         margin-top: 0;
         font-family: var(--font-mono); font-size: var(--text-xs);
         line-height: var(--lh-label); letter-spacing: 0; color: var(--text-dim);
         display: flex; flex-wrap: wrap; gap: var(--sp-4);
         justify-content: space-between; }

.mark__name { display: flex; flex-direction: column; gap: 2px; }
.mark__role { font-style: normal; font-size: 0.625rem; letter-spacing: var(--track-label);
              color: var(--text-dim); }
@media (max-width: 760px) { .mark__role { display: none; } }

/* ---------- Hero meta strip --------------------------------------------- */
.hero__meta { display: flex; flex-wrap: wrap; gap: var(--sp-3) var(--sp-6);
              margin-bottom: var(--sp-6);
              font-family: var(--font-mono); font-size: var(--text-xs);
              letter-spacing: var(--track-label); text-transform: uppercase;
              color: var(--text-dim); }
.hero__meta span { display: inline-flex; align-items: center; gap: var(--sp-2); }
.hero__meta svg { width: 13px; height: 13px; color: var(--accent); }

/* The console's title bar keeps the one glyph worth keeping. */
.term__dot { width: 7px; height: 7px; border: 1px solid var(--line-strong);
             transform: rotate(45deg); }

/* ---------- Per-job technology row -------------------------------------- */
.job__tags { display: flex; flex-wrap: wrap; gap: var(--sp-2); margin-top: var(--sp-4); }
.job__tags span { font-family: var(--font-mono); font-size: var(--text-xs);
                  line-height: var(--lh-label); letter-spacing: 0;
                  color: var(--text-dim); border: 1px solid var(--line);
                  padding: .2rem .45rem; }

/* ---------- Document region line ---------------------------------------- */
.doc__region { display: block; margin-top: var(--sp-1);
               font-family: var(--font-mono); font-size: var(--text-xs);
               letter-spacing: var(--track-label); text-transform: uppercase;
               color: var(--accent); }


/* ---------- The console: a real shell, not a picture of one ------------- */
.sh { margin-top: var(--gap-head); border: 1px solid var(--line-strong);
      background: var(--bg-sunken); font-family: var(--font-mono);
      font-size: var(--text-sm); display: flex; flex-direction: column;
      max-width: 92ch; }
.sh__bar { display: flex; align-items: center; gap: var(--sp-3);
           padding: var(--sp-2) var(--sp-3); border-bottom: 1px solid var(--line);
           color: var(--text-dim); font-size: var(--text-xs); letter-spacing: 0; }
.sh__hint { margin-left: auto; }
.sh__hint b { color: var(--accent); font-weight: 500; }
.sh__out { padding: var(--sp-4); line-height: 1.75;
           height: clamp(19rem, 42vh, 26rem); flex: none;
           overflow-y: auto; overscroll-behavior: contain; }
.sh__line { display: block; white-space: pre-wrap; word-break: break-word; }
.sh__line--cmd { color: var(--text); }
.sh__line--cmd b { color: var(--accent); font-weight: 500; }
.sh__line--dim { color: var(--text-dim); }
.sh__line--key { color: var(--accent); }
.sh__line--warn { color: var(--amber); }
.sh__in { display: flex; align-items: center; gap: var(--sp-2);
          padding: var(--sp-3) var(--sp-4); border-top: 1px solid var(--line);
          background: color-mix(in srgb, var(--accent) 4%, transparent); }
.sh__p { color: var(--accent); flex: none; }
.sh__field { flex: 1; min-width: 0; background: none; border: 0; outline: none;
             color: var(--text); font: inherit; caret-color: var(--accent); padding: 0; }
.sh__field::placeholder { color: var(--text-dim); }
.sh__keys { display: flex; flex-wrap: wrap; gap: var(--sp-2); margin-top: var(--sp-4); }
.sh__key { font-family: var(--font-mono); font-size: var(--text-xs); letter-spacing: 0;
           padding: .3rem .55rem; background: transparent; cursor: pointer;
           color: var(--text-dim); border: 1px solid var(--line);
           transition: color var(--dur) var(--ease), border-color var(--dur) var(--ease); }
.sh__key:hover { color: var(--accent); border-color: var(--accent); }
.sec__lede code { font-family: var(--font-mono); font-size: .92em; color: var(--accent); }
@media (max-width: 560px) {
  .sh { font-size: var(--text-xs); }
  .sh__out { padding: var(--sp-3); }
  .sh__hint { display: none; }
}


/* ---------- The console, as the interface rather than a section --------- */
/* The hero was a column of text in a 1600px shell with its whole right side
   empty. The pitch and the thing that proves it are one idea, so they share
   one zone: the argument on the left, a live shell on the right, both above
   the fold. It stacks below 1100, where a terminal needs the full width to
   be usable. */
.topzone { position: relative; }
@media (min-width: 1400px) {
  .topzone { display: grid; grid-template-columns: minmax(0, .84fr) minmax(0, 1.16fr);
             gap: calc(var(--gap-col) * 1.4); align-items: stretch;
             padding-block: var(--gap-sec) var(--gap-sec); }
  .topzone .hero { padding-block: 0; display: flex; flex-direction: column;
                   justify-content: center; }
  .topzone .hero.node { --node-y: 0.55rem; }
  .topzone .console { padding-block: 0; display: flex; flex-direction: column;
                      justify-content: center; }
  /* The branch belongs to the zone, not to each half. */
  .topzone .console .node::before, .topzone .console .node::after { display: none; }
  .hero__act { margin-top: var(--sp-5); }
  .hero .matrix div { grid-template-columns: 8.5rem 1fr; gap: var(--sp-4); }
}
@media (min-width: 760px) and (max-width: 1399.98px) {
  .hero .matrix { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
                  border-bottom: 1px solid var(--line); }
  .hero .matrix div { display: block; border-bottom: 0;
                      padding: var(--sp-4) var(--sp-5) var(--sp-4) 0; }
  .hero .matrix div + div { border-left: 1px solid var(--line);
                            padding-left: var(--sp-5); }
  .hero .matrix div:hover::before { background: transparent; }
  .hero .matrix dt { margin-bottom: var(--sp-2); padding-top: 0; }
}
.console { padding-block: 0 var(--gap-sec); position: relative; }
.console .sh { margin-top: 0; max-width: none; border-color: var(--line-strong); }
/* One definite height, in every layout. A console is a window of a fixed size
   that you scroll inside; it must not grow when it answers you, or the page
   under it moves every time a command is run. The clamp tracks the viewport,
   never the content. The phone case follows immediately, so it wins on order
   rather than on a specificity trick that the next edit would undo. */
.console .sh__out { height: clamp(22rem, 46vh, 30rem); }
@media (max-width: 560px) { .console .sh__out { height: 17rem; } }
/* Stacked under the hero, the console starts folded to its prompt and
   shortcuts; the first command run unfolds the output (main.js). Beside the
   hero, at 1400 and up, it is always open because it costs no scroll. */
@media (max-width: 1399.98px) {
  .console:not(.is-live) .sh__out { display: none; }
}
.hero { padding-bottom: var(--sp-6); }

/* ---------- Featured schematics -----------------------------------------
   Two of the register's claims are diagrams by nature: drawn they are
   evidence, described they are adjectives. They were capped at 64rem inside
   the register's flow while the column runs to 1700, so they now get the
   full width as framed plates — a header that names the figure, the drawing
   at the scale it deserves, and the claim underneath. */
.wfig { display: block; margin: var(--gap-row) 0;
        background: var(--surface); border: 1px solid var(--line);
        padding: var(--gap-row) var(--gap-col); }
.wfig__head { display: flex; align-items: baseline; gap: var(--sp-4);
              margin-bottom: var(--gap-row); }
.wfig__n { font-family: var(--font-mono); font-size: var(--text-xs);
           letter-spacing: var(--track-label); text-transform: uppercase;
           color: var(--accent); flex: none; }
.wfig__t { font-family: var(--font-display); font-size: var(--d-1);
           font-weight: 600; letter-spacing: var(--track-display);
           line-height: var(--lh-display); }
.wfig__rule { flex: 1; height: 1px; background: var(--line); }
.wfig__tags { font-family: var(--font-mono); font-size: var(--text-xs);
              letter-spacing: var(--track-label); text-transform: uppercase;
              color: var(--text-dim); flex: none; }
/* The drawing fills the plate. Below 880px the plate scrolls sideways
   instead of scaling the drawing down, because a viewBox shrinks its labels
   along with everything else — at 760px the type had fallen to 6px. A
   technical figure is better swiped than made illegible. */
.wfig__cap { color: var(--text-muted); font-size: var(--text-md);
             line-height: var(--lh-body); max-width: 58ch; }
.wfig__cap b { color: var(--text); font-weight: 600; }
.wfig__scroll { overflow-x: auto; overscroll-behavior-x: contain;
                margin-bottom: var(--gap-row);
                scrollbar-width: thin; }
.wfig__svg { display: block; width: 100%; min-width: 880px; height: auto;
             overflow: visible; }
.wfig__svg text { font-family: var(--font-mono); font-size: 13px;
                  letter-spacing: .09em; fill: var(--text-dim); }
.wfig__svg .on { fill: var(--accent); }
.wfig__svg .dim { fill: var(--text-dim); font-size: 11px; }
.wfig__svg .box--ghost { stroke-dasharray: 3 3; }
.wfig__svg .diff { opacity: .9; }
.wfig__svg .diff--in { fill: color-mix(in srgb, var(--accent) 55%, transparent); }
.wfig__svg .diff--out { fill: color-mix(in srgb, var(--amber) 45%, transparent); }
.wfig__svg .axis { stroke: var(--line); stroke-width: 1.25; }
/* Interface furniture: title bars, dividers, and the suggestion of content. */
.wfig__svg .rule { stroke: var(--line); stroke-width: 1; }
.wfig__svg .rule--on { stroke: color-mix(in srgb, var(--accent) 50%, var(--line)); }
.wfig__svg .pane { fill: color-mix(in srgb, var(--text-dim) 30%, transparent); }
.wfig__svg .pane--on { fill: color-mix(in srgb, var(--accent) 45%, transparent); }
.wfig__svg .thresh { stroke: var(--amber); stroke-width: 1.25; stroke-dasharray: 4 4; }

.wfig__svg .bar { transform-box: fill-box; transform-origin: left center; transform: scaleX(0); }
.is-in .wfig__svg .bar { animation: barin .9s var(--ease) forwards;
                         animation-delay: calc(.35s + var(--i, 0) * .22s); }
@keyframes barin { to { transform: scaleX(1); } }
.wfig__svg .bar--on { fill: var(--accent); }
.wfig__svg .bar--warn { fill: color-mix(in srgb, var(--amber) 80%, transparent); }
.wfig__svg .warn { fill: var(--amber); }
.wfig__svg .box { fill: none; stroke: var(--line); stroke-width: 1.25; }
.wfig__svg .box--on { stroke: color-mix(in srgb, var(--accent) 60%, var(--line)); }
.wfig__svg .box--warn { stroke: color-mix(in srgb, var(--amber) 60%, var(--line)); }
.wfig__svg .wire {
  fill: none; stroke: var(--line-strong); stroke-width: 1.5;
  /* The fallback must exceed the longest wire on the page, or the tail of a
     long one lands in the dash gap and the line appears to stop short. */
  stroke-dasharray: var(--len, 800); stroke-dashoffset: var(--len, 800);
  transition: stroke-dashoffset 1.2s var(--ease) var(--wd, 0s);
}
.is-in .wfig__svg .wire { stroke-dashoffset: 0; }
.wfig__tok { fill: var(--accent); opacity: 0; }
/* Twice, then it stops. A figure sits in the middle of something you are
   reading; a dot going round it forever is something you have to look away
   from. The keyframes end at zero opacity, so the resting state is the drawn
   wire with no token on it. */
.is-in .wfig__tok { animation: tok 4.6s linear 1.1s 2 forwards; }
@keyframes tok {
  0%   { transform: translateX(0);     opacity: 0; }
  5%   { opacity: 1; }
  95%  { opacity: 1; }
  100% { transform: translateX(780px); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .wfig__svg .wire { stroke-dashoffset: 0; }
  .is-in .wfig__tok { animation: none; opacity: 1; }
  .wfig__svg .bar, .is-in .wfig__svg .bar { transform: none; animation: none; }
}

/* ---------- The career strip ------------------------------------------- */
.strip { margin: 0 0 var(--gap-head); }
.strip__svg { display: block; width: 100%; max-width: 64rem; height: auto; overflow: visible; }
.strip__axis, .strip__tick { stroke: var(--line); stroke-width: 1; }
.strip__bar { fill: color-mix(in srgb, var(--accent) 42%, transparent); }
.strip__bar--now { fill: var(--accent); }
.strip__bar--alt { fill: none; stroke: var(--accent); stroke-width: 1;
                   stroke-dasharray: 3 3; }
.strip__lbl { font-family: var(--font-mono); font-size: 10.5px;
              letter-spacing: .09em; fill: var(--text-muted); }
.strip__lbl.on { fill: var(--accent); }
.strip__yr { font-family: var(--font-mono); font-size: 10.5px;
             letter-spacing: .06em; fill: var(--text-dim); }
.strip__cap { color: var(--text-muted); font-size: var(--text-md);
              max-width: 56ch; margin-top: var(--sp-4); }
.strip__cap b { color: var(--text); font-weight: 600; }
/* Grows when its tab is opened, and again each time it is reopened. */
.panel .strip__bar { transform: scaleX(0); transform-origin: left center; }
.panel.is-on .strip__bar { animation: grow .7s var(--ease) forwards;
                           animation-delay: calc(var(--i, 0) * 90ms); }
@keyframes grow { to { transform: scaleX(1); } }
@media (prefers-reduced-motion: reduce) {
  .panel .strip__bar, .panel.is-on .strip__bar { transform: none; animation: none; }
}

/* ---------- Dossier: five files, one surface --------------------------- */
.tabs { display: flex; flex-wrap: wrap; gap: var(--sp-1);
        border-bottom: 1px solid var(--line); margin-bottom: var(--gap-head); }
.tab { font-family: var(--font-mono); font-size: var(--text-xs);
       letter-spacing: var(--track-label); text-transform: uppercase;
       padding: .7rem .9rem; margin-bottom: -1px; background: none; border: 0;
       border-bottom: 2px solid transparent; color: var(--text-dim);
       cursor: pointer; transition: color var(--dur) var(--ease),
       border-color var(--dur) var(--ease); }
.tab:hover { color: var(--text); }
.tab[aria-selected="true"] { color: var(--accent); border-bottom-color: var(--accent); }
.panel[hidden] { display: none; }
/* A panel has no plate and no spine beside it, so its head is a plain block
   and the branches that pointed at the line are suppressed. */
.panel .sec__head { display: block; margin-bottom: var(--gap-head); }
.panels .node::before, .panels .node::after { display: none; }
/* Panels are revealed by their tab, not by scrolling. Resetting the entrance
   states here also stops them replaying every time a tab is clicked. */
.panels .sec__title, .panels .sec__lede, .panels .statement, .panels .blocks,
.panels .matrix, .panels .job, .panels .doc, .panels .row, .panels .legend {
  opacity: 1; transform: none; clip-path: none; transition: none;
}

/* ---------- Skills legend ----------------------------------------------- */
.legend { display: flex; flex-wrap: wrap; gap: var(--sp-3) var(--sp-6);
          margin-bottom: var(--gap-head); padding-bottom: var(--sp-4);
          border-bottom: 1px solid var(--line);
          font-size: var(--text-sm); color: var(--text-muted); }
.legend span { display: inline-flex; align-items: baseline; gap: var(--sp-2); }
.legend b { color: var(--accent); font-weight: 600; }
.legend i { font-style: normal; color: var(--text); font-weight: 500; }
/* A highlighted item in the matrix means the same thing the legend says. */
.matrix dd b { color: var(--accent); font-weight: 500; }

/* ---------- Channels: the register shape, with an action ---------------- */
.chan__val { font-family: var(--font-mono); font-size: var(--text-sm);
             letter-spacing: 0; color: var(--text-muted);
             display: block; margin-top: var(--sp-1); word-break: break-all; }
.chan__act { display: flex; gap: var(--sp-2); align-items: center; }
.copied { color: var(--accent); }

/* ---------- Chrome the page was missing -------------------------------- */
.skip { position: absolute; left: var(--sp-4); top: -100px; z-index: 200;
        padding: var(--sp-3) var(--sp-5); background: var(--accent);
        color: var(--accent-ink); font-weight: 600;
        transition: top var(--dur) var(--ease); }
.skip:focus { top: var(--sp-4); }

.nav-toggle { display: none; }
.nav-toggle svg { width: 18px; height: 18px; }

.to-top { position: fixed; right: clamp(1rem, 3vw, 2.5rem);
          bottom: clamp(1rem, 3vw, 2.5rem); z-index: 60;
          width: 44px; height: 44px; display: grid; place-items: center;
          background: color-mix(in srgb, var(--bg) 85%, transparent);
          backdrop-filter: blur(8px);
          border: 1px solid var(--line-strong); color: var(--text-muted);
          cursor: pointer; opacity: 0; pointer-events: none;
          transform: translateY(8px);
          transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease),
                      color var(--dur) var(--ease), border-color var(--dur) var(--ease); }
.to-top.is-on { opacity: 1; pointer-events: auto; transform: none; }
.to-top:hover { color: var(--accent); border-color: var(--accent); }
.to-top svg { width: 18px; height: 18px; }

/* The caret belongs to a page whose author lives in a terminal — but a caret
   next to a line that has stopped being written is just a blinking light. It
   is present only while the line is actually filling, which is the one moment
   it means anything. With no script at all it never appears. */
.caret { display: inline-block; width: 2px; height: 1em; margin-left: 3px;
         background: var(--accent); vertical-align: -0.12em; opacity: 0; }
.is-typing .caret { animation: blink 1.1s steps(2, start) infinite; }
@keyframes blink { 0%, 50% { opacity: 1; } 50.01%, 100% { opacity: 0; } }

/* ==========================================================================
   MOTION
   One rule, no exceptions: the line arrives, then the content it came for.
   Nothing animates because it entered the viewport — a block animates when
   the DRAWN EDGE OF THE SPINE reaches its node. The scroll is not a trigger
   for decoration; it is the signal travelling the wire.
   ========================================================================== */

/* The mark draws its own construction, once, on load. --len is measured from
   the real geometry, because the arch is a 38-unit arc and the wing a bezier:
   a guessed dash length would be visibly wrong. */
.mark svg g path { stroke-dasharray: var(--len, 1000); stroke-dashoffset: var(--len, 1000);
                   animation: draw 1.15s var(--ease) .15s forwards; }
.mark svg g path + path { animation-duration: .75s; animation-delay: .72s; }
.mark svg > path:last-child { opacity: 0; transform-box: fill-box;
                              transform-origin: 50% 50%;
                              animation: land .55s var(--ease) 1.15s forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes land { from { opacity: 0; transform: translate(-9px, 5px) rotate(-10deg) scale(.72); }
                  to   { opacity: 1; transform: none; } }

/* Then the block, in reading order. A title is wiped upward rather than
   faded, so the line feels like it is writing the page. */
.plate, .sec__title, .sec__lede, .statement, .blocks, .matrix,
.hero__kicker, .hero__role, .hero__lede, .hero__act,
.close__title, .close__text {
  opacity: 0; transform: translateY(12px);
  transition: opacity .65s var(--ease) calc(var(--d, 0s) * var(--d-mult)),
              transform .65s var(--ease) calc(var(--d, 0s) * var(--d-mult));
}
.is-shown .plate, .is-shown .sec__title, .is-shown .sec__lede,
.is-shown .statement, .is-shown .blocks, .is-shown .matrix,
.is-shown .hero__kicker, .is-shown .hero__role, .is-shown .hero__lede,
.is-shown .hero__act, .is-shown .close__title, .is-shown .close__text { opacity: 1; transform: none; }

.sec__title, .close__title, .statement {
  clip-path: inset(0 0 102% 0);
  transition: opacity .7s var(--ease) calc(var(--d, 0s) * var(--d-mult)),
              transform .7s var(--ease) calc(var(--d, 0s) * var(--d-mult)),
              clip-path .85s var(--ease) calc(var(--d, 0s) * var(--d-mult));
}
.is-shown .sec__title, .is-shown .close__title, .is-shown .statement {
  clip-path: inset(-28% 0 -28% 0);
}

.plate { --d: .10s; } .sec__title { --d: .20s; } .sec__lede { --d: .34s; }
.statement { --d: .16s; } .blocks { --d: .22s; } .matrix { --d: .26s; }
.hero__kicker { --d: .10s; } .hero__role { --d: .20s; }
.hero__lede { --d: .28s; } .hero__lede + .hero__lede { --d: .36s; }
.hero__act { --d: .46s; }
.close__title { --d: .18s; } .close__text { --d: .30s; }

.row, .job, .doc, .wfig {
  opacity: 0; transform: translateY(16px);
  transition: opacity .6s var(--ease) calc(var(--d, 0s) * var(--d-mult)),
              transform .6s var(--ease) calc(var(--d, 0s) * var(--d-mult));
}
.row.is-in, .job.is-in, .doc.is-in, .wfig.is-in { opacity: 1; transform: none; }

/* ---------- Narrow screens ---------------------------------------------- */
@media (max-width: 1000px) {
  .matrix div { grid-template-columns: 9rem 1fr; gap: var(--sp-4); }
}
@media (max-width: 900px) {
  :root { --d-mult: 0.7; }
  .row__text { max-width: none; }
  .job__grid { grid-template-columns: 1fr; gap: var(--sp-5); }

  /* A drawer, not six bare numbers. The spine's own node list, stacked. */
  .nav-toggle { display: inline-grid; place-items: center; width: 44px; height: 44px; }
  .ticks {
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    margin: 0; padding: var(--sp-4) var(--gutter) var(--sp-6);
    background: var(--bg); border-bottom: 1px solid var(--line);
    transform: translateY(-8px); opacity: 0; visibility: hidden;
    transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease),
                visibility var(--dur);
  }
  .ticks.is-open { transform: none; opacity: 1; visibility: visible; }
  .tick { gap: var(--sp-3); padding-block: var(--sp-4);
          border-bottom: 1px solid var(--line); font-size: var(--text-sm); }
  /* The theme switch and the menu stay; only the Resume call to action
     stands down, because it is repeated twice further down the page. */
  .top__act .btn--solid { display: none; }
}
@media (max-width: 700px) {
  .matrix div { grid-template-columns: 1fr; gap: var(--sp-1); }
  .matrix dt { padding-top: 0; }
}
@media (max-width: 560px) {
  :root { --d-mult: 0.5; }
  .doc { grid-template-columns: 1fr; gap: var(--sp-3); }
  .mark__name { display: none; }
  .hero__lede, .statement { max-width: none; }
}

/* Reduced motion: every start state is reset to its finished state. Turning
   the animations off is not enough — a wiped title would stay wiped and the
   page would be half invisible. */
@media (prefers-reduced-motion: reduce) {
  .mark svg g path { stroke-dasharray: none; stroke-dashoffset: 0; animation: none; }
  .mark svg > path:last-child { opacity: 1; animation: none; }
  .node::before { transform: scaleX(1); }
  .node::after { transform: rotate(45deg) scale(1); animation: none; }
  .plate, .sec__title, .sec__lede, .statement, .blocks, .matrix,
  .hero__kicker, .hero__role, .hero__lede, .hero__act, .close__title,
  .close__text, .row, .job, .doc, .wfig { opacity: 1; transform: none; }
  .sec__title, .close__title, .statement { clip-path: none; }
  .plate__n { -webkit-text-stroke-color: var(--accent); }
  .row::after { display: none; }
  .caret { animation: none; opacity: 0; }
  .wfig__tok { animation: none; opacity: 0; }
  * { transition-duration: .01ms !important; animation-duration: .01ms !important; }
  html { scroll-behavior: auto; }
}
html {
  scroll-behavior: smooth;
  /* The header is sticky and 72px tall, so every jump to an anchor — a nav
     tap, the console's `open` command, a skip link — landed the target's
     first 72px underneath it. The browser accounts for this only if it is
     told how much of the top is already spoken for. */
  scroll-padding-top: calc(72px + var(--sp-5));
}

/* ==========================================================================
   THE BRAND GUIDE
   Only brand.html uses what follows. It is a page about the system, so it is
   the one place that shows raw values — and it still builds them out of the
   same components as everything else.
   ========================================================================== */

/* ---- Logo variants ----------------------------------------------------- */
.tiles { display: grid; gap: var(--gap-col);
         grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr)); }
.tile { border: 1px solid var(--line); background: var(--surface);
        padding: var(--sp-6) var(--sp-5); display: flex; flex-direction: column;
        align-items: center; gap: var(--sp-5); text-align: center; }
.tile svg { width: 100%; max-width: 7.5rem; height: auto; }
.tile--paper { background: #FFFFFF; }
.tile--ink { background: #08121A; }
.tile__name { font-family: var(--font-mono); font-size: var(--text-xs);
              line-height: var(--lh-label); letter-spacing: var(--track-label);
              text-transform: uppercase; color: var(--text); }
.tile__note { display: block; margin-top: var(--sp-2); color: var(--text-dim);
              font-family: var(--font-body); font-size: var(--text-sm);
              letter-spacing: 0; text-transform: none; }
/* Those two tiles carry their own background, so their labels cannot inherit
   the page's text color. */
.tile--paper .tile__name { color: #14181B; }
.tile--paper .tile__note { color: #4C5760; }
.tile--ink .tile__name { color: #E9F1F5; }
.tile--ink .tile__note { color: #9BB0BC; }

/* ---- Color ------------------------------------------------------------- */
.swatches { display: grid; gap: var(--gap-col);
            grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); }
.swatch { border: 1px solid var(--line); background: var(--surface); }
.swatch__chip { height: 5.5rem; border-bottom: 1px solid var(--line); }
.swatch__body { padding: var(--sp-4) var(--sp-5) var(--sp-5); }
.swatch__name { font-size: var(--text-md); font-weight: 600; color: var(--text); }
.swatch__hex { margin-top: var(--sp-1); font-family: var(--font-mono);
               font-size: var(--text-sm); color: var(--accent); }
.swatch__use { margin-top: var(--sp-3); color: var(--text-muted);
               font-size: var(--text-sm); line-height: var(--lh-snug); }

/* ---- Type specimens ---------------------------------------------------- */
.spec { border-top: 1px solid var(--line); padding-block: var(--gap-row); }
.spec__meta { display: flex; flex-wrap: wrap; gap: var(--sp-2) var(--sp-5);
              font-family: var(--font-mono); font-size: var(--text-xs);
              line-height: var(--lh-label); letter-spacing: var(--track-label);
              text-transform: uppercase; color: var(--text-dim);
              margin-bottom: var(--sp-5); }
.spec__meta span:first-child { color: var(--accent); }
.spec__sample { color: var(--text); }
.spec__sample--display { font-family: var(--font-display); font-weight: 600;
                         font-size: var(--d-3); line-height: var(--lh-display);
                         letter-spacing: var(--track-display);
                         font-optical-sizing: auto; }
.spec__sample--body { font-size: var(--text-xl); line-height: var(--lh-snug);
                      letter-spacing: var(--track-text); max-width: var(--measure); }
.spec__sample--mono { font-family: var(--font-mono); font-size: var(--text-md);
                      line-height: var(--lh-body); color: var(--text-muted); }
.spec__scale { margin-top: var(--sp-4); font-family: var(--font-mono);
               font-size: var(--text-sm); color: var(--text-dim);
               word-break: break-word; }

/* ---- Do and don't ------------------------------------------------------ */
.rules { display: grid; gap: var(--gap-col); }
@media (min-width: 900px) { .rules { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.rule { border: 1px solid var(--line); background: var(--surface);
        padding: var(--sp-6); }
.rule__head { display: flex; align-items: center; gap: var(--sp-3);
              font-family: var(--font-mono); font-size: var(--text-xs);
              line-height: var(--lh-label); letter-spacing: var(--track-label);
              text-transform: uppercase; padding-bottom: var(--sp-4);
              border-bottom: 1px solid var(--line); margin-bottom: var(--sp-5); }
.rule__head svg { width: 18px; height: 18px; flex: none; }
.rule--do    { border-top: 2px solid var(--h-mint); }
.rule--dont  { border-top: 2px solid var(--h-amber); }
.rule--do   .rule__head { color: var(--h-mint); }
.rule--dont .rule__head { color: var(--h-amber); }
.rule li { color: var(--text-muted); padding-left: var(--sp-5);
           position: relative; max-width: 54ch; }
.rule li + li { margin-top: var(--sp-3); }
.rule li::before { content: ""; position: absolute; left: 0; top: .62em;
                   width: var(--sp-3); height: 1px; background: var(--line-strong); }

/* ---- The tokens, as a table -------------------------------------------- */
.tbl { overflow-x: auto; border: 1px solid var(--line); }
.tbl table { width: 100%; min-width: 40rem; border-collapse: collapse;
             font-size: var(--text-sm); }
.tbl th, .tbl td { text-align: left; padding: var(--sp-3) var(--sp-4);
                   border-bottom: 1px solid var(--line); }
.tbl thead th { font-family: var(--font-mono); font-size: var(--text-xs);
                line-height: var(--lh-label); letter-spacing: var(--track-label);
                text-transform: uppercase; color: var(--text-dim);
                background: var(--bg-sunken); font-weight: 400; }
.tbl tbody tr:last-child td { border-bottom: 0; }
.tbl tbody tr:hover { background: color-mix(in srgb, var(--accent) 4%, transparent); }
.tbl td:first-child { font-family: var(--font-mono); color: var(--accent);
                      white-space: nowrap; }
.tbl td { color: var(--text-muted); }
.tbl td:last-child { color: var(--text-dim); }

/* ---- A row of downloads ------------------------------------------------ */
.dlrow { display: flex; flex-wrap: wrap; gap: var(--sp-3); margin-top: var(--gap-head); }

/* ---------- Notes ----------------------------------------------------------
   Long-form prose: one column at reading measure, the same muted ink as the
   blocks, with the bold lines lifted to full text color. */
.note__body { max-width: var(--measure); }
.note__body p { color: var(--text-muted); font-size: var(--text-lg); line-height: 1.7; }
.note__body p + p { margin-top: var(--sp-5); }
.note__body b, .note__body em { color: var(--text); }
.note__body b { font-weight: 600; }
.note__body code { font-family: var(--font-mono); font-size: .88em; color: var(--text);
                   background: var(--surface-2); border: 1px solid var(--line);
                   padding: .05em .35em; border-radius: 4px; white-space: nowrap; }
.note__body .row__links { margin-top: var(--sp-6); }
.sec__lede a { color: var(--accent); }
