/* ==========================================================================
   CURA Records Dashboard
   Everything is scoped under #cura-dash so it cannot leak into, or be
   clobbered by, the Astra theme.
   ========================================================================== */

#cura-dash {
  /* palette ------------------------------------------------------------- */
  --cam: #85b09a;          /* Cambridge — matches the site's sage green      */
  --cam-dark: #5c8a72;
  --cam-deep: #2f4a3c;
  --cam-wash: #e6efe9;
  --ox: #002147;           /* Oxford dark blue                               */
  --ox-light: #21467c;
  --ox-wash: #e2e7ef;
  --paper: #f8f5ef;
  --paper-2: #efe9dd;
  --paper-3: #e3dccd;
  --ink: #333836;
  --ink-soft: #6f7674;
  --ink-faint: #9aa09e;
  --gold: #b8913f;
  --blue-full: #a3c1ad;    /* Cambridge Blue, as the Blue is worn            */
  --blue-half-off: #f6f2e8;/* the off-white it is striped against            */
  --line: rgba(51, 56, 54, 0.14);

  /* One number for the height of the banner, added to the figures measured off
     the rest of the site. 0 is "exactly like /membership/ and the others"; 40px
     is a little roomier. Negative values work.

     Everything about the banner below was taken from the live site rather than
     guessed: on /membership/ the strip is 600px tall, the h1's top edge sits
     280px down, and the heading is Playfair Display 64px/1.4, bold, white,
     uppercase, centred. Those are the numbers to preserve. */
  --cd-banner-extra: 0px;

  /* type ---------------------------------------------------------------- */
  --serif: "Playfair Display", "Times New Roman", serif;
  --sans: "Source Sans Pro", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --radius: 4px;
  --shadow-1: 0 1px 2px rgba(47, 74, 60, 0.06), 0 4px 14px rgba(47, 74, 60, 0.07);
  --shadow-2: 0 2px 6px rgba(47, 74, 60, 0.10), 0 18px 44px rgba(47, 74, 60, 0.14);
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);

  font-family: var(--sans);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  position: relative;
}

#cura-dash *,
#cura-dash *::before,
#cura-dash *::after { box-sizing: border-box; }

#cura-dash h1, #cura-dash h2, #cura-dash h3, #cura-dash h4 {
  font-family: var(--serif);
  font-weight: 600;
  color: var(--cam-deep);
  margin: 0 0 0.4em;
  line-height: 1.2;
  letter-spacing: 0.01em;
}

#cura-dash p { margin: 0 0 1em; }

/* Full reset for form elements.
   WordPress themes style every <button> on the page — Astra applies
   `padding: 15px 33px`, a background colour, uppercase text and its own
   line-height. Every one of those has to be undone explicitly, or the
   dashboard's buttons inherit them. */
#cura-dash button,
#cura-dash input,
#cura-dash select,
#cura-dash textarea {
  font: inherit;
  font-family: var(--sans);
  letter-spacing: inherit;
  text-transform: none;
  line-height: inherit;
  color: inherit;
  margin: 0;
  min-height: 0;
  min-width: 0;
  box-shadow: none;
  text-shadow: none;
  -webkit-appearance: none;
  appearance: none;
}
#cura-dash button {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: none;
  cursor: pointer;
  text-align: inherit;
  width: auto;
}
#cura-dash button:hover,
#cura-dash button:focus {
  background: none;
  color: inherit;
  box-shadow: none;
}

/* Tables and lists likewise. */
#cura-dash table {
  border-collapse: collapse;
  margin: 0;
  width: 100%;
  background: none;
}
#cura-dash th,
#cura-dash td { border: 0; background: none; }
#cura-dash ul,
#cura-dash ol { margin: 0; padding: 0; list-style: none; }
#cura-dash li { margin: 0; }
#cura-dash svg { max-width: none; }
#cura-dash img { max-width: 100%; height: auto; border-radius: 0; }

/* The WordPress version sits inside Astra's centred content column. The Astro
   page has no wrapper of its own, so retain that reading width here while the
   section banner remains full bleed. */
#cura-dash > :not(.cd-banner):not(.cd-tip):not(.cd-lb) {
  width: min(1200px, calc(100% - 3rem));
  margin-left: auto;
  margin-right: auto;
}

/* --------------------------------------------------------------------------
   Utility
   -------------------------------------------------------------------------- */
#cura-dash .cd-eyebrow {
  font-size: 0.84rem;
  letter-spacing: 0;
  text-transform: uppercase;
  color: #74323d;
  font-weight: 700;
  margin-bottom: 0.85rem;
  display: block;
}

#cura-dash .cd-rule {
  height: 1px;
  background: linear-gradient(90deg, var(--line), transparent);
  border: 0;
  margin: 0 0 1.6rem;
}

#cura-dash .cd-sr {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

/* reveal-on-scroll */
#cura-dash [data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
#cura-dash [data-reveal].cd-in { opacity: 1; transform: none; }

/* --------------------------------------------------------------------------
   Sample-data banner
   -------------------------------------------------------------------------- */
#cura-dash .cd-sample {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  background: #fdf6e3;
  border: 1px solid #e6d3a3;
  border-left: 3px solid var(--gold);
  color: #6b5520;
  padding: 0.7rem 1rem;
  font-size: 0.86rem;
  border-radius: var(--radius);
  margin-bottom: 1.6rem;
}
#cura-dash .cd-sample strong { font-weight: 700; }

/* --------------------------------------------------------------------------
   Competition switcher
   -------------------------------------------------------------------------- */
#cura-dash .cd-compswitch {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 0.6rem;
  margin-bottom: 1.5rem;
}
#cura-dash .cd-comp {
  text-align: left;
  padding: 0.85rem 1.1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  position: relative;
  overflow: hidden;
  transition: all 0.35s var(--ease);
}
#cura-dash .cd-comp::before {
  content: "";
  position: absolute; left: 0; top: 0; bottom: 0; width: 3px;
  background: var(--cam-dark);
  transform: scaleY(0); transform-origin: top;
  transition: transform 0.4s var(--ease);
}
#cura-dash .cd-comp:hover { background: #fff; border-color: var(--cam); }
#cura-dash .cd-comp.cd-on { background: #fff; border-color: var(--cam-deep); box-shadow: var(--shadow-1); }
#cura-dash .cd-comp.cd-on::before { transform: scaleY(1); }
#cura-dash .cd-comp-name {
  display: block;
  font-family: var(--serif);
  font-size: 1.12rem;
  color: var(--cam-deep);
}
#cura-dash .cd-comp-sub {
  display: block;
  font-size: 0.76rem;
  color: var(--ink-soft);
  margin-top: 0.2rem;
  font-variant-numeric: tabular-nums;
}

#cura-dash .cd-blurb {
  font-size: 0.92rem;
  color: var(--ink-soft);
  max-width: 76ch;
  margin: 0 0 1.2rem;
}

/* --------------------------------------------------------------------------
   Headline statistics
   -------------------------------------------------------------------------- */
#cura-dash .cd-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 1.4rem;
}

#cura-dash .cd-stat {
  background: var(--paper);
  padding: 1.15rem 1rem 1rem;
  text-align: center;
  transition: background 0.35s var(--ease);
}
#cura-dash .cd-stat:hover { background: #fff; }

#cura-dash .cd-stat-num {
  font-family: var(--serif);
  font-size: clamp(1.7rem, 4.2vw, 2.5rem);
  line-height: 1;
  color: var(--cam-deep);
  font-variant-numeric: tabular-nums;
  display: block;
}
#cura-dash .cd-stat-num.cd-cam { color: var(--cam-dark); }
#cura-dash .cd-stat-num.cd-ox { color: var(--ox); }

#cura-dash .cd-stat-label {
  display: block;
  margin-top: 0.4rem;
  font-size: 0.7rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--ink-soft);
  font-weight: 600;
}

/* all-time balance bar */
#cura-dash .cd-balance { margin-bottom: 2.2rem; }
#cura-dash .cd-balance-bar {
  display: flex;
  height: 26px;
  border-radius: 3px;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px var(--line);
}
#cura-dash .cd-balance-seg {
  display: flex;
  align-items: center;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: #fff;
  width: 0;
  transition: width 1.4s var(--ease);
  white-space: nowrap;
  overflow: hidden;
}
#cura-dash .cd-balance-seg.cam { background: var(--cam-dark); padding-left: 0.7rem; }
#cura-dash .cd-balance-seg.draw { background: var(--paper-3); color: var(--ink-soft); justify-content: center; }
#cura-dash .cd-balance-seg.ox { background: var(--ox); justify-content: flex-end; padding-right: 0.7rem; }
#cura-dash .cd-balance-key {
  display: flex; justify-content: space-between;
  font-size: 0.74rem; color: var(--ink-soft); margin-top: 0.45rem;
  letter-spacing: 0.08em; text-transform: uppercase; font-weight: 600;
}

/* --------------------------------------------------------------------------
   Tab navigation
   -------------------------------------------------------------------------- */
#cura-dash .cd-tabs {
  display: flex;
  gap: 0.15rem;
  border-bottom: 1px solid var(--line);
  margin-bottom: 1.8rem;
  position: sticky;
  top: 0;
  z-index: 20;
  background: linear-gradient(var(--paper) 70%, rgba(248, 245, 239, 0.86));
  backdrop-filter: blur(6px);
  overflow-x: auto;
  scrollbar-width: none;
}
#cura-dash .cd-tabs::-webkit-scrollbar { display: none; }

#cura-dash .cd-tab {
  position: relative;
  padding: 0.75rem 1.15rem;
  font-size: 0.78rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--ink-soft);
  white-space: nowrap;
  transition: color 0.3s var(--ease);
}
#cura-dash .cd-tab::after {
  content: "";
  position: absolute; left: 0.9rem; right: 0.9rem; bottom: -1px;
  height: 2px; background: var(--cam-dark);
  transform: scaleX(0); transform-origin: center;
  transition: transform 0.4s var(--ease);
}
#cura-dash .cd-tab:hover { color: var(--cam-deep); }
#cura-dash .cd-tab[aria-selected="true"] { color: var(--cam-deep); }
#cura-dash .cd-tab[aria-selected="true"]::after { transform: scaleX(1); }

#cura-dash .cd-panel { display: none; animation: cd-fade 0.5s var(--ease); }
#cura-dash .cd-panel.cd-active { display: block; }
@keyframes cd-fade { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* --------------------------------------------------------------------------
   Timeline
   -------------------------------------------------------------------------- */
#cura-dash .cd-timeline-wrap {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.1rem 1.1rem 0.6rem;
  margin-bottom: 1.4rem;
  box-shadow: var(--shadow-1);
}

#cura-dash .cd-timeline-head {
  display: flex; flex-wrap: wrap; align-items: baseline;
  justify-content: space-between; gap: 0.6rem; margin-bottom: 0.7rem;
}
#cura-dash .cd-timeline-hint { font-size: 0.78rem; color: var(--ink-faint); }

#cura-dash .cd-timeline-scroll {
  overflow-x: auto;
  overflow-y: hidden;
  padding-bottom: 0.5rem;
  scrollbar-width: thin;
}
#cura-dash .cd-timeline-scroll::-webkit-scrollbar { height: 8px; }
#cura-dash .cd-timeline-scroll::-webkit-scrollbar-track { background: var(--paper-2); border-radius: 4px; }
#cura-dash .cd-timeline-scroll::-webkit-scrollbar-thumb { background: var(--paper-3); border-radius: 4px; }
#cura-dash .cd-timeline-scroll::-webkit-scrollbar-thumb:hover { background: var(--cam); }

