/* 4WStudios platform styles. Each client's colors and fonts come from clients/<id>/client.json
   (build.sh writes them into the page after this file); these are the plain fallbacks. */
:root {
  --brand: #1f2a37;
  --brand-deep: #121a24;
  --brand-tint: #e6eaf0;
  --accent: #2f6fde;
  --accent-dark: #1f56b5;
  --highlight: #a9c4ea;
  --highlight-soft: #e1ebf8;
  --fog: #f1f4f8;
  --score-hi: #ffd84d;
  --line: #d3dde8;
  --ink: #14213a;
  --muted: #55657d;
  --white: #ffffff;
  --ok: #2b7a4b;
  --ok-tint: #e2f2e8;
  --wait: #9a5d0c;
  --wait-tint: #fbf0dc;
  --danger: #b3261e;
  --danger-tint: #fbe5e3;
  --radius: 10px;
  --radius-sm: 6px;
  --display: system-ui, -apple-system, 'Segoe UI', sans-serif;
  --body: system-ui, -apple-system, 'Segoe UI', sans-serif;
  --cond: system-ui, -apple-system, 'Segoe UI', sans-serif;
  --nav-h: 64px;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--fog);
  color: var(--ink);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.5;
}
img { max-width: 100%; display: block; }
a { color: var(--brand); }
p { margin: 0; }
h1, h2, h3 { margin: 0; line-height: 1.15; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--highlight); outline-offset: 2px; border-radius: 4px; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip { position: absolute; left: -999px; top: 8px; background: var(--white); padding: 8px 12px; z-index: 50; }
.skip:focus { left: 8px; }

/* ---------- Shell ---------- */
.shell { min-height: 100vh; padding-bottom: calc(var(--nav-h) + env(safe-area-inset-bottom) + 24px); }
.shell-plain { padding-bottom: 32px; }

.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 8px 16px; padding-top: calc(8px + env(safe-area-inset-top));
  background: var(--brand); color: var(--white);
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--white); text-decoration: none; min-width: 0; }
.brand img { width: 40px; height: 40px; flex: none; }
.brand-text { display: flex; flex-direction: column; min-width: 0; }
.brand-name { font-family: var(--display); font-size: 18px; letter-spacing: 0.02em; line-height: 1.1; }
.brand-sub { font-size: 12px; color: var(--highlight); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar-actions { display: flex; gap: 4px; }
.icon-btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: 50%; color: var(--white);
}
.icon-btn:hover { background: rgba(255, 255, 255, 0.1); }
.dot {
  position: absolute; top: 6px; right: 4px; min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: 9px; background: var(--accent); color: var(--white);
  font: 600 11px/18px var(--cond); text-align: center; border: 2px solid var(--brand);
}

/* The stitched seam under the header: the app's one signature mark, in the client's accent color. */
.seam {
  position: relative;
  height: 14px;
  background: var(--white) linear-gradient(var(--line), var(--line)) 0 100% / 100% 1px no-repeat;
}
.seam::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--accent);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='14' viewBox='0 0 16 14'%3E%3Cpath d='M3 3.5 L8 7 L3 10.5 M10 3.5 L15 7 L10 10.5' fill='none' stroke='%23000' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E") 4px center / 16px 14px repeat-x;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='14' viewBox='0 0 16 14'%3E%3Cpath d='M3 3.5 L8 7 L3 10.5 M10 3.5 L15 7 L10 10.5' fill='none' stroke='%23000' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E") 4px center / 16px 14px repeat-x;
}

.page { max-width: 640px; margin: 0 auto; padding: 16px 16px 0; }

.bottomnav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
  display: flex; justify-content: space-around;
  height: calc(var(--nav-h) + env(safe-area-inset-bottom));
  padding-bottom: env(safe-area-inset-bottom);
  background: var(--white); border-top: 1px solid var(--line);
}
.nav-item {
  flex: 1; max-width: 140px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  color: var(--muted); text-decoration: none; font-size: 12px; font-weight: 600;
}
.nav-item.nav-on { color: var(--accent); }
.nav-item.nav-on .icon { stroke-width: 2.2; }

/* ---------- Type & headers ---------- */
.page-header { margin: 4px 0 16px; }
.page-header-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.page-header h1 { font-family: var(--display); font-size: 26px; font-weight: 400; color: var(--brand); letter-spacing: 0.01em; }
.back-link { display: inline-flex; align-items: center; gap: 2px; margin-bottom: 8px; font-weight: 600; text-decoration: none; color: var(--muted); }
.lead { color: var(--muted); margin: -8px 0 16px; }
.fine { color: var(--muted); font-size: 14px; }
h2 { font-size: 19px; font-weight: 700; color: var(--brand); }
.card-title { font-size: 17px; font-weight: 700; color: var(--brand); }
.division-head { font-family: var(--display); font-weight: 400; font-size: 20px; margin-bottom: 8px; }

