/* The verdict (verdict.js): Arachne close up, the tablet she speaks through,
   the heap of threads and the scroll that explains each one.

   One ASCII scene. Every object is drawn in glyphs on the same cell grid as
   her portrait and the temple (16px JetBrains Mono, 20px lines): +==+ [ ]
   bronze tablets, ._. | stone, (@)==(@) scroll rods, ~^~ cocoons, jagged
   shards. Behind each edge is an opaque dark face (the site's --face-*
   tokens), and the words on it are real text: mono for labels and actions,
   Literata for anything you read at length. No gradients, no shadows, no
   painted materials. Contrast on the faces: body 14:1, secondary >= 8:1. */

.vd {
  --band: 600px;
  --vd-cell: 20px;                       /* one line of the frame grid */
  --vd-face: var(--face-tablet, #19150f);
  --vd-edge: var(--edge-tablet, rgb(168, 132, 79));
  /* risk, on the dark faces (all >= 7:1 on #19150f) */
  --r-critical: #ff8a73;
  --r-high: #ffb36b;
  --r-medium: #ead08a;
  --r-low: #a9c6d8;
  --r-info: #b9c2d0;

  position: fixed;
  inset: 0;
  z-index: 100;
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
  background: var(--bg, #0b0e18);
  color: var(--text-body, #efe6d4);
  font-family: var(--font-mono);
  font-size: 16px;
  line-height: 1.5;
}
.vd[hidden] { display: none; }
html.vd-open, html.vd-open body { overflow: hidden; }

.vd-sr, .vd-probe {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: pre-wrap;
}
.vd-probe { width: auto; height: auto; clip: none; clip-path: none; visibility: hidden; white-space: pre; font: 400 16px/20px var(--font-mono); }

/* the page's terminal decorations (styles.css) belong to the log, not here */
.vd h2, .vd h3, .vd h4 { display: block; text-transform: none; }
.vd h2::before, .vd h2::after, .vd h3::before, .vd h3::after, .vd summary::before { content: none; }
.vd details { margin: 0; }
.vd summary { text-transform: none; color: inherit; list-style: none; }
.vd summary::-webkit-details-marker { display: none; }

/* ---------- Frames ---------- */

[data-frame], .vd-thing { position: relative; isolation: isolate; }
.vd-fr {
  position: absolute;
  top: 0;
  left: 0;
  z-index: -1;
  margin: 0;
  padding: 0;
  font: 400 16px/var(--vd-cell) var(--font-mono);
  letter-spacing: 0;
  white-space: pre;
  color: var(--vd-edge);
  background: var(--vd-face);
  pointer-events: none;
  user-select: none;
  font-variant-ligatures: none;
}
.vd-fr i { font-style: normal; }
.vd-fr .c, .vd-fr .k { color: var(--gold); }
.vd-fr .t { color: var(--text-strong); }
.vd-fr .r-critical { color: var(--r-critical); font-weight: 700; }
.vd-fr .r-high { color: var(--r-high); font-weight: 700; }
.vd-fr .r-medium { color: var(--r-medium); }
.vd-fr .r-low { color: var(--r-low); }
.vd-fr .r-info { color: var(--r-info); }

/* ---------- Buttons: the site's [ BRACKETED ] actions ---------- */

.vd-btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 4px;
  border: 0;
  background: none;
  color: var(--silver);
  font: 500 15px/1.3 var(--font-mono);
  letter-spacing: var(--tracking-caps, 0.06em);
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
}
.vd-btn::before { content: "[ "; color: var(--ornament); }
.vd-btn::after { content: " ]"; color: var(--ornament); }
.vd-btn:hover, .vd-btn:focus-visible { background: var(--silver); color: var(--bg); }
.vd-btn:hover::before, .vd-btn:hover::after, .vd-btn:focus-visible::before, .vd-btn:focus-visible::after { color: inherit; }
.vd-btn.vd-primary { color: var(--gold); font-weight: 700; }
.vd-btn.vd-primary::after { content: " ] >>"; }
.vd-btn.vd-primary:hover, .vd-btn.vd-primary:focus-visible { background: var(--gold); color: var(--bg); }
.vd-btn[hidden] { display: none; }
.vd-btn:focus-visible, .vd a:focus-visible, .vd summary:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 3px;
}

/* ---------- The scene: her portrait and the hanging tablet ---------- */

.vd-scene { position: relative; min-height: var(--band); }
.vd-portrait { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.vd-scene-inner {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: flex-end;
  padding: calc(var(--band) * 0.13) max(4vw, 24px) 32px;
  pointer-events: none;
}

.vd-tablet {
  pointer-events: auto;
  width: min(660px, 52vw);
  padding: 30px 40px 20px;
}
.vd-tablet-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 16px;
  margin-bottom: 14px;
}
.vd-tablet h2 {
  margin: 0;
  font: 700 18px/1.3 var(--font-mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
}
.vd-tablet h2:focus { outline: none; }
.vd-seals { display: flex; flex-wrap: wrap; gap: 4px 14px; margin: 0; font: 500 14px/1.4 var(--font-mono); color: var(--text-muted); }
.vd-seal::before { content: "< "; color: var(--ornament); }
.vd-seal::after { content: " >"; color: var(--ornament); }
.vd-seal-grade { color: var(--text-strong); }
.vd-seal-demo { color: var(--r-high); }

/* Her words: long prose, so the serif, large and loose */
.vd-speech {
  min-height: 7em;
  font-family: var(--font-prose);
  font-size: clamp(18px, 0.5vw + 13px, 20px);
  line-height: 1.65;
  color: var(--text-body);
  text-wrap: pretty;
  cursor: pointer;
}
.vd-speech p, .vd-quip p { margin: 0 0 0.75em; }
.vd-speech p:last-child, .vd-quip p:last-child { margin-bottom: 0; }
.vd-speech.vd-typed { cursor: auto; }

.vd-ch { visibility: hidden; position: relative; }
.vd-ch.on { visibility: visible; transition: color 0.6s ease-out, text-shadow 0.8s ease-out; }
.vd-ch.lit { color: var(--gold); text-shadow: 0 0 5px rgba(227, 174, 95, 0.55); transition: none; }
.vd-ch.rune { color: transparent; }
.vd-ch.rune::after {
  content: attr(data-g);
  position: absolute;
  left: 50%;
  top: 0;
  transform: translateX(-50%);
  color: #cdb0ff;
  text-shadow: 0 0 6px rgba(190, 140, 255, 0.7);
}

.vd-em { font-weight: 600; }
.vd-em-critical { color: var(--r-critical); }
.vd-em-high { color: var(--r-high); }
.vd-em-medium { color: var(--r-medium); }
.vd-em-low, .vd-em-info { color: var(--r-low); }
.vd-em-gold { color: var(--gold); }
a.vd-em { cursor: pointer; text-decoration: none; }
/* underlined once she has finished (a line under unspoken words would show) */
.vd-typed a.vd-em { text-decoration: underline 1px; text-underline-offset: 4px; text-decoration-color: currentColor; }
.vd-typed a.vd-em:hover { text-decoration-thickness: 2px; }

.vd-tablet-foot { display: flex; justify-content: flex-end; max-width: none; margin: 10px 0 0; padding: 0; z-index: auto; }
.vd-tablet-foot .vd-btn { font-size: 14px; color: var(--text-muted); }

/* ---------- The heap ---------- */

.vd-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 460px);
  gap: 40px;
  max-width: 1480px;
  margin: 0 auto;
  padding: 12px max(4vw, 24px) 24px;
}
.vd-heap-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px 24px;
}
.vd-heap-head h3 {
  margin: 0;
  font: 700 18px/1.3 var(--font-mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
}
.vd-heap-head h3::before { content: "-=[ "; color: var(--ornament); }
.vd-heap-head h3::after { content: " ]=-"; color: var(--ornament); }
.vd-legend { display: flex; flex-wrap: wrap; gap: 4px 18px; margin: 0; font: 400 15px/1.5 var(--font-mono); color: var(--text-muted); }
.vd-legend[hidden] { display: none; }
.vd-legend i { font-style: normal; color: var(--ornament); margin-right: 4px; }
.vd-hint { margin: 10px 0 0; max-width: 62ch; font: 400 15px/1.55 var(--font-mono); color: var(--text-muted); }
.vd-hint[hidden] { display: none; }

.vd-heap { position: relative; min-height: 120px; margin-top: 16px; }
.vd-web {
  position: absolute;
  top: 0;
  margin: 0;
  font: 400 16px/var(--vd-cell) var(--font-mono);
  white-space: pre;
  color: var(--strand-faint, rgba(127, 147, 166, 0.55));
  pointer-events: none;
  user-select: none;
}
.vd-web i { font-style: normal; }
.vd-web .r { color: rgba(227, 174, 95, 0.55); }
.vd-web .k { color: var(--gold); }
.vd-web .l { color: var(--strand); }
.vd-pile { list-style: none; margin: 0; padding: 0; }

.vd-li {
  position: absolute;
  left: 0; top: 0;
  transform: translate(var(--x), var(--y));
}
.vd-li:hover, .vd-li:focus-within, .vd-li.vd-pinned { z-index: 999 !important; }
/* pieces fall in whole rows, like everything else on the grid */
.vd-li.vd-drop { animation: vd-fall 0.62s steps(16, end) var(--d) backwards; }
@keyframes vd-fall {
  0% { transform: translate(var(--x), calc(var(--y) - 320px)); opacity: 0; }
  10% { opacity: 1; }
  100% { transform: translate(var(--x), var(--y)); }
}

.vd-thing {
  appearance: none;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: var(--vd-cell) 2ch 0 2.5ch;
  border: 0;
  background: none;
  color: var(--text-body);
  font: inherit;
  text-align: left;
  cursor: pointer;
  --vd-face: #17130e;
}
.vd-thing:focus { outline: none; }

/* each kind of object in its own material, all in glyphs */
.vd-k-tablet { --vd-edge: var(--edge-tablet); }
.vd-k-scroll { --vd-edge: #c9a46a; padding-left: 3ch; padding-right: 3ch; }
.vd-k-cocoon { --vd-edge: #b8c2d0; --vd-face: #15171e; padding-left: 2.5ch; }
.vd-k-shard  { --vd-edge: #c98c6a; --vd-face: #1a120e; }
.vd-k-veil   { --vd-edge: #a99cc8; --vd-face: #16131f; }
.vd-k-veil .vd-title { font-style: italic; }

/* risk: the riskiest wear their colour on the edge, and critical ones glint */
.vd-risk-critical { --vd-edge: var(--r-critical); }
.vd-risk-critical .vd-fr .e { text-shadow: 0 0 6px rgba(255, 138, 115, 0.55); }
.vd-risk-high .vd-fr .c { color: var(--r-high); }

.vd-label { display: flex; flex-direction: column; min-width: 0; }
.vd-title {
  font: 600 15px/var(--vd-cell) var(--font-mono);
  color: var(--text-strong);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  overflow: hidden;
  min-height: calc(var(--vd-cell) * 2);
}
.vd-meta {
  font: 400 14px/var(--vd-cell) var(--font-mono);
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.vd-short .vd-meta { display: none; }

/* pointing lights the edge; focus and pinning light it brighter */
.vd-thing:hover { --vd-face: #221c13; }
.vd-thing:hover .vd-fr .e { color: var(--text-strong); }
.vd-thing:focus-visible { --vd-face: #2a2216; }
.vd-thing:focus-visible .vd-fr, .vd-thing:focus-visible .vd-fr .e, .vd-thing:focus-visible .vd-fr .c { color: var(--focus); font-weight: 700; }
.vd-pinned .vd-thing { --vd-face: #2a2216; }
.vd-pinned .vd-thing .vd-fr .e, .vd-pinned .vd-thing .vd-fr .c { color: var(--gold); font-weight: 700; }
.vd-pinned .vd-thing .vd-title::before { content: "> "; color: var(--gold); }

.vd-nothing {
  --vd-face: var(--face-stone);
  --vd-edge: var(--edge-stone);
  max-width: 600px;
  margin: 8px auto 0;
  padding: 28px 3ch 20px;
  font: 400 18px/1.6 var(--font-prose);
  color: var(--text-body);
}
.vd-nothing strong { display: block; font: 700 16px/1.5 var(--font-mono); color: var(--gold); margin-bottom: 4px; }
.vd-heap.vd-empty { height: auto !important; }

.vd-notes {
  margin-top: 28px;
  font: 400 15px/1.6 var(--font-mono);
  color: var(--text-muted);
}
.vd-notes[hidden] { display: none; }
.vd-notes h4 { margin: 0 0 6px; font: 700 14px/1.4 var(--font-mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--silver); }
.vd-notes h4::before { content: "// "; color: var(--ornament); }
.vd-notes ul { margin: 0 0 10px; padding: 0; list-style: none; }
.vd-notes li::before { content: ":: "; color: var(--ornament); }
.vd-notes code { font: inherit; color: var(--text-body); }
.vd-notes p { margin: 0 0 6px; }

/* ---------- Is this you? Unclaimed cocoons hanging beside the heap ---------- */

.vd-claims { margin-top: 36px; }
.vd-claims[hidden] { display: none; }
.vd-claims h3:focus { outline: none; }
.vd-cocoons {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr));
  gap: 12px 24px;
}
.vd-claims-main { margin-top: 8px; }
.vd-claims details > summary {
  margin-top: 18px;
  cursor: pointer;
  font: 500 15px/2 var(--font-mono);
  color: var(--silver);
}
.vd-claims details > summary::before { content: "[+] "; color: var(--ornament); }
.vd-claims details[open] > summary::before { content: "[-] "; }
.vd-claims details[hidden] { display: none; }
.vd-claims details > .vd-hint { margin-bottom: 8px; }

/* each hangs on a silk thread from the web above */
.vd-cocoon {
  --vd-edge: #b8c2d0;
  --vd-face: #15171e;
  margin-top: var(--vd-cell);
  padding: var(--vd-cell) 2.5ch 6px;
  min-width: 0;
  font: 400 15px/var(--vd-cell) var(--font-mono);
}
.vd-fr .s { color: rgba(184, 194, 208, 0.5); }
.vd-silk { position: absolute; left: 50%; top: calc(var(--vd-cell) * -1); width: 1ch; font: 400 16px/var(--vd-cell) var(--font-mono); color: var(--strand, #7f93a6); }
.vd-silk::before { content: "|"; }
.vd-cocoon p { margin: 0; }
.vd-claim-kind { color: var(--text-muted); font-size: 14px; }
.vd-claim-what { font: 600 16px/1.45 var(--font-mono); color: var(--text-strong); overflow-wrap: anywhere; margin: 2px 0; }
.vd-claim-what a { color: var(--text-strong); text-decoration: underline 1px; text-underline-offset: 3px; text-decoration-color: var(--ornament); }
.vd-claim-what a:hover { text-decoration-color: currentColor; }
.vd-claim-where { color: var(--text-muted); font-size: 14px; }
.vd-claim-why { font: 400 16px/1.5 var(--font-prose); color: var(--text-body); margin-top: 2px !important; }
.vd-claim-items { margin-top: 6px; }
.vd-claim-items summary { cursor: pointer; color: var(--text-muted); font-size: 14px; }
.vd-claim-items ol { margin: 6px 0 0; padding-left: 20px; max-height: 260px; overflow-y: auto; }
.vd-claim-items li { margin-bottom: 6px; overflow-wrap: anywhere; font-size: 14px; }
.vd-claim-quote { display: block; color: var(--text-muted); font-style: italic; }
.vd-sources-more summary { cursor: pointer; color: var(--text-muted); font-size: 14px; }
.vd-claim-acts { display: flex; flex-wrap: wrap; gap: 2px 16px; margin: 8px 0 2px; }
.vd-claim-acts .vd-btn { font-size: 15px; }
.vd-btn.vd-yes { color: var(--gold); font-weight: 700; }
.vd-btn.vd-yes:hover, .vd-btn.vd-yes:focus-visible { background: var(--gold); color: var(--bg); }
.vd-btn:disabled { opacity: 0.55; cursor: default; }
.vd-claim-state { color: var(--text-muted); font-size: 14px; }
.vd-claim-state:empty { display: none; }

/* claimed: wrapped tight in gold silk, then it drops toward the heap;
   disowned: its thread snaps and it falls away */
.vd-claimed { --vd-edge: var(--gold); }
.vd-claimed .vd-silk::before { content: "|"; color: var(--gold); }
.vd-cut .vd-silk::before { content: "x"; color: var(--r-critical); }
.vd-cut { --vd-edge: rgba(184, 194, 208, 0.5); }
.vd-cocoon.vd-gone { animation: vd-drop-away 0.6s steps(10, end) forwards; pointer-events: none; }
.vd-cut.vd-gone { animation-name: vd-cut-away; }
@keyframes vd-drop-away {
  0% { transform: none; opacity: 1; }
  100% { transform: translateY(-160px); opacity: 0; }
}
@keyframes vd-cut-away {
  0% { transform: none; opacity: 1; }
  100% { transform: translateY(140px); opacity: 0; }
}

/* the score after a review: it lights while it counts */
.vd-seal b { font-weight: inherit; }
.vd-seal-grade.vd-moved { color: var(--gold); font-weight: 700; }

/* ---------- The scroll of details ---------- */

.vd-detail {
  position: sticky;
  top: 12px;
  align-self: start;
  max-height: calc(100vh - 24px);
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 40px 0 24px;
  scrollbar-width: thin;
  scrollbar-color: var(--strand) transparent;
}
/* it hangs from two threads, knotted to the rod */
.vd-detail::before, .vd-detail::after {
  content: "|\A|";
  position: absolute;
  top: 0;
  font: 400 16px/20px var(--font-mono);
  white-space: pre;
  color: var(--strand);
  pointer-events: none;
}
.vd-detail::before { left: 24%; }
.vd-detail::after { right: 24%; }
.vd-scroll { padding: 28px 4ch 26px; }
.vd-remark-label, .vd-sheet h4 {
  margin: 0 0 4px;
  font: 700 13px/1.5 var(--font-mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--silver);
}
.vd-remark-label::before, .vd-sheet h4::before { content: "// "; color: var(--ornament); }
.vd-quip {
  min-height: 3.3em;
  font: italic 400 18px/1.6 var(--font-prose);
  color: var(--text-strong);
  text-wrap: pretty;
}
.vd-quip-idle { color: var(--text-muted); }
.vd-rule { margin: 14px -1ch 12px; height: 20px; overflow: hidden; font: 400 16px/20px var(--font-mono); color: var(--vd-edge); white-space: nowrap; }
.vd-rule::before { content: "-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-"; }

.vd-sheet {
  font: 400 17px/1.6 var(--font-prose);
  color: var(--text-body);
  text-wrap: pretty;
}
.vd-sheet h3 {
  margin: 6px 0 10px;
  font: 600 21px/1.35 var(--font-prose);
  color: var(--text-strong);
}
.vd-sheet h4 { margin: 20px 0 6px; }
.vd-sheet p { margin: 0 0 8px; }
.vd-sheet a { color: var(--gold); text-decoration: underline 1px; text-underline-offset: 3px; }
.vd-sheet a.vd-btn { text-decoration: none; }
.vd-sheet code { font: 400 15px var(--font-mono); color: var(--text-strong); word-break: break-all; }
.vd-kicker { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; margin: 0; font: 500 14px/1.5 var(--font-mono); color: var(--text-muted); }
.vd-kicker span + span::before { content: "/ "; color: var(--ornament); }
.vd-risk { font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; }
.vd-kicker .vd-risk + span::before { content: "/ "; }
.vd-risk.vd-risk-critical { color: var(--r-critical); }
.vd-risk.vd-risk-high { color: var(--r-high); }
.vd-risk.vd-risk-medium { color: var(--r-medium); }
.vd-risk.vd-risk-low { color: var(--r-low); }
.vd-risk.vd-risk-info { color: var(--r-info); }
.vd-why { font-size: 18px; }
.vd-facts { display: grid; grid-template-columns: auto 1fr; gap: 2px 16px; margin: 10px 0 0; }
.vd-facts div { display: contents; }
.vd-facts dt { font: 500 14px/1.75 var(--font-mono); color: var(--text-muted); }
.vd-facts dd { margin: 0; }
.vd-sources { margin: 0; padding: 0; list-style: none; }
.vd-sources li { margin-bottom: 4px; overflow-wrap: anywhere; font: 400 15px/1.5 var(--font-mono); }
.vd-small { font-size: 15.5px; color: var(--text-muted); }
.vd-proof { margin: 6px 0 10px; padding: 6px 10px; border-left: 2px solid var(--gold, #e3ae5f); overflow-wrap: anywhere; }
.vd-proof code { font: 400 14px/1.5 var(--font-mono); color: var(--text); white-space: normal; }
.vd-masked-note { font-style: italic; }
/* verifying a masked thread's email: a small in-world prompt on the scroll */
.vd-verify-form { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; margin: 8px 0 2px; }
.vd-verify-form label { flex: 1 0 100%; margin: 0; }
.vd-input {
  flex: 1 1 16ch;
  min-width: 0;
  min-height: 44px;
  padding: 6px 10px;
  border: 1px solid var(--ornament);
  border-radius: 0;
  background: rgba(0, 0, 0, 0.35);
  color: var(--text-strong, #f3ead7);
  font: 400 16px/1.3 var(--font-mono);
}
.vd-input.vd-code { flex: 0 1 11ch; letter-spacing: 0.3em; }
.vd-input:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.vd-verify-msg:empty { display: none; }
.vd-steps { margin: 6px 0 8px; padding-left: 0; list-style: none; counter-reset: step; }
.vd-steps li { counter-increment: step; margin-bottom: 6px; padding-left: 3.2ch; position: relative; }
.vd-steps li::before { content: counter(step) "."; position: absolute; left: 0; font: 600 15px/1.75 var(--font-mono); color: var(--gold); }
.vd-links { margin: 8px 0 0; padding: 0; list-style: none; }
.vd-links li { margin-bottom: 4px; }
.vd-links li::before { content: "-> "; font-family: var(--font-mono); color: var(--ornament); }

/* the removal letter: a stone slip inside the scroll */
.vd-letter {
  --vd-face: var(--face-stone);
  --vd-edge: var(--edge-stone);
  margin: 6px 0 14px;
  padding: 26px 2.5ch 14px;
}
.vd-letter-head { font-size: 18px; }
.vd-letter-to { display: flex; gap: 10px; align-items: baseline; }
.vd-letter-to span { font: 500 14px var(--font-mono); color: var(--text-muted); }
.vd-letter-actions { display: flex; flex-wrap: wrap; gap: 0 14px; margin: 6px 0 2px; }
.vd-letter-text summary { cursor: pointer; font: 500 14px/2.4 var(--font-mono); color: var(--silver); text-transform: uppercase; letter-spacing: 0.06em; }
.vd-letter-text summary::before { content: "[+] "; color: var(--ornament); }
.vd-letter-text[open] summary::before { content: "[-] "; }
.vd-letter-text pre {
  margin: 4px 0 0;
  padding: 10px 0 0;
  max-height: 260px;
  overflow: auto;
  white-space: pre-wrap;
  font: 400 14px/1.6 var(--font-mono);
  color: var(--text-body);
  border-top: 1px dashed var(--strand);
}
.vd-copied:empty { display: none; }
.vd-sheet-foot { margin-top: 14px; display: flex; justify-content: flex-end; }
.vd-sheet-foot .vd-small { font-family: var(--font-mono); font-size: 14px; }

/* ---------- What next ---------- */

.vd-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px 22px;
  padding: 24px max(4vw, 16px) 56px;
}

/* ---------- Arachne's notes: the case file on a tablet of its own ----------
   One row per list: its name and count, then its values as small buttons
   (gold: confirmed, muted: suspected, faint and slanted: unchecked claims).
   A value unrolls where she found it under its row. */

.vd-dossier { margin-top: 36px; }
.vd-dossier[hidden] { display: none; }
.vd-dossier-face {
  --vd-edge: var(--ornament);
  --vd-face: #13110d;
  margin-top: 14px;
  padding: var(--vd-cell) 3ch 6px;
  font: 400 15px/1.5 var(--font-mono);
}
.vd-dos { margin: 0; }
.vd-dos-row {
  display: grid;
  grid-template-columns: 14ch minmax(0, 1fr);
  column-gap: 1.5ch;
  padding: 3px 0;
  border-bottom: 1px dashed rgba(168, 132, 79, 0.28);
}
.vd-dos-row:last-child { border-bottom: 0; }
.vd-dos-row dt { color: var(--silver); white-space: nowrap; }
.vd-dos-n { color: var(--text-faint); font-variant-numeric: tabular-nums; }
.vd-dos-vals { margin: 0; display: flex; flex-wrap: wrap; gap: 0 1.5ch; min-width: 0; }
.vd-dos-src {
  grid-column: 2;
  margin: 2px 0 4px;
  color: var(--text-muted);
  font-size: 14px;
  overflow-wrap: anywhere;
}
.vd-dos-src[hidden] { display: none; }
.vd-dos-src::before { content: "\2514 "; color: var(--ornament); }
.vd-dos-src b { color: var(--text-strong); font-weight: 600; }
.vd-dos-src a { color: var(--silver); }
.vd-cf {
  appearance: none;
  min-height: 28px;
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  text-align: left;
  overflow-wrap: anywhere;
  color: var(--text-body);
  cursor: pointer;
}
span.vd-cf { cursor: default; }
.vd-cf.confirmed { color: var(--gold); font-weight: 700; }
.vd-cf.possible { color: var(--text-faint); }
.vd-cf.claimed { color: var(--text-faint); font-style: italic; }
.vd-cf.masked { letter-spacing: 0.04em; }
button.vd-cf:hover, button.vd-cf:focus-visible, .vd-cf[aria-expanded="true"] { text-decoration: underline 1px; text-underline-offset: 4px; }
.vd-dos-row:not(.vd-all) .vd-extra { display: none; }
.vd-cf-more { appearance: none; min-height: 28px; padding: 0; border: 0; background: none; font: inherit; color: var(--silver); cursor: pointer; }
.vd-cf-more:hover, .vd-cf-more:focus-visible { color: var(--gold); }

/* ---------- Phones: she sits above, the tablet hangs below her, and the
   scroll becomes a sheet that rises when you tap a thread ---------- */

@media (max-width: 760px) {
  .vd-scene-inner { padding: calc(var(--band) - 30px) 16px 20px; justify-content: center; }
  .vd-tablet { width: 100%; padding: 28px 3ch 16px; }
  .vd-tablet h2 { font-size: 16px; }
  .vd-speech { font-size: 18px; min-height: 0; }
  .vd-body { grid-template-columns: minmax(0, 1fr); padding: 8px 16px 16px; gap: 0; }
  .vd-legend { font-size: 13px; gap: 2px 14px; }
  .vd-hint { font-size: 14px; }
  .vd-title { font-size: 14px; }
  .vd-meta { font-size: 13px; }
  .vd-thing { padding-left: 2ch; padding-right: 1.5ch; }
  .vd-thing.vd-k-scroll { padding-left: 3ch; padding-right: 3ch; }

  .vd-detail {
    position: fixed;
    z-index: 1000;
    left: 0; right: 0; bottom: 0; top: auto;
    max-height: 80vh;
    padding: 0 6px;
    background: var(--bg);
    transform: translateY(104%);
    visibility: hidden;
    transition: transform 0.28s steps(8, end), visibility 0s linear 0.28s;
  }
  .vd-sheet-open .vd-detail { transform: none; visibility: visible; transition: transform 0.28s steps(8, end); }
  .vd-detail::before, .vd-detail::after { display: none; }
  .vd-scroll { padding: 26px 3ch 22px; }
  .vd-quip { font-size: 17px; }
  .vd-sheet { font-size: 17px; }
  .vd-sheet-foot { position: sticky; bottom: 0; background: var(--vd-face); }
  .vd-actions { padding-bottom: 40px; flex-direction: column; align-items: center; }
  .vd-dossier-face { padding: var(--vd-cell) 2.5ch 6px; font-size: 14px; }
  .vd-dos-row { grid-template-columns: minmax(0, 1fr); }
  .vd-dos-src { grid-column: 1; }
  .vd-cf, .vd-cf-more { min-height: 32px; }
}

@media (prefers-reduced-motion: reduce) {
  .vd-li, .vd-btn, .vd-detail, .vd-ch.on { transition: none !important; }
  .vd-li.vd-drop { animation: none; }
  .vd-cocoon.vd-gone { animation: none; opacity: 0.4; }
}

@media (forced-colors: active) {
  .vd-fr { forced-color-adjust: none; }
  .vd-thing:focus-visible { outline: 3px solid Highlight; }
}