#cura-dash .cd-tl-bar {
  transition: opacity 0.25s var(--ease), filter 0.25s var(--ease);
  cursor: pointer;
}
#cura-dash .cd-tl-col:hover .cd-tl-bar { filter: brightness(1.12); }
#cura-dash .cd-tl-hit { fill: transparent; cursor: pointer; }
#cura-dash .cd-tl-col.cd-dim { opacity: 0.22; }
#cura-dash .cd-tl-col.cd-sel .cd-tl-bar { filter: brightness(1.15); }
#cura-dash .cd-tl-axis { stroke: var(--line); stroke-width: 1; }
#cura-dash .cd-tl-decade { fill: var(--ink-faint); font-size: 10px; font-family: var(--sans); letter-spacing: 0.1em; }
#cura-dash .cd-tl-tick { stroke: var(--line); }
#cura-dash .cd-tl-gap { fill: var(--paper-2); }
#cura-dash .cd-tl-sel-ring { fill: none; stroke: var(--gold); stroke-width: 2; }
#cura-dash .cd-tl-photo-dot { fill: var(--gold); opacity: 0.75; }

#cura-dash .cd-tip {
  position: absolute;
  pointer-events: none;
  z-index: 60;
  background: var(--cam-deep);
  color: #fff;
  padding: 0.5rem 0.7rem;
  border-radius: 3px;
  font-size: 0.78rem;
  line-height: 1.35;
  box-shadow: var(--shadow-2);
  opacity: 0;
  transform: translate(-50%, -104%) scale(0.96);
  transition: opacity 0.16s var(--ease), transform 0.16s var(--ease);
  white-space: nowrap;
}
#cura-dash .cd-tip.cd-on { opacity: 1; transform: translate(-50%, -110%) scale(1); }
#cura-dash .cd-tip b { font-family: var(--serif); font-size: 0.92rem; display: block; margin-bottom: 0.15rem; }

/* timeline controls */
#cura-dash .cd-tl-controls {
  display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem;
  margin-bottom: 1.4rem;
}
#cura-dash .cd-chip {
  padding: 0.32rem 0.8rem;
  border: 1px solid var(--line);
  border-radius: 100px;
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--ink-soft);
  background: var(--paper);
  transition: all 0.28s var(--ease);
  letter-spacing: 0.03em;
}
#cura-dash .cd-chip:hover { border-color: var(--cam); color: var(--cam-deep); transform: translateY(-1px); }

/* A firer's average beside his name, in the roll under a college. Tabular
   figures so the percentages line up down a wrapped list. */
#cura-dash .cd-chip-name + .cd-chip-pct { margin-left: 0.45rem; }
#cura-dash .cd-chip-pct {
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  color: var(--cam-deep);
  opacity: 0.85;
}
#cura-dash .cd-chip-pct.cd-chip-none { color: var(--ink-faint); font-weight: 600; }

/* One-of-several controls, as on the college page: what to count and which
   match to count it over. Each row says what it governs, so the setting is
   readable at a glance rather than inferred from which button looks pressed. */
#cura-dash .cd-pick-row {
  display: flex; flex-wrap: wrap; gap: 0.8rem 1.8rem;
  align-items: center; margin: 0 0 1.4rem;
}
#cura-dash .cd-pick { display: flex; align-items: center; gap: 0.55rem; }
#cura-dash .cd-pick-label {
  font-size: 0.68rem; letter-spacing: 0.12em; text-transform: uppercase;
  font-weight: 700; color: var(--ink-faint);
}
#cura-dash .cd-pick-group { display: flex; flex-wrap: wrap; gap: 0.3rem; }
#cura-dash .cd-chip:hover .cd-chip-pct { opacity: 1; }
#cura-dash .cd-chip[aria-pressed="true"] .cd-chip-pct,
#cura-dash .cd-chip.cd-on .cd-chip-pct { color: #fff; }
#cura-dash .cd-chip[aria-pressed="true"],
#cura-dash .cd-chip.cd-on {
  background: var(--cam-deep); border-color: var(--cam-deep); color: #fff;
}

/* --------------------------------------------------------------------------
   Match record card
   -------------------------------------------------------------------------- */
#cura-dash .cd-match {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-1);
  overflow: hidden;
  animation: cd-rise 0.45s var(--ease);
}
@keyframes cd-rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

#cura-dash .cd-match-head {
  display: flex; flex-wrap: wrap; align-items: flex-end; gap: 0.8rem;
  justify-content: space-between;
  padding: 1.2rem 1.4rem 1rem;
  background: linear-gradient(180deg, var(--paper) 0%, #fff 100%);
  border-bottom: 1px solid var(--line);
}
#cura-dash .cd-match-year {
  font-family: var(--serif);
  font-size: clamp(2rem, 6vw, 3rem);
  line-height: 0.95;
  color: var(--cam-deep);
}
#cura-dash .cd-match-meta { font-size: 0.82rem; color: var(--ink-soft); }
#cura-dash .cd-match-meta span + span::before { content: "·"; margin: 0 0.45rem; color: var(--ink-faint); }

#cura-dash .cd-verdict {
  font-family: var(--serif);
  font-size: 1rem;
  padding: 0.3rem 0.9rem;
  border-radius: 100px;
  color: #fff;
  white-space: nowrap;
}
#cura-dash .cd-verdict.cam { background: var(--cam-dark); }
#cura-dash .cd-verdict.ox { background: var(--ox); }
#cura-dash .cd-verdict.draw { background: var(--paper-3); color: var(--ink); }
#cura-dash .cd-verdict.unknown { background: var(--paper-2); color: var(--ink-soft); }
#cura-dash .cd-verdict.none {
  background: transparent; color: var(--ink-faint);
  box-shadow: inset 0 0 0 1px var(--line);
}

#cura-dash .cd-scoreline { padding: 1.3rem 1.4rem; }
#cura-dash .cd-score-row {
  display: grid;
  grid-template-columns: 110px 1fr 78px;
  align-items: center;
  gap: 0.8rem;
  margin-bottom: 0.7rem;
}
#cura-dash .cd-score-side {
  font-family: var(--serif); font-size: 1.02rem; color: var(--ink);
}
#cura-dash .cd-score-track { background: var(--paper-2); height: 22px; border-radius: 2px; overflow: hidden; }
#cura-dash .cd-score-fill {
  height: 100%; width: 0;
  transition: width 1s var(--ease);
  border-radius: 2px;
}
#cura-dash .cd-score-fill.cam { background: linear-gradient(90deg, var(--cam), var(--cam-dark)); }
#cura-dash .cd-score-fill.ox { background: linear-gradient(90deg, var(--ox-light), var(--ox)); }
#cura-dash .cd-score-val {
  font-family: var(--serif); font-size: 1.3rem; text-align: right;
  font-variant-numeric: tabular-nums; color: var(--cam-deep);
}

#cura-dash .cd-match-notes {
  font-size: 0.9rem; color: var(--ink-soft); font-style: italic;
  border-left: 2px solid var(--paper-3); padding-left: 0.85rem; margin: 1rem 0 0;
}

#cura-dash .cd-score-foot {
  font-size: 0.76rem; color: var(--ink-faint); margin: 0.2rem 0 0;
  letter-spacing: 0.04em;
}

/* --- teams ---------------------------------------------------------------- */
#cura-dash .cd-match-teams {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  border-top: 1px solid var(--line);
}
#cura-dash .cd-team { padding: 1.2rem 1.4rem; min-width: 0; }
#cura-dash .cd-team + .cd-team { border-left: 1px solid var(--line); }
@media (max-width: 780px) {
  #cura-dash .cd-team + .cd-team { border-left: 0; border-top: 1px solid var(--line); }
}

/* Solid banner per side — the university should be unmistakable at a glance. */
#cura-dash .cd-team h4 {
  display: flex; align-items: center; justify-content: space-between; gap: 0.6rem;
  font-size: 0.78rem; letter-spacing: 0.14em; text-transform: uppercase;
  font-family: var(--sans); font-weight: 700;
  margin: 0 0 0.2rem;
  padding: 0.5rem 0.8rem;
  border-radius: 3px;
  color: #fff;
  background: var(--ink-faint);
}
#cura-dash .cd-team-cambridge h4 { background: var(--cam-dark); }
#cura-dash .cd-team-oxford h4 { background: var(--ox); }
#cura-dash .cd-team-cambridge { background:
  linear-gradient(180deg, rgba(133,176,154,0.10), rgba(133,176,154,0) 190px); }
#cura-dash .cd-team-oxford { background:
  linear-gradient(180deg, rgba(0,33,71,0.07), rgba(0,33,71,0) 190px); }
#cura-dash .cd-team-total {
  font-family: var(--serif); font-size: 1.1rem; letter-spacing: 0;
  text-transform: none; color: #fff; font-variant-numeric: tabular-nums;
}
#cura-dash .cd-team-captain {
  font-size: 0.78rem; color: var(--ink-soft); margin: 0.5rem 0 0.2rem;
  font-style: italic;
}

#cura-dash .cd-table-scroll { overflow-x: auto; margin-top: 0.4rem; }
#cura-dash .cd-team-table {
  width: 100%; border-collapse: collapse; font-size: 0.88rem;
}
#cura-dash .cd-team-table th {
  font-family: var(--sans); font-weight: 600; font-size: 0.66rem;
  letter-spacing: 0.09em; text-transform: uppercase; color: var(--ink-faint);
  text-align: right; padding: 0.4rem 0.4rem; white-space: nowrap;
}
#cura-dash .cd-team-table th.cd-th-name { text-align: left; }
#cura-dash .cd-team-table td {
  padding: 0.38rem 0.4rem; border-bottom: 1px dotted var(--line);
  vertical-align: baseline;
}
#cura-dash .cd-team-table tbody tr { transition: background 0.22s var(--ease); }
#cura-dash .cd-team-table tbody tr:hover { background: var(--cam-wash); }
#cura-dash .cd-team-oxford .cd-team-table tbody tr:hover { background: var(--ox-wash); }
#cura-dash .cd-td-name { display: flex; align-items: center; gap: 0.4rem; flex-wrap: wrap; }
#cura-dash .cd-td-num {
  text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap;
  color: var(--ink-soft);
}
#cura-dash .cd-td-total { color: var(--ink); font-weight: 600; }
#cura-dash .cd-tr-total td {
  border-top: 1px solid var(--line); border-bottom: 0;
  font-family: var(--serif); color: var(--cam-deep); padding-top: 0.55rem;
}
#cura-dash .cd-team-oxford .cd-tr-total td { color: var(--ox); }
#cura-dash .cd-tr-total .cd-td-name {
  font-family: var(--sans); font-size: 0.66rem; letter-spacing: 0.09em;
  text-transform: uppercase; color: var(--ink-faint); font-weight: 700;
}

