/* ABV Nexus — the back of the business card: moving ASCII waves, black panels with a white border. Mobile first. */
@font-face { font-family: "JetBrains Mono"; src: url("/fonts/jetbrains-mono-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "JetBrains Mono"; src: url("/fonts/jetbrains-mono-latin-700-normal.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Silkscreen"; src: url("/fonts/silkscreen-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Silkscreen"; src: url("/fonts/silkscreen-latin-700-normal.woff2") format("woff2"); font-weight: 700; font-display: swap; }

:root {
  --bg: #000000;
  --fg: #e6e6e6;
  --dim: #9c9c9c;
  --faint: #505050;
  --rule: 1.5px;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --pixel: "Silkscreen", "JetBrains Mono", monospace;
  --pad: max(14px, env(safe-area-inset-left), env(safe-area-inset-right));
  --ease: cubic-bezier(.2, .7, .1, 1);
  color-scheme: dark;
}
@media (min-width: 760px) { :root { --pad: max(20px, env(safe-area-inset-left), env(safe-area-inset-right)); } }

*, *::before, *::after { box-sizing: border-box; }
html { background: var(--bg); -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--fg); font: 400 13px/1.6 var(--mono); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
@media (min-width: 760px) { body { font-size: 14px; } }
::selection { background: var(--fg); color: var(--bg); }
a { color: inherit; text-decoration: none; -webkit-tap-highlight-color: transparent; }
button, select { -webkit-tap-highlight-color: transparent; }
p, h1, h2, h3, dl, dd, ul, ol, figure, pre { margin: 0; padding: 0; }
ul, ol { list-style: none; }
img { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px dashed var(--fg); outline-offset: 3px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: fixed; left: 8px; top: -60px; z-index: 100; padding: 8px 12px; background: var(--bg); color: var(--fg); border: var(--rule) solid var(--fg); }
.skip:focus { top: 8px; }

/* Big ASCII words. ascii.js fills the <pre>; until then (or without JS) the pixel font shows. */
.word { position: relative; container-type: inline-size; }
.ascii-word { display: none; width: fit-content; max-width: 100%; font-family: var(--mono); line-height: 1; white-space: pre; overflow: hidden; color: var(--fg); user-select: none; -webkit-user-select: none; background: var(--bg); }
.word.ready .ascii-word { display: block; }
.word.ready .word-fallback { display: none; }
.word-fallback { display: block; font: 700 18px/.6 var(--pixel); padding-block: .02em; text-transform: uppercase; white-space: nowrap; overflow: hidden; }
.wl-1 .word-fallback { font-size: calc(100cqw / 0.86); }
.wl-2 .word-fallback { font-size: calc(100cqw / 1.72); }
.wl-3 .word-fallback { font-size: calc(100cqw / 2.58); }
.wl-4 .word-fallback { font-size: calc(100cqw / 3.44); }
.wl-5 .word-fallback { font-size: calc(100cqw / 4.30); }
.wl-6 .word-fallback { font-size: calc(100cqw / 5.16); }
.wl-7 .word-fallback { font-size: calc(100cqw / 6.02); }
.wl-8 .word-fallback { font-size: calc(100cqw / 6.88); }
.wl-9 .word-fallback { font-size: calc(100cqw / 7.74); }
.wl-10 .word-fallback { font-size: calc(100cqw / 8.60); }
.wl-11 .word-fallback { font-size: calc(100cqw / 9.46); }
.wl-12 .word-fallback { font-size: calc(100cqw / 10.32); }
.wl-13 .word-fallback { font-size: calc(100cqw / 11.18); }
.wl-14 .word-fallback { font-size: calc(100cqw / 12.04); }
.wl-15 .word-fallback { font-size: calc(100cqw / 12.90); }
.wl-16 .word-fallback { font-size: calc(100cqw / 13.76); }
.wl-17 .word-fallback { font-size: calc(100cqw / 14.62); }
.wl-18 .word-fallback { font-size: calc(100cqw / 15.48); }
.wl-19 .word-fallback { font-size: calc(100cqw / 16.34); }
.wl-20 .word-fallback { font-size: calc(100cqw / 17.20); }
.wl-21 .word-fallback { font-size: calc(100cqw / 18.06); }
.wl-22 .word-fallback { font-size: calc(100cqw / 18.92); }
.wl-23 .word-fallback { font-size: calc(100cqw / 19.78); }
.wl-24 .word-fallback { font-size: calc(100cqw / 20.64); }

pre { font-variant-ligatures: none; font-feature-settings: "liga" 0, "calt" 0; } /* keep ASCII as typed: no != → ≠ */
.status i { font-style: normal; animation: blink 1.4s steps(1) infinite; }
@keyframes blink { 50% { opacity: .25; } }
/* ASCII pictures */
.art { position: absolute; inset: 0; display: none; place-items: center; font-family: var(--mono); line-height: 1; white-space: pre; overflow: hidden; color: var(--fg); user-select: none; transition: color .3s; }
.art.ready { display: grid; }
.art.ready ~ .art-fallback { display: none; }
.art-fallback { position: absolute; inset: 0; display: grid; place-items: center; color: var(--dim); }
.art-photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: grayscale(1) contrast(1.15); opacity: 0; transition: opacity .5s var(--ease); }
.tile:focus-visible .art-photo, .art-photo.shown { opacity: 1; }
@media (hover: hover) { .tile:hover .art-photo, .frame:hover .art-photo { opacity: 1; } }
.art:not(.ready) ~ .art-photo { opacity: 1; }
.prompt { display: grid; grid-template-columns: 9ch 1fr; align-items: center; gap: 8px; min-height: 46px; border-bottom: 1px dashed var(--faint); }
.prompt span { color: var(--dim); }
.prompt input, .prompt select, .prompt textarea { width: 100%; min-height: 44px; padding: 8px 0; background: transparent; border: 0; border-radius: 0; font-size: 16px; caret-color: var(--fg); -webkit-appearance: none; appearance: none; }
.prompt select { padding-right: 22px; cursor: pointer; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%23e6e6e6' stroke-width='1.4'/%3E%3C/svg%3E") no-repeat right 4px center / 10px 6px; }
.prompt select option { background: #000; color: var(--fg); }
.prompt-area { align-items: start; padding-top: 4px; }
.prompt-area span { padding-top: 10px; }
.prompt textarea { min-height: 120px; resize: vertical; line-height: 1.5; }
.prompt:focus-within { border-bottom-color: var(--fg); }
.prompt:focus-within span { color: var(--fg); }
.prompt input:focus, .prompt select:focus, .prompt textarea:focus { outline: none; }
.prompt [aria-invalid="true"] { text-decoration: underline wavy var(--fg); }
.prompt input:-webkit-autofill, .prompt input:-webkit-autofill:hover, .prompt input:-webkit-autofill:focus { -webkit-text-fill-color: var(--fg); -webkit-box-shadow: 0 0 0 100px var(--bg) inset; caret-color: var(--fg); transition: background-color 9999s; }
.form-foot { display: grid; gap: 10px; justify-items: start; padding-top: 12px; }
.send { min-height: 48px; padding: 0 18px; background: var(--bg); border: var(--rule) solid var(--fg); cursor: pointer; transition: box-shadow .2s; }
.send:focus-visible { outline: none; box-shadow: inset 0 0 0 2px var(--fg); }
@media (hover: hover) { .send:hover { box-shadow: inset 0 0 0 2px var(--fg); } }
.send:disabled { opacity: .5; cursor: default; }
.result { min-height: 21px; color: var(--dim); }
.result[data-state="ok"], .result[data-state="error"] { color: var(--fg); }
.trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.pills { display: flex; flex-wrap: wrap; gap: 6px; }
.pills a span { font-family: var(--mono); font-weight: 400; font-size: .6em; vertical-align: .25em; }
.pills a { display: inline-flex; align-items: center; min-height: 44px; padding: .12em .5em .08em; background: var(--bg); border: var(--rule) solid var(--fg); border-radius: 12px; font: 700 clamp(20px, 5.6vw, 52px)/1.1 var(--pixel); text-transform: uppercase; transition: box-shadow .2s, color .2s; }
.pills a:focus-visible { outline: none; box-shadow: inset 0 0 0 3px var(--fg); }
@media (hover: hover) { .pills a:hover { box-shadow: inset 0 0 0 3px var(--fg); } }
/* Project screenshots: a self-playing carousel, neighbours peeking in at the edges in solid black and white. */
.v-shots { margin: 0; }
.shots-track { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; padding: 14px 11%; overscroll-behavior-x: contain; }
.shots-track::-webkit-scrollbar { display: none; }
.v-shots-one .shots-track { padding: 14px; }
.shot { position: relative; flex: 0 0 100%; aspect-ratio: 4 / 3; overflow: hidden; scroll-snap-align: center; border: 1px solid var(--faint); background: #0b0b0b; transition: transform .35s var(--ease), border-color .2s; }
.shot img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(1); -webkit-user-drag: none; user-select: none; }
.shot.on { border-color: var(--fg); cursor: zoom-in; }
.shot.on img { filter: none; }
.js .shot:not(.on) { transform: scale(.92); }
.shot-hint { position: absolute; right: 8px; bottom: 8px; padding: 2px 8px; background: var(--bg); border: 1px solid var(--fg); font-size: 11px; opacity: 0; transition: opacity .2s; pointer-events: none; }
.shot.on .shot-hint { opacity: 1; }
@media (hover: hover) { .shot.on:not(:hover) .shot-hint { opacity: 0; } }
.shots-bar { display: flex; align-items: center; min-height: 40px; border-top: var(--rule) solid var(--fg); font-size: 12px; color: var(--dim); text-transform: uppercase; letter-spacing: .03em; }
.shots-count { flex: 1; padding: 0 10px; text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.shots-count b { color: var(--fg); font-weight: 400; }
.shots-arrow { flex: none; min-width: 44px; min-height: 40px; padding: 0; background: var(--bg); border: 0; color: var(--fg); font: inherit; cursor: pointer; }
.shots-arrow[data-prev] { border-right: var(--rule) solid var(--fg); }
.shots-arrow[data-next] { border-left: var(--rule) solid var(--fg); }
.shots-arrow:focus-visible, .shots-lines button:focus-visible, .shots-track:focus-visible { outline: 2px dashed var(--fg); outline-offset: -4px; }
/* One line per screenshot, always one row; the current one fills while it shows. */
.shots-lines { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 6px; padding: 2px 14px 6px; border-top: var(--rule) solid var(--fg); }
.shots-lines[hidden] { display: none; }
.shots-lines button { position: relative; height: 28px; padding: 0; background: none; border: 0; cursor: pointer; }
.shots-lines i { position: absolute; left: 0; right: 0; top: 50%; height: 3px; margin-top: -1.5px; background: #2e2e2e; overflow: hidden; }
.shots-lines b { display: block; width: 0; height: 100%; background: var(--fg); }
/* Large view: a window on top of the page, drawn like the panels. */
.shot-window { position: fixed; inset: 0; z-index: 60; display: none; place-items: center; padding: max(12px, env(safe-area-inset-top)) max(12px, env(safe-area-inset-right)) max(12px, env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-left)); background: rgba(0, 0, 0, .82); }
.shot-window.open { display: grid; }
html.window-open { overflow: hidden; }
.sw-in { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; width: min(1100px, 100%); max-height: 100%; min-width: 0; overflow: hidden; background: var(--bg); border: var(--rule) solid var(--fg); }
.sw-bar { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding-left: 12px; border-bottom: var(--rule) solid var(--fg); font-size: 12px; color: var(--dim); }
.sw-title { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sw-close { flex: none; min-width: 44px; min-height: 40px; background: var(--bg); border: 0; border-left: var(--rule) solid var(--fg); color: var(--fg); font: inherit; font-size: 16px; cursor: pointer; }
.sw-track { display: flex; aspect-ratio: 4 / 3; max-height: calc(100svh - 120px); overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior: contain; }
.sw-track::-webkit-scrollbar { display: none; }
.sw-track > div { flex: 0 0 100%; height: 100%; min-height: 0; display: grid; grid-template: minmax(0, 1fr) / minmax(0, 1fr); place-items: center; overflow: hidden; scroll-snap-align: center; }
.sw-track img { width: auto; height: auto; max-width: 100%; max-height: 100%; object-fit: contain; }
.shot-window .shots-arrow:disabled { color: #444; cursor: default; }
.sw-close:focus-visible, .shot-window .shots-arrow:focus-visible { outline: 2px dashed var(--fg); outline-offset: -4px; }
.points { display: grid; gap: 7px; }
.points li { display: grid; grid-template-columns: 2ch 1fr; color: var(--dim); }
.points li::before { content: "-"; color: var(--fg); }
.doc-body { display: grid; gap: 12px; max-width: 76ch; }
.doc-body h2 { margin-top: 14px; font-size: 15px; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; }
.doc-body h3 { margin-top: 6px; font-size: 14px; font-weight: 700; }
.doc-body ul, .doc-body ol { display: grid; gap: 6px; padding-left: 3ch; }
.doc-body ul { list-style: "- "; } .doc-body ol { list-style: decimal; }
.doc-body a { text-decoration: underline; text-underline-offset: 3px; }
.doc-body code { color: var(--fg); background: #111; padding: 0 .3ch; }
.doc-body pre.code { overflow-x: auto; padding: 12px 14px; border: 1px solid var(--faint); background: var(--bg); font-size: 13px; line-height: 1.5; white-space: pre; }
.doc-body pre.code code { background: none; padding: 0; }
@media (prefers-reduced-motion: reduce) {
  .js .shot:not(.on) { transform: none; }
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition-duration: .001ms !important; }
}

/* Cat card: a little "meow" now and then. */
.art-meow { position: absolute; right: 8px; top: 8px; z-index: 2; padding: 2px 7px; background: var(--bg); border: 1px solid var(--fg); font-size: 12px; opacity: 0; transform: translateY(4px); transition: opacity .25s, transform .25s; pointer-events: none; }
.art-meow.on { opacity: 1; transform: none; }

/* Motion switch (footer) and repeat visits: everything shows instantly, nothing moves on its own. */
html.motion-off *, html.motion-off *::before, html.motion-off *::after { animation: none !important; }
html.motion-off .art-meow { display: none; }

/* ---------- The card frame: waves underneath, black panels with a white border on top ---------- */
.field { position: fixed; inset: 0; z-index: 0; width: 100%; height: 100%; pointer-events: none; }
.shell { position: relative; z-index: 1; display: grid; grid-template-rows: auto 1fr auto; gap: 16px; width: 100%; max-width: 1180px; min-height: 100svh; margin: 0 auto; padding: max(14px, env(safe-area-inset-top)) var(--pad) calc(14px + env(safe-area-inset-bottom)); }
.stack { display: grid; gap: 16px; align-content: start; min-width: 0; }
.box { position: relative; min-width: 0; background: var(--bg); border: var(--rule) solid var(--fg); }
.pad { padding: 18px 16px; }
@media (min-width: 760px) { .pad { padding: 22px 24px; } }
.two { display: grid; gap: 16px; align-items: stretch; } /* panels side by side always end together */
@media (min-width: 860px) { .two { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
.label { width: fit-content; margin: 0 0 8px; color: var(--dim); font-size: 12px; font-weight: 400; line-height: 1.5; }
.label a { color: var(--dim); }
.label a:hover { color: var(--fg); text-decoration: underline; text-underline-offset: 3px; }
.h { font: 700 clamp(26px, 6vw, 46px)/1.05 var(--pixel); text-transform: uppercase; overflow-wrap: anywhere; }
.name { font: 700 clamp(18px, 3vw, 24px)/1.15 var(--pixel); text-transform: uppercase; }
.page-lede { max-width: 70ch; margin-top: 12px; color: var(--fg); }

/* Menu bar */
.topbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0 14px; padding: 0 12px; }
.topbar a { display: inline-flex; align-items: center; min-height: 44px; white-space: nowrap; }
.topbar-name { margin-left: .6ch; }
.topbar-home { font-size: 12px; letter-spacing: .06em; text-transform: uppercase; }
.menu { display: flex; flex-wrap: wrap; gap: 0 clamp(8px, 2.4vw, 18px); }
.menu a { font-size: clamp(11px, 2.9vw, 13px); text-transform: uppercase; letter-spacing: .03em; color: var(--dim); }
.menu b { font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.menu a[aria-current] { color: var(--fg); text-decoration: underline; text-underline-offset: 4px; }
@media (hover: hover) { .menu a:hover, .topbar-home:hover { color: var(--fg); text-decoration: underline; text-underline-offset: 4px; } }
@media (max-width: 559px) { .topbar-name { display: none; } .topbar { flex-wrap: nowrap; } .menu { flex: 1; justify-content: space-between; gap: 0 6px; } .menu b { text-decoration: none; } }

/* Home: the back of the card */
.cardback-wrap { display: grid; place-items: center; min-height: min(70svh, 620px); }
.cardback { display: grid; place-content: center; justify-items: center; gap: 18px; width: min(300px, 72vw); aspect-ratio: 1; }
.cardback-mark { position: relative; font: 700 clamp(64px, 16vw, 112px)/.9 var(--pixel); }
/* Interference copies of the mark (ascii.js): invisible until a glitch animates them. */
.glitch-band { position: absolute; inset: 0; color: var(--fg); opacity: 0; pointer-events: none; }
.cardback-name { color: var(--dim); font-size: 12px; letter-spacing: .2em; }

/* Footer */
.footer { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 4px 16px; padding: 8px 16px; font-size: 12px; color: var(--dim); }
.footer a { text-decoration: underline; text-decoration-color: var(--faint); text-underline-offset: 3px; }
.footer a, .motion-toggle { display: inline-block; padding-block: 10px; }
.footer-tools { display: flex; gap: 18px; align-items: center; }
.motion-toggle { padding-inline: 0; background: none; border: 0; color: var(--dim); font: inherit; cursor: pointer; }
.motion-toggle[aria-pressed="false"] { color: var(--fg); }
@media (hover: hover) { .footer a:hover, .motion-toggle:hover { color: var(--fg); text-decoration-color: var(--fg); } }
/* Phones: one line. Copyright and KvK on the left, Legal and the motion switch on the right; the email is on Contact. */
.foot-short { display: none; }
@media (max-width: 759px) {
  .footer { flex-wrap: nowrap; gap: 12px; padding: 0 12px; font-size: 11.5px; }
  .footer .foot-long, .foot-mail { display: none; }
  .footer .foot-short { display: inline; }
  .footer > p:first-child { white-space: nowrap; }
  .footer-tools { gap: 12px; }
  .footer a, .motion-toggle { padding-block: 13px; white-space: nowrap; }
}

/* Figures: a picture with a caption bar, like a figure on the card */
.frame figcaption { display: flex; justify-content: space-between; gap: 12px; padding: 6px 10px; border-top: var(--rule) solid var(--fg); font-size: 12px; color: var(--dim); text-transform: uppercase; letter-spacing: .03em; }
.knot-frame { display: grid; grid-template-rows: 1fr auto; }
.knot-frame .knot { align-self: center; }
.knot { display: block; aspect-ratio: 5 / 4; font-family: var(--mono); line-height: 1; white-space: pre; overflow: hidden; color: var(--fg); text-align: center; user-select: none; }
.facts { display: grid; margin-top: 16px; }
.facts div { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 8px 0; border-top: 1px solid #222; }
.facts dt { flex: none; max-width: 50%; color: var(--dim); font-size: 12px; text-transform: uppercase; letter-spacing: .03em; }
.facts dd { text-align: right; }
.facts dd a { display: inline-block; padding-block: 6px; margin-block: -6px; text-decoration: underline; text-underline-offset: 3px; }

/* Projects: one card each */
/* Column counts divide the number of cards, so no row is left half empty. */
.cards { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
@media (min-width: 640px) { .cards:has(> :nth-child(2):last-child), .cards:has(> :nth-child(4):last-child) { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 900px) { .cards { grid-template-columns: repeat(3, minmax(0, 1fr)); } .cards:has(> :nth-child(2):last-child), .cards:has(> :nth-child(4):last-child) { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.pcard { display: grid; grid-template-rows: auto auto 1fr auto; gap: 10px; height: 100%; padding: 14px; transition: box-shadow .2s; }
.pcard-top, .pcard-foot { display: flex; justify-content: space-between; gap: 12px; font-size: 12px; color: var(--dim); }
.pcard-top { text-transform: uppercase; letter-spacing: .03em; }
.pcard-foot { color: var(--fg); }
.pcard-art { position: relative; display: block; aspect-ratio: 85 / 55; overflow: hidden; border: 1px solid #3a3a3a; }
.pcard .art { color: #bdbdbd; }
.pcard-name { font: 700 clamp(18px, 3vw, 22px)/1.15 var(--pixel); text-transform: uppercase; }
.pcard-line { color: var(--dim); }
.pcard:focus-visible { outline: none; box-shadow: inset 0 0 0 2px var(--fg); }
@media (hover: hover) { .pcard:hover { box-shadow: inset 0 0 0 2px var(--fg); } .pcard:hover .art { color: #fff; } .pcard:hover .art-photo { opacity: 1; } }

/* Method: six numbered panels */
.rules { display: grid; grid-template-columns: minmax(0, 1fr); grid-auto-rows: 1fr; gap: 16px; }
@media (min-width: 640px) { .rules { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1000px) { .rules { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.rule-no { color: var(--dim); font-size: 12px; }
.rule-name { margin-top: 6px; font: 700 16px/1.2 var(--pixel); text-transform: uppercase; }
.rule-text { margin-top: 8px; color: var(--dim); }

/* Contact: the details as a card, beside the form */
.ccard { display: grid; align-content: space-between; gap: 16px; }
.ccard-intro { margin-top: 10px; color: var(--dim); max-width: 46ch; }
.ccard-lines { margin-top: 14px; line-height: 1.8; }
.ccard-lines a { text-decoration: underline; text-decoration-color: var(--faint); text-underline-offset: 3px; }
.ccard-foot { color: var(--dim); font-size: 12px; }
.form { display: grid; gap: 4px; }
.form-foot { display: grid; gap: 10px; justify-items: start; padding-top: 12px; }
.send, .btn { display: inline-block; min-height: 48px; padding: 0 18px; background: var(--bg); border: var(--rule) solid var(--fg); line-height: 45px; cursor: pointer; transition: box-shadow .2s; }
.send:focus-visible, .btn:focus-visible { outline: none; box-shadow: inset 0 0 0 2px var(--fg); }
@media (hover: hover) { .send:hover, .btn:hover { box-shadow: inset 0 0 0 2px var(--fg); } }
.send:disabled { opacity: .5; cursor: default; }
@media (min-width: 760px) { .form-foot { grid-template-columns: auto 1fr; align-items: center; } }
.pills a { font-size: clamp(18px, 4.6vw, 40px); }

/* Project page */
.v-head { display: grid; gap: 12px; container-type: inline-size; }
/* Project name: typed at a prompt with a block cursor. One size for every project, set so the longest name
   (SirChesterCoon: "> " + 14 letters + cursor, about 10em of monospace) fills the panel; shorter names match it. */
.v-title { margin: 0; font: 700 min(52px, calc(100cqw / 10.4))/1.1 var(--mono); letter-spacing: -.02em; overflow-wrap: anywhere; }
.v-prompt { color: var(--dim); }
.v-cursor { display: inline-block; width: .55em; height: .9em; margin-left: .06em; vertical-align: -.08em; background: var(--fg); animation: blink-hard 1s steps(1) infinite; }
@keyframes blink-hard { 50% { opacity: 0; } }
.v-head .label { margin: 0; }
.v-line { max-width: 70ch; font-size: 15px; }
.v-line .status { color: var(--dim); white-space: nowrap; }
.v-grid { display: grid; gap: 16px; }
.v-art { aspect-ratio: 1 / 1; display: grid; grid-template-rows: 1fr auto; }
@media (min-width: 860px) { .v-art { aspect-ratio: auto; min-height: 420px; } }
.v-art .art, .v-art .art-photo, .v-art .art-fallback { inset: 0 0 31px 0; height: auto; }
.v-body { display: grid; gap: 18px; align-content: start; }
.v-text p + p { margin-top: 1em; }
.v-text p:first-child { font-size: 15px; }
.v-text p:not(:first-child) { color: var(--dim); }
.v-body .facts { margin-top: 0; }
.pills-small a { font-size: clamp(15px, 3.6vw, 20px); border-radius: 9px; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 16px; }
.gallery .frame { aspect-ratio: 4 / 3; display: grid; grid-template-rows: 1fr auto; }
.gallery .art, .gallery .art-photo { inset: 0 0 31px 0; height: auto; }
.chapters { display: grid; gap: 16px; }
.v-more { display: grid; gap: 16px; }
.chapter { display: grid; gap: 12px; }
.chapter > .label { margin: 0; color: var(--fg); font-size: 13px; text-transform: uppercase; letter-spacing: .04em; }
.chapter-body { display: grid; gap: 16px; max-width: 86ch; }
.chapter-lede { color: var(--fg); }
.group h3 { margin-bottom: 8px; font-size: 12px; font-weight: 400; color: var(--dim); text-transform: uppercase; letter-spacing: .04em; }
.bars { display: grid; gap: 16px; }
.bar { display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 56px; padding: 14px 16px; transition: box-shadow .2s; }
.bar-name { font-weight: 700; }
.bar-sector { color: var(--dim); font-size: 12px; }
.bar:focus-visible { outline: none; box-shadow: inset 0 0 0 2px var(--fg); }
@media (hover: hover) { .bar:hover { box-shadow: inset 0 0 0 2px var(--fg); } }
@media (min-width: 860px) {
  .v-grid { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); align-items: stretch; }
  .bars { grid-template-columns: 1fr 1fr; }
}
.v-shots { order: -1; }

/* Documents, legal info and single notes */
.doc { display: grid; gap: 18px; }
.doc .label { margin: 0; }
.doc-title { font: 700 clamp(24px, 5.5vw, 44px)/1.08 var(--pixel); text-transform: uppercase; overflow-wrap: anywhere; }
.doc-lede { max-width: 64ch; color: var(--dim); }
.doc-lede a { text-decoration: underline; text-underline-offset: 3px; }
.doc .facts { margin-top: 0; max-width: 76ch; }
.note-fig { position: relative; height: clamp(180px, 30vw, 320px); max-width: 76ch; overflow: hidden; border: 1px solid #3a3a3a; }
.note-fig .knot { position: absolute; top: 0; bottom: 0; left: 50%; transform: translateX(-50%); height: 100%; width: auto; max-width: 100%; aspect-ratio: 5 / 4; }

/* Notes index: one panel per project */
.note-groups { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; align-items: stretch; }
@media (min-width: 760px) { .note-groups { grid-template-columns: repeat(2, minmax(0, 1fr)); } .note-groups > .ng:last-child:nth-child(odd) { grid-column: 1 / -1; } }
.ng-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 4px 12px; }
.ng-head .name { min-width: 0; overflow-wrap: anywhere; }
.ng-head a, .ng-head span { flex: none; color: var(--dim); font-size: 12px; }
.ng-head a { display: inline-block; padding-block: 10px; margin-block: -10px; }
@media (hover: hover) { .ng-head a:hover { color: var(--fg); text-decoration: underline; text-underline-offset: 3px; } }
.ng-list { display: grid; margin-top: 10px; }
.ng-list li { border-top: 1px solid #222; }
.ng-note { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 14px; padding: 12px 0; }
.ng-title { font-weight: 700; line-height: 1.35; }
.ng-note time { color: var(--dim); font-size: 12px; white-space: nowrap; }
.ng-sum { grid-column: 1 / -1; color: var(--dim); font-size: 12.5px; }
@media (hover: hover) { .ng-note:hover .ng-title { text-decoration: underline; text-underline-offset: 3px; } }

/* 404 */
.lost h1 { font: 700 clamp(80px, 26vw, 240px)/.85 var(--pixel); }
.lost p { margin: 16px 0; color: var(--dim); }