.section { margin-top: 28px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.section-head + .fine { margin-bottom: 12px; }
.count { color: var(--muted); font-family: var(--cond); font-size: 16px; font-weight: 600; }

.stack > * + * { margin-top: 14px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.grid-3 { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 10px; }
.grid-2 > .field + .field, .grid-3 > .field + .field { margin-top: 0; }
.grid-2 > *, .grid-3 > * { min-width: 0; }
input[type='date'], input[type='time'] { -webkit-appearance: none; appearance: none; }
.actions-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.form-page { margin-bottom: 24px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 0 18px; border-radius: 8px; border: 2px solid transparent;
  font-weight: 700; font-size: 16px; text-decoration: none; cursor: pointer;
  transition: background-color 120ms ease, border-color 120ms ease;
}
.btn > span { display: inline-flex; align-items: center; gap: 6px; }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }
.btn-primary { background: var(--accent); color: var(--white); }
.btn-primary:hover:not(:disabled) { background: var(--accent-dark); }
.btn-secondary { background: var(--white); color: var(--brand); border-color: var(--brand); }
.btn-secondary:hover:not(:disabled) { background: var(--brand-tint); }
.btn-ghost { background: transparent; color: var(--brand); padding: 0 12px; }
.btn-ghost:hover:not(:disabled) { background: var(--brand-tint); }
.btn-danger { background: var(--white); color: var(--danger); border-color: var(--danger); }
.btn-danger:hover:not(:disabled) { background: var(--danger-tint); }
.btn-sm { min-height: 38px; padding: 0 12px; font-size: 15px; }
.btn-block { width: 100%; }
.btn-grow { flex: 1; }
.text-btn { background: none; border: 0; padding: 8px 0; color: var(--brand); font-weight: 600; text-decoration: underline; cursor: pointer; }

.spinner {
  width: 16px; height: 16px; border-radius: 50%;
  border: 2px solid currentColor; border-right-color: transparent;
  animation: spin 0.7s linear infinite; display: inline-block;
}
.spinner-dark { color: var(--brand); }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Forms ---------- */
.field { display: block; }
.field > label, .field-label { display: block; font-weight: 600; font-size: 15px; margin-bottom: 6px; color: var(--ink); }
.field input:not([type='checkbox']), .field select, .field textarea, input[type='search'] {
  width: 100%; min-height: 48px; padding: 10px 12px;
  border: 1.5px solid var(--line); border-radius: 8px; background: var(--white);
  font-size: 16px;
}
.field textarea { min-height: 88px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus, input[type='search']:focus {
  outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--highlight-soft);
}
.field-error input, .field-error select { border-color: var(--danger); }
.field-msg { margin-top: 6px; font-size: 14px; color: var(--muted); }
.field-msg.error { color: var(--danger); }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 500; cursor: pointer; }
.check input { width: 22px; height: 22px; margin: 1px 0 0; accent-color: var(--accent); flex: none; }

/* ---------- Badges, banners, empty ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 8px; border-radius: 999px; font-size: 13px; font-weight: 600; white-space: nowrap;
}
.badge-neutral { background: var(--fog); color: var(--muted); border: 1px solid var(--line); }
.badge-division { background: var(--brand); color: var(--white); font-family: var(--cond); font-size: 14px; letter-spacing: 0.02em; }
.badge-kind { background: var(--highlight-soft); color: var(--brand); }
.badge-ok { background: var(--ok-tint); color: var(--ok); }
.badge-wait { background: var(--wait-tint); color: var(--wait); }
.badge-danger { background: var(--danger-tint); color: var(--danger); }

.banner {
  display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap;
  padding: 12px 14px; border-radius: var(--radius); margin-bottom: 16px; border-left: 4px solid;
}
.banner-info { background: var(--white); border-color: var(--brand); }
.banner-ok { background: var(--ok-tint); border-color: var(--ok); }
.banner-wait { background: var(--wait-tint); border-color: var(--wait); }
.banner-error { background: var(--danger-tint); border-color: var(--danger); }
.banner-title { font-weight: 700; }
.banner-body { font-size: 15px; }

.empty { padding: 28px 16px; text-align: center; border: 1.5px dashed var(--line); border-radius: var(--radius); margin: 12px 0; }
.empty-title { font-weight: 700; color: var(--brand); }
.empty-body { color: var(--muted); margin-top: 4px; }
.empty .btn { margin-top: 14px; }
.empty-actions { justify-content: center; }
.empty-actions .btn { margin-top: 14px; }
.empty { background: var(--white); }

.loading { display: flex; align-items: center; gap: 10px; justify-content: center; padding: 40px 0; color: var(--muted); }

.card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; margin: 12px 0; }

/* ---------- Segmented & chips ---------- */
.segmented { display: flex; background: var(--white); border: 1px solid var(--line); border-radius: 10px; padding: 4px; margin-bottom: 16px; gap: 4px; }
.seg {
  flex: 1; min-height: 40px; border: 0; border-radius: 7px; background: transparent;
  font-weight: 600; color: var(--muted); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
}
.seg-on { background: var(--brand); color: var(--white); }
.seg-count { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--accent); color: var(--white); font: 600 12px/20px var(--cond); }

.team-switch { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 6px; margin-bottom: 12px; }
.chip { flex: none; padding: 8px 14px; border-radius: 999px; border: 1.5px solid var(--line); background: var(--white); text-decoration: none; font-weight: 600; color: var(--brand); }
.chip-on { background: var(--brand); color: var(--white); border-color: var(--brand); }

/* ---------- Date tile (scoreboard block) ---------- */
.date-tile {
  flex: none; align-self: flex-start; width: 60px; padding: 6px 0 7px; border-radius: 8px;
  background: var(--brand); color: var(--white);
  display: flex; flex-direction: column; align-items: center; line-height: 1;
  box-shadow: inset 0 -3px 0 var(--accent);
}
.dt-month { font-family: var(--cond); font-size: 14px; font-weight: 600; color: var(--highlight); }
.dt-day { font-family: var(--display); font-size: 28px; margin: 3px 0 2px; }
.dt-weekday { font-family: var(--cond); font-size: 13px; color: var(--highlight-soft); }
.date-tile-lg { width: 84px; padding: 10px 0 11px; }
.date-tile-lg .dt-month { font-size: 17px; }
.date-tile-lg .dt-day { font-size: 40px; margin: 4px 0; }
.date-tile-lg .dt-weekday { font-size: 15px; }

/* ---------- Event list & detail ---------- */
.event-list { list-style: none; margin: 0; padding: 0; }
.event-card {
  display: flex; gap: 14px; padding: 14px; margin-bottom: 10px;
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  color: inherit; text-decoration: none;
}
.event-card:hover { border-color: var(--brand); }
.event-main { min-width: 0; flex: 1; }
.event-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 6px; }
.event-title { font-weight: 700; font-size: 17px; line-height: 1.25; color: var(--brand); }
.event-meta { display: flex; flex-wrap: wrap; gap: 4px 14px; margin-top: 4px; color: var(--muted); font-size: 15px; }
.event-meta span { display: inline-flex; align-items: center; gap: 4px; }
.event-count { margin-top: 6px; font-size: 14px; color: var(--ink); }

