:root {
  --navy: #1f4d36;
  --navy-2: #2f6b4a;
  --ink: #1b1f2a;
  --muted: #667085;
  --line: #e0e8e1;
  --bg: #f4f7f3;
  --card: #ffffff;
  --g1: #2f7d4f;
  --g2: #7a9a3a;
  --g3: #3e8e7e;
  --g4: #d97706;
  --danger: #c0392b;
  --radius: 10px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 15px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif; color: var(--ink); background: var(--bg); }
a { color: var(--navy-2); }
h1 { font-size: 1.6rem; margin: 0 0 .25rem; }
h2 { font-size: 1.15rem; margin: 0 0 .75rem; }
h3 { font-size: .95rem; margin: .75rem 0 .35rem; }
main { max-width: 1440px; margin: 0 auto; padding: 20px 16px 60px; }
main.wide { max-width: none; }
.muted { color: var(--muted); }
.tiny { font-size: .78rem; }
.strong { font-weight: 600; }
.center { text-align: center; }
.mono { font-family: ui-monospace, Consolas, monospace; font-size: .85rem; }
.private { color: var(--danger); font-weight: 600; }
.crumbs { margin: 0 0 .25rem; font-size: .85rem; }

/* top bar */
.topbar { display: flex; align-items: center; gap: 20px; padding: 8px 16px; background: var(--navy); color: #fff; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 8px; color: #fff; text-decoration: none; font-weight: 800; letter-spacing: .06em; }
.brand img { background: #fff; border-radius: 50%; }
.topbar nav { display: flex; gap: 4px; flex: 1; flex-wrap: wrap; }
.topbar nav a { color: #dcebdf; text-decoration: none; padding: 6px 12px; border-radius: 6px; }
.topbar nav a.on, .topbar nav a:hover { background: rgba(255,255,255,.14); color: #fff; }
.who { display: flex; align-items: center; gap: 8px; font-size: .85rem; margin: 0; }
.who .role { background: rgba(255,255,255,.18); border-radius: 99px; padding: 1px 8px; text-transform: capitalize; }
.who .link { color: #fff; }

/* controls */
input, select, textarea, button { font: inherit; color: inherit; }
input, select, textarea { border: 1px solid #ccd8ce; border-radius: 7px; padding: 7px 9px; background: #fff; max-width: 100%; }
textarea { width: 100%; resize: vertical; }
button { border: 1px solid #ccd8ce; background: #fff; border-radius: 7px; padding: 7px 14px; cursor: pointer; }
button:hover { border-color: var(--navy-2); }
button.primary { background: var(--navy); border-color: var(--navy); color: #fff; }
button.primary:hover { background: var(--navy-2); }
a.button { display: inline-block; border: 1px solid #ccd8ce; background: #fff; border-radius: 7px; padding: 7px 14px; text-decoration: none; color: inherit; }
a.button.primary { background: var(--navy); border-color: var(--navy); color: #fff; }
a.button.primary:hover { background: var(--navy-2); }
.inline-label { flex-direction: column; gap: 0; font-weight: 400; }
button.small { padding: 4px 10px; font-size: .85rem; }
button.link { border: 0; background: none; padding: 0; color: var(--navy-2); text-decoration: underline; font-size: inherit; }
button.link.danger { color: var(--danger); }
label { display: flex; flex-direction: column; gap: 4px; font-weight: 600; font-size: .9rem; }
.row { display: flex; gap: 8px; align-items: center; }
.row.wrap { flex-wrap: wrap; }
.row.spread { justify-content: space-between; }
.row label { flex-direction: row; align-items: center; }
.stack { display: flex; flex-direction: column; gap: 12px; }
form.inline { display: inline; margin: 0; }
.flash { background: #eef6ff; border: 1px solid #c7defa; padding: 10px 14px; border-radius: var(--radius); }
.error { color: var(--danger); font-weight: 600; }

/* layout bits */
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 16px; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; margin: 0; }
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; margin-bottom: 16px; }
details.panel > summary { cursor: pointer; display: flex; gap: 10px; align-items: center; }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 800px) { .two-col { grid-template-columns: 1fr; } }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 16px; overflow-x: auto; }
.tabs a { padding: 8px 14px; text-decoration: none; color: var(--muted); border-bottom: 2px solid transparent; white-space: nowrap; }
.tabs a.on { color: var(--navy); border-color: var(--navy); font-weight: 600; }

/* badges */
.badge { display: inline-block; padding: 2px 9px; border-radius: 99px; font-size: .78rem; font-weight: 600; white-space: nowrap; background: #eef0f5; color: #475069; }
.badge.g1 { background: #e1efe4; color: var(--g1); }
.badge.g2 { background: #efe6ff; color: var(--g2); }
.badge.g3 { background: #ddf6ec; color: var(--g3); }
.badge.g4 { background: #fdf0d9; color: #a85b00; }
.badge.perf { background: #e7f0e8; color: var(--navy-2); }
.badge.dev { background: #e9f6ef; color: #237a52; }
.badge.none { background: #f1f1f1; color: #888; }
.status { display: inline-block; padding: 1px 8px; border-radius: 5px; font-size: .78rem; background: #f0f1f4; white-space: nowrap; }
.s-ready-to-generate { background: #fff4d6; }
.s-generated { background: #e1efe4; }
.s-shared-with-player { background: #ddf6ec; color: #136c48; }
.s-n-a { color: #999; }

/* groups */
.group-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 14px; }
@media (max-width: 800px) { .group-cards { grid-template-columns: repeat(2, 1fr); } }
.group-card { background: #fff; border: 1px solid var(--line); border-top: 4px solid; border-radius: var(--radius); padding: 12px 14px; text-decoration: none; color: inherit; }
.group-card.g1 { border-top-color: var(--g1); } .group-card.g2 { border-top-color: var(--g2); }
.group-card.g3 { border-top-color: var(--g3); } .group-card.g4 { border-top-color: var(--g4); }
.group-card.on { box-shadow: 0 0 0 2px var(--navy-2); }
.gc-top { display: flex; justify-content: space-between; align-items: baseline; gap: 6px; flex-wrap: wrap; font-size: .9rem; }
.gc-count { font-size: 1.8rem; font-weight: 700; }
.gc-coaches { font-size: .8rem; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; margin-bottom: 14px; }
.chip { padding: 4px 12px; border-radius: 99px; border: 1px solid var(--line); background: #fff; text-decoration: none; color: inherit; font-size: .85rem; }
.chip.on { background: var(--navy); border-color: var(--navy); color: #fff; }
.chips .count { margin-left: auto; }
.chips .sep { width: 1px; align-self: stretch; background: var(--line); margin: 0 4px; }
.new-camp summary { cursor: pointer; color: var(--navy-2); font-weight: 600; }
.new-camp form { margin-top: 10px; }
.table-scroll { overflow-x: auto; }
table.data.db td { vertical-align: middle; }
table.data input.cell, table.data select.cell { border-color: transparent; background: transparent; padding: 4px 6px; }
table.data input.cell:hover, table.data select.cell:hover { border-color: #ccd8ce; }
table.data input.cell:focus { border-color: var(--navy-2); background: #fff; outline: none; }
table.data input[type=email].cell { min-width: 210px; }
table.data input[type=url].cell { min-width: 170px; }
.folder-cell { white-space: nowrap; }
input.attendance { display: block; margin-top: 2px; width: 140px; color: var(--muted); }
.profile-actions .spacer { flex: 1; }
.profile-actions button { margin-left: 0; }
a.button.google { display: inline-flex; align-items: center; gap: 10px; justify-content: center; width: 100%; padding: 10px 14px; font-weight: 600; margin: 8px 0; }
.dev-login { margin-top: 18px; padding-top: 14px; border-top: 1px dashed var(--line); }
.status-ok { color: #136c48; font-weight: 600; }

/* tables */
table.data { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
table.data th, table.data td { padding: 9px 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
table.data th { background: #f8faf8; font-size: .8rem; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); }
table.data.compact th, table.data.compact td { padding: 6px 10px; }
.history { white-space: nowrap; }
.hist { display: inline-flex; flex-direction: column; align-items: flex-start; margin-right: 8px; opacity: .8; }
.hist.on { opacity: 1; }
.notes-cell { min-width: 240px; max-width: 420px; }
.latest-note { display: flex; flex-direction: column; margin-bottom: 4px; }
.clamp { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.quick-note summary { cursor: pointer; color: var(--navy-2); font-size: .82rem; }
.quick-note form { display: flex; flex-direction: column; gap: 6px; margin-top: 6px; align-items: flex-start; }


/* notes */
.note-form { display: flex; flex-direction: column; gap: 8px; margin-bottom: 12px; align-items: flex-start; }
.notes { list-style: none; margin: 0; padding: 0; }
.notes li { border-left: 3px solid var(--line); padding: 4px 0 4px 10px; margin-bottom: 10px; }
.notes form.inline { margin-left: 8px; }
.notes p { margin: 0 0 2px; white-space: pre-wrap; }
.note-group h3 { color: var(--muted); }
.current { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; }
.field-sections { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px 24px; }
dl { display: grid; grid-template-columns: auto 1fr; gap: 3px 12px; margin: 0; font-size: .9rem; }
dt { color: var(--muted); }
dd { margin: 0; }
dd.long { grid-column: 1 / -1; white-space: pre-wrap; background: #fafcfa; padding: 6px 8px; border-radius: 6px; }

/* camps */
.camp-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.camp-card { text-decoration: none; color: inherit; }
.pills { display: flex; flex-wrap: wrap; gap: 8px; font-size: .85rem; }
.bulk { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.grid-wrap { overflow: auto; max-height: 75vh; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; margin-bottom: 16px; }
table.grid { border-collapse: separate; border-spacing: 0; font-size: .85rem; }
table.grid th, table.grid td { border-bottom: 1px solid var(--line); border-right: 1px solid #f0f1f5; padding: 4px 6px; vertical-align: top; }
table.grid thead th { position: sticky; top: 0; background: #f8faf8; z-index: 2; text-align: left; font-weight: 600; min-width: 80px; }
table.grid .sticky { position: sticky; left: 0; background: #fff; z-index: 1; min-width: 160px; text-align: left; }
table.grid thead .sticky { z-index: 3; background: #f8faf8; }
table.grid input, table.grid select, table.grid textarea { padding: 4px 6px; border-color: transparent; background: transparent; }
table.grid input:hover, table.grid textarea:hover, table.grid select:hover { border-color: #ccd8ce; }
table.grid input:focus, table.grid textarea:focus { border-color: var(--navy-2); background: #fff; outline: none; }
table.grid .wide-col { min-width: 260px; }
table.grid textarea { min-width: 250px; }
table.grid .computed { color: #344; background: #eef3fb; font-weight: 600; }
table.grid thead th.computed { background: #e3ebf8; }
table.grid td.long { min-width: 260px; max-width: 360px; white-space: pre-wrap; }
table.grid .actions { white-space: nowrap; }
.saving { background: #fff9e0 !important; }
.saved { background: #e3f8ec !important; }
.failed { background: #fde8e6 !important; border-color: var(--danger) !important; }

/* login */
.login { max-width: 380px; margin: 8vh auto; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 28px; text-align: center; }
.login form { text-align: left; }
.login input { width: 100%; }

/* profile: mirrors the Google Doc template */
.profile-actions { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; max-width: 816px; margin: 0 auto 12px; }

.profile { background: #fff; max-width: 816px; margin: 0 auto; padding: 48px 56px; box-shadow: 0 2px 14px rgba(0,0,0,.08); font-family: Arial, Helvetica, sans-serif; color: #000; }
.p-head { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; }
.p-head > div { flex: 1; }
.p-head h1 { font-size: 2.1rem; font-weight: 400; margin: 0; }
.p-head p { margin: 2px 0; }
.p-sub { font-size: 1.3rem; }
.p-head hr { border: 0; border-top: 1px solid #999; margin: 12px 0 0; }
.p-logo { width: 130px; height: auto; }
.profile h2 { font-size: 1.25rem; margin: 28px 0 10px; }
.profile h3 { font-size: 1rem; margin: 14px 0 4px; }
.p-text { white-space: pre-wrap; margin: 0 0 10px; }
table.pt { width: 100%; border-collapse: collapse; text-align: center; font-size: .9rem; }
table.pt.narrow { width: 50%; }
table.pt th, table.pt td { border: 2px solid #fff; padding: 6px 4px; }
table.pt thead th { background: #1f4d36; color: #fff; font-weight: 400; font-size: 1rem; }
table.pt thead tr.sub th { font-size: .8rem; }
table.pt tbody td { background: #f2f2f2; }
table.pt tr.strong td { font-weight: 700; }
table.testing tbody th { text-align: right; font-weight: 400; padding-right: 10px; background: #f2f2f2; font-size: .85rem; }
table.testing tr.personal th { font-weight: 700; }
table.testing tr.bench td, table.testing tr.bench th { background: #d9d9d9; }
table.testing tr.b-best td, table.testing tr.b-best th { background: #b3ff66; }
table.testing tr.b-team1 td, table.testing tr.b-team1 th { background: #ffff00; }
table.testing tr.b-perf td, table.testing tr.b-perf th { background: #cfe2f3; }
table.testing tr.b-yours td, table.testing tr.b-yours th { background: #bfbfbf; }
.profile + .profile { margin-top: 24px; }
@media (max-width: 700px) {
  .profile { padding: 20px 16px; }
  .p-logo { width: 72px; }
  .p-head h1 { font-size: 1.5rem; }
  table.pt { font-size: .75rem; }
  table.pt.narrow { width: 100%; }
}

@media print {
  @page { size: letter; margin: 0.5in; }
  body { background: #fff; }
  .no-print, .topbar, .flash { display: none !important; }
  main { padding: 0; max-width: none; }
  .profile { box-shadow: none; padding: 0; max-width: none; }
  .profile + .profile { break-before: page; }
  table.pt th, table.pt td { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}
button.danger-outline { color: var(--danger); border-color: #e7b4ae; }

/* player photos */
.player-head { align-items: center; justify-content: flex-start; }
.player-head .grow, .task-head .grow { flex: 1; }
.player-photo img, .player-photo.none { width: 96px; height: 96px; border-radius: 12px; object-fit: cover; display: block; }
.player-photo.none, .task-photo.none { display: grid; place-items: center; background: #e7f0e8; color: var(--navy-2); font-weight: 700; font-size: 1.3rem; }

/* attendance */
th.att-col, td.att-col { white-space: nowrap; }
select.att { min-width: 110px; }
.att-yes { color: #136c48; }
.att-no { color: var(--danger); }
.att-maybe { color: #a85b00; }
.att-pill { font-size: .8rem; font-weight: 600; }
.import-panel summary { cursor: pointer; color: var(--navy-2); font-weight: 600; }
.import-panel form { margin: 10px 0; }
.wide-input { min-width: 320px; flex: 1; }
tr.imp-close td { background: #fff9e8; }
tr.imp-new td { background: #fdeeee; }

/* my tasks */
.task-summary { margin-bottom: 14px; color: var(--muted); }
.task-summary .big { font-size: 1.6rem; font-weight: 700; color: var(--ink); }
.task-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(420px, 1fr)); gap: 14px; }
@media (max-width: 700px) { .task-list { grid-template-columns: 1fr; } }
.task-head { display: flex; gap: 12px; align-items: center; margin-bottom: 8px; }
.task-head h3 { margin: 0 0 4px; font-size: 1.05rem; }
.task-section { margin-bottom: 22px; }
.role-help { margin: 8px 0 0; padding-left: 18px; }
.task-photo, .task-photo.none { width: 56px; height: 56px; border-radius: 10px; object-fit: cover; font-size: 1rem; }
.checklist { list-style: none; padding: 0; margin: 8px 0; }
.checklist li { display: flex; gap: 8px; align-items: center; padding: 3px 0; }
.checklist .box { width: 18px; height: 18px; border: 2px solid #b7c8bb; border-radius: 4px; display: grid; place-items: center; font-size: .75rem; color: #fff; }
.checklist li.done { color: var(--muted); text-decoration: line-through; }
.checklist li.done .box { background: #1f9d6b; border-color: #1f9d6b; }
.task-field { margin: 8px 0; font-weight: 600; }
.staff-note { background: #fff6e5; padding: 6px 8px; border-radius: 6px; }
.done-list li { margin: 4px 0; }
.lock { font-size: .8rem; }
button:disabled { opacity: .45; cursor: not-allowed; }
.aka { margin-top: 4px; display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.inactive-panel summary { cursor: pointer; font-weight: 600; color: var(--muted); }
.inactive-panel tr td { opacity: .8; }

/* evaluations */
.eval-form { margin: 10px 0; border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; background: #fbfdfb; }
.eval-form summary { cursor: pointer; font-weight: 600; }
.eval-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 10px; margin-top: 6px; }
.eval-grid fieldset { border: 0; padding: 0; margin: 0; }
.eval-grid legend { font-size: .78rem; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); margin-bottom: 4px; }
.eval-grid label { flex-direction: row; justify-content: space-between; align-items: center; font-weight: 400; font-size: .85rem; gap: 6px; margin-bottom: 3px; }
.eval-grid select { width: 64px; padding: 3px 4px; font-size: .85rem; text-align: center; }
.eval-grid select.legacy { border-color: #e0b44b; background: #fff8e6; }
.eval-grid { grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
.eval-host { margin-top: 12px; }
.eval-table th.sec, .eval-overview th.sec { text-align: center; background: #eef4ef; }
.eval-table td.center, .eval-table th.center, .eval-overview .center { text-align: center; }
.eval-table .avg-row td { font-weight: 700; background: #f2f6f2; }
.eval-overview .player-row th, .eval-overview .player-row td { background: #f2f6f2; border-top: 2px solid var(--line); }
.eval-overview .coach-row th { font-weight: 400; padding-left: 16px; }
.eval-overview td.missing, .eval-overview span.missing { color: var(--danger); font-weight: 700; }

/* score guide tooltip */
.scale-tip { position: relative; display: inline-block; color: var(--navy-2); cursor: help; font-weight: 600; white-space: nowrap; outline: none; }
.scale-tip-box { display: none; position: absolute; z-index: 20; left: 0; top: calc(100% + 6px); min-width: 230px; padding: 8px 10px; background: #1b1f2a; color: #fff; border-radius: 8px; box-shadow: 0 6px 18px rgba(0,0,0,.18); font-weight: 400; font-size: .8rem; line-height: 1.5; white-space: normal; text-align: left; }
.scale-tip-box span { display: block; }
.scale-tip:hover .scale-tip-box, .scale-tip:focus .scale-tip-box, .scale-tip:focus-within .scale-tip-box { display: block; }
.trial-switch select { font-size: .85rem; padding: 3px 6px; margin-bottom: 4px; }
.checklist li.manual label { flex-direction: row; align-items: center; gap: 8px; font-weight: 600; font-size: inherit; }
.checklist li.manual input { width: 18px; height: 18px; margin: 0; accent-color: #1f9d6b; }
.checklist li.manual input:disabled + * , .checklist li.manual input:disabled { cursor: not-allowed; }

/* profile endurance chart */
.p-chart { margin: 4px 0 0; }
.p-chart svg { width: 100%; height: auto; display: block; }
.p-legend { display: flex; gap: 18px; flex-wrap: wrap; font-size: .82rem; margin-top: 4px; }
.p-legend i { display: inline-block; width: 18px; height: 3px; margin-right: 6px; vertical-align: middle; }

/* profile template editor */
.tpl-layout { display: grid; grid-template-columns: minmax(320px, 440px) 1fr; gap: 18px; align-items: start; }
@media (max-width: 900px) { .tpl-layout { grid-template-columns: 1fr; } }
.tpl-editor { display: flex; flex-direction: column; gap: 10px; }
.tpl-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; }
.tpl-row { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; }
.tpl-row.off { opacity: .55; }
.tpl-row p { margin: 2px 0 6px; }
.tpl-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.tpl-on { flex-direction: row; align-items: center; gap: 6px; font-weight: 400; }
.tpl-move { display: flex; gap: 4px; }
.tpl-field { font-weight: 600; font-size: .82rem; margin-top: 4px; }
.tpl-field input, .tpl-field textarea { width: 100%; font-weight: 400; }
.tpl-bench { border: 0; padding: 0; margin: 6px 0 0; display: flex; flex-wrap: wrap; gap: 4px 14px; }
.tpl-bench label { flex-direction: row; gap: 4px; font-weight: 400; }
.tpl-preview { position: sticky; top: 10px; }
.tpl-frame { width: 100%; height: 82vh; border: 1px solid var(--line); border-radius: 10px; background: #f4f7f3; margin-top: 8px; }
.preview-pad { padding: 16px; }
.eval-box { border-left: 4px solid var(--navy-2); }
.eval-box h3 { margin-top: 0; font-size: 1.05rem; }
.eval-box > p { margin: 0 0 8px; }
.profile h3.p-subhead { font-size: 1.02rem; margin: 18px 0 8px; color: #1b1f2a; }
.tpl-row.is-sub { margin-left: 22px; border-left: 3px solid var(--line); }
.tpl-sub { gap: 6px; font-weight: 400; margin-bottom: 2px; }
.requests { border-left: 4px solid #e0a020; }
.email-cell input { display: block; }
table.data input.cell.alt { font-size: .8rem; color: var(--muted); margin-top: 2px; }

/* evaluation table: tabs, frozen Coach + Overall, final score */
.eval-tabs { display: flex; gap: 4px; margin: 6px 0; }
.eval-tabs button { padding: 4px 12px; font-size: .82rem; border-radius: 99px; }
.eval-tabs button.on { background: var(--navy); color: #fff; border-color: var(--navy); }
.eval-table .fz { position: sticky; background: #fff; z-index: 1; }
.eval-table thead .fz { background: #f8faf8; z-index: 2; }
.eval-table .fz1 { left: 0; min-width: 150px; }
.eval-table .fz2 { left: 150px; min-width: 70px; border-right: 2px solid var(--line); }
.eval-table .avg-row .fz { background: #f2f6f2; }
.eval-table td.override { background: #fff6e0; }
.eval-table td select { padding: 2px 4px; font-size: .82rem; }
/* photo pop-up */
#lightbox { border: 0; padding: 0; background: transparent; max-width: 92vw; max-height: 92vh; }
#lightbox::backdrop { background: rgba(10, 12, 20, .75); }
#lightbox img { display: block; max-width: 92vw; max-height: 88vh; border-radius: 10px; }
#lightbox .lb-close { position: absolute; top: 6px; right: 6px; background: rgba(0,0,0,.6); color: #fff; border: 0; font-size: 1.4rem; line-height: 1; padding: 4px 10px; border-radius: 99px; }
/* locked fields */
[data-lockable] textarea[readonly] { background: #f6f8f5; color: var(--ink); }
main { max-width: 1440px; }
.inline-edit { display: inline-block; margin-left: 8px; }
.inline-edit summary { display: inline; cursor: pointer; color: var(--navy-2); text-decoration: underline; }
.inline-edit[open] { display: block; margin: 6px 0; }
.inline-edit form { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; margin-top: 4px; }

/* player page */
.details-edit { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: flex-end; margin: 4px 0; }
.details-edit label { font-weight: 400; color: var(--muted); }
.details-edit input { min-width: 200px; }
.trial-panel .compare { margin: 10px 0 14px; }
.trial-panel .compare h3 { margin: 0 0 6px; }
.trial-panel .compare textarea { width: 100%; }
td.cmp-better { color: #136c48; }
td.cmp-worse { color: var(--danger); }
td.cmp-better-bg { background: #eaf8f0; }
td.cmp-worse-bg { background: #fdeeee; }

/* analytics */
.bars-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px 24px; margin-top: 14px; }
.bars h4 { margin: 0 0 6px; font-size: .9rem; }
.bar-row { display: grid; grid-template-columns: 62px 1fr 48px; align-items: center; gap: 6px; font-size: .8rem; margin: 3px 0; }
.bar-track { background: #f1f5f1; border-radius: 4px; height: 12px; overflow: hidden; }
.bar { display: block; height: 100%; border-radius: 4px; }
.bar-val { text-align: right; font-weight: 600; }
.standouts { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px 24px; }
.standouts h4 { margin: 0 0 4px; font-size: .9rem; }
.standouts ol { margin: 0; padding-left: 18px; font-size: .85rem; }
td.ai-comment { min-width: 280px; max-width: 420px; color: #39404f; }
.camp-groups { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px 24px; }
.camp-groups ul { margin: 0; padding-left: 18px; }
.att-sum { background: #f1f5f1; padding: 4px 10px; border-radius: 99px; }

/* sortable tables */
table[data-sortable] thead th:not([data-nosort]) { cursor: pointer; user-select: none; }
table[data-sortable] thead th:not([data-nosort]):hover { background: #eef4ef; }
table[data-sortable] thead th[data-sorted="asc"]::after { content: " ▲"; font-size: .7em; }
table[data-sortable] thead th[data-sorted="desc"]::after { content: " ▼"; font-size: .7em; }

button.xs { padding: 2px 8px; font-size: .75rem; white-space: nowrap; }
button[hidden] { display: none; }

/* My tasks, on the right of the header */
.tasks-link { color: #dcebdf; text-decoration: none; padding: 6px 12px; border-radius: 6px; display: inline-flex; align-items: center; gap: 6px; }
.tasks-link.on, .tasks-link:hover { background: rgba(255,255,255,.14); color: #fff; }
.tasks-link .count { background: #f59e0b; color: #1b1f2a; border-radius: 99px; min-width: 20px; padding: 0 6px; font-size: .75rem; font-weight: 700; text-align: center; line-height: 20px; }
.tasks-link .count.zero { background: rgba(255,255,255,.18); color: #dcebdf; }

/* view as coach */
.view-as select { background: rgba(255,255,255,.12); color: #fff; border: 1px solid rgba(255,255,255,.3); border-radius: 6px; padding: 4px 8px; font-size: .85rem; }
.view-as option { color: #1b1f2a; }
.viewing-as { background: #fff4d6; border-bottom: 1px solid #f0d38a; margin: 0; padding: 8px 16px; font-size: .9rem; display: flex; align-items: center; justify-content: center; gap: 12px; flex-wrap: wrap; }
.viewing-as form { margin: 0; }
form.inline { display: inline; }

/* Evaluations page: big tabs on the same row as the group filter */
.eval-topbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; border-bottom: 1px solid var(--line); margin-bottom: 18px; }
.big-tabs { display: flex; gap: 6px; }
.big-tabs a { padding: 12px 20px; font-size: 1.05rem; font-weight: 600; text-decoration: none; color: var(--muted); border-bottom: 3px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.big-tabs a:hover { color: var(--navy); }
.big-tabs a.on { color: var(--navy); border-color: var(--navy); }
select.trial-switch { margin-bottom: 4px; }

/* status colours */
.s-incomplete { background: #fff4d6; color: #8a5a00; }
.s-complete { background: #e1efe4; color: #2f7d4f; }
.s-shared { background: #ddf6ec; color: #136c48; }
select.status-select { border-radius: 6px; font-weight: 600; }
.group-card.unassigned { border-top-color: #9aa1ad; }
.group-cards { grid-template-columns: repeat(4, 1fr); }
.folder-cell .button.small { display: inline-block; padding: 3px 10px; font-size: .8rem; white-space: nowrap; }
.folder-edit summary { cursor: pointer; color: var(--muted); margin-top: 4px; }
.folder-edit[open] summary { margin-bottom: 4px; }
button.link:disabled { color: #a3a8b3; text-decoration: none; cursor: not-allowed; }

/* top bar: keep everything on one centred line */
.topbar { align-items: center; }
.topbar nav, .topbar .tasks-link, .topbar .view-as, .topbar .who { align-self: center; }
.topbar .view-as { margin: 0; display: flex; align-items: center; }
.topbar .view-as select { height: 32px; }
.topbar .tasks-link { height: 32px; box-sizing: border-box; }

/* player page header card */
.player-card { display: flex; gap: 20px; align-items: flex-start; }
.player-card .player-photo { flex: none; }
.player-title { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.player-title h1 { margin: 0 6px 0 0; }
.chip-static { background: #f1f5f1; border-radius: 99px; padding: 2px 10px; font-size: .8rem; color: var(--muted); }
.player-facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px 18px; margin: 0; }
.player-facts > div { min-width: 0; }
.player-facts .wide { grid-column: 1 / -1; }
.player-facts dt { font-size: .72rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin-bottom: 3px; }
.player-facts dd { margin: 0; overflow-wrap: anywhere; }
.player-facts input, .player-facts select { width: 100%; box-sizing: border-box; min-width: 0; }
@media (max-width: 900px) { .player-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); } .player-card { flex-direction: column; } }

/* collapsible note groups on the player page */
details.note-group > summary { cursor: pointer; list-style: none; display: flex; align-items: center; gap: 6px; padding: 6px 0; border-top: 1px solid var(--line); }
details.note-group > summary::before { content: '▸'; color: var(--muted); }
details.note-group[open] > summary::before { content: '▾'; }
details.note-group > summary::-webkit-details-marker { display: none; }
details.note-group > summary h3 { margin: 0; font-size: 1rem; }

/* evaluation section tabs: look like real tabs */
.eval-tabs { display: flex; gap: 2px; margin: 10px 0 0; border-bottom: 2px solid var(--line); }
.eval-tabs button { padding: 8px 18px; font-size: .9rem; font-weight: 600; border: 1px solid var(--line); border-bottom: none; border-radius: 8px 8px 0 0; background: #f1f5f1; color: var(--muted); margin-bottom: -2px; }
.eval-tabs button:hover { color: var(--navy); background: #e8ecf5; }
.eval-tabs button.on { background: #fff; color: var(--navy); border-color: var(--line); border-top: 3px solid var(--navy); border-bottom: 2px solid #fff; }
/* comparison table numbers centred */
.compare td.center, .compare th.center, table.data td.center, table.data th.center { text-align: center; }

/* ---- sidebar layout ---- */
.shell { display: flex; min-height: 100vh; }
.nav-toggle { display: none; }
.sidebar { width: 236px; flex: none; position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; background: linear-gradient(180deg, #1f4d36 0%, #0d1a47 100%); color: #dcebdf; padding: 18px 12px; box-sizing: border-box; overflow-y: auto; z-index: 20; }
.sb-top { display: flex; align-items: center; justify-content: space-between; padding: 0 8px 18px; border-bottom: 1px solid rgba(255,255,255,.1); }
.sidebar .brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; font-weight: 800; font-size: 1.15rem; letter-spacing: .02em; }
.sidebar .brand small { display: block; font-weight: 500; font-size: .72rem; color: #9cc4a8; letter-spacing: .04em; text-transform: uppercase; }
.nav-burger { display: none; cursor: pointer; color: #fff; padding: 6px; }
.sb-nav { display: flex; flex-direction: column; gap: 4px; padding: 16px 0; flex: 1; }
.sb-nav a { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; color: #c4dccb; text-decoration: none; font-weight: 500; font-size: .93rem; transition: background .15s, color .15s; }
.sb-nav a:hover { background: rgba(255,255,255,.08); color: #fff; }
.sb-nav a.on { background: #fff; color: var(--navy); font-weight: 700; box-shadow: 0 4px 14px rgba(0,0,0,.18); }
.sb-nav .icon { flex: none; opacity: .9; }
.sb-nav .count { margin-left: auto; background: #f59e0b; color: #1b1f2a; border-radius: 99px; min-width: 22px; padding: 0 7px; font-size: .75rem; font-weight: 700; text-align: center; line-height: 20px; }
.sb-nav .count.zero { background: rgba(255,255,255,.16); color: #dcebdf; }
.sb-nav a.on .count.zero { background: #eef4ef; color: var(--muted); }
.sb-bottom { border-top: 1px solid rgba(255,255,255,.1); padding-top: 14px; display: flex; flex-direction: column; gap: 12px; }
.sb-label { display: block; font-size: .7rem; text-transform: uppercase; letter-spacing: .06em; color: #9cc4a8; margin: 0 4px 4px; }
.sidebar .view-as { margin: 0; display: block; }
.sidebar .view-as select { width: 100%; height: auto; background: rgba(255,255,255,.1); color: #fff; border: 1px solid rgba(255,255,255,.22); border-radius: 8px; padding: 7px 8px; font-size: .85rem; }
.sidebar .view-as option { color: #1b1f2a; }
.sidebar .who { display: flex; align-items: center; gap: 10px; margin: 0; padding: 4px; font-size: .85rem; }
.sidebar .avatar { width: 34px; height: 34px; flex: none; border-radius: 50%; background: #2f4aa8; color: #fff; display: grid; place-items: center; font-weight: 700; font-size: .8rem; }
.sidebar .who-text { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.sidebar .who-text strong { color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sidebar .who .role { background: none; padding: 0; color: #9cc4a8; font-size: .75rem; text-transform: capitalize; }
.sidebar .who .link { color: #c4dccb; padding: 6px; border-radius: 8px; display: grid; place-items: center; }
.sidebar .who .link:hover { background: rgba(255,255,255,.1); color: #fff; }
.content { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.content main { width: 100%; box-sizing: border-box; }
@media (max-width: 900px) {
  .shell { flex-direction: column; }
  .sidebar { width: 100%; height: auto; position: sticky; padding: 10px 12px; }
  .sb-top { padding: 0 4px; border-bottom: none; }
  .nav-burger { display: block; }
  .sb-nav, .sb-bottom { display: none; }
  .nav-toggle:checked + .sidebar .sb-nav, .nav-toggle:checked + .sidebar .sb-bottom { display: flex; }
}
@media print { .sidebar { display: none !important; } }

.role-picker { display: inline-flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.role-picker label { display: inline-flex; gap: 4px; align-items: center; font-weight: 400; white-space: nowrap; }

.sb-nav-bottom { flex: none; padding: 0 0 4px; }

/* In narrow evaluation forms (My tasks cards) Position skills drop below and split into two columns. */
.eval-form { container-type: inline-size; }
@container (max-width: 640px) {
  .eval-grid fieldset.pos-skills { grid-column: 1 / -1; }
  .eval-grid fieldset.pos-skills .skill-items { display: grid; grid-template-columns: 1fr 1fr; column-gap: 18px; }
}

/* quick links + feedback */
.link-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.link-list li { border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; background: #fff; }
.link-card { display: flex; flex-direction: column; gap: 2px; text-decoration: none; }
.link-card strong { color: var(--navy); font-size: 1rem; }
.link-card:hover strong { text-decoration: underline; }
.feedback-list { list-style: none; margin: 0; padding: 0; }
.feedback-list li { border-top: 1px solid var(--line); padding: 10px 0; }
.feedback-list li.done { opacity: .55; }
.feedback-list .pre { white-space: pre-wrap; margin: 0 0 4px; }

/* export all (coach evaluations) */
.export-evals { position: relative; }
.export-evals > summary { list-style: none; cursor: pointer; }
.export-evals > summary::-webkit-details-marker { display: none; }
.export-box { position: absolute; right: 0; top: calc(100% + 6px); z-index: 30; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 10px 30px rgba(31,77,54,.15); padding: 14px; display: flex; flex-direction: column; gap: 8px; width: 260px; }
.export-box label { display: flex; gap: 6px; align-items: center; font-weight: 400; flex-direction: row; }

.share-page { max-width: 1000px; margin: 0 auto; }
.login .button.primary { display: inline-block; margin-top: 8px; background: var(--navy); color: #fff; border-color: var(--navy); }

/* camp page groups board */
.group-board { display: grid; grid-template-columns: repeat(3, minmax(240px, 1fr)); gap: 12px; overflow-x: auto; padding-bottom: 6px; }
.gb-col { background: #f5f8f5; border: 1px solid var(--line); border-top: 4px solid #9aa1ad; border-radius: var(--radius); padding: 10px; min-height: 120px; display: flex; flex-direction: column; }
.gb-col.g1 { border-top-color: var(--g1); } .gb-col.g2 { border-top-color: var(--g2); } .gb-col.g3 { border-top-color: var(--g3); }
.gb-col.gb-out { background: #fbf4f3; border-top-color: #d9a29b; }
.gb-col.drop-on { outline: 2px dashed var(--navy-2); outline-offset: -4px; background: #ecf5ee; }
.gb-col h3 { margin: 0 0 8px; font-size: .95rem; display: flex; justify-content: space-between; align-items: center; }
.gb-count { background: #fff; border: 1px solid var(--line); border-radius: 99px; padding: 0 8px; font-size: .75rem; color: var(--muted); }
.gb-list { display: flex; flex-direction: column; gap: 8px; flex: 1; }
.gb-card { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; box-shadow: 0 1px 2px rgba(31,77,54,.05); }
.gb-card[draggable="true"] { cursor: grab; }
.gb-card.dragging { opacity: .45; }
.gb-top { display: flex; justify-content: space-between; align-items: center; gap: 6px; flex-wrap: wrap; }
.gb-name { font-weight: 600; text-decoration: none; color: var(--ink); }
.gb-name:hover { text-decoration: underline; }
.gb-att { font-size: .75rem; padding: 1px 4px; max-width: 120px; }
.gb-notes { margin: 6px 0 0; padding-left: 16px; font-size: .78rem; color: #39404f; }
.gb-notes li { margin-bottom: 2px; }

.gb-wide { margin-top: 14px; min-height: 80px; }
.gb-list-wide { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 8px; }
.gb-out-list { margin-top: 18px; }
.gb-out-list h3 { display: flex; gap: 8px; align-items: center; font-size: .95rem; }
.drag-handle { color: #9aa1ad; cursor: grab; font-size: 1rem; line-height: 1; user-select: none; margin-right: -2px; }
.gb-card:hover .drag-handle { color: var(--navy-2); }
.gb-top .gb-name { flex: 1; }
.past-group { margin-bottom: 16px; }
.past-group h3 { font-size: .95rem; margin: 10px 0 6px; }
/* camp workspace cards */
.section-title { font-size: 1.05rem; margin: 18px 0 10px; }
.camp-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 12px; }
.camp-card { display: flex; flex-direction: column; gap: 6px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; text-decoration: none; color: inherit; transition: box-shadow .15s, transform .15s; }
.camp-card:hover { box-shadow: 0 8px 22px rgba(31,77,54,.12); transform: translateY(-1px); }
.camp-card.next { border: 2px solid var(--navy-2); }
.camp-card.past { background: #fbfdfb; }
.cc-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.cc-top strong { font-size: 1.02rem; color: var(--navy); }
.cc-kpis { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: .82rem; color: var(--muted); }
.cc-kpis b { color: var(--ink); font-size: .95rem; }
.cc-groups { display: flex; gap: 6px; flex-wrap: wrap; }
/* camp schedule */
.schedule-day > summary { cursor: pointer; list-style: none; }
.schedule-day > summary::-webkit-details-marker { display: none; }
.schedule-day > summary h3 { display: inline; font-size: 1rem; }
.schedule-day > summary::before { content: '▾ '; color: var(--muted); }
.schedule-day:not([open]) > summary::before { content: '▸ '; }
table.schedule td { vertical-align: top; }
table.schedule tr.sched-head td { background: #eef4ef; font-weight: 700; }
table.schedule tr.sched-sub td:nth-child(2) { padding-left: 22px; color: #39404f; }
table.schedule td.nowrap { white-space: nowrap; }
.schedule-edit { margin-top: 10px; }
textarea.mono { font-family: ui-monospace, Consolas, monospace; font-size: .8rem; }

/* schedule link button */
.schedule-link { display: inline-flex; align-items: center; gap: 14px; padding: 12px 18px; border-radius: 12px; background: linear-gradient(135deg, #1f4d36, #2f6b4a); color: #fff; text-decoration: none; box-shadow: 0 6px 18px rgba(31,77,54,.22); transition: transform .15s, box-shadow .15s, filter .15s; }
.schedule-link:hover { transform: translateY(-2px); box-shadow: 0 10px 26px rgba(31,77,54,.3); filter: brightness(1.08); }
.schedule-link:active { transform: translateY(0); }
.schedule-link .sl-icon { width: 40px; height: 40px; border-radius: 10px; background: rgba(255,255,255,.15); display: grid; place-items: center; }
.schedule-link .sl-text { display: flex; flex-direction: column; }
.schedule-link .sl-text strong { font-size: 1rem; }
.schedule-link .sl-text span { font-size: .78rem; color: #c4dccb; }
.schedule-link .sl-arrow { font-size: 1.2rem; margin-left: 6px; transition: transform .15s; }
.schedule-link:hover .sl-arrow { transform: translate(2px, -2px); }
/* status pill that admins click to change */
.status-pill { border: 1px solid transparent; border-radius: 99px; padding: 2px 10px; font-size: .75rem; font-weight: 600; background: #f1f5f1; white-space: nowrap; }
.status-pill.att-yes { background: #e3f6ee; } .status-pill.att-no { background: #fdecea; } .status-pill.att-maybe { background: #fff4e0; }
button.status-pill { cursor: pointer; }
button.status-pill:hover { border-color: currentColor; }
.status-edit select { font-size: .75rem; padding: 1px 4px; }
/* not coming list starts collapsed */
details.gb-out-list > summary { cursor: pointer; list-style: none; }
details.gb-out-list > summary::-webkit-details-marker { display: none; }
details.gb-out-list > summary h3::before { content: '▸ '; color: var(--muted); }
details.gb-out-list[open] > summary h3::before { content: '▾ '; }
/* inline note editing */
.gb-notes li[data-note] { cursor: text; border-radius: 4px; }
.gb-notes li[data-note]:hover { background: #f5f8f5; }
.note-edit { display: flex; flex-direction: column; gap: 4px; margin-top: 6px; }
.note-edit textarea { width: 100%; box-sizing: border-box; font-size: .8rem; min-height: 54px; }
.note-edit .row { display: flex; gap: 6px; }

.cg-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.cg-head h2 { margin: 0; }
.cg-nav { display: flex; align-items: center; gap: 10px; }
.cg-nav strong { min-width: 150px; text-align: center; }
.button.disabled { opacity: .35; pointer-events: none; }
.sidebar .brand img { object-fit: contain; }

/* camp goals */
#goals { margin-top: 18px; }
.goal-block { border: 1px solid var(--line); border-left: 4px solid var(--navy-2); border-radius: var(--radius); padding: 12px 14px; background: #fff; }
.goal-block.program { background: #f7f9ff; margin-bottom: 12px; }
.goal-block.g1 { border-left-color: var(--g1); } .goal-block.g2 { border-left-color: var(--g2); } .goal-block.g3 { border-left-color: var(--g3); }
.goal-block h3 { margin: 0 0 6px; font-size: .98rem; }
.goal-block ul { margin: 0; padding-left: 20px; }
.goal-block li { margin-bottom: 3px; }
.goal-groups { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.goal-edit summary { cursor: pointer; color: var(--navy-2); margin-top: 6px; }
/* goal tasks on My tasks */
.goal-tasks { margin: 10px 0 22px; }
.goal-tasks h2 { font-size: 1.05rem; }
.goal-task-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 10px; }
.goal-task { display: flex; align-items: center; gap: 10px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; text-decoration: none; color: var(--ink); transition: box-shadow .15s; }
.goal-task:hover { box-shadow: 0 6px 18px rgba(31,77,54,.12); }
.goal-task .sl-arrow { margin-left: auto; color: var(--navy-2); }

/* evaluation pop-up from Coach evaluations */
tr[data-eval-entry] { cursor: pointer; }
tr.player-row[data-eval-entry]:hover th, tr.player-row[data-eval-entry]:hover td, tr.coach-row[data-eval-entry]:hover th, tr.coach-row[data-eval-entry]:hover td { background: #ecf5ee; }
.eval-dialog { width: min(1100px, 94vw); max-height: 90vh; border: 0; border-radius: 14px; padding: 22px 24px; box-shadow: 0 24px 60px rgba(31,77,54,.3); }
.eval-dialog::backdrop { background: rgba(13,26,71,.45); }
.eval-dialog .dialog-close { position: absolute; top: 10px; right: 12px; border: 0; background: none; font-size: 1.6rem; line-height: 1; color: var(--muted); padding: 4px 8px; }
.eval-dialog .dialog-close:hover { color: var(--ink); }
.eval-dialog h3 { margin-top: 0; padding-right: 30px; }

/* snoozing tasks */
.task-head .snooze-form { margin-left: auto; align-self: flex-start; }
.snooze-form button { color: var(--muted); }
.snooze-form button:hover { color: var(--navy-2); }
.goal-task { justify-content: space-between; }
.goal-task-link { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); flex: 1; }
details.snoozed { margin-top: 20px; }
details.snoozed summary { cursor: pointer; font-weight: 600; }
details.snoozed ul { margin: 10px 0 0; padding-left: 18px; }
details.snoozed li { margin-bottom: 6px; }

/* Competition analytics (Qlik embed) */
.qlik-panel { padding: 0; overflow: hidden; position: relative; transform: translateZ(0); /* keeps any full-screen Qlik layer inside the panel */ }
.qlik-panel qlik-embed { display: block; width: 100%; height: 100%; }

.qlik-request { position: relative; }
.qlik-request > summary { list-style: none; cursor: pointer; }
.qlik-request > summary::-webkit-details-marker { display: none; }
.qlik-request form { position: absolute; top: calc(100% + 6px); left: 0; z-index: 30; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 10px 30px rgba(31,77,54,.15); padding: 14px; width: 360px; }

/* Competition analytics fills the height left under its header */
.content:has(.qlik-page) { height: 100vh; }
.content:has(.qlik-page) main { flex: 1; min-height: 0; display: flex; flex-direction: column; padding-bottom: 16px; }
.qlik-page { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.qlik-page .qlik-panel { flex: 1; min-height: 420px; margin-bottom: 0; }
.qlik-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.qlik-head h1 { margin: 0; }
.qlik-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }
.qlik-request form { left: auto; right: 0; }
.button.outline, summary.button.outline { background: #fff; border: 1.5px solid var(--navy); color: var(--navy); font-weight: 600; }
.button.outline:hover, summary.button.outline:hover { background: #eef4ef; }
@media (max-width: 900px) { .content:has(.qlik-page) { height: auto; } .qlik-page .qlik-panel { height: 75vh; flex: none; } }
summary.button { display: inline-block; border: 1px solid #ccd8ce; background: #fff; border-radius: 7px; padding: 7px 14px; cursor: pointer; }

/* The full Qlik client (classic/app) is drawn in an iframe sized to its container; keep it inside the panel. */
.qlik-panel qlik-embed iframe { position: absolute !important; inset: 0 !important; width: 100% !important; height: 100% !important; border: 0; }

.trial-panel > summary { display: flex; align-items: center; gap: 8px; }
.trial-panel > summary .spacer { flex: 1; }
.share-btn { font-size: .78rem; }

/* My tasks header: count by the title, quiet sort/filter controls on the right */
.tasks-head { align-items: center; }
.tasks-head h1 { margin: 0; display: flex; align-items: baseline; gap: 12px; }
.title-count { font-size: .95rem; font-weight: 600; color: var(--navy-2); background: #eef4ef; border-radius: 99px; padding: 2px 12px; }
.task-filters { display: flex; gap: 8px; flex-wrap: wrap; }
.task-filters select { border: 1px solid transparent; background: transparent; color: var(--muted); font-size: .85rem; padding: 4px 6px; border-radius: 6px; cursor: pointer; }
.task-filters select:hover, .task-filters select:focus { border-color: var(--line); background: #fff; color: var(--ink); }
/* Snooze: plain, light, unobtrusive */
.snooze-form button, .snooze-form button.link { color: #a3a8b3; text-decoration: none; font-size: .78rem; }
.snooze-form button:hover { color: var(--muted); text-decoration: none; }

/* skill definitions on hover in the evaluation form */
.skill-tip { position: relative; border-bottom: 1px dotted #9aa1ad; cursor: help; }
.skill-tip:hover::after, .skill-tip:focus::after {
  content: attr(data-tip); position: absolute; left: 0; bottom: calc(100% + 6px); z-index: 40; width: 280px;
  background: #1b1f2a; color: #fff; font-size: .75rem; line-height: 1.4; font-weight: 400; padding: 8px 10px; border-radius: 8px;
  box-shadow: 0 8px 20px rgba(0,0,0,.2); white-space: normal; pointer-events: none;
}
.eval-form > summary .scale-tip { margin-left: 6px; }

/* sidebar: name/avatar opens the profile page */
.sidebar .who-link { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; text-decoration: none; color: inherit; border-radius: 8px; padding: 2px; }
.sidebar .who-link:hover, .sidebar .who-link.on { background: rgba(255,255,255,.08); }
.sidebar img.avatar { object-fit: cover; }
/* profile page */
.me-form { display: flex; gap: 28px; align-items: flex-start; flex-wrap: wrap; }
.me-avatar { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.me-avatar img, .me-avatar span[data-avatar-preview] { width: 112px; height: 112px; border-radius: 50%; object-fit: cover; background: #2f4aa8; color: #fff; display: grid; place-items: center; font-size: 2rem; font-weight: 700; }
.me-avatar label.button { cursor: pointer; }
.me-fields { display: flex; flex-direction: column; gap: 12px; min-width: 260px; flex: 1; max-width: 420px; }
.me-label { display: block; font-size: .72rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin-bottom: 2px; }
.me-fields button { align-self: flex-start; }

.add-details summary { cursor: pointer; color: var(--navy-2); }
.add-details-fields { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 6px; }
.add-details-fields label { display: flex; flex-direction: column; gap: 3px; min-width: 220px; }

/* Evaluations: title on the left, controls together on the right, same spot on every tab */
.eval-head { align-items: center; margin-top: 4px; }
.eval-head h1 { margin: 0; }
.head-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: flex-end; margin-left: auto; }
.head-actions .filters { margin: 0; }
.head-actions .export-evals { margin: 0; }
.bulk-bottom { margin-top: 14px; }
.status-lock { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
.status-lock select:disabled { opacity: 1; cursor: not-allowed; }

/* compact camp details */
.details-panel h2 { margin-bottom: 8px; }
.details-top { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.details-sub { margin: 0 0 6px; font-size: .78rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.details-panel .schedule-link { margin-left: auto; padding: 8px 14px; }
.details-panel .schedule-link .sl-icon { width: 32px; height: 32px; }
.details-panel #goals { margin-top: 14px; }
.details-panel .goal-block { padding: 10px 12px; }
.details-panel .goal-block.program { margin-bottom: 10px; }
.details-panel .goal-block h3 { margin-bottom: 4px; }
.details-panel .goal-edit summary { margin-top: 4px; }
table.grid td.center, table.grid th.center { text-align: center; }

/* analytics group insights */
.insights-title { margin: 22px 0 10px; font-size: 1rem; display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; }
.insights { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 14px; }
.insight { background: #f7f9fc; border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; }
.insight h4 { margin: 0 0 8px; font-size: .9rem; }
.insight ul { margin: 0; padding-left: 18px; font-size: .85rem; }
.insight li { margin-bottom: 6px; }

.camp-head { align-items: center; }
.camp-head h1 { margin: 0; }
.camp-head-right { display: flex; align-items: center; gap: 14px; margin-left: auto; }
.camp-dates { color: var(--muted); font-weight: 500; }

/* testing data styled like the coach evaluations table */
table.testing-grid { font-size: .8rem; }
table.testing-grid thead th { font-size: .78rem; vertical-align: bottom; }
table.testing-grid thead tr:first-child th { top: 0; }
table.testing-grid thead tr:nth-child(2) th { top: 31px; }
table.testing-grid th.sec { text-align: center; background: #eef4ef; color: var(--navy); }
table.testing-grid th.computed { background: #eef3ff; }
table[data-rename] th[data-field-key], table[data-rename] th[data-section] { cursor: pointer; }
table[data-rename] th[data-field-key]:hover, table[data-rename] th[data-section]:hover { text-decoration: underline dotted; }

/* attendance grouped Yes / Maybe / No */
.att-groups { display: flex; gap: 10px; flex-wrap: wrap; }
.att-group { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; padding: 6px 10px; border-radius: 12px; border: 1px solid var(--line); }
.att-group-head { font-size: .85rem; margin-right: 4px; }
.att-group.att-yes { background: #eefaf4; border-color: #c7ecd9; }
.att-group.att-maybe { background: #fff8ec; border-color: #f3dfb6; }
.att-group.att-no { background: #fdf1f0; border-color: #f2cdc8; }
.att-group .att-sum { background: rgba(255,255,255,.8); }
.title-tip { font-weight: 400; vertical-align: middle; margin-left: 6px; }
/* testing grid heading rows */
table.testing-grid thead tr.sec-row th { height: 30px; box-sizing: border-box; top: 0; }
table.testing-grid thead tr:nth-child(2) th { top: 30px; }
table.testing-grid thead th.blank { background: #f8faf8; }

/* player database: upload button by the title; search in the filter row */
.db-head { align-items: center; position: relative; }
.db-head .import-panel { margin-left: auto; }
.db-head .import-panel > summary { list-style: none; }
.db-head .import-panel > summary::-webkit-details-marker { display: none; }
.import-box { position: absolute; right: 0; top: calc(100% + 6px); z-index: 30; width: min(760px, 92vw); box-shadow: 0 14px 40px rgba(31,77,54,.18); }
.chip-search { margin: 0 6px 0 0; }
.chip-search input { min-width: 240px; padding: 5px 10px; border-radius: 99px; }

/* first recorded camp: subtle marker and setter */
.first-tag { margin-left: 6px; font-size: .68rem; color: var(--muted); border: 1px solid var(--line); border-radius: 99px; padding: 0 6px; }
.first-set { margin-left: 4px; border: 0; background: none; padding: 0 2px; color: #c4c8d1; font-size: .8rem; cursor: pointer; opacity: 0; transition: opacity .15s; }
tr:hover .first-set { opacity: 1; }
.first-set:hover { color: var(--navy-2); }
.older-toggle-row td { background: #fafcfa; }

/* Evaluations header dropdowns: one size, one baseline */
.head-actions select, .head-actions .button, .head-actions summary.button { height: 36px; box-sizing: border-box; margin: 0; font-size: .88rem; vertical-align: middle; }
.head-actions select { padding: 0 28px 0 12px; }
.head-actions select.trial-switch { margin: 0; }
.head-actions .export-evals > summary { display: inline-flex; align-items: center; }

/* Camp details: program goals on the left half, the three group goals stacked on the right */
.goals-split { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; align-items: stretch; }
.goals-split > .goal-block.program { margin-bottom: 0; }
.goals-split .goal-groups { grid-template-columns: 1fr; gap: 8px; }
.goals-split .goal-groups .goal-block { padding: 8px 12px; }
.goals-split .goal-groups .goal-block h3 { display: inline; margin-right: 8px; }
.goals-split .goal-groups .goal-edit { display: inline; }
.goals-split .goal-groups .goal-edit[open] { display: block; }
@media (max-width: 900px) { .goals-split { grid-template-columns: 1fr; } }

/* mid-camp group moves */
.moved-chip { display: inline-flex; align-items: center; gap: 2px; font-size: .68rem; font-weight: 600; padding: 0 6px; border-radius: 99px; background: #f1f3f7; color: var(--muted); white-space: nowrap; }
.moved-chip.up { background: #e6f6ee; color: #18794e; }
.moved-chip.down { background: #fdf0e6; color: #b4570f; }
.moved-clear { border: 0; background: none; padding: 0 0 0 2px; font-size: .8rem; line-height: 1; color: inherit; opacity: .55; cursor: pointer; }
.moved-clear:hover { opacity: 1; }

/* camp details: title row with the schedule button; attendance as three small Yes / Maybe / No cards */
.details-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.details-head h2 { margin: 0; }
.schedule-btn { white-space: nowrap; }
.att-groups { display: grid; grid-template-columns: repeat(3, minmax(0, 220px)); gap: 10px; }
.att-group { display: block; padding: 8px 12px; }
.att-group-head { display: flex; justify-content: space-between; font-weight: 700; font-size: .85rem; padding-bottom: 4px; margin: 0 0 4px; border-bottom: 1px solid rgba(0,0,0,.08); }
.att-group ul { list-style: none; margin: 0; padding: 0; font-size: .82rem; }
.att-group li { display: flex; justify-content: space-between; gap: 8px; padding: 1px 0; }
.att-group li strong { font-weight: 600; }
.att-group.att-yes .att-group-head { color: #18794e; }
.att-group.att-maybe .att-group-head { color: #a15c00; }
.att-group.att-no .att-group-head { color: #b42318; }
@media (max-width: 640px) { .att-groups { grid-template-columns: 1fr; } }

/* evaluation cards: Notes tab and per-group overalls */
.eval-table .cat-overall { background: #eaf0ff; }
.eval-table thead .cat-overall { background: #dfe7fb; }
.eval-table .avg-row .cat-overall { background: #dbe4fa; font-weight: 700; }
.eval-table td.eval-note { min-width: 260px; white-space: normal; font-size: .82rem; }
.eval-table .nowrap { white-space: nowrap; }

/* task cards: expand + snooze top right; test bests and profile link at the bottom */
.task-head-actions { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; }
.task-head-actions [data-eval-open] { color: var(--navy-2); white-space: nowrap; }
.task-foot { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; padding-top: 8px; margin-top: 4px; border-top: 1px solid var(--line); }

.skill-name .req { color: var(--muted); font-size: .8em; margin-left: 2px; vertical-align: super; line-height: 0; }
.req-key { font-weight: 400; }

.eval-pane.eval-photo { padding: 12px 0; text-align: center; }
.eval-pane.eval-photo img { max-width: 100%; max-height: 420px; border-radius: 10px; }

/* admin: tasks per coach */
.coach-tasks .badge { margin-right: 3px; }
.progress { width: 120px; height: 8px; border-radius: 99px; background: #eceff5; overflow: hidden; }
.progress span { display: block; height: 100%; background: #2e9e6a; }
.ok-text { color: #18794e; }

/* drag handle on group board cards: a clear six-dot grip */
.gb-card .drag-handle { display: inline-flex; align-items: center; color: #c2c7d0; margin-right: 2px; padding: 2px 1px; border-radius: 4px; }
.gb-card:hover .drag-handle { color: var(--navy-2); background: #eef4ef; }

/* ---- phones ---- */
@media (max-width: 700px) {
  main { padding-left: 12px !important; padding-right: 12px !important; }
  .panel { padding: 14px 12px; }
  /* Tables keep their columns and scroll sideways instead of squashing. */
  table.data, table.grid { display: block; max-width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  table.data td, table.data th { white-space: nowrap; padding: 6px 8px; }
  table.data td.notes-cell, table.data td.eval-note, table.data td.long { white-space: normal; min-width: 220px; }
  table.data select { max-width: 150px; }
  .two-col, .player-facts { grid-template-columns: minmax(0, 1fr) !important; }
  .two-col > *, .panel, section { min-width: 0; max-width: 100%; box-sizing: border-box; }
  .player-card .player-photo img { width: 120px; height: 120px; object-fit: cover; }
  .page-head { flex-wrap: wrap; gap: 8px; }
  /* tabs scroll sideways rather than overflowing the page */
  .big-tabs, .eval-tabs, .tabs { overflow-x: auto; flex-wrap: nowrap; scrollbar-width: none; max-width: 100%; }
  .big-tabs a, .eval-tabs button { white-space: nowrap; flex: none; }
  .big-tabs a { padding: 8px 12px; font-size: .9rem; }
  .eval-tabs button { padding: 6px 12px; font-size: .82rem; }
  /* evaluation pop-up: near full screen, one column of skills */
  .eval-dialog { width: 100vw; max-width: 100vw; max-height: 92vh; margin: auto 0 0; padding: 16px 12px; border-radius: 14px 14px 0 0; box-sizing: border-box; }
  .eval-dialog .eval-host { border-left: 0; padding-left: 0; }
  .eval-grid { grid-template-columns: 1fr !important; }
  .eval-grid fieldset.pos-skills .skill-items { display: block !important; }
  .eval-grid label { gap: 8px; }
  .eval-form summary { flex-wrap: wrap; }
  .group-cards { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: 8px; }
  .group-cards > * { min-width: 0; padding: 10px; }
  .group-cards strong { font-size: .9rem; }
  .group-cards .muted, .group-cards span { font-size: .75rem; }
  /* admin coach groups */
  .role-picker { gap: 6px; }
}

/* player database: emails are hidden until an admin shows them */
table.db.hide-email .col-email { display: none; }
button.chip { font: inherit; cursor: pointer; }

/* admin: an account's sign-in emails */
.user-emails .user-email { display: flex; align-items: center; gap: 4px; margin: 0; }
.user-emails .quick-note input { min-width: 190px; }

/* floating copy of a card while dragging on a phone */
.drag-ghost { position: fixed; left: 0; top: 0; z-index: 1000; pointer-events: none; opacity: .92; box-shadow: 0 8px 22px rgba(31,77,54,.3); }

@media screen and (max-width: 700px) {
  .hide-phone { display: none !important; }
  /* a larger handle that doesn't scroll the page */
  .gb-card .drag-handle { padding: 8px 7px; margin: -6px 2px -6px -6px; touch-action: none; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }

  /* player page */
  .player-facts input[type=date] { -webkit-appearance: none; appearance: none; display: block; width: 100%; max-width: 100%; min-width: 0; text-align: left; }
  .player-facts dd { overflow: hidden; }
  .player-title h1 { font-size: 1.4rem; }
  .trial-panel > summary { flex-wrap: nowrap; gap: 6px; }
  .trial-panel > summary strong { font-size: .84rem; white-space: nowrap; }
  .trial-panel > summary .badge { font-size: .68rem; padding: 1px 6px; white-space: nowrap; }
  .share-btn { white-space: nowrap; padding: 4px 8px; font-size: .72rem; }
  .trial-panel .compare h3 { font-size: .85rem; }
  table.compare-table { display: table; width: 100%; font-size: .68rem; }
  table.compare-table th, table.compare-table td { white-space: normal; padding: 4px 3px; }
  table.compare-table th { font-size: .58rem; letter-spacing: 0; line-height: 1.15; }
  table.data td select { max-width: 112px; font-size: .78rem; padding-left: 6px; padding-right: 18px; }

  /* evaluation cards: everything smaller so the tabs and tables fit */
  .eval-tabs { gap: 1px; }
  .eval-tabs button { padding: 5px 8px; font-size: .72rem; flex: 1 1 auto; }
  .eval-dialog h2, .eval-dialog h3 { font-size: .95rem; }
  .eval-form summary { font-size: .88rem; }
  .eval-table { font-size: .72rem; }
  .eval-table th { font-size: .58rem; white-space: normal; letter-spacing: 0; line-height: 1.15; padding: 4px 3px; vertical-align: bottom; }
  .eval-table td { padding: 4px 3px; }
  .eval-table .fz1 { min-width: 76px; max-width: 92px; white-space: normal; }
  table.eval-summary { display: table; width: 100%; }
  table.eval-summary td.eval-note { min-width: 0; font-size: .68rem; }
  .eval-grid { font-size: .84rem; }

  /* athlete profile: fits the screen without scrolling */
  .profile { padding: 12px 8px; overflow: hidden; }
  .p-logo { width: 52px; }
  .p-head h1 { font-size: 1.05rem; }
  .p-sub { font-size: .8rem; }
  .p-head p { font-size: .72rem; }
  .profile h2 { font-size: .9rem; margin: 14px 0 6px; }
  .profile h3, .profile h3.p-subhead { font-size: .8rem; margin: 10px 0 4px; }
  .profile .p-text { font-size: .76rem; }
  .p-legend { font-size: .66rem; gap: 10px; }
  table.pt { table-layout: fixed; font-size: .58rem; }
  table.pt th, table.pt td { padding: 3px 1px; border-width: 1px; overflow-wrap: anywhere; }
  table.pt thead th { font-size: .58rem; line-height: 1.15; }
  table.pt thead tr.sub th { font-size: .5rem; }
  table.pt tbody th { font-size: .58rem; font-weight: 600; overflow-wrap: normal; }

  /* testing data */
  .eval-head h1 { font-size: 1.25rem; width: 100%; }
  .eval-head .head-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; width: 100%; margin: 0; }
  .eval-head .head-actions select { width: 100%; min-width: 0; height: 32px; font-size: .76rem; padding: 0 20px 0 8px; }
  .eval-head .head-actions .trial-switch { grid-column: 1 / -1; order: -1; }
  .grid-wrap table.grid { display: table; overflow: visible; font-size: .68rem; }
  .grid-wrap table.grid th, .grid-wrap table.grid td { padding: 3px 4px; }
  .grid-wrap table.grid thead th { min-width: 40px; font-size: .6rem; line-height: 1.15; }
  .grid-wrap table.grid .sticky { min-width: 82px; max-width: 92px; white-space: normal; line-height: 1.15; }
  .grid-wrap table.grid .wide-col, .grid-wrap table.grid td.long { min-width: 340px; max-width: 420px; }
  .grid-wrap table.grid .badge { font-size: .58rem; padding: 0 5px; white-space: nowrap; }
  .grid-wrap table.grid thead th[data-nosort]:not(.sec):not(.blank) { min-width: 28px; }
  .grid-wrap table.grid textarea { min-width: 320px; font-size: .68rem; }
  .grid-wrap table.grid input, .grid-wrap table.grid select { font-size: .68rem; padding: 2px 3px; max-width: 74px; }
}

/* Coach evaluations: Completed column */
/* Only a ticked cell turns light green; the header and % stay as the other headings. */
.eval-overview td.done-col:has(input:checked) { background: #e6f6e6; }
.eval-overview th.done-col { white-space: nowrap; }
.eval-overview .done-pct { font-size: 1.05rem; font-weight: 700; }
/* Every row stays one line tall; notes are cut off (hover for the full text) in a wide last column. */
[data-done-table] tbody th, [data-done-table] tbody td { white-space: nowrap; }
[data-done-table] .notes-col { min-width: 320px; max-width: 480px; overflow: hidden; text-overflow: ellipsis; text-align: left; }
.eval-overview .done-col input { width: 16px; height: 16px; accent-color: #2e9c4a; cursor: pointer; }
.eval-box-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.eval-box-head .spacer { flex: 1; }

/* Evaluation report (draft) */
.eval-report table.pt { width: 100%; }
.eval-report table.er-overall td { font-size: 1.15rem; }
.eval-report .er-scale { display: flex; flex-wrap: wrap; gap: 4px 16px; }

/* Coach evaluations: ready-to-review tint, section dividers, expand hint on hover */
.eval-overview td.done-col.ready { background: #e6f6e6; }
[data-done-table] .sec-start { border-left: 2px solid #aab3c8; }
[data-done-table] tbody tr[data-eval-entry] { cursor: pointer; }
[data-done-table] tbody th.sticky { padding-right: 26px; }
[data-done-table] tbody tr[data-eval-entry]:hover th.sticky::after {
  content: '⤢'; position: absolute; right: 5px; top: 50%; transform: translateY(-50%);
  background: var(--navy); color: #fff; border-radius: 4px; padding: 0 5px; font-size: .8rem; line-height: 1.5;
}

/* Quick links: one full-width line each */
.link-list { grid-template-columns: 1fr !important; gap: 8px !important; }
.link-list li { flex-direction: row !important; align-items: center; gap: 14px !important; padding: 10px 14px !important; }
.link-list .link-card { flex: 1; min-width: 0; flex-direction: row; align-items: baseline; gap: 12px; }
.link-list .link-card strong { white-space: nowrap; }
.link-list .link-url { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.link-list form.inline { margin: 0; }

/* Player database: Filter menu, chosen-filter pills, wider search, Show emails column */
.chip-search { flex: 0 1 50%; }
.chip-search input { width: 100%; min-width: 0; box-sizing: border-box; }
.filter-menu { position: relative; }
.filter-menu > summary { list-style: none; cursor: pointer; }
.filter-menu > summary::-webkit-details-marker { display: none; }
.filter-box { position: absolute; z-index: 20; top: calc(100% + 4px); left: 0; min-width: 220px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 6px 18px rgba(31,77,54,.14); padding: 6px; display: flex; flex-direction: column; }
.filter-box a { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border-radius: 6px; text-decoration: none; color: inherit; font-size: .9rem; }
.filter-box a:hover { background: #f1f5f1; }
.filter-box a.on { font-weight: 600; }
.filter-box a .tiny { margin-left: auto; }
.fm-check { width: 14px; color: #2e9c4a; font-weight: 700; }
table.db th.email-toggle, table.db td.email-toggle { width: 1%; white-space: nowrap; }
.show-phone { display: none !important; }

@media screen and (max-width: 700px) {
  .show-phone { display: revert !important; }
  .chip-search { flex: 1 1 100%; margin: 0; }
  .db-view { padding: 4px 8px; border-radius: 99px; font-size: .85rem; }
  .goals-split { grid-template-columns: 1fr; }
  .link-list li { flex-wrap: wrap; row-gap: 2px !important; }
  .link-list .link-card { flex-basis: 100%; }

  /* Box view: each player is a card you scroll down through, no sideways scrolling */
  .db-wrap.box-view { overflow: visible; }
  .db-wrap.box-view table.db, .db-wrap.box-view table.db tbody { display: block; overflow: visible; }
  .db-wrap.box-view table.db thead, .db-wrap.box-view table.db td.email-toggle, .db-wrap.box-view table.db.hide-email td.col-email { display: none; }
  .db-wrap.box-view table.db tr { display: block; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 8px 12px; margin-bottom: 8px; }
  .db-wrap.box-view table.db td { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 4px 0; border: 0; white-space: normal; min-width: 0; text-align: right; }
  .db-wrap.box-view table.db td[data-label]::before { content: attr(data-label); color: var(--muted); font-size: .75rem; text-align: left; flex: none; }
  .db-wrap.box-view table.db td.db-name { font-size: 1.05rem; padding-bottom: 6px; border-bottom: 1px solid var(--line); margin-bottom: 4px; }
  .db-wrap.box-view table.db td.notes-cell { display: block; text-align: left; }
  .db-wrap.box-view table.db td.notes-cell::before { display: block; margin-bottom: 2px; }
  .db-wrap.box-view table.db td select { max-width: 60%; }
}

/* Marked complete in My tasks: ticked, but never green. */
.eval-overview td.done-col.task-done { background: transparent !important; }

/* Quick links: never wider than the panel (long addresses are cut off with …). */
.link-list { grid-template-columns: minmax(0, 1fr) !important; }
.link-list li { min-width: 0; }
.link-list .link-card { overflow: hidden; }

/* Not invited to the next camp: a small yellow "!" (higher priority). */
.prio-flag { display: inline-flex; align-items: center; justify-content: center; width: 16px; height: 16px; margin-right: 6px; border-radius: 50%; background: #f5c518; color: #3a2c00; font-size: .72rem; font-weight: 800; line-height: 1; vertical-align: 1px; }

/* Player feedback: Save button and when it was last saved. */
.feedback-save { display: flex; align-items: center; gap: 10px; margin-top: 4px; }
.pre-line { white-space: pre-line; }
.task-due { font-weight: 600; color: var(--muted); }

/* My tasks: a much smaller Evaluations link under Snooze; player info line with notes on hover. */
.task-head-actions .eval-mini { font-size: .66rem; color: var(--navy-2); white-space: nowrap; padding: 0; }
.task-info { margin-top: 3px; }
.note-tip { border-bottom: 1px dotted currentColor; cursor: help; }
/* Compact testing results, coloured by quarter of the performance team. */
.task-testing { display: flex; flex-wrap: wrap; gap: 4px 6px; margin: 4px 0 8px; }
.tt { font-size: .74rem; font-weight: 700; border-radius: 99px; padding: 1px 8px; background: #f2f4f8; color: var(--ink, #1f3a2c); white-space: nowrap; }
.tt .tt-label { font-weight: 500; opacity: .8; }
.tt.q1 { color: #b42318; background: #fdecec; }
.tt.q2 { color: #c4560a; background: #fff1e3; }
.tt.q3 { color: #8a6d00; background: #fff8d2; }
.tt.q4 { color: #17803d; background: #e7f6ec; }

/* Sign in: the subtle "or sign in with an email code" link, and the code box. */
.login-or { margin: 14px 0 0; font-size: .8rem; color: var(--muted); }
.login-or span { margin-right: 2px; }
.login-or a { color: var(--muted); }
.login-or a:hover { color: var(--navy); }
.login .code-input { font-size: 1.4rem; letter-spacing: 6px; text-align: center; }

/* My tasks cards: a tidier layout. Header: photo, name + group, one muted info line, note chips;
   actions stacked top right. Body: testing pills, feedback box, one action row. */
.task { display: flex; flex-direction: column; gap: 10px; }
.task-head { align-items: flex-start; margin-bottom: 0; gap: 14px; }
.task-title { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.task-title h3 { margin: 0; font-size: 1.08rem; }
.task-title .prio-flag { margin-right: 0; }
.task-meta { display: flex; flex-wrap: wrap; gap: 0 6px; margin-top: 4px; font-size: .78rem; color: var(--muted); }
.task-meta span + span::before { content: '·'; margin-right: 6px; }
.task-notes { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.note-chip { font-size: .72rem; color: var(--navy-2); background: #eef4ef; border-radius: 99px; padding: 1px 8px; cursor: help; white-space: nowrap; }
.note-chip:hover, .note-chip:focus { background: #dbe8dd; outline: none; }
.task-head-actions { gap: 4px; padding-top: 2px; }
.task-head-actions .link, .task-head-actions .snooze-form .link { font-size: .72rem; color: var(--muted); text-decoration: none; padding: 0; }
.task-head-actions .link:hover { color: var(--navy); text-decoration: underline; }
.task-head .snooze-form { margin-left: 0; }
.task-testing { margin: 0; }
.task .task-field { margin: 0; display: flex; flex-direction: column; gap: 6px; }
.task-field-head { display: flex; align-items: center; justify-content: space-between; font-size: .85rem; }
.fb-check .box { width: 18px; height: 18px; border: 2px solid #b7c8bb; border-radius: 50%; display: grid; place-items: center; font-size: .7rem; color: #fff; }
.fb-check.done .box { background: #1f9d6b; border-color: #1f9d6b; }
.task textarea { width: 100%; box-sizing: border-box; }
.task-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding-top: 10px; border-top: 1px solid var(--line); }
.task-actions .spacer { flex: 1; }
.complete-toggle { display: inline-flex; align-items: center; gap: 6px; font-size: .85rem; font-weight: 600; margin: 0; cursor: pointer; }
.complete-toggle input { width: 17px; height: 17px; margin: 0; accent-color: #1f9d6b; }
.complete-toggle:has(input:disabled) { color: var(--muted); cursor: not-allowed; }
.task .checklist { margin: 0; }
/* Player page: the evaluation box folds away like the trials panel. */
details.eval-collapse > summary { cursor: pointer; list-style: none; }
details.eval-collapse > summary::-webkit-details-marker { display: none; }
details.eval-collapse > summary h3 { margin: 0; }
details.eval-collapse > summary h3::before { content: '▸ '; color: var(--muted); }
details.eval-collapse[open] > summary { margin-bottom: 10px; }
details.eval-collapse[open] > summary h3::before { content: '▾ '; }
.task-actions label.complete-toggle { flex-direction: row; white-space: nowrap; }
.task-field-head { justify-content: flex-start; gap: 6px; }
.fb-check .box { width: 15px; height: 15px; font-size: .6rem; }

/* My tasks cards, calmer: group as a quiet chip under the name, Snooze alone top right,
   View / Evaluations next to Mark task as complete. */
.task-head { align-items: center; }
.task-head-actions { align-self: flex-start; padding-top: 0; }
.task-meta { align-items: center; margin-top: 3px; }
.task-group { font-size: .72rem; color: var(--navy-2); background: #eef4ef; border-radius: 99px; padding: 0 8px; line-height: 1.6; }
.task-meta .task-group + span::before { content: none; }
.task-meta .task-group { margin-right: 2px; }
.task-notes { margin-top: 5px; }
.task-actions { gap: 12px; }
.task-actions .task-link { font-size: .78rem; color: var(--navy-2); text-decoration: none; padding: 0; background: none; border: 0; cursor: pointer; white-space: nowrap; }
.task-actions .task-link:hover { text-decoration: underline; }
.task-actions [data-feedback-save]:disabled { opacity: .45; cursor: default; }

/* Evaluation form, two columns: the optional Blitzing, Snapping and Passing fill the right column. */
.eval-grid fieldset.pos-skills .skill-items { grid-auto-flow: column; grid-template-rows: repeat(4, auto); }

/* My tasks: a task another coach has completed sits at the bottom in yellow, for you to review. */
.task.review { background: #fffbea; border-color: #f1d77a; }
.review-note { margin: 0; font-size: .78rem; color: #7a5b00; background: #fff3c4; border-radius: 6px; padding: 4px 8px; }
.goal-task.review { background: #fffbea; border-color: #f1d77a; }
.goal-task button.small { white-space: nowrap; }

/* Notes chips: their notes open underneath on a click or tap. */
.task-notes { flex-wrap: wrap; }
.note-chip { cursor: pointer; }
.note-chip.on { background: #dbe8dd; }
.note-pop { flex-basis: 100%; white-space: pre-line; font-size: .78rem; color: var(--ink, #1f3a2c); background: #f5f7fc; border: 1px solid #dbe8dd; border-radius: 8px; padding: 6px 9px; margin-top: 2px; overflow-wrap: anywhere; }

/* Coach tasks: compact, with a progress ring; Progress and Coach stay frozen while the months scroll. */
.coach-tasks-wrap { max-width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }
table.data.coach-tasks { display: table; width: auto; min-width: 0; font-size: .85rem; border-collapse: separate; border-spacing: 0; }
.coach-tasks th, .coach-tasks td { padding: 6px 10px; }
.coach-tasks thead th { white-space: normal; line-height: 1.2; vertical-align: bottom; }
.coach-tasks .ct-month { text-transform: none; font-size: .8rem; color: var(--navy); border-bottom: 2px solid var(--line); }
.coach-tasks .ct-later { border-left: 2px solid var(--line); }
.coach-tasks .ct-frozen { position: sticky; z-index: 1; background: #fff; }
.coach-tasks thead .ct-frozen { background: var(--th-bg, #f6f7fb); z-index: 2; }
.coach-tasks .ct-ring { left: 0; width: 46px; min-width: 46px; padding: 4px 6px; }
.coach-tasks .ct-name { left: 46px; white-space: nowrap; box-shadow: 1px 0 0 var(--line); }
.ring .ring-bg { fill: none; stroke: #e6e9f2; stroke-width: 4; }
.ring .ring-fg { fill: none; stroke: #1f9d6b; stroke-width: 4; stroke-linecap: round; }
.ring text { font-size: 9px; font-weight: 700; fill: var(--ink, #1f3a2c); }

@media (max-width: 700px) {
  /* iPhones zoom in on a text box or dropdown under 16px (and the page then scrolls sideways). */
  input:not(.code-input):not([type=checkbox]):not([type=radio]), select, textarea { font-size: 16px; }
  html, body { overflow-x: clip; }
  .task { max-width: 100%; min-width: 0; overflow-wrap: anywhere; }
  .eval-dialog { max-width: 100vw; box-sizing: border-box; overflow-x: hidden; }
  .eval-dialog td, .eval-dialog th { white-space: normal; overflow-wrap: anywhere; }
  .coach-tasks th, .coach-tasks td { padding: 5px 7px; }
  table.data.coach-tasks { font-size: .8rem; }
}

.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.coach-tasks .ct-ring { max-width: 46px; box-sizing: border-box; }
@media (max-width: 700px) {
  .coach-tasks .ct-name { white-space: normal; max-width: 96px; min-width: 70px; overflow-wrap: anywhere; line-height: 1.25; }
  .coach-tasks thead th { font-size: .66rem; }
  .coach-tasks .ct-month { font-size: .72rem; }
}

[data-rename-player] { cursor: text; }

/* Due dates on My tasks and Coach tasks; red once overdue. */
.due-pill, .overdue-pill { display: inline-block; font-size: .7rem; font-weight: 600; border-radius: 99px; padding: 1px 8px; vertical-align: 3px; margin-left: 4px; }
.due-pill { background: #eef4ef; color: var(--navy-2); }
.overdue-pill { background: #fdecec; color: #b42318; }
.task.late { border-left: 4px solid #d92d20; }
.coach-tasks td.late, .coach-tasks th.late { color: #b42318; font-weight: 700; }
.coach-tasks td.late { background: #fff3f2; }
.ring.late .ring-fg { stroke: #d92d20; }
.ring.late .ring-bg { stroke: #f9d7d4; }
.ring.late text { fill: #b42318; }
.task-actions .snooze-form { margin: 0; }
.task-actions .snooze-form .link { font-size: .72rem; color: var(--muted); text-decoration: none; }

/* Mobile menu: the burger becomes ✕ while the menu is open. */
.nav-burger .burger-close { display: none; font-size: 1.35rem; line-height: 1; width: 24px; text-align: center; }
.nav-toggle:checked + .sidebar .nav-burger .burger-open { display: none; }
.nav-toggle:checked + .sidebar .nav-burger .burger-close { display: inline-block; }

/* My tasks: my completed tasks, collapsed, as a compact table (yellow = changed by someone since). */
details.done-tasks { margin-top: 10px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 6px 10px; }
details.done-tasks > summary { cursor: pointer; font-size: .85rem; color: var(--muted); }
details.done-tasks .changed-count { color: #7a5b00; font-weight: 600; }
.done-table { margin-top: 6px; font-size: .82rem; }
.done-table td, .done-table th { padding: 4px 8px; }
.done-table tr.changed td { background: #fff6cf; }
.done-table .right { text-align: right; }

/* Testing data: how many of the group's coaches have completed this profile. */
.coach-done { display: inline-block; margin-left: 6px; font-size: .68rem; border-radius: 99px; padding: 0 6px; background: #eef4ef; color: var(--muted); white-space: nowrap; cursor: help; }
.coach-done.some { background: #fff3c4; color: #7a5b00; }
.coach-done.all { background: #e7f6ec; color: #17803d; }

/* Camp goals: program and group goals as equal boxes in one grid. */
.goals-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 10px; align-items: start; }
.goals-grid .goal-block { margin: 0; padding: 10px 12px; height: 100%; box-sizing: border-box; }
.goals-grid .goal-block h3 { font-size: .95rem; }
.goals-grid .goal-block li { font-size: .88rem; }
@media (max-width: 1100px) { .goals-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .goals-grid { grid-template-columns: 1fr; } }

/* "Mark complete for me": the same button on every task. */
.done-btn { display: inline-flex; align-items: center; gap: 6px; background: transparent; color: var(--ink, #1f3a2c); border: 1px solid var(--line); border-radius: 8px; padding: 6px 12px; font-size: .85rem; font-weight: 600; cursor: pointer; white-space: nowrap; }
.done-btn svg { color: #1f9d6b; }
.done-btn:hover:not(:disabled) { border-color: #1f9d6b; background: #f1faf5; }
.done-btn:disabled { opacity: .45; cursor: not-allowed; }

/* Goal and registration tasks: what to do on the left, the button and Snooze on the right. */
.goal-task { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px; }
.goal-task .goal-task-link { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; min-width: 0; }
.goal-task .goal-task-title { font-weight: 600; }
.goal-task .goal-task-title .sl-arrow { margin-left: 2px; }
.goal-task-actions { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.goal-task-actions .snooze-form { margin: 0; }
.goal-task-actions .snooze-form .link { font-size: .72rem; color: var(--muted); text-decoration: none; }

/* Player page: player feedback edits like My tasks. */
.fb-editor { display: flex; flex-direction: column; gap: 8px; }
.fb-editor textarea { width: 100%; box-sizing: border-box; }
.fb-editor .task-actions { border-top: 0; padding-top: 0; }
.fb-log { cursor: help; }

/* Player page: the Profile data button sits at the top right. */
.player-title .profile-data-btn { margin-left: auto; }

/* Camp groups: Board / Spreadsheet toggle, the spreadsheet layout, and the linked group sheet. */
.groups-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.groups-head h2 { margin: 0; }
.seg-toggle { display: inline-flex; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.seg-toggle button { border: 0; border-radius: 0; background: #fff; padding: 5px 12px; font-size: .82rem; color: var(--muted); cursor: pointer; }
.seg-toggle button.on { background: var(--navy); color: #fff; }
.sheet-sync { margin: 6px 0 10px; display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: baseline; }
.sheet-sync .error { color: #b42318; }
.sheet-unmatched { color: #7a5b00; cursor: help; }
.sheet-link summary { cursor: pointer; }
.sheet-link form { margin-top: 6px; gap: 6px; }
.sheet-link input { min-width: 320px; flex: 1; }
.ss-groups { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 14px; align-items: start; }
.ss-table { width: 100%; border-collapse: collapse; font-size: .84rem; background: #fff; }
.ss-table th, .ss-table td { border: 1px solid #c9ced8; padding: 3px 6px; text-align: left; white-space: nowrap; }
.ss-table thead th { background: #fff; font-weight: 700; }
.ss-table .ss-title { text-align: center; font-size: .92rem; }
.ss-table .ss-n { text-align: right; font-weight: 700; width: 28px; }
.ss-table td a { color: inherit; text-decoration: none; }
.ss-table tr.ss-yes td { background: #c6f5c0; }
.ss-table tr.ss-maybe td { background: #fff3a6; }
.ss-table tr.ss-out td { background: #f8d4d8; }
.ss-table tr.ss-expected td { background: #fff; }
@media (max-width: 700px) { .ss-groups { grid-template-columns: 1fr; } .sheet-link input { min-width: 0; } }

/* Groups sheet box and the No group yet column. */
.sheet-sync { flex-direction: column; align-items: flex-start; gap: 6px; }
.sheet-sync form.inline { margin: 0; }
.sheet-sync .sheet-link { width: 100%; max-width: 760px; gap: 6px; }
.sheet-sync .sheet-link input { flex: 1; min-width: 0; font-size: .82rem; }
.ss-table.ss-none .ss-title { color: var(--muted); }
.ss-groups { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }

/* Attendance "To confirm" after a camp: for the group's coaches to fill in. */
.att-confirm { background: #fff3c4 !important; color: #7a5b00 !important; border-color: #f1d77a !important; }
.confirm-att table { margin-top: 4px; }
.confirm-att td { vertical-align: middle; }

/* Player page header: the details side fills the card (Profile data sits at the right edge), and the
   fields share one three-column grid so "Also known as" lines up with the row above. */
.player-card > .grow { flex: 1; min-width: 0; }
.player-card .player-facts { grid-template-columns: repeat(3, minmax(0, 1fr)); max-width: 780px; }
@media (max-width: 900px) { .player-card .player-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: none; } }
@media (max-width: 700px) { .player-card .player-facts { grid-template-columns: minmax(0, 1fr); } }

/* Groups sheet: one compact line (status, Sync from sheet, and the link tucked in a collapsed "Change link"). */
.sheet-sync { flex-direction: row !important; align-items: center !important; flex-wrap: wrap; gap: 4px 10px !important; margin: 4px 0 8px !important; }
.sheet-sync button.xs { padding: 2px 8px; font-size: .74rem; }
.sheet-sync .sheet-link { width: auto !important; max-width: none !important; position: relative; }
.sheet-sync .sheet-link > summary { list-style: none; font-size: .74rem; }
.sheet-sync .sheet-link > summary::-webkit-details-marker { display: none; }
.sheet-link-form { display: flex; gap: 6px; align-items: center; margin-top: 4px; }
.sheet-link-form input { width: 280px; max-width: 70vw; font-size: .8rem; padding: 3px 6px; }
.groups-head { margin-bottom: 2px; }

/* My tasks on a phone: two formats only. Save and Mark complete for me as equal buttons side by side, then
   View, Evaluations and Snooze as one row of small links. */
@media (max-width: 700px) {
  .task .task-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
  .task .task-actions .spacer { display: none; }
  .task .task-actions .goal-task-actions { display: contents; }
  .task .task-actions [data-feedback-save], .task .task-actions .done-btn { order: 1; flex: 1 1 0; justify-content: center; min-height: 38px; padding: 7px 10px; font-size: .88rem; border-radius: 8px; margin: 0; }
  .task .task-actions .task-link, .task .task-actions .snooze-form { order: 2; }
  .task .task-actions .task-link, .task .task-actions .snooze-form .link { font-size: .8rem; color: var(--navy-2); text-decoration: none; }
  .task .task-actions .snooze-form { margin: 0 0 0 auto; }
  .task .task-actions .snooze-form .link { color: var(--muted); }
}
@media (max-width: 700px) {
  .task .task-actions .spacer { display: block; order: 2; flex: 0 0 100%; height: 0; }
  .task .task-actions .task-link, .task .task-actions .snooze-form { order: 3; }
}

/* Player notes: internal notes are labelled; older feedback versions are a little quieter. */
.internal-tag { font-size: .7rem; font-weight: 500; color: var(--muted); }
.notes li.old-version p { color: var(--muted); }

/* Player feedback history: tucked under the current version. */
details.fb-history { margin-top: 6px; }
details.fb-history > summary { cursor: pointer; list-style: none; }
details.fb-history > summary::-webkit-details-marker { display: none; }
details.fb-history .notes { margin-top: 6px; }

/* Spreadsheet view: counts by each group, not-found names, and fitting on a phone. */
.ss-table .ss-count { font-weight: 500; color: var(--muted); font-size: .82rem; }
.ss-table tr.ss-notfound td { background: #fdecec; }
.nf-flag { display: inline-block; font-size: .68rem; font-weight: 700; color: #b42318; border: 1px solid #f3b8b3; background: #fff; border-radius: 99px; padding: 0 6px; margin-right: 6px; }
.ss-table tr.ss-notfound form { display: inline; margin: 0; }
.ss-table tr.ss-notfound button.xs { padding: 1px 6px; font-size: .7rem; }
@media (max-width: 700px) {
  .ss-groups { grid-template-columns: minmax(0, 1fr) !important; }
  .ss-table { width: 100%; font-size: .8rem; }
  .ss-table th, .ss-table td { white-space: normal; overflow-wrap: anywhere; padding: 3px 4px; }
  .ss-table th:first-child, .ss-table td.ss-n { width: 26px; }
}

/* Spreadsheet view on a computer: four tables side by side, text wrapping so none runs off the page. */
.ss-groups { grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); }
.ss-groups > .ss-table { min-width: 0; width: 100%; }
.ss-table th, .ss-table td { white-space: normal; overflow-wrap: anywhere; }

/* Expected: a neutral pill (Confirmed green, maybes yellow, not coming red), as in the spreadsheet view. */
.att-expected { color: var(--ink, #1f3a2c); }
.status-pill.att-expected { background: #f1f5f1; color: #3d4663; }
/* Board: names from the groups sheet that don't match a player. */
.gb-card.gb-notfound { background: #fdf3f2; border-color: #f3c6c0; }
.gb-card.gb-notfound .gb-name { font-weight: 600; }
.gb-card.gb-notfound form { margin-top: 4px; }
.gb-nf-note { margin: 4px 0 0; }

/* Player database: filter a camp column by status. */
th.att-col .col-filter { display: block; margin-top: 3px; font-size: .72rem; padding: 1px 2px; max-width: 120px; font-weight: 500; }
th.att-col .col-filter.on { border-color: var(--accent, #2f7d4f); color: var(--accent, #2f7d4f); font-weight: 700; }
.filter-box .fm-head { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); padding: 8px 10px 2px; border-top: 1px solid var(--line, #e2eae3); margin-top: 4px; }
/* Camp spreadsheet view: statuses can be changed there too. */
.ss-table .status-edit .att-pill { cursor: pointer; }
.ss-table select.gb-att { font-size: .78rem; max-width: 150px; }
/* Profile statuses: Ready to review is blue; Complete (signed off) is solid. */
.s-ready-to-review { background: #e1efe4; color: #2f7d4f; }
.s-complete { background: #2f7d4f; color: #fff; }
select.status-select.s-complete option { background: #fff; color: #1f3a2c; }

/* Sat Jersey: a small box in the camp workspace. */
.jersey-input { width: 5.5em; padding: 2px 4px; font-size: 16px; text-align: center; }
@media (min-width: 701px) { .jersey-input { font-size: .82rem; } }
.jersey-input.saved { border-color: #16a34a; }
.jersey-input.failed { border-color: #b42318; }
.ss-jersey { text-align: center; white-space: nowrap; }
.gb-jersey { display: flex; align-items: center; gap: 6px; font-size: .72rem; color: var(--muted); margin-top: 4px; }
.gb-jersey .jersey-input { width: 5.5em; padding: 1px 4px; }

.gb-card label.gb-jersey { display: flex; flex-direction: row; justify-content: flex-start; align-items: center; gap: 6px; margin: 4px 0 0; font-weight: 400; }

/* Player database: a small Upload button. */
.import-panel > summary.upload-btn { font-size: .78rem; padding: 3px 10px; }
/* Phones: smaller names and statuses on the camp board, to fit more on screen. */
@media (max-width: 700px) {
  .gb-card .gb-name { font-size: .78rem; }
  .gb-card .status-pill, .gb-card .att-pill { font-size: .62rem; padding: 1px 6px; }
  .gb-card { padding: 5px 7px; }
  .gb-card .gb-jersey { font-size: .65rem; }
}

/* Camp spreadsheet view: room to read. Fixed column widths (Attendance about as wide as "Out - Conflict",
   longer statuses wrap), names wrap between words, never mid-word. */
.ss-groups { grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)) !important; }
.ss-table { table-layout: fixed; }
.ss-table th, .ss-table td { overflow-wrap: normal; word-break: normal; white-space: normal; vertical-align: middle; }
.ss-table col.c-n { width: 30px; }
.ss-table col.c-att { width: 122px; }
.ss-table col.c-jersey { width: 84px; }
.ss-table td.ss-name { overflow-wrap: break-word; }
.ss-table td.ss-att .att-pill, .ss-table td.ss-att .status-pill { white-space: normal; display: inline-block; max-width: 100%; text-align: center; line-height: 1.25; }
.ss-table td.ss-att select.gb-att { max-width: 100%; }
.ss-table .jersey-input { width: 100%; box-sizing: border-box; }
.ss-table th.ss-jersey, .ss-table td.ss-jersey { padding-left: 4px; padding-right: 4px; }
/* Camp board: notes start folded. */
.gb-notes-fold { margin-top: 3px; font-size: .74rem; }
.gb-notes-fold > summary { cursor: pointer; color: var(--muted); list-style: none; }
.gb-notes-fold > summary::-webkit-details-marker { display: none; }
.gb-notes-fold > summary::before { content: '▸ '; }
.gb-notes-fold[open] > summary::before { content: '▾ '; }
@media (max-width: 700px) {
  .ss-table col.c-n { width: 22px; }
  .ss-table col.c-att { width: 86px; }
  .ss-table col.c-jersey { width: 58px; }
  .ss-table td.ss-att .att-pill, .ss-table td.ss-att .status-pill { font-size: .62rem; padding: 1px 5px; }
  .ss-table .jersey-input { font-size: 16px; padding: 1px 2px; }
}
/* The group title spans every column: no width of its own, so the column widths above hold. */
.ss-table th.ss-title { width: auto !important; }
@media (max-width: 700px) {
  .ss-table col.c-att { width: 80px; }
  .ss-table col.c-jersey { width: 70px; }
  .ss-table td.ss-jersey { padding: 2px; }
  .ss-table .jersey-input { padding: 1px 0; }
}

/* Camp spreadsheet view: the Participating filter. */
.ss-participating { display: inline-flex; flex-direction: row; align-items: center; gap: 6px; font-weight: 600; font-size: .85rem; margin: 0 0 10px; cursor: pointer; }
.ss-participating .tiny { font-weight: 400; }
.ss-table[hidden], .ss-table tr[hidden] { display: none; }
.gb-card[hidden], .gb-col[hidden], .gb-out-list[hidden] { display: none !important; }
.groups-head .ss-participating { margin: 0 10px 0 auto; }
/* Camp spreadsheet view: double-click a row to add a note; ✎ shows how many notes (hover to read them). */
.ss-table tr[data-player] { cursor: default; }
.ss-table .ss-notes { margin-left: 6px; font-size: .7rem; color: var(--muted); white-space: nowrap; cursor: help; }
.ss-table tr.ss-note-row td { background: #fff; padding: 6px; }
.ss-table tr.ss-note-row textarea { width: 100%; min-height: 60px; box-sizing: border-box; font-size: 16px; }

/* Admin: rename photos in the Drive folder. */
.photo-rename-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.photo-rename { margin: 0; padding: 10px; display: flex; flex-direction: column; gap: 6px; }
.photo-rename img { width: 100%; height: 260px; object-fit: contain; background: #f1f5f1; border-radius: 6px; display: block; }
.photo-rename .pr-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.photo-rename .row { display: flex; gap: 6px; }
.photo-rename .row input { flex: 1; min-width: 0; }

/* 2027 performance team evaluations */
.team-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.team-head .seg-toggle a.button { border: 0; border-radius: 0; padding: 6px 14px; font-size: .85rem; background: #fff; color: var(--muted); text-decoration: none; }
.team-head .seg-toggle a.button.on { background: var(--navy); color: #fff; }
.team-head .seg-n { display: inline-block; margin-left: 4px; font-size: .72rem; font-weight: 700; background: rgba(0,0,0,.08); border-radius: 99px; padding: 0 6px; }
.team-head .seg-toggle a.button.on .seg-n { background: rgba(255,255,255,.25); }
.team-counts { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 6px 0 14px; }
.team-count { border-radius: 99px; padding: 3px 12px; font-size: .82rem; background: #f1f5f1; }
.team-count b { margin-left: 4px; }
.tc-pride-1 { background: #e1efe4; color: #2f7d4f; }
.tc-pride-2 { background: #efe5ff; color: #6b2fb3; }
.tc-performance-team { background: #ddf6ec; color: #136c48; }
.team-table td.ss-n, .team-table th.ss-n { width: 34px; text-align: right; font-weight: 700; }
.team-table select { min-width: 150px; }
/* 2027 performance team: compact tables, one per group, side by side. */
.team-list { padding: 10px 12px; }
.team-list h2 { margin: 0 0 8px; font-size: 1rem; }
.team-groups { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 330px), 1fr)); gap: 10px; align-items: start; }
.team-table { table-layout: fixed; font-size: .78rem; }
.team-table th, .team-table td { padding: 1px 4px; line-height: 1.25; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.team-table td.ss-n { width: 26px; }
.team-table td.tm-att { width: 92px; }
.team-table td.tm-pick { width: 112px; }
.team-table td.tm-att .status-pill { font-size: .64rem; padding: 0 6px; }
.team-table select { min-width: 0; width: 100%; font-size: .74rem; padding: 0 2px; height: 22px; }
.team-table tr:nth-child(even) td { background: #fafcfa; }
.team-counts { margin: 2px 0 8px; }
@media (max-width: 700px) { .team-table select { font-size: 16px; height: auto; } }
.team-table col.c-n { width: 26px; }
.team-table col.c-att { width: 92px; }
.team-table col.c-pick { width: 112px; }
@media (max-width: 700px) { .team-table col.c-att { width: 78px; } .team-table col.c-pick { width: 104px; } }
@media (min-width: 701px) {
  .team-table select { height: 19px; font-size: .72rem; padding: 0 1px; }
  .team-table th, .team-table td { padding: 0 4px; }
  .team-table td.tm-att .status-pill { line-height: 1.3; }
  .team-head h1 { font-size: 1.3rem; margin: 4px 0; }
}
.tc-cut { background: #fdecea; color: #b42318; }
.tc-decide-sunday { background: #fff4e0; color: #8a5a00; }
/* 2027 performance team, Sorted view: the lists side by side. */
.team-sorted-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); gap: 10px; align-items: start; }
.team-sorted-grid .team-list { margin: 0; }
.team-sorted-grid .team-groups { grid-template-columns: minmax(0, 1fr); }

/* Sidebar collapse button, and the collapsed sidebar (desktop): a thin strip of icons. */
.sb-collapse { background: none; border: 0; color: #9cc4a8; cursor: pointer; font-size: 1.1rem; line-height: 1; padding: 4px 6px; border-radius: 6px; }
.sb-collapse:hover { background: rgba(255,255,255,.1); color: #fff; }
.sb-collapse .sb-collapse-out { display: none; }
@media (max-width: 900px) { .sb-collapse { display: none; } }
@media (min-width: 901px) {
  html.sb-mini .sidebar { width: 52px; padding: 12px 5px; overflow: visible; }
  html.sb-mini .sb-top { flex-direction: column; gap: 8px; padding: 0 0 10px; }
  html.sb-mini .sidebar .brand span, html.sb-mini .sb-text, html.sb-mini .sb-label, html.sb-mini .sidebar .view-as, html.sb-mini .sidebar .who-text { display: none; }
  html.sb-mini .sidebar .brand img { width: 30px; height: 30px; }
  html.sb-mini .sb-collapse .sb-collapse-in { display: none; }
  html.sb-mini .sb-collapse .sb-collapse-out { display: inline; }
  html.sb-mini .sb-nav { padding: 10px 0; gap: 2px; }
  html.sb-mini .sb-nav a { justify-content: center; padding: 9px 0; position: relative; gap: 0; }
  html.sb-mini .sb-nav .count { position: absolute; top: 1px; right: 0; min-width: 16px; padding: 0 4px; font-size: .62rem; line-height: 15px; }
  html.sb-mini .sb-nav .count.zero { display: none; }
  html.sb-mini .sb-bottom { gap: 6px; padding-top: 8px; }
  html.sb-mini .sidebar .who { flex-direction: column; gap: 4px; padding: 0; }
  html.sb-mini .sidebar .who-link { flex: none; padding: 0; }
  html.sb-mini .sidebar .avatar { width: 30px; height: 30px; font-size: .7rem; }
}

/* 2027 performance team: dragging to rank. */
.team-table tr.team-drag { cursor: grab; }
.team-table tr.team-drag td.ss-n::before { content: '⠿ '; color: var(--muted); font-weight: 400; }
.team-table tr.dragging td { background: #e1efe4 !important; opacity: .7; }
.team-table td.ss-n { width: 40px; }
.team-table col.c-n { width: 40px; }
.team-range { font-weight: 500; margin-left: 4px; }
/* Phones: the ⠿ number is the handle for dragging (it doesn't scroll the page). */
.team-table tr.team-drag td.ss-n { touch-action: none; user-select: none; -webkit-user-select: none; }
@media (max-width: 700px) {
  .team-table tr.team-drag td.ss-n { width: 46px; font-size: .85rem; }
  .team-table col.c-n { width: 46px; }
  .team-table tr.team-drag td { padding-top: 5px; padding-bottom: 5px; }
}
/* 2027 performance team, Sorted: Pride 1, Pride 2, Performance team and See Sunday in one row on a wide screen;
   Cut below, folded until opened. Each list can be folded by its title. */
details.team-list > summary { list-style: none; cursor: pointer; }
details.team-list > summary::-webkit-details-marker { display: none; }
details.team-list > summary h2::before { content: '▾ '; color: var(--muted); font-size: .8em; }
details.team-list:not([open]) > summary h2::before { content: '▸ '; }
details.team-list:not([open]) > summary h2 { margin-bottom: 0; }
.team-sorted-grid .team-cut { grid-column: 1 / -1; }
@media (min-width: 1100px) {
  .team-sorted-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
  .team-sorted-grid .team-list { padding: 8px; }
  .team-sorted-grid .team-table col.c-n { width: 38px; }
  .team-sorted-grid .team-table col.c-att { width: 74px; }
  .team-sorted-grid .team-table col.c-pick { width: 92px; }
  .team-sorted-grid .team-table td.tm-att .status-pill { font-size: .6rem; padding: 0 4px; }
  .team-sorted-grid .team-table select { font-size: .7rem; }
}
@media (min-width: 1100px) {
  .team-sorted-grid .team-table col.c-n { width: 34px; }
  .team-sorted-grid .team-table col.c-att { width: 64px; }
  .team-sorted-grid .team-table col.c-pick { width: 70px; }
  .team-sorted-grid .team-table td.tm-att .status-pill { max-width: 100%; overflow: hidden; text-overflow: ellipsis; display: inline-block; vertical-align: middle; }
  .team-sorted-grid .team-table select { font-size: .66rem; }
}
/* 2027 performance team: smaller numbers (and drag handle) so two-digit ranks fit. */
@media (min-width: 701px) {
  .team-table td.ss-n { font-size: .66rem; padding: 0 2px 0 1px; letter-spacing: -.01em; white-space: nowrap; overflow: visible; text-overflow: clip; }
  .team-table tr.team-drag td.ss-n::before { font-size: .62rem; margin-right: 1px; }
}

/* 2027 performance team decisions: Only attended, and the 2027 group counts. */
.team-head .team-attended { margin: 0; }
.team-table tr[hidden], .team-table[hidden] { display: none; }
.team-grp-counts { margin-top: -4px; }
.team-count.tg { background: #fff; border: 1px solid var(--line, #e2eae3); font-weight: 600; }
.team-count.tg1 { border-color: #9fb3ec; }
.team-count.tg2 { border-color: #c6d8a0; }
.team-count.tg3 { border-color: #9fd8b9; }
.team-count .tg-of { font-weight: 400; color: var(--muted); font-size: .72rem; margin-left: 4px; }
/* 2027 performance team decisions, Sorted: each 2027 group outlined and labelled. */
.team-summary { margin: 2px 0 8px; }
.team-sorted-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; align-items: start; }
.team-grp { margin: 0; min-width: 0; border: 2px solid var(--line, #d9dde8); border-radius: 12px; padding: 2px 8px 8px; }
.team-grp > legend { padding: 0 6px; font-weight: 800; font-size: .95rem; }
.team-grp.tg1 { border-color: #9fb3ec; } .team-grp.tg1 > legend { color: #2f7d4f; }
.team-grp.tg2 { border-color: #c6d8a0; } .team-grp.tg2 > legend { color: #6b2fb3; }
.team-grp.tg3 { border-color: #f3b8b3; } .team-grp.tg3 > legend { color: #b42318; }
.team-grp-lists { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 8px; align-items: start; }
.team-grp .team-list { margin: 0; }
.team-grp.tg3 .team-grp-lists { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 1100px) {
  .team-sorted-grid { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: 10px; }
  .team-grp.tg3 { grid-column: 1 / -1; }
  .team-grp-lists { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Player page: add a camp to Camp history. */
.add-camp > summary { list-style: none; cursor: pointer; display: inline-block; }
.add-camp > summary::-webkit-details-marker { display: none; }
.add-camp-form { margin-top: 6px; gap: 6px; }
.add-camp-form select { max-width: 200px; }

/* Player database: Export sits next to Upload. */
.db-head .db-export { margin-left: auto; }
.db-head .db-export + .import-panel { margin-left: 6px; }

/* Player database: Export and Upload look the same. */
.db-head .db-export, .db-head .import-panel > summary.upload-btn {
  display: inline-flex; align-items: center; height: 28px; box-sizing: border-box; padding: 0 12px; font-size: .8rem; font-weight: 600;
  border: 1px solid #ccd8ce; border-radius: 7px; background: #fff; color: var(--navy, #1f4d36); line-height: 1; cursor: pointer;
}
.db-head .db-export:hover, .db-head .import-panel > summary.upload-btn:hover { background: #eef4ef; }

/* 2027 decisions: row 1 Group 1 | Group 2, row 2 Group 2.5 (Decide Sunday) | Group 3 (Cut). */
.team-grp.tg25 { border-color: #f0c98a; } .team-grp.tg25 > legend { color: #8a5a00; }
.team-grp.tg25 .team-grp-lists, .team-grp.tg3 .team-grp-lists { grid-template-columns: minmax(0, 1fr) !important; }
@media (min-width: 1100px) {
  .team-grp.tg3 { grid-column: auto; }
}
.team-table tr.team-empty td { color: var(--muted); font-size: .72rem; text-align: center; padding: 10px 4px; border-style: dashed; }

/* Player page: a more compact Camp history. */
.two-col .panel table.data.compact[data-player] td { padding-top: 3px; padding-bottom: 3px; vertical-align: middle; }
.two-col .panel table.data.compact[data-player] td select { font-size: .78rem; padding: 1px 4px; height: 26px; }
.two-col .panel table.data.compact[data-player] .att-pill, .two-col .panel table.data.compact[data-player] .badge { font-size: .72rem; }
.two-col .panel table.data.compact[data-player] .first-tag { font-size: .62rem; }
/* Player page: Separate / Combined layout, and the combined table. */
.pp-view-toggle { margin: 4px 0 8px; }
.two-col[hidden], .pp-combined[hidden] { display: none !important; }
.pp-combined-table td { vertical-align: top; padding-top: 4px; padding-bottom: 4px; }
.pp-combined-table td.pp-camp { white-space: nowrap; }
.pp-combined-table .att-pill, .pp-combined-table .badge { font-size: .72rem; }
.pp-combined-table .pp-note { margin: 0 0 4px; line-height: 1.35; }
.pp-combined-table .pp-note:last-child { margin-bottom: 0; }
.pp-combined-table tr.pp-overview-row td { background: #f7faf7; }

/* Player profile link: email code for players without a Google account. */
.share-code { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line, #e2eae3); text-align: left; }
.share-code input { width: 100%; box-sizing: border-box; }

/* Camp page: groups before camp / Saturday / Sunday, and the past-camp editor. */
.groups-head .gb-day a.button { border: 0; border-radius: 0; padding: 5px 12px; font-size: .82rem; background: #fff; color: var(--muted); text-decoration: none; }
.groups-head .gb-day a.button.on { background: var(--navy); color: #fff; }
.cell-editor .ce-row { gap: 10px; margin-bottom: 6px; flex-wrap: wrap; }
.cell-editor .ce-row label { display: flex; flex-direction: column; gap: 2px; font-weight: 600; }
.cell-editor select { font-size: .85rem; }

/* Player page: overview in the header, smaller facts, and the Camps table. */
.player-facts dt { font-size: .66rem; }
.player-facts dd input.cell, .player-facts dd select.cell { font-size: .82rem; padding: 3px 6px; height: auto; }
.player-facts .wide dd input.cell { font-size: .76rem; }
.pp-overview { margin-top: 10px; border-top: 1px solid var(--line, #e2eae3); padding-top: 8px; }
.pp-overview h3 { font-size: .8rem; margin: 0 0 4px; color: var(--muted); }
.pp-overview .notes li { padding: 4px 0; }
.pp-overview .notes p { margin: 0; font-size: .86rem; }
.pp-combined-table td { vertical-align: top; }
.pp-combined-table td.pp-edit { cursor: default; }
.pp-combined-table td.pp-edit select { font-size: .78rem; }
.pp-combined-table .pp-grp { font-size: .78rem; }
.pp-combined-table .badge.perf { font-size: .62rem; }
.pp-combined-table td.pp-notes { width: 55%; max-width: 0; }
.pp-note { margin: 0 0 2px; font-size: .74rem; }
.pp-note > summary { list-style: none; cursor: pointer; display: flex; gap: 6px; align-items: baseline; white-space: nowrap; overflow: hidden; }
.pp-note > summary::-webkit-details-marker { display: none; }
.pp-note > summary::before { content: '▸'; color: var(--muted); font-size: .65rem; flex: none; }
.pp-note[open] > summary::before { content: '▾'; }
.pp-note .pp-note-text { overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.pp-note .pp-note-by { color: var(--muted); font-size: .66rem; flex: none; }
.pp-note[open] > summary .pp-note-text, .pp-note[open] > summary .pp-note-by { display: none; }
.pp-note[open] > summary::after { content: 'Hide'; color: var(--muted); font-size: .66rem; }
.pp-note .notes { margin: 2px 0 4px 12px; }
.pp-note .notes p { font-size: .8rem; margin: 0; }
.pp-notes .quick-note > summary { font-size: .7rem; }
.pp-camps[hidden], .pp-feedback[hidden] { display: none !important; }
/* Camp spreadsheet: the group tables stretch to fill the row (four across with No group yet, three wider without). */
.ss-groups { grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)) !important; }
.gb-out-list + .sheet-sync, section.panel > .sheet-sync:last-child { margin-top: 14px; padding-top: 10px; border-top: 1px solid var(--line, #e2eae3); }

/* Admin: old player profiles. */
.old-profiles td { vertical-align: top; }
.old-profiles .old-hit { background: #fff4d6; font-weight: 600; }

/* Past-camp editor: compact. */
.cell-editor { padding: 6px; font-size: .78rem; }
.cell-editor .ce-row { gap: 6px; margin-bottom: 4px; }
.cell-editor .ce-row label { font-size: .68rem; gap: 1px; }
.cell-editor select { font-size: .74rem; padding: 1px 4px; height: 24px; }
.cell-editor textarea { font-size: .78rem; min-height: 38px; padding: 4px 6px; }
.cell-editor .row button { font-size: .72rem; padding: 2px 10px; }
@media (max-width: 700px) { .cell-editor select, .cell-editor textarea { font-size: 16px; } }
/* Not coming list: went inactive after the camp. */
.gb-out-list td.after-inactive { color: #8a1f12; }

/* Player profile document: unfinished parts. */
.doc-pending .doc-pending-note { color: #8a5a00; font-weight: 600; }
.doc-flag { max-width: 820px; margin: 14px auto 4px; padding: 6px 10px; background: #fff4d6; border-radius: 8px; font-size: .8rem; color: #8a5a00; }
.doc-view-toggle a.button { border: 0; border-radius: 0; padding: 4px 12px; font-size: .8rem; background: #fff; color: var(--muted); text-decoration: none; }
.doc-view-toggle a.button.on { background: var(--navy); color: #fff; }

/* Testing data: tidy rows. */
.testing-grid td, .testing-grid th { vertical-align: top; }
.testing-grid .cell-clip { max-height: 4.1em; overflow-y: auto; line-height: 1.35; white-space: pre-line; }
.testing-grid td.long { min-width: 220px; }
.testing-grid .grid-filter { display: block; margin-top: 3px; font-size: .7rem; font-weight: 500; padding: 1px 2px; max-width: 120px; }
.testing-grid .grid-filter.on { border-color: var(--accent, #2f7d4f); color: var(--accent, #2f7d4f); font-weight: 700; }
.testing-grid .coach-done { display: block; margin-top: 3px; width: fit-content; }
.testing-grid .lock-btn { text-decoration: none; padding: 0 2px; }
.testing-grid tr[hidden] { display: none; }
.name-filter { font-size: .85rem; padding: 5px 8px; min-width: 160px; }
/* Player page: one Overview box. */
.pp-overview-text { font-size: .86rem; padding: 4px 6px; border-radius: 6px; min-height: 1.4em; cursor: text; }
.pp-overview-text:hover { background: #f7faf7; }
.pp-overview-text textarea { width: 100%; box-sizing: border-box; font-size: .86rem; }
.pp-overview h3 { color: var(--ink, #1f3a2c); }
/* Camp overview: Goals is a subheader like Attendance, with room around it; space under the groups heading. */
.goals-details { margin-top: 18px; }
.goals-details > summary h3.details-sub { display: inline; margin: 0; }
.groups-head + * { margin-top: 10px; }
.panel .groups-head { margin-bottom: 8px; }

/* Camp workspace: Goals heading matches Attendance. */
.goals-details > summary { font-size: .78rem; margin-bottom: 6px; }
.goals-details > summary h3.details-sub { font-size: .78rem; display: inline; margin: 0; }

/* Testing data: lock by the name, a smaller status, resizable feedback columns. */
.testing-grid th.sticky .name-lock, .testing-grid th.sticky .lock-btn { margin-left: 4px; font-size: .72rem; }
.testing-grid select.status-select { font-size: .7rem; padding: 1px 2px; margin: 0; height: auto; min-height: 0; line-height: 1.3; border-radius: 5px; }
.testing-grid .col-resizer { position: absolute; top: 0; right: 0; width: 9px; height: 100%; cursor: col-resize; z-index: 3; border-right: 2px solid #d7dcea; box-sizing: border-box; }
.testing-grid .col-resizer:hover, .testing-grid .col-resizer.on { background: rgba(29, 78, 216, .25); }

/* Profile statuses: soft colours throughout. */
.s-complete { background: #e7f6ec; color: #17803d; }
select.status-select.s-complete { background: #e7f6ec; color: #17803d; }
.s-shared { background: #e6efe7; color: #24503a; }

/* Player page: compact details. */
.player-card .player-facts { display: flex; flex-wrap: wrap; gap: 6px 12px; max-width: none; align-items: flex-end; }
.player-card .player-facts > div, .player-card .player-facts > details { flex: 0 0 auto; }
.player-card .player-facts .pf-email { width: 210px; }
.player-card .player-facts .pf-dob { width: 100px; }
.player-card .player-facts .pf-grp { width: 140px; }
.player-card .player-facts .pf-aka { flex: 1 1 200px; min-width: 180px; }
.player-card .player-facts .pf-add { align-self: center; }
.player-card .player-facts dt { margin-bottom: 1px; }
@media (max-width: 700px) { .player-card .player-facts > div { width: 100% !important; flex-basis: 100%; } }

/* Shared feedback: smaller text. */
.pp-feedback { font-size: .84rem; }
.pp-feedback .note-group h3 { font-size: .9rem; }
.pp-feedback .notes p { font-size: .84rem; }

/* Player profile document: the incomplete bar sits on the document. */
article.profile > .doc-flag { max-width: none; margin: -4px 0 12px; }

/* Evaluation report: compact tables like the evaluation tables. */
.eval-report table.er-table { font-size: .82rem; border-collapse: collapse; }
.eval-report table.er-table th { font-size: .74rem; padding: 5px 8px; }
.eval-report table.er-table td { padding: 5px 8px; }
.eval-report table.er-overall td { font-size: .95rem; }
.eval-report h2.er-h { font-size: .95rem; margin: 14px 0 6px; }
.eval-report .er-sec { font-weight: 700; }
.eval-report .er-scale { display: flex; flex-wrap: wrap; gap: 2px 12px; margin-top: 16px; font-size: .7rem; color: var(--muted, #6b7385); }
.eval-report .er-scale strong { color: inherit; }
.eval-report .er-scale-head { font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }

/* Testing data: locked feedback reads as locked. */
.testing-grid textarea[readonly] { background: #f6f8f5; color: #4a5266; border-style: dashed; }
/* Player page: status changed by double-click; only the title toggles a section. */
.status-dbl { cursor: default; }
.status-dbl select.status-select { font-size: .74rem; padding: 1px 4px; }
details.trial-panel > summary, details.eval-box > summary, .pp-feedback details.note-group > summary { cursor: default; }
details.trial-panel > summary > strong, details.eval-box > summary > h3, .pp-feedback details.note-group > summary > h3 { cursor: pointer; }

/* Player page: the trials status is a pill you click to change. */
select.status-pill-select { -webkit-appearance: none; appearance: none; background-image: none; border: 0; border-radius: 99px; padding: 2px 10px; font-size: .74rem; font-weight: 600; cursor: pointer; width: auto; height: auto; min-height: 0; line-height: 1.4; field-sizing: content; }
select.status-pill-select:not([class*=" s-"]) { background: #eef4ef; }
/* Camp notes: a smaller box. */
.pp-notes .quick-note textarea { font-size: .78rem; padding: 4px 6px; min-height: 0; line-height: 1.35; }
.pp-notes .quick-note .button, .pp-notes .quick-note button { font-size: .74rem; padding: 3px 10px; }
.pp-notes .quick-note summary { font-size: .74rem; }

/* Testing data: the name column's row lines. At some screen scales Chrome rounds the sticky name cells so each
   one covers the line under the one above; drawing the line along the top of each cell (painted last) keeps it. */
table.testing-grid tbody th.sticky { border-bottom-color: transparent; box-shadow: inset 0 1px 0 var(--line); }
table.testing-grid tbody tr:first-child th.sticky { box-shadow: none; }
table.testing-grid tbody tr:last-child th.sticky { border-bottom-color: var(--line); }

/* Testing data: every cell draws its row line along its top (the name column has to, see above), so the lines
   line up across the whole row. */
table.testing-grid tbody td { border-bottom-color: transparent; box-shadow: inset 0 1px 0 var(--line); }
table.testing-grid tbody tr:first-child td { box-shadow: none; }
table.testing-grid tbody tr:last-child td { border-bottom-color: var(--line); }
/* Resizable headings stay sticky (the grip is positioned inside the sticky heading). */
table.testing-grid thead th[data-resize] { position: sticky; }

/* Coach evaluations: small skill names, column filters, the expand hint on player rows only, editable own scores. */
[data-done-table] thead tr:nth-child(2) th { font-size: .6rem; font-weight: 600; line-height: 1.15; padding: 3px 3px; }
[data-done-table] .grid-filter { display: block; margin-top: 3px; font-size: .68rem; font-weight: 500; padding: 1px 2px; max-width: 110px; }
[data-done-table] .grid-filter.on { border-color: var(--accent, #2f7d4f); color: var(--accent, #2f7d4f); font-weight: 700; }
.eval-overview tr[hidden] { display: none; }
[data-done-table] tbody tr.coach-row[data-no-open] { cursor: default; }
[data-done-table] tbody tr.coach-row[data-no-open]:hover th.sticky::after { content: none; }
.eval-overview tr[data-mine] td[data-skill] { cursor: cell; }
.eval-overview tr[data-mine] td[data-skill]:hover { outline: 1px dashed #9aa6c4; outline-offset: -2px; }
.eval-overview td[data-skill] select { font-size: .74rem; padding: 0 2px; width: 3.6em; }
.eval-mine-toggle { display: inline-flex; align-items: center; gap: 5px; font-size: .82rem; white-space: nowrap; }
.filters label.eval-mine-toggle { flex-direction: row !important; align-items: center; gap: 5px; text-transform: none; letter-spacing: 0; font-size: .82rem; color: var(--ink, #1f3a2c); }

/* Published (was Shared). */
.s-published { background: #e6efe7; color: #24503a; }
select.status-select.s-published { background: #e6efe7; color: #24503a; }
.doc-flag.complete { background: #e6efe7; color: #24503a; }
.pub-tag { display: block; width: fit-content; margin: 2px auto 0; font-size: .6rem; font-weight: 700; padding: 0 5px; border-radius: 99px; background: #e6efe7; color: #24503a; }
.emailed-chip { white-space: nowrap; }

/* Publish / email dialogs. */
dialog.publish-dialog { width: min(640px, calc(100vw - 32px)); max-height: calc(100vh - 40px); border: 0; border-radius: 12px; padding: 18px 20px; box-shadow: 0 20px 50px rgba(15, 23, 60, .3); }
dialog.publish-dialog::backdrop { background: rgba(15, 23, 60, .35); }
.publish-dialog h2 { margin: 0 0 12px; font-size: 1.15rem; }
.publish-dialog fieldset { border: 1px solid var(--line, #e2eae3); border-radius: 8px; padding: 8px 12px 10px; margin: 0 0 12px; }
.publish-dialog legend { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); padding: 0 4px; }
.publish-dialog .pd-doc, .publish-dialog .pd-to, .publish-dialog .pd-check { display: flex; align-items: center; gap: 8px; font-size: .86rem; padding: 3px 0; }
.publish-dialog .pd-doc.incomplete { color: var(--muted); }
.publish-dialog .pd-state { margin-left: auto; font-size: .7rem; font-weight: 600; padding: 1px 8px; border-radius: 99px; background: #fff4d6; color: #8a5a00; white-space: nowrap; }
.publish-dialog .pd-state.published { background: #e6efe7; color: #24503a; }
.publish-dialog .pd-state.complete { background: #e7f6ec; color: #17803d; }
.publish-dialog input[name="to_other"] { margin-top: 6px; width: 100%; box-sizing: border-box; }
.publish-dialog .pd-field { display: flex; flex-direction: column; gap: 3px; margin-bottom: 10px; font-size: .74rem; font-weight: 600; color: var(--muted); }
.publish-dialog .pd-field input, .publish-dialog .pd-field select, .publish-dialog .pd-field textarea { font-size: .86rem; font-weight: 400; color: var(--ink, #1f3a2c); width: 100%; box-sizing: border-box; }
.publish-dialog .pd-field textarea { font-family: inherit; line-height: 1.45; }
.publish-dialog .pd-two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (max-width: 600px) { .publish-dialog .pd-two { grid-template-columns: 1fr; } }
.publish-dialog .pd-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.publish-dialog .pd-actions .spacer { flex: 1; }
.publish-dialog .pd-status { font-size: .82rem; color: var(--navy, #1f4d36); min-height: 1.2em; margin: 4px 0 10px; }
.publish-dialog .pd-status ul { margin: 4px 0 0; padding-left: 18px; font-size: .78rem; color: #8a1f12; }
.publish-dialog label.pd-doc, .publish-dialog label.pd-to, .publish-dialog label.pd-check { flex-direction: row !important; align-items: center !important; text-align: left; font-weight: 400; }
.publish-dialog label.pd-doc > span:first-of-type { font-weight: 600; }
.publish-dialog input[type=checkbox] { width: auto; margin: 0; flex: none; }

/* Coach evaluations: smaller headings. */
[data-done-table] thead tr:first-child th { font-size: .7rem; font-weight: 600; }
[data-done-table] thead tr:first-child th.sec { font-size: .74rem; }
.eval-overview .done-pct { font-size: .74rem; font-weight: 700; }
/* Buttons under a table. */
.table-actions { display: flex; gap: 8px; justify-content: flex-end; align-items: center; margin: -6px 0 16px; }
.table-actions .button, .table-actions button, .table-actions summary.button { font-size: .76rem; padding: 4px 10px; }
.table-actions .export-evals .export-box { top: auto; bottom: calc(100% + 6px); }
/* Bulk publish: the count, and the list to untick players. */
.publish-dialog .bulk-head { display: flex; align-items: center; gap: 10px; }
.publish-dialog .bulk-head h2 { margin: 0; }
.publish-dialog .bulk-n { margin-left: auto; min-width: 2em; text-align: center; font-size: 1.1rem; font-weight: 700; color: #fff; background: var(--navy, #1f4d36); border-radius: 99px; padding: 2px 10px; }
.publish-dialog [data-bulk-select] { margin: 6px 0 4px; padding: 0; }
.publish-dialog .bulk-list { max-height: 190px; overflow: auto; border: 1px solid var(--line, #e2eae3); border-radius: 8px; padding: 6px 10px; margin-bottom: 10px; columns: 2; }
.publish-dialog .bulk-list label { break-inside: avoid; }

/* Player profile document: documents wrapped for their links still sit apart as cards. */
.doc-wrap + .doc-wrap, .profile + .doc-wrap, .doc-wrap + .profile { margin-top: 24px; }
@media print { .doc-wrap + .doc-wrap, .profile + .doc-wrap, .doc-wrap + .profile { margin-top: 0; break-before: page; } }
/* Testing data: the sort arrow sits in the heading's corner, so it never wraps under a filter. */
table.testing-grid thead th[data-sorted]::after { position: absolute; top: 3px; right: 4px; }

/* Player profile: tests tables (March 2025 layout) and numbered feedback. */
.profile table.tests { margin-bottom: 18px; }
.profile table.tests th.corner { background: #dbe5f5; }
.profile table.tests tr.bench.tb-avg td, .profile table.tests tr.bench.tb-avg th { background: #d9d9d9; }
.profile table.tests tr.bench.tb-best td, .profile table.tests tr.bench.tb-best th { background: #a8e05f; }
.profile table.tests tr.bench.tb-g1 td, .profile table.tests tr.bench.tb-g1 th { background: #ffee33; }
.profile table.tests tr.bench.tb-g2 td, .profile table.tests tr.bench.tb-g2 th { background: #c9c9c9; }
.profile ol.p-points { margin: 4px 0 14px; padding-left: 22px; font-size: .92rem; line-height: 1.45; }
.profile ol.p-points li { margin-bottom: 4px; }

/* Camp workspace: the small Export button by the layout toggle. */
.groups-head .gb-export, .team-head .gb-export { font-size: .72rem; padding: 3px 8px; }

/* Long notes: a preview of a few lines with Read more. */
.clamped { display: -webkit-box; -webkit-line-clamp: var(--lines, 6); -webkit-box-orient: vertical; overflow: hidden; white-space: pre-line; }
.clamped.open { display: block; }
.read-more { padding: 0; margin-top: 2px; }
/* Player page: an evaluation nobody has started is just a button. */
.eval-add { margin: 0 0 14px; }
.eval-add > summary { list-style: none; display: inline-block; cursor: pointer; }
.eval-add > summary::-webkit-details-marker { display: none; }
.eval-add[open] > summary { margin-bottom: 8px; }
/* Player page on a phone: each camp is a card (camp, then attendance and group, then the notes full width), so
   nothing scrolls sideways. Notes show two lines and Read more. */
@media (max-width: 700px) {
  .pp-combined-table thead { display: none; }
  .pp-combined-table, .pp-combined-table tbody { display: block; width: 100%; }
  .pp-combined-table tr { display: grid; grid-template-columns: 1fr auto auto; gap: 2px 12px; align-items: start; padding: 8px 2px; border-bottom: 1px solid var(--line); }
  .pp-combined-table tr[hidden] { display: none; }
  .pp-combined-table td { display: block; padding: 0 !important; border: 0 !important; }
  .pp-combined-table td.pp-camp { white-space: normal; }
  .pp-combined-table td.pp-camp .pp-camp-name { display: block; font-weight: 600; }
  .pp-combined-table td.pp-camp .badge, .pp-combined-table td.pp-camp .first-tag { margin: 2px 4px 0 0; }
  .pp-combined-table td.pp-notes { grid-column: 1 / -1; width: auto; max-width: none; margin-top: 4px; }
  .pp-combined-table tr.older-toggle-row { display: block; }
  .pp-note > summary { display: block; white-space: normal; }
  .pp-note > summary::before { content: none; }
  .pp-note .pp-note-text { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; white-space: normal; font-size: .8rem; }
  .pp-note .pp-note-by { display: inline; }
  .pp-note > summary::after { content: 'Read more'; color: var(--navy, #1f4d36); font-size: .7rem; margin-left: 6px; }
  .pp-note[open] > summary::after { content: 'Hide'; color: var(--muted); }
  .pp-note .notes { margin-left: 0; }
  .pp-note .notes .tiny { display: flex; flex-wrap: wrap; gap: 2px 8px; align-items: baseline; }
}

/* Profile headings in colour: main headings navy, sub-headings a lighter blue. */
.profile h2 { color: #1f4d36; }
.profile h3.p-subhead { color: #2e5aa8; }
/* Profile template editor: the testing table's headings and comparison row names; the Variables list. */
.tpl-heads { border: 0; padding: 0; margin: 8px 0 0; display: grid; gap: 8px; }
.tpl-head-group { border: 1px solid var(--line, #e2eae3); border-radius: 8px; padding: 6px; display: grid; gap: 4px; }
.tpl-head-group input { font-size: .8rem; padding: 4px 6px; width: 100%; }
.tpl-head-main { font-weight: 600; text-align: center; background: #eef4ef; }
.tpl-head-subs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; }
.tpl-head-subs input { text-align: center; }
.tpl-bench { display: grid !important; grid-template-columns: 1fr; gap: 4px !important; }
.tpl-bench-row { display: flex; align-items: center; gap: 6px; }
.tpl-bench-row input[data-bench-label] { flex: 1; font-size: .8rem; padding: 3px 6px; }
.tpl-vars { position: relative; margin-left: auto; }
.tpl-vars > summary { list-style: none; cursor: pointer; }
.tpl-vars > summary::-webkit-details-marker { display: none; }
.tpl-vars-box { position: absolute; right: 0; top: calc(100% + 6px); z-index: 20; background: var(--card, #fff); border: 1px solid var(--line, #e2eae3); border-radius: 10px; box-shadow: 0 8px 24px rgba(0, 0, 0, .12); padding: 10px 12px; min-width: 300px; }
.tpl-vars-box p { margin: 0 0 6px; }

/* Profile template: See variables ▾ (the arrow turns when open). */
.tpl-vars-arrow { display: inline-block; margin-left: 2px; transition: transform .15s; }
.tpl-vars[open] .tpl-vars-arrow { transform: rotate(180deg); }
/* Analytics → Tournament Analysis. */
.tour-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 8px; margin: 6px 0 14px; }
.tour-card { border: 1px solid var(--line, #e2eae3); border-radius: 10px; padding: 8px 10px; display: flex; flex-direction: column; gap: 2px; background: #f9fafc; }
.tour-card strong { font-size: 1.15rem; color: #1f4d36; }
.tour-table th { font-size: .72rem; }
.tour-table td { font-size: .82rem; white-space: nowrap; }
.tour-table tr.muted td { color: var(--muted); }
.tour-d { font-size: .7rem; font-weight: 600; }
.tour-d.better { color: #1e7b3c; }
.tour-d.worse { color: #b42318; }
.tour-d.same { color: var(--muted); }
.tour-notes { margin: 4px 0 12px; padding-left: 18px; font-size: .88rem; }
.tour-notes li { margin-bottom: 3px; }

/* Player's own page (share link): their details and camps beside their documents. */
.me-layout { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 18px; align-items: start; }
.me-side { grid-column: 2; grid-row: 1; position: sticky; top: 12px; display: grid; gap: 12px; }
.me-docs { grid-column: 1; grid-row: 1; min-width: 0; }
@media (max-width: 900px) { .me-layout { grid-template-columns: 1fr; } .me-side, .me-docs { grid-column: 1; grid-row: auto; position: static; } }
@media print { .me-layout { display: block; } }
.me-card { background: var(--card, #fff); border: 1px solid var(--line, #e2eae3); border-radius: 12px; padding: 12px 14px; font-size: .86rem; }
.me-top { display: flex; align-items: center; gap: 10px; }
.me-photo { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; flex: none; }
.me-initials { display: inline-flex; align-items: center; justify-content: center; background: #1f4d36; color: #fff; font-weight: 700; }
.me-who { display: flex; flex-direction: column; min-width: 0; }
.me-who .tiny { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.me-edit-btn { margin-left: auto; }
.me-facts { display: grid; grid-template-columns: auto 1fr; gap: 4px 10px; margin: 10px 0 0; }
.me-facts dt { color: var(--muted); font-size: .76rem; }
.me-facts dd { margin: 0; word-break: break-all; }
.me-edit { display: none; margin-top: 10px; gap: 8px; }
.me-card.editing .me-edit { display: grid; }
.me-card.editing .me-facts, .me-card.editing .me-edit-btn { display: none; }
.me-edit label { display: grid; gap: 2px; font-size: .78rem; font-weight: 600; }
.me-edit input { font-weight: 400; }
.me-emails { border: 1px solid var(--line, #e2eae3); border-radius: 8px; padding: 6px 8px; display: grid; gap: 4px; }
.me-emails legend { font-size: .78rem; font-weight: 600; padding: 0 4px; }
.me-email-row { display: flex; align-items: center; gap: 8px; }
.me-email-row .me-default { display: flex !important; align-items: center; gap: 4px; font-weight: 400 !important; word-break: break-all; }
.me-email-row .me-remove { display: flex !important; align-items: center; gap: 2px; margin-left: auto; font-weight: 400 !important; }
.me-msg { color: #1e7b3c; margin: 6px 0 0; }
.me-camps h3 { margin: 0 0 6px; font-size: .95rem; }
.me-camps select { font-size: .78rem; padding: 2px 4px; }
.me-camps select.me-confirm { background: #fff7e0; }
.me-camps td { vertical-align: middle; }
.me-email-row input[type=radio], .me-email-row input[type=checkbox] { width: auto; margin: 0; flex: none; }
.me-email-row .me-default { flex: 1; min-width: 0; }
.me-email-row .me-default, .me-email-row .me-remove { flex-direction: row !important; align-items: center !important; }

/* Player page: Mark complete for me on a trials' section. */
.trial-task { display: flex; align-items: center; gap: 10px; margin: 8px 0 4px; }
.trial-done { color: #1e7b3c; font-weight: 600; }

/* Testing data: double-click editing (admins). */
.testing-grid td[data-dbl-field] { cursor: cell; }
.testing-grid td input.cell-dbl { width: 100%; min-width: 4em; font: inherit; padding: 2px 4px; text-align: center; }
.testing-grid td.saving { opacity: .6; }
.testing-grid td.saved { box-shadow: inset 0 0 0 2px #1e7b3c; }
/* Player page: the player's own group's median column. */
.compare-table .own-grp { background-image: linear-gradient(rgba(31, 77, 54, .06), rgba(31, 77, 54, .06)); font-weight: 600; }

/* Coach evaluations: the Required column. */
.eval-overview .req-col { white-space: nowrap; min-width: 84px; }

/* My tasks (admins): Ready to publish. */
.publish-list { margin: 4px 0 6px; padding-left: 18px; }
.publish-list li { margin-bottom: 3px; }
.login-player { margin-top: 10px; }

/* Selection evaluation: header facts, score tiles, tinted scores, score guide chips. */
.eval-report .er-head .p-sub { margin-bottom: 6px; }
.eval-report .er-meta { list-style: none; padding: 0; margin: 4px 0 10px; display: flex; flex-wrap: wrap; gap: 6px; }
.eval-report .er-meta li { font-size: .8rem; background: #eef4ef; color: #1f4d36; border-radius: 99px; padding: 3px 10px; font-weight: 600; }
.eval-report .er-tiles { display: grid; grid-template-columns: 1.3fr repeat(3, 1fr); gap: 10px; margin: 6px 0 18px; }
.eval-report .er-tile { border-radius: 12px; padding: 10px 12px; display: flex; flex-direction: column; gap: 2px; border: 1px solid #e3e7f0; background: #f7faf7; }
.eval-report .er-tile span { font-size: .72rem; text-transform: uppercase; letter-spacing: .04em; color: #4b5e52; font-weight: 600; }
.eval-report .er-tile strong { font-size: 1.6rem; line-height: 1.1; color: #1f4d36; }
.eval-report .er-tile.er-main { background: #1f4d36; border-color: #1f4d36; }
.eval-report .er-tile.er-main span, .eval-report .er-tile.er-main strong { color: #fff; }
.eval-report .er-section { margin-bottom: 4px; }
.eval-report h2.er-h { display: flex; align-items: baseline; gap: 8px; }
.eval-report .er-h-score { font-size: .8rem; font-weight: 700; color: #1f4d36; background: #eef4ef; border-radius: 99px; padding: 1px 8px; }
.eval-report table.er-skills td { font-weight: 700; font-size: .9rem; }
.eval-report .er-b1 { background: #fde2e1 !important; }
.eval-report .er-b2 { background: #fdeedc !important; }
.eval-report .er-b3 { background: #f3f6f2 !important; }
.eval-report .er-b4 { background: #e4f3e6 !important; }
.eval-report .er-b5 { background: #c9ebcf !important; }
.eval-report .er-b6 { background: #a8e0b2 !important; }
.eval-report .er-tile.er-main.er-b1, .eval-report .er-tile.er-main.er-b2, .eval-report .er-tile.er-main.er-b3,
.eval-report .er-tile.er-main.er-b4, .eval-report .er-tile.er-main.er-b5, .eval-report .er-tile.er-main.er-b6 { background: #1f4d36 !important; }
.eval-report .er-scale { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 16px; font-size: .72rem; color: #4b5e52; }
.eval-report .er-chip { border-radius: 99px; padding: 2px 8px; }
@media (max-width: 600px) { .eval-report .er-tiles { grid-template-columns: 1fr 1fr; } }
@media print { .eval-report .er-tile.er-main, .eval-report .er-b1, .eval-report .er-b2, .eval-report .er-b3, .eval-report .er-b4, .eval-report .er-b5, .eval-report .er-b6 { -webkit-print-color-adjust: exact; print-color-adjust: exact; } }
.eval-report .er-scale-note { flex-basis: 100%; order: 99; font-style: italic; color: #4b5e52; }
/* Selection evaluation: scores and tiles plain grey; the colours stay only in the score guide. */
.eval-report .er-tile:not(.er-main) { background: #f3f6f2 !important; }

/* Selection evaluation on a phone: smaller headings that wrap between words (hyphenated if they must), compact chips and tiles. */
.eval-report table.er-skills th { hyphens: auto; -webkit-hyphens: auto; word-break: normal; overflow-wrap: normal; }
@media (max-width: 600px) {
  .eval-report table.er-skills th { font-size: .58rem; padding: 4px 2px; line-height: 1.2; letter-spacing: -.01em; }
  .eval-report table.er-skills td { font-size: .8rem; padding: 4px 2px; }
  .eval-report .er-meta { gap: 4px; }
  .eval-report .er-meta li { font-size: .68rem; padding: 2px 8px; }
  .eval-report .er-tiles { gap: 6px; margin-bottom: 12px; }
  .eval-report .er-tile { padding: 6px 8px; }
  .eval-report .er-tile span { font-size: .6rem; }
  .eval-report .er-tile strong { font-size: 1.2rem; }
  .eval-report h2.er-h { font-size: .85rem; }
  .eval-report .er-scale { font-size: .62rem; gap: 4px; }
}
/* Player profile tables on a phone: smaller text that wraps between words. */
@media (max-width: 600px) {
  .profile table.pt th, .profile table.pt td { font-size: .58rem; padding: 3px 2px; hyphens: auto; -webkit-hyphens: auto; word-break: normal; overflow-wrap: normal; }
  .profile table.pt.testing tbody th { font-size: .56rem; }
}
@media (max-width: 600px) {
  .profile table.pt.testing tbody th { min-width: 50px; white-space: normal; overflow: hidden; }
}
@media (max-width: 600px) {
  .profile table.pt.testing { table-layout: auto; }
  .profile table.pt.testing tbody th { white-space: nowrap; min-width: 0; overflow: visible; }
}
@media (max-width: 600px) { .profile table.pt.testing tbody th { white-space: normal; } .profile table.pt.testing { max-width: 100%; } }

/* Competition analytics (demo soccer dashboard) */
.sa-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; margin: 12px 0 16px; }
.sa-tile { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; display: flex; flex-direction: column; gap: 2px; }
.sa-tile strong { font-size: 1.5rem; color: var(--navy); line-height: 1.2; }
.sa-charts { display: grid; grid-template-columns: repeat(auto-fit, minmax(420px, 1fr)); gap: 0 16px; }
.sa-chart { margin: 0; }
.sa-chart figcaption { display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 8px; margin-bottom: 6px; }
.sa-chart svg { width: 100%; height: auto; display: block; }
.sa-legend { font-size: .78rem; color: var(--muted); display: inline-flex; align-items: center; gap: 6px; }
.sa-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-left: 6px; }
.sa-pair:hover rect[fill="transparent"] { fill: rgba(31,77,54,.06); }
.sa-res { display: inline-block; width: 20px; text-align: center; border-radius: 4px; font-weight: 700; font-size: .75rem; color: #fff; }
.sa-W { background: #2f7d4f; } .sa-D { background: #8a8f99; } .sa-L { background: #b42318; }
.sa-poss { display: inline-block; width: 70px; height: 8px; background: #e6efe7; border-radius: 4px; overflow: hidden; vertical-align: middle; }
.sa-poss span { display: block; height: 100%; background: #2f7d4f; border-radius: 4px; }
.demo-login button { width: 100%; }
