/* CaseModel website - css/p-site.css
   What every page carries around its figures. The header's one row and its menu: "What CaseModel does" opens a panel under
   the header with the overview and the eight parts in their four groups, and the readers; on a narrow window the menu opens
   with the eight parts as a short list. The hero's headline, sized from its own column so it can never be clipped; who is
   reading; the route a reader is offered across the pages, as a line under the hero's chooser, a card at the foot of the
   window, numbers on the map and marks on the overview's lists; the map of the site at the left edge; the aids under each
   section's heading; the six questions on a narrow window; the custody ledger's altered line.
   The header, its panel, the map and the route card are one material: white glass with a hairline, over the field of squares.
   A route is drawn the same way wherever it appears: a small square for each stop, filled once seen, the next one ringed. */

:root { --ch-line: color-mix(in srgb, var(--brand-navy) 12%, transparent); }

/* a small label over a control or a value */
.ch-k { color: var(--text-3); font: 700 11px/1.2 var(--font-display); letter-spacing: .09em; text-transform: uppercase; }
.ch-chips { display: flex; flex-wrap: wrap; gap: 6px; }
@media (max-width: 640px) {
  .ch-k { font-size: 12px; }
  .ch-chips .chip { min-height: 40px; font-size: 14px; }
}
@keyframes ch-new { from { opacity: 0; transform: translateY(7px); } }
@keyframes ch-drop { from { opacity: 0; transform: translateY(-6px); } }

