/* Preview D — Clubs & Claims styles. One table on desktop, compact rows on mobile, and a strict
   badge hierarchy: strong only for reported reserved rights, neutral chips for scenario basis.
   Deliberately no "Modelled estimate" badge on all 35 rows: the whole section already lives inside
   the scenario laboratory, so repeating it is visual noise. */

.labhead { margin: 0 0 16px; }
.labbadge { display: inline-block; font-size: 11px; letter-spacing: .08em; text-transform: uppercase;
  font-weight: 700; color: #ffd479; border: 1px solid #6b5320; background: #1d1808; border-radius: 6px;
  padding: 3px 9px; }
.labline { margin: 8px 0 0; color: var(--ink); font-size: 15px; line-height: 1.55; }

/* --- overall range ---
   One readable band. The Lower/Central/Upper segmented control is deliberately GONE: it looked
   interactive but was hardcoded (lr-fill width:100%, lr-mid written once), so selecting a scenario
   changed only a label. Do not reintroduce a scenario switch here unless it redraws every figure
   on the page from the canonical records. */
.labrange { border: 1px solid #24374b; background: #0f1720; border-radius: 14px; padding: 16px 18px; margin: 0 0 26px; }
.lr-lab { display: block; color: var(--ink3); font-size: 11.5px; letter-spacing: .06em; text-transform: uppercase; }
.lr-val { display: block; font-size: 32px; font-weight: 700; letter-spacing: -.01em; margin-top: 4px; }
.lr-track { position: relative; height: 10px; border-radius: 99px; background: #16202c;
  border: 1px solid #24374b; margin: 16px 0 10px; }
.lr-fill { position: absolute; inset: 0; border-radius: 99px;
  background: linear-gradient(90deg,#6cc4ff,#8ee6a8); opacity: .9; }
.lr-mid { position: absolute; top: -6px; bottom: -6px; width: 3px; background: #fff; border-radius: 2px;
  transform: translateX(-1px); box-shadow: 0 0 0 2px rgba(12,16,23,.85); }
.lr-nums { display: flex; justify-content: space-between; gap: 10px; font-size: 13px; color: var(--ink); }
.lr-nums > span { display: flex; flex-direction: column; gap: 1px; }
.lr-nums > span:last-child { text-align: right; }
.lr-nums em { font-style: normal; font-size: 11px; letter-spacing: .05em; text-transform: uppercase;
  color: var(--ink3); }
.lr-cen { text-align: center; } .lr-cen b { color: #fff; font-size: 19px; font-weight: 700;
  display: block; }
.lr-cen em { color: #8ee6a8; }
/* Audit item 10: each figure now carries its scenario name, so the label sits ABOVE the number.
   The old markup had the value first; the flex column order is flipped for all three so the three
   read as a set of named scenarios rather than a number with a caption. */
.lr-nums > span { align-items: center; flex: 1 1 0; }
.lr-nums > span:first-child { align-items: flex-start; text-align: left; }
.lr-nums > span:last-child { align-items: flex-end; text-align: right; }
.lr-nums em { order: -1; }
.lr-nums b { font-size: 19px; font-weight: 700; }

/* Scenario letter next to the table figure. */
.c-cen-l { display: inline-block; margin-left: 5px; font-size: 10px; font-weight: 700;
  letter-spacing: .06em; color: var(--ink3); border: 1px solid var(--line);
  border-radius: 3px; padding: 0 4px; vertical-align: 1px; }
.lr-note { margin: 12px 0 0; font-size: 12.5px; color: var(--ink3); line-height: 1.5; max-width: 62ch; }

/* --- what a claimant must establish (audit item 11) --- */
.mustlist { margin: 10px 0 0; padding-left: 1.25em; max-width: 68ch; }
.mustlist li { margin-bottom: 8px; font-size: 14px; line-height: 1.6; color: var(--ink2); }
.mustlist li b { color: var(--ink); }
.mustblk .note + .mustlist { margin-top: 4px; }

/* --- reserved rights --- */
.reservedblk { margin: 0 0 26px; }
.rrgrid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 12px; }
.rrcard { border: 1px solid #6b5320; background: #14110a; border-radius: 12px; padding: 13px 14px; }
.rr-name { font-weight: 700; font-size: 15px; margin-bottom: 6px; }
.rr-basis { display: flex; gap: 5px; flex-wrap: wrap; margin-bottom: 8px; }
.rr-val { font-size: 24px; font-weight: 700; margin-bottom: 8px; letter-spacing: -.01em; }
.rr-total { color: var(--ink2); font-size: 13.5px; margin: 10px 0 0; }

.bchip { display: inline-block; font-size: 10.5px; letter-spacing: .06em; text-transform: uppercase;
  color: var(--ink2); border: 1px solid #2b3d52; background: #131c26; border-radius: 4px;
  padding: 2px 6px; margin: 0 4px 4px 0; white-space: nowrap; }
.stchip { display: inline-block; font-size: 11.5px; border-radius: 5px; padding: 2px 8px; white-space: nowrap; }
.st-res { color: #0c1017; background: #f0b429; font-weight: 700; }
.st-none { color: var(--ink3); border: 1px solid #24374b; }

/* --- comparator --- */
.compblk { margin: 0 0 26px; }
.compcard { border: 1px solid #24374b; background: #0f1720; border-radius: 12px; padding: 14px 16px; }
.comp-case { font-weight: 700; font-size: 15px; }
.comp-amt { color: #8ee6a8; font-size: 14px; margin: 6px 0; }
.comp-out { color: var(--ink2); font-size: 13.5px; }

/* --- top scenarios --- */
.topblk { margin: 0 0 26px; }
.topbars { display: grid; gap: 6px; }
.tbar { display: grid; grid-template-columns: 160px minmax(0,1fr) 62px; gap: 10px; align-items: center;
  cursor: pointer; background: none; border: 0; font: inherit; color: inherit; text-align: left; padding: 3px 2px;
  border-radius: 6px; }
.tbar:hover, .tbar:focus-visible { background: #131c26; outline: none; }
.tb-name { font-size: 13.5px; color: var(--ink2); }
.tb-track { height: 12px; border-radius: 3px; background: #16202c; position: relative; overflow: hidden; }
.tb-fill { position: absolute; inset: 0 auto 0 0; background: var(--pl); border-radius: 3px; }
.tb-val { text-align: right; font-size: 13px; color: var(--ink); font-variant-numeric: tabular-nums; }
.btn-more { margin-top: 12px; background: #16202c; border: 1px solid #2b3d52; color: var(--ink);
  border-radius: 8px; padding: 8px 14px; font-size: 13.5px; cursor: pointer; font-family: inherit; }

/* --- filters --- */
.filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 0 0 12px;
  min-width: 0; max-width: 100%; }
.fbtn { background: #16202c; border: 1px solid #24374b; color: var(--ink2); border-radius: 99px;
  padding: 6px 13px; font-size: 13px; cursor: pointer; font-family: inherit; white-space: nowrap; }
.fbtn.is-on { background: #12202e; border-color: #6cc4ff; color: #fff; font-weight: 600; }
.fsearch input { background: #16202c; border: 1px solid #24374b; color: var(--ink); border-radius: 8px;
  padding: 7px 11px; font-size: 13.5px; font-family: inherit; min-width: 0;
  flex: 1 1 min(170px, 100%); max-width: 100%; }
.tbar-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin: 0 0 8px; }
.count-note { color: var(--ink3); font-size: 12.5px; }
.sortsel { color: var(--ink3); font-size: 12.5px; display: flex; align-items: center; gap: 6px; }
.sortsel select { background: #16202c; border: 1px solid #24374b; color: var(--ink2); border-radius: 7px;
  padding: 5px 8px; font-size: 13px; font-family: inherit;
  min-width: 0; max-width: 100%; flex: 1 1 auto; }
.sortsel { min-width: 0; flex-wrap: wrap; }

/* --- the table --- */
.tablescroll { overflow-x: auto; }
.ctable { width: 100%; border-collapse: collapse; font-size: 13.5px; min-width: 940px; }
.ctable thead th { text-align: left; font-size: 11px; letter-spacing: .06em; text-transform: uppercase;
  color: var(--ink3); font-weight: 600; padding: 8px 10px; border-bottom: 1px solid #24374b; white-space: nowrap; }
.ctable tbody th, .ctable tbody td { padding: 8px 10px; border-bottom: 1px solid #1b2430; vertical-align: middle;
  text-align: left; font-weight: 400; }
.c-club .cname { display: block; font-weight: 600; color: var(--ink); }
.c-club .cmeta { display: block; color: var(--ink3); font-size: 11.5px; margin-top: 2px; }
.c-hist { color: var(--ink2); font-size: 12.5px; max-width: 260px; }
/* The cell holds Scenario A, B and C side by side at equal weight. It was styled as one bold
   right-aligned figure for when it showed Scenario B alone, which gave B the visual emphasis the
   audit asked to remove. Now it is a small stack, none of the three emphasised over the others. */
.c-abc-cell { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.c-abc-cell .c-abc { display: block; font-weight: 500; color: var(--ink); line-height: 1.5; }
.c-abc-cell .c-abc i { display: inline-block; min-width: 1.1em; margin-right: 4px; font-style: normal;
  font-weight: 700; font-size: 10px; letter-spacing: .06em; color: var(--ink3); }
.c-range { min-width: 190px; }
.btn-det { background: none; border: 1px solid #2b3d52; color: #6cc4ff; border-radius: 7px;
  padding: 5px 10px; font-size: 12.5px; cursor: pointer; font-family: inherit; white-space: nowrap; }
.btn-det:hover { border-color: #6cc4ff; }
.detrow td { background: #0d141c; }
.det { padding: 4px 2px 10px; color: var(--ink2); font-size: 13px; line-height: 1.6; }
.det p { margin: 0 0 8px; }
.det .srcs { color: var(--ink3); font-size: 12.5px; }

/* Shared-scale range bar (brief §14): every row is scaled against CC.scaleMax, the largest upper
   scenario in the dataset, so bars are comparable ACROSS clubs. A per-row scale would make a £3m
   club look like a £100m club. If a future upper scenario exceeds it, raise CC.scaleMax rather
   than rescaling individual rows. Colour is never the only signal: the numbers are always
   printed beneath the bar and the whole bar carries an aria-label. */
.rng { display: block; }
.rng-track { display: block; position: relative; height: 7px; border-radius: 99px; background: #16202c; }
.rng-fill { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 99px; background: #24425e; }
.rng-mid { position: absolute; top: -3px; width: 3px; height: 13px; background: #fff; border-radius: 2px;
  box-shadow: 0 0 0 2px rgba(13,20,28,.9); }
.rng-nums { display: flex; justify-content: space-between; font-size: 11px; color: var(--ink3); margin-top: 3px;
  font-variant-numeric: tabular-nums; }
.rng-cen { color: #fff; font-weight: 600; }

/* Visible focus on every interactive club target.
   The earlier rule sets `.tbar:focus-visible { outline: none }`, so this MUST come after it in
   source order or it loses. Without it, keyboard users get no focus indicator on the primary
   navigation controls — a WCAG failure that axe cannot detect, because axe checks contrast and
   roles, not the presence of a ring. */
.tbar:focus-visible, .tbar:focus, .rrcard:focus-visible, .rrcard:focus,
.c-link:focus-visible, .mc-name:focus-visible { outline: 2px solid #6cc4ff !important;
  outline-offset: 2px; border-radius: 4px; }
   /* --- focused club view ---
   The full record for one club. This is the single source of truth per club and the destination for
   every click on a club name, top-chart bar or reserved-rights card. */
.btn-back { margin: 0 0 16px; }
.focushead { border-bottom: 1px solid #24374b; padding-bottom: 14px; margin-bottom: 18px; }
.fh-name { font-size: 26px; font-weight: 700; color: #fff; letter-spacing: -.01em; }
.fh-sub { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 9px; }
.fh-hist { color: var(--ink2); font-size: 13px; margin-top: 8px; }
.focuscard { border: 1px solid #24374b; background: #0f1720; border-radius: 12px; padding: 18px 20px; }
.focuscard h4 { font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--ink3);
  margin: 20px 0 8px; font-weight: 600; }
.focuscard h4:first-child { margin-top: 0; }
.focuscard p { font-size: 14px; line-height: 1.6; color: var(--ink2); margin: 0 0 8px; }
.focuscard .rng { margin-bottom: 10px; }
.seasontable { width: 100%; border-collapse: collapse; font-size: 13px; }
.seasontable th, .seasontable td { padding: 7px 9px; text-align: left; border-bottom: 1px solid #1b2430; }
.seasontable thead th { color: var(--ink3); font-size: 11px; text-transform: uppercase; }
.focusnav { margin-top: 22px; }

.ec-cf { color: var(--ink2); font-size: 12.5px; margin-top: 5px; }
.ec-anal { margin-top: 7px; }
.ec-anal summary { font-size: 11.5px; color: var(--ink3); cursor: pointer; }
.ec-anal p { margin: 5px 0 0; font-size: 12.5px; color: var(--ink3); line-height: 1.5; }
.ecards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(260px, 100%), 1fr)); gap: 12px; }
.ecard { border: 1px solid #24374b; background: #0f1720; border-radius: 11px; padding: 12px 14px; }
.ec-season { color: #6cc4ff; font-size: 12px; letter-spacing: .05em; text-transform: uppercase; }
.ec-comp { font-size: 14px; margin: 4px 0 6px; color: var(--ink); }
.ec-note { color: var(--ink2); font-size: 12.5px; line-height: 1.5; }

.how { margin: 10px 0 0; border-top: 1px solid #24374b; padding-top: 8px; }
.how summary { cursor: pointer; color: var(--ink2); font-size: 13px; }
.how p { color: var(--ink2); font-size: 13px; line-height: 1.6; margin: 8px 0 0; }
.how.big { margin: 22px 0 0; }
/* Visually hidden. `left: 0; top: 0` matters: without an explicit offset an absolutely
   positioned element anchors at its STATIC position, so a .vh label inside a horizontally
   scrolling strip (the club filter row) landed ~480px off-canvas and made the whole DOCUMENT
   scroll at 200% zoom. Clipping it to a 1px box at the origin removes that. clip-path is the
   modern equivalent and keeps it out of view even where `clip` is unsupported. */
.vh { position: absolute; left: 0; top: 0; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }

/* --- mobile: semantic list of compact rows, not a squeezed table --- */
.mlist { list-style: none; margin: 0; padding: 0; }
.mclub { border: 1px solid #1b2430; border-radius: 12px; padding: 11px 13px; margin: 0 0 9px; background: #0f1720; }
.mc-top { display: flex; gap: 5px; flex-wrap: wrap; align-items: center; margin-bottom: 6px; }
.mc-mid { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.mc-cen { font-size: 17px; }
.mc-range { color: var(--ink3); font-size: 12.5px; font-variant-numeric: tabular-nums; }
/* The club name is the anchor for every mobile row. It was missing entirely, which made 35 rows of
   figures unreadable. Bold, full width, first line. */
.mc-name { font-weight: 700; color: var(--ink); font-size: 15px; background: none; border: 0;
  padding: 0; font-family: inherit; cursor: pointer; text-align: left; }
.c-link { background: none; border: 0; padding: 0; font: inherit; font-weight: 600; color: var(--ink);
  cursor: pointer; text-align: left; text-decoration: underline; text-decoration-color: #2f4a63;
  text-underline-offset: 2px; }
.c-link:hover { color: #6cc4ff; text-decoration-color: #6cc4ff; }
.mc-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.mc-basis { display: flex; gap: 5px; flex-wrap: wrap; margin-top: 6px; }
.mclub { border: 1px solid #24374b; background: #0f1720; border-radius: 11px; padding: 12px 13px;
  margin: 0 0 10px; list-style: none; }
.mc-mid { display: flex; justify-content: space-between; align-items: baseline; gap: 10px;
  margin-top: 9px; padding-top: 9px; border-top: 1px solid #1b2430; }
.mc-cen { font-size: 17px; font-weight: 700; color: #fff; }
.mc-range { font-size: 12.5px; color: var(--ink3); font-variant-numeric: tabular-nums; }
.mc-hist { margin: 7px 0 0; font-size: 12.5px; line-height: 1.45; color: var(--ink2); }
.mclub .btn-det { margin-top: 10px; width: 100%; }

/* Sections are flex/grid children of .view, so they inherit min-width:auto and refuse to shrink
   below their content. A scrolling strip inside then widens the whole document to 561px on a
   390px phone even though the strip itself clips correctly. */
.labrange, .reservedblk, .compblk, .topblk, .allblk, .explblk { min-width: 0; max-width: 100%; }

@media (min-width: 861px) { .mlist { display: none; } }
@media (max-width: 860px) {
  .tablescroll { display: none; }
  .rrgrid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .tbar { grid-template-columns: 118px minmax(0,1fr) 56px; }
}
/* The filter strip scrolls horizontally on a phone.
   Diagnosis: .filters is a flex row whose children total 743px. Even with the wrapper at
   overflow:hidden, min-width:0 and .filters itself at overflow-x:auto + width:100%, the strip's
   intrinsic width still propagated up and widened the document to 561px on a 390px screen.
   Measured in-page, each of these restored a 390px document: .filterswrap { contain: paint } and
   .filters { display: block }. clip-path: inset(0) and overflow-x:hidden did NOT help.
   `contain: paint` is the correct declaration: it clips the element's contents to its own box and
   makes it a containing block, so the overflow can no longer contribute to ancestor scroll width. */
.filterswrap { min-width: 0; max-width: 100%; contain: paint; }

/* 200% zoom on a 390px phone gives a ~195px CSS viewport, which is narrower than any of the
   breakpoints above. The fixed name/value columns in .tbar cannot shrink, so they pushed the
   DOCUMENT sideways. minmax(0, N) lets a column collapse to zero before the grid itself does,
   and the bar keeps its three-part shape at any width. */
@media (max-width: 300px) {
  .tbar { grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr) auto; gap: 6px; }
  .tbar .tb-name { font-size: 12.5px; }
  .tbar .tb-val { font-size: 12.5px; }
  .lr-nums { flex-wrap: wrap; }
  .rr-val { font-size: 22px; }
}

@media (max-width: 520px) {
  .rrgrid { grid-template-columns: minmax(0,1fr); }
  .lr-val { font-size: 24px; }
  .filters { flex-wrap: nowrap; overflow-x: auto; width: 100%; min-width: 0;
    padding-bottom: 4px; -webkit-overflow-scrolling: touch; }
  .fsearch { flex: 1 1 auto; min-width: 0; max-width: 100%; }
  .fsearch input { min-width: 0; }
  .tbar { grid-template-columns: 104px minmax(0,1fr) 52px; }
  .tb-name { font-size: 12.5px; }
}
/* Scenario presentation (audit item 6).
   Scenario B was headline everywhere: the focused card led with "B £Xm", the table had a single B
   column, the ranking sorted by B, and the reserved-rights cards showed B alone. Together those
   made B read as the expected figure even though nothing claimed it was. The range now leads and
   A/B/C sit beneath at the same size and weight, so no scenario is visually privileged. */
.mc-mid { flex-wrap: wrap; align-items: baseline; }
.mc-range { font-size: 17px; font-weight: 700; color: #fff; }
.mc-rangelab { font-size: 11.5px; color: var(--ink3); margin-left: 6px; }
.mc-abc, .rr-abc { flex-basis: 100%; margin-top: 6px; font-size: 12.5px; color: var(--ink2);
  font-variant-numeric: tabular-nums; display: flex; gap: 12px; flex-wrap: wrap; }
.mc-abc i, .rr-abc i { font-style: normal; font-weight: 700; color: var(--ink3); margin-right: 3px; }

.c-cen { white-space: normal; text-align: right; }
.c-abc { display: block; font-variant-numeric: tabular-nums; }
.c-abc i { font-style: normal; font-weight: 700; color: var(--ink3); margin-right: 3px; }

.rr-val { font-size: 20px; }
.rr-vallab { display: block; font-size: 11.5px; font-weight: 400; color: var(--ink3);
  margin-top: 2px; letter-spacing: 0; }
