:root {
  --navy: #14213D;
  --navy-2: #1D2E52;
  --cream: #F6F4EE;
  --card: #FBFAF6;
  --line: #E2DDD0;
  --orange: #E8833A;
  --kicker: #B0551A;
  --muted: #5A6378;
  --ok: #2F7D4F;
  --ok-bg: #E3F1E8;
  --no: #B23A2E;
  --no-bg: #F8E3E0;
  --display: 'Oswald', Arial, sans-serif;
  --body: 'Public Sans', Arial, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--cream);
  color: var(--navy);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.45;
  -webkit-tap-highlight-color: transparent;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }

.wrap { max-width: 560px; margin: 0 auto; padding: 20px 16px 48px; }

/* Header */
.top { background: var(--navy); color: var(--cream); padding: 28px 16px 24px; }
.top .inner { max-width: 560px; margin: 0 auto; }
.brand { font-family: var(--display); font-weight: 700; font-size: 34px; letter-spacing: 1px; text-transform: uppercase; line-height: 1; }
.brand span { color: var(--orange); }
.tag { margin: 8px 0 0; color: #C9CFDB; font-size: 15px; }

.bar { background: var(--navy); color: var(--cream); padding: 12px 16px; position: sticky; top: 0; z-index: 5; }
.bar .inner { max-width: 560px; margin: 0 auto; display: flex; align-items: center; gap: 12px; }
.bar .back { font-size: 15px; font-weight: 600; color: #C9CFDB; padding: 6px 0; }
.bar .title { font-family: var(--display); font-size: 20px; font-weight: 600; text-transform: uppercase; letter-spacing: .5px; }

.kicker { font-size: 13px; font-weight: 700; color: var(--kicker); text-transform: uppercase; letter-spacing: 1.5px; margin: 0 0 8px; }
h1, h2 { font-family: var(--display); text-transform: uppercase; line-height: 1.1; margin: 0; }
h1 { font-size: 32px; font-weight: 700; }
h2 { font-size: 24px; font-weight: 600; }

/* Playbook cards */
.pb { display: block; background: var(--card); border: 2px solid var(--line); border-radius: 18px; padding: 18px; margin-bottom: 14px; }
.pb:active { transform: scale(.99); }
.pb .row { display: flex; align-items: center; gap: 14px; }
.pb .badge { width: 52px; height: 52px; flex: none; border-radius: 50%; background: var(--orange); color: var(--navy); display: grid; place-items: center; font-family: var(--display); font-weight: 700; font-size: 20px; }
.pb h2 { font-size: 22px; }
.pb p { margin: 2px 0 0; color: var(--muted); font-size: 15px; }
.meter { height: 8px; border-radius: 4px; background: var(--line); overflow: hidden; }
.meter i { display: block; height: 100%; background: var(--orange); border-radius: 4px; transition: width .3s; }
.pb .meter { margin-top: 14px; }
.pb .count { margin-top: 6px; font-size: 13px; color: var(--muted); }

.note { font-size: 14px; color: var(--muted); margin-top: 24px; }

/* Buttons */
.btn { display: block; width: 100%; border: 0; border-radius: 14px; padding: 16px; background: var(--orange); color: var(--navy); font-family: var(--display); font-size: 20px; font-weight: 600; text-transform: uppercase; letter-spacing: 1px; cursor: pointer; text-align: center; }
.btn.alt { background: transparent; border: 2px solid var(--navy); }
.btn + .btn { margin-top: 10px; }
.btn:disabled { opacity: .45; }

/* Playbook detail */
.stats { display: flex; gap: 10px; margin: 18px 0; }
.stat { flex: 1; background: var(--card); border: 2px solid var(--line); border-radius: 14px; padding: 12px; text-align: center; }
.stat b { display: block; font-family: var(--display); font-size: 28px; line-height: 1.1; }
.stat span { font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: 1px; }
.plays { list-style: none; padding: 0; margin: 22px 0 0; }
.plays li { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.plays .t { flex: 1; font-weight: 600; }
.plays .t small.by { display: block; font-weight: 400; font-size: 12px; color: var(--muted); }
.pill { font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 99px; text-transform: uppercase; letter-spacing: .5px; flex: none; }
.pill.new { background: var(--line); color: var(--muted); }
.book .plays.builtin li { flex-wrap: nowrap; }
.book .plays.builtin .t { flex: 1; min-width: 0; color: inherit; text-decoration: none; }
.plays.builtin .t b { display: block; font-weight: 600; }
.plays.builtin .t small { display: block; font-weight: 400; font-size: 12px; color: var(--muted); }
.plays.builtin a.t b { color: var(--navy); }
.plays.builtin li.off .t b { text-decoration: line-through; color: var(--muted); }
.choicerow { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.fld .choicerow textarea { resize: none; field-sizing: content; min-height: 0; padding: 10px 14px; }
.choicerow input[type="radio"] { width: 24px; height: 24px; flex: none; accent-color: var(--navy); margin: 0; padding: 0; }
.editplay .pane-field { margin-bottom: 24px; }
.choicerow .k { flex: none; width: 1em; font-family: var(--display); font-weight: 600; color: var(--muted); }
.pill.learning { background: #FBE6D4; color: var(--kicker); }
.pill.mastered { background: var(--ok-bg); color: var(--ok); }

/* Quiz */
.qbar .inner { gap: 14px; }
.qbar .x { font-size: 22px; line-height: 1; padding: 4px 6px 4px 0; color: #C9CFDB; }
.qbar .meter { flex: 1; background: var(--navy-2); }
.qbar .n { font-size: 14px; color: #C9CFDB; min-width: 40px; text-align: right; }

.sit { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; font-weight: 600; font-size: 15px; }
.sit svg { flex: none; }
.outs { display: flex; gap: 4px; margin-left: auto; align-items: center; font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: 1px; }
.outs i { width: 12px; height: 12px; border-radius: 50%; border: 2px solid var(--navy); }
.outs i.on { background: var(--navy); }

.field { border-radius: 18px; overflow: hidden; background: var(--navy-2); }
.field svg { display: block; width: 100%; height: auto; }
.legend { font-size: 12px; color: var(--muted); margin: 6px 2px 0; }

.prompt { font-family: var(--body); text-transform: none; font-size: 21px; font-weight: 700; line-height: 1.3; margin: 18px 0 14px; }
.hint { color: var(--muted); font-size: 15px; margin: -6px 0 0; }
.choices { display: flex; flex-direction: column; gap: 10px; }
.choice { text-align: left; background: var(--card); border: 2px solid var(--line); border-radius: 14px; padding: 14px 16px; font-size: 16px; cursor: pointer; display: flex; gap: 12px; align-items: flex-start; }
.choice .k { font-family: var(--display); font-weight: 600; color: var(--muted); }
.choice:disabled { cursor: default; }
.choice.right { border-color: var(--ok); background: var(--ok-bg); }
.choice.wrong { border-color: var(--no); background: var(--no-bg); }
.choice.dim { opacity: .55; }

.spot { cursor: pointer; }
.spot circle { fill: rgba(246,244,238,.18); stroke: #F6F4EE; stroke-width: 3; stroke-dasharray: 6 5; }
.spot text { fill: #F6F4EE; font: 700 20px var(--display); text-anchor: middle; dominant-baseline: central; pointer-events: none; }
.spot:hover circle, .spot:focus circle { fill: rgba(232,131,58,.35); }
.spot:focus { outline: none; }
.spot.right circle { fill: rgba(47,125,79,.85); stroke: #fff; stroke-dasharray: none; }
.spot.wrong circle { fill: rgba(178,58,46,.85); stroke: #fff; stroke-dasharray: none; }
.spot.dim { opacity: .35; }
.answered .spot { cursor: default; }

.fb { margin-top: 18px; border-radius: 16px; padding: 16px 18px 18px; border: 2px solid; animation: up .2s ease-out; }
.fb.ok { background: var(--ok-bg); border-color: var(--ok); }
.fb.no { background: var(--no-bg); border-color: var(--no); }
.fb strong { font-family: var(--display); font-size: 22px; text-transform: uppercase; letter-spacing: .5px; }
.fb.ok strong { color: var(--ok); }
.fb.no strong { color: var(--no); }
.fb p { margin: 8px 0 0; }
.fb .ans { font-weight: 700; }
.fb .btn { margin-top: 16px; }
@keyframes up { from { transform: translateY(8px); opacity: 0; } to { transform: none; opacity: 1; } }

/* Results */
.score { text-align: center; padding: 28px 0 8px; }
.score b { display: block; font-family: var(--display); font-size: 72px; line-height: 1; }
.score p { margin: 8px 0 0; color: var(--muted); }
.lookbar { display: block; background: var(--orange); color: var(--navy); text-align: center; font-weight: 700; font-size: 14px; padding: 10px 16px; text-decoration: none; }
.picks li, .shelf li.pick { flex-wrap: wrap; }
.shelf li.pick .name { flex-basis: 100%; }
.pickbtns { display: flex; flex-direction: column; gap: 6px; }
.quiznote { text-align: center; margin: 6px 0 0; }
.missed { background: var(--card); border: 2px solid var(--line); border-radius: 16px; padding: 14px 18px; margin: 20px 0; }
.missed ul { margin: 6px 0 0; padding-left: 20px; }

/* Coach tools */
.pb.tool .badge { background: var(--navy); color: var(--cream); font-size: 24px; }
.tools { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 28px; }
.tools .tool { display: grid; grid-template-columns: auto 1fr; column-gap: 10px; align-items: center; align-content: center; background: var(--card); border: 2px solid var(--line); border-radius: 16px; padding: 12px 14px; min-width: 0; }
.tools .tool:active, .pbrows a:active { transform: scale(.98); }
.tools .tool:first-child { grid-column: 1 / -1; }
.tools .badge { grid-row: span 2; width: 34px; height: 34px; border-radius: 50%; background: var(--navy); color: var(--cream); display: grid; place-items: center; font-size: 16px; }
.tools b { font-family: var(--display); font-size: 17px; line-height: 1.15; color: var(--navy); }
.tools small { color: var(--muted); font-size: 12px; line-height: 1.25; }
.pbrows { background: var(--card); border: 2px solid var(--line); border-radius: 16px; overflow: hidden; margin-bottom: 14px; }
.pbrows a { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-top: 1px solid var(--line); }
.pbrows a:first-child { border-top: 0; }
.pbrows .badge { width: 36px; height: 36px; flex: none; border-radius: 50%; background: var(--orange); color: var(--navy); display: grid; place-items: center; font-family: var(--display); font-weight: 700; font-size: 14px; }
.pbrows b { flex: 1; min-width: 0; font-family: var(--display); font-size: 18px; color: var(--navy); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pbrows small { color: var(--muted); font-size: 13px; white-space: nowrap; }
.toast { background: var(--ok-bg); border: 2px solid var(--ok); color: var(--ok); border-radius: 12px; padding: 10px 14px; font-weight: 600; margin: 0 0 16px; }

/* Builder form */
.fld { display: block; margin-bottom: 16px; }
.fld > span { display: block; font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 6px; }
.fld input, .fld select, .fld textarea, .spotrow input, .signrow input {
  width: 100%; font: inherit; font-size: 16px; color: var(--navy); background: var(--card);
  border: 2px solid var(--line); border-radius: 12px; padding: 12px 14px;
}
.fld input:focus, .fld select:focus, .fld textarea:focus, .spotrow input:focus, .signrow input:focus { outline: none; border-color: var(--orange); }
.fld textarea { resize: vertical; }
.fld select { appearance: none; -webkit-appearance: none; padding-right: 46px; background-image: url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 width=%2716%27 height=%2716%27 viewBox=%270 0 16 16%27%3E%3Cpath d=%27M3 6l5 5 5-5%27 fill=%27none%27 stroke=%27%2314213D%27 stroke-width=%272.6%27 stroke-linecap=%27round%27 stroke-linejoin=%27round%27/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 16px center; background-size: 16px; text-overflow: ellipsis; cursor: pointer; }
.fld .hint { margin: 0; }
.two { display: flex; gap: 12px; }
.two .fld { flex: 1; min-width: 0; }
.seg { display: flex; gap: 8px; }
.seg button { flex: 1; border: 2px solid var(--line); background: var(--card); border-radius: 12px; padding: 10px; font-weight: 700; cursor: pointer; }
.seg button.on { background: var(--navy); border-color: var(--navy); color: var(--cream); }
.builder .field { cursor: crosshair; }
#spots { margin: 12px 0 18px; display: flex; flex-direction: column; gap: 8px; }
.spotrow { display: flex; align-items: center; gap: 8px; }
.spotrow .L { width: 34px; height: 34px; flex: none; border-radius: 50%; display: grid; place-items: center; font-family: var(--display); font-weight: 700; background: var(--line); }
.spotrow .L.on { background: var(--ok); color: #fff; }
.spotrow input { padding: 10px 12px; min-width: 0; }
.link { background: none; border: 0; padding: 6px 4px; font-weight: 700; font-size: 14px; color: var(--kicker); cursor: pointer; white-space: nowrap; }
.link.danger { color: var(--no); }
.agerow { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 10px; margin: 4px 0 6px; }
.err { color: var(--no); font-weight: 600; min-height: 1em; margin: 0 0 12px; }

/* Team grid */
.insight { background: var(--card); border: 2px solid var(--line); border-left: 6px solid var(--orange); border-radius: 14px; padding: 4px 16px 14px; }
.insight p { margin: 10px 0 0; font-size: 15px; }
.grid-wrap { overflow-x: auto; margin-top: 18px; border: 2px solid var(--line); border-radius: 14px; background: var(--card); }
.grid { border-collapse: separate; border-spacing: 0; width: 100%; font-size: 14px; }
.grid th, .grid td { padding: 7px 2px; text-align: center; border-bottom: 1px solid var(--line); }
.grid thead th { font-size: 10px; text-transform: uppercase; letter-spacing: .5px; color: var(--muted); vertical-align: bottom; line-height: 1.2; }
.grid .who { text-align: left; position: sticky; left: 0; z-index: 1; background: var(--card); box-shadow: inset -2px 0 0 var(--line); white-space: nowrap; min-width: 92px; max-width: 120px; overflow: hidden; text-overflow: ellipsis; padding: 7px 8px 7px 10px; font-weight: 700; }
.grid .who small { display: block; font-weight: 400; color: var(--muted); font-size: 11px; }
.grid tr.live .who, .grid tr.live td { background: #FBE6D4; }
.grid tfoot td, .grid tfoot th { font-size: 12px; font-weight: 700; border-bottom: 0; }
.c { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 7px; font-style: normal; font-weight: 700; vertical-align: middle; }
.c.mastered { background: var(--ok); color: #fff; }
.c.learning { background: #F3C9A3; color: var(--kicker); }
.c.new { background: transparent; border: 2px dashed #C9C3B4; }
.grid-legend { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.grid-legend .c { width: 18px; height: 18px; font-size: 11px; border-radius: 5px; margin-left: 8px; }
.grid-legend .c:first-child { margin-left: 0; }

/* Study mode */
.plays li:has(.play-link) { padding: 0; }
.play-link { display: flex; align-items: center; gap: 12px; padding: 12px 0; width: 100%; }
.play-link .chev { flex: none; width: 16px; display: grid; place-items: center; font-size: 0; color: var(--navy); }
.study-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.study-head h1 { flex: 1; font-size: 28px; }
.study-q { font-size: 18px; font-weight: 600; margin: 0; }
.study-a { margin-top: 18px; background: var(--ok-bg); border: 2px solid var(--ok); border-radius: 16px; padding: 16px 18px; }
.study-a .kicker { color: var(--ok); }
.study-a p { margin: 0; }
.study-a .a { font-size: 18px; font-weight: 700; }
.pager { display: flex; gap: 10px; margin-top: 22px; }
.pager > * { flex: 1; }
.pager .btn + .btn { margin-top: 0; }

.fld[hidden] { display: none; }

/* Throwing arm tags and the player profile */
.pill.arm { background: var(--navy); color: var(--cream); }
.pill.added { background: var(--orange); color: var(--navy); }
.pb .count { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.top .who { display: inline-block; margin-top: 14px; color: var(--orange); font-weight: 700; font-size: 14px; text-decoration: none; }

/* Team language */
.fld small.hint { display: block; margin-top: 6px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { border: 2px solid var(--line); background: var(--card); border-radius: 99px; padding: 6px 14px; font: inherit; font-weight: 700; color: var(--navy); cursor: pointer; }

/* Tablets and phones turned sideways: field on the left, question on the right,
   so the answers are on screen without scrolling. */
@media (min-width: 900px) and (orientation: landscape) {
  .wrap.split { max-width: 1100px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 36px; align-items: start; }
  .split .pane-field .field { max-width: calc(100vh - 190px); }
  .split .pane-text { padding-top: 6px; }
  .split .pane-text > .kicker:first-child { margin-top: 0 !important; }
  .split .prompt { margin-top: 0; }
}

/* Player mode: a quiet way back to the coach tools */
.coach-link { display: block; margin-top: 24px; font-size: 14px; color: var(--muted); text-decoration: none; }

/* Pitch picker and pitching-play extras */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips button { border: 2px solid var(--line); background: var(--card); border-radius: 999px; padding: 9px 16px; font-weight: 700; cursor: pointer; color: inherit; }
.chips button.on { background: var(--navy); border-color: var(--navy); color: var(--cream); }
.chips button:disabled { cursor: default; opacity: .75; }
.cnt { background: var(--navy); color: var(--cream); border-radius: 8px; padding: 2px 8px; font-family: var(--display); letter-spacing: 1px; }
.zone-word { fill: rgba(246,244,238,.55); font: 700 14px var(--display); letter-spacing: 2px; text-anchor: middle; }
.zone-tag { fill: #14213D; font: 700 16px var(--display); letter-spacing: 2px; text-anchor: middle; }
.pose-tag { fill: rgba(246,244,238,.6); font: 700 16px var(--display); letter-spacing: 2px; }
.cellhit { fill: transparent; cursor: pointer; }
.cellhit:hover { fill: rgba(232,131,58,.12); }
.cellhit.right { fill: rgba(47,125,79,.22); stroke: #2F7D4F; stroke-width: 6; }
.cellhit.wrong { fill: rgba(178,58,46,.22); stroke: #B23A2E; stroke-width: 6; }
.cellhit.dim { fill: rgba(29,46,82,.5); }
.answered .cellhit { cursor: default; }

/* Levels 2 and 3 */
.level { background: var(--card); border: 2px solid var(--line); border-radius: 16px; padding: 16px; margin-top: 12px; }
.level h3 { margin: 0 0 4px; font-family: var(--display); text-transform: uppercase; letter-spacing: .5px; font-size: 18px; }
.level > p { margin: 0 0 10px; color: var(--muted); font-size: 14px; }
.level .btn { margin-top: 10px; }
.level.locked { opacity: .75; }
.level .lock { font-weight: 600; color: var(--navy); margin: 0; }
.level .lock::before { content: '🔒 '; }
.unknown { width: 30px; height: 30px; flex: none; border-radius: 50%; display: grid; place-items: center; background: var(--orange); color: #fff; font-family: var(--display); font-size: 20px; }
.timer { height: 6px; background: rgba(246,244,238,.2); }
.timer i { display: block; height: 100%; width: 100%; background: var(--orange); transform-origin: left; animation: timer linear forwards; }
.timer.stopped i { animation-play-state: paused; }
@keyframes timer { from { transform: scaleX(1); } to { transform: scaleX(0); } }
.copy-hint { background: #FDF0E4; border: 2px solid var(--orange); border-radius: 12px; padding: 10px 14px; margin: 0 0 16px; }
.others summary { display: flex; align-items: center; justify-content: space-between; gap: 10px; list-style: none; cursor: pointer; padding: 10px 0 14px; }
.others summary::-webkit-details-marker { display: none; }
.others summary .kicker { margin: 0; }
.flips { margin-top: 12px; }
.flips summary { display: flex; align-items: center; justify-content: space-between; gap: 10px; list-style: none; font-weight: 700; color: var(--navy); cursor: pointer; padding: 6px 0; }
.flips summary::-webkit-details-marker { display: none; }
.flips li.off .t { text-decoration: line-through; color: var(--muted); }

/* Playbooks (coach) */
.shelf { list-style: none; padding: 0; margin: 0; }
.shelf li { display: flex; align-items: center; gap: 10px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.shelf .badge { width: 40px; height: 40px; flex: none; border-radius: 50%; background: var(--orange); color: var(--navy); display: grid; place-items: center; font-family: var(--display); font-weight: 700; font-size: 15px; }
.shelf .name { flex: 1; min-width: 0; color: inherit; text-decoration: none; }
.shelf .name b { display: block; }
.shelf .name small { color: var(--muted); font-size: 13px; }
.shelf .move { display: flex; flex-direction: column; }
.shelf .move .link { padding: 2px 6px; font-size: 12px; }
.shelf .link:disabled { opacity: .25; cursor: default; }
.shelf li.off .badge { background: var(--line); color: var(--muted); }
.shelf li.off .name b { color: var(--muted); }
.book .plays { margin-top: 10px; }
.book .plays li { flex-wrap: wrap; gap: 4px 10px; }
.book .plays .t { flex-basis: 100%; }
.book .plays li.moveto { display: block; background: var(--card); padding: 12px; border-radius: 12px; }
.delbook { margin-top: 32px; background: var(--card); border: 2px solid var(--no); border-radius: 16px; padding: 16px; }
.delbook p { margin: 0 0 12px; }
.btn.danger { border-color: var(--no); color: var(--no); }
.key { margin: 14px 0 0; padding-left: 26px; font-size: 14px; color: var(--muted); }
.key li { break-inside: avoid; margin-bottom: 4px; }

/* Teams */
.joinrow { display: flex; gap: 8px; }
.joinrow input { flex: 1; min-width: 0; text-transform: uppercase; letter-spacing: 2px; font-weight: 700; }
.joinrow .btn { width: auto; padding: 10px 22px; font-size: 18px; }
.onteam { margin: 0 0 12px; }
.c.na { background: transparent; color: #C9C3B4; }
.joincode { background: var(--card); border: 2px solid var(--line); border-left: 6px solid var(--orange); border-radius: 14px; padding: 4px 16px 14px; margin-top: 18px; }
.joincode .code { font-family: var(--display); font-size: 34px; letter-spacing: 6px; margin: 6px 0; }
.row2 { display: flex; gap: 8px; align-items: center; }
.row2 input { flex: 1; min-width: 0; }
.row2 .btn { width: auto; padding: 10px 16px; font-size: 16px; margin: 0; }
.btn.small { width: auto; padding: 6px 12px; font-size: 14px; margin: 0; }
.fld select.small { width: auto; padding: 6px 10px; font-size: 14px; border-radius: 10px; }
.joincode .btn { margin-bottom: 4px; }
#level button { padding: 10px 4px; font-size: 15px; white-space: nowrap; }

/* Assignments */
.assigned { background: var(--card); border: 2px solid var(--orange); border-radius: 18px; padding: 14px 18px 16px; margin-bottom: 14px; }
.assigned .when { margin: 0 0 2px; font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; color: var(--kicker); }
.assigned.late .when { color: var(--no); }
.assigned.done { border-color: var(--ok); }
.assigned.done .when { color: var(--ok); }
.assigned.done .meter i { background: var(--ok); }
.assigned h2 { font-size: 20px; margin: 0 0 10px; }
.assigned .count { margin-top: 6px; font-size: 13px; color: var(--muted); }
.assigned .btn { margin: 12px 0 0; }
/* Roster: the positions a player plays, one even row */
.shelf li.player { flex-direction: column; align-items: stretch; gap: 0; padding: 0; }
.popen { display: grid; grid-template-columns: 1fr auto; align-items: center; column-gap: 10px; width: 100%; padding: 12px 0; background: none; border: 0; font: inherit; text-align: left; cursor: pointer; }
.popen b, .popen small { grid-column: 1; }
.popen small { font-weight: 700; color: var(--navy) !important; }
.popen small.none { font-weight: 400; color: var(--muted) !important; }
.popen .tog { grid-column: 2; grid-row: 1 / 3; }
/* Open/close: a round button, its arrow turning down when open */
.tog { flex: none; width: 32px; height: 32px; border-radius: 50%; border: 2px solid var(--line); background: var(--card); display: grid; place-items: center; color: var(--navy); transition: transform .15s; }
.tog::before, .play-link .chev::before { content: ""; width: 8px; height: 8px; border: solid currentColor; border-width: 0 3px 3px 0; transform: translateX(-2px) rotate(-45deg); }
li.player.open .tog, details[open] > summary .tog { transform: rotate(90deg); background: var(--navy); border-color: var(--navy); color: var(--cream); }
.pmore { display: none; padding-bottom: 12px; }
li.player.open .pmore { display: block; }
.pfoot { display: flex; align-items: center; justify-content: space-between; margin-top: 10px; }
.pfoot small { color: var(--muted); font-size: 13px; }
.posgrid { display: grid; grid-template-columns: repeat(9, minmax(0, 1fr)); gap: 4px; }
.posgrid button { border: 2px solid var(--line); background: var(--card); color: var(--muted); border-radius: 10px; padding: 8px 0; font: inherit; font-size: 13px; font-weight: 700; text-align: center; cursor: pointer; }
.posgrid button.on { background: var(--navy); border-color: var(--navy); color: var(--cream); }
.assignform { background: var(--card); border: 2px solid var(--line); border-radius: 14px; padding: 4px 16px 14px; margin-top: 4px; }
.assignform #alevel { margin-bottom: 16px; }
.assignform #alevel button { padding: 10px 4px; font-size: 15px; white-space: nowrap; }
#apick { margin: -6px 0 16px; display: flex; flex-wrap: wrap; gap: 4px 16px; }
#apick[hidden] { display: none; }
.check { display: flex; align-items: center; gap: 6px; font-size: 15px; padding: 4px 0; }
.check input { width: 20px; height: 20px; }
.rule { margin-bottom: 14px; }
.signrow { border-bottom: 2px solid var(--line); }
.signsum { display: grid; grid-template-columns: 1fr auto; align-items: center; column-gap: 10px; width: 100%; padding: 10px 0; background: none; border: 0; font: inherit; color: var(--navy); text-align: left; cursor: pointer; }
.signsum b, .signsum small { grid-column: 1; }
.signsum small { color: var(--muted); }
.signsum small.by { font-size: 12px; margin-top: 2px; }
.signsum small.by .pill { padding: 1px 7px; font-size: 10px; }
.signsum .tog { grid-column: 2; grid-row: 1 / 4; }
.signrow.open .tog { transform: rotate(90deg); background: var(--navy); border-color: var(--navy); color: var(--cream); }
.signedit { display: none; grid-template-columns: 1fr auto; gap: 8px; padding-bottom: 14px; }
.signrow.open .signedit { display: grid; }
.signedit .s-how { grid-column: 1 / -1; }
#rows + .btn { margin-top: 14px; }
.iconbtn { width: 48px; border: 2px solid var(--line); border-radius: 12px; background: var(--card); color: var(--navy); font-size: 22px; cursor: pointer; }
.rule .hint { display: block; margin: 0 0 0 26px; }
.filter { font-size: 14px; color: var(--muted); margin: -4px 0 12px; }
.filter .link { padding: 4px 0 4px 4px; }
.assignform .hint { margin: 10px 0 0; }

/* New version saved in the background (sw.js). */
.update { position: fixed; left: 16px; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); max-width: 528px; margin: 0 auto; z-index: 20;
  background: var(--navy); color: var(--cream); border: 0; border-radius: 12px; padding: 14px 16px; font: inherit; font-weight: 600; box-shadow: 0 4px 16px rgba(0,0,0,.25); cursor: pointer; }
#teamnote:empty { display: none; }

/* Privacy notice and agreeing to it */
.prose h2 { font-size: 19px; margin: 26px 0 8px; }
.prose p, .prose li { font-size: 16px; line-height: 1.5; }
.prose p { margin: 0 0 10px; }
.prose ul { padding-left: 20px; margin: 0 0 12px; }
.prose li { margin: 5px 0; }
.agree { background: var(--card); border: 2px solid var(--orange); border-radius: 14px; padding: 12px 14px; margin: 0 0 14px; }
.agree p { margin: 0 0 10px; }
.check.consent { align-items: flex-start; gap: 10px; margin-top: 10px; line-height: 1.4; }
.check.consent input { flex: none; margin-top: 1px; }
.check.consent a, .agree a, .note a { color: var(--kicker); text-decoration: underline; }