/* ---- the header: one row from 1021 px up. The menu gives up its padding first, then the pill its words ---- */
.top-in > .brand, .top-in > .top-cta, .top-in > .menu-btn, #top #film-pill { flex: none; }
.nav > a, .nav-what-btn { white-space: nowrap; }
@media (min-width: 1021px) and (max-width: 1239px) {
  .nav { gap: 0; }
  .nav > a, .nav-what-btn { padding: 9px 7px; }
  .nav .nav-signin { margin-left: 2px; }
}
/* the pill keeps its mark, the first thing in it, and lets its words go (its name stays with it, unseen) */
@media (min-width: 1021px) and (max-width: 1059px), (max-width: 560px) {
  #top #film-pill { width: 40px; padding: 0 0 0 12px; gap: 40px; overflow: hidden; }
}
@media (max-width: 1020px) {
  .film-pill:not([hidden]) { margin-left: auto; }
  .film-pill:not([hidden]) ~ .top-cta { margin-left: 0; }
  .nav { max-height: calc(100vh - 96px - var(--ch-rec, 0px)); max-height: calc(100svh - 96px - var(--ch-rec, 0px)); overflow-y: auto; overscroll-behavior: contain; }
}
@media (max-width: 400px) {
  .top-in { gap: 6px; }
  #top .top-cta { padding: 0 12px; font-size: 13px; }
}
@media (max-width: 360px) {
  .top-in { gap: 4px; padding: 0 6px 0 10px; }
  #top .top-cta { padding: 0 10px; font-size: 12.5px; }
}
@media (max-width: 339px) { #top #film-pill { display: none; } }

/* ---- "What CaseModel does": a menu entry that opens the eight parts. On a part's own page it is where you are ---- */
.nav-what { position: static; }
.nav-what-btn { display: inline-flex; align-items: center; gap: 9px; padding: 9px 12px; border: 0; border-radius: var(--r-2); background: none; color: var(--text-2);
  font: 600 14px/1 var(--font-display); cursor: pointer; transition: color .15s, background .15s; }
.nav-what-btn i { flex: none; width: 6px; height: 6px; margin-top: -3px; border-right: 1.6px solid currentColor; border-bottom: 1.6px solid currentColor; transform: rotate(45deg);
  transition: transform .22s var(--ease), margin .22s var(--ease); }
.nav-what-btn[aria-expanded="true"] i { margin-top: 3px; transform: rotate(225deg); }
.nav-what-btn:hover, .nav-what-btn.here, .nav-what-btn[aria-expanded="true"] { color: var(--azure-11); background: var(--sky-3); }
.nav-what-btn[aria-current="true"] { color: var(--brand-navy); }
.nav-what-btn[aria-current="true"]::before { content: ''; flex: none; width: 7px; height: 7px; margin-right: -1px; background: var(--brand-navy); }
.nav-what-panel a { text-decoration: none; }
.nav-what-panel a:focus-visible { outline-offset: -2px; }
.nav-what-g > p { margin: 0; }
.ch-what-n { margin: 0; color: var(--text-3); font-size: 14px; line-height: 1.35; }

/* a wide window: the panel drops under the header, as wide as it, in the same material. The overview across the top, the
   four groups as columns in the briefing's order, the readers along the foot */
@media (min-width: 1021px) {
  .nav-what-panel { position: absolute; left: -1px; right: -1px; top: calc(100% + 8px); display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); counter-reset: ch-g;
    max-height: calc(100vh - 100px); max-height: calc(100svh - 100px); overflow-y: auto; overscroll-behavior: contain;
    border: 1px solid rgb(0 40 96 / .1); border-radius: var(--r-3); background: #ffffff; box-shadow: var(--shadow-3); animation: ch-drop .26s var(--ease) both; }
  .nav .nav-what-all { grid-column: 1 / -1; display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 14px; padding: 15px 22px 14px; border-bottom: 1px solid var(--border-row);
    border-radius: 0; color: var(--brand-navy); font: 700 15px/1.3 var(--font-display); letter-spacing: -0.01em; white-space: normal; }
  .nav .nav-what-all span { color: var(--text-3); font: 400 14.5px/1.4 var(--font-ui); letter-spacing: 0; }
  .nav .nav-what-all::after { content: ''; align-self: center; width: 7px; height: 7px; margin-left: auto; border-right: 2px solid var(--brand-azure); border-bottom: 2px solid var(--brand-azure);
    transform: rotate(-45deg); transition: transform .2s var(--ease); }
  .nav .nav-what-all:hover::after { transform: translateX(3px) rotate(-45deg); }
  .nav-what-g { counter-increment: ch-g; padding: 14px 10px 16px; border-left: 1px solid var(--border-row); }
  .nav-what-all + .nav-what-g { border-left: 0; }
  .nav-what-g > p { display: flex; align-items: baseline; gap: 8px; margin: 0 0 6px; padding: 0 12px; color: var(--azure-11); font: 700 11.5px/1.2 var(--font-display);
    letter-spacing: .09em; text-transform: uppercase; }
  .nav-what-g > p::before { content: counter(ch-g, decimal-leading-zero); color: var(--text-3); font: 500 11.5px/1.2 var(--font-mono); letter-spacing: 0; }
  .nav .nav-what-g a { display: block; padding: 10px 12px 11px; border-radius: var(--r-2); color: var(--brand-navy); font: 700 15px/1.25 var(--font-display);
    letter-spacing: -0.012em; white-space: normal; }
  .nav .nav-what-g a span { display: block; margin-top: 4px; color: var(--text-3); font: 400 14px/1.4 var(--font-ui); letter-spacing: 0; }
  .nav .nav-what-g a:hover { background: var(--sky-3); color: var(--azure-11); }
  .nav .nav-what-g a:hover span { color: var(--text-2); }
  /* the page you are on: a navy square, as on the map */
  .nav .nav-what-panel a[aria-current="page"] { background: var(--sky-2); }
  .nav .nav-what-g a[aria-current="page"]::before, .nav .nav-what-all[aria-current="page"]::before { content: ''; display: inline-block; width: 8px; height: 8px; margin: 0 9px 1px 0;
    background: var(--brand-navy); vertical-align: baseline; }
  .nav .nav-what-all[aria-current="page"]::before { align-self: center; margin: 0 -5px 0 0; }
  .ch-what-aud { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; padding: 11px 22px 12px; border-top: 1px solid var(--border-row); background: var(--sky-2); }
  .ch-what-aud .ch-chips .chip { min-height: 34px; }
  .ch-what-n { margin-left: auto; }
}
@media (min-width: 1021px) and (max-width: 1239px) {
  .nav .nav-what-all, .ch-what-aud { padding-left: 18px; padding-right: 18px; }
  .nav-what-g { padding-left: 6px; padding-right: 6px; }
  .ch-what-n { display: none; }
}

/* a narrow window: the menu opens under the header with the eight parts first, as a short list (names only; each part's
   line is on the overview and on its own page), then the overview's other places, signing in and the readers */
.ch-nav-aud { display: none; }
@media (max-width: 1020px) {
  .nav.open { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2px; }
  .nav > *, .nav > .nav-what, .nav > .nav-signin, .nav > .ch-nav-aud { grid-column: 1 / -1; }
  .nav > a:not(.nav-signin) { grid-column: auto; padding: 14px 6px; font-size: 15.5px; text-align: center; }
  .nav-what { margin: 0 0 6px; padding: 0 0 6px; border-bottom: 1px solid var(--border-row); }
  .nav-what-btn { display: flex; justify-content: space-between; width: 100%; min-height: 48px; padding: 0 14px; color: var(--brand-navy); font-size: 17px; }
  .nav-what-btn i { width: 8px; height: 8px; border-width: 0 2px 2px 0; }
  .nav-what-btn[aria-current="true"]::before { display: none; }
  .nav-what-panel { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 10px; counter-reset: ch-g; }
  .nav .nav-what-all { grid-column: 1 / -1; display: flex; align-items: center; min-height: 44px; padding: 0 14px; color: var(--brand-navy); font: 600 16px/1.3 var(--font-display); white-space: normal; }
  .nav .nav-what-all span { display: none; }
  .nav-what-g { counter-increment: ch-g; min-width: 0; }
  .nav-what-g > p { display: flex; align-items: baseline; gap: 8px; margin: 8px 0 0; padding: 4px 14px; color: var(--azure-11); font: 700 12px/1.2 var(--font-display); letter-spacing: .09em; text-transform: uppercase; }
  .nav-what-g > p::before { content: counter(ch-g, decimal-leading-zero); color: var(--text-3); font: 500 12px/1.2 var(--font-mono); letter-spacing: 0; }
  .nav .nav-what-g a { display: flex; align-items: center; min-height: 42px; padding: 6px 14px; color: var(--text-2); font: 600 16px/1.3 var(--font-display); white-space: normal; }
  .nav .nav-what-g a span { display: none; }
  .nav .nav-what-panel a[aria-current="page"] { background: var(--sky-3); color: var(--brand-navy); }
  .nav .nav-what-panel a[aria-current="page"]::before { content: ''; flex: none; width: 8px; height: 8px; margin-right: 10px; background: var(--brand-navy); }
  .ch-what-aud { display: none; }
  .nav .nav-signin { margin: 4px 0 0; }
  .ch-nav-aud { display: block; margin: 4px 0 0; padding: 14px 14px 8px; border-top: 1px solid var(--border-row); }
  .ch-nav-aud .ch-k { display: block; margin: 0 0 10px; }
  .ch-nav-aud .chip { min-height: 40px; }
}
@media (max-width: 640px) {
  .nav-what-panel { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 360px) {
  .nav > a:not(.nav-signin) { font-size: 14.5px; }
}

/* ---- the hero. The headline is sized from the column it sits in: a seventeenth of the column a hundred times over, so its
   longer line fits in the page's own face and in the face that stands in for it.
   A short window brings it down before it pushes the chooser off the screen. ---- */
.hero-copy { container-type: inline-size; }
h1 { font-size: clamp(40px, min(17cqi, 15svh), 128px); }
@media (min-width: 1021px) and (max-height: 780px) {
  h1 { font-size: clamp(40px, min(17cqi, 14svh), 128px); }
  .hero { padding: 96px 0 64px; }
  .lede { margin-top: 22px; }
  .cta { margin-top: 22px; }
  .aud { margin-top: 24px; }
}
@media (min-width: 1021px) and (max-height: 700px) {
  h1 { font-size: clamp(40px, min(17cqi, 12.4svh), 128px); }
  .hero { padding: 88px 0 56px; }
  .lede { margin-top: 18px; font-size: 18px; }
  .cta { margin-top: 20px; }
  .cta .btn { height: 48px; }
  .aud { margin-top: 20px; }
}
@media (max-width: 640px) { .aud button { height: 40px; } }
/* beside the mark on a narrower wide window, the chooser's label takes its own line so the five readers stay in one row */
@media (min-width: 1021px) and (max-width: 1199px) { .hero .aud-l { width: 100%; margin-bottom: 4px; } }
/* a phone held sideways: the headline and the mark side by side, as on a wide window, both at the top, so the first
   screen holds the words */
@media (max-width: 1020px) and (max-height: 500px) and (orientation: landscape) {
  .hero-grid { grid-template-columns: minmax(0, 1.04fr) minmax(0, 1fr); align-items: start; }
}
/* beside the mark, the hero's words for each reader share one place, as tall as the longest of them, so the chooser
   beneath does not move under the hand that is pressing it. In one column the page is moved to keep it there instead. */
@media (min-width: 1021px) {
  .hero .lede.adapt { display: grid; }
  .hero .lede.adapt > [data-for] { grid-area: 1 / 1; }
  .hero .lede.adapt > [data-for][hidden] { display: block !important; visibility: hidden; }
}
/* under the chooser: what choosing does; for a chosen reader, the route as squares and where to start it */
.aud-route { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; min-height: 44px; }
.ch-hr-t { flex: 1 1 15em; min-width: 0; }
.ch-hr-go { flex: none; display: inline-flex; align-items: center; gap: 14px; }
.ch-go { flex: none; display: inline-flex; align-items: center; gap: 10px; height: 36px; padding: 0 13px 0 14px; border: 1px solid var(--azure-6); border-radius: var(--r-2); background: var(--azure-3);
  font: 700 13.5px/1 var(--font-display); text-decoration: none; white-space: nowrap; transition: background .15s, border-color .15s, color .15s; }
.ch-go i { width: 7px; height: 7px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(-45deg); transition: transform .2s var(--ease); }
@media (hover: hover) {
  .ch-go:hover { border-color: var(--brand-azure); background: var(--azure-4); }
  .ch-go:hover i { transform: translateX(3px) rotate(-45deg); }
}
@media (max-width: 640px) {
  .aud-route { min-height: 66px; }
  .ch-go { height: 40px; font-size: 14px; }
}

/* a route, as squares: one for each stop in its order, filled once seen, the next one ringed in navy */
.ch-sqs { display: inline-flex; align-items: center; gap: 4px; }
.ch-sqs i { flex: none; width: 9px; height: 9px; border: 2px solid var(--azure-6); background: #ffffff; transition: background .3s, border-color .3s, transform .35s var(--spring); }
.ch-sqs i.ch-seen { border-color: var(--brand-azure); background: var(--brand-azure); }
.ch-sqs i.ch-next { border-color: var(--brand-navy); transform: scale(1.22); }

/* the overview's lists under "Who it is for": a stop on another page points on, and a stop seen says so */
.route a.ch-away::after { transform: rotate(-45deg); }
.route a.ch-away:hover::after { transform: translateX(3px) rotate(-45deg); }
.route a .ch-seen-t { display: inline-block; margin-left: 10px; padding: 3px 6px 2px; border-radius: var(--r-1); background: var(--sky-3); color: var(--azure-11);
  font: 700 10.5px/1.2 var(--font-display); letter-spacing: .08em; text-transform: uppercase; vertical-align: 2px; }

/* ---- the wordmarks, in a heading or in a sentence. In a sentence the display face runs large beside the text face:
   brought down a little, its capitals stand level with the words around it, on the same baseline. The name itself is
   carried once, unseen, so a copy of the sentence reads as written. ---- */
.wm { position: relative; }
.wm .wm-a, .wm .wm-n { -webkit-user-select: none; user-select: none; }
p .wm { font-size: .94em; }

/* ---- under a section's heading: the part of the briefing that tells it, and a line for whoever is reading ---- */
.sec-aids { align-items: stretch; }
.sec-aids:not(:has(> :not([hidden]))) { display: none; }
.sec-aids > .cue-film { flex: 0 1 auto; }
.sec-aids > .rl { display: flex; flex-direction: column; justify-content: center; }
.story .sec-aids { margin-top: 26px; }
@media (max-width: 1020px) {
  .story .sec-aids { margin-top: 12px; }
}
/* held on a short screen, the build keeps its room for its words and its stage: the reader's line gives way there */
@media (min-width: 1021px) and (max-height: 730px) {
  .story .sec-aids { margin-top: 14px; }
  .story .sec-aids > .rl { display: none; }
}
@media (max-width: 1020px) and (max-height: 760px) {
  .story .sec-aids > .rl { display: none; }
}
@media (max-width: 640px) {
  .sec-aids { flex-direction: column; gap: 10px; }
  .sec-aids > .cue-film, .sec-aids > .rl { flex: none; width: 100%; max-width: none; }
}

/* ---- the map: the overview and the eight parts down the left edge of a wide window, in the gutter beside the page. The
   page you are on carries its own sections beneath it, on a thin stem ---- */
.ch-rail { position: fixed; left: 0; top: 50%; z-index: 50; display: none; width: 40px; padding: 0 8px; opacity: 0; visibility: hidden; transform: translate(-12px, -50%);
  transition: opacity .45s var(--ease), transform .45s var(--ease), visibility 0s .45s; }
.ch-rail.ch-on { opacity: 1; visibility: visible; transform: translate(0, -50%); transition: opacity .45s var(--ease), transform .45s var(--ease); }
@media (min-width: 1180px) and (min-height: 560px) { .ch-rail { display: block; } }
.ch-rail::before { content: ''; position: absolute; left: 8px; top: -10px; bottom: -10px; width: 24px; border: 1px solid var(--ch-line); border-radius: var(--r-3);
  background: rgb(255 255 255 / .8); -webkit-backdrop-filter: blur(14px) saturate(1.7); backdrop-filter: blur(14px) saturate(1.7); box-shadow: var(--shadow-2);
  transition: width .28s var(--ease) .08s, top .28s var(--ease) .08s, bottom .28s var(--ease) .08s, box-shadow .3s, background .3s; }
/* opening, the panel widens and then the names come; closing, the names go and then the panel narrows */
.ch-rail.ch-open::before { top: -42px; width: 312px; background: rgb(255 255 255 / .97); box-shadow: var(--shadow-3); transition-delay: 0s; }
.ch-rail.ch-keys::before { bottom: -40px; }
.ch-rail ol { position: relative; margin: 0; padding: 0; list-style: none; }
.ch-rail li { position: relative; }
.ch-rail li.ch-brk { margin-top: 11px; }
.ch-rail li.ch-brk::before { content: ''; position: absolute; left: 7px; top: -6px; width: 10px; height: 1px; background: var(--slate-6); }      /* the thin break between the groups */
.ch-rail a { position: relative; display: flex; align-items: center; width: 24px; height: 24px; border-radius: var(--r-1); color: var(--text-2); font: 600 13.5px/1 var(--font-display);
  letter-spacing: -0.005em; text-decoration: none; white-space: nowrap; outline-offset: -2px; }
.ch-rail .ch-subs a { height: 20px; color: var(--text-3); font: 500 12.5px/1 var(--font-display); letter-spacing: 0; }
.ch-rail.ch-open a { width: 312px; }
.ch-rail.ch-open a:hover, .ch-rail.ch-open a:focus-visible { background: var(--sky-3); color: var(--azure-11); }
.ch-sq { position: relative; z-index: 1; flex: none; display: grid; place-items: center; width: 24px; height: 100%; }
.ch-sq i { position: relative; display: block; width: 8px; height: 8px; border: 1.5px solid var(--azure-6); background: #ffffff;
  transition: width .25s var(--spring), height .25s var(--spring), border-color .25s, background .25s; }
.ch-subs .ch-sq i { width: 6px; height: 6px; }
.ch-sq b { display: none; }
/* the stem: this page's sections hang from its square */
.ch-rail .ch-subs { padding: 1px 0 3px; }
.ch-rail .ch-subs::before { content: ''; position: absolute; left: 11.5px; top: -12px; bottom: 13px; width: 1px; background: var(--azure-6); }
/* pages opened on this visit, and sections passed */
.ch-rail a.ch-vis .ch-sq i, .ch-rail a.ch-done .ch-sq i { border-color: var(--brand-azure); background: var(--brand-azure); }
/* the page you are on: navy and larger; the section being read: navy */
.ch-rail a.ch-cur .ch-sq i { width: 13px; height: 13px; border-color: var(--brand-navy); background: var(--brand-navy); }
.ch-rail a.ch-now .ch-sq i { width: 9px; height: 9px; border-color: var(--brand-navy); background: var(--brand-navy); }
/* a stop on the reader's route: a ring with its number, filled once seen */
.ch-rail a.ch-stop .ch-sq i { display: grid; place-items: center; width: 17px; height: 17px; border-color: var(--brand-azure); background: #ffffff; }
.ch-rail .ch-subs a.ch-stop .ch-sq i { width: 16px; height: 16px; }
.ch-rail a.ch-stop .ch-sq b { display: block; color: var(--azure-11); font: 700 10px/1 var(--font-display); letter-spacing: 0; }
.ch-rail a.ch-stop.ch-seen .ch-sq i { background: var(--brand-azure); }
.ch-rail a.ch-stop.ch-cur .ch-sq i { width: 19px; height: 19px; border-color: var(--brand-navy); background: var(--brand-navy); }
.ch-rail a.ch-stop.ch-now .ch-sq i { width: 18px; height: 18px; border-color: var(--brand-navy); background: var(--brand-navy); }
.ch-rail a.ch-stop.ch-seen .ch-sq b, .ch-rail a.ch-stop.ch-cur .ch-sq b, .ch-rail a.ch-stop.ch-now .ch-sq b { color: #ffffff; }
/* the section the briefing has reached, while it plays */
.ch-rail a.ch-play .ch-sq::after { content: ''; position: absolute; left: 25px; top: 50%; margin-top: -4px; border-left: 6px solid var(--brand-azure); border-top: 4px solid transparent; border-bottom: 4px solid transparent; }
.ch-rail.ch-open a.ch-play .ch-sq::after { display: none; }
.ch-rail a.ch-play em { color: var(--azure-11); font-weight: 700; }
.ch-rail a.ch-play em::before { content: ''; display: inline-block; margin-right: 6px; border-left: 6px solid var(--brand-azure); border-top: 4px solid transparent; border-bottom: 4px solid transparent; }
/* the names, when the map is pointed at or reached by keyboard */
.ch-rail-t { flex: 1 1 0; display: flex; align-items: center; gap: 10px; min-width: 0; height: 100%; padding: 0 12px 0 6px; opacity: 0; pointer-events: none; transform: translateX(-6px);
  transition: opacity .12s, transform .3s var(--ease); }
.ch-rail.ch-open .ch-rail-t { opacity: 1; pointer-events: auto; transform: none; transition: opacity .2s .14s, transform .3s var(--ease) .1s; }
.ch-rail-n { overflow: hidden; text-overflow: ellipsis; }
.ch-rail a.ch-cur .ch-rail-n { color: var(--brand-navy); font-weight: 800; }
.ch-rail a.ch-now .ch-rail-n { color: var(--brand-navy); font-weight: 700; }
.ch-rail-s { flex: none; color: var(--azure-11); font: 700 11px/1 var(--font-display); letter-spacing: .06em; text-transform: uppercase; }
.ch-rail-s:empty { display: none; }
.ch-rail a em { flex: none; margin-left: auto; color: var(--text-3); font: 500 12px/1 var(--font-mono); font-style: normal; font-variant-numeric: tabular-nums; }
.ch-rail-h, .ch-rail-k { position: absolute; left: 38px; display: flex; justify-content: space-between; gap: 12px; width: 268px; margin: 0; opacity: 0; pointer-events: none; white-space: nowrap; transition: opacity .12s; }
.ch-rail-h { top: -30px; color: var(--text-3); font: 700 11px/1.2 var(--font-display); letter-spacing: .07em; text-transform: uppercase; }
.ch-rail-k { bottom: -28px; color: var(--text-3); font: 400 13px/1.2 var(--font-ui); }
.ch-rail.ch-open .ch-rail-h, .ch-rail.ch-open.ch-keys .ch-rail-k { opacity: 1; transition: opacity .2s .14s; }
@media (pointer: coarse) {
  .ch-rail a { height: 30px; }
  .ch-rail .ch-subs a { height: 26px; }
}
@media (min-width: 1180px) and (max-height: 700px) {
  .ch-rail a { height: 21px; }
  .ch-rail .ch-subs a { height: 17px; }
  .ch-rail li.ch-brk { margin-top: 8px; }
  .ch-rail li.ch-brk::before { top: -5px; }
}
.film-on .ch-rail, .ch-theatre .ch-rail { opacity: 0; visibility: hidden; }

/* ---- the route card: who you are reading as, the next stop for you, how far along. At the foot of the window, out of the
   way, on any page ---- */
.ch-route { position: fixed; left: var(--ch-x, calc(50% - min(440px, 100vw - 20px) / 2)); bottom: calc(var(--ch-b, 14px) + env(safe-area-inset-bottom, 0px)); z-index: 55;
  width: min(440px, calc(100vw - 20px)); border: 1px solid var(--ch-line); border-radius: var(--r-3); background: rgb(255 255 255 / .92);
  -webkit-backdrop-filter: blur(18px) saturate(1.7); backdrop-filter: blur(18px) saturate(1.7); box-shadow: var(--shadow-3);
  opacity: 0; visibility: hidden; transform: translateY(16px); transition: opacity .32s var(--ease), transform .32s var(--ease), visibility 0s .32s; }
.ch-route.ch-on { opacity: 1; visibility: visible; transform: none; transition: opacity .32s var(--ease), transform .32s var(--ease), left .32s var(--ease), bottom .32s var(--ease); }
.ch-route-top { position: relative; display: flex; align-items: center; gap: 10px; height: 40px; padding: 0 2px 0 6px; }
.ch-route-who { flex: 0 1 auto; display: inline-flex; align-items: center; gap: 9px; min-width: 0; height: 30px; padding: 0 9px; border: 0; border-radius: var(--r-2); background: none; color: var(--azure-11);
  font: 700 11.5px/1 var(--font-display); letter-spacing: .08em; text-transform: uppercase; white-space: nowrap; cursor: pointer; transition: background .15s, color .15s; }
.ch-route-who > span { overflow: hidden; text-overflow: ellipsis; }
.ch-route-who[aria-expanded="true"] { background: var(--sky-3); color: var(--azure-12); }
.ch-route-who i { flex: none; width: 6px; height: 6px; margin-top: 3px; border-left: 2px solid currentColor; border-top: 2px solid currentColor; transform: rotate(45deg); transition: transform .2s var(--ease); }
.ch-route-who[aria-expanded="true"] i { margin-top: -3px; transform: rotate(225deg); }
.ch-route-top .ch-sqs { margin-left: auto; }
.ch-route-n { flex: none; color: var(--text-2); font: 600 12.5px/1 var(--font-display); font-variant-numeric: tabular-nums; white-space: nowrap; }
.ch-route-x { position: relative; flex: none; width: 36px; height: 36px; padding: 0; border: 0; border-radius: var(--r-2); background: none; color: var(--slate-10); cursor: pointer; transition: background .15s, color .15s; }
.ch-route-x i::before, .ch-route-x i::after { content: ''; position: absolute; left: 11px; top: 17px; width: 14px; height: 2px; background: currentColor; transform: rotate(45deg); }
.ch-route-x i::after { transform: rotate(-45deg); }
.ch-route-next { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 12px; min-height: 46px; padding: 9px 16px 10px 15px; border-top: 1px solid var(--border-row);
  border-radius: 0 0 var(--r-3) var(--r-3); color: var(--brand-navy); text-decoration: none; outline-offset: -3px; transition: background .15s, color .15s; }
.ch-route-next b { font: 700 15px/1.25 var(--font-display); letter-spacing: -0.012em; text-wrap: balance; }
.ch-route-next i { width: 8px; height: 8px; margin-top: -4px; border-right: 2px solid var(--brand-azure); border-bottom: 2px solid var(--brand-azure); transform: rotate(45deg); transition: transform .25s var(--ease), margin .25s var(--ease); }
.ch-route-next.ch-up i { margin-top: 4px; transform: rotate(225deg); }                 /* the next stop is back up this page */
.ch-route-next.ch-away i { margin: 0 2px 0 0; transform: rotate(-45deg); }             /* the next stop is on another page */
.ch-route-next.ch-new b, .ch-route-next.ch-new .ch-k { animation: ch-new .5s var(--ease) both; }
@media (hover: hover) {
  .ch-route-who:hover { background: var(--sky-3); color: var(--azure-12); }
  .ch-route-x:hover { background: var(--slate-3); color: var(--brand-navy); }
  .ch-route-next:hover { background: var(--sky-3); color: var(--azure-11); }
  .ch-route-next.ch-away:hover i { transform: translateX(3px) rotate(-45deg); }
}
/* the five readers, opened from the card */
.ch-pick { position: absolute; left: -1px; right: -1px; bottom: calc(100% + 8px); padding: 14px 14px 13px; border: 1px solid var(--ch-line); border-radius: var(--r-3); background: #ffffff;
  box-shadow: var(--shadow-3); animation: ch-new .25s var(--ease) both; }
.ch-pick .ch-k { margin: 0 0 9px; }
.ch-pick-n { margin: 11px 0 0; color: var(--text-3); font-size: 14px; line-height: 1.4; }
@media (max-width: 640px) {
  .ch-route-top { height: 44px; padding-left: 4px; gap: 8px; }
  .ch-route-who { height: 40px; font-size: 14px; letter-spacing: 0; text-transform: none; }
  .ch-route-x { width: 40px; height: 40px; }
  .ch-route-x i::before, .ch-route-x i::after { left: 13px; top: 19px; }
  .ch-route-next { min-height: 48px; }
  .ch-route-next b { font-size: 14.5px; }
  .ch-pick .chip { min-height: 40px; }
}
/* narrow: the squares say how far along; the count is still read out */
@media (max-width: 480px) {
  .ch-route-n { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
}
/* the narrowest phones: the row gives up a little of its spacing, so the reader's name is never cut short */
@media (max-width: 340px) {
  .ch-route-top { gap: 4px; }
  .ch-route-who { gap: 7px; padding: 0 6px; }
}
.film-on .ch-route, .ch-theatre .ch-route { opacity: 0; visibility: hidden; }

/* ---- "Who it is for" on a narrower window: the four readers all in view, the chosen one among them, nothing off to the side ---- */
@media (max-width: 1020px) {
  .who .aud.col { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; margin: 0; padding: 0; overflow: visible; }
  .who .aud.col button { align-items: flex-start; gap: 10px; min-height: 56px; padding: 14px; white-space: normal; }
  .who .aud.col button span { padding-top: 3px; }
}
@media (max-width: 640px) {
  .who .aud.col { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .who .aud.col button { font-size: 16.5px; line-height: 1.2; }
}

/* ---- six questions on a narrower window: the questions as one list over their answer, nothing off to the side ---- */
@media (max-width: 1020px) {
  .qa-list { flex-direction: column; gap: 4px; margin: 0; padding: 0; overflow: visible; scroll-snap-type: none; }
  .qa-list button { width: auto; padding: 13px 16px 13px 42px; border-color: transparent; background: none; font-size: 16.5px; }
  .qa-list button::before { left: 17px; top: 18px; }
  .qa-list button[aria-selected="true"] { border-color: var(--border); background: #ffffff; }
}

/* ---- the custody ledger: the two digits that changed places, and what it shows, said in a line ---- */
.ledger-rows .lg-t mark { padding: 0 1px; border-radius: var(--r-1); background: #ffffff; color: var(--adv-fg); box-shadow: inset 0 -2px 0 var(--adv); transition: background .3s; }
.ch-ledger-s { display: flex; align-items: baseline; gap: 10px; margin: 0; padding: 12px 20px 13px; border-top: 1px solid var(--border-row); background: var(--sky-2); color: var(--brand-navy);
  font: 600 14.5px/1.4 var(--font-display); letter-spacing: -0.005em; transition: background .4s, color .4s; }
.ch-ledger-s.bad { background: var(--adv-bg); color: var(--adv-fg); }
@media (max-width: 640px) {
  .ledger-rows .lg-n, .ledger-rows .lg-h { font-size: 14px; }
  .ledger-rows .lg-s { font-size: 14px; }
  .ch-ledger-s { padding: 12px 16px 13px; font-size: 15px; }
}

/* ---- small targets, made large enough for a thumb ---- */
@media (max-width: 640px) {
  .foot-rec { min-height: 40px; }
  .rec-b { height: 40px; }
  .rec-more { min-height: 40px; }
}

@media (prefers-contrast: more) {
  .ch-rail::before, .ch-route, .nav-what-panel { background: #ffffff; border-color: var(--slate-10); }
}
/* colours the reader's own system chooses: the squares keep their meaning by fill and outline */
@media (forced-colors: active) {
  .ch-sq i, .ch-sqs i { forced-color-adjust: none; border-color: CanvasText; background: Canvas; }
  .ch-rail a.ch-done .ch-sq i, .ch-rail a.ch-vis .ch-sq i, .ch-rail a.ch-stop.ch-seen .ch-sq i, .ch-sqs i.ch-seen { background: CanvasText; }
  .ch-rail a.ch-cur .ch-sq i, .ch-rail a.ch-now .ch-sq i, .ch-rail a.ch-stop.ch-cur .ch-sq i, .ch-rail a.ch-stop.ch-now .ch-sq i { border-color: Highlight; background: Highlight; }
  .ch-sqs i.ch-next { border-color: Highlight; }
  .ch-rail a.ch-stop .ch-sq b { forced-color-adjust: none; color: CanvasText; }
  .ch-rail a.ch-stop.ch-seen .ch-sq b, .ch-rail a.ch-stop.ch-cur .ch-sq b, .ch-rail a.ch-stop.ch-now .ch-sq b { color: Canvas; }
  .ch-rail .ch-subs::before { background: CanvasText; }
  .ch-rail::before, .ch-route, .ch-pick, .nav-what-panel { border-color: CanvasText; }
  .nav .nav-what-panel a[aria-current="page"]::before, .nav-what-btn[aria-current="true"]::before { forced-color-adjust: none; background: Highlight; }
}
@media print {
  .ch-rail, .ch-route, .nav-what-panel { display: none !important; }
}