/* Shooter names carry their university's colour outright. */
#cura-dash .cd-team-name {
  text-align: left; font-size: 0.92rem; font-weight: 600;
  border-bottom: 1px solid transparent; transition: border-color 0.25s;
  padding: 0;
}
#cura-dash .cd-team-cambridge .cd-team-name { color: var(--cam-deep); }
#cura-dash .cd-team-oxford .cd-team-name { color: var(--ox); }
#cura-dash .cd-team-cambridge .cd-td-name { box-shadow: inset 3px 0 0 var(--cam); }
#cura-dash .cd-team-oxford .cd-td-name { box-shadow: inset 3px 0 0 var(--ox); }
#cura-dash .cd-td-name { padding-left: 0.7rem; }
#cura-dash .cd-team-cambridge .cd-team-table tbody tr:hover .cd-team-name {
  border-bottom-color: var(--cam-dark);
}
#cura-dash .cd-team-oxford .cd-team-table tbody tr:hover .cd-team-name {
  border-bottom-color: var(--ox);
}
#cura-dash .cd-team-tag {
  font-size: 0.58rem; letter-spacing: 0.09em; text-transform: uppercase;
  background: var(--cam-deep); color: #fff; padding: 0.08rem 0.36rem; border-radius: 2px;
}
#cura-dash .cd-team-oxford .cd-team-tag { background: var(--ox); }

/* Walking the record: the year before, the year after, and the other Varsity
   match of the same summer. Three cells, so the middle one stays centred even
   when there is no previous or next match to show. */
#cura-dash .cd-match-nav {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: stretch;
  gap: 0.5rem; padding: 0.55rem 0.9rem;
  border-top: 1px solid var(--line); background: var(--paper);
}
#cura-dash .cd-match-step {
  display: flex; align-items: center; gap: 0.5rem;
  padding: 0.35rem 0.6rem; border-radius: 6px;
  font-family: var(--sans); text-decoration: none; color: var(--ink-soft);
  transition: background 0.15s ease, color 0.15s ease;
}
#cura-dash .cd-step-next { justify-content: flex-end; flex-direction: row-reverse; }
#cura-dash .cd-match-step:hover { background: var(--paper-3); color: var(--ink); }
#cura-dash .cd-step-none { pointer-events: none; visibility: hidden; }
#cura-dash .cd-step-arrow { font-size: 1.3rem; line-height: 1; opacity: 0.6; }
#cura-dash .cd-step-words { display: flex; flex-direction: column; line-height: 1.15; }
#cura-dash .cd-step-next .cd-step-words { align-items: flex-end; }
#cura-dash .cd-step-label {
  font-size: 0.6rem; letter-spacing: 0.11em; text-transform: uppercase;
  color: var(--ink-faint); font-weight: 700;
}
#cura-dash .cd-step-year { font-size: 0.92rem; font-weight: 600; }

#cura-dash .cd-match-swap { display: flex; align-items: center; }
#cura-dash .cd-match-other {
  display: inline-flex; align-items: center; gap: 0.45rem;
  padding: 0.36rem 0.8rem; border-radius: 999px;
  border: 1px solid var(--cam);
  font-family: var(--sans); font-size: 0.78rem; font-weight: 600;
  color: var(--cam-deep); text-decoration: none; white-space: nowrap;
  transition: background 0.15s ease, color 0.15s ease;
}
#cura-dash .cd-match-other:hover { background: var(--cam-deep); color: #fff; }
#cura-dash .cd-swap-icon { font-size: 0.95rem; opacity: 0.75; }

@media (max-width: 560px) {
  #cura-dash .cd-match-nav { grid-template-columns: 1fr 1fr; row-gap: 0.4rem; }
  #cura-dash .cd-match-swap { grid-column: 1 / -1; order: 3; justify-content: center; }
}

#cura-dash .cd-match-photos { padding: 1.2rem 1.4rem; border-top: 1px solid var(--line); }
#cura-dash .cd-match-photos h4 {
  font-family: var(--sans); font-size: 0.72rem; letter-spacing: 0.15em;
  text-transform: uppercase; color: var(--ink-faint); font-weight: 700;
  margin-bottom: 0.7rem;
}
#cura-dash .cd-photo-strip {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 0.7rem;
}
/* Under a score table a photograph is usually one of several from the day —
   the team, then the squad or the prize-giving — so each says what it is
   rather than leaving the reader to open all of them to find out. */
#cura-dash .cd-match-photo { margin: 0; display: flex; flex-direction: column; }
#cura-dash .cd-match-photo .cd-frame { flex: 1 1 auto; }
#cura-dash .cd-match-photo figcaption {
  font-family: var(--sans); font-size: 0.7rem; line-height: 1.35;
  color: var(--ink-faint); margin-top: 0.4rem;
}

#cura-dash .cd-empty-panel {
  background: var(--paper); border: 1px dashed var(--paper-3);
  border-radius: var(--radius); padding: 2.4rem 1.8rem; text-align: center;
}
#cura-dash .cd-empty-panel .cd-blurb { margin: 0 auto; max-width: 62ch; }
#cura-dash .cd-ph-file {
  font-size: 0.66rem; opacity: 0.7; word-break: break-all; margin-top: 0.15rem;
}

/* --------------------------------------------------------------------------
   University identity on search cards
   -------------------------------------------------------------------------- */
#cura-dash .cd-person-card { border-left: 6px solid var(--paper-3); }
#cura-dash .cd-person-card.cd-u-cambridge {
  border-left-color: var(--cam-dark); background: var(--cam-wash);
}
#cura-dash .cd-person-card.cd-u-oxford {
  border-left-color: var(--ox); background: var(--ox-wash);
}
#cura-dash .cd-person-card.cd-u-both {
  border-left-color: transparent;
  border-image: linear-gradient(var(--cam-dark) 50%, var(--ox) 50%) 1;
  border-image-width: 0 0 0 6px;
}
#cura-dash .cd-person-card.cd-u-cambridge .cd-person-name { color: var(--cam-deep); }
#cura-dash .cd-person-card.cd-u-oxford .cd-person-name { color: var(--ox); }
#cura-dash .cd-person-card:hover { background: #fff; }

/* --------------------------------------------------------------------------
   Eras
   -------------------------------------------------------------------------- */
#cura-dash .cd-era-filters { margin-bottom: 1rem; }

#cura-dash .cd-era-banner {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.2rem 0.9rem;
  background: var(--cam-deep); color: #fff;
  padding: 0.6rem 1rem; border-radius: var(--radius); margin-bottom: 1.3rem;
}
#cura-dash .cd-era-banner-label { font-family: var(--serif); font-size: 1.15rem; }
#cura-dash .cd-era-banner-detail { font-size: 0.8rem; opacity: 0.82; }

#cura-dash .cd-era-card { margin-bottom: 1.6rem; }
#cura-dash .cd-era-table { width: 100%; border-collapse: collapse; font-size: 0.86rem; }
#cura-dash .cd-era-table th {
  font-size: 0.64rem; letter-spacing: 0.11em; text-transform: uppercase;
  color: var(--ink-faint); font-weight: 700; text-align: left;
  padding: 0.5rem 0.5rem; white-space: nowrap;
}
#cura-dash .cd-era-table th.cd-th-total { text-align: right; }
#cura-dash .cd-era-table td {
  padding: 0.55rem 0.5rem; border-top: 1px solid var(--line); vertical-align: top;
}
#cura-dash .cd-era-table tbody tr:hover { background: var(--paper); }
#cura-dash .cd-era-label { white-space: nowrap; }
#cura-dash .cd-era-jump {
  font-family: var(--serif); font-size: 1rem; color: var(--cam-deep);
  border-bottom: 1px solid transparent; transition: border-color 0.25s;
}
#cura-dash .cd-era-jump:hover { border-bottom-color: var(--cam); }
#cura-dash .cd-era-count {
  display: block; font-size: 0.66rem; color: var(--ink-faint);
  letter-spacing: 0.06em; margin-top: 0.1rem;
}
#cura-dash .cd-era-detail { color: var(--ink-soft); font-size: 0.8rem; min-width: 15rem; }
#cura-dash .cd-era-score {
  display: block; font-family: var(--serif); font-size: 1.05rem; color: var(--cam-deep);
}
#cura-dash .cd-era-who {
  display: block; font-size: 0.72rem; color: var(--ink-soft); margin-top: 0.1rem;
}
#cura-dash .cd-era-link { text-align: right; width: 100%; }
#cura-dash .cd-era-link:hover { color: var(--cam-dark); text-decoration: underline; }

/* timeline era bands */
#cura-dash .cd-tl-era-bg { fill: rgba(47, 74, 60, 0.035); }
#cura-dash .cd-tl-era-alt .cd-tl-era-bg { fill: transparent; }
#cura-dash .cd-tl-era-label {
  fill: var(--ink-faint); font-family: var(--sans); font-size: 9px;
  letter-spacing: 0.08em; font-weight: 600;
}
#cura-dash .cd-tl-era:hover .cd-tl-era-bg { fill: rgba(133, 176, 154, 0.14); }

/* --------------------------------------------------------------------------
   Photo frames
   -------------------------------------------------------------------------- */
#cura-dash .cd-frame {
  display: block; width: 100%; padding: 0;
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-1);
  overflow: hidden;
  position: relative;
  transition: transform 0.45s var(--ease), box-shadow 0.45s var(--ease);
}
#cura-dash .cd-frame:hover { transform: translateY(-3px); box-shadow: var(--shadow-2); }
#cura-dash .cd-frame img {
  display: block; width: 100%; height: auto;
  filter: sepia(0.12) saturate(0.94);
  transition: filter 0.5s var(--ease), transform 0.9s var(--ease);
}
#cura-dash .cd-frame:hover img { filter: sepia(0) saturate(1); transform: scale(1.02); }

#cura-dash .cd-frame-ph {
  aspect-ratio: 4 / 3;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 0.4rem;
  background:
    repeating-linear-gradient(45deg, var(--paper-2) 0 10px, var(--paper) 10px 20px);
  color: var(--ink-faint);
  font-size: 0.78rem;
  text-align: center;
  padding: 1rem;
}
#cura-dash .cd-frame-ph svg { opacity: 0.4; }

#cura-dash .cd-caption {
  font-size: 0.8rem; color: var(--ink-soft); line-height: 1.45; margin-top: 0.6rem;
}

/* --------------------------------------------------------------------------
   Competitor search
   -------------------------------------------------------------------------- */
#cura-dash .cd-search-wrap { position: relative; margin-bottom: 1.4rem; }
#cura-dash .cd-search {
  width: 100%;
  padding: 0.9rem 1rem 0.9rem 2.9rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%236f7674' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='M20 20l-4.2-4.2'/%3E%3C/svg%3E") no-repeat 1rem center;
  font-size: 1rem;
  color: var(--ink);
  transition: border-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
}
#cura-dash .cd-search:focus {
  outline: none;
  border-color: var(--cam);
  box-shadow: 0 0 0 3px rgba(133, 176, 154, 0.22);
}
#cura-dash .cd-search::placeholder { color: var(--ink-faint); }

#cura-dash .cd-results {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(215px, 1fr));
  gap: 0.7rem;
  margin-bottom: 1.6rem;
}
#cura-dash .cd-person-card {
  text-align: left;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.85rem 0.95rem;
  transition: all 0.3s var(--ease);
  animation: cd-rise 0.4s var(--ease) backwards;
}
#cura-dash .cd-person-card:hover {
  background: #fff; border-color: var(--cam);
  transform: translateY(-2px); box-shadow: var(--shadow-1);
}
#cura-dash .cd-person-card.cd-on { border-color: var(--cam-deep); background: #fff; box-shadow: var(--shadow-1); }
#cura-dash .cd-person-name { font-family: var(--serif); font-size: 1.05rem; color: var(--cam-deep); }
#cura-dash .cd-person-sub { font-size: 0.76rem; color: var(--ink-soft); margin-top: 0.15rem; }

