@font-face { font-family: "Host Grotesk"; src: url(fonts/host-grotesk.woff2) format("woff2"); font-weight: 300 800; font-display: block; }
@font-face { font-family: "Fragment Mono"; src: url(fonts/fragment-mono.woff2) format("woff2"); font-weight: 400; font-display: block; }
@font-face { font-family: "Bodoni Moda"; src: url(fonts/bodoni-moda.woff2) format("woff2"); font-weight: 400 900; font-display: block; }

/* Two rooms. The stage takes the room of the material on the plinth; the sheet below is always the
   black one. One accent: temper blue, the colour steel turns at about 300 °C. */
:root {
  --ground: #c4c6c9;
  --ink: #0d0e10;
  --accent: #2238d6;
  --line: rgba(13, 14, 16, .16);
  --space: #08090a;
  --space-ink: #e8eaed;
  --space-dim: #8a8e94;
  --space-line: rgba(232, 234, 237, .12);
  --temper: #8c9dff;
  --sans: "Host Grotesk", sans-serif;
  --mono: "Fragment Mono", ui-monospace, monospace;
  color-scheme: light dark;
}
* { box-sizing: border-box; }
html { background: var(--space); color: var(--space-ink); scrollbar-color: #3a3d42 var(--space); scrollbar-width: thin; }
body { margin: 0; font: 400 16px/1.5 var(--sans); -webkit-font-smoothing: antialiased; font-feature-settings: "ss01"; overflow-x: hidden; }
::selection { background: var(--accent); color: #fff; }
::-webkit-scrollbar { width: 9px; background: var(--space); }
::-webkit-scrollbar-thumb { background: #34373c; border-radius: 9px; border: 3px solid var(--space); }
:focus { outline: none; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

#stage { position: relative; width: 100%; height: 100svh; overflow: hidden; touch-action: pan-y; background: var(--ground); color: var(--ink); transition: background-color .5s linear, color .4s linear; }
#object { position: absolute; inset: 0; width: 100%; display: block; }
.table { position: absolute; inset: 0; cursor: grab; touch-action: pan-y; }
.table:active { cursor: grabbing; }
#hits { position: absolute; inset: 0; pointer-events: none; z-index: 2; }
.hit { position: absolute; pointer-events: auto; margin: 0; padding: 0; border: 0; min-width: 0; touch-action: none; cursor: pointer; }
.hit.plate { cursor: grab; touch-action: pan-y; }
.hit.plate:active { cursor: grabbing; }
.hit input, .hit button { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; pointer-events: none; }
.hit label { pointer-events: none; }
/* Focus: one hairline in temper blue, held off the part so it never reads as the part's own edge */
.hit:has(:focus-visible), .hit:focus-visible, .chip:focus-visible { outline: 1px solid var(--accent); outline-offset: 5px; }
#hit-dial, #hit-tray { cursor: grab; }
#hit-dial:active, #hit-tray:active { cursor: grabbing; }

/* The frame: hairlines on the object's own edges, the way a spec sheet rules its page */
#frame { position: absolute; inset: 0; pointer-events: none; --edge: 48px; --rule: 60px; --foot: 860px; }
#frame i { position: absolute; background: var(--line); transition: background-color .4s linear; }
#frame .v { top: 0; bottom: 0; width: 1px; }
#frame .v.l { left: var(--edge); }
#frame .v.r { right: var(--edge); }
#frame .h { left: 0; right: 0; height: 1px; }
#frame .h.t { top: var(--rule); }
#frame .h.b { top: var(--foot); }
#frame p { position: absolute; top: calc(var(--rule) - 30px); margin: 0; font-size: 13px; line-height: 16px; letter-spacing: .01em; }
#frame .mark { left: calc(var(--edge) + 14px); font-weight: 600; }
#frame .mark span, #row .k { opacity: .45; font-weight: 400; }
#frame .term { right: calc(var(--edge) + 14px); opacity: .55; }

.chip { position: absolute; padding: 0; background: none; border: 0; border-radius: 7px; cursor: pointer; z-index: 2; }
.chip::after { content: attr(data-n); position: absolute; left: 0; right: 0; top: calc(100% + 9px); font: 400 10.5px/1 var(--mono); letter-spacing: .02em; text-align: center; color: var(--ink); opacity: .38; transition: opacity .2s; }
.chip:hover::after { opacity: .7; }
.chip[aria-checked="true"]::after { opacity: 1; color: var(--accent); }

#row { position: absolute; left: 48px; right: 48px; padding: 0 14px; height: 0; display: flex; justify-content: space-between; align-items: center; pointer-events: none; font-size: 13px; line-height: 16px; letter-spacing: .01em; z-index: 1; }
#row p { margin: 0; display: flex; gap: 10px; align-items: baseline; }
#row #name { font-weight: 600; }
#row #idx { font: 400 11px/1 var(--mono); opacity: .5; }
#row .right { opacity: .58; transition: opacity .6s; }
.touched #row .right { opacity: .36; }
#row .left { transition: opacity .3s; }
.turning #row .left, .turning #row .right { opacity: 0; transition-duration: .15s; }

/* The sheet: black, ruled, quiet */
#sheet { position: relative; width: min(1180px, 100%); margin: 0 auto; padding: 128px 48px 120px; display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; border-inline: 1px solid var(--space-line); }
#sheet::before { content: ""; position: absolute; inset: 0 0 auto; height: 1px; background: var(--space-line); }
#sheet h2 { grid-column: 1 / -1; margin: 0 0 32px; font-size: clamp(52px, 7.6vw, 104px); line-height: .95; font-weight: 500; letter-spacing: -0.035em; text-wrap: balance; }
#sheet h3 { margin: 0 0 20px; font-size: 15px; line-height: 1.2; font-weight: 600; letter-spacing: .005em; }
#sheet h3::after { content: "/"; margin-left: 2px; color: var(--space-dim); font-weight: 400; }
#sheet section { grid-column: 1 / -1; margin-bottom: 96px; }
#sheet section.limits { margin-bottom: 0; }
#sheet .lede { max-width: 44ch; margin: 0; font-size: clamp(20px, 2vw, 26px); line-height: 1.36; font-weight: 400; color: #c9ccd1; }
#sheet p { max-width: 66ch; color: #b4b8be; }
.limits p { margin: 0; }
table { width: 100%; border-collapse: collapse; border-bottom: 1px solid var(--space-line); }
th, td { padding: 15px 16px 15px 0; text-align: left; vertical-align: baseline; border-top: 1px solid var(--space-line); font-weight: 400; }
td:not(.v) { color: #a9adb3; }
th { width: 13%; font-weight: 600; }
td.v { width: 34%; font: 400 12.5px/1.55 var(--mono); font-variant-numeric: tabular-nums; color: var(--space-ink); }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin: 24px 0; }
.actions button, .actions a { position: relative; font: 600 14px/1 var(--sans); letter-spacing: .01em; color: var(--space-ink); border: 0; border-radius: 999px; padding: 15px 24px; min-height: 46px; cursor: pointer; text-decoration: none; transition: transform .12s cubic-bezier(.2,.8,.2,1), filter .2s; }
/* A polished steel pill: a cold sky in the top half, a dark horizon, the floor bounced up from below */
.actions button {
  color: #0c0d0f;
  background:
    radial-gradient(60% 40% at 82% 22%, rgba(255,255,255,.95), rgba(255,255,255,0) 70%),
    linear-gradient(180deg, #f8f9fb 0%, #e2e5e9 46%, #a3a8b0 70%, #c4c8cd 80%, #f0f2f5 100%);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.55), inset 0 -1px 0 rgba(0,0,0,.35), 0 1px 0 rgba(0,0,0,.6), 0 10px 24px -10px rgba(0,0,0,.8);
}
.actions a { background: none; box-shadow: inset 0 0 0 1px #3a3d43; }
.actions a:hover { box-shadow: inset 0 0 0 1px #6b7078; }
.actions button:active, .actions a:active { transform: translateY(1px) scale(.985); }
.actions button:focus-visible, .actions a:focus-visible, pre:focus-visible { outline: 1px solid var(--temper); outline-offset: 4px; }
.actions button:hover { filter: brightness(1.06); }
#bytes { font: 400 12px/1.4 var(--mono); color: var(--space-dim); }
pre { margin: 0; padding: 26px 28px; max-height: 560px; overflow: auto; background: #040405; color: #d5d8dc; border: 1px solid var(--space-line); border-radius: 4px; font: 400 12.5px/1.75 var(--mono); scrollbar-color: #3a3d42 transparent; white-space: pre-wrap; overflow-wrap: anywhere; }
pre ::selection, #sheet ::selection { background: var(--temper); color: #050506; }

#nogl { display: none; position: absolute; inset: 40% 10% auto; text-align: center; font-size: 20px; }
.no-gl #nogl { display: block; }
.no-gl #stage, .no-gl #sheet { display: none; }

@media (max-width: 800px) {
  #row { left: 16px; right: 16px; font-size: 12.5px; }
  #row .k { display: none; }
  #frame p { font-size: 12.5px; top: calc(var(--rule) - 28px); }
  #frame .v { display: none; }
  #frame .mark { left: 16px; }
  #frame .term { right: 16px; }
  .chip::after { top: calc(100% + 8px); }
  #sheet { padding: 72px 20px 80px; border-inline: 0; }
  #sheet section { margin-bottom: 64px; }
  th, td { display: block; width: auto; padding: 0 0 6px; border: 0; }
  tr { display: block; padding: 14px 0 10px; border-top: 1px solid var(--space-line); }
  td.v { width: auto; }
  #sheet h2 { font-size: 12.4vw; }
  pre { padding: 18px; font-size: 11.5px; }
}
@media (prefers-reduced-motion: reduce) {
  #stage, #frame i { transition: none; }
}
