:root {
  color-scheme: light;
  --ink: #173c42;
  --blue: #165d6b;
  --gold: #965025;
  --paper: #fcf8ed;
  --panel: #fffdf6;
  --line: #9eafa7;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 1.04rem/1.55 "Segoe UI", Arial, sans-serif; }
header, main, footer { width: min(1120px, calc(100% - 3rem)); margin-inline: auto; }
header, footer, nav, .actions { display: flex; gap: .9rem 1.4rem; align-items: center; flex-wrap: wrap; }
header, footer { justify-content: space-between; }
header { border-bottom: 1px solid var(--line); padding: 1.05rem 0; }
footer { border-top: 1px solid var(--line); padding: 1rem 0 2rem; font-size: .88rem; }
a { color: var(--blue); text-underline-offset: .15em; }
a:focus-visible,button:focus-visible,textarea:focus-visible,input:focus-visible,select:focus-visible { outline: 3px solid #965025; outline-offset: 3px; }
.brand { color: var(--ink); font: bold 1.23rem Georgia,serif; text-decoration: none; }
main { padding: clamp(2rem, 5vw, 4.2rem) 0 3rem; }
h1,h2,h3 { font-family: Georgia,"Times New Roman",serif; line-height: 1.08; margin: .2em 0 .4em; }
h1 { font-size: clamp(2.65rem, 5.5vw, 4.8rem); letter-spacing: -.045em; max-width: 17ch; }
h2 { font-size: clamp(1.7rem,3vw,2.35rem); letter-spacing: -.025em; }
h3 { font-size: 1.5rem; }
p { margin: .3rem 0 1rem; }
.kicker { color: var(--gold); text-transform: uppercase; letter-spacing: .13em; font-weight: 750; font-size: .77rem; }
.lead { max-width: 57ch; font-size: 1.18rem; }
.actions { margin: 1.05rem 0; }
.button,button.action { display: inline-block; border: 1px solid var(--blue); background: var(--blue); color: white; padding: .56rem 1.03rem; border-radius: .2rem; text-decoration: none; font: inherit; font-weight: 650; cursor: pointer; }
img { display: block; max-width: 100%; height: auto; }
figure { margin: 0; }
figcaption,.by { color: #365653; font-size: .88rem; }
figcaption { margin-top: .45rem; }
.by { font-weight: 650; }
.hero { display: grid; grid-template-columns: .9fr 1.1fr; align-items: center; gap: clamp(1.2rem,4vw,3rem); }
.hero img { width: 100%; border: 1px solid var(--line); }
.section { margin-top: 2rem; padding-top: 1.4rem; border-top: 1px solid var(--line); }
.folders,.evidence,.two { display: grid; gap: 1rem 2rem; }
.folders { grid-template-columns: repeat(3,minmax(0,1fr)); }
.folders article { border-right: 1px solid var(--line); padding-right: 1.1rem; }
.folders article:last-child { border: 0; }
.folders img { width: 9rem; margin: .35rem 0 .1rem; }
.evidence,.two { grid-template-columns: repeat(2,minmax(0,1fr)); }
.evidence article,.compareCard { background: var(--panel); border-left: .28rem solid #689c98; padding: .7rem 1rem .45rem; }
.reading { max-width: 48rem; }
.pieces { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: .65rem; }
button.piece,button.slot,button.join { font: inherit; color: var(--ink); background: var(--panel); cursor: pointer; }
.piece, .slot { border: 1px solid #73958d; border-radius: .24rem; padding: .48rem; min-width: 0; text-align: center; }
.piece img,.slot img { display: block; width: min(100%,180px); margin: 0 auto .3rem; }
.piece:disabled { cursor: default; }
.piece.used { opacity: .49; }
.piece[aria-pressed="true"] { border: 3px solid #965025; padding: calc(.48rem - 2px); background: #fff2cc; }
.route { display: grid; align-items: center; gap: .3rem; margin: .55rem 0 1rem; }
.serial { grid-template-columns: minmax(0,1fr) 2.7rem minmax(0,1fr) 2.7rem minmax(0,1fr) 2.7rem minmax(0,1fr); grid-template-areas: "p0 e0 p1 e1 p2 e2 p3"; }
.branch { grid-template-columns: minmax(0,1fr) 2.7rem minmax(0,1fr) 2.7rem minmax(0,1fr); grid-template-areas: "p0 e0 p2 e2 p3" "p1 e1 p2 e2 p3"; }
.slot { border: 1.5px dashed #56817a; min-height: 6.3rem; font-size: .96rem; }
.slot.placed { border-style: solid; }
.slot small { display: block; color: #355952; font-weight: 650; }
[data-slot="0"] { grid-area: p0; } [data-slot="1"] { grid-area: p1; }
[data-slot="2"] { grid-area: p2; } [data-slot="3"] { grid-area: p3; }
[data-edge="0"] { grid-area: e0; } [data-edge="1"] { grid-area: e1; } [data-edge="2"] { grid-area: e2; }
button.join { width: 2.7rem; height: 2.7rem; padding: 0; border: 1px solid #9bada4; border-radius: 50%; font: 650 1.5rem/1 "Segoe UI",Arial,sans-serif; justify-self: center; }
.join .narrow { display: none; }
.status { min-height: 1.55rem; margin: .5rem 0; font-weight: 650; color: var(--blue); }
.formfield { display: block; max-width: 45rem; margin: .9rem 0; font-weight: 650; }
textarea,input,select { display: block; width: 100%; margin-top: .35rem; padding: .5rem; font: inherit; color: var(--ink); background: var(--panel); border: 1px solid #69837e; border-radius: .18rem; }
select { width: min(100%,24rem); }
textarea { min-height: 5rem; }
.small-note { font-size: .9rem; }
.skip { position: absolute; left: 1rem; top: 0; transform: translateY(-200%); background: white; padding: .55rem; }
.skip:focus { transform: none; }
[hidden] { display: none !important; }
@media(max-width: 720px) {
  header,main,footer { width: calc(100% - 2rem); }
  header { align-items: start; gap: .5rem; }
  .hero,.evidence,.two,.folders { grid-template-columns: 1fr; }
  .folders article { border: 0; border-bottom: 1px solid var(--line); padding: .45rem 0; }
  .folders img { width: 7rem; float: right; margin-left: .6rem; }
  .pieces { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .serial { grid-template-columns: 1fr; grid-template-areas: "p0" "e0" "p1" "e1" "p2" "e2" "p3"; }
  .branch { grid-template-columns: 1fr 1fr; grid-template-areas: "p0 p1" "e0 e1" "p2 p2" "e2 e2" "p3 p3"; }
  .serial .slot, .branch .slot:nth-of-type(n+3) { min-height: 4.2rem; }
  .slot img { width: 95px; }
  .join .wide { display: none; } .join .narrow { display: inline; }
}
@media print {
  header,footer,.skip,.actions { display: none; }
  body { background: white; }
  main { width: 100%; padding: 0; }
  .section, article { break-inside: avoid; }
}