.event-hero { display: flex; gap: 16px; align-items: flex-start; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.event-hero-info { min-width: 0; }
.hero-line { display: flex; gap: 6px; align-items: center; margin-top: 4px; }
.hero-line .icon { color: var(--muted); flex: none; }
.event-notes { margin-top: 14px; white-space: pre-line; background: var(--white); border-radius: var(--radius); padding: 14px; border: 1px solid var(--line); }

.signup { margin-top: 16px; }
.signup-row { display: flex; gap: 10px; align-items: center; margin-bottom: 10px; }
.signup-in { background: var(--ok-tint); color: var(--ok); border-radius: var(--radius); padding: 10px 12px; }
.signup-in p { flex: 1; color: var(--ink); }
.signup-wait { background: var(--wait-tint); color: var(--wait); border-radius: var(--radius); padding: 10px 12px; }
.signup-wait p { flex: 1; color: var(--ink); }
.signup-note { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; margin-bottom: 10px; color: var(--muted); }

/* ---------- Teams ---------- */
.team-logo {
  flex: none; display: inline-flex; align-items: center; justify-content: center; overflow: hidden;
  border-radius: 50%; background: var(--brand); color: var(--white);
  font-family: var(--display); border: 2px solid var(--white); box-shadow: 0 0 0 1px var(--line);
}
.team-logo img { width: 100%; height: 100%; object-fit: cover; background: var(--white); }
.team-list { list-style: none; margin: 0; padding: 0; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); }
.team-list > li + li { border-top: 1px solid var(--line); }
.team-row { display: flex; align-items: center; gap: 12px; padding: 12px 14px; }
.team-row-link { color: inherit; text-decoration: none; }
.team-row-main { flex: 1; min-width: 0; color: inherit; text-decoration: none; }
.team-name { font-weight: 700; color: var(--brand); }
.team-sub { font-size: 14px; color: var(--muted); }

.team-hero { display: flex; gap: 16px; align-items: center; margin: 4px 0 16px; }
.logo-btn { position: relative; padding: 0; border: 0; background: none; border-radius: 50%; cursor: pointer; }
.logo-btn:disabled { cursor: default; }
.logo-edit {
  position: absolute; right: -2px; bottom: -2px; width: 30px; height: 30px; border-radius: 50%;
  background: var(--accent); color: var(--white); display: flex; align-items: center; justify-content: center; border: 2px solid var(--fog);
}
.team-title { font-family: var(--display); font-weight: 400; font-size: 26px; color: var(--brand); line-height: 1.1; }

/* ---------- Roster ---------- */
.roster { list-style: none; margin: 14px 0 0; padding: 0; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); }
.roster:empty { display: none; }
.roster > li + li { border-top: 1px solid var(--line); }
.roster-row { display: flex; gap: 12px; padding: 14px; }
.roster-edit { padding: 0 8px; }
.jersey {
  flex: none; width: 40px; height: 40px; border-radius: 8px; background: var(--fog);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--display); font-size: 18px; color: var(--brand);
}
.roster-main { flex: 1; min-width: 0; }
.player-name { font-weight: 700; color: var(--brand); }
.player-sub { font-size: 14px; color: var(--muted); }
.roster-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.roster-actions { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 8px; margin-left: -8px; }
.roster-actions .btn-secondary { margin-left: 8px; }
.cert-picker { background: var(--fog); border-radius: 8px; padding: 12px; }
.cert-picker .btn { margin-top: 10px; }

/* ---------- Inbox ---------- */
.inbox { list-style: none; margin: 0; padding: 0; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); }
.inbox > li + li { border-top: 1px solid var(--line); }
.inbox-row { display: flex; gap: 12px; width: 100%; padding: 14px; background: none; border: 0; text-align: left; cursor: pointer; align-items: flex-start; }
.inbox-dot { width: 9px; height: 9px; border-radius: 50%; margin-top: 7px; flex: none; background: transparent; }
.inbox-unread .inbox-dot { background: var(--accent); }
.inbox-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.inbox-title { font-weight: 500; color: var(--ink); }
.inbox-unread .inbox-title { font-weight: 700; color: var(--brand); }
.inbox-body { font-size: 14px; color: var(--muted); }
.inbox-time { font-size: 13px; color: var(--muted); white-space: nowrap; }

