/* makeyeti.com. Direction B ("Board"): grey page, black ink, one amber signal colour; a split-flap board with real
   rows, flip-tile figures, a variable-width headline. Light and dark themes: the device setting by default, or the
   choice made with the header button (data-theme on <html>). No library; no WebGL. */
/* fonts are served from this site (both under the SIL Open Font License); nothing is loaded from a font service */
@font-face { font-family: "Archivo"; font-style: normal; font-weight: 300 900; font-stretch: 62% 125%; font-display: swap; src: url(/assets/fonts/archivo-var.woff2) format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-weight: 400; font-display: swap; src: url(/assets/fonts/plexmono-400.woff2) format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-weight: 500; font-display: swap; src: url(/assets/fonts/plexmono-500.woff2) format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-weight: 600; font-display: swap; src: url(/assets/fonts/plexmono-600.woff2) format("woff2"); }
@property --wd { syntax: "<number>"; inherits: true; initial-value: 100; }
@property --wg { syntax: "<number>"; inherits: true; initial-value: 800; }
:root {
  color-scheme: light;
  --bg: #e4e6ea;
  --ink: #0a0b0d;
  --body: #1c1e22;
  --dim: #454950;
  --line: rgba(10, 11, 13, .2);
  --rule: #0a0b0d;
  --card: #f4f5f7;
  --panel: #0a0b0d;
  --panel-ink: #f3f2ee;
  --panel-dim: #c9ccd2;
  --panel-line: rgba(255, 255, 255, .22);
  --tile: #15171b;
  --tile-ink: #f1f0ea;
  --foot: #0a0b0d;
  --amb: #ffb300;
  --amb-ink: #0a0b0d;
  --pad: clamp(18px, 4.4vw, 64px);
  --sans: "Archivo", "Arial Narrow", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, Consolas, monospace;
}
/* dark palette: the same roles, not an inversion. Panels and the board stay near-black and gain a hairline;
   cards are a step lighter than the page; amber keeps its dark ink. */
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0d0f12; --ink: #f0eee8; --body: #d6d8dd; --dim: #a9aeb8; --line: rgba(255, 255, 255, .2); --rule: #f0eee8;
  --card: #171a1f; --panel: #050607; --panel-line: rgba(255, 255, 255, .22); --tile: #22262d; --foot: #050607;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #0d0f12; --ink: #f0eee8; --body: #d6d8dd; --dim: #a9aeb8; --line: rgba(255, 255, 255, .2); --rule: #f0eee8;
    --card: #171a1f; --panel: #050607; --panel-line: rgba(255, 255, 255, .22); --tile: #22262d; --foot: #050607;
  }
}
* { box-sizing: border-box; margin: 0; }
html { background: var(--bg); -webkit-text-size-adjust: 100%; scroll-padding-top: 90px; }
body { background: var(--bg); color: var(--ink); font: 400 17px/1.5 var(--sans); overflow-x: clip; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; padding: 0; }
.skip { position: fixed; left: 12px; top: -60px; z-index: 50; background: var(--ink); color: var(--bg); padding: 10px 14px; }
.skip:focus { top: 12px; }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
.foot :focus-visible, .ui :focus-visible { outline-color: var(--amb); }

/* nav */
.nav { position: fixed; z-index: 20; top: 0; left: 0; right: 0; height: 66px; display: flex; align-items: center; gap: 10px; padding: 0 var(--pad); background: var(--bg); border-bottom: 1px solid var(--line); }
.brand { margin-right: auto; display: block; color: var(--ink); flex: none; }
/* the logo (J4): one drawing, coloured by ground. Light ground: all ink. Dark ground: amber M, white letters.
   Amber is never used on a light ground (1.79:1). */
