@font-face {
  font-family: "VIC";
  src: url("/fonts/VIC-Regular.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "VIC";
  src: url("/fonts/VIC-SemiBold.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
}
@font-face {
  font-family: "VIC";
  src: url("/fonts/VIC-Bold.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
}
:root {
  color-scheme: light;
  --bg: #dfe3e8;
  --deep: var(--bg);
  --panel: #f6f7f9;
  --surface: #eef0f3;
  --line: #d2d6dc;
  --quiet-line: #e4e7eb;
  --chalk: #15181c;
  --muted: #5b6470;
  --font: "VIC", Roboto, Arial, sans-serif;
}
* { box-sizing: border-box; }
[data-team="1"] { --team-color: #ff0000; }
[data-team="2"] { --team-color: #08b855; }
[data-team="3"] { --team-color: #0050f4; }
[data-team="4"] { --team-color: #ffffff; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--bg); color: var(--chalk); font: 1rem/1.45 var(--font); }
button, input, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .5; }
:focus-visible { outline: 2px solid var(--chalk); outline-offset: 3px; }
::selection { background: var(--chalk); color: var(--deep); }
.shell { width: min(100% - 72px, 1460px); margin-inline: auto; }
.skip { position: fixed; z-index: 5; top: 10px; left: 10px; padding: 8px 12px; background: var(--chalk); color: var(--deep); transform: translateY(-150%); }
.skip:focus { transform: none; }
.site-header { border-bottom: 1px solid var(--quiet-line); background: var(--deep); }
.masthead { min-height: 70px; display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); gap: 0 24px; align-items: center; }
.masthead nav { grid-column: 2; grid-row: 1; display: flex; height: 100%; gap: 25px; }
.masthead nav a { position: relative; display: grid; place-items: center; min-height: 49px; color: var(--muted); white-space: nowrap; padding-inline: 1px; font-size: .92rem; font-weight: 600; text-decoration: none; }
.masthead nav a:hover, .masthead nav a[aria-current="page"] { color: var(--chalk); }
.masthead nav a[aria-current="page"]::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--chalk); }
.header-actions { grid-column: 3; grid-row: 1; justify-self: end; display: flex; align-items: center; gap: 15px; }
.connection { white-space: nowrap; color: var(--muted); font-size: .78rem; }
.connection.offline { border-left: 3px solid var(--chalk); padding-left: 7px; color: var(--chalk); }
.board .masthead { min-height: 60px; padding-top: 0; }
.board .site-header { display: none; }
.board .masthead nav, .board .connection:not(.offline, .demo), .board .site-footer { display: none; }
.connection.demo { padding: 4px 8px; border: 1px solid var(--line); }
.board .main { padding-top: 18px; }
.main { padding-block: 28px 22px; }
.page-heading { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
h1, h2, p { margin: 0; }
h1 { font: 700 clamp(2rem, 2.8vw, 3rem)/1 var(--font); letter-spacing: -.025em; }
h2 { font: 600 1.35rem/1.2 var(--font); letter-spacing: -.012em; }
.mono { font-variant-numeric: tabular-nums; }
.eyebrow { font: 600 .8rem/1.2 var(--font); }
.chip { display: inline-flex; align-items: center; width: fit-content; padding: 5px 8px; min-height: 25px; background: var(--surface); color: var(--chalk); font: 600 .78rem/1.1 var(--font); white-space: nowrap; }
.eyebrow, .chip { letter-spacing: .08em; text-transform: uppercase; }
.chip.signal { background: var(--chalk); color: var(--deep); }
.heading-actions, .dialog-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.button { border: 1px solid transparent; min-height: 42px; padding: 8px 13px; font-weight: 600; font-size: .9rem; line-height: 1.2; text-align: center; }
.button.primary { background: var(--chalk); color: var(--deep); }
.button.primary:hover:not(:disabled) { background: #e6e6e6; }
.button.subtle { border-color: var(--line); background: var(--panel); color: var(--chalk); }
.button.subtle:hover:not(:disabled) { background: var(--surface); }
.hero { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 18px; min-height: 145px; padding: 19px 23px 20px 25px; border: 1px solid var(--line); border-left: 3px solid var(--chalk); background: var(--deep); }
.hero h2 { font: 700 clamp(2.7rem, 5.5vw, 4.5rem)/.94 var(--font); letter-spacing: -.034em; margin-top: 11px; }
.board-turn { position: relative; overflow: hidden; min-height: 117px; align-items: center; justify-content: center; padding-inline: 23px; margin-bottom: 16px; text-align: center; }
.board-turn-content { width: 100%; min-width: 0; }
.board-turn h1 { font-size: clamp(2.1rem, 4.2vw, 3.45rem); letter-spacing: -.032em; overflow-wrap: anywhere; }
.board-turn .chip + h1 { margin-top: 7px; }
.board-turn-previous {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: inherit;
  background: var(--deep);
  color: var(--chalk);
  pointer-events: none;
  animation: board-background-wipe var(--board-wipe-duration) cubic-bezier(.65, 0, .35, 1) both;
}
:is(.board-turn, .board-turn-previous).is-pick {
  background: var(--chalk);
  color: var(--deep);
}
:is(.board-turn, .board-turn-previous).is-pick .chip {
  background: var(--deep);
  color: var(--chalk);
}
@keyframes board-background-wipe {
  from { clip-path: polygon(0 0, 100% 0, 100% 100%, -2.5rem 100%); }
  to { clip-path: polygon(calc(100% + 2.5rem) 0, 100% 0, 100% 100%, 100% 100%); visibility: hidden; }
}
@media (prefers-reduced-motion: reduce) {
  .board-turn-previous { display: none; }
}
.hero-stats { display: flex; gap: 8px; }
.hero-stat { min-width: 108px; padding: 9px 12px; border: 1px solid var(--line); background: var(--panel); }
.hero-stat span { display: block; color: var(--muted); font-weight: 600; }
.hero-stat strong { display: block; margin-top: 3px; font: 700 1.28rem/1.25 var(--font); font-variant-numeric: tabular-nums; white-space: nowrap; }
.ticker { min-height: 40px; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 20px; padding: 6px 1px 0; }
.ticker-item { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 10px; color: var(--chalk); font-size: .88rem; }
.ticker .eyebrow { color: var(--muted); }
.section-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-top: 11px; margin-bottom: 10px; }
.section-heading > span { color: var(--muted); font-size: .86rem; }
.roster-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.team { min-width: 0; border: 1px solid var(--line); background: var(--panel); overflow: hidden; }
.team.active { border-left: 3px solid var(--chalk); }
.team-header { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 12px 8px; min-height: 43px; border-bottom: 1px solid var(--line); }
.team-header h2 { font-size: 1.16rem; }
.team-count { color: var(--muted); font-size: .8rem; white-space: nowrap; }
.team.active .team-header { background: var(--surface); }
.progress { height: 3px; background: var(--surface); }
.progress span { display: block; height: 100%; background: var(--chalk); width: var(--progress); }
.team ol { margin: 0; padding: 2px 12px 5px; list-style: none; }
.slot { display: grid; grid-template-columns: 24px minmax(0, 1fr); align-items: center; gap: 6px; min-height: 26px; padding-block: 2px; border-bottom: 1px solid var(--quiet-line); }
.slot:last-child { border: 0; }
.slot-index { color: var(--muted); font-size: .74rem; }
.slot.captain .slot-index { color: var(--chalk); font-weight: 700; text-decoration: none; }
.slot-name { overflow-wrap: anywhere; font-weight: 700; font-size: .9rem; line-height: 1.17; }
.slot.empty .slot-name { font-size: .8rem; font-weight: 400; color: var(--muted); }
.slot.recent .slot-index { background: var(--chalk); color: var(--deep); text-align: center; }
.site-footer { display: flex; justify-content: space-between; gap: 12px; border-top: 1px solid var(--line); padding: 12px 0 17px; color: var(--muted); font-size: .82rem; }
.pool-panel { margin-top: 12px; }
.captain-content { display: grid; grid-template-columns: minmax(0, 1fr) minmax(260px, 300px); gap: 24px; align-items: start; }
.captain-roster-panel { margin-top: 23px; }
.captain-roster-panel > h2 { margin-bottom: 10px; }
.captain-roster-panel .team ol { padding: 5px 14px; }
.captain-roster-panel .slot { min-height: 37px; }
.captain-roster-panel .slot-name { font-size: 1rem; }
.captain-roster-panel .slot.empty .slot-name { font-size: .88rem; }
.pause-allowance { margin-top: 8px; }
.filters { display: flex; flex-wrap: wrap; align-items: end; gap: 12px; padding: 14px 0; }
.field { display: flex; flex-direction: column; gap: 5px; font-size: .88rem; font-weight: 600; }
.field.search { flex: 1 1 280px; }
.captain-heading .eyebrow { margin-bottom: 8px; color: var(--muted); }
.team-selection { max-width: 1000px; margin: clamp(24px, 6vh, 64px) auto; }
.team-selection-heading { margin-bottom: 32px; text-align: center; }
.team-selection-heading .eyebrow { color: var(--muted); margin-bottom: 12px; }
.team-selection-heading h1 { font-size: clamp(2.5rem, 5.8vw, 4.8rem); line-height: 1.05; }
.team-selection-heading > p:last-child { color: var(--muted); margin-top: 16px; font-size: 1.1rem; }
.team-choices { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.team-choice { display: flex; flex-direction: column; align-items: start; min-height: 210px; padding: clamp(20px, 3vw, 32px); border: 2px solid var(--line); background: var(--panel); color: var(--chalk); text-align: left; transition: background .15s, border-color .15s; }
.team-choice:hover { border-color: var(--chalk); background: var(--surface); }
.team-choice:focus-visible { outline-offset: 4px; }

.team-choice-name { font-size: clamp(1.8rem, 3.2vw, 2.6rem); font-weight: 700; line-height: 1.1; }
.team-choice-captain { margin: 10px 0 24px; color: var(--muted); font-size: 1rem; }
.team-choice-action { display: block; margin-top: auto; padding: 9px 16px; background: var(--chalk); color: var(--deep); font-size: 1rem; font-weight: 700; }
.team-selection-help { margin-top: 20px; color: var(--muted); font-size: .95rem; }
@media (max-width: 600px) {
  .team-choices { grid-template-columns: 1fr; gap: 12px; }
  .team-choice { min-height: 170px; }
  .team-selection { margin-top: 20px; }
}
.picker-turn {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 24px;
  padding: clamp(16px, 2.75vw, 32px);
  border: 1px solid var(--line);
  border-left: 3px solid var(--line);
  background: var(--deep);
}
.picker-turn.is-your-turn { border-left-color: var(--chalk); }
.picker-turn h2 { font-size: clamp(1.65rem, 3.1vw, 2.7rem); line-height: 1.05; }
.picker-turn p { margin-top: 8px; color: var(--muted); font-size: .96rem; }
.picker-order { display: grid; gap: 2px; }
.picker-order .button { justify-self: start; margin-top: 8px; }
.picker-order span, .picker-order small { color: var(--muted); font-size: .82rem; font-weight: 600; }
.picker-order strong { font-size: 1.32rem; font-variant-numeric: tabular-nums; }
.picker-other { grid-column: 1 / -1; padding-top: 15px; border-top: 1px solid var(--quiet-line); }
.picker-other h3 { margin: 0 0 8px; color: var(--muted); font-size: .9rem; font-weight: 600; }
.picker-sides { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: start; gap: 8px; }
.picker-side { min-width: 0; border: 1px solid var(--line); background: var(--panel); overflow: hidden; }
.picker-side summary { position: relative; display: block; cursor: pointer; list-style: none; overflow: hidden; }
.picker-side summary::-webkit-details-marker { display: none; }
.picker-side summary:focus-visible { outline-offset: -3px; }
.picker-side-copy {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 2px 8px;
  padding: 8px 11px;
}
.picker-side-team { font-size: .82rem; font-weight: 600; }
.picker-side-count { color: var(--muted); font-size: .76rem; }
.picker-side-player { grid-column: 1 / -1; font-size: 1rem; overflow-wrap: anywhere; }
.picker-side.is-empty .picker-side-player { color: var(--muted); font-weight: 400; }
.picker-side summary .picker-side-player::after {
  display: inline-block;
  width: .36em;
  height: .36em;
  margin-left: .55em;
  border-right: 1px solid currentColor;
  border-bottom: 1px solid currentColor;
  transform: translateY(-.15em) rotate(45deg);
  content: "";
}
.picker-side[open] summary .picker-side-player::after { transform: rotate(225deg); }
.picker-side ol { display: grid; gap: 7px; margin: 0; padding: 8px 11px 10px; border-top: 1px solid var(--line); list-style: none; }
.picker-side li { display: flex; align-items: baseline; gap: 9px; font-size: .88rem; overflow-wrap: anywhere; }
.picker-side li span { flex: 0 0 3.1rem; color: var(--muted); font-size: .75rem; }
.picker-side-reveal {
  position: absolute;
  inset: 0;
  background: var(--chalk);
  color: var(--deep);
  pointer-events: none;
  animation: picker-pick-wipe 6040ms cubic-bezier(.65, 0, .35, 1) both;
}
.picker-side-reveal .picker-side-count { color: inherit; }
@keyframes picker-pick-wipe {
  0% { clip-path: polygon(0 0, -1rem 0, 0 100%, 0 100%); }
  8.61%, 91.39% { clip-path: polygon(0 0, 100% 0, calc(100% + 1rem) 100%, 0 100%); }
  100% { clip-path: polygon(calc(100% + 1rem) 0, 100% 0, 100% 100%, 100% 100%); visibility: hidden; }
}
@media (prefers-reduced-motion: reduce) {
  .picker-side-reveal { display: none; }
}
.field input, textarea { width: 100%; background: var(--deep); color: var(--chalk); border: 1px solid var(--line); padding: 9px 12px; }
.field input { min-height: 44px; }
.field input::placeholder, textarea::placeholder { color: var(--muted); }
.pool-list { padding: 0; margin: 0; list-style: none; display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 7px 12px; }
.pool-row { display: flex; justify-content: space-between; align-items: center; gap: 8px; min-height: 52px; padding: 5px 11px; border: 1px solid var(--line); background: var(--panel); }
.pool-row strong { overflow-wrap: anywhere; font-size: .96rem; }
.pool-row .button { min-height: 36px; }
.empty-panel { padding: 22px; border: 1px dashed var(--line); color: var(--muted); }
.notice { margin-top: 12px; padding: 11px 14px; border: 1px solid var(--line); background: var(--panel); color: var(--muted); font-size: .91rem; }
dialog { width: min(100% - 32px, 520px); max-height: calc(100% - 36px); border: 1px solid var(--line); background: var(--panel); color: var(--chalk); padding: 21px; box-shadow: 0 18px 40px #0008; }
dialog::backdrop { background: #000000bd; }
dialog p { margin: 9px 0 16px; color: var(--muted); }
dialog label { font-size: .9rem; font-weight: 600; display: block; margin-bottom: 5px; }
dialog textarea { resize: vertical; display: block; }
.dialog-actions { justify-content: end; }
.dialog-error { border-left: 3px solid var(--chalk); padding-left: 8px; color: var(--chalk); }
.dialog-error:empty { display: none; }
.admin-login { max-width: 440px; margin: clamp(24px, 8vh, 90px) auto; }
.admin-login form { display: grid; gap: 16px; margin-top: 22px; }
.admin-login .button { justify-self: start; }
dialog .import-count { font-size: .88rem; }
#captain-fields .field { margin-bottom: 12px; }
#captain-fields input { display: block; margin-top: 4px; }
.toast { position: fixed; right: 18px; bottom: 18px; width: min(420px, calc(100% - 36px)); z-index: 3; padding: 12px 14px; border: 1px solid var(--line); border-left: 3px solid var(--chalk); background: var(--surface); box-shadow: 0 8px 24px #0005; }
.toast.error { background: var(--chalk); color: var(--deep); }

.countdown-page {
  display: grid;
  place-items: center;
  min-height: 100vh;
  min-height: 100svh;
  padding: 24px 14px;
}
.countdown { width: min(100%, 50rem); text-align: center; }
.countdown-logo { display: block; width: clamp(4.25rem, 18vmin, 9rem); height: auto; margin-inline: auto; }
.countdown-heading { margin-top: clamp(20px, 5vmin, 44px); }
.countdown-heading time { display: block; margin-top: 10px; color: var(--muted); font-size: clamp(.88rem, 2vw, 1.1rem); }
.countdown-timer {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: clamp(20px, 5vmin, 44px);
  background: var(--panel);
  border-block: 1px solid var(--line);
}
.countdown-timer > div { display: grid; gap: .45em; padding-block: clamp(10px, 3vmin, 24px); }
.countdown-timer > div + div { border-left: 1px solid var(--line); }
.countdown-timer strong { font-size: clamp(2rem, 10vw, 6.25rem); font-variant-numeric: tabular-nums; line-height: 1; }
.countdown-timer span { color: var(--muted); font-size: clamp(.65rem, 2vw, .9rem); font-weight: 600; letter-spacing: .05em; text-transform: uppercase; }
.countdown-end p { font-size: 1.25rem; font-weight: 700; }
.countdown-end p:not(:empty) { margin-top: 28px; }
.countdown-end a { display: inline-flex; align-items: center; margin-top: 16px; text-decoration: none; }

@media (min-width: 1600px) { .slot { min-height: 30px; } }
@media (max-width: 1040px) {
  .captain-content { grid-template-columns: minmax(0, 1fr) minmax(235px, 270px); gap: 16px; }
  .captain-content .pool-list { grid-template-columns: 1fr; }
  .shell { width: min(100% - 40px, 1460px); }
  .masthead { column-gap: 14px; }
  .masthead nav { gap: 15px; }
  .slot { grid-template-columns: 21px minmax(0, 1fr); }
}
@media (max-width: 780px) {
  .captain-content { grid-template-columns: minmax(0, 1fr); }
  .captain-roster-panel { margin-top: 0; }
  .roster-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .slot { min-height: 27px; }
  .masthead { column-gap: 12px; padding-top: 10px; }
  .masthead nav { grid-column: 1 / -1; grid-row: 2; justify-content: center; }
  .main { padding-top: 20px; }
  .pool-list { grid-template-columns: 1fr; }
  .picker-turn { grid-template-columns: 1fr; gap: 16px; }
}
@media (max-width: 480px) {
  .shell { width: calc(100% - 28px); }
  .page-heading { align-items: start; flex-direction: column; gap: 10px; }
  .hero { padding: 15px; gap: 14px; }
  .hero-stats { width: 100%; }
  .hero-stat { flex: 1; min-width: 0; padding: 7px; }
  .hero-stat span { font-size: .66rem; }
  .hero-stat strong { font-size: 1.05rem; font-weight: 700; }
  .roster-grid { gap: 8px; }
  .team-header, .team ol { padding-inline: 7px; }
  .slot { grid-template-columns: 18px minmax(0, 1fr); }
  .slot-name { font-size: .84rem; }
  .team-count { font-size: .7rem; }
  .site-footer { font-size: .75rem; }
  .masthead nav { gap: clamp(6px, 2.4vw, 12px); flex-wrap: wrap; }
  .picker-sides { grid-template-columns: 1fr; }
}

@media (min-width: 720px) and (min-height: 400px) and (min-aspect-ratio: 4/3) {
  .board {
    --tv-viewport-height: 100vh;
    --tv-height: min(var(--tv-viewport-height), 56.25vw);
    --tv-unit: calc(var(--tv-height) / 100);
    display: grid;
    grid-template-rows: minmax(0, 1fr);
    width: min(100%, calc(var(--tv-height) * 16 / 9));
    height: var(--tv-height);
    margin: calc((var(--tv-viewport-height) - var(--tv-height)) / 2) auto;
    padding: calc(var(--tv-unit) * 3) calc(var(--tv-unit) * 5.2);
  }
  @supports (height: 100dvh) {
    .board { --tv-viewport-height: 100dvh; }
  }
  .board .shell { width: 100%; margin-inline: 0; }
  .board .masthead { height: 100%; min-height: 0; }
  .board .connection { font-size: calc(var(--tv-unit) * 1.5); }
  .board .connection.demo { padding: calc(var(--tv-unit) * .35) calc(var(--tv-unit) * .8); }
  .board .main {
    display: grid;
    grid-template-rows: calc(var(--tv-unit) * 14) minmax(0, 1fr);
    gap: calc(var(--tv-unit) * 1.5);
    min-height: 0;
    padding: 0;
  }
  .board #heading { display: none; }
  .board-turn { height: 100%; min-height: 0; margin: 0; padding: calc(var(--tv-unit) * .7) calc(var(--tv-unit) * 2); }
  .board-turn h1 { font-size: calc(var(--tv-unit) * 4.5 * var(--tv-name-scale, 1)); }
  .board-turn .chip {
    min-height: 0;
    padding: calc(var(--tv-unit) * .55) calc(var(--tv-unit) * 1.05);
    font-size: calc(var(--tv-unit) * 1.6);
  }
  .board-turn .chip + h1 { margin-top: calc(var(--tv-unit) * .6); }
  .board .roster-grid {
    height: 100%;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: calc(var(--tv-unit) * 1.15);
  }
  .board .team {
    display: grid;
    grid-template-rows: calc(var(--tv-unit) * 4.8) calc(var(--tv-unit) * .35) minmax(0, 1fr);
  }
  .board .team-header { min-height: 0; padding: 0 calc(var(--tv-unit) * 1.05); }
  .board .team-header h2 { font-size: calc(var(--tv-unit) * 2.5); }
  .board .team-count { font-size: calc(var(--tv-unit) * 1.65); }
  .board .progress { height: auto; }
  .board .team ol {
    display: grid;
    grid-template-rows: repeat(16, minmax(0, 1fr));
    padding: calc(var(--tv-unit) * .2) calc(var(--tv-unit) * 1.05);
  }
  .board .slot { grid-template-columns: calc(var(--tv-unit) * 2.4) minmax(0, 1fr); gap: calc(var(--tv-unit) * .6); min-height: 0; padding: 0; }
  .board .slot-index { font-size: calc(var(--tv-unit) * 1.48); }
  .board .slot-name { font-size: calc(var(--tv-unit) * 1.9 * var(--tv-name-scale, 1)); line-height: 1; }
  .board .slot.empty .slot-name { font-size: calc(var(--tv-unit) * 1.6); }
}


/* Team colours apply consistently across selection, rosters and pick reveals. */
.team-choice { border-top: 5px solid var(--team-color); }
.team-choice:hover { border-color: var(--team-color); }
.team-choice-name, .captain-heading h1 { color: var(--team-color, var(--chalk)); }
.team-choice .team-choice-action { background: var(--team-color); color: var(--deep); }
.team .team-header h2, .picker-side-team { color: var(--team-color, var(--chalk)); }
.team, .team.active { border-top: 3px solid var(--team-color, var(--line)); }
.team.active { border-left-color: var(--team-color, var(--chalk)); }
.team .progress span { background: var(--team-color, var(--chalk)); }
.team .slot.recent .slot-index { background: var(--team-color, var(--chalk)); }
.picker-side { border-top: 3px solid var(--team-color, var(--line)); }
.picker-turn, .picker-turn.is-your-turn { border-left-color: var(--team-color, var(--line)); }
.picker-turn > div:first-child h2 { color: var(--team-color, var(--chalk)); }
.board-turn { border-left-color: var(--team-color, var(--chalk)); }
.board-turn .chip { background: var(--team-color, var(--chalk)); color: var(--deep); }
:is(.board-turn, .board-turn-previous).is-pick { background: var(--team-color, var(--chalk)); }
.picker-side-reveal { background: var(--team-color, var(--chalk)); }
.picker-side-reveal .picker-side-team { color: inherit; }


/* Solid team colour panels with navy text. */
.team .team-header,
.team.active .team-header {
  background: var(--team-color, var(--panel));
  color: #000000;
  border-bottom-color: transparent;
}
.team .team-header h2,
.team .team-header .team-count { color: #000000; }
.team-choice,
.team-choice:hover {
  background: var(--team-color, var(--panel));
  color: #000000;
  border-color: var(--team-color, var(--line));
}
.team-choice .team-choice-name,
.team-choice .team-choice-captain { color: #000000; }
.team-choice .team-choice-action { background: #000000; color: var(--chalk); }
.team-choice:hover { filter: brightness(1.06); }
.picker-side > summary,
.picker-side.is-empty {
  background: var(--team-color, var(--panel));
  color: #000000;
}
.picker-side .picker-side-team,
.picker-side .picker-side-count,
.picker-side.is-empty .picker-side-player { color: #000000; }


.turn-clock { display: flex; align-items: baseline; justify-content: center; gap: 10px; margin-top: 8px; }
.turn-clock > span { font-size: .85rem; color: inherit; }
.turn-clock [data-turn-timer] { font-size: 1.7rem; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; }
.picker-order .turn-clock { justify-content: start; flex-wrap: wrap; }
.picker-order .turn-clock > span { color: var(--muted); }
[data-turn-timer].is-expired { text-decoration: underline; text-underline-offset: .15em; }
@media (min-width: 720px) and (min-height: 400px) and (min-aspect-ratio: 4/3) {
  .board .turn-clock { margin-top: calc(var(--tv-unit) * .65); gap: calc(var(--tv-unit) * 1); }
  .board .turn-clock > span { font-size: calc(var(--tv-unit) * 1.5); }
  .board .turn-clock [data-turn-timer] { font-size: calc(var(--tv-unit) * 2.7); }
}

.event-start-date { margin-top: 7px; color: var(--muted); font-size: .9rem; }
@media (min-width: 720px) and (min-height: 400px) and (min-aspect-ratio: 4/3) {
  .board .event-start-date { margin-top: calc(var(--tv-unit) * .65); font-size: calc(var(--tv-unit) * 1.5); }
}

.player-copy { min-width: 0; }
.player-metadata { display: block; margin-top: 3px; color: var(--muted); font-size: .875rem; line-height: 1.35; }
#player-form { display: grid; gap: 14px; }
#player-form select { min-height: 44px; padding: 8px 12px; border: 1px solid var(--line); background: var(--deep); color: var(--chalk); font: inherit; }
.slot-copy { min-width: 0; }
.slot-details { display: block; color: var(--muted); font-size: .75rem; line-height: 1.15; margin-top: 2px; }
@media (min-width: 720px) and (min-height: 400px) and (min-aspect-ratio: 4/3) {
  .board .slot-details { font-size: calc(var(--tv-unit) * 1.35); margin-top: calc(var(--tv-unit) * .2); }
}


/* Solid team headers meet the roster without the old progress track. */
.team > .progress { display: none; }
@media (min-width: 720px) and (min-height: 400px) and (min-aspect-ratio: 4/3) {
  .board .team { grid-template-rows: calc(var(--tv-unit) * 4.8) minmax(0, 1fr); }
}

/* Keep every roster name at the same size, including team leaders. */
.team .slot-name, .team .slot.empty .slot-name { font-size: .8rem; }
.captain-roster-panel .team .slot-name, .captain-roster-panel .team .slot.empty .slot-name { font-size: .88rem; }
@media (min-width: 720px) and (min-height: 400px) and (min-aspect-ratio: 4/3) {
  .board .team .slot-name, .board .team .slot.empty .slot-name { font-size: calc(var(--tv-unit) * 1.6); }
}

.pool-row.is-unavailable { background: var(--deep); border-color: var(--quiet-line); color: #858585; }
.pool-row.is-unavailable .player-copy { opacity: .65; }
.pool-row.is-unavailable .button { opacity: .3; cursor: not-allowed; }

.roster-reminder { border-left: 4px solid var(--chalk); color: var(--chalk); line-height: 1.6; }
.roster-reminder strong { display: block; }

.picker-side-meta { grid-column: 1 / -1; color: inherit; opacity: .8; font-size: .8rem; line-height: 1.3; }
.picker-history-meta { display: block; margin-top: 3px; color: var(--muted); font-size: .78rem; line-height: 1.3; }
.picker-side li > div { min-width: 0; }
.slot-copy { display: grid; line-height: 1; }

@font-face {
  font-family: "SCL Team Wordmark";
  src: url("/fonts/RussoOne-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
.board .team-wordmark, .team-choice .team-wordmark, .captain-heading .team-wordmark {
  display: inline-grid;
  justify-items: center;
  gap: .08em;
  color: #fff;
  font-family: "SCL Team Wordmark", var(--font);
  font-weight: 400;
  font-style: normal;
  line-height: .95;
  text-transform: uppercase;
  letter-spacing: -.035em;
  transform: skewX(-11deg);
}
.board .team-wordmark-prefix, .team-choice .team-wordmark-prefix, .captain-heading .team-wordmark-prefix { font-size: .4em; line-height: .9; letter-spacing: .015em; }
.board .team-wordmark-name, .team-choice .team-wordmark-name, .captain-heading .team-wordmark-name { font: inherit; }
.board .team-header h2 { flex: 1; min-width: 0; text-align: center; }
.board .team-header .team-wordmark { font-size: 1.7rem; }
.board .team-wordmark-heading { display: flex; justify-content: center; }
.board .board-turn .team-wordmark { font-size: 2.2rem; }
@media (min-width: 720px) and (min-height: 400px) and (min-aspect-ratio: 4/3) {
  .board .team-header .team-wordmark { font-size: calc(var(--tv-unit) * 3.1); }
  .board .board-turn .team-wordmark { font-size: calc(var(--tv-unit) * 3.6); }
}

@media (min-width: 720px) and (min-height: 400px) and (min-aspect-ratio: 4/3) {
  .board .team { grid-template-rows: calc(var(--tv-unit) * 6) minmax(0, 1fr); }
}


/* Centre the main-board wordmarks in the entire coloured header. */
.board .team-header { display: flex; justify-content: center; align-items: center; gap: 0; padding-block: 0; }
.board .team-header h2 { display: flex; justify-content: center; align-items: center; width: 100%; height: 100%; margin: 0; line-height: 1; }
.board .team-header .team-count { display: none; }

.team-choice { align-items: center; justify-content: center; text-align: center; gap: 14px; min-height: 245px; }
.team-choice .team-wordmark { font-size: clamp(2.1rem, 4vw, 3.25rem); }
.team-choice .team-choice-name { display: flex; align-items: center; justify-content: center; line-height: 1; }
.team-choice .team-choice-captain { margin: 0; }
.team-choice .team-choice-action { margin-top: 0; }
@media (max-width: 600px) { .team-choice { min-height: 210px; } }

/* Full-screen pick reveal, confined to the public main board. */
.page-pick-reveal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  padding: clamp(24px, 5vmin, 80px);
  background: var(--team-color, var(--chalk));
  color: var(--deep);
  text-align: center;
  pointer-events: none;
}
.page-pick-copy { width: min(100%, 1600px); min-width: 0; }
.page-pick-label { margin: 0 0 16px; font-size: clamp(.9rem, 1.7vw, 1.5rem); font-weight: 700; text-transform: uppercase; letter-spacing: .12em; }
.page-pick-reveal .team-wordmark { font-size: clamp(2.2rem, 6vmin, 4.5rem); margin-bottom: clamp(20px, 5vmin, 55px); }
.page-pick-reveal .page-pick-name { margin: 0; font-size: clamp(2.5rem, 6.5vw, 7.5rem); line-height: 1.05; overflow-wrap: anywhere; }
.page-pick-reveal.is-entering { animation: page-pick-enter 520ms cubic-bezier(.65, 0, .35, 1) both; }
.page-pick-reveal.is-exiting { animation: page-pick-exit 520ms cubic-bezier(.65, 0, .35, 1) both; }
@keyframes page-pick-enter {
  from { clip-path: polygon(0 0, 0 0, -5vw 100%, 0 100%); }
  to { clip-path: polygon(0 0, calc(100% + 5vw) 0, 100% 100%, 0 100%); }
}
@keyframes page-pick-exit {
  from { clip-path: polygon(0 0, 100% 0, 100% 100%, -5vw 100%); }
  to { clip-path: polygon(calc(100% + 5vw) 0, 100% 0, 100% 100%, 100% 100%); }
}
@media (prefers-reduced-motion: reduce) {
  .page-pick-reveal.is-entering, .page-pick-reveal.is-exiting { animation: none; }
}

/* Keep each club alongside its player on the main board. */
.board .slot-copy { display: flex; align-items: baseline; flex-wrap: wrap; gap: .4em; }
.board .team .slot-details { display: inline; margin: 0; white-space: nowrap; }
.board .slot-details::before { content: '·'; margin-right: .4em; }
/* Compact, centred team picking screen. */
.captain-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  margin: 12px 0;
}
.captain-heading > div { grid-column: 2; text-align: center; }
.captain-heading h1 { margin: 0; line-height: 1; }
.captain-heading .team-wordmark { font-size: clamp(1.8rem, 3vw, 2.6rem); color: var(--team-color); }
.captain-heading > .button { grid-column: 3; justify-self: end; padding: 10px 16px; }
.picker-turn { grid-template-columns: minmax(0, 1fr); gap: 14px; padding: 18px 20px; }
.picker-turn > div:first-child { text-align: center; }
.picker-turn h2 { font-size: clamp(1.5rem, 2.4vw, 2rem); }
.picker-turn p { margin-top: 5px; font-size: .9rem; }
.picker-order { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px 14px; text-align: center; }
.picker-order strong { font-size: 1.15rem; }
.picker-order .button { margin: 0; padding: 9px 14px; }
.picker-order .turn-clock { margin: 0; justify-content: center; }
.picker-other { padding-top: 12px; }
.picker-other h3 { margin-bottom: 6px; font-size: .82rem; }
@media (max-width: 600px) {
  .captain-heading { grid-template-columns: 1fr; gap: 8px; }
  .captain-heading > div, .captain-heading > .button { grid-column: 1; justify-self: center; }
  .picker-turn { padding: 14px 12px; gap: 12px; }
  .picker-order { gap: 6px 10px; }
}

/* Dark lettering keeps all four solid team colours legible, including white. */
.board .team-header .team-wordmark,
.team-choice .team-wordmark,
.page-pick-reveal .team-wordmark { color: #000000; }

/* Supplied mascot artwork, displayed from its original four-quadrant sheet. */
.team-identity { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-width: 0; vertical-align: middle; }
.team-logo { display: block; flex: 0 0 auto; width: 84px; aspect-ratio: 1; background-image: url("/team-logos.webp"); background-size: 200% 200%; background-repeat: no-repeat; clip-path: inset(2%); }
[data-team="1"] .team-logo { background-position: 0 0; }
[data-team="2"] .team-logo { background-position: 100% 0; }
[data-team="3"] .team-logo { background-position: 0 100%; }
[data-team="4"] .team-logo { background-position: 100% 100%; }
.team-identity-name { font: 700 1rem/1.1 var(--font); letter-spacing: -.02em; text-transform: none; overflow-wrap: normal; }
.team-header .team-identity { width: 100%; }
.team-header .team-logo { width: 70px; }
.team-header .team-identity-name { max-width: 9em; text-align: left; }
.team-header { min-height: 80px; }
.team-choice { min-height: 260px; }
.team-choice .team-identity { flex-direction: column; gap: 5px; }
.team-choice .team-logo { width: clamp(130px, 13vw, 175px); }
.team-choice .team-identity-name { font-size: 1.15rem; }
.captain-heading .team-logo { width: 72px; }
.captain-heading .team-identity-name { font-size: clamp(1.2rem, 2.5vw, 1.8rem); color: var(--team-color); }
.picker-side-team .team-identity { gap: 6px; justify-content: start; }
.picker-side-team .team-logo { width: 40px; }
.picker-side-team .team-identity-name { font-size: .82rem; text-align: left; }
.page-pick-reveal .team-identity { display: flex; flex-direction: column; gap: 5px; margin-bottom: 20px; }
.page-pick-reveal .team-logo { width: clamp(140px, 29vmin, 280px); }
.page-pick-reveal .team-identity-name { font-size: clamp(1.15rem, 3vmin, 2rem); }
.board-turn .team-logo { width: 64px; }
.board-turn .team-identity-name { font-size: clamp(1.15rem, 2vw, 1.8rem); }
.board-turn .chip + h1 { margin-top: 4px; }
@media (min-width: 720px) and (min-height: 400px) and (min-aspect-ratio: 4/3) {
  .board .team { grid-template-rows: calc(var(--tv-unit) * 12) minmax(0, 1fr); }
  .board .team-header .team-logo { width: calc(var(--tv-unit) * 10.5); }
  .board .team-header .team-identity { gap: calc(var(--tv-unit) * .8); }
  .board .team-header .team-identity-name { font-size: calc(var(--tv-unit) * 2.1); }
  .board .board-turn .team-logo { width: calc(var(--tv-unit) * 6); }
  .board .board-turn .team-identity-name { font-size: calc(var(--tv-unit) * 2.6); }
  .board .board-turn .chip + h1 { margin-top: calc(var(--tv-unit) * .15); }
  .board .board-turn .turn-clock { margin-top: 0; }
}
@media (max-width: 600px) {
  .team-header .team-identity { flex-direction: column; gap: 4px; }
  .team-header .team-identity-name { text-align: center; font-size: .82rem; }
  .team-header { padding-block: 6px; }
  .captain-heading .team-identity { flex-direction: column; gap: 4px; }
}

/* White lettering keeps the cobalt panels readable. */
.team[data-team="3"] .team-header,
.team[data-team="3"] .team-header h2,
.team[data-team="3"] .team-header .team-count,
.team-choice[data-team="3"] .team-choice-name,
.picker-side[data-team="3"] > summary,
.picker-side[data-team="3"] .picker-side-team,
.picker-side[data-team="3"] .picker-side-count,
.picker-side[data-team="3"].is-empty .picker-side-player,
.page-pick-reveal[data-team="3"] { color: #ffffff; }

/* Logo-only identities and a full-height public roster board. */
.team-identity { gap: 0; }
.team-identity-name {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); clip-path: inset(50%);
  white-space: nowrap; border: 0;
}
.board #summary { display: none; }
.board .main { display: block; }
.board .team-header { flex-direction: column; justify-content: center; gap: 3px; padding-block: 5px; }
.board .team-header h2 { flex: 0 0 auto; height: auto; }
.board .team-header .team-identity { flex-direction: row; gap: 0; }
.board .team-header .team-logo { width: min(160px, 70%); }
.board .team { border-left-width: 1px; }
.team-pick-state { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 26px; }
.team-pick-label { background: #000; color: #fff; padding: 4px 9px; font: 700 .75rem/1 var(--font); text-transform: uppercase; letter-spacing: .06em; border-radius: 3px; }
.team-pick-state .turn-clock { margin: 0; gap: 0; color: #000; }
.team-pick-state .turn-clock > span { display: none; }
.team-pick-state .turn-clock [data-turn-timer] { font-size: 1rem; }
.team[data-team="3"] .team-pick-state .turn-clock { color: #fff; }
.board .team.is-picking { outline: 2px solid var(--team-color); outline-offset: 3px; box-shadow: 0 0 20px color-mix(in srgb, var(--team-color) 45%, transparent); }
.board .team.active:not(.is-picking) { outline: 2px dashed var(--team-color); outline-offset: 3px; }
@media (min-width: 720px) and (min-height: 400px) and (min-aspect-ratio: 4/3) {
  .board .main { display: grid; grid-template-rows: minmax(0, 1fr); gap: 0; }
  .board .team { grid-template-rows: calc(var(--tv-unit) * 26) minmax(0, 1fr); }
  .board .team-header .team-logo { width: calc(var(--tv-unit) * 20); }
  .board .team-header { padding: calc(var(--tv-unit) * .5); }
  .board .team-pick-state { min-height: calc(var(--tv-unit) * 3.5); gap: calc(var(--tv-unit) * 1); }
  .board .team-pick-label { font-size: calc(var(--tv-unit) * 1.5); padding: calc(var(--tv-unit) * .55) calc(var(--tv-unit) * 1); }
  .board .team-pick-state .turn-clock [data-turn-timer] { font-size: calc(var(--tv-unit) * 2); }
}

/* Light surfaces retain readable labels on the solid team panels. */
[data-team] { --team-ink: #111111; --team-outline: var(--team-color); }
[data-team="3"] { --team-ink: #ffffff; }
[data-team="4"] { --team-outline: #000000; }
.team-choice .team-choice-action { background: #111111; color: #ffffff; }
.team .team-header,
.team .team-header h2,
.team .team-header .team-count,
.team-choice .team-choice-name,
.picker-side > summary,
.picker-side .picker-side-team,
.picker-side .picker-side-count,
.picker-side.is-empty .picker-side-player,
.page-pick-reveal,
.picker-side-reveal { color: var(--team-ink, #111111); }
.picker-turn > div:first-child h2 { color: var(--chalk); }
.board-turn .chip { color: var(--team-ink, #111111); }
:is(.board-turn, .board-turn-previous).is-pick { color: var(--team-ink, #111111); }
:is(.board-turn, .board-turn-previous).is-pick .chip { background: #111111; color: #ffffff; }
.board .team.is-picking { outline-color: var(--team-outline); box-shadow: 0 0 16px color-mix(in srgb, var(--team-outline) 25%, transparent); }
.board .team.active:not(.is-picking) { outline-color: var(--team-outline); }
dialog::backdrop { background: #11182766; }
.pool-row.is-unavailable { color: #68707b; }

.team .slot.recent .slot-index { color: var(--team-ink, #111111); }

/* Grey surround, stronger roster text and compact, centred logo headers. */
.board .slot-name,
.board .slot.empty .slot-name,
.board .slot-details,
.board .slot-index { font-weight: 700; }
.board .team-header { position: relative; display: grid; place-items: center; gap: 0; padding: 0; }
.board .team-header h2 { display: grid; place-items: center; width: 100%; height: 100%; margin: 0; }
.board .team-header .team-identity { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; }
.board .team-pick-state { position: absolute; inset: auto 4px 3px; min-height: 22px; }
.board .team-pick-state:empty { display: none; }
@media (min-width: 720px) and (min-height: 400px) and (min-aspect-ratio: 4/3) {
  .board .team { grid-template-rows: calc(var(--tv-unit) * 22) minmax(0, 1fr); }
  .board .team-header { padding: 0; }
  .board .team-header .team-logo { width: calc(var(--tv-unit) * 19); }
  .board .team-pick-state { bottom: calc(var(--tv-unit) * .3); min-height: calc(var(--tv-unit) * 3); }
}

/* White rosters and a clear selected-team banner. */
.team { background: #ffffff; }
.captain-heading.team-banner {
  display: flex; align-items: center; justify-content: center; width: 100%;
  min-height: 100px; padding: 12px 20px; margin: 0 0 16px;
  background: var(--team-color); border: 1px solid var(--line); color: var(--team-ink, #111111);
}
.captain-heading.team-banner h1 {
  display: flex; align-items: center; justify-content: center; gap: 18px;
  width: 100%; margin: 0; color: inherit; font-size: clamp(1.6rem, 3vw, 2.4rem); text-align: center;
}
.captain-heading.team-banner .team-logo { width: 74px; }
.team-banner-name { min-width: 0; }
.captain-content .pool-heading { justify-content: flex-end; margin-block: 0 4px; }
.captain-content .pool-list { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.captain-content .pool-row { min-height: 62px; padding: 8px 10px; background: #ffffff; }
.captain-content .pool-row strong { font-size: .9rem; line-height: 1.2; display: block; }
.pool-player-details { display: block; color: var(--muted); font-size: .75rem; line-height: 1.3; margin-top: 4px; }
.captain-content .filters { padding-block: 6px 10px; }
.captain-content .pool-row.is-unavailable { background: #eef0f3; }
@media (max-width: 1100px) {
  .captain-content .pool-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 600px) {
  .captain-heading.team-banner { min-height: 84px; padding: 10px; }
  .captain-heading.team-banner h1 { gap: 10px; font-size: 1.45rem; }
  .captain-heading.team-banner .team-logo { width: 60px; }
  .captain-content .pool-list { grid-template-columns: minmax(0, 1fr); }
}

/* Edge-to-edge banner on a white team picking page. */
body.picker-page { --bg: #ffffff; --deep: #ffffff; background: #ffffff; }
.picker-page .main { width: 100%; padding-top: 0; margin-inline: 0; }
.picker-page #heading { width: 100%; }
.picker-page .captain-heading.team-banner { width: 100%; margin: 0 0 18px; border-inline: 0; border-top: 0; }
.picker-page #summary,
.picker-page #content { width: min(calc(100% - 72px), 1460px); margin-inline: auto; }
.picker-page #team-selection { width: min(calc(100% - 72px), 1000px); }
@media (max-width: 1040px) {
  .picker-page #summary, .picker-page #content { width: calc(100% - 40px); }
}
@media (max-width: 480px) {
  .picker-page #summary, .picker-page #content, .picker-page #team-selection { width: calc(100% - 28px); }
}

/* Join the coloured team banner to the full-width black status strip. */
.picker-page .site-header { border-bottom: 0; }
.picker-page .masthead nav a[aria-current="page"]::after { display: none; }
.picker-page .captain-heading.team-banner { margin-bottom: 0; border-bottom: 0; }
.picker-page #summary {
  --chalk: #ffffff; --muted: #d2d7de; --deep: #000000;
  --panel: #111111; --surface: #252525; --line: #454545; --quiet-line: #333333;
  width: 100%; margin: 0; background: #000000; color: #ffffff;
}
.picker-page #summary .picker-turn { width: 100%; padding-block: 22px; border: 0; background: #000000; color: #ffffff; }
.picker-page #summary .picker-turn h2 { color: #ffffff; }
.picker-page #content { margin-top: 16px; }

/* Admin breaks replace the public board with a simple shared message. */
.event-break {
  position: fixed; inset: 0; z-index: 100; display: grid; place-items: center;
  padding: 32px; background: var(--bg); color: var(--chalk); text-align: center;
}
.event-break h1 { font-size: clamp(2.2rem, 5vw, 5rem); line-height: 1.1; }
.event-break p { margin-top: 18px; color: var(--muted); font-size: clamp(1.2rem, 2.5vw, 2rem); }

/* Public and team-choice boards stay grey; individual team pages stay white. */
body.board { background: #dfe3e8; }
body.picker-page.choosing-team { --bg: #dfe3e8; --deep: #dfe3e8; background: #dfe3e8; }

/* Centre player labels, with balanced space for row numbers and pick controls. */
.team .slot { grid-template-columns: 24px minmax(0, 1fr) 24px; }
.team .slot-copy { grid-column: 2; text-align: center; justify-content: center; justify-items: center; align-items: center; }
.captain-content .pool-row { display: grid; grid-template-columns: minmax(0, 1fr); }
.captain-content .pool-row .player-copy { text-align: center; }
.captain-content .pool-row:has([data-pick]) { grid-template-columns: 42px minmax(0, 1fr) 42px; }
.captain-content .pool-row:has([data-pick]) .player-copy { grid-column: 2; }
.captain-content .pool-row [data-pick] { grid-column: 3; padding-inline: 6px; min-width: 0; }
@media (min-width: 720px) and (min-height: 400px) and (min-aspect-ratio: 4/3) {
  .board .team .slot { grid-template-columns: calc(var(--tv-unit) * 2.4) minmax(0, 1fr) calc(var(--tv-unit) * 2.4); }
}

/* The original league badge sits above the break message on black. */
.event-break { background: #000000; color: #ffffff; }
.event-break-content { width: 100%; }
.event-break-logo {
  position: relative; overflow: hidden; width: clamp(220px, 46vw, 580px);
  aspect-ratio: 1.9; margin: 0 auto clamp(16px, 3vh, 30px);
}
.event-break-logo img { display: block; position: absolute; width: 180%; height: auto; max-width: none; left: -40%; top: -116%; }
.event-break p { color: #d2d7de; }
@media (max-height: 550px) {
  .event-break { padding: 18px; }
  .event-break-logo { width: min(38vw, 330px); margin-bottom: 12px; }
  .event-break h1 { font-size: clamp(1.6rem, 4vw, 3rem); }
  .event-break p { margin-top: 10px; font-size: 1.15rem; }
}

.login-hint { color: var(--muted); font-size: .85rem; }
.admin-users { margin: 24px 0; padding: 20px; background: #ffffff; border: 1px solid var(--line); }
.admin-users h2 { margin-bottom: 10px; }
.admin-users > p { color: var(--muted); margin-bottom: 16px; }
.user-create-form { display: grid; grid-template-columns: 1fr 1fr 1fr auto; align-items: end; gap: 12px; }
.admin-users input, .admin-users select, #account-password-form input {
  min-height: 44px; width: 100%; padding: 8px 10px; border: 1px solid var(--line); background: #fff; color: #15181c; font: inherit;
}
.user-list { margin-top: 18px; }
.user-account-row { display: grid; grid-template-columns: 1fr 1fr auto auto; align-items: center; gap: 10px; padding: 12px 0; border-top: 1px solid var(--quiet-line); }
.user-account-row strong { overflow-wrap: anywhere; }
.account-feedback { margin-top: 12px; color: var(--muted); }
@media (max-width: 850px) {
  .user-create-form { grid-template-columns: 1fr 1fr; }
  .user-account-row { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 480px) { .user-create-form { grid-template-columns: 1fr; } .admin-users { padding: 14px; } }

/* Tighter player cards and roster rows on individual team screens. */
.picker-page .captain-content .pool-list { gap: 5px 8px; }
.picker-page .captain-content .pool-row { min-height: 46px; padding: 4px 8px; gap: 5px; }
.picker-page .captain-content .pool-row strong { line-height: 1.1; }
.picker-page .pool-player-details { margin-top: 1px; line-height: 1.1; }
.picker-page .captain-content .pool-row .button { min-height: 30px; padding: 5px 6px; font-size: .82rem; }
.picker-page .captain-roster-panel .slot { min-height: 31px; padding-block: 2px; }
.picker-page .captain-roster-panel .slot-name { line-height: 1.1; }
.picker-page .captain-roster-panel .slot-details { margin-top: 1px; line-height: 1.1; }

/* A branded black sign-in screen; team pages retain their own light theme. */
body.login-screen, body.picker-page.login-screen {
  --bg: #000000; --deep: #000000; --chalk: #ffffff; --muted: #c8cdd5;
  --line: #454545; --quiet-line: #282828; --panel: #111111; --surface: #222222;
  background: #000000; color: #ffffff;
}
.login-screen .site-header, .login-screen .site-footer { display: none; }
.login-screen .main {
  display: grid; place-items: center; width: 100%; min-height: 100vh; min-height: 100dvh;
  padding: clamp(24px, 5vmin, 48px) 20px; margin: 0;
}
.login-screen .main > :not(#admin-login) { display: none !important; }
.login-screen .admin-login { width: min(100%, 440px); max-width: 440px; margin: 0; }
.login-screen .admin-login h1 { text-align: center; font-size: 2rem; }
.login-screen .admin-login form { gap: 12px; margin-top: 24px; }
.login-screen .admin-login input { background: #111111; color: #ffffff; border-color: #454545; }
.login-screen .admin-login .button { width: 100%; }
.login-league-logo { position: relative; overflow: hidden; width: min(100%, 380px); aspect-ratio: 1.9; margin: 0 auto 24px; }
.login-league-logo img { display: block; position: absolute; width: 180%; height: auto; max-width: none; left: -40%; top: -116%; }

/* The pre-draft countdown spans the centre of the broadcast screen. */
.broadcast-countdown {
  position: fixed; inset: 50% 0 auto; transform: translateY(-50%); z-index: 30;
  display: grid; justify-items: center; gap: 8px; width: 100%;
  padding: clamp(16px, 2.4vh, 30px) 20px; background: #000; color: #fff;
  text-align: center; box-shadow: 0 6px 24px #0003;
}
.broadcast-countdown-label { font-size: clamp(13px, 1.2vw, 20px); font-weight: 700; text-transform: uppercase; letter-spacing: .12em; }
.broadcast-countdown [data-event-countdown] { font-size: clamp(25px, 4.6vw, 78px); line-height: 1.08; font-weight: 700; font-variant-numeric: tabular-nums; }
.broadcast-countdown-date { font-size: clamp(13px, 1.15vw, 18px); color: #d2d7de; }