#cura-dash .cd-person-detail {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow-1); padding: 1.4rem; animation: cd-rise 0.45s var(--ease);
}
#cura-dash .cd-person-detail h3 { font-size: 1.6rem; margin-bottom: 0.15rem; }

#cura-dash .cd-mini-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 160px));
  justify-content: start;
  gap: 0.6rem;
  margin: 1.1rem 0 1.3rem;
}
#cura-dash .cd-mini {
  background: var(--paper); border-radius: 3px; padding: 0.7rem 0.5rem; text-align: center;
}
#cura-dash .cd-mini-num {
  font-family: var(--serif); font-size: 1.45rem; color: var(--cam-deep);
  font-variant-numeric: tabular-nums; display: block; line-height: 1;
}
#cura-dash .cd-mini-label {
  font-size: 0.63rem; letter-spacing: 0.11em; text-transform: uppercase;
  color: var(--ink-soft); font-weight: 600; margin-top: 0.35rem; display: block;
}

#cura-dash .cd-year-pills { display: flex; flex-wrap: wrap; gap: 0.35rem; }
#cura-dash .cd-year-pill {
  font-family: var(--serif); font-size: 0.86rem;
  padding: 0.25rem 0.6rem; border-radius: 3px;
  background: var(--paper-2); color: var(--cam-deep);
  transition: all 0.25s var(--ease);
}
#cura-dash .cd-year-pill:hover { background: var(--cam-deep); color: #fff; transform: translateY(-2px); }

/* --------------------------------------------------------------------------
   A shooter's appearances: year, score and who won, kept visually distinct
   -------------------------------------------------------------------------- */
#cura-dash .cd-comp-section {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 0 1rem;
  margin-bottom: 1.4rem;
  overflow: hidden;
  background: var(--paper);
}
#cura-dash .cd-comp-head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 0.8rem; flex-wrap: wrap;
  padding: 0.75rem 1rem;
  background: #fff;
  border-bottom: 1px solid var(--line);
}
#cura-dash .cd-comp-head h4 {
  font-family: var(--serif); font-size: 1.12rem; color: var(--cam-deep); margin: 0;
}
#cura-dash .cd-comp-span {
  font-size: 0.78rem; color: var(--ink-soft); font-variant-numeric: tabular-nums;
  letter-spacing: 0.06em;
}
#cura-dash .cd-comp-section .cd-mini-stats { margin: 0.9rem 1rem 1.1rem; }
#cura-dash .cd-mini-note {
  display: block; font-size: 0.68rem; color: var(--ink-faint); margin-top: 0.2rem;
}

#cura-dash .cd-year-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(104px, 1fr));
  gap: 0.5rem;
  padding: 0 1rem;
}

#cura-dash .cd-ybox {
  display: flex; flex-direction: column; align-items: stretch;
  border: 1px solid var(--line);
  border-radius: 3px;
  overflow: hidden;
  background: #fff;
  text-align: center;
  transition: transform 0.28s var(--ease), box-shadow 0.28s var(--ease);
}
#cura-dash .cd-ybox:hover { transform: translateY(-3px); box-shadow: var(--shadow-1); }

/* Year band — the colour of whichever university won that match. */
#cura-dash .cd-ybox-year {
  font-family: var(--serif); font-size: 1.02rem; letter-spacing: 0.04em;
  padding: 0.3rem 0.2rem;
  color: #fff;
  background: var(--ink-faint);
}
/* The banner is the side he shot for, not the side that won — the two part
   company for the men who turned out for both universities. */
#cura-dash .cd-ybox.cd-for-cam .cd-ybox-year { background: var(--cam-dark); }
#cura-dash .cd-ybox.cd-for-ox .cd-ybox-year { background: var(--ox); }
#cura-dash .cd-ybox.cd-for-unknown .cd-ybox-year { background: var(--paper-2);
  color: var(--ink-soft); }

#cura-dash .cd-ybox-body { padding: 0.5rem 0.25rem 0.35rem; }
#cura-dash .cd-ybox-score {
  font-family: var(--serif); font-size: 1.08rem; color: var(--ink);
  font-variant-numeric: tabular-nums;
}
#cura-dash .cd-ybox-foot {
  font-size: 0.6rem; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--ink-faint); font-weight: 600;
  padding: 0 0.25rem 0.45rem;
}
#cura-dash .cd-ybox.cd-w-cam .cd-ybox-foot { color: var(--cam-dark); }
#cura-dash .cd-ybox.cd-w-ox .cd-ybox-foot { color: var(--ox); }
/* A loss for this shooter reads quieter than a win. */
#cura-dash .cd-ybox-lost { background: var(--paper); }
#cura-dash .cd-ybox-lost .cd-ybox-score { color: var(--ink-soft); }
#cura-dash .cd-ybox-won .cd-ybox-score { font-weight: 600; }

/* Top score of the match, across both teams: a gold edge on the plaque. */
#cura-dash .cd-ybox-top { border-color: var(--gold);
  box-shadow: inset 0 0 0 1px var(--gold); background: #fffdf6; }
#cura-dash .cd-ybox-top.cd-ybox-lost { background: #fffbf0; }
/* Among the twenty best ever shot in that era. */
#cura-dash .cd-ybox-crown { display: block; margin-top: .12rem;
  font-size: .62rem; letter-spacing: .04em; font-weight: 700;
  color: #8a6a1c; text-transform: uppercase; }
#cura-dash .cd-crown { font-size: .8rem; letter-spacing: 0;
  margin-right: .15rem; vertical-align: -.05em; }

#cura-dash .cd-empty {
  text-align: center; padding: 2.6rem 1rem; color: var(--ink-faint);
  font-family: var(--serif); font-size: 1.05rem;
}

/* --------------------------------------------------------------------------
   Gallery
   -------------------------------------------------------------------------- */
#cura-dash .cd-filters {
  display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 1.2rem;
  align-items: center;
}
#cura-dash .cd-filter-sep { width: 1px; height: 20px; background: var(--line); margin: 0 0.4rem; }

/* A grid, not columns. CSS columns fill top-to-bottom before moving right,
   so a chronological album read down the first column and then jumped back to
   1920 at the top of the second. A grid fills left-to-right, which is how a
   date-ordered set of photographs is meant to be read. */
#cura-dash .cd-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 0.8rem;
  align-items: start;
}
#cura-dash .cd-gallery > * {
  margin-bottom: 0;
  animation: cd-rise 0.5s var(--ease) backwards;
}
#cura-dash .cd-gal-item { position: relative; }
#cura-dash .cd-gal-badge {
  position: absolute; top: 0; left: 0;
  background: rgba(47, 74, 60, 0.86); color: #fff;
  font-family: var(--serif); font-size: 0.82rem;
  padding: 0.18rem 0.55rem;
  letter-spacing: 0.04em;
}
#cura-dash .cd-gal-over {
  position: absolute; inset: auto 0 0 0;
  background: linear-gradient(transparent, rgba(24, 32, 28, 0.86));
  color: #fff; padding: 1.6rem 0.7rem 0.6rem;
  font-size: 0.78rem; text-align: left;
  opacity: 0; transform: translateY(8px);
  transition: opacity 0.35s var(--ease), transform 0.35s var(--ease);
}
#cura-dash .cd-frame:hover .cd-gal-over { opacity: 1; transform: none; }

/* --------------------------------------------------------------------------
   Lightbox
   -------------------------------------------------------------------------- */
#cura-dash .cd-lb {
  position: fixed; inset: 0; z-index: 9999;
  background: rgba(20, 27, 24, 0.94);
  display: none;
  opacity: 0;
  transition: opacity 0.3s var(--ease);
}
#cura-dash .cd-lb.cd-open { display: flex; flex-direction: column; }
#cura-dash .cd-lb.cd-shown { opacity: 1; }

#cura-dash .cd-lb-stage {
  flex: 1; display: flex; align-items: center; justify-content: center;
  padding: 3rem 4rem 0.5rem; min-height: 0; position: relative;
}
#cura-dash .cd-lb-stage img {
  max-width: 100%; max-height: 100%; object-fit: contain;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5);
  background: #fff;
  animation: cd-zoom 0.4s var(--ease);
  cursor: zoom-in;
}
#cura-dash .cd-lb-stage img.cd-zoomed { cursor: zoom-out; max-width: none; max-height: none; }
#cura-dash .cd-lb-stage.cd-scroll { overflow: auto; align-items: flex-start; justify-content: flex-start; }
@keyframes cd-zoom { from { opacity: 0; transform: scale(0.96); } to { opacity: 1; transform: none; } }

#cura-dash .cd-lb-ph {
  width: min(680px, 80vw); aspect-ratio: 4/3;
  background: repeating-linear-gradient(45deg, #2a332e 0 12px, #232b27 12px 24px);
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,0.45); font-size: 0.9rem; text-align: center; padding: 2rem;
}

#cura-dash .cd-lb-bar {
  padding: 0.9rem 1.4rem 1.3rem;
  color: rgba(255, 255, 255, 0.88);
  max-height: 34vh; overflow-y: auto;
  background: linear-gradient(transparent, rgba(0,0,0,0.35));
}
#cura-dash .cd-lb-title { font-family: var(--serif); font-size: 1.15rem; color: #fff; margin-bottom: 0.2rem; }
#cura-dash .cd-lb-cap { font-size: 0.85rem; line-height: 1.5; color: rgba(255,255,255,0.72); max-width: 70ch; }
#cura-dash .cd-lb-people { display: flex; flex-wrap: wrap; gap: 0.35rem; margin-top: 0.7rem; }

/* The key under the photograph, laid out the way the album writes it. */
#cura-dash .cd-lb-key { margin-top: 0.8rem; display: flex; flex-direction: column; gap: 0.3rem; }
#cura-dash .cd-lb-row {
  display: flex; flex-wrap: wrap; gap: 0.3rem; align-items: center;
  justify-content: center;
}
#cura-dash .cd-lb-rowlabel {
  font-size: 0.62rem; letter-spacing: 0.12em; text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45); min-width: 3.4rem; text-align: right;
  margin-right: 0.3rem;
}

/* Faces, boxed over the picture. */
#cura-dash .cd-face {
  position: absolute; border: 2px solid rgba(133, 176, 154, 0);
  border-radius: 2px; padding: 0; background: none;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
#cura-dash .cd-lb-stage:hover .cd-face { border-color: rgba(133, 176, 154, 0.45); }
#cura-dash .cd-face:hover,
#cura-dash .cd-face.cd-face-on {
  border-color: var(--cam); box-shadow: 0 0 0 2px rgba(20, 27, 24, 0.55);
}
#cura-dash .cd-face-name {
  position: absolute; left: 50%; top: 100%; transform: translate(-50%, 4px);
  background: var(--cam-deep); color: #fff; font-size: 0.68rem;
  padding: 0.1rem 0.4rem; border-radius: 2px; white-space: nowrap;
  opacity: 0; pointer-events: none; transition: opacity 0.2s var(--ease);
}
#cura-dash .cd-face:hover .cd-face-name,
#cura-dash .cd-face.cd-face-on .cd-face-name { opacity: 1; }
#cura-dash .cd-lb-chip {
  font-size: 0.78rem; padding: 0.22rem 0.62rem; border-radius: 100px;
  background: rgba(255,255,255,0.12); color: #fff;
  transition: background 0.25s var(--ease), transform 0.25s var(--ease);
}
#cura-dash .cd-lb-chip:hover { background: var(--cam); transform: translateY(-1px); }

