
:root {
  --night: #070b12;
  --night-2: #0c121c;
  --night-3: #141c29;
  --line: #243041;
  --pale: #e7ebe0;
  --mist: #a2adb1;
  --dim: #7b878d;
  --flash: #c9f25c;
  --f: 0;
  --r: 0;
  --serif: 'Spectral', Georgia, serif;
  --mono: 'DM Mono', ui-monospace, Consolas, monospace;
  --fig: 'Cutive Mono', 'DM Mono', monospace;
  --math: 'STIX Two Text', 'Times New Roman', serif;
  --lit: color-mix(in srgb, var(--flash) calc(var(--f) * 100%), var(--pale));
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box; }
html { background: var(--night); scrollbar-color: var(--line) var(--night); -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--night); color: var(--pale); font: 300 18px/1.55 var(--serif); overflow-x: hidden; }
::selection { background: var(--flash); color: var(--night); }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--night); }
::-webkit-scrollbar-thumb { background: var(--line); border-radius: 5px; }
a { color: inherit; text-underline-offset: .22em; text-decoration-color: var(--line); }
a:hover { text-decoration-color: currentColor; }
:focus-visible { outline: 2px solid var(--flash); outline-offset: 3px; border-radius: 2px; }
canvas { display: block; }
h1, h2, h3 { font-family: var(--serif); font-weight: 200; letter-spacing: -.015em; line-height: 1.04; margin: 0; text-wrap: balance; }
p { margin: 0; text-wrap: pretty; }
.num { font-family: var(--fig); font-weight: 400; font-variant-numeric: tabular-nums; letter-spacing: -.05em; }
.data { font: 400 13px/1.5 var(--mono); font-variant-numeric: tabular-nums; color: var(--mist); }
.math { font-family: var(--math); }

/* The action: pale at rest, only the flash lights it */
.release {
  display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: 0 28px;
  font: 400 18px/1 var(--serif); color: var(--night); text-decoration: none; cursor: pointer; white-space: nowrap;
  background: var(--lit); border: 0; border-radius: 3px;
  box-shadow: 0 2px calc(var(--f) * 34px) color-mix(in srgb, var(--flash) calc(var(--f) * 70%), transparent);
  transition: transform .18s cubic-bezier(.16,1,.3,1);
}
.release:hover { transform: translateY(-2px); }
.release:active { transform: translateY(0); }

.bar { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 22px clamp(16px, 3vw, 40px); font-size: 16px; }
.bar nav { display: flex; gap: clamp(14px, 2vw, 28px); }
.bar nav a { text-decoration: none; color: var(--mist); }
.bar nav a:hover { color: var(--pale); }
.mark { font: 300 24px/1 var(--serif); text-decoration: none; color: var(--lit); letter-spacing: -.01em; }

/* every number here is simulated: the tag says so on each page */
.demo { font: 400 12px/1.4 var(--mono); color: var(--dim); }
select.pair, input.field {
  height: 52px; padding: 0 14px; background: var(--night-2); color: var(--pale); border: 1px solid var(--line);
  border-radius: 3px; font: 400 15px var(--mono);
}
select.pair:hover, input.field:hover { border-color: var(--mist); }

.full { position: absolute; inset: 0; width: 100%; height: 100%; }

