/* Cassivorn: an editing suite on porcelain. Sharp corners, slab headings,
 * cobalt for links and the edit, vermilion for the playhead and the keys
 * that start a take, dark monitors for every game screen. */

:root {
  --wv-bg: #f5f2ec;
  --wv-paper: #fffdf8;
  --wv-sunk: #ebe6dc;
  --wv-ink: #16122a;
  --wv-mute: #544d68;
  --wv-line: #d6cfc2;
  --wv-cobalt: #3a2fd0;
  --wv-cobalt-deep: #261d9e;
  --wv-cobalt-soft: #e4e2fb;
  --wv-verm: #d8391a;
  --wv-verm-text: #b02c10;
  --wv-verm-hot: #ff6a3d;
  --wv-amber: #ffb22e;
  --wv-violet: #6c4ad6;
  --wv-night: #120e24;
  --wv-night-2: #1d1838;
  --wv-night-3: #2a2450;
  --wv-night-ink: #eeebf8;
  --wv-night-mute: #b3acd0;
  --wv-good: #1f9d63;
  --wv-slab: "Rockwell Nova", Rockwell, "Roboto Slab", "Zilla Slab", Bitter, "DejaVu Serif", Georgia, serif;
  --wv-human: Seravek, "Gill Sans Nova", "Gill Sans", Ubuntu, Calibri, "Segoe UI", "Fira Sans", "DejaVu Sans", sans-serif;
  --wv-mono: "SF Mono", ui-monospace, Menlo, Consolas, "DejaVu Sans Mono", monospace;
  --wv-s1: 4px; --wv-s2: 8px; --wv-s3: 12px; --wv-s4: 16px; --wv-s5: 24px; --wv-s6: 32px; --wv-s7: 48px; --wv-s8: 64px; --wv-s9: 96px;
  --wv-wide: 1240px;
  --wv-gut: 20px;
  --wv-sprocket: repeating-linear-gradient(90deg, transparent 0 7px, var(--wv-bg) 7px 15px, transparent 15px 22px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--wv-bg); color: var(--wv-ink); font: 17px/1.55 var(--wv-human); }