#cura-dash .cd-lb-btn {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 46px; height: 46px; border-radius: 50%;
  background: rgba(255,255,255,0.1); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem; transition: background 0.25s var(--ease);
  z-index: 3;
}
#cura-dash .cd-lb-btn:hover { background: var(--cam); }
#cura-dash .cd-lb-prev { left: 0.8rem; }
#cura-dash .cd-lb-next { right: 0.8rem; }
#cura-dash .cd-lb-close {
  position: absolute; top: 0.9rem; right: 1.1rem;
  width: 40px; height: 40px; border-radius: 50%;
  background: rgba(255,255,255,0.1); color: #fff; font-size: 1.3rem;
  display: flex; align-items: center; justify-content: center; z-index: 4;
  transition: background 0.25s var(--ease), transform 0.25s var(--ease);
}
#cura-dash .cd-lb-close:hover { background: rgba(255,255,255,0.24); transform: rotate(90deg); }
#cura-dash .cd-lb-count {
  position: absolute; top: 1.3rem; left: 1.4rem;
  font-size: 0.78rem; letter-spacing: 0.12em; color: rgba(255,255,255,0.6);
}

/* --------------------------------------------------------------------------
   Stats panel
   -------------------------------------------------------------------------- */
#cura-dash .cd-cards {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem; margin-bottom: 1.6rem;
}
#cura-dash .cd-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.1rem 1.2rem; box-shadow: var(--shadow-1);
  transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
#cura-dash .cd-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-2); }
#cura-dash .cd-card h4 {
  font-family: var(--sans); font-size: 0.7rem; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--ink-faint); font-weight: 700; margin-bottom: 0.7rem;
}
#cura-dash .cd-card-big {
  font-family: var(--serif); font-size: 2rem; color: var(--cam-deep); line-height: 1;
}
#cura-dash .cd-card-sub { font-size: 0.85rem; color: var(--ink-soft); margin-top: 0.35rem; }

/* A ranked list carries a name, a note under it and a figure, and all three
   have to be readable at once. Packed into the same 260px column as a headline
   card they squeeze into an unreadable ribbon, so the rankings get a wider
   minimum of their own — three across a desktop page rather than five. */
#cura-dash .cd-rank-cards {
  grid-template-columns: repeat(auto-fit, minmax(330px, 1fr));
}
#cura-dash .cd-rank-note {
  font-size: 0.72rem; line-height: 1.45; color: var(--ink-faint);
  margin: -0.2rem 0 0.5rem;
}

#cura-dash .cd-rank { list-style: none; margin: 0; padding: 0; counter-reset: r; }
#cura-dash .cd-rank li {
  display: flex; align-items: baseline; gap: 0.6rem;
  padding: 0.4rem 0; border-bottom: 1px dotted var(--line); font-size: 0.9rem;
}
#cura-dash .cd-rank li:last-child { border-bottom: 0; }
#cura-dash .cd-rank li::before {
  counter-increment: r; content: counter(r);
  font-family: var(--serif); color: var(--ink-faint); font-size: 0.8rem;
  width: 1.6rem; text-align: right; flex: none;
}
#cura-dash .cd-rank .cd-rank-name { flex: 1; text-align: left; min-width: 0; }
#cura-dash .cd-rank-who {
  border-bottom: 1px solid transparent; transition: border-color 0.25s, color 0.25s;
}
#cura-dash .cd-rank-name:hover .cd-rank-who {
  color: var(--cam-dark); border-bottom-color: var(--cam);
}
/* A row that names a college leads nowhere, so it does not offer to. */
#cura-dash .cd-rank-flat { cursor: default; }
#cura-dash .cd-rank-flat:hover .cd-rank-who {
  color: inherit; border-bottom-color: transparent;
}
#cura-dash .cd-rank-sub {
  display: block; font-size: 0.72rem; color: var(--ink-faint); margin-top: 0.05rem;
}
#cura-dash .cd-rank .cd-rank-val {
  font-family: var(--serif); color: var(--cam-deep); font-variant-numeric: tabular-nums;
  flex: none; white-space: nowrap;
}

/* Scrollable rankings: the leaders are visible, the rest are a flick away. */
#cura-dash .cd-rank-card { position: relative; }
#cura-dash .cd-rank-count {
  float: right; font-size: 0.62rem; letter-spacing: 0.08em;
  color: var(--ink-faint); font-weight: 600; text-transform: none;
}
#cura-dash .cd-rank-scroll {
  max-height: 19.5rem;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: var(--paper-3) transparent;
  padding-right: 0.3rem;
}
#cura-dash .cd-rank-scroll::-webkit-scrollbar { width: 7px; }
#cura-dash .cd-rank-scroll::-webkit-scrollbar-track {
  background: var(--paper-2); border-radius: 4px;
}
#cura-dash .cd-rank-scroll::-webkit-scrollbar-thumb {
  background: var(--paper-3); border-radius: 4px;
}
#cura-dash .cd-rank-scroll::-webkit-scrollbar-thumb:hover { background: var(--cam); }

/* Fade at the foot, hidden once you reach the end. */
#cura-dash .cd-rank-card::after {
  content: "";
  position: absolute; left: 1px; right: 8px; bottom: 1px; height: 2.6rem;
  background: linear-gradient(rgba(255, 255, 255, 0), #fff 85%);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s var(--ease);
  border-radius: 0 0 var(--radius) var(--radius);
}
#cura-dash .cd-rank-card.cd-rank-more::after { opacity: 1; }

#cura-dash .cd-decades { display: flex; flex-direction: column; gap: 0.45rem; }
#cura-dash .cd-decade-row { display: grid; grid-template-columns: 56px 1fr 62px; align-items: center; gap: 0.6rem; font-size: 0.82rem; }
#cura-dash .cd-decade-label { color: var(--ink-soft); font-variant-numeric: tabular-nums; }
#cura-dash .cd-decade-track { display: flex; height: 15px; border-radius: 2px; overflow: hidden; background: var(--paper-2); }
#cura-dash .cd-decade-track span { width: 0; transition: width 0.9s var(--ease); }
#cura-dash .cd-decade-track .cam { background: var(--cam-dark); }
#cura-dash .cd-decade-track .draw { background: var(--paper-3); }
#cura-dash .cd-decade-track .ox { background: var(--ox); }
#cura-dash .cd-decade-val { text-align: right; color: var(--ink-soft); font-variant-numeric: tabular-nums; }

/* --------------------------------------------------------------------------
   Loading / error
   -------------------------------------------------------------------------- */
#cura-dash .cd-loading {
  padding: 4rem 1rem; text-align: center; color: var(--ink-faint);
  font-family: var(--serif); font-size: 1.05rem;
}
#cura-dash .cd-loading::after {
  content: ""; display: block; width: 28px; height: 28px; margin: 1rem auto 0;
  border: 2px solid var(--paper-3); border-top-color: var(--cam-dark);
  border-radius: 50%; animation: cd-spin 0.9s linear infinite;
}
@keyframes cd-spin { to { transform: rotate(360deg); } }

#cura-dash .cd-error {
  background: #fdecea; border: 1px solid #f3c1bb; color: #8a2b1f;
  padding: 1rem 1.2rem; border-radius: var(--radius); font-size: 0.9rem;
}

/* --------------------------------------------------------------------------
   Reduced motion
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  #cura-dash *, #cura-dash *::before, #cura-dash *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
  #cura-dash [data-reveal] { opacity: 1; transform: none; }
}

/* ---------------------------------------------------------------- *
 * Colleges
 * ---------------------------------------------------------------- */
#cura-dash .cd-rank-who.cd-cambridge { color: var(--cam-deep); }
#cura-dash .cd-rank-who.cd-oxford { color: var(--ox); }

/* The men who shot for a college, revealed under its row. */
#cura-dash .cd-college-who {
  display: flex; flex-wrap: wrap; gap: .3rem;
  padding: .5rem .6rem .7rem; margin: 0;
  background: var(--cam-wash); border-radius: 4px;
}
#cura-dash .cd-college-who::before { content: none; }

/* Appearances by decade. A block per decade, shaded by how many. */
#cura-dash .cd-college-time { grid-column: 1 / -1; }
#cura-dash .cd-heat-scroll { overflow-x: auto; }
#cura-dash .cd-heat {
  border-collapse: collapse; width: 100%; font-size: .78rem;
}
#cura-dash .cd-heat th {
  font-weight: 600; text-align: center; padding: .2rem .3rem;
  color: var(--ink-soft, #5b6660); white-space: nowrap;
}
#cura-dash .cd-heat .cd-heat-col {
  text-align: right; padding-right: .6rem; white-space: nowrap;
  position: sticky; left: 0; background: var(--panel, #fff);
}
#cura-dash .cd-heat td { padding: 1px 2px; }
#cura-dash .cd-heat-cell {
  display: block; min-width: 1.6rem; line-height: 1.5rem;
  text-align: center; border-radius: 3px;
  background: var(--cam-dark); color: #fff; font-variant-numeric: tabular-nums;
}

/* A photo key that reads as a caption: name, then college and role. */
#cura-dash .cd-lb-chip { display: inline-flex; flex-direction: column;
  align-items: flex-start; line-height: 1.25; text-align: left; }
#cura-dash .cd-lb-who { font-weight: 600; }
#cura-dash .cd-lb-sub { font-size: .72rem; opacity: .72; letter-spacing: .01em; }
#cura-dash .cd-lb-unknown { opacity: .4; font-style: italic; }

/* Numbered key: count along the row and the name is the man. */
#cura-dash .cd-lb-key { gap: .5rem; }
#cura-dash .cd-lb-row { align-items: flex-start; gap: .45rem; flex-wrap: wrap; }
#cura-dash .cd-lb-rowlabel { font-size: .68rem; text-transform: uppercase;
  letter-spacing: .08em; opacity: .6; width: 100%; margin-bottom: .15rem; }
#cura-dash .cd-lb-chip { display: inline-flex; align-items: baseline; gap: .35rem;
  padding: .3rem .5rem; border-radius: 4px; background: rgba(255,255,255,.07);
  line-height: 1.3; text-align: left; }
#cura-dash .cd-lb-num { font-size: .68rem; opacity: .55;
  font-variant-numeric: tabular-nums; min-width: .9em; }
#cura-dash .cd-lb-who { font-weight: 600; }
#cura-dash .cd-lb-sub { font-size: .72rem; opacity: .72; display: block; }
#cura-dash .cd-lb-unknown { opacity: .45; font-style: italic; }

/* The side's photograph, beneath its scores. */
#cura-dash .cd-team-photo { margin: .9rem 0 0; }
#cura-dash .cd-team-photo-btn { display: block; width: 100%; padding: 0;
  border: 0; background: none; cursor: zoom-in; }
#cura-dash .cd-team-photo img { display: block; width: 100%; height: auto;
  border-radius: 4px; }
#cura-dash .cd-team-photo-cap { font-size: .72rem; opacity: .65;
  margin-top: .35rem; }

/* Name tags: centred, name over college over role. */
#cura-dash .cd-lb-chip { flex-direction: column; align-items: center;
  text-align: center; gap: .1rem; padding: .35rem .55rem; }
#cura-dash .cd-lb-num { opacity: .5; }
#cura-dash .cd-lb-sub { display: block; text-align: center; }
#cura-dash .cd-lb-role { font-variant: small-caps; letter-spacing: .04em;
  opacity: .85; }

/* Under the picture: the title, centred, with a quiet way through to the
   scores. The link is a line of text rather than a bar — it should be
   available without competing with the photograph. */