@media (max-width: 720px) {
  body { font-size: 17px; }
  .bar nav a.opt { display: none; }
}
/* site */
.bar nav { align-items: center; }
.bar nav a[aria-current="page"] { color: var(--pale); }
.xbtn { display: inline-grid; place-items: center; width: 38px; height: 38px; border: 1px solid var(--line); border-radius: 3px; color: var(--pale); }
.xbtn:hover { border-color: var(--mist); }
.xbtn svg { width: 15px; height: 15px; fill: currentColor; }
.bar .release { min-height: 38px; padding: 0 16px; font-size: 16px; }
main.page { max-width: 1120px; margin: 0 auto; padding: clamp(20px, 4vw, 56px) clamp(16px, 3vw, 40px) 80px; }
main.page > h1 { font-size: clamp(38px, 5.4vw, 76px); margin-bottom: 18px; max-width: 18ch; }
.lead { color: var(--mist); max-width: 62ch; }
.prose { max-width: 68ch; }
.prose h2 { font-size: clamp(26px, 3vw, 38px); margin: 52px 0 14px; }
.prose p { margin-bottom: 14px; color: #c3cbc8; }
.prose ul { padding-left: 20px; color: #c3cbc8; } .prose li { margin-bottom: 8px; }
.prose b { font-weight: 400; color: var(--pale); }
.foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 28px; padding: 24px clamp(16px, 3vw, 40px); border-top: 1px solid var(--line); font-size: 15px; color: var(--mist); }
.foot nav { display: flex; flex-wrap: wrap; gap: 8px 22px; } .foot a { color: var(--mist); }
.book { display: grid; grid-template-columns: 1fr 1fr; margin: 0 clamp(16px, 3vw, 40px); border: 1px solid var(--line); position: relative; min-height: calc(100svh - 110px); }
.book::after { content: ""; position: absolute; left: 50%; top: 0; bottom: 0; width: 1px; background: var(--line); }
.leaf { padding: clamp(22px, 3.6vw, 56px); position: relative; min-width: 0; }
.leaf h1 { font-size: clamp(38px, 5vw, 76px); margin-bottom: 28px; }
.leaf p { max-width: 44ch; color: var(--mist); margin-bottom: 20px; }
.formula { font: 400 clamp(20px, 2vw, 27px)/1.5 var(--math); color: var(--pale); margin: 26px 0 8px; }
.formula-note { font: 400 13px/1.5 var(--mono); color: var(--mist); margin-bottom: 30px; }
.plate { display: grid; grid-template-rows: 1fr auto; padding: 0; }
.plate figure { margin: 0; position: relative; min-height: 420px; }
.plate figcaption { display: flex; justify-content: space-between; gap: 12px; padding: 14px 22px; border-top: 1px solid var(--line); flex-wrap: wrap; }
.note { position: absolute; font: 400 12.5px/1.35 var(--mono); color: var(--mist); max-width: 170px; }
.note b { display: block; font: 400 34px/1 var(--fig); color: var(--lit); letter-spacing: -.05em; }
.n1 { left: 22px; top: 22px; } .n2 { right: 22px; top: 22px; text-align: right; }
.sect { max-width: 1120px; margin: 0 auto; padding: 72px clamp(16px, 3vw, 40px) 0; }
.sect h2 { font-size: clamp(30px, 3.6vw, 50px); margin-bottom: 22px; max-width: 22ch; }
.row { display: grid; grid-template-columns: minmax(0,1.1fr) minmax(0,1.6fr) 90px; gap: 18px; align-items: center; min-height: 56px; padding: 8px 0; border-bottom: 1px solid #18212e; color: inherit; text-decoration: none; }
a.row:hover { background: var(--night-2); }
.row .pn { font: 300 23px/1.1 var(--serif); } .row .nm { font-size: 16px; color: var(--mist); } .row .ct { text-align: right; font: 400 22px var(--fig); }
details { border-bottom: 1px solid #18212e; padding: 16px 0; } summary { cursor: pointer; font-size: 21px; font-weight: 300; }
details p { color: var(--mist); max-width: 66ch; margin-top: 10px; }
.empty { border: 1px solid var(--line); padding: 28px; color: var(--mist); max-width: 66ch; }
.fig { position: relative; border: 1px solid var(--line); margin: 14px 0 6px; }
.fig canvas { width: 100%; }
.cap { margin-bottom: 34px; font: 400 13px/1.5 var(--mono); color: var(--mist); }
.deck { display: flex; flex-wrap: wrap; gap: 18px 32px; align-items: center; padding: 16px 0; }
.deck .num { font-size: 58px; line-height: 1; color: var(--lit); }
.deck label { flex: 1 1 260px; display: grid; gap: 6px; font: 400 13px var(--mono); color: var(--mist); }
input[type=range] { width: 100%; height: 26px; accent-color: var(--pale); background: transparent; }
.ghost { min-height: 44px; padding: 0 18px; background: transparent; color: var(--pale); border: 1px solid var(--line); border-radius: 3px; font: 300 17px var(--serif); cursor: pointer; }
.ghost:hover { border-color: var(--mist); }
a.ghost { display: inline-flex; align-items: center; text-decoration: none; }
.lgrid { display: grid; grid-template-columns: minmax(0,1.25fr) minmax(0,1fr); gap: clamp(24px, 4vw, 64px); align-items: start; margin-top: 28px; }
.f { display: grid; gap: 6px; margin-bottom: 18px; align-content: start; }
.f label, .lab { font-size: 16px; color: var(--pale); } .f small { font: 400 12.5px/1.45 var(--mono); color: var(--mist); }
.inp { width: 100%; min-height: 48px; padding: 10px 14px; background: var(--night-2); color: var(--pale); border: 1px solid var(--line); border-radius: 3px; font: 400 15px var(--mono); }
.inp:hover { border-color: var(--mist); } textarea.inp { resize: vertical; }
.inp::placeholder { color: var(--dim); }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.drop { display: grid; grid-template-columns: 112px 1fr; gap: 16px; align-items: center; padding: 12px; border: 1px dashed var(--line); border-radius: 3px; cursor: pointer; margin-bottom: 18px; position: relative; }
.drop:hover, .drop.over { border-color: var(--mist); }
.drop .pic { width: 112px; height: 112px; background: var(--night-2) center/cover no-repeat; border-radius: 3px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.chips button { min-height: 34px; padding: 0 12px; background: transparent; color: var(--mist); border: 1px solid var(--line); border-radius: 3px; font: 400 13px var(--mono); cursor: pointer; }
.chips button:hover { color: var(--pale); border-color: var(--mist); }
.card { position: sticky; top: 20px; border: 1px solid var(--line); padding: 22px; display: grid; gap: 14px; }
.card .pv { display: grid; grid-template-columns: 84px 1fr; gap: 14px; align-items: center; }
.card .pv i { display: block; width: 84px; height: 84px; background: var(--night-2) center/cover no-repeat; border-radius: 3px; }
.card .pv b { display: block; font: 300 25px/1.1 var(--serif); overflow-wrap: anywhere; } .card .pv span { font: 400 14px var(--mono); color: var(--mist); overflow-wrap: anywhere; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; margin: 0; font: 400 13px/1.5 var(--mono); }
.kv dt { color: var(--mist); } .kv dd { margin: 0; text-align: right; overflow-wrap: anywhere; }
.card .release { width: 100%; } .release[disabled] { opacity: .5; cursor: not-allowed; transform: none; }
.log { list-style: none; margin: 0; padding: 0; font: 400 13px/1.55 var(--mono); color: var(--mist); display: grid; gap: 6px; }
.log .ok { color: var(--pale); } .log .bad { color: #ffb4a2; } .log a { color: var(--pale); }
.banner { border: 1px solid var(--line); padding: 14px 16px; margin-top: 18px; color: #c3cbc8; font-size: 16px; }
.coin { display: grid; grid-template-columns: minmax(0,260px) minmax(0,1fr); gap: 32px; align-items: start; }
.coin img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 3px; background: var(--night-2); }
@media (max-width: 860px) {
  .book, .lgrid, .coin { grid-template-columns: 1fr; } .book::after { display: none; } .plate { border-top: 1px solid var(--line); }
  .card { position: static; } .row { grid-template-columns: minmax(0,1fr) 60px; } .row .nm { display: none; }
}
@media (max-width: 520px) { .two { grid-template-columns: 1fr; gap: 0; } .bar { gap: 10px; } .bar .release { padding: 0 10px; font-size: 14px; } .bar nav > a:first-child { display: none; } }

.bar nav a.release, .bar nav a.release[aria-current="page"] { color: var(--night); }