.wm { display: block; height: 34px; width: auto; overflow: visible; --logo-m: #0E1726; --logo-ink: #0E1726; }
.wm .wm-m { fill: var(--logo-m); }
.wm .wl, .wm .wdot { fill: var(--logo-ink); }
:root[data-theme="dark"] .wm, .foot .wm { --logo-m: #FFB300; --logo-ink: #FFFFFF; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .wm { --logo-m: #FFB300; --logo-ink: #FFFFFF; } }
.nav nav { display: flex; gap: 2px; font: 500 12.5px/1 var(--mono); text-transform: uppercase; letter-spacing: .03em; }
.nav nav a { padding: 10px 12px; white-space: nowrap; transition: background .2s, color .2s; }
.nav nav a:hover, .nav nav a[aria-current="page"] { background: var(--ink); color: var(--bg); }
.btn { font: 500 13px/1 var(--mono); padding: 12px 16px; border: 1px solid var(--ink); display: inline-flex; gap: 10px; align-items: center; white-space: nowrap; transition: background .2s, color .2s, border-color .2s; }
.btn:hover { background: var(--ink); color: var(--bg); }
.btn.solid { background: var(--ink); color: var(--bg); font-size: 14px; padding: 16px 20px; }
.btn.solid:hover { background: var(--amb); color: var(--amb-ink); border-color: var(--amb); }
.btn.solid span { transition: transform .25s; }
.btn.solid:hover span { transform: translateX(4px); }
.theme { font: 500 12px/1 var(--mono); text-transform: uppercase; letter-spacing: .03em; color: var(--ink); background: none; border: 1px solid var(--line); height: 39px; padding: 0 12px; display: inline-flex; align-items: center; gap: 8px; cursor: pointer; transition: border-color .2s; }
.theme:hover { border-color: var(--ink); }
.theme i { width: 12px; height: 12px; border-radius: 50%; border: 1px solid var(--ink); background: linear-gradient(90deg, var(--ink) 50%, transparent 50%); }
.theme[data-mode="light"] i { background: transparent; }
.theme[data-mode="dark"] i { background: var(--ink); }

.tag { font: 500 12.5px/1.3 var(--mono); letter-spacing: .04em; text-transform: uppercase; color: var(--dim); display: flex; align-items: center; gap: 10px; }
.tag i { width: 9px; height: 9px; background: var(--amb); border: 1px solid var(--ink); flex: none; }

/* home hero */
.hero { padding: clamp(96px, 12vh, 118px) var(--pad) 28px; display: flex; flex-direction: column; gap: clamp(22px, 3vh, 34px); }
.display { font-weight: var(--wg); font-variation-settings: "wdth" var(--wd), "wght" var(--wg); font-size: clamp(40px, 7.3vw, 128px); line-height: 1; letter-spacing: -.045em; --wd: 100; --wg: 800; }
.display .row { display: block; white-space: nowrap; width: max-content; max-width: 100%; }
.display .hl { background: var(--amb); color: var(--amb-ink); padding: 0 .12em .1em .06em; margin-top: .06em; line-height: 1.06; }
.hero-top { display: grid; gap: 20px; }
.hero-side { display: grid; grid-template-columns: minmax(0, 640px); gap: 14px; }
.hero-side .tag { grid-column: 1 / -1; }
.lede { font-size: clamp(16px, 1.25vw, 19px); line-height: 1.45; color: var(--body); }
.cta { justify-self: start; display: flex; gap: 10px; flex-wrap: wrap; margin-top: 6px; }

/* split-flap board */
.board-wrap { background: var(--panel); padding: 10px; border: 1px solid var(--panel-line); }
.board-cap { display: flex; justify-content: space-between; gap: 18px; font: 500 12px/1.3 var(--mono); letter-spacing: .04em; text-transform: uppercase; color: var(--panel-dim); padding: 4px 4px 12px; }
.board-cap span:first-child { color: #fff; display: flex; align-items: center; gap: 8px; }
.board-cap span:last-child { white-space: nowrap; }
.lamp { width: 8px; height: 8px; border-radius: 50%; background: var(--amb); flex: none; }
.board { --cols: 59; display: grid; grid-template-columns: repeat(var(--cols), 1fr); aspect-ratio: 59 / 10.5; perspective: 600px; }
.board .c { position: relative; margin: 1px; background: var(--tile); color: var(--tile-ink); display: grid; place-items: center; font: 600 calc(var(--cw, 22px) * .82)/1 var(--mono); border-radius: 2px; overflow: hidden; }
.board .c::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 1px; background: rgba(0, 0, 0, .75); }
.board .c.d { color: var(--amb); }

/* the band: the four things we build, readable whole at a glance */
.band { border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); display: grid; grid-template-columns: repeat(4, 1fr); margin-top: clamp(20px, 3vw, 44px); }
.band a { display: flex; flex-direction: column; gap: 10px; padding: clamp(18px, 2vw, 30px) clamp(14px, 1.6vw, 26px) clamp(18px, 2vw, 28px); border-right: 1px solid var(--line); position: relative; transition: background .25s, color .25s; }
.band a:first-child { padding-left: var(--pad); }
.band a:last-child { border-right: 0; padding-right: var(--pad); }
.band .k { font: 500 12px/1 var(--mono); color: var(--dim); transition: color .25s; }
.band b { font-size: clamp(24px, 2.7vw, 44px); font-weight: 800; font-variation-settings: "wdth" 100, "wght" 800; letter-spacing: -.035em; line-height: 1; }
.band .s { font-size: 15.5px; line-height: 1.35; color: var(--body); max-width: 26ch; transition: color .25s; }
.band .go2 { font: 500 12px/1 var(--mono); text-transform: uppercase; letter-spacing: .03em; margin-top: auto; padding-top: 8px; }
.band a:hover { background: var(--amb); color: var(--amb-ink); }
.band a:hover .k, .band a:hover .s { color: var(--amb-ink); }

/* sections */
.h2 { font-size: clamp(32px, 4.6vw, 72px); font-weight: 800; font-variation-settings: "wdth" 100, "wght" 800; letter-spacing: -.04em; line-height: 1; text-wrap: balance; }
h3, .h3, .display { text-wrap: balance; }
p, li, dt, td, caption { text-wrap: pretty; }
.sec { padding: clamp(60px, 7.5vw, 120px) var(--pad); border-top: 1px solid var(--rule); }
.band + .sec { border-top: 0; }
.sec-head { margin-bottom: clamp(26px, 3.4vw, 52px); display: grid; gap: 14px; }
.sec-head p.sub { color: var(--body); max-width: 60ch; font-size: 18px; }

/* what we build: a grid, no sideways motion */
.work-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.card { background: var(--card); border: 1px solid var(--rule); padding: clamp(18px, 2.2vw, 34px); display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.card-head { display: grid; grid-template-columns: auto 1fr; gap: 6px 18px; align-items: end; }
.idx { font-size: clamp(54px, 5.4vw, 92px); font-weight: 300; font-variation-settings: "wdth" 62, "wght" 300; line-height: .8; letter-spacing: -.03em; grid-row: span 1; }
.card h3 { font-size: clamp(26px, 2.5vw, 40px); font-weight: 800; font-variation-settings: "wdth" 100, "wght" 800; letter-spacing: -.035em; line-height: 1; padding-bottom: .08em; }
.card p { color: var(--body); font-size: 16px; max-width: 60ch; }
.card-foot { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-top: auto; }
.meta { font: 400 12.5px/1.5 var(--mono); color: var(--dim); display: grid; gap: 5px; }
.meta li { padding-left: 18px; position: relative; }
.meta li::before { content: ""; position: absolute; left: 0; top: .5em; width: 8px; height: 8px; background: var(--amb); border: 1px solid var(--ink); }
.go { flex: none; display: inline-flex; gap: 10px; align-items: center; font: 500 13px/1 var(--mono); text-transform: uppercase; letter-spacing: .03em; padding: 14px 16px; border: 1px solid var(--ink); white-space: nowrap; transition: background .2s, color .2s; }
.go span { transition: transform .25s; }
.go:hover { background: var(--ink); color: var(--bg); }
.go:hover span { transform: translateX(5px); }

/* dark panels inside cards: each runs a small interface */
.ui { background: var(--panel); color: var(--panel-ink); border: 1px solid var(--panel-line); font: 400 13px/1.45 var(--mono); padding: 14px 16px; display: flex; flex-direction: column; min-height: 270px; min-width: 0; }
.card .ui { flex: 1; }
.ui p { color: var(--panel-dim); max-width: none; font-size: 12px; }
.ui-bar { display: flex; justify-content: space-between; gap: 12px; padding-bottom: 12px; border-bottom: 1px solid var(--panel-line); text-transform: uppercase; letter-spacing: .04em; }
.ui-bar span:first-child { color: #fff; }
.feed { flex: 1; display: flex; flex-direction: column; }
.feed li { flex: 1; align-items: center; }
.ui-bar span:last-child { text-align: right; }
.ui-foot { margin-top: auto; padding-top: 12px; border-top: 1px solid var(--panel-line); display: flex; align-items: center; gap: 10px; }
.feed li { display: grid; grid-template-columns: 10ch minmax(0, 1fr) auto; gap: 12px; padding: 9px 0 9px 10px; border-bottom: 1px solid rgba(255, 255, 255, .12); border-left: 3px solid transparent; transition: background .3s, border-color .3s; }
.feed li.on { border-left-color: var(--amb); background: rgba(255, 179, 0, .1); }
.feed b { font-weight: 600; color: #fff; }
.feed span { color: #d5d7dc; }
.feed em { font-style: normal; color: var(--amb); text-align: right; }
.scan { width: 22px; height: 8px; background: repeating-linear-gradient(90deg, var(--amb) 0 2px, transparent 2px 4px); flex: none; }
.merge { display: grid; grid-template-columns: auto minmax(30px, 1fr) auto; align-items: stretch; flex: 1; padding-top: 14px; min-height: 210px; }
.src, .out { display: grid; align-content: space-around; gap: 6px; }
.src li { border: 1px solid rgba(255, 255, 255, .5); padding: 7px 10px; color: #fff; transition: background .25s, color .25s, border-color .25s; }
.src li.on { background: var(--amb); border-color: var(--amb); color: var(--amb-ink); }
.out { border: 1px solid var(--amb); padding: 10px 12px; align-content: center; gap: 1px; }
.out li { color: var(--panel-ink); }
.out li::before { content: "\201C"; color: var(--amb); }
.out li::after { content: "\201D"; color: var(--amb); }
.wires { width: 100%; height: 100%; min-width: 0; }
.wires path { fill: none; stroke: rgba(255, 255, 255, .55); stroke-width: 1.2; vector-effect: non-scaling-stroke; stroke-dasharray: 5 6; }
.bars { display: grid; gap: 14px; padding: 18px 0 14px; flex: 1; align-content: space-evenly; }
.bars li { display: grid; grid-template-columns: 118px minmax(0, 1fr) 46px; gap: 12px; align-items: center; }
.bars span { color: #d5d7dc; }
.bars i { display: block; height: 22px; background: rgba(255, 255, 255, .14); }
.bars u { display: block; height: 100%; background: var(--amb); transform-origin: left; transform: scaleX(0); transition: transform 1s cubic-bezier(.2, .7, .1, 1); }
.bars b { font: 600 24px/1 var(--mono); color: #fff; text-align: right; }
.chk { display: grid; padding-top: 4px; flex: 1; align-content: space-around; }
.chk li { display: grid; grid-template-columns: 22px 88px minmax(0, 1fr); gap: 12px; align-items: center; padding: 8px 0; border-bottom: 1px solid rgba(255, 255, 255, .12); }
.chk i { width: 16px; height: 16px; border: 1px solid rgba(255, 255, 255, .6); position: relative; transition: background .25s, border-color .25s; }
.chk li.on i { background: var(--amb); border-color: var(--amb); }
.chk li.on i::after { content: ""; position: absolute; left: 4px; top: 1px; width: 5px; height: 9px; border: solid var(--amb-ink); border-width: 0 2px 2px 0; transform: rotate(40deg); }
.chk b { color: #fff; font-weight: 600; }
.chk span { color: var(--panel-dim); }

/* how we work */
.rules { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 3px solid var(--rule); }
.rules li { padding: 22px 28px 8px 0; border-right: 1px solid var(--line); }
.rules li + li { padding-left: 28px; }
.rules li:last-child { border-right: 0; }
.rules .n { display: grid; place-items: center; width: 44px; height: 44px; background: var(--ink); color: var(--bg); font: 600 20px/1 var(--mono); margin-bottom: clamp(18px, 2.4vw, 36px); }
.rules h3 { font-size: clamp(24px, 2.4vw, 36px); font-weight: 800; font-variation-settings: "wdth" 100, "wght" 800; letter-spacing: -.03em; line-height: 1.04; margin-bottom: 12px; }
.rules p { color: var(--body); max-width: 36ch; }

/* figures on the amber band: flip tiles */
.facts { padding: clamp(60px, 7.5vw, 120px) var(--pad); border-top: 1px solid var(--rule); background: var(--amb); color: var(--amb-ink); }
.facts .tag { color: var(--amb-ink); margin-bottom: 14px; }
.facts .tag i { background: var(--amb-ink); border-color: var(--amb-ink); }
.facts :focus-visible { outline-color: var(--amb-ink); }
/* tile size is set so that four figures (18 digits on the home page) fit inside the page margins at every width */
.nums { --tw: clamp(30px, 3.3vw, 64px); display: grid; grid-template-columns: repeat(4, auto); justify-content: start; gap: 32px clamp(28px, 3.4vw, 64px); margin-top: clamp(26px, 3.4vw, 52px); }
.nums.n3 { grid-template-columns: repeat(3, auto); --tw: clamp(34px, 4vw, 70px); }
.nums dd { display: flex; gap: 3px; height: calc(var(--tw) * 1.6); }
.nums dd .t { background: var(--tile); color: var(--tile-ink); width: var(--tw); display: grid; place-items: center; font: 600 calc(var(--tw) * 1.06)/1 var(--mono); position: relative; border-radius: 3px; }
/* the comma is set smaller than the digits so the glyph fits its narrow tile (a mono glyph is 0.6 em wide) */
.nums dd .t.p { width: calc(var(--tw) * .42); font-size: calc(var(--tw) * .66); background: none; color: var(--amb-ink); align-items: end; padding-bottom: .5em; }
.nums dd .t:not(.p)::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 2px; background: rgba(0, 0, 0, .8); }
.nums dt { font: 500 13px/1.45 var(--mono); margin-top: 14px; max-width: 28ch; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.fnote { font: 400 13px/1.5 var(--mono); margin-top: 28px; max-width: 90ch; }

/* subpages */
.phero { padding: clamp(104px, 13vh, 132px) var(--pad) clamp(40px, 5vw, 72px); display: grid; gap: 20px; }
.phero .display { font-size: clamp(40px, 6.4vw, 112px); }
.phero .display .row { white-space: normal; width: auto; }
.phero .display .hl { width: max-content; max-width: 100%; }
.phero-row { display: grid; grid-template-columns: minmax(0, 720px); gap: 20px; }
.cols { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(24px, 4vw, 72px); align-items: start; }
/* beside a long right column, the heading stays in view while the reader scrolls (ordinary sticky positioning) */
.cols > .sec-head { position: sticky; top: 96px; margin-bottom: 0; }
.prose { display: grid; gap: 14px; color: var(--body); max-width: 68ch; }
.prose h3 { color: var(--ink); font-size: 24px; font-weight: 800; font-variation-settings: "wdth" 100, "wght" 800; letter-spacing: -.02em; line-height: 1.1; margin-top: 14px; }
.h3 { color: var(--ink); font-size: clamp(22px, 2vw, 28px); font-weight: 800; font-variation-settings: "wdth" 100, "wght" 800; letter-spacing: -.02em; line-height: 1.1; }
.prose .h3 { margin-top: 18px; }
.prose .h3:first-child { margin-top: 0; }
.rules a { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.prose a, .lede a, .note a, .tbl a { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.prose a:hover, .lede a:hover, .note a:hover, .tbl a:hover { background: var(--amb); color: var(--amb-ink); }
.prose ul { display: grid; gap: 8px; }
.prose ul li { padding-left: 20px; position: relative; }
.prose ul li::before { content: ""; position: absolute; left: 0; top: .55em; width: 8px; height: 8px; background: var(--amb); border: 1px solid var(--ink); }
.prose code, .tbl code { font: 500 .88em var(--mono); background: var(--card); border: 1px solid var(--line); padding: 1px 5px; white-space: nowrap; }
.tbl { width: 100%; border-collapse: collapse; background: var(--card); border: 1px solid var(--rule); font-size: 15.5px; }
.tbl caption { caption-side: bottom; text-align: left; font: 400 12.5px/1.45 var(--mono); color: var(--dim); padding: 12px 0 0; }
.tbl th, .tbl td { text-align: left; vertical-align: top; padding: 11px 14px; border-bottom: 1px solid var(--line); overflow-wrap: break-word; }
.tbl thead th { font: 500 12px/1.2 var(--mono); letter-spacing: .04em; text-transform: uppercase; color: var(--panel-ink); background: var(--panel); border-bottom: 0; }
.tbl tbody th { font-weight: 700; white-space: nowrap; }
.tbl td { color: var(--body); }
.tbl tr:last-child th, .tbl tr:last-child td { border-bottom: 0; }
.tbl .num { font-family: var(--mono); white-space: nowrap; }
.pcards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.pcards.two { grid-template-columns: 1fr 1fr; }
.pcard { background: var(--card); border: 1px solid var(--rule); padding: clamp(18px, 2vw, 30px); display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.pcard h3 { font-size: clamp(24px, 2.2vw, 34px); font-weight: 800; font-variation-settings: "wdth" 100, "wght" 800; letter-spacing: -.03em; line-height: 1.05; }
.pcard p { color: var(--body); font-size: 16px; }
.pcard p:not(.price) { flex: 1; }
.pcard .price { font: 600 15px/1.4 var(--mono); background: var(--amb); color: var(--amb-ink); padding: 8px 10px; width: max-content; max-width: 100%; }
.pcard .go { margin-top: auto; align-self: flex-start; white-space: normal; }
.note { border: 1px solid var(--rule); border-left: 10px solid var(--amb); background: var(--card); padding: 20px 22px; display: grid; gap: 10px; color: var(--body); }
.note .prose { max-width: none; }
.note > p { max-width: 96ch; }
.sec > .note .prose ul { grid-template-columns: 1fr 1fr; gap: 10px 40px; }
.note h3 { color: var(--ink); font-size: 22px; font-weight: 800; font-variation-settings: "wdth" 100, "wght" 800; letter-spacing: -.02em; }
.code { background: var(--panel); color: var(--panel-ink); border: 1px solid var(--panel-line); font: 400 13.5px/1.7 var(--mono); padding: 16px 18px; white-space: pre-wrap; overflow-wrap: normal; word-break: normal; overflow-x: auto; max-width: 100%; margin:0; }
.code .k { color: var(--amb); white-space: nowrap; }
.code .nb { white-space: nowrap; } /* an argument or a value is never broken in the middle; lines break between them */
.code .c { color: var(--panel-dim); }
.stack { display: grid; gap: clamp(20px, 2.6vw, 36px); }

/* footer */
.foot { background: var(--foot); color: #eceae4; padding: clamp(70px, 9vw, 150px) var(--pad) 28px; border-top: 1px solid var(--panel-line); }
.foot .tag { color: #c9ccd2; }
.foot .tag i { border-color: var(--amb); }
.mail { display: block; width: max-content; max-width: 100%; font-size: clamp(34px, 9.6vw, 160px); font-weight: 800; font-variation-settings: "wdth" 84, "wght" 800; letter-spacing: -.05em; line-height: 1; margin: 20px 0 clamp(36px, 5vw, 80px); transition: font-variation-settings .5s cubic-bezier(.2, .7, .1, 1), color .3s; color: #fff; }
.mail:hover { font-variation-settings: "wdth" 96, "wght" 800; color: var(--amb); }
.foot-grid { display: grid; grid-template-columns: minmax(0, 2fr) 1fr 1.4fr; gap: 32px; padding-top: 24px; border-top: 1px solid rgba(255, 255, 255, .25); color: #d5d7dc; font-size: 15px; }
.foot-grid p { max-width: 44ch; }
.foot-about { display: grid; gap: 12px; align-content: start; }
.foot-grid .small { font-size: 13px; line-height: 1.45; color: #c9ccd2; }
.fine span { line-height: 1.5; text-align: right; }
.fine a { text-decoration: underline; text-underline-offset: 3px; }
.foot-grid li { padding: 3px 0; }
.foot-grid a { border-bottom: 1px solid transparent; transition: border-color .2s, color .2s; }
.foot-grid a:hover { color: #fff; border-color: var(--amb); }
.fine { margin-top: 40px; font: 400 12px/1 var(--mono); color: #c9ccd2; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.fine .brand { color: #fff; margin: 0; }

/* reveal on scroll: the script adds .rv to the elements it will reveal, so without the script everything shows */
.rv { opacity: 0; transform: translateY(34px); transition: opacity .7s cubic-bezier(.2, .7, .1, 1), transform .7s cubic-bezier(.2, .7, .1, 1); transition-delay: var(--d, 0s); }
.rv.in { opacity: 1; transform: none; }

/* motion that needs no script: the hero intro and the wordmark */
@media (prefers-reduced-motion: no-preference) {
  .display { animation: open 1.2s cubic-bezier(.2, .8, .15, 1) backwards; }
  .display .hl { animation: wipe .9s .3s cubic-bezier(.2, .8, .15, 1) backwards; }
  .hero-side, .board-wrap, .phero-row, .phero .tag { animation: up .9s .3s cubic-bezier(.2, .8, .15, 1) backwards; }
  .board-wrap { animation-delay: .45s; }
  .lamp { animation: lamp 1.6s steps(2) infinite; }
  .wires path { animation: dash 1.2s linear infinite; }
  /* the wordmark: letters settle in one after another; the dot of the i flips like a board tile */
  /* the brush M is drawn in from the left, as a stroke is made; then the letters settle in one after another
     (the M is the first path, so the letters are paths 2 to 8); last, the dot of the i flips like a board tile */
  .nav .wm-m { animation: wm-brush .75s cubic-bezier(.45, 0, .2, 1) backwards; animation-delay: 80ms; }
  .nav .wl { transform-box: fill-box; transform-origin: 50% 100%; animation: wl .55s cubic-bezier(.2, .8, .15, 1) backwards; animation-delay: 480ms; }
  .nav .wl:nth-of-type(3) { animation-delay: 530ms; } .nav .wl:nth-of-type(4) { animation-delay: 580ms; } .nav .wl:nth-of-type(5) { animation-delay: 630ms; }
  .nav .wl:nth-of-type(6) { animation-delay: 680ms; } .nav .wl:nth-of-type(7) { animation-delay: 730ms; }
  .nav .wl:nth-of-type(n+8) { animation-delay: 780ms; }
  .nav .wdot { transform-box: fill-box; transform-origin: 50% 50%; animation: wdot .7s 1.1s cubic-bezier(.3, 0, .2, 1) backwards; }
  @keyframes wm-brush { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
  .nav .brand:hover .wdot { animation: wdot2 .5s cubic-bezier(.3, 0, .2, 1); }
  @keyframes open { from { --wd: 62; --wg: 300; opacity: 0; } 30% { opacity: 1; } }
  @keyframes wipe { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
  @keyframes up { from { opacity: 0; transform: translateY(26px); } }
  @keyframes lamp { 50% { opacity: .25; } }
  @keyframes dash { to { stroke-dashoffset: -22; } }
  @keyframes wl { from { opacity: 0; transform: translateY(55%) scaleY(.5); } }
  @keyframes wdot { 0% { transform: scaleY(0); } 35% { transform: scaleY(1); } 55% { transform: scaleY(0); } 100% { transform: scaleY(1); } }
  @keyframes wdot2 { 0% { transform: scaleY(1); } 50% { transform: scaleY(0); } 100% { transform: scaleY(1); } }
}
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  .rv { opacity: 1; transform: none; }
}

/* narrower desktops and tablets */
@media (max-width: 1180px) {
  .nav nav a { padding: 10px 8px; }
  .mailbtn { display: none; }
  .band { grid-template-columns: 1fr 1fr; }
  .band a:nth-child(2) { border-right: 0; padding-right: var(--pad); }
  .band a:nth-child(3) { padding-left: var(--pad); }
  .band a:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
}
@media (max-width: 980px) {
  .work-grid { grid-template-columns: 1fr; }
  .cols, .phero-row { grid-template-columns: 1fr; }
  .board { --cols: 24; aspect-ratio: 24 / 9; }
  .board-cap .wide { display: none; }
  .rules { grid-template-columns: 1fr; }
  .rules li, .rules li + li { padding: 20px 0; border-right: 0; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 60px 1fr; }
  .rules p { max-width: 60ch; }
  .cols > .sec-head { position: static; }
  .rules .n { margin-bottom: 0; grid-row: span 2; }
  .nums { grid-template-columns: auto auto; }
  .pcards, .pcards.two { grid-template-columns: 1fr; }
  .sec > .note .prose ul { grid-template-columns: 1fr; }
  /* wide tables become one block per row; the script copies each column's heading in front of its value */
  .tbl.stackable thead { display: none; }
  .tbl.stackable tr { display: grid; padding: 10px 0; border-bottom: 1px solid var(--line); }
  .tbl.stackable tr:last-child { border-bottom: 0; }
  .tbl.stackable th, .tbl.stackable td { border: 0; padding: 2px 14px; }
  .tbl.stackable tbody th { font-size: 18px; white-space: normal; }
  .tbl.stackable td[data-l]::before { content: attr(data-l) ": "; font: 500 12px/1 var(--mono); letter-spacing: .03em; text-transform: uppercase; color: var(--dim); }
}
/* phone */
@media (max-width: 700px) {
  /* phone header: the wordmark and the theme button on one row, the four page links on a second row */
  .nav { gap: 0 8px; height: auto; flex-wrap: wrap; padding-top: 10px; }
  .nav nav { order: 3; width: 100%; justify-content: space-between; gap: 0; font-size: 11.5px; letter-spacing: 0; margin: 8px calc(-1 * var(--pad)) 0; padding: 0 calc(var(--pad) - 6px); width: calc(100% + 2 * var(--pad)); border-top: 1px solid var(--line); }
  .nav nav a { padding: 11px 6px; }
  .hero, .phero { padding-top: 124px; }
  html { scroll-padding-top: 120px; }
  .mailbtn { display: none; }
  .wm { height: 28px; }
  .display { --wd: 78; font-size: 16vw; line-height: 1.04; letter-spacing: -.02em; }
  .display .row { white-space: normal; width: auto; }
  .display .hl { width: max-content; max-width: 100%; }
  .display .ln { display: block; }
  .phero .display { font-size: 12.5vw; }
  .ui-bar { font-size: 11px; }
  .fine { flex-direction: column; align-items: flex-start; }
  .fine span { text-align: left; }
  .nums.n3 { grid-template-columns: 1fr; }
  .band { grid-template-columns: 1fr; }
  .band a, .band a:first-child, .band a:last-child, .band a:nth-child(2), .band a:nth-child(3) { padding: 16px var(--pad); border-right: 0; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 30px 1fr; gap: 4px 8px; }
  .band a:last-child { border-bottom: 0; }
  .band .s, .band .go2 { grid-column: 2; }
  .band .go2 { padding-top: 2px; }
  .card-foot { flex-direction: column; align-items: flex-start; }
  .ui { min-height: 0; }
  .merge { min-height: 200px; }
  .bars li { grid-template-columns: 116px minmax(0, 1fr) 48px; }
  .bars b { font-size: 22px; }
  .feed li { grid-template-columns: 10ch minmax(0, 1fr); }
  .feed em { grid-column: 2; text-align: left; }
  .nums, .nums.n3 { grid-template-columns: 1fr; }
  .nums, .nums.n3 { --tw: 11.5vw; }
  .card-head { align-items: start; }
  .idx { line-height: .9; }
  .pcards, .pcards.two { grid-template-columns: 1fr; }
  .foot-grid { grid-template-columns: 1fr; }
  .tbl { font-size: 14.5px; }
  .tbl th, .tbl td { padding: 10px; }
  .tbl tbody th { white-space: normal; }
  .tbl.stackable thead { display: none; }
  .tbl.stackable tr { display: grid; padding: 10px 0; border-bottom: 1px solid var(--line); }
  .tbl.stackable th, .tbl.stackable td { border: 0; padding: 2px 10px; }
}