/* ---------- Admin ---------- */
.review-list { list-style: none; margin: 0; padding: 0; }
.review-head { display: flex; gap: 12px; align-items: center; margin-bottom: 10px; }
.facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 0 0 12px; }
.facts dt { font-size: 13px; color: var(--muted); }
.facts dd { margin: 0; font-weight: 700; display: flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.reject-box { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.contact { font-size: 15px; margin-bottom: 8px; word-break: break-word; }
.simple-list { list-style: none; margin: 0; padding: 0; }
.simple-list li { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); flex-wrap: wrap; }

/* ---------- Scores ---------- */
.score-list { list-style: none; margin: 0 0 12px; padding: 0; }
.score-row {
  display: grid; grid-template-columns: 1fr auto auto 1fr auto auto; gap: 8px; align-items: center;
  padding: 12px 14px; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  margin-bottom: 8px; color: inherit; text-decoration: none;
}
.score-team { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.score-num { font-family: var(--display); font-size: 22px; color: var(--brand); }
.score-at { color: var(--muted); font-size: 14px; }

.scoreboard { background: var(--brand-deep); color: var(--white); border-radius: var(--radius); padding: 10px; overflow-x: auto; margin-bottom: 14px; }
.sb-row { display: grid; grid-template-columns: 112px repeat(var(--n, 7), 36px) 44px; gap: 4px; align-items: center; min-width: max-content; }
.sb-row + .sb-row { margin-top: 6px; }
.sb-head { color: var(--highlight); font-family: var(--cond); font-size: 14px; }
.sb-team { display: flex; align-items: center; gap: 8px; font-weight: 600; min-width: 0; padding-right: 6px; position: sticky; left: 0; z-index: 1; background: var(--brand-deep); }
.sb-team span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sb-cell, .sb-total { text-align: center; font-family: var(--display); font-size: 18px; }
.sb-head .sb-cell, .sb-head .sb-total { font-family: var(--cond); font-size: 14px; }
.sb-cell input {
  width: 36px; height: 38px; text-align: center; border-radius: 6px; border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.08); color: var(--white); font-family: var(--display); font-size: 18px; padding: 0;
}
.sb-total { color: var(--score-hi); position: sticky; right: 0; background: var(--brand-deep); box-shadow: -8px 0 8px var(--brand-deep); }

/* ---------- Auth ---------- */
.auth { max-width: 440px; margin: 0 auto; padding: calc(24px + env(safe-area-inset-top)) 16px 24px; }
.auth-hero { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 12px 0 20px; }
.auth-logo { width: 220px; height: auto; }
.auth-tagline { margin-top: 12px; font-family: var(--cond); font-weight: 600; font-size: 20px; color: var(--brand); letter-spacing: 0.02em; }
.auth-card { background: var(--white); border: 1px solid var(--line); border-radius: 14px; padding: 20px; }
.auth-card > * + * { margin-top: 14px; }
.auth-title { font-family: var(--display); font-weight: 400; font-size: 22px; color: var(--brand); }

/* ---------- Toast ---------- */
.toast {
  position: fixed; left: 50%; transform: translateX(-50%);
  bottom: calc(var(--nav-h) + env(safe-area-inset-bottom) + 14px); z-index: 40;
  max-width: min(560px, calc(100vw - 32px)); padding: 12px 16px; border-radius: 10px;
  background: var(--brand-deep); color: var(--white); font-weight: 600; box-shadow: 0 6px 20px rgba(12, 28, 54, 0.25);
  animation: toast-in 180ms ease-out;
}
.toast-error { background: var(--danger); }
.shell-plain .toast { bottom: 24px; }
@keyframes toast-in { from { opacity: 0; transform: translate(-50%, 8px); } to { opacity: 1; transform: translate(-50%, 0); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

@media (max-width: 480px) {
  .grid-3 { grid-template-columns: 1fr 1fr; }
  .grid-3 > .field:first-child { grid-column: 1 / -1; }
}

@media (max-width: 380px) {
  .facts { grid-template-columns: 1fr 1fr; }
  .brand-sub { display: none; }
}

@media (min-width: 720px) {
  .page { padding-top: 28px; }
  .page-header h1 { font-size: 30px; }
}

/* ---------- Coach contacts & GameChanger ---------- */
.coach-list { list-style: none; margin: 6px 0 0; padding: 0; }
.coach { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; padding: 2px 0; }
.coach-name { font-size: 14px; color: var(--ink); }
.coach-actions { display: inline-flex; gap: 6px; }
.mini-btn {
  display: inline-flex; align-items: center; gap: 4px; min-height: 32px; padding: 0 10px;
  border-radius: 999px; border: 1.5px solid var(--brand); color: var(--brand);
  font-size: 14px; font-weight: 600; text-decoration: none; background: var(--white);
}
.mini-btn:hover { background: var(--brand-tint); }
.gc-link {
  display: inline-flex; align-items: center; gap: 4px; margin-top: 6px;
  font-size: 14px; font-weight: 600; color: var(--brand);
}
.team-hero-info .gc-link { margin-top: 4px; }
.team-hero + .banner, .team-hero ~ .coach-list { margin-bottom: 12px; }
.team-name-link { text-decoration: none; display: inline-block; }
.team-name-link:hover { text-decoration: underline; }

/* ---------- Public landing page ---------- */
.landing { min-height: 100vh; background: var(--fog); }
.landing-bar .bar-signin { border-color: var(--white); background: transparent; color: var(--white); min-height: 40px; }
.landing-bar .bar-signin:hover { background: rgba(255, 255, 255, 0.12); }

.hero { background: var(--brand); color: var(--white); padding: 28px 16px 32px; }
.hero-inner { max-width: 1080px; margin: 0 auto; display: grid; gap: 24px; }
.hero-copy { text-align: center; }
.hero-logo { width: 150px; height: auto; margin: 0 auto 12px; filter: drop-shadow(0 6px 14px rgba(0, 0, 0, 0.35)); }
.hero-title { font-family: var(--display); font-weight: 400; font-size: 30px; line-height: 1.1; letter-spacing: 0.01em; }
.hero-tagline { margin-top: 8px; font-family: var(--cond); font-weight: 600; font-size: 20px; color: var(--highlight); }
.hero-about { margin: 14px auto 0; max-width: 56ch; color: var(--highlight-soft); font-size: 17px; }
.hero-facts { list-style: none; padding: 0; margin: 18px 0 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 22px; color: var(--highlight-soft); }
.hero-facts strong { font-family: var(--display); font-weight: 400; color: var(--white); font-size: 20px; margin-right: 4px; }
.hero-signin { color: var(--ink); }
.auth-card-compact { box-shadow: 0 12px 30px rgba(6, 15, 31, 0.35); border: 0; scroll-margin-top: 90px; }

.landing-main { max-width: 1080px; margin: 0 auto; padding: 8px 16px 24px; }
.lsection { margin-top: 32px; }
.lsection-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 12px; margin-bottom: 12px; }
.lsection-head h2 { font-family: var(--display); font-weight: 400; font-size: 24px; }
.empty-inline { background: var(--white); border: 1.5px dashed var(--line); border-radius: var(--radius); padding: 16px; color: var(--muted); }

/* Scoreboard ticker */
.ticker { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 8px; scroll-snap-type: x mandatory; }
.tick {
  flex: none; width: 236px; scroll-snap-align: start;
  background: var(--brand-deep); color: var(--white); border-radius: var(--radius); padding: 12px 14px;
  box-shadow: inset 0 -3px 0 var(--accent);
}
.tick-status { font-family: var(--cond); font-size: 14px; color: var(--highlight); margin-bottom: 8px; }
.tick-live::before { content: ''; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #ff5a5f; margin-right: 6px; vertical-align: middle; }
.tick-row { display: flex; align-items: center; gap: 8px; padding: 3px 0; color: var(--highlight-soft); }
.tick-row .team-logo { border-width: 1px; box-shadow: none; }
.tick-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.tick-runs { font-family: var(--display); font-size: 22px; color: var(--white); }
.tick-win .tick-name { color: var(--white); }
.tick-win .tick-runs { color: var(--score-hi); }

/* Calendar + list */
.upcoming { display: grid; gap: 16px; }
.cal { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; align-self: start; }
.cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.cal-title { font-weight: 700; color: var(--brand); }
.cal-nav { color: var(--brand); width: 40px; height: 40px; border: 0; background: none; cursor: pointer; }
.cal-nav:disabled { opacity: 0.3; cursor: default; }
.cal-next .icon { transform: rotate(180deg); }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal-dow { text-align: center; font-family: var(--cond); font-size: 13px; color: var(--muted); padding: 4px 0; }
.cal-day {
  position: relative; aspect-ratio: 1 / 1; min-height: 38px; border: 0; border-radius: 8px; background: transparent;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  font-weight: 600; color: var(--ink); font-size: 15px;
}
.cal-day:disabled { cursor: default; color: var(--muted); font-weight: 500; }
.cal-past { opacity: 0.45; }
.cal-today { box-shadow: inset 0 0 0 2px var(--highlight); }
.cal-has { background: var(--brand-tint); color: var(--brand); cursor: pointer; }
.cal-has:hover { background: var(--highlight-soft); }
.cal-on { background: var(--brand); color: var(--white); }
.cal-dot { min-width: 8px; height: 8px; border-radius: 4px; background: var(--accent); color: var(--white); font: 600 10px/8px var(--cond); padding: 0 2px; }
.cal-dot:not(:empty) { height: 14px; line-height: 14px; min-width: 14px; border-radius: 7px; padding: 0 4px; }
.day-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.day-title { font-weight: 700; color: var(--brand); }
.logo-stack { display: flex; align-items: center; margin-top: 8px; }
.logo-stack .team-logo + .team-logo { margin-left: -8px; }
.logo-stack .event-count { margin: 0 0 0 10px; }

/* How it works */
.how { display: grid; gap: 12px; }
.how-item { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.how-item .icon { color: var(--accent); }
.how-item h3 { font-size: 18px; color: var(--brand); margin: 8px 0 4px; }
.how-item p { color: var(--muted); }

/* Why we started / what makes us different */
.why { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.why-body { padding: 22px 18px 8px; }
.why-title { font-family: var(--display); font-weight: 400; font-size: 26px; color: var(--brand); }
.why-about { margin-top: 10px; font-size: 18px; line-height: 1.55; color: var(--ink); max-width: 64ch; white-space: pre-line; }
.why-sub {
  margin: 22px 0 6px; font-family: var(--cond); font-weight: 700; font-size: 15px;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent);
}
.pillars { list-style: none; margin: 0; padding: 0; display: grid; }
.pillar { display: grid; grid-template-columns: 46px 1fr; gap: 12px; padding: 14px 0; border-top: 1px solid var(--line); }
.pillar:first-child { border-top: 0; }
.pillar-num { font-family: var(--display); font-size: 26px; line-height: 1; color: var(--accent); padding-top: 2px; }
.pillar-title { margin: 0; font-family: var(--cond); font-weight: 700; font-size: 20px; line-height: 1.2; color: var(--brand); }
.pillar-text { margin: 3px 0 0; color: var(--muted); }
.why-close {
  background: var(--brand); color: var(--highlight-soft); text-align: center;
  font-family: var(--display); font-size: 16px; line-height: 1.4; padding: 16px 18px;
}

.contact-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.contact-name { font-weight: 700; color: var(--brand); margin-bottom: 10px; }
.contact-note { color: var(--muted); margin-bottom: 12px; }

.forward-box { border-top: 1px solid var(--line); padding-top: 14px; }
.usage-meter { height: 10px; border-radius: 999px; background: var(--fog); border: 1px solid var(--line); overflow: hidden; }
.usage-fill { height: 100%; background: var(--brand); border-radius: 999px; }
.usage-fill.usage-high { background: var(--accent); }
.contact-links { display: flex; flex-wrap: wrap; gap: 8px; }
.contact-links .mini-btn { min-height: 40px; }

.landing-footer {
  margin-top: 40px; padding: 22px 16px calc(22px + env(safe-area-inset-bottom));
  background: var(--brand-deep); color: var(--highlight-soft); text-align: center; font-size: 14px;
  display: flex; flex-direction: column; gap: 4px;
}
.built-by { letter-spacing: 0.02em; display: flex; align-items: center; justify-content: center; gap: 8px; }
.built-by-mark { width: 22px; height: 22px; flex: none; }
.built-by-link { display: inline-flex; align-items: center; gap: 8px; color: inherit; text-decoration: none; }
.built-by-link:hover strong { text-decoration: underline; }
.built-by strong { font-family: var(--display); font-weight: 400; letter-spacing: 0.04em; }
.landing-footer .built-by strong { color: var(--white); }
.landing-footer a { color: inherit; }
.app-footer a { color: inherit; }
.built-by-plain { text-align: center; margin-top: 18px; color: var(--muted); font-size: 14px; }
.app-footer { margin-top: 40px; padding: 16px 0 8px; border-top: 1px solid var(--line); text-align: center; color: var(--muted); font-size: 13px; }
.app-footer .built-by strong { color: var(--brand); }

@media (min-width: 860px) {
  .hero { padding: 44px 24px 48px; }
  .hero-inner { grid-template-columns: 1.25fr 1fr; align-items: center; gap: 40px; }
  .hero-copy { text-align: left; display: grid; grid-template-columns: 150px 1fr; column-gap: 24px; align-items: start; }
  .hero-logo { grid-row: span 4; margin: 0; }
  .hero-about { margin-left: 0; }
  .hero-facts { justify-content: flex-start; }
  .hero-title { font-size: 38px; }
  .upcoming { grid-template-columns: 340px 1fr; gap: 24px; }
  .how { grid-template-columns: repeat(3, 1fr); }
  .landing-main { padding: 8px 24px 32px; }
  .why-body { padding: 30px 30px 14px; }
  .why-title { font-size: 30px; }
  .pillars { grid-template-columns: repeat(2, 1fr); column-gap: 32px; }
  .pillar:nth-child(2) { border-top: 0; }
  .why-close { font-size: 18px; }
}

/* ---------- Public teams & standings ---------- */
.public-nav { display: flex; align-items: center; gap: 6px; }
.public-link { color: var(--white); font-weight: 600; text-decoration: none; padding: 8px 10px; border-radius: 8px; }
.public-link:hover { background: rgba(255, 255, 255, 0.1); }
.public-title { font-family: var(--display); font-weight: 400; font-size: 28px; color: var(--brand); }
.chip-row { display: flex; gap: 8px; overflow-x: auto; padding: 4px 0 8px; margin-top: 12px; }
.chip-row .chip { cursor: pointer; font: inherit; font-weight: 600; }
.standings { list-style: none; margin: 0; padding: 0; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); }
.standings > li + li { border-top: 1px solid var(--line); }
.standing { display: flex; align-items: center; gap: 12px; padding: 12px 14px; }
.standing-main { flex: 1; min-width: 0; }
.standing-rec { flex: none; text-align: right; }
.rec { font-family: var(--display); font-size: 20px; color: var(--brand); }
.rec-none { color: var(--line); }
.logo-wall { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; }
.wall-team {
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px; padding: 12px 6px;
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; color: inherit; height: 100%;
}
.wall-team:hover { border-color: var(--brand); }
.wall-name { font-weight: 700; font-size: 14px; color: var(--brand); line-height: 1.2; }
.wall-div { font-family: var(--cond); font-size: 13px; color: var(--muted); }
@media (max-width: 420px) {
  .public-link { display: none; }
}

/* ---------- Public team page ---------- */
.team-band { background: var(--brand); color: var(--white); padding: 24px 16px; }
.team-band-inner { max-width: 1080px; margin: 0 auto; display: grid; grid-template-columns: auto 1fr; gap: 16px; align-items: center; }
.team-band-name { font-family: var(--display); font-weight: 400; font-size: 28px; line-height: 1.1; }
.team-band-sub { color: var(--highlight); margin-top: 2px; }
.team-band .gc-link { color: var(--white); }
.team-band-rec { grid-column: 1 / -1; display: flex; align-items: baseline; gap: 8px; padding-top: 12px; border-top: 1px solid rgba(255, 255, 255, 0.15); }
.rec-big { font-family: var(--display); font-size: 34px; color: var(--score-hi); }
.rec-label { font-family: var(--cond); color: var(--highlight); }
.team-about { white-space: pre-line; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; font-size: 17px; }
.results { list-style: none; margin: 0; padding: 0; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); }
.results > li + li { border-top: 1px solid var(--line); }
.result { display: grid; grid-template-columns: 32px 1fr auto auto; gap: 10px; align-items: center; padding: 12px 14px; }
.result-badge { width: 28px; height: 28px; border-radius: 6px; display: inline-flex; align-items: center; justify-content: center; font-family: var(--display); font-size: 15px; }
.result-W { background: var(--ok-tint); color: var(--ok); }
.result-L { background: var(--danger-tint); color: var(--danger); }
.result-T { background: var(--fog); color: var(--muted); }
.result-opp { font-weight: 600; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.result-score { font-family: var(--display); font-size: 18px; color: var(--brand); }
.result-date { font-size: 14px; color: var(--muted); }
@media (min-width: 720px) {
  .team-band { padding: 36px 24px; }
  .team-band-inner { grid-template-columns: auto 1fr auto; }
  .team-band-rec { grid-column: auto; border-top: 0; padding-top: 0; flex-direction: column; align-items: flex-end; gap: 0; }
  .team-band-name { font-size: 36px; }
}

/* ---------- Roster paste ---------- */
.roster-add { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.import-list { list-style: none; margin: 0; padding: 0; border: 1px solid var(--line); border-radius: var(--radius); }
.import-list > li + li { border-top: 1px solid var(--line); }
.import-row {
  display: grid; grid-template-columns: 26px 46px 1fr 1fr; gap: 6px 8px; align-items: center; padding: 10px;
}
.import-off { background: var(--fog); }
.import-off input:not(.import-check) { opacity: 0.55; }
.import-row input:not([type='checkbox']) {
  min-height: 40px; padding: 6px 8px; border: 1.5px solid var(--line); border-radius: 6px; background: var(--white); font-size: 15px; width: 100%; min-width: 0;
}
.import-check { width: 22px; height: 22px; accent-color: var(--accent); }
.import-num { text-align: center; }
.import-dob { grid-column: 2 / -1; }
.import-note { grid-column: 2 / -1; font-size: 13px; color: var(--muted); }
.import-bad { color: var(--danger); }

/* ---------- Family pages ---------- */
.family-card .review-head { margin-bottom: 12px; }
.family-card .review-head .badge { margin-left: auto; }
.steps { list-style: none; margin: 0; padding: 0; }
.step { display: flex; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.step-mark {
  flex: none; width: 26px; height: 26px; border-radius: 50%; border: 2px solid var(--line);
  display: inline-flex; align-items: center; justify-content: center; color: var(--white); margin-top: 1px;
}
.step-done .step-mark { background: var(--ok); border-color: var(--ok); }
.step-body { flex: 1; min-width: 0; }
.step-body > * + * { margin-top: 8px; }
.step-title { font-weight: 700; color: var(--brand); }
.step-done .step-title { color: var(--ok); }
.inline-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px; }
.inline-form .field { flex: 1 1 200px; }
.inline-form .field > label { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.waiver-text {
  max-height: 220px; overflow-y: auto; white-space: pre-line; font-size: 15px; padding: 12px;
  background: var(--fog); border: 1px solid var(--line); border-radius: 8px;
}
.join-head { display: flex; align-items: center; gap: 14px; }
.join-card .auth-title { margin-top: 2px; }
.join-steps { margin: 0; padding-left: 20px; }
.join-steps li { margin: 4px 0; }
.auth-logo-sm { width: 140px; }

/* ---------- Field, umpires, sign-up notes ---------- */
.choice { border: 0; padding: 0; margin: 0; }
.choice legend { font-weight: 600; font-size: 15px; margin-bottom: 6px; padding: 0; }
.radio { display: flex; gap: 10px; align-items: flex-start; padding: 8px 0; cursor: pointer; }
.radio input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--accent); flex: none; }
.signup-box { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; margin-bottom: 10px; }
.signup-box .signup-row { margin: 10px 0 0; }
.team-note { font-size: 14px; color: var(--ink); margin-top: 4px; font-style: italic; }
.hero-line a { color: var(--brand); }

/* ---------- Team home: up next + setup ---------- */
.edit-team-btn {
  display: inline-flex; align-items: center; gap: 6px; margin-top: 6px; padding: 4px 0;
  background: none; border: 0; color: var(--brand); font-weight: 600; font-size: 14px; cursor: pointer;
}
.edit-team-btn:hover { text-decoration: underline; }
.home-grid { display: grid; gap: 12px; margin: 12px 0 8px; }
.home-grid > .card { margin: 0; }
.home-card .section-head { margin-bottom: 8px; }
.home-card .section-head .text-btn { padding: 0; }
.home-card .event-card { background: var(--fog); border-color: transparent; margin-bottom: 8px; }
.home-card .event-card:hover { border-color: var(--brand); }
.home-empty { color: var(--muted); margin-bottom: 12px; }
.home-actions { margin-top: 4px; }
.progress { height: 8px; border-radius: 999px; background: var(--fog); border: 1px solid var(--line); overflow: hidden; margin: 2px 0 8px; }
.progress > div { height: 100%; background: var(--ok); border-radius: 999px; }
.checklist { list-style: none; margin: 0; padding: 0; }
.check-item { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); }
.check-item:first-child { border-top: 0; }
.check-mark {
  width: 24px; height: 24px; flex: none; border-radius: 50%; border: 2px solid var(--line);
  display: inline-flex; align-items: center; justify-content: center;
}
.check-done .check-mark { background: var(--ok); border-color: var(--ok); color: var(--white); }
.check-label { flex: 1; min-width: 0; display: flex; flex-direction: column; font-weight: 600; color: var(--ink); }
.check-label .fine { font-weight: 400; }
.check-done .check-label { color: var(--muted); font-weight: 500; }
.check-item .text-btn { flex: none; padding: 6px 0; }

/* ---------- Tournaments ---------- */
.tournament .segmented { margin-top: 4px; }
.t-games { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.t-game { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 12px; }
.t-game-mine { border-color: var(--highlight); box-shadow: inset 4px 0 0 var(--accent); }
.t-game-meta { display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.t-game-meta strong { color: var(--brand); }
.t-side { display: flex; align-items: center; gap: 8px; padding: 3px 0; }
.t-name { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.t-runs { font-family: var(--cond); font-size: 20px; font-weight: 600; min-width: 26px; text-align: right; color: var(--brand); }
.t-win .t-name { font-weight: 700; }
.t-win .t-runs { color: var(--accent); }
.t-seed {
  flex: none; min-width: 22px; height: 22px; padding: 0 4px; border-radius: 6px; background: var(--brand-tint); color: var(--brand);
  font-size: 12px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center;
}
.t-game-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--line); }
.t-game-foot:empty { display: none; }
.t-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-left: auto; }
.t-actions:empty { display: none; }
.t-score-form { width: 100%; }
.t-score-form .actions-row { margin-top: 10px; }
.t-pools { display: grid; gap: 16px; }
.t-pool-name { font-family: var(--display); font-weight: 400; font-size: 20px; color: var(--brand); margin: 4px 0 8px; }
.t-table { width: 100%; border-collapse: collapse; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; font-size: 15px; }
.t-table th { text-align: center; font-size: 12px; text-transform: uppercase; letter-spacing: 0.04em; color: var(--muted); padding: 8px 4px; background: var(--fog); }
.t-table td { text-align: center; padding: 8px 4px; border-top: 1px solid var(--line); font-variant-numeric: tabular-nums; }
.t-table .t-team-col { text-align: left; width: 50%; }
.t-table abbr { text-decoration: none; }
.t-rank { color: var(--muted); font-weight: 700; width: 30px; }
.t-tie { color: var(--accent); margin-left: 1px; }
.t-team-cell { display: inline-flex; align-items: center; gap: 8px; min-width: 0; }
.t-team-cell > span { overflow-wrap: anywhere; }
.t-rules ul { margin: 0; padding-left: 20px; color: var(--ink); }
.t-rules li + li { margin-top: 4px; }
.t-rules, .t-pools + .t-rules { margin-top: 18px; }
.t-rules-note { margin-top: 10px; white-space: pre-line; color: var(--muted); }
.t-confirm { border-color: var(--wait); background: var(--wait-tint); }
.t-confirm-title { font-weight: 700; color: var(--wait); }
.t-confirm-score { font-size: 17px; }
.t-champ { display: flex; align-items: center; gap: 8px; padding: 12px 14px; margin-bottom: 12px; border-radius: var(--radius); background: var(--brand); color: var(--white); }
.t-champ .icon { color: var(--score-hi); }
.bracket { display: flex; gap: 14px; overflow-x: auto; padding-bottom: 8px; -webkit-overflow-scrolling: touch; }
.bracket-round { flex: 0 0 210px; display: flex; flex-direction: column; }
.bracket-round-name { font-family: var(--cond); font-weight: 600; font-size: 15px; text-transform: uppercase; letter-spacing: 0.04em; color: var(--muted); margin-bottom: 8px; }
.bracket-games { flex: 1; display: flex; flex-direction: column; justify-content: space-around; gap: 12px; }
.bracket-game { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 6px 8px; }
.bracket-meta { font-size: 12px; color: var(--muted); margin-bottom: 2px; }
.bracket-game .t-runs { font-size: 17px; }
.t-step-n {
  display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; border-radius: 50%;
  background: var(--brand); color: var(--white); font-size: 13px; margin-right: 4px; vertical-align: 2px;
}
.t-breakers, .t-seeds { list-style: none; margin: 0 0 8px; padding: 0; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.t-breakers li, .t-seeds li { display: flex; align-items: center; gap: 10px; padding: 8px 10px; }
.t-breakers li + li, .t-seeds li + li { border-top: 1px solid var(--line); }
.t-breaker-n { flex: none; width: 22px; height: 22px; border-radius: 50%; background: var(--brand-tint); color: var(--brand); font-weight: 700; font-size: 13px; display: inline-flex; align-items: center; justify-content: center; }
.t-breaker-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.t-breaker-btns { flex: none; display: flex; gap: 2px; }
.icon-btn-light { color: var(--brand); width: 34px; height: 34px; font-size: 18px; font-weight: 700; border: 1.5px solid var(--line); background: var(--white); cursor: pointer; }
.icon-btn-light:hover { background: var(--brand-tint); }
.icon-btn-light:disabled { opacity: 0.3; cursor: default; background: none; }
.t-add-breaker { width: 100%; padding: 10px; border: 1.5px solid var(--line); border-radius: var(--radius-sm); background: var(--white); font: inherit; }
.t-seed-out { opacity: 0.5; }
.t-seed-empty { background: none; }
.t-pool-picks select { max-width: 150px; padding: 8px; border: 1.5px solid var(--line); border-radius: var(--radius-sm); font: inherit; background: var(--white); }
.t-pool-picks li { align-items: center; }
.t-public-head .public-title { margin: 8px 0 6px; }
.bracket-part + .bracket-part { margin-top: 18px; }
.t-game-skipped { opacity: 0.6; border-style: dashed; }
.t-third { font-weight: 400; }
.t-register-head { display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.t-register-count { font-weight: 700; color: var(--brand); font-size: 17px; }
.t-entered { list-style: none; margin: 0 0 8px; padding: 0; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--white); }
.t-entered li { display: flex; align-items: center; gap: 10px; padding: 8px 10px; }
.t-entered li + li { border-top: 1px solid var(--line); }
.t-entered .t-name { flex: 1; min-width: 0; font-weight: 600; }
.t-entered .fine { flex: none; }
.t-waitlist li .t-seed { color: var(--wait); }
.t-share-link { margin: 12px 0; padding: 10px 12px; background: var(--brand-tint); border-radius: var(--radius-sm); }
.t-share-link code { word-break: break-all; font-size: 13px; }
.t-reg { max-width: 640px; }
.t-guest-opts { margin: 14px 0; }
.t-attest { padding: 10px 12px; border: 1.5px solid var(--line); border-radius: var(--radius-sm); background: var(--white); }
.t-todo { margin: 0; padding-left: 20px; }
.t-todo li + li { margin-top: 4px; }
.badge-guest { background: var(--brand-tint); color: var(--brand); }
.t-director { display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap;
  padding: 10px 12px; margin: 0 0 14px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--white); }
.t-director .contact-links { display: flex; gap: 8px; }
.tx-status .badge { margin-right: 6px; vertical-align: 1px; }
.tx-consent span { font-weight: 400; }
.tx-register { padding-top: 6px; border-top: 1px solid var(--line); }
.tx-inbox { list-style: none; margin: 0; padding: 0; }
.tx-inbox li { display: flex; flex-direction: column; gap: 2px; padding: 8px 0; border-top: 1px solid var(--line); }
.tx-in { font-size: 15px; overflow-wrap: anywhere; }
.legal { max-width: 760px; }
.legal h2 { font-size: 20px; color: var(--brand); margin: 0 0 8px; }
.legal ul { padding-left: 20px; margin: 8px 0 0; }
.legal li + li { margin-top: 8px; }
.legal p + p { margin-top: 10px; }

/* ---------- Laptops and desktops ----------
   The menu moves into the top bar, pages get room to breathe, lists flow into two columns,
   and forms stay at a comfortable reading width. Phones are unchanged. */
.topnav { display: none; }

@media (min-width: 1000px) {
  body { font-size: 17px; }
  .t-games { grid-template-columns: 1fr 1fr; }
  .bracket-round { flex-basis: 240px; }
  .shell { padding-bottom: 48px; }
  .bottomnav { display: none; }
  .toast { bottom: 28px; }

  .topbar { padding: 10px 32px; gap: 24px; }
  .brand img { width: 44px; height: 44px; }
  .brand-name { font-size: 20px; }
  .brand-sub { font-size: 13px; }
  .topnav { display: flex; align-items: center; gap: 4px; margin-right: auto; }
  .topnav-item {
    display: inline-flex; align-items: center; gap: 8px; min-height: 42px; padding: 0 16px;
    border-radius: 999px; color: var(--highlight-soft); text-decoration: none; font-weight: 600; font-size: 15px;
  }
  .topnav-item:hover { background: rgba(255, 255, 255, 0.1); color: var(--white); }
  .topnav-item.topnav-on { background: var(--white); color: var(--brand); }
  .topnav-item.topnav-on .icon { color: var(--accent); stroke-width: 2.2; }

  .page { padding: 36px 32px 0; }
  .page-wide { max-width: 1180px; }
  .page-mid { max-width: 920px; }
  .page-form { max-width: 760px; }
  .page-header { margin: 0 0 22px; }
  .page-header h1 { font-size: 36px; }
  .lead { font-size: 18px; }
  .fine { font-size: 15px; }
  h2 { font-size: 21px; }
  .card { padding: 22px; }
  .card-title { font-size: 19px; }
  .division-head { font-size: 24px; }
  .event-title { font-size: 19px; }
  .event-meta { font-size: 16px; }
  .event-count { font-size: 15px; }

  /* Lists use the extra room */
  .page-wide .event-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
  .page-wide .event-list > li { display: flex; }
  .page-wide .event-card { margin: 0; flex: 1; padding: 18px; }
  .page-wide .team-list,
  .page-wide .review-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; background: none; border: 0; }
  .page-wide .team-list > li { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); }
  .page-wide .team-list > li + li { border-top: 1px solid var(--line); }
  .page-wide .review-list > li { margin: 0; }
  .page-wide .segmented { max-width: 560px; }
  .page-wide input[type='search'] { max-width: 560px; }

  /* Side-by-side cards (Account, Admin settings) */
  .card-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; align-items: start; }
  .card-grid > * { margin: 0; }
  .signout { width: auto; min-width: 220px; margin-top: 24px; }

  /* Team home: up next and setup side by side; a lone card spans the row */
  .home-grid { grid-template-columns: repeat(auto-fit, minmax(380px, 1fr)); gap: 20px; margin: 16px 0 8px; }
  .team-title { font-size: 34px; }

  /* Scorecard: full team names and bigger boxes */
  .scoreboard { padding: 16px; }
  .sb-row { grid-template-columns: minmax(200px, 1fr) repeat(var(--n, 7), 48px) 60px; gap: 6px; }
  .sb-cell, .sb-total { font-size: 22px; }
  .sb-head .sb-cell, .sb-head .sb-total { font-size: 15px; }
  .sb-cell input { width: 48px; height: 46px; font-size: 22px; }
}