#cura-dash .cd-lb-title { text-align: center; }
#cura-dash .cd-lb-match {
  display: block; margin: .15rem auto .5rem; padding: 0;
  background: none; border: 0; font-size: .78rem; letter-spacing: .01em;
  color: inherit; opacity: .65; cursor: pointer; text-align: center;
  text-decoration: underline; text-underline-offset: .2em;
}
#cura-dash .cd-lb-match:hover { opacity: 1; background: none; }

/* ---------------------------------------------------------------- *
 * Sections — the five pages the club's menu points at
 * ---------------------------------------------------------------- */
#cura-dash .cd-sections {
  display: flex; flex-wrap: wrap; gap: .3rem;
  border-bottom: 2px solid var(--line); margin-bottom: 1.4rem;
}
#cura-dash .cd-section {
  padding: .55rem .95rem; font-size: .84rem; font-weight: 600;
  letter-spacing: .02em; text-decoration: none; color: var(--ink-soft);
  border-bottom: 3px solid transparent; margin-bottom: -2px;
  transition: color .15s, border-color .15s;
}
#cura-dash .cd-section:hover { color: var(--cam-deep); }
#cura-dash .cd-section.cd-on {
  color: var(--cam-deep); border-bottom-color: var(--cam-dark);
}

/* Match the main site's reading column: generous enough for an archive
   introduction without stretching prose across the full results grid. */
#cura-dash .cd-intro { max-width: 880px; margin: 0 0 2.2rem; }
#cura-dash .cd-intro-title {
  font-family: var(--serif); font-size: clamp(2.35rem, 4vw, 3rem); font-weight: 700;
  color: var(--cam-deep); margin: 0 0 .75rem; line-height: 1.12;
}
#cura-dash .cd-intro-p { margin: 0 0 .7rem; line-height: 1.65; }
#cura-dash .cd-intro-lead { font-size: 1.05rem; }

/* Blues, captains and trophies */
#cura-dash .cd-chips { display: flex; flex-wrap: wrap; gap: .35rem; margin-top: .5rem; }
#cura-dash .cd-chip-sub { display: block; font-size: .68rem; opacity: .65; }
/* ==========================================================================
   Origins — the club's story as a rail of years
   ========================================================================== */
#cura-dash .cd-story {
  position: relative; margin: .6rem 0 2.4rem; padding-left: 1.1rem;
}
/* The rail itself, drawn once behind everything. */
#cura-dash .cd-story::before {
  content: ""; position: absolute; left: 0; top: .4rem; bottom: .4rem;
  width: 2px; background: linear-gradient(var(--paper-3), var(--cam),
                                          var(--cam-dark));
  border-radius: 2px;
}
#cura-dash .cd-story-era {
  display: flex; align-items: baseline; gap: .6rem; margin: 1.6rem 0 .6rem;
  padding-left: 1.4rem;
}
#cura-dash .cd-story-era:first-child { margin-top: .2rem; }
#cura-dash .cd-story-era-label {
  font-family: var(--serif); font-size: 1.15rem; color: var(--cam-deep);
}
#cura-dash .cd-story-era-span {
  font-size: .74rem; color: var(--ink-faint); font-variant-numeric: tabular-nums;
}

#cura-dash .cd-story-item {
  position: relative; display: grid;
  grid-template-columns: 5.4rem minmax(0, 1fr); gap: 1rem;
  padding: .7rem 0 .7rem 1.4rem;
}
/* The dot where this year meets the rail. */
#cura-dash .cd-story-item::before {
  content: ""; position: absolute; left: -5px; top: 1.15rem;
  width: 12px; height: 12px; border-radius: 50%;
  background: #fff; border: 2px solid var(--cam-dark);
  transition: transform .5s var(--ease), background .5s var(--ease);
}
#cura-dash .cd-story-item[data-reveal]:not(.cd-in)::before { transform: scale(.3); }
#cura-dash .cd-story-item.cd-in::before { background: var(--cam-wash); }
#cura-dash .cd-story-aside::before { border-color: var(--paper-3); }
#cura-dash .cd-story-aside .cd-story-body { opacity: .8; }

#cura-dash .cd-story-when { text-align: right; padding-top: .1rem; }
#cura-dash .cd-story-year {
  display: block; font-family: var(--serif); font-size: 1.35rem;
  color: var(--cam-deep); font-variant-numeric: tabular-nums; line-height: 1.1;
}
#cura-dash .cd-story-date {
  display: block; font-size: .68rem; color: var(--ink-faint); margin-top: .1rem;
}
#cura-dash .cd-story-title {
  margin: 0 0 .2rem; font-family: var(--serif); font-size: 1.05rem;
  color: var(--ink);
}
#cura-dash .cd-story-text {
  margin: 0; font-size: .92rem; max-width: 60ch; color: var(--ink-soft);
}
#cura-dash .cd-story-links {
  display: flex; flex-wrap: wrap; gap: .3rem .9rem; margin-top: .4rem;
}
/* A link inside a sentence reads at the size of the sentence. */
#cura-dash .cd-story-link {
  font-size: inherit; color: var(--cam-deep); text-decoration: underline;
  text-decoration-color: var(--cam); text-underline-offset: 3px;
  cursor: pointer;
}
#cura-dash .cd-story-link:hover { text-decoration-color: currentColor; }
@media (max-width: 640px) {
  #cura-dash .cd-story-item { grid-template-columns: 1fr; gap: .1rem; }
  #cura-dash .cd-story-when { text-align: left; }
  #cura-dash .cd-story-year { font-size: 1.15rem; }
}

/* Notable members. */
#cura-dash .cd-notable { margin: 1.6rem 0 1rem; }
#cura-dash .cd-notable-title {
  font-family: var(--serif); font-size: 1.3rem; margin: 0 0 .2rem;
  color: var(--cam-deep);
}
#cura-dash .cd-notable-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: .7rem;
}
#cura-dash .cd-notable-card {
  display: flex; flex-direction: column; align-items: flex-start;
  text-align: left; background: #fff; border: 1px solid var(--line);
  border-left: 3px solid var(--cam); border-radius: 3px; padding: .6rem .75rem;
  transition: transform .3s var(--ease), box-shadow .3s var(--ease);
}
#cura-dash button.cd-notable-card { cursor: pointer; }
#cura-dash button.cd-notable-card:hover {
  transform: translateY(-3px); box-shadow: var(--shadow-1);
}
#cura-dash .cd-notable-flat { border-left-color: var(--paper-3); cursor: default; }
#cura-dash .cd-notable-name {
  font-family: var(--serif); font-size: 1.02rem; color: var(--ink);
}
#cura-dash .cd-notable-as { font-size: .68rem; color: var(--ink-faint); }
#cura-dash .cd-notable-note {
  font-size: .78rem; color: var(--ink-soft); margin-top: .2rem;
}

/* ==========================================================================
   Other matches
   ========================================================================== */
#cura-dash .cd-other {
  padding: 1.1rem 0; border-top: 1px solid var(--line);
}
#cura-dash .cd-other:first-child { border-top: 0; padding-top: .4rem; }
#cura-dash .cd-other-head {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: .3rem .8rem;
}
#cura-dash .cd-other-name {
  margin: 0; font-family: var(--serif); font-size: 1.2rem; color: var(--cam-deep);
}
#cura-dash .cd-other-facts { font-size: .76rem; color: var(--ink-faint); }
#cura-dash .cd-other-status {
  font-size: .62rem; letter-spacing: .08em; text-transform: uppercase;
  font-weight: 700; padding: .12rem .45rem; border-radius: 100px;
  background: var(--cam-wash); color: var(--cam-deep);
}
#cura-dash .cd-other-occasional { background: var(--paper-2); color: var(--ink-soft); }
#cura-dash .cd-other-discontinued {
  background: transparent; color: var(--ink-faint);
  box-shadow: inset 0 0 0 1px var(--line);
}
#cura-dash .cd-other-aka {
  font-size: .78rem; color: var(--ink-faint); margin: .3rem 0 0; font-style: italic;
}
#cura-dash .cd-other-text { font-size: .92rem; max-width: 62ch; margin: .5rem 0 0; }
#cura-dash .cd-other-foot {
  margin-top: 1.4rem; padding-top: .8rem; border-top: 1px solid var(--line);
  font-size: .8rem; color: var(--ink-faint); max-width: 62ch;
}

/* Team scores over time. Drawn at a fixed aspect so the marks stay round. */
#cura-dash .cd-trend { margin: .2rem 0 1.6rem; }
#cura-dash .cd-trend-head { margin-bottom: .4rem; }
#cura-dash .cd-trend-head h4 {
  margin: 0 0 .4rem; font-family: var(--serif); font-size: 1.05rem;
}
#cura-dash .cd-trend-controls { margin-bottom: .3rem; }
#cura-dash .cd-trend-svg { width: 100%; height: auto; display: block; }
#cura-dash .cd-trend-grid { stroke: var(--line); stroke-width: 1;
  shape-rendering: crispEdges; }
#cura-dash .cd-trend-tick { font-size: 9px; fill: var(--ink-faint);
  font-variant-numeric: tabular-nums; }
#cura-dash .cd-trend-path { fill: none; stroke-width: 1.7;
  stroke-linejoin: round; stroke-linecap: round; }
#cura-dash .cd-trend-path.cd-trend-cam { stroke: var(--cam-dark); }
#cura-dash .cd-trend-path.cd-trend-ox { stroke: var(--ox-light); }
#cura-dash .cd-trend-dot.cd-trend-cam { fill: var(--cam-dark); opacity: .7; }
#cura-dash .cd-trend-dot.cd-trend-ox { fill: var(--ox-light); opacity: .7; }
/* The spread between the best and the worst of the day. */
#cura-dash .cd-trend-band { stroke: none; }
#cura-dash .cd-trend-band.cd-trend-cam { fill: var(--cam); opacity: .16; }
#cura-dash .cd-trend-band.cd-trend-ox { fill: var(--ox-light); opacity: .12; }
/* An invisible target over each year, wide enough to hit. */
#cura-dash .cd-trend-hit { fill: transparent; cursor: pointer; }
#cura-dash .cd-trend-hit:hover { fill: rgba(51, 56, 54, .10); }
#cura-dash .cd-trend-hit:focus { outline: none; fill: rgba(51, 56, 54, .16); }
#cura-dash .cd-trend-note { font-size: .72rem; color: var(--ink-faint);
  margin: .35rem 0 0; }

/* An introduction that has to carry rules as well as prose. */
#cura-dash .cd-intro-h {
  font-family: var(--serif); font-size: 1.02rem; margin: 1.1rem 0 .2rem;
  color: var(--cam-deep);
}
#cura-dash .cd-intro-list {
  margin: .2rem 0 .7rem; padding-left: 1.2rem; max-width: 46rem;
  font-size: .92rem; color: var(--ink-soft);
}
#cura-dash .cd-intro-list li { margin: .18rem 0; }
#cura-dash .cd-intro-list .cd-intro-list { margin: .2rem 0 .1rem; }
/* Rules that have been superseded are worth keeping and not worth leading
   with, so they fold away. */