img, svg { display: block; max-width: 100%; height: auto; }
a { color: var(--wv-cobalt); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { color: var(--wv-cobalt-deep); text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--wv-verm-hot); outline-offset: 2px; }
h1, h2, h3 { font-family: var(--wv-slab); font-weight: 700; line-height: 1.12; letter-spacing: -0.01em; margin: 0 0 var(--wv-s4); text-wrap: balance; }
h1 { font-size: clamp(2rem, 1.2rem + 3.2vw, 3.4rem); }
h2 { font-size: clamp(1.45rem, 1.1rem + 1.3vw, 2rem); }
p { margin: 0 0 var(--wv-s4); max-width: 68ch; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
code { font-family: var(--wv-mono); font-size: 0.9em; background: var(--wv-sunk); padding: 1px 5px; }
[hidden] { display: none !important; }

.wv-vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.wv-skip { position: absolute; left: var(--wv-s4); top: -60px; z-index: 90; background: var(--wv-ink); color: #fff; padding: var(--wv-s2) var(--wv-s4); }
.wv-skip:focus { top: var(--wv-s2); color: #fff; }
.wv-ico { width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: square; stroke-linejoin: miter; }
.wv-small { font-size: 0.88rem; color: var(--wv-mute); }

/* ---------- keys ---------- */
.wv-key {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--wv-s2);
  min-height: 46px; padding: 10px 20px; border: 2px solid var(--wv-ink); border-radius: 0;
  background: var(--wv-paper); color: var(--wv-ink); font-weight: 700; text-decoration: none; line-height: 1.2;
  transition: transform 0.14s ease-out, background-color 0.18s ease-out, color 0.18s ease-out, box-shadow 0.18s ease-out;
}
.wv-key:hover { color: var(--wv-ink); text-decoration: none; box-shadow: 4px 4px 0 var(--wv-ink); transform: translate(-2px, -2px); }
.wv-key:active { transform: translate(0, 0); box-shadow: none; }
.wv-key:disabled { opacity: 0.45; cursor: not-allowed; transform: none; box-shadow: none; }
.wv-key--go { background: var(--wv-verm); border-color: var(--wv-verm); color: #fff; }
.wv-key--go:hover { background: var(--wv-verm-text); color: #fff; box-shadow: 4px 4px 0 var(--wv-ink); }
.wv-key--line { background: transparent; }
.wv-key--even { flex: 1; background: var(--wv-paper); }
.wv-key--ghost { border-color: transparent; background: transparent; text-decoration: underline; text-underline-offset: 3px; font-weight: 600; }
.wv-key--ghost:hover { box-shadow: none; transform: none; color: var(--wv-cobalt); }
.wv-key--big { width: 100%; min-height: 56px; font-size: 1.1rem; font-family: var(--wv-slab); }
.wv-textkey { border: 0; background: none; padding: 0; color: var(--wv-cobalt); text-decoration: underline; text-underline-offset: 3px; }
.wv-textlink { font-weight: 700; }
.wv-keyrow { display: flex; flex-wrap: wrap; gap: var(--wv-s2); align-items: center; }

.wv-pill {
  display: inline-flex; align-items: center; gap: 6px; margin: 0 0 var(--wv-s3); padding: 5px 12px 5px 10px;
  border-radius: 999px; background: var(--wv-cobalt-soft); color: var(--wv-cobalt-deep);
  font: 700 0.76rem/1.2 var(--wv-mono); letter-spacing: 0.06em; text-transform: uppercase;
}
.wv-pill .wv-ico { width: 15px; height: 15px; }

/* ---------- header ---------- */
.wv-leader { position: sticky; top: 0; z-index: 40; background: var(--wv-paper); border-bottom: 2px solid var(--wv-ink); }
.wv-strip {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 18px; margin: 0; max-width: none;
  padding: 5px var(--wv-gut); background: var(--wv-ink); color: var(--wv-night-ink); font: 600 0.74rem/1.4 var(--wv-mono); letter-spacing: 0.04em;
}
.wv-strip b { color: var(--wv-amber); }
.wv-leader__bar { display: flex; align-items: center; gap: var(--wv-s4); max-width: var(--wv-wide); margin: 0 auto; padding: 8px var(--wv-gut); }
.wv-mark { display: inline-flex; align-items: center; gap: 10px; color: var(--wv-ink); text-decoration: none; flex: none; }
.wv-mark img { width: 40px; height: 40px; }
.wv-mark__word { font: 700 1.3rem/1 var(--wv-slab); letter-spacing: 0.02em; }
.wv-mark__word i { font-style: normal; color: var(--wv-verm-text); }
.wv-mark:hover { color: var(--wv-ink); }

.wv-path { flex: 1; min-width: 0; }
.wv-path__list { display: flex; align-items: center; gap: 0; margin: 0; padding: 0; list-style: none; font: 600 0.92rem/1.2 var(--wv-human); }
.wv-path__list > li { display: flex; align-items: center; min-width: 0; }
.wv-path__list > li + li::before { content: "/"; margin: 0 10px; color: var(--wv-line); font-family: var(--wv-mono); font-weight: 400; }
.wv-path__list a { color: var(--wv-mute); text-decoration: none; }
.wv-path__list a:hover { color: var(--wv-cobalt); text-decoration: underline; }
.wv-path__here span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--wv-ink); }
.wv-zone { position: relative; }
.wv-zone__key {
  display: inline-flex; align-items: center; gap: 8px; padding: 6px 10px; border: 2px solid var(--wv-ink); background: var(--wv-bg);
  list-style: none; cursor: pointer; white-space: nowrap; transition: background-color 0.16s ease-out;
}
.wv-zone__key::-webkit-details-marker { display: none; }
.wv-zone__key:hover { background: var(--wv-cobalt-soft); }
.wv-zone__tc { font: 700 0.66rem/1 var(--wv-mono); background: var(--wv-verm); color: #fff; padding: 3px 4px; }
.wv-zone__caret { width: 8px; height: 8px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: translateY(-2px) rotate(45deg); transition: transform 0.18s ease-out; }
.wv-zone[open] .wv-zone__caret { transform: translateY(2px) rotate(225deg); }
.wv-zone__menu {
  position: absolute; left: 0; top: calc(100% + 10px); z-index: 50; width: min(360px, 86vw); padding: var(--wv-s2);
  background: var(--wv-night); color: var(--wv-night-ink); border: 2px solid var(--wv-ink); box-shadow: 8px 8px 0 var(--wv-verm);
  transform-origin: top left; animation: wv-drop 0.18s ease-out;
}
@keyframes wv-drop { from { opacity: 0; transform: scale(0.96) translateY(-4px); } to { opacity: 1; transform: none; } }
.wv-zone__row { display: grid; gap: 2px; padding: 10px 12px; color: var(--wv-night-ink); text-decoration: none; border-left: 4px solid transparent; }
.wv-zone__row b { font-family: var(--wv-slab); font-size: 1.05rem; }
.wv-zone__row span { color: var(--wv-night-mute); font-size: 0.86rem; }
.wv-zone__row:hover { background: var(--wv-night-2); color: #fff; border-left-color: var(--wv-amber); }
.wv-zone__row.is-here { border-left-color: var(--wv-verm-hot); background: var(--wv-night-2); }
.wv-zone__foot { margin: 6px 12px 4px; font-size: 0.86rem; color: var(--wv-night-mute); }
.wv-zone__foot a { color: var(--wv-night-ink); }

.wv-leader__tools { display: flex; align-items: center; gap: var(--wv-s2); flex: none; }
.wv-count { display: inline-flex; align-items: baseline; gap: 6px; padding: 6px 10px; background: var(--wv-night); color: var(--wv-amber); text-decoration: none; font-family: var(--wv-mono); }
.wv-count:hover { color: #fff; }
.wv-count__n { font-weight: 700; font-size: 1rem; }
.wv-count__u { font-size: 0.72rem; color: var(--wv-night-mute); text-transform: uppercase; letter-spacing: 0.08em; }
.wv-hold { display: inline-flex; align-items: center; gap: 8px; min-height: 38px; padding: 6px 12px; border: 2px solid var(--wv-violet); background: transparent; color: var(--wv-violet); font-weight: 700; }
.wv-hold:hover { background: var(--wv-violet); color: #fff; }
.wv-hold__ico { width: 10px; height: 12px; border-left: 3px solid currentColor; border-right: 3px solid currentColor; }
.wv-hold.is-on { background: var(--wv-violet); color: #fff; }

/* ---------- main frame ---------- */
.wv-main { max-width: var(--wv-wide); margin: 0 auto; padding: var(--wv-s6) var(--wv-gut) var(--wv-s8); }
.wv-lede { font-size: 1.16rem; color: var(--wv-mute); max-width: 60ch; }

/* ---------- fx: spotlight + tilt ---------- */
[data-spot] { position: relative; isolation: isolate; }
[data-spot]::after {
  content: ""; position: absolute; inset: 0; z-index: 3; pointer-events: none; opacity: 0;
  background: radial-gradient(280px circle at var(--wv-sx, 50%) var(--wv-sy, 50%), rgba(255, 190, 110, 0.16), transparent 62%);
  transition: opacity 0.3s ease-out;
}
@media (hover: hover) and (pointer: fine) { [data-spot]:hover::after { opacity: 1; } }
[data-tilt] { transform: perspective(900px) rotateX(var(--wv-rx, 0deg)) rotateY(var(--wv-ry, 0deg)); transition: transform 0.22s ease-out; }

/* ---------- hero: off-centre object ---------- */
.wv-hero {
  display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: center; gap: var(--wv-s6);
  padding: var(--wv-s6) 0 var(--wv-s7); border-bottom: 2px solid var(--wv-ink);
}
.wv-hero__keys { display: flex; flex-wrap: wrap; gap: var(--wv-s4); align-items: center; }
.wv-hero__facts { display: flex; flex-wrap: wrap; gap: var(--wv-s5); margin: var(--wv-s5) 0 var(--wv-s4); padding: 0; list-style: none; }
.wv-hero__facts li { display: grid; padding-left: var(--wv-s3); border-left: 4px solid var(--wv-cobalt); }
.wv-hero__facts b { font: 700 1.9rem/1.1 var(--wv-slab); }
.wv-hero__facts span { color: var(--wv-mute); font-size: 0.9rem; }
.wv-hero__note { font: 600 0.8rem/1.4 var(--wv-mono); color: var(--wv-mute); letter-spacing: 0.03em; }
.wv-hero__object { position: relative; margin: 0 -8% 0 0; }
.wv-hero__object img { width: 118%; max-width: none; margin-left: -6%; transform: rotate(-7deg); filter: drop-shadow(18px 22px 0 rgba(58, 47, 208, 0.14)); }
.wv-hero__object::before {
  content: ""; position: absolute; z-index: -1; right: 4%; top: 6%; width: 74%; aspect-ratio: 1; background: var(--wv-cobalt);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 22% 100%);
}
.wv-hero__tag {
  position: absolute; left: -2%; bottom: 8%; display: grid; padding: 8px 12px; background: var(--wv-ink); color: var(--wv-night-ink);
  font: 700 0.74rem/1.35 var(--wv-mono); letter-spacing: 0.12em; transform: rotate(-3deg);
}
.wv-hero__tag span:first-child { color: var(--wv-verm-hot); }

/* ---------- the edit (timeline + monitor) ---------- */
.wv-edit { margin: var(--wv-s7) calc(var(--wv-gut) * -1) 0; padding: var(--wv-s6) var(--wv-gut); background: var(--wv-night); color: var(--wv-night-ink); position: relative; }
.wv-edit::before, .wv-edit::after { content: ""; position: absolute; left: 0; right: 0; height: 10px; background: var(--wv-sprocket); opacity: 0.9; }
.wv-edit::before { top: 6px; }
.wv-edit::after { bottom: 6px; }
.wv-edit__head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: var(--wv-s2) var(--wv-s5); margin-bottom: var(--wv-s5); }
.wv-edit__head h2 { margin: 0; }
.wv-edit__head p { margin: 0; color: var(--wv-night-mute); max-width: 62ch; }
.wv-edit__grid { display: grid; gap: var(--wv-s5); }
.wv-edit a { color: #cfc9ff; }

.wv-monitor { border: 2px solid var(--wv-night-3); background: #000; }
.wv-monitor__bar { display: flex; align-items: center; gap: var(--wv-s3); margin: 0; max-width: none; padding: 6px 12px; background: var(--wv-night-2); font: 700 0.76rem/1 var(--wv-mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--wv-night-mute); }
.wv-monitor__rec { width: 9px; height: 9px; border-radius: 50%; background: var(--wv-verm-hot); }
.wv-monitor__tc { margin-left: auto; color: var(--wv-amber); }
.wv-monitor__frame { display: grid; grid-template-columns: minmax(150px, 230px) 1fr; gap: var(--wv-s5); padding: var(--wv-s4); }
.wv-monitor__frame img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border: 2px solid var(--wv-night-3); }
.wv-monitor.is-cut .wv-monitor__frame img, .wv-monitor.is-cut .wv-monitor__info { animation: wv-cut 0.26s ease-out; }
@keyframes wv-cut { from { opacity: 0.25; transform: translateX(6px); } to { opacity: 1; transform: none; } }
.wv-monitor__info { align-self: center; }
.wv-monitor__code { margin: 0 0 6px; font: 700 0.78rem/1.3 var(--wv-mono); color: var(--wv-verm-hot); letter-spacing: 0.08em; text-transform: uppercase; }
.wv-monitor__name { margin: 0 0 var(--wv-s3); font: 700 clamp(1.7rem, 1.2rem + 1.6vw, 2.6rem)/1.05 var(--wv-slab); color: #fff; }
.wv-monitor__info p { color: var(--wv-night-ink); }
.wv-monitor__facts { display: flex; flex-wrap: wrap; gap: var(--wv-s2) var(--wv-s5); margin: 0 0 var(--wv-s4); }
.wv-monitor__facts dt { font: 600 0.7rem/1.3 var(--wv-mono); color: var(--wv-night-mute); text-transform: uppercase; letter-spacing: 0.1em; }
.wv-monitor__facts dd { margin: 0; font-weight: 600; }
.wv-monitor .wv-key--go { color: #fff; }
.wv-monitor .wv-key--go:hover { box-shadow: 4px 4px 0 var(--wv-amber); }

.wv-tracks { --wv-head: 46px; --wv-p: 0.04; position: relative; padding-top: 4px; user-select: none; touch-action: pan-y; }
.wv-ruler { position: relative; height: 24px; margin-left: var(--wv-head); border-bottom: 1px solid var(--wv-night-3); overflow: hidden; }
.wv-ruler__tick { position: absolute; bottom: 0; padding: 0 0 4px 4px; border-left: 1px solid var(--wv-night-mute); font: 600 0.66rem/1 var(--wv-mono); color: var(--wv-night-mute); }
.wv-ruler__tick:nth-child(1) { left: 0; }
.wv-ruler__tick:nth-child(2) { left: 10.87%; }
.wv-ruler__tick:nth-child(3) { left: 21.74%; }
.wv-ruler__tick:nth-child(4) { left: 32.61%; }
.wv-ruler__tick:nth-child(5) { left: 43.48%; }
.wv-ruler__tick:nth-child(6) { left: 54.35%; }
.wv-ruler__tick:nth-child(7) { left: 65.22%; }
.wv-ruler__tick:nth-child(8) { left: 76.09%; }
.wv-ruler__tick:nth-child(9) { left: 86.96%; }
.wv-ruler__tick:nth-child(10) { left: 97.83%; }
.wv-lane { display: grid; grid-template-columns: var(--wv-head) 1fr; align-items: stretch; border-bottom: 1px solid var(--wv-night-3); }
.wv-lane__h { margin: 0; display: grid; place-items: center; background: var(--wv-night-2); font: 700 0.78rem/1 var(--wv-mono); color: var(--wv-night-mute); }
.wv-lane__body { position: relative; height: 72px; background: repeating-linear-gradient(90deg, transparent 0 calc(100% / 46 - 1px), rgba(255, 255, 255, 0.04) calc(100% / 46 - 1px) calc(100% / 46)); }
.wv-lane--audio .wv-lane__body { height: 44px; }
.wv-wave { width: 100%; height: 44px; }
.wv-wave path { stroke: #4fd1a1; stroke-width: 2; opacity: 0.7; }
.wv-blk {
  position: absolute; top: 6px; bottom: 6px; display: flex; flex-direction: column; justify-content: space-between; overflow: hidden;
  padding: 6px 8px; border: 2px solid rgba(255, 255, 255, 0.22); color: #fff; text-decoration: none;
  background-color: var(--wv-night-3); background-size: auto 140%; background-position: left center; background-repeat: repeat-x;
  transition: border-color 0.16s ease-out, transform 0.16s ease-out;
}
.wv-blk::before { content: ""; position: absolute; inset: 0; z-index: 0; background: linear-gradient(90deg, rgba(18, 14, 36, 0.86), rgba(18, 14, 36, 0.35)); }
.wv-blk > * { position: relative; z-index: 1; }
.wv-blk__name { font: 700 0.98rem/1.1 var(--wv-slab); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wv-blk__tc { font: 600 0.66rem/1 var(--wv-mono); color: var(--wv-night-mute); }
.wv-blk:hover { color: #fff; border-color: var(--wv-amber); }
.wv-blk.is-live { border-color: var(--wv-verm-hot); }
.wv-blk.is-live .wv-blk__tc { color: var(--wv-amber); }
.wv-blk--drop-frame { left: 0; width: 19.565%; background-image: url("../img/cover/drop-frame.webp"); }
.wv-blk--jump-cut { left: 13.043%; width: 21.739%; background-image: url("../img/cover/jump-cut.webp"); }
.wv-blk--gel-grade { left: 23.913%; width: 26.087%; background-image: url("../img/cover/gel-grade.webp"); }
.wv-blk--splice-run { left: 43.478%; width: 23.913%; background-image: url("../img/cover/splice-run.webp"); }
.wv-blk--take-21 { left: 56.522%; width: 28.261%; background-image: url("../img/cover/take-21.webp"); }
.wv-blk--light-leak { left: 73.913%; width: 21.739%; background-image: url("../img/cover/light-leak.webp"); }
.wv-playhead {
  position: absolute; top: 0; bottom: 0; width: 26px; margin-left: -13px; cursor: ew-resize; z-index: 4;
  left: calc(var(--wv-head) + (100% - var(--wv-head)) * var(--wv-p));
}
.wv-playhead::before { content: ""; position: absolute; left: 12px; top: 0; bottom: 0; width: 2px; background: var(--wv-verm-hot); box-shadow: 0 0 12px rgba(255, 106, 61, 0.6); }
.wv-playhead__cap { position: absolute; left: 4px; top: 0; width: 18px; height: 16px; background: var(--wv-verm-hot); clip-path: polygon(0 0, 100% 0, 100% 55%, 50% 100%, 0 55%); }
.wv-playhead:focus-visible { outline: none; }
.wv-playhead:focus-visible .wv-playhead__cap { outline: 3px solid var(--wv-amber); outline-offset: 2px; }

/* ---------- numbered rows ---------- */
.wv-rows { margin-top: var(--wv-s7); }
.wv-row { display: grid; grid-template-columns: 132px minmax(0, 1fr); gap: var(--wv-s5); padding: var(--wv-s6) 0; border-top: 2px solid var(--wv-ink); }
.wv-row__no { margin: 0; font: 700 4.6rem/0.9 var(--wv-slab); color: transparent; -webkit-text-stroke: 2px var(--wv-cobalt); letter-spacing: -0.04em; }
.wv-row:nth-child(even) .wv-row__no { -webkit-text-stroke-color: var(--wv-verm); }
.wv-row__body > :last-child { margin-bottom: 0; }
.wv-statline { display: flex; flex-wrap: wrap; gap: var(--wv-s2) var(--wv-s5); padding: var(--wv-s3) var(--wv-s4); background: var(--wv-paper); border-left: 4px solid var(--wv-verm); font-size: 0.96rem; max-width: none; }
.wv-statline b { font-family: var(--wv-mono); }

.wv-ticks, .wv-steps { margin: 0 0 var(--wv-s4); padding: 0; list-style: none; max-width: 72ch; }
.wv-ticks li, .wv-steps li { position: relative; padding: 8px 0 8px 34px; border-bottom: 1px solid var(--wv-line); }
.wv-ticks li::before { content: ""; position: absolute; left: 4px; top: 16px; width: 14px; height: 8px; border-left: 3px solid var(--wv-cobalt); border-bottom: 3px solid var(--wv-cobalt); transform: rotate(-45deg); }
.wv-steps { counter-reset: wv-step; }
.wv-steps li { counter-increment: wv-step; }
.wv-steps li::before { content: counter(wv-step); position: absolute; left: 0; top: 8px; width: 24px; height: 24px; display: grid; place-items: center; background: var(--wv-ink); color: #fff; font: 700 0.8rem/1 var(--wv-mono); }

.wv-scroll { overflow-x: auto; margin: 0 0 var(--wv-s4); border: 2px solid var(--wv-ink); background: var(--wv-paper); }
.wv-table { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
.wv-table caption { text-align: left; padding: 8px 12px; font-weight: 700; }
.wv-table th, .wv-table td { padding: 9px 12px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--wv-line); }
.wv-table thead th { background: var(--wv-ink); color: var(--wv-night-ink); font: 700 0.76rem/1.3 var(--wv-mono); text-transform: uppercase; letter-spacing: 0.06em; white-space: nowrap; }
.wv-table tbody tr:nth-child(even) { background: #faf7f1; }
.wv-table--num td { font-family: var(--wv-mono); font-size: 0.9rem; white-space: nowrap; }

.wv-qas { border-top: 1px solid var(--wv-line); }
.wv-qa { border-bottom: 1px solid var(--wv-line); }
.wv-qa summary { display: flex; justify-content: space-between; gap: var(--wv-s4); padding: 14px 0; font: 700 1.06rem/1.35 var(--wv-slab); cursor: pointer; list-style: none; }
.wv-qa summary::-webkit-details-marker { display: none; }
.wv-qa summary::after { content: "+"; flex: none; width: 26px; height: 26px; display: grid; place-items: center; border: 2px solid var(--wv-ink); font-family: var(--wv-mono); transition: transform 0.18s ease-out; }
.wv-qa[open] summary::after { transform: rotate(45deg); background: var(--wv-verm); color: #fff; border-color: var(--wv-verm); }
.wv-qa__a { padding: 0 0 var(--wv-s3); color: var(--wv-mute); }

.wv-notecards { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: var(--wv-s4); margin: var(--wv-s4) 0 0; padding: 0; list-style: none; }
.wv-notecards--index { margin-top: var(--wv-s5); }
.wv-notecard { display: grid; gap: 6px; height: 100%; padding: 0 0 var(--wv-s4); background: var(--wv-paper); border: 2px solid var(--wv-ink); color: var(--wv-ink); text-decoration: none; transition: transform 0.16s ease-out, box-shadow 0.16s ease-out; }
.wv-notecard img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border-bottom: 2px solid var(--wv-ink); }
.wv-notecard > :not(img) { padding: 0 var(--wv-s4); }
.wv-notecard__k { margin-top: 6px; font: 700 0.72rem/1.2 var(--wv-mono); color: var(--wv-verm-text); text-transform: uppercase; letter-spacing: 0.08em; }
.wv-notecard b { font: 700 1.14rem/1.2 var(--wv-slab); }
.wv-notecard span:last-child { color: var(--wv-mute); font-size: 0.94rem; }
.wv-notecard:hover { color: var(--wv-ink); transform: translate(-3px, -3px); box-shadow: 6px 6px 0 var(--wv-cobalt); }

/* ---------- intros (inner pages) ---------- */
.wv-intro { padding: var(--wv-s4) 0 var(--wv-s5); }
.wv-intro--care, .wv-intro--about { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--wv-s6); align-items: center; }
.wv-intro__pic { margin: 0; }
.wv-intro__pic img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border: 2px solid var(--wv-ink); box-shadow: 10px 10px 0 var(--wv-violet); }
.wv-intro--about .wv-intro__pic img { box-shadow: 10px 10px 0 var(--wv-verm); }
.wv-status { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 2px; margin: var(--wv-s4) 0 0; background: var(--wv-ink); border: 2px solid var(--wv-ink); }
.wv-status div { padding: 10px 12px; background: var(--wv-paper); }
.wv-status dt { font: 700 0.7rem/1.3 var(--wv-mono); text-transform: uppercase; letter-spacing: 0.08em; color: var(--wv-mute); }
.wv-status dd { margin: 0; font-weight: 700; }
.wv-intro--lost { text-align: left; padding: var(--wv-s8) 0; }

/* ---------- timeline list ---------- */
.wv-shots { margin: var(--wv-s4) 0 0; padding: 0; list-style: none; border-top: 2px solid var(--wv-ink); }
.wv-shot__link {
  display: grid; grid-template-columns: 64px 96px minmax(0, 1fr) 220px; gap: var(--wv-s5); align-items: center;
  padding: var(--wv-s4) var(--wv-s3); border-bottom: 2px solid var(--wv-ink); color: var(--wv-ink); text-decoration: none;
  transition: background-color 0.16s ease-out;
}
.wv-shot__link:hover { background: var(--wv-paper); color: var(--wv-ink); }
.wv-shot__no { font: 700 2.4rem/1 var(--wv-slab); color: var(--wv-verm-text); }
.wv-shot__img { width: 96px; aspect-ratio: 3 / 4; object-fit: cover; border: 2px solid var(--wv-ink); transition: transform 0.2s ease-out; }
.wv-shot__link:hover .wv-shot__img { transform: rotate(-3deg) scale(1.04); }
.wv-shot__text { display: grid; gap: 4px; }
.wv-shot__code { font: 700 0.74rem/1.2 var(--wv-mono); color: var(--wv-cobalt); text-transform: uppercase; letter-spacing: 0.08em; }
.wv-shot__text b { font: 700 1.5rem/1.1 var(--wv-slab); }
.wv-shot__text span:last-child { color: var(--wv-mute); }
.wv-shot__meta { display: grid; gap: 6px; font-size: 0.9rem; color: var(--wv-mute); border-left: 2px solid var(--wv-line); padding-left: var(--wv-s4); }

/* ---------- clip page ---------- */
.wv-cliphead { display: grid; grid-template-columns: minmax(0, 1fr) minmax(220px, 340px); gap: var(--wv-s7); align-items: center; padding-bottom: var(--wv-s6); }
.wv-cliphead__art { margin: 0 4% 0 0; }
.wv-cliphead__art img { width: 100%; border: 3px solid var(--wv-ink); transform: rotate(3deg); box-shadow: -12px 12px 0 var(--wv-cobalt); }
.wv-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 0; margin: 0 0 var(--wv-s5); border-top: 2px solid var(--wv-ink); }
.wv-facts div { padding: 10px 12px 10px 0; border-bottom: 1px solid var(--wv-line); }
.wv-facts dt { font: 700 0.7rem/1.3 var(--wv-mono); text-transform: uppercase; letter-spacing: 0.08em; color: var(--wv-mute); }
.wv-facts dd { margin: 0; font-weight: 700; }
.wv-cliphead__go { display: flex; flex-wrap: wrap; gap: var(--wv-s4); align-items: center; }

.wv-viewer { display: grid; grid-template-columns: minmax(0, 1fr) 320px; margin: 0 calc(var(--wv-gut) * -1); background: var(--wv-night); color: var(--wv-night-ink); border-top: 2px solid var(--wv-ink); border-bottom: 2px solid var(--wv-ink); scroll-margin-top: 110px; }
.wv-viewer__screen { scroll-margin-top: 128px; min-height: 520px; display: grid; place-items: center; padding: var(--wv-s7) var(--wv-s5) var(--wv-s6); overflow: hidden; }
.wv-viewer__bg { position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%; object-fit: cover; opacity: 0.38; }
.wv-safe { position: absolute; inset: 18px; z-index: 0; pointer-events: none; border: 1px dashed rgba(255, 255, 255, 0.16); }
.wv-safe::before, .wv-safe::after { content: ""; position: absolute; width: 22px; height: 22px; border: 3px solid var(--wv-verm-hot); }
.wv-safe::before { left: -3px; top: -3px; border-right: 0; border-bottom: 0; }
.wv-safe::after { right: -3px; bottom: -3px; border-left: 0; border-top: 0; }
.wv-tc { position: absolute; top: 24px; right: 30px; margin: 0; z-index: 2; font: 700 0.8rem/1 var(--wv-mono); color: var(--wv-amber); letter-spacing: 0.12em; }
.wv-viewer__slate { position: absolute; top: 24px; left: 30px; margin: 0; z-index: 2; font: 700 0.76rem/1 var(--wv-mono); color: var(--wv-night-mute); letter-spacing: 0.1em; text-transform: uppercase; }
.wv-stage { position: relative; z-index: 1; width: 100%; display: grid; justify-items: center; gap: var(--wv-s4); }
.wv-lock { position: absolute; inset: 0; z-index: 5; display: grid; place-content: center; gap: var(--wv-s2); padding: var(--wv-s6); text-align: center; background: rgba(18, 14, 36, 0.94); }
.wv-lock p { margin: 0 auto; }
.wv-lock__h { font: 700 1.7rem/1.2 var(--wv-slab); color: #fff; }
.wv-lock__keys { display: flex; flex-wrap: wrap; gap: var(--wv-s2); justify-content: center; margin-top: var(--wv-s3) !important; }
.wv-lock .wv-key--line { color: #fff; border-color: #fff; }
.wv-lock .wv-key--ghost { color: #cfc9ff; }

.wv-inspector { padding: var(--wv-s5); background: var(--wv-night-2); border-left: 2px solid var(--wv-night-3); display: flex; flex-direction: column; gap: var(--wv-s4); }
.wv-inspector__h { margin: 0; font: 700 0.76rem/1 var(--wv-mono); text-transform: uppercase; letter-spacing: 0.14em; color: var(--wv-night-mute); }
.wv-bal { display: flex; justify-content: space-between; align-items: baseline; margin: 0; padding: 10px 12px; background: #000; font-family: var(--wv-mono); }
.wv-bal span { font-size: 0.78rem; color: var(--wv-night-mute); text-transform: uppercase; letter-spacing: 0.08em; }
.wv-bal b { font-size: 1.5rem; color: var(--wv-amber); }
.wv-stakes { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; margin: 0; padding: 0; border: 0; min-width: 0; }
.wv-opts { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; border: 0; min-width: 0; }
.wv-stakes legend, .wv-opts legend { width: 100%; margin-bottom: 6px; font: 700 0.72rem/1.2 var(--wv-mono); text-transform: uppercase; letter-spacing: 0.08em; color: var(--wv-night-mute); }
.wv-stake, .wv-opt { min-width: 50px; min-height: 40px; padding: 6px 10px; border: 2px solid var(--wv-night-3); background: var(--wv-night); color: var(--wv-night-ink); font: 700 0.92rem/1 var(--wv-mono); transition: border-color 0.14s ease-out, background-color 0.14s ease-out; }
.wv-stakes .wv-stake { min-width: 0; padding: 6px 2px; }
.wv-stake:hover, .wv-opt:hover { border-color: var(--wv-night-mute); }
.wv-stake[aria-pressed="true"], .wv-opt[aria-pressed="true"] { border-color: var(--wv-amber); background: var(--wv-amber); color: var(--wv-night); }
.wv-stake:disabled, .wv-opt:disabled { opacity: 0.4; cursor: not-allowed; }
.wv-inspector .wv-small { color: var(--wv-night-mute); }
.wv-inspector a { color: #cfc9ff; }
.wv-inspector .wv-key--go:hover { box-shadow: 4px 4px 0 var(--wv-amber); }
.wv-inspector .wv-key--line { color: #fff; border-color: var(--wv-night-mute); }
.wv-result { min-height: 3.2em; margin: 0; padding: 10px 12px; border-left: 4px solid var(--wv-night-3); background: rgba(0, 0, 0, 0.3); font-weight: 600; }
.wv-result[data-tone="up"] { border-left-color: var(--wv-amber); }
.wv-result[data-tone="even"] { border-left-color: var(--wv-night-mute); }
.wv-result[data-tone="down"] { border-left-color: var(--wv-violet); }
.wv-sess { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px; margin: 0; }
.wv-sess div { padding: 6px 4px; background: var(--wv-night); text-align: center; }
.wv-sess dt { font: 600 0.62rem/1.2 var(--wv-mono); text-transform: uppercase; letter-spacing: 0.06em; color: var(--wv-night-mute); }
.wv-sess dd { margin: 0; font: 700 0.9rem/1.3 var(--wv-mono); }
.wv-viewer.is-locked .wv-stage { filter: blur(3px); }

.wv-thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: var(--wv-s4); margin: 0; padding: 0; list-style: none; }
.wv-thumb { display: grid; gap: 4px; color: var(--wv-ink); text-decoration: none; }
.wv-thumb img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border: 2px solid var(--wv-ink); transition: transform 0.18s ease-out, box-shadow 0.18s ease-out; }
.wv-thumb:hover { color: var(--wv-ink); }
.wv-thumb:hover img { transform: translate(-3px, -3px); box-shadow: 6px 6px 0 var(--wv-verm); }
.wv-thumb__code { font: 700 0.7rem/1.2 var(--wv-mono); color: var(--wv-cobalt); }
.wv-thumb b { font: 700 1.08rem/1.2 var(--wv-slab); }
.wv-thumb span:last-child { font-size: 0.88rem; color: var(--wv-mute); }

/* ---------- games ---------- */
.wv-board { width: min(100%, 470px); }
.wv-pins circle { fill: #d9d4ee; }
.wv-gates rect { fill: rgba(255, 255, 255, 0.06); stroke: rgba(255, 255, 255, 0.24); stroke-width: 1.5; transition: fill 0.2s ease-out; }
.wv-gates text { font: 700 11px/1 var(--wv-mono); fill: var(--wv-night-ink); }
.wv-gates [data-heat="hot"] rect { stroke: var(--wv-verm-hot); }
.wv-gates [data-heat="warm"] rect { stroke: var(--wv-amber); }
.wv-gates .is-hit rect { fill: var(--wv-verm-hot); }
.wv-gates .is-hit text { fill: #fff; }
.wv-ball { fill: var(--wv-verm-hot); stroke: #fff; stroke-width: 2; transition: transform 0.11s ease-out; }

.wv-cutbay { width: min(100%, 560px); display: grid; justify-items: center; gap: var(--wv-s4); }
.wv-cutbay__strip { display: flex; gap: 6px; min-height: 58px; padding: 8px 10px; background: #000; border-top: 6px dotted var(--wv-night-mute); border-bottom: 6px dotted var(--wv-night-mute); }
.wv-cutbay__now { min-height: 168px; display: grid; place-items: center; }
.wv-card { width: 116px; height: 164px; display: grid; place-content: center; justify-items: center; gap: 2px; background: #fffef9; color: #17122a; border: 2px solid #fff; box-shadow: 0 10px 24px rgba(0, 0, 0, 0.45); animation: wv-card-in 0.24s ease-out; }
.wv-card b { font: 700 2.6rem/1 var(--wv-slab); }
.wv-card span { font-size: 2rem; line-height: 1; }
.wv-card.is-red { color: #c0281a; }
.wv-card--frame { width: 38px; height: 50px; box-shadow: none; animation: none; }
.wv-card--frame b { font-size: 0.95rem; }
.wv-card--frame span { font-size: 0.8rem; }
.wv-card.is-back { background: repeating-linear-gradient(45deg, var(--wv-cobalt) 0 8px, var(--wv-cobalt-deep) 8px 16px); border-color: #fff; }
@keyframes wv-card-in { from { opacity: 0; transform: scale(0.95) translateY(8px); } to { opacity: 1; transform: none; } }
.wv-ladder { margin: 0; text-align: center; font: 700 1rem/1.4 var(--wv-mono); color: var(--wv-amber); }
.wv-calls, .wv-acts { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--wv-s2); }
.wv-key--call { display: grid; gap: 2px; min-width: 132px; background: var(--wv-night-2); color: #fff; border-color: var(--wv-night-mute); }
.wv-key--call span { font: 600 0.72rem/1.2 var(--wv-mono); color: var(--wv-night-mute); }
.wv-key--call:hover { color: #fff; box-shadow: 4px 4px 0 var(--wv-amber); }
.wv-stage .wv-key--ghost { color: #cfc9ff; }
.wv-stage .wv-small { color: var(--wv-night-mute); text-align: center; width: 100%; }

.wv-grid { display: grid; gap: 4px; width: min(100%, 470px); padding: 8px; background: rgba(0, 0, 0, 0.5); border: 2px solid var(--wv-night-3); }
.wv-grid[data-cols="7"] { grid-template-columns: repeat(7, 1fr); }
.wv-grid[data-cols="6"] { grid-template-columns: repeat(6, 1fr); width: min(100%, 420px); }
.wv-tile { aspect-ratio: 1; display: grid; place-items: center; background: rgba(255, 255, 255, 0.07); transition: transform 0.2s ease-out, opacity 0.2s ease-out, background-color 0.2s ease-out; }
.wv-tile img { width: 86%; height: auto; }
.wv-tile.is-new { animation: wv-fall 0.26s ease-out; }
@keyframes wv-fall { from { opacity: 0; transform: translateY(-14px); } to { opacity: 1; transform: none; } }
.wv-tile.is-lit { background: rgba(255, 178, 46, 0.38); box-shadow: inset 0 0 0 2px var(--wv-amber); transform: scale(1.06); }
.wv-tile.is-gone { opacity: 0; transform: scale(0.95); }
.wv-meter { margin: 0; min-height: 1.5em; text-align: center; font: 600 0.9rem/1.4 var(--wv-mono); color: var(--wv-amber); max-width: 58ch; }
.wv-splices { display: flex; gap: 4px; margin: 0; padding: 0; list-style: none; }
.wv-splices li { padding: 4px 10px; border: 2px solid var(--wv-night-3); font: 700 0.82rem/1 var(--wv-mono); color: var(--wv-night-mute); transition: background-color 0.18s ease-out, color 0.18s ease-out; }
.wv-splices li.is-on { background: var(--wv-verm-hot); border-color: var(--wv-verm-hot); color: #fff; }

.wv-table21 { width: min(100%, 560px); display: grid; gap: var(--wv-s5); }
.wv-seat { padding: var(--wv-s3); border: 2px dashed rgba(255, 255, 255, 0.18); }
.wv-seat__h { display: flex; justify-content: space-between; margin: 0 0 var(--wv-s2); font: 700 0.8rem/1 var(--wv-mono); text-transform: uppercase; letter-spacing: 0.1em; color: var(--wv-night-mute); max-width: none; }
.wv-seat__h span { color: var(--wv-amber); }
.wv-seat__cards { display: flex; flex-wrap: wrap; gap: 8px; min-height: 120px; }
.wv-seat .wv-card { width: 82px; height: 116px; }
.wv-seat .wv-card b { font-size: 1.9rem; }
.wv-seat .wv-card span { font-size: 1.4rem; }

.wv-leak { width: min(100%, 620px); display: grid; gap: var(--wv-s2); }
.wv-exposure { margin: 0; font: 700 clamp(2.4rem, 1.6rem + 3vw, 3.8rem)/1 var(--wv-mono); color: #fff; text-align: center; transition: color 0.2s ease-out; }
.wv-leak.is-held .wv-exposure { color: var(--wv-amber); }
.wv-leak.is-leak .wv-exposure { color: var(--wv-verm-hot); }
.wv-chart { width: 100%; background: rgba(0, 0, 0, 0.55); border: 2px solid var(--wv-night-3); }
.wv-chart__grid { stroke: rgba(255, 255, 255, 0.07); }
.wv-chart__axis { stroke: var(--wv-night-mute); }
.wv-chart__cue { stroke-width: 2; stroke-dasharray: 6 5; }
.wv-chart__cue--first { stroke: #8fd3ff; }
.wv-chart__cue--final { stroke: var(--wv-amber); }
.wv-chart__label { font: 700 12px/1 var(--wv-mono); fill: var(--wv-night-ink); }
.wv-chart__run { fill: none; stroke: #fff; stroke-width: 3; stroke-linejoin: round; }
.wv-chart__head { fill: var(--wv-verm-hot); }
.wv-leak.is-leak .wv-chart { background: radial-gradient(circle at 85% 40%, rgba(255, 106, 61, 0.45), rgba(0, 0, 0, 0.55) 60%); }

/* ---------- rushes ---------- */
.wv-ranks { display: grid; grid-template-columns: repeat(6, 1fr); gap: 0; margin: 0; padding: 14px 0; list-style: none; background: var(--wv-night); position: relative; }
.wv-ranks::before, .wv-ranks::after { content: ""; position: absolute; left: 0; right: 0; height: 8px; background: var(--wv-sprocket); }
.wv-ranks::before { top: 3px; }
.wv-ranks::after { bottom: 3px; }
.wv-rank { display: grid; gap: 2px; padding: 12px; margin: 0 2px; background: var(--wv-night-2); color: var(--wv-night-mute); }
.wv-rank__no { font: 700 0.72rem/1 var(--wv-mono); }
.wv-rank b { font: 700 1rem/1.2 var(--wv-slab); color: var(--wv-night-ink); }
.wv-rank span:last-child { font-size: 0.8rem; }
.wv-rank.is-done { background: var(--wv-night-3); }
.wv-rank.is-here { background: var(--wv-verm); color: #fff; }
.wv-rank.is-here b { color: #fff; }
.wv-slates { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: var(--wv-s3); margin: 0; padding: 0; list-style: none; }
.wv-slate { display: grid; gap: 2px; padding: var(--wv-s3); background: var(--wv-paper); border: 2px solid var(--wv-line); color: var(--wv-mute); }
.wv-slate__mark { color: var(--wv-line); }
.wv-slate__mark .wv-ico { width: 28px; height: 28px; }
.wv-slate b { color: var(--wv-ink); font-family: var(--wv-slab); }
.wv-slate span:not(.wv-slate__mark) { font-size: 0.86rem; }
.wv-slate__state { font-family: var(--wv-mono); }
.wv-slate.is-on { border-color: var(--wv-ink); box-shadow: 4px 4px 0 var(--wv-cobalt); }
.wv-slate.is-on .wv-slate__mark { color: var(--wv-verm); }
.wv-slate.is-on .wv-slate__state { color: var(--wv-cobalt-deep); font-weight: 700; }

/* ---------- intermission ---------- */
.wv-check ol { margin: 0 0 var(--wv-s4); padding: 0; list-style: none; counter-reset: wv-q; }
.wv-check li { counter-increment: wv-q; padding: 10px 0; border-bottom: 1px solid var(--wv-line); }
.wv-scale { margin: 0; padding: 0; border: 0; }
.wv-scale legend { padding: 0; margin-bottom: 8px; font-weight: 700; }
.wv-scale legend::before { content: counter(wv-q, decimal-leading-zero) "  "; font-family: var(--wv-mono); color: var(--wv-verm-text); }
.wv-scale label { display: inline-flex; align-items: center; gap: 6px; margin: 0 14px 6px 0; cursor: pointer; }
.wv-scale input { width: 18px; height: 18px; accent-color: var(--wv-cobalt); }
.wv-check__out { padding: var(--wv-s3) var(--wv-s4); background: var(--wv-cobalt-soft); font-weight: 600; }
.wv-check__out:empty { display: none; }
.wv-row .wv-opt { border-color: var(--wv-ink); background: var(--wv-paper); color: var(--wv-ink); font-family: var(--wv-human); }
.wv-row .wv-opt[aria-pressed="true"] { background: var(--wv-ink); border-color: var(--wv-ink); color: #fff; }

/* ---------- notes ---------- */
.wv-note__head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 420px); gap: var(--wv-s6); align-items: center; }
.wv-note__pic { margin: 0; }
.wv-note__pic img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border: 2px solid var(--wv-ink); box-shadow: 10px -10px 0 var(--wv-amber); }
.wv-note__next { margin-top: var(--wv-s6); padding-top: var(--wv-s4); border-top: 2px solid var(--wv-ink); font-weight: 700; }

/* ---------- contact + docs ---------- */
.wv-form { max-width: 620px; }
.wv-form label { display: block; margin-bottom: 4px; font-weight: 700; }
.wv-form input, .wv-form select, .wv-form textarea { width: 100%; padding: 10px 12px; border: 2px solid var(--wv-ink); border-radius: 0; background: var(--wv-paper); }
.wv-form input:focus-visible, .wv-form select:focus-visible, .wv-form textarea:focus-visible { outline-offset: 0; }
.wv-trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.wv-flash { padding: var(--wv-s3) var(--wv-s4); font-weight: 700; border-left: 6px solid; }
.wv-flash--ok { background: #e3f5ec; border-color: var(--wv-good); }
.wv-flash--bad { background: #fde7e1; border-color: var(--wv-verm); }
.wv-toc ol { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; list-style: none; counter-reset: wv-toc; }
.wv-toc li { counter-increment: wv-toc; }
.wv-toc a { display: inline-block; padding: 5px 10px; border: 1px solid var(--wv-line); background: var(--wv-paper); font-size: 0.9rem; text-decoration: none; }
.wv-toc a::before { content: counter(wv-toc, decimal-leading-zero) " "; font-family: var(--wv-mono); color: var(--wv-verm-text); }
.wv-rows--doc .wv-row__no { font-size: 3rem; }
.wv-rows--doc .wv-row { padding: var(--wv-s5) 0; }
.wv-doclist { display: grid; gap: 0; margin: var(--wv-s4) 0 0; padding: 0; list-style: none; border-top: 2px solid var(--wv-ink); }
.wv-doclink { display: grid; grid-template-columns: minmax(180px, 280px) 1fr; gap: var(--wv-s4); padding: var(--wv-s4) var(--wv-s2); border-bottom: 2px solid var(--wv-ink); color: var(--wv-ink); text-decoration: none; }
.wv-doclink b { font: 700 1.25rem/1.2 var(--wv-slab); }
.wv-doclink span { color: var(--wv-mute); }
.wv-doclink:hover { background: var(--wv-paper); color: var(--wv-cobalt-deep); }

/* ---------- footer: one band ---------- */
.wv-tail { background: var(--wv-ink); color: var(--wv-night-ink); border-top: 6px solid var(--wv-verm); }
.wv-tail__in { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: var(--wv-s5) var(--wv-s7); max-width: var(--wv-wide); margin: 0 auto; padding: var(--wv-s6) var(--wv-gut) var(--wv-s5); }
.wv-tail a { color: #d8d3ff; }
.wv-tail a:hover { color: #fff; }
.wv-tail__lead { font-size: 1.04rem; }
.wv-tail__lead strong { color: var(--wv-amber); }
.wv-tail__say p:not(.wv-tail__lead) { color: var(--wv-night-mute); }
.wv-tail__h { margin: 0 0 var(--wv-s2); font: 700 0.74rem/1.3 var(--wv-mono); text-transform: uppercase; letter-spacing: 0.1em; color: var(--wv-night-mute); }
.wv-tail__help ul { margin: 0; padding: 0; list-style: none; font-size: 0.94rem; }
.wv-tail__help li { padding: 4px 0; border-bottom: 1px solid rgba(255, 255, 255, 0.1); }
.wv-tail__links { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 6px 18px; padding: var(--wv-s4) 0; border-top: 1px solid rgba(255, 255, 255, 0.16); border-bottom: 1px solid rgba(255, 255, 255, 0.16); font-weight: 600; }
.wv-tail__links .wv-textkey { color: #d8d3ff; font-weight: 600; }
.wv-tail__base { grid-column: 1 / -1; margin: 0; max-width: none; font-size: 0.86rem; color: var(--wv-night-mute); }

/* ---------- overlays ---------- */
.wv-gate { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: var(--wv-s4); background: rgba(18, 14, 36, 0.9); }
.wv-gate__card { width: min(520px, 100%); padding: var(--wv-s6); background: var(--wv-paper); border: 3px solid var(--wv-ink); box-shadow: 12px 12px 0 var(--wv-verm); }
.wv-gate__card img { width: 72px; height: 72px; margin-bottom: var(--wv-s3); }
.wv-gate__q { font: 700 1.5rem/1.2 var(--wv-slab); }
.wv-gate__keys { display: flex; flex-wrap: wrap; gap: var(--wv-s2); margin-bottom: var(--wv-s3); }

.wv-drawer {
  position: fixed; right: 0; top: 0; bottom: 0; z-index: 80; width: min(380px, 92vw); overflow-y: auto;
  padding: var(--wv-s6) var(--wv-s5); background: var(--wv-paper); border-left: 3px solid var(--wv-ink); box-shadow: -14px 0 0 rgba(58, 47, 208, 0.18);
  animation: wv-slide 0.26s ease-out;
}
@keyframes wv-slide { from { transform: translateX(24px); opacity: 0; } to { transform: none; opacity: 1; } }
.wv-drawer__h { font: 700 1.3rem/1.25 var(--wv-slab); }
.wv-drawer__keys { display: flex; gap: var(--wv-s2); }

.wv-sheet { position: fixed; inset: 0; z-index: 95; display: grid; place-items: center; padding: var(--wv-s4); background: rgba(18, 14, 36, 0.78); }
.wv-sheet__card { width: min(500px, 100%); padding: var(--wv-s5); background: var(--wv-paper); border: 3px solid var(--wv-ink); box-shadow: 10px 10px 0 var(--wv-violet); animation: wv-card-in 0.2s ease-out; }
.wv-sheet__h { font: 700 1.4rem/1.2 var(--wv-slab); }
.wv-sheet__keys { display: flex; flex-wrap: wrap; gap: var(--wv-s2); margin-bottom: var(--wv-s3); }
.wv-sheet__facts { display: grid; grid-template-columns: auto 1fr; gap: 4px 16px; margin: 0 0 var(--wv-s4); font-family: var(--wv-mono); }
.wv-sheet__facts dt { color: var(--wv-mute); }
.wv-sheet__facts dd { margin: 0; font-weight: 700; }
.wv-toast { position: fixed; left: 50%; bottom: 20px; z-index: 120; margin: 0; max-width: min(520px, 92vw); padding: 12px 18px; background: var(--wv-ink); color: #fff; border-left: 5px solid var(--wv-amber); opacity: 0; transform: translate(-50%, 10px); pointer-events: none; transition: opacity 0.2s ease-out, transform 0.2s ease-out; }
.wv-toast.is-up { opacity: 1; transform: translate(-50%, 0); }

/* ---------- calm + reduced motion ---------- */
.wv-calm *, .wv-calm *::before, .wv-calm *::after { animation: none !important; transition: none !important; }
.wv-calm [data-tilt] { transform: none !important; }
.wv-calm [data-spot]::after { display: none; }
.wv-calm .wv-tile.is-lit { transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  [data-tilt] { transform: none !important; }
}

/* ---------- narrower screens ---------- */
@media (max-width: 1020px) {
  .wv-viewer { grid-template-columns: 1fr; }
  .wv-inspector { border-left: 0; border-top: 2px solid var(--wv-night-3); }
  .wv-shot__link { grid-template-columns: 48px 80px minmax(0, 1fr); }
  .wv-shot__meta { display: none; }
  .wv-ranks { grid-template-columns: repeat(3, 1fr); row-gap: 4px; }
}
@media (max-width: 860px) {
  .wv-leader__bar { flex-wrap: wrap; }
  .wv-path { order: 3; flex-basis: 100%; }
  .wv-leader__tools { margin-left: auto; }
  .wv-hero, .wv-intro--care, .wv-intro--about, .wv-note__head, .wv-cliphead { grid-template-columns: minmax(0, 1fr); }
  .wv-hero__object { margin: 0 auto; width: min(420px, 90%); }
  .wv-hero__object img { width: 100%; margin: 0; }
  .wv-cliphead__art { width: min(260px, 70%); margin: 0 auto; order: -1; }
  .wv-row { grid-template-columns: minmax(0, 1fr); gap: var(--wv-s2); }
  .wv-row__no { font-size: 3rem; }
  .wv-monitor__frame { grid-template-columns: 110px 1fr; gap: var(--wv-s3); }
  .wv-tail__in { grid-template-columns: minmax(0, 1fr); }
  .wv-doclink { grid-template-columns: 1fr; gap: 2px; }
}
@media (max-width: 560px) {
  :root { --wv-gut: 16px; }
  body { font-size: 16px; }
  .wv-strip { font-size: 0.66rem; gap: 2px 10px; }
  .wv-mark__word { font-size: 1.1rem; }
  .wv-count__u { display: none; }
  .wv-main { padding-top: var(--wv-s5); }
  .wv-tracks { --wv-head: 34px; }
  .wv-lane__body { height: 60px; }
  .wv-blk { padding: 4px; }
  .wv-blk__name { font-size: 0.76rem; }
  .wv-blk__tc { display: none; }
  .wv-ruler__tick:nth-child(even) { display: none; }
  .wv-monitor__frame { grid-template-columns: 1fr; }
  .wv-monitor__frame img { width: 140px; }
  .wv-viewer__screen { min-height: 0; padding: var(--wv-s7) var(--wv-s2) var(--wv-s5); }
  .wv-tc, .wv-viewer__slate { top: 26px; }
  .wv-viewer__slate { left: 22px; font-size: 0.66rem; }
  .wv-tc { right: 22px; font-size: 0.7rem; }
  .wv-grid { gap: 2px; padding: 4px; }
  .wv-card { width: 96px; height: 136px; }
  .wv-key--call { min-width: 112px; }
  .wv-seat .wv-card { width: 62px; height: 88px; }
  .wv-seat .wv-card b { font-size: 1.4rem; }
  .wv-ranks { grid-template-columns: repeat(2, 1fr); }
  .wv-shot__link { grid-template-columns: 64px minmax(0, 1fr); gap: var(--wv-s3); }
  .wv-shot__no { display: none; }
  .wv-shot__img { width: 64px; }
  .wv-hero__facts b { font-size: 1.5rem; }
  .wv-gate__card { padding: var(--wv-s5); }
}