#cura-dash .cd-intro-fold {
  margin: .5rem 0 .3rem; border-top: 1px solid var(--line);
  padding-top: .5rem; max-width: 46rem;
}
#cura-dash .cd-intro-fold > summary {
  cursor: pointer; font-size: .8rem; letter-spacing: .04em;
  text-transform: uppercase; font-weight: 600; color: var(--ink-faint);
  list-style: none;
}
#cura-dash .cd-intro-fold > summary::-webkit-details-marker { display: none; }
#cura-dash .cd-intro-fold > summary::before {
  content: "▸ "; display: inline-block; transition: transform .2s var(--ease);
}
#cura-dash .cd-intro-fold[open] > summary::before { content: "▾ "; }
#cura-dash .cd-intro-fold > summary:hover { color: var(--cam-dark); }
#cura-dash .cd-intro-fold .cd-intro-p,
#cura-dash .cd-intro-fold .cd-intro-list { font-size: .86rem; }

/* A roll of years — Full Blues, captains. Cards, not a two-column table:
   the table left nine tenths of the page empty and ran on for a mile. */
#cura-dash .cd-roll {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(178px, 1fr));
  gap: .6rem; margin: .4rem 0 1rem;
}
#cura-dash .cd-roll-item {
  display: flex; flex-direction: column; align-items: stretch; text-align: left;
  background: #fff; border: 1px solid var(--line); border-radius: 3px;
  overflow: hidden; padding: 0;
  transition: transform .3s var(--ease), box-shadow .3s var(--ease);
}
#cura-dash button.cd-roll-item { cursor: pointer; }
#cura-dash button.cd-roll-item:hover {
  transform: translateY(-3px); box-shadow: var(--shadow-1);
}
#cura-dash .cd-roll-flat { cursor: default; }
#cura-dash .cd-roll-year {
  font-family: var(--serif); font-size: .98rem; letter-spacing: .04em;
  padding: .22rem .6rem; color: #fff; background: var(--cam-dark);
  font-variant-numeric: tabular-nums;
}
/* A Full Blue is the club's own award; a captaincy taken from a match team
   rather than from the club's list is a weaker claim and looks it. */
/* A Full Blue wears Cambridge Blue, the same shade as its badge. */
#cura-dash .cd-roll-full .cd-roll-year {
  background: var(--blue-full); color: var(--cam-deep);
}
#cura-dash .cd-roll-match .cd-roll-year {
  background: var(--paper-2); color: var(--ink-soft);
}
#cura-dash .cd-roll-body { padding: .45rem .6rem .55rem; }
#cura-dash .cd-roll-name {
  display: block; font-family: var(--serif); font-size: 1.02rem;
  line-height: 1.25; color: var(--ink);
}
#cura-dash .cd-roll-sub {
  display: block; font-size: .73rem; color: var(--ink-soft); margin-top: .1rem;
}
#cura-dash .cd-roll-note {
  display: block; font-size: .68rem; color: var(--ink-faint); margin-top: .25rem;
  font-style: italic;
}
#cura-dash .cd-roll-full .cd-roll-note { color: var(--gold); font-style: normal; }

#cura-dash .cd-captains-scroll { max-height: 30rem; overflow-y: auto; }
#cura-dash .cd-captains { width: 100%; border-collapse: collapse; }
#cura-dash .cd-captains th.cd-captains-year {
  text-align: right; padding: .4rem .7rem .4rem 0; vertical-align: top;
  font-variant-numeric: tabular-nums; color: var(--ink-soft); font-weight: 600;
  white-space: nowrap; width: 1%;
}
#cura-dash .cd-captains td { padding: .25rem 0; }
#cura-dash .cd-captains tr + tr { border-top: 1px solid var(--line); }

/* Trophies come in two kinds — shot for against Oxford, and shot for within
   the club — and the page says so rather than running them together. */
#cura-dash .cd-trophy-group { margin-bottom: 2rem; }
#cura-dash .cd-trophy-group-title {
  font-family: var(--serif); font-size: 1.3rem; margin: .2rem 0 .3rem;
  color: var(--cam-deep);
}
#cura-dash .cd-trophy {
  display: grid; grid-template-columns: minmax(0, 18rem) 1fr; gap: 1.4rem;
  padding: 1.2rem 0; border-top: 1px solid var(--line); align-items: start;
}
#cura-dash .cd-trophy:first-child { border-top: 0; }
/* Arrived here from somebody's profile: say which one was meant. */
#cura-dash .cd-trophy-lit {
  animation: cd-trophy-lit 2.2s var(--ease);
}
@keyframes cd-trophy-lit {
  0%, 60% { background: var(--cam-wash); }
  100% { background: transparent; }
}
#cura-dash .cd-trophy-shot img { width: 100%; height: auto; border-radius: 4px; }
/* An empty frame asks for a photograph; nothing at all asks for nothing. */
#cura-dash .cd-trophy-empty {
  display: flex; align-items: center; justify-content: center;
  min-height: 7rem; border: 1px dashed var(--paper-3); border-radius: 4px;
  background: var(--paper);
}
#cura-dash .cd-trophy-wanted {
  font-size: .7rem; letter-spacing: .08em; text-transform: uppercase;
  color: var(--ink-faint);
}
#cura-dash .cd-trophy-disc {
  margin-left: .5rem; font-family: var(--sans); font-size: .62rem;
  letter-spacing: .08em; font-weight: 700; padding: .12rem .4rem;
  border-radius: 3px; background: var(--paper-2); color: var(--ink-soft);
  vertical-align: .18em; cursor: help;
}
#cura-dash .cd-trophy-crit {
  font-size: .88rem; color: var(--ink); margin: .1rem 0 .4rem;
}
#cura-dash .cd-trophy-derived, #cura-dash .cd-trophy-none {
  font-size: .74rem; color: var(--ink-faint); margin: .3rem 0 .2rem;
}
#cura-dash .cd-trophy-scroll {
  max-height: 15rem; overflow-y: auto; overscroll-behavior: contain;
  border-top: 1px solid var(--line); margin-top: .4rem;
}
#cura-dash .cd-trophy-score {
  margin-left: .5rem; font-family: var(--serif); color: var(--cam-deep);
  font-variant-numeric: tabular-nums;
}
#cura-dash .cd-trophy-name {
  font-family: var(--serif); font-size: 1.3rem; color: var(--cam-deep);
  margin: 0 0 .2rem;
}
#cura-dash .cd-trophy-given { font-size: .8rem; opacity: .7; margin: 0 0 .6rem; }
#cura-dash .cd-trophy-text { margin: 0 0 .7rem; line-height: 1.6; max-width: 60ch; }
#cura-dash .cd-trophy-tally { font-size: .82rem; font-weight: 600; margin: 0; }
#cura-dash .cd-trophy-awards { list-style: none; padding: 0; margin: .5rem 0 0; }
#cura-dash .cd-trophy-awards li { display: flex; gap: .6rem; padding: .2rem 0; }
#cura-dash .cd-trophy-year { font-variant-numeric: tabular-nums; opacity: .7; }
#cura-dash .cd-trophy-note { opacity: .6; font-size: .8rem; }
@media (max-width: 640px) {
  #cura-dash .cd-trophy { grid-template-columns: 1fr; }
}
#cura-dash .cd-blue-note { display: block; font-size: .75rem; opacity: .7;
  margin-top: .15rem; font-style: italic; }

/* A link worth sending. */
#cura-dash .cd-person-head { display: flex; align-items: baseline; gap: .8rem;
  flex-wrap: wrap; }
#cura-dash .cd-share { font-size: .72rem; padding: .25rem .6rem; border-radius: 100px;
  background: var(--paper-2); color: var(--ink-soft); cursor: pointer;
  border: 1px solid var(--line); }
#cura-dash .cd-share:hover { background: var(--cam-wash); color: var(--cam-deep); }

/* Years there is a photograph of. */
#cura-dash .cd-tl-shot { fill: var(--cam-dark); opacity: .45; pointer-events: none; }
#cura-dash .cd-tl-col:hover .cd-tl-shot,
#cura-dash .cd-tl-col.cd-sel .cd-tl-shot { opacity: .95; }

/* A career at a glance. */
/* A career on a line, with each year's plaque hanging beneath its own score.
   --hang-col must match HANG.col in the script: the chart is drawn in real
   pixels at that spacing, and the plaques are laid out to the same measure. */
#cura-dash .cd-hang { --hang-col: 108px; margin: .4rem 0 .2rem; }
#cura-dash .cd-hang-scroll { overflow-x: auto; overflow-y: hidden;
  padding: 0 1rem .2rem; }
#cura-dash .cd-hang-inner { position: relative; }
#cura-dash .cd-hang-svg { display: block; }

#cura-dash .cd-hang-grid { stroke: var(--line); stroke-width: 1;
  shape-rendering: crispEdges; }
#cura-dash .cd-hang-tick { font-size: 9px; fill: var(--ink-faint);
  font-variant-numeric: tabular-nums; }
#cura-dash .cd-hang-path { fill: none; stroke: var(--cam-dark);
  stroke-width: 1.8; stroke-linejoin: round; stroke-linecap: round; }
/* The string from the score down to the plaque it belongs to. */
#cura-dash .cd-hang-string { stroke: var(--line); stroke-width: 1;
  stroke-dasharray: 2 3; }
#cura-dash .cd-hang-dot { fill: var(--cam-dark); }
#cura-dash .cd-hang-dot-top { fill: var(--gold);
  stroke: #fff; stroke-width: 1.2; }
#cura-dash .cd-hang-row { display: flex; align-items: flex-start; }
#cura-dash .cd-hang-row .cd-ybox { width: calc(var(--hang-col) - 10px);
  flex: 0 0 calc(var(--hang-col) - 10px); margin: 0 5px; }
#cura-dash .cd-hang-note { font-size: .7rem; opacity: .6;
  margin: .35rem 0 0; padding: 0 1rem; }

/* Coverage, year by year: ten years to a row, a bar per competition, so the
   decades that are covered and the decades that are not can be seen rather
   than counted. */
#cura-dash .cd-cover { margin: .2rem 0 1.4rem; }
#cura-dash .cd-cover-head {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: .6rem 1.2rem;
  margin-bottom: .3rem;
}
#cura-dash .cd-cover-head h4 { margin: 0; font-family: var(--serif);
  font-size: 1.05rem; }
#cura-dash .cd-cover-key { display: flex; flex-wrap: wrap; gap: .1rem .9rem;
  font-size: .72rem; color: var(--ink-soft); }
#cura-dash .cd-cover-key-item { display: inline-flex; align-items: center;
  gap: .3rem; }
#cura-dash .cd-cover-swatch { width: .7rem; height: .7rem; border-radius: 2px;
  display: inline-block; }
#cura-dash .cd-cover-legend { display: flex; flex-wrap: wrap; gap: .1rem .9rem;
  font-size: .72rem; color: var(--ink-soft); margin: 0 0 .5rem; }
#cura-dash .cd-cover-legend-item { display: inline-flex; align-items: center;
  gap: .3rem; }
#cura-dash .cd-cover-legend-bar { width: 1.1rem; height: .45rem;
  border-radius: 1px; display: inline-block; background: var(--cam-deep); }

#cura-dash .cd-cover-scroll { max-height: 24rem; overflow-y: auto;
  overflow-x: auto; overscroll-behavior: contain; padding: .2rem 0; }
#cura-dash .cd-cover-rows { display: flex; flex-direction: column; gap: .28rem;
  min-width: max-content; }
#cura-dash .cd-cover-row { display: flex; align-items: center; gap: .5rem; }
#cura-dash .cd-cover-decade {
  width: 3.2rem; flex: none; text-align: right; font-size: .74rem;
  color: var(--ink-faint); font-variant-numeric: tabular-nums;
}
#cura-dash .cd-cover-cells { display: flex; gap: .22rem; }
#cura-dash .cd-cover-cell {
  width: 2.9rem; flex: none; display: flex; flex-direction: column; gap: .12rem;
}
#cura-dash .cd-cover-year {
  font-size: .58rem; color: var(--ink-faint); letter-spacing: .02em;
  font-variant-numeric: tabular-nums; text-align: center; line-height: 1;
}
#cura-dash .cd-cover-bar {
  display: block; height: .5rem; border-radius: 1px; padding: 0;
  border: 0; width: 100%;
}
#cura-dash button.cd-cover-bar { cursor: pointer; }
#cura-dash button.cd-cover-bar:hover { outline: 1px solid var(--cam-deep);
  outline-offset: 1px; }
/* A photograph is held; the archive has it. */
#cura-dash .cd-cover-held, #cura-dash .cd-cover-swatch.cd-cover-held {
  background: var(--cam-dark);
}
/* Fired, but nobody has found a photograph of it. */
#cura-dash .cd-cover-gap, #cura-dash .cd-cover-swatch.cd-cover-gap {
  background: var(--paper-3);
}
/* Not fired at all — the wars, and the Humphry's lapse. Hatched, so it can
   never be mistaken for something the archive is missing. */
#cura-dash .cd-cover-off, #cura-dash .cd-cover-swatch.cd-cover-off {
  background: repeating-linear-gradient(45deg,
    transparent 0 3px, rgba(51, 56, 54, .18) 3px 4px);
  box-shadow: inset 0 0 0 1px var(--line);
}
/* Before the fixture began: nothing to say. */
#cura-dash .cd-cover-none { background: transparent; }
#cura-dash .cd-cover-empty { visibility: hidden; }

/* The team sheets, as a ramp from what survives whole to what does not:
   names with scores, names alone, a team total with nobody named, nothing.
   Cambridge's charts are in the club's own colour, Oxford's in theirs. */
#cura-dash .cd-cover-full { background: var(--cam-deep); }
#cura-dash .cd-cover-names { background: var(--cam); }
#cura-dash .cd-cover-scores { background: var(--cam-wash);
  box-shadow: inset 0 0 0 1px var(--line); }
#cura-dash .cd-cover-nothing { background: var(--paper-2);
  box-shadow: inset 0 0 0 1px var(--line); }
#cura-dash .cd-tone-ox .cd-cover-full { background: var(--ox); }
#cura-dash .cd-tone-ox .cd-cover-names { background: var(--ox-light); }
#cura-dash .cd-tone-ox .cd-cover-scores { background: var(--ox-wash); }
#cura-dash .cd-tone-ox button.cd-cover-bar:hover { outline-color: var(--ox); }
#cura-dash .cd-cover-note { font-size: .75rem; color: var(--ink-soft);
  margin: .5rem 0 0; max-width: 46rem; }

/* What is missing. */
#cura-dash .cd-gap-scroll { max-height: 13rem; overflow-y: auto;
  overscroll-behavior: contain; }
#cura-dash .cd-gap-card .cd-rank-count { float: right; font-variant-numeric: tabular-nums;
  font-size: 1.1rem; font-weight: 700; color: var(--cam-deep); }
#cura-dash .cd-gap-note { font-size: .75rem; opacity: .65; margin: .1rem 0 .4rem; }
#cura-dash .cd-gap-none { font-size: .8rem; color: var(--cam-dark); margin: .2rem 0 0; }

/* A profile arriving: the panel settles, then its parts follow. */
#cura-dash .cd-person-detail { animation: cd-rise .45s var(--ease) backwards; }
#cura-dash .cd-person-detail .cd-comp-section { animation: cd-rise .45s var(--ease) backwards; }
#cura-dash .cd-person-detail .cd-comp-section:nth-child(2) { animation-delay: .06s; }
#cura-dash .cd-person-detail .cd-comp-section:nth-child(3) { animation-delay: .12s; }
#cura-dash .cd-person-detail .cd-ybox { animation: cd-rise .4s var(--ease) backwards; }

/* The photographs a man appears in, shown smaller than the full album. */
#cura-dash .cd-gallery-tight {
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: .5rem;
}

/* Honours. */
#cura-dash .cd-honours { margin: .6rem 0 .2rem; display: flex;
  flex-direction: column; gap: .3rem; }
#cura-dash .cd-honour-line { display: flex; align-items: baseline; gap: .5rem;
  font-size: .85rem; }
#cura-dash .cd-honour-badge { font-size: .68rem; text-transform: uppercase;
  letter-spacing: .07em; font-weight: 700; padding: .15rem .5rem;
  border-radius: 100px; background: var(--cam-deep); color: #fff;
  white-space: nowrap; }
/* The awards wear their own colours. A Full Blue is Cambridge Blue, solid.
   A Half Blue is the striped version of it — Cambridge Blue on off-white,
   which is how the half blue is worn. */
#cura-dash .cd-honour-full {
  background: var(--blue-full); color: var(--cam-deep);
  box-shadow: inset 0 0 0 1px rgba(47, 74, 60, .18);
}
#cura-dash .cd-honour-half {
  background: repeating-linear-gradient(45deg,
    var(--blue-half-off) 0 5px, var(--blue-full) 5px 10px);
  color: var(--cam-deep);
  box-shadow: inset 0 0 0 1px rgba(47, 74, 60, .18);
  /* The label has to stay readable across the stripes. */
  text-shadow: 0 0 3px var(--blue-half-off), 0 0 6px var(--blue-half-off);
}
#cura-dash .cd-honour-top { background: #6b5b2a; }
#cura-dash .cd-honour-cup { background: var(--cam-dark); }
/* An award recorded by hand, because nothing in the results implies it. */
#cura-dash .cd-honour-won { background: var(--cam-deep); }
#cura-dash .cd-honour-note { font-size: .72rem; opacity: .6; margin: 0; }

/* Earned more than once: the count leads, the years follow, and each one is
   then set out below so the claim can be checked. */
#cura-dash .cd-honour-count { font-weight: 700; font-size: .82rem; }
#cura-dash .cd-honour-span { font-size: .78rem; opacity: .65; }
#cura-dash .cd-honour-detail { font-size: .8rem; opacity: .85;
  padding-left: .3rem; margin-left: .55rem;
  border-left: 2px solid rgba(0, 0, 0, .12); }
#cura-dash .cd-honour-detail + .cd-honour-detail { margin-top: -.1rem; }
#cura-dash .cd-honour-link { color: inherit; text-decoration: underline;
  text-decoration-color: rgba(0, 0, 0, .25); text-underline-offset: 2px; }
#cura-dash .cd-honour-link:hover { text-decoration-color: currentColor; }

/* The marks beside a name in a team list. */
#cura-dash .cd-honour { margin-left: .2rem; color: var(--cam-dark);
  font-weight: 700; letter-spacing: -.05em; }
/* A Gold Medallist should catch the eye — there are three in the archive. */
#cura-dash .cd-gm { margin-left: .3rem; font-size: .66rem; font-weight: 800;
  letter-spacing: .06em; padding: .05rem .3rem; border-radius: 3px;
  background: #b8912f; color: #fff; vertical-align: .08em; }
#cura-dash .cd-honour-gm .cd-gm { margin-left: 0; }

/* ==========================================================================
   The banner

   Reproduces the Spectra (UAGB) container that used to sit at the head of each
   of the eleven pages, so that moving to one page changes nothing a reader can
   see. Its settings, taken from the block itself:

       background image   cover, positioned 49% across and 45% down
       background colour  #1d1e1e, seen only before the photograph paints
       overlay            black at 15%
       padding            230px top and bottom; 100px on tablet and phone
       heading            centred h1, var(--ast-global-color-5)

   FULL BLEED. The dashboard sits inside a WordPress container with a maximum
   width, and the banner has to escape it. `width: 100vw` with a negative
   margin of half the difference does that from wherever it happens to be,
   without needing the block itself to be full-width. The one cost is that
   100vw counts the vertical scrollbar, so a page long enough to scroll gains
   a few pixels of horizontal overflow — which the overflow-x rule below eats.
   ========================================================================== */

#cura-dash .cd-banner {
  position: relative;

  /* Escaping the container. Negative margins on both sides with an automatic
     width, rather than `width: 100vw` and one negative margin: the two come out
     the same size, but this version is measured from the parent's content box
     outwards, so it survives being put inside a flex or grid parent, which
     100vw does not.

     Nothing above this element may clip. There WAS an `overflow-x: clip` on
     #cura-dash here, added to swallow the sliver of horizontal scroll that a
     100vw child can cause — and a clipping ancestor clips exactly the overflow
     the banner depends on, so the banner came out the width of the text column
     instead. The scrollbar sliver is the lesser evil, and `max-width` below
     keeps it to nothing on all but the widest windows. */
  width: auto;
  max-width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  margin-bottom: 2.2rem;

  /* The Spectra container this replaces was 230px of padding, then a 30px
     spacer, then the heading — so the title's top edge sat 260px down, not
     halfway. Centring it instead moved it 15px up, which on a site whose
     header overlays the top of the page was enough to slide it under the menu.
     Reproduced literally, and laid out as a block rather than centred, so it
     cannot drift again. */
  /* 280 above and 230 below. On /membership/ the Spectra container is 230px of
     padding, then a 30px spacer, then a heading whose box starts 280px from the
     top of the strip; 280 + a 90px line + 230 is the 600px that page measures.
     Reproduced as two numbers rather than three, because a padding and a spacer
     that always move together are one measurement wearing a disguise. */
  padding: calc(280px + var(--cd-banner-extra, 0px)) 1.2rem 230px;
  box-sizing: border-box;

  background-color: #1d1e1e;
  background-repeat: no-repeat;
  background-size: cover;
  background-position: 50% 47%;

  /* The image arrives when it arrives; a fade means the reader sees it
     appear rather than sees the dark rectangle blink. */
  animation: cd-banner-in 0.45s ease both;
}

/* The 15% wash. A pseudo-element rather than a gradient on the background, so
   that the photograph and the overlay do not have to be redeclared together
   every time the section changes. */
#cura-dash .cd-banner::after {
  content: ""; position: absolute; inset: 0;
  background: rgba(0, 0, 0, 0.15);
  pointer-events: none;
}

#cura-dash .cd-banner-plain { background-image: none; }

/* The site's own heading, to the property. Read off /membership/:
   Playfair Display, 64px, weight 700, line-height 89.6px (= 1.4), white,
   centred, uppercase, no margin. The uppercase is the site's, not an
   embellishment — every other page banner is set that way. */
#cura-dash .cd-banner-title {
  position: relative; z-index: 1;
  margin: 0; text-align: center;
  font-family: var(--serif);
  font-size: clamp(2.1rem, 6.4vw, 64px);
  font-weight: 700;
  line-height: 1.4;
  letter-spacing: normal;
  text-transform: uppercase;

  /* The theme's own palette where it exists, white where it does not — the
     dashboard is meant to survive being lifted out of this site. */
  color: var(--ast-global-color-5, #ffffff);
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.45);
}

@keyframes cd-banner-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* The block's own tablet and mobile figures — 100px of padding — with the same
   30px spacer folded into the top, and the heading left to the clamp above. */
@media (max-width: 921px) {
  #cura-dash .cd-banner {
    padding: calc(140px + var(--cd-banner-extra, 0px)) 1.2rem 100px;
  }
}

@media (prefers-reduced-motion: reduce) {
  #cura-dash .cd-banner { animation: none; }
}
