/* =====================================================================
   Wolf Pack Team Hub — design system
   Light and clean: light-grey page, white cards, Wolf Pack red as the accent, and charcoal used only for depth
   (the next-game hero, scoreboard, jersey numbers, toasts). Plain CSS, no build step.
   Mobile first; tablet ≥ 768px; desktop ≥ 1100px.
   ===================================================================== */

:root {
  --red: #E8261E;          /* the club colour — another club's own colour replaces these (App\Support\ClubBrand) */
  --red-rgb: 232, 38, 30;  /* the same colour, for see-through rgba(var(--red-rgb), .3) glows */
  --red-light: #FF5A4F;
  --red-600: #C8190F;
  --red-700: #A3140C;
  --red-glow: rgba(var(--red-rgb), .28);
  --red-soft: #FDECEA;
  --red-tint: #FFF5F4;

  --ink: #17181C;          /* charcoal — depth only */
  --ink-2: #26282E;
  --bg: #F2F3F5;
  --surface: #FFFFFF;
  --surface-2: #F6F6F8;
  --surface-3: #ECEDF0;
  --field: #FAFAFB;
  --line: #E7E8EC;
  --line-strong: #D6D8DE;
  --text: #15161A;
  --text-2: #44464D;
  --muted: #6E7078;

  --paper: #FFFFFF;
  --paper-2: #F6F6F8;
  --paper-text: #15161A;
  --paper-muted: #6E7078;
  --paper-line: #E7E8EC;

  --green: #16A34A;
  --green-ink: #0F7A36;
  --amber: #F5A524;
  --amber-ink: #945600;
  --grey: #8E9097;

  --radius-lg: 22px;
  --radius: 16px;
  --radius-sm: 12px;
  --shadow: 0 1px 2px rgba(16, 18, 24, .04), 0 6px 20px rgba(16, 18, 24, .05);
  --shadow-lift: 0 2px 4px rgba(16, 18, 24, .05), 0 14px 32px rgba(16, 18, 24, .09);
  --shadow-dark: 0 20px 44px rgba(16, 18, 24, .28);

  --font: "Barlow", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-display: "Barlow Condensed", "Arial Narrow", "Roboto Condensed", system-ui, sans-serif;

  --header-h: 66px;
  /* Set inline on .shell (61px) only while the demo role-switcher bar is actually showing — see its own
     comment on .sidebar for why this needs to be a variable rather than baked into --header-h itself. */
  --demo-bar-h: 0px;
  --bottom-h: 70px;
  --gutter: 16px;
  color-scheme: light;
}

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

/* The HTML `hidden` attribute means hidden, full stop. On its own it only carries the user-agent's
   `display: none`, which any class that sets its own display silently outranks — a `.list-item[hidden]`
   row stayed right where it was. */
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; min-height: 100dvh;
  font-family: var(--font); font-size: 16px; line-height: 1.5; color: var(--text);
  background: radial-gradient(900px 340px at 100% -140px, rgba(var(--red-rgb), .07), transparent 60%), var(--bg);
  -webkit-font-smoothing: antialiased;
}
/* Set by any open modal or the mobile "More" sheet (see their x-effect) so the page behind an overlay can't
   be scrolled while it's covering it — position:fixed rather than plain overflow:hidden so iOS Safari can't
   still rubber-band the body behind the overlay, restoring the exact scroll position on close. */
body.scroll-locked { position: fixed; left: 0; right: 0; overflow: hidden; }
img, svg { display: block; max-width: 100%; }
img { height: auto; }   /* keep proportions when CSS sets only a width */
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid rgba(var(--red-rgb), .55); outline-offset: 2px; border-radius: 6px; }
[x-cloak] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

h1, h2, h3, h4, .display { font-family: var(--font-display); font-weight: 800; letter-spacing: .005em; line-height: 1.05; margin: 0; text-transform: uppercase; color: var(--text); }
h1 { font-size: clamp(2rem, 6.5vw, 2.7rem); }
h2 { font-size: 1.35rem; }
h3 { font-size: 1.1rem; }
p { margin: 0; }
.eyebrow { font-family: var(--font); font-weight: 800; font-size: .76rem; letter-spacing: .14em; text-transform: uppercase; color: var(--red); }
.muted { color: var(--muted); }
.text-2 { color: var(--text-2); }
.small { font-size: .875rem; }
.tiny { font-size: .78rem; }
.num { font-family: var(--font-display); font-weight: 800; font-variant-numeric: tabular-nums; }
.nowrap { white-space: nowrap; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }

/* ------------------------------------------------------------------ layout */
.shell { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }
.shell-body { flex: 1; display: flex; width: 100%; max-width: 1440px; margin: 0 auto; }
.main { flex: 1; min-width: 0; padding: 22px var(--gutter) calc(var(--bottom-h) + 32px); }
.stack { display: flex; flex-direction: column; gap: 16px; }
.stack-sm { display: flex; flex-direction: column; gap: 8px; }
.stack-lg { display: flex; flex-direction: column; gap: 24px; }
.row { display: flex; align-items: center; gap: 12px; }
.row-sm { display: flex; align-items: center; gap: 6px; }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.wrap { flex-wrap: wrap; }
.grow { flex: 1; min-width: 0; }
.grid { display: grid; gap: 16px; }
.grid-2, .grid-3, .grid-4 { display: grid; gap: 16px; grid-template-columns: 1fr; }
.grid-stats { display: grid; gap: 12px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.mt-1 { margin-top: 4px; } .mt-2 { margin-top: 8px; } .mt-3 { margin-top: 12px; } .mt-4 { margin-top: 16px; } .mt-6 { margin-top: 24px; }
.hide-mobile { display: none; }

@media (min-width: 768px) {
  :root { --gutter: 24px; }
  .grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .hide-mobile { display: initial; }
  .hide-tablet-up { display: none !important; }
  .span-2 { grid-column: span 2; }
}
@media (min-width: 1100px) {
  .grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .main { padding: 30px 34px 48px; }
  .grid-main { display: grid; gap: 20px; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); align-items: start; }
}

/* ------------------------------------------------------------------ header */
.topbar {
  position: sticky; top: 0; z-index: 42;   /* above .bottom-nav (40) and .menu-backdrop (41): an open avatar/language menu shows in front of both */ height: var(--header-h);
  display: flex; align-items: center; gap: 10px; padding: 0 var(--gutter);
  background: rgba(255, 255, 255, .92); backdrop-filter: saturate(160%) blur(14px); -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.topbar::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: var(--red); }
.brand { display: flex; align-items: center; gap: 10px; min-width: 0; }
.brand img { height: 48px; width: auto; filter: drop-shadow(0 3px 8px rgba(var(--red-rgb), .22)); }
.brand-name { font-family: var(--font-display); font-weight: 800; text-transform: uppercase; line-height: 1; font-size: 1.2rem; letter-spacing: .02em; }
.brand-name small { display: block; font-family: var(--font); font-size: .66rem; letter-spacing: .16em; color: var(--red); font-weight: 800; margin-top: 4px; }
.topbar-actions { margin-left: auto; display: flex; align-items: center; gap: 6px; }

.icon-btn { position: relative; display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: transparent; border: 1px solid transparent; color: var(--text); }
.icon-btn .dot { position: absolute; top: 5px; right: 5px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--red); color: #fff; font-size: .7rem; font-weight: 800; display: grid; place-items: center; box-shadow: 0 0 0 2px #fff; }
.icon { width: 22px; height: 22px; flex: none; }
.icon-sm { width: 18px; height: 18px; flex: none; }
.icon-lg { width: 28px; height: 28px; flex: none; }

/* language selector — always visible; plain <details> so it works without JavaScript */
.dropdown { position: relative; }
.dropdown > summary { list-style: none; }
.dropdown > summary::-webkit-details-marker { display: none; }

/* a collapsible <section><details> card, e.g. "Change password" — plain <details> so it works without JS */
.details-plain > summary { list-style: none; cursor: pointer; }
.details-plain > summary::-webkit-details-marker { display: none; }
.details-plain > summary .chevron { transition: transform .15s ease; }
.details-plain[open] > summary .chevron { transform: rotate(180deg); }
.lang-btn {
  display: inline-flex; align-items: center; gap: 6px; height: 42px; padding: 0 12px; border-radius: 999px;
  border: 1px solid var(--line-strong); background: var(--surface); font-weight: 700; font-size: .92rem; cursor: pointer; box-shadow: 0 1px 2px rgba(16, 18, 24, .05);
}
.lang-btn .icon-sm { color: var(--red); }
.dropdown[open] > .lang-btn { border-color: var(--red); }
.menu { position: absolute; right: 0; top: calc(100% + 8px); z-index: 60; min-width: 236px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 20px 50px rgba(16, 18, 24, .16); padding: 8px; max-height: calc(100vh - 90px); overflow-y: auto; }
.menu-title { padding: 8px 10px 6px; font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-weight: 800; }
/* A club with many teams shouldn't push the rest of this menu (profile info, language, sign out) off the
   bottom of the screen with no way to reach it — the team list scrolls on its own within a fixed height. */
.menu-scroll { max-height: 240px; overflow-y: auto; }
.menu-item { width: 100%; display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 8px 10px; border: 0; border-radius: 10px; background: transparent; text-align: left; color: var(--text); font-weight: 600; }
.menu-item.is-active { background: var(--red-tint); color: var(--red-700); }
.menu-item .code { width: 36px; height: 28px; border-radius: 7px; display: grid; place-items: center; background: var(--surface-3); font-family: var(--font-display); font-weight: 800; font-size: .85rem; color: var(--text-2); }
.menu-item.is-active .code { background: var(--red); color: #fff; }
.menu-item .check { margin-left: auto; color: var(--red); }
.menu hr { border: 0; border-top: 1px solid var(--line); margin: 6px 0; }
/* Pinned with absolute + transform, not grid centering: the icon-btn it sits in is position:relative inside a
   sticky, backdrop-filter header, and on iOS Safari that combination can leave grid/flex-centered content
   floating at a stale offset after a page swap. A transform anchored to the parent's own box never depends on
   that recalculation, so it can't drift regardless. */
.avatar-btn { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 40px; height: 40px; border-radius: 50%; background: var(--ink); color: #fff; font-family: var(--font-display); font-weight: 800; display: grid; place-items: center; box-shadow: 0 0 0 2px #fff, 0 0 0 3px var(--red); overflow: hidden; }
.avatar-btn img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* demo role switcher */
.demo-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 8px var(--gutter); background: var(--red-tint); border-bottom: 1px solid #F6D3D0; font-size: .85rem; }
.demo-tag { font-weight: 800; letter-spacing: .12em; font-size: .72rem; padding: 4px 9px; border-radius: 999px; background: var(--red); color: #fff; }
.seg { display: inline-flex; padding: 4px; gap: 2px; background: var(--surface-3); border-radius: 999px; overflow-x: auto; max-width: 100%; }
.seg button, .seg a { border: 0; background: transparent; color: var(--text-2); min-height: 36px; padding: 6px 14px; border-radius: 999px; font-weight: 700; font-size: .88rem; white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; }
.seg .is-active { background: var(--red); color: #fff; box-shadow: 0 4px 12px var(--red-glow); }

/* Attendance sheet — compact labelled rows */
.att-list { padding-top: 4px; padding-bottom: 4px; }
.att-row { padding: 12px 0; border-top: 1px solid var(--line); }
.att-row:first-child { border-top: 0; }
.att-who { display: flex; align-items: center; gap: 10px; }
.att-who .badge { flex-shrink: 0; }
.att-choices { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; margin-top: 10px; }
.att-choices button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 48px; padding: 4px 2px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-2); color: var(--text-2); font-size: .74rem; font-weight: 700; line-height: 1.1; text-align: center; overflow-wrap: anywhere; -webkit-tap-highlight-color: transparent; touch-action: manipulation; transition: background .12s ease, color .12s ease, border-color .12s ease; }
.att-choices button.is-active { color: #fff; border-color: transparent; }
.att-choices .att-present.is-active { background: var(--green); }
.att-choices .att-late.is-active { background: var(--amber); color: #3D2400; }
.att-choices .att-absent.is-active { background: var(--red); }
.att-choices .att-excused.is-active { background: var(--grey); }
@media (min-width: 768px) {
  .att-row { display: flex; align-items: center; gap: 16px; }
  .att-who { flex: 1; min-width: 0; }
  .att-choices { margin-top: 0; width: 380px; flex-shrink: 0; }
  .att-choices button { flex-direction: row; gap: 6px; font-size: .82rem; min-height: 42px; }
}

/* ------------------------------------------------------------------ navigation */
.sidebar { display: none; }
@media (min-width: 1100px) {
  /* `fixed`, not `sticky`: pinned to the viewport for good, so it can never run out of its containing
     block's height and disengage partway down a long page (the classic sticky pitfall — it would detach
     right as .shell-body ended, leaving a blank gap above it for the rest of the scroll). Its left edge
     matches .shell-body's own centering math (max-width: 1440px, margin: 0 auto) so it still lines up with
     .main's content on screens wider than that, even though "fixed" no longer follows that centered box.
     A solid background (not the translucent one this used to have), plus z-index: 2 — matching
     .dash-below-hero — so the dashboard's fixed, full-viewport hero-photo layer (.dash-hero-bg, z-index: 0,
     see its own comment) never shows through it or paints over it. top/height both add --demo-bar-h (0px
     normally, set inline on .shell only while the demo role-switcher bar is showing) — fixed positioning
     no longer follows that bar in the document flow the way the old sticky sidebar did, so without this it
     would start too high and sit on top of its buttons instead of below them. */
  .sidebar { display: block; position: fixed; top: calc(var(--header-h) + var(--demo-bar-h)); left: max(0px, calc((100vw - 1440px) / 2)); z-index: 2; width: 250px; height: calc(100vh - var(--header-h) - var(--demo-bar-h)); height: calc(100dvh - var(--header-h) - var(--demo-bar-h)); overflow-y: auto; padding: 22px 12px 24px 16px; border-right: 1px solid var(--line); background: var(--surface); }
  .bottom-nav { display: none !important; }
  .main { padding-bottom: 48px; margin-left: 250px; }
}
.nav-section { margin-top: 18px; }
.nav-section:first-child { margin-top: 0; }
.nav-heading { padding: 0 12px 6px; font-size: .7rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); font-weight: 800; }
.nav-link { display: flex; align-items: center; gap: 12px; min-height: 46px; padding: 8px 12px; border-radius: 12px; color: var(--text-2); font-weight: 600; }
.nav-link .icon { color: var(--muted); }
.nav-link.is-active { background: var(--surface); color: var(--text); font-weight: 800; box-shadow: var(--shadow), inset 3px 0 0 var(--red); }
.nav-link.is-active .icon { color: var(--red); }
.nav-link .badge-count { margin-left: auto; background: var(--red); color: #fff; font-size: .72rem; font-weight: 800; padding: 1px 7px; border-radius: 10px; }
.nav-group > summary { list-style: none; cursor: pointer; }
.nav-group > summary::-webkit-details-marker { display: none; }
.nav-group-chev { margin-left: auto; color: var(--muted); transition: transform .15s ease; }
.nav-group[open] > summary .nav-group-chev { transform: rotate(180deg); }
.nav-sublink { min-height: 40px; padding-left: 46px; font-size: .94rem; }

.bottom-nav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; height: calc(var(--bottom-h) + env(safe-area-inset-bottom));
  padding: 6px 6px env(safe-area-inset-bottom); display: grid; grid-template-columns: repeat(5, 1fr);
  background: rgba(255, 255, 255, .96); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid var(--line); box-shadow: 0 -6px 20px rgba(16, 18, 24, .05);
  /* iOS Safari can visually detach a `position: fixed` bar during scroll and leave it floating mid-page,
     especially after a wire:navigate swap (only clearing once the page is fully re-laid out, e.g. on reopen).
     Forcing this onto its own GPU layer stops that drift — the standard fix for this exact WebKit quirk. */
  transform: translateZ(0); -webkit-transform: translateZ(0); will-change: transform;
}
.bottom-nav a, .bottom-nav button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; border: 0; background: transparent; color: var(--muted); font-size: .72rem; font-weight: 700; border-radius: 12px; position: relative; }
.bottom-nav .is-active { color: var(--red); }
.bottom-nav .is-active::before { content: ""; position: absolute; top: -6px; width: 28px; height: 3px; border-radius: 0 0 3px 3px; background: var(--red); }
.bottom-nav .pip { position: absolute; top: 4px; left: 55%; min-width: 16px; height: 16px; border-radius: 8px; background: var(--red); color: #fff; font-size: .65rem; display: grid; place-items: center; padding: 0 4px; }

.sheet-backdrop { position: fixed; inset: 0; z-index: 70; background: rgba(16, 18, 24, .45); backdrop-filter: blur(2px); }
.sheet { position: fixed; left: 0; right: 0; bottom: 0; z-index: 71; max-height: 88vh; max-height: 88dvh; overflow-y: auto; background: var(--surface); border-radius: 24px 24px 0 0; padding: 10px 16px calc(20px + env(safe-area-inset-bottom)); box-shadow: 0 -20px 50px rgba(16, 18, 24, .2); }
.sheet-grip { width: 44px; height: 5px; border-radius: 3px; background: var(--line-strong); margin: 4px auto 12px; }
.sheet-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.sheet-grid a { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 14px 6px; border-radius: 16px; background: var(--surface-2); font-size: .82rem; font-weight: 700; text-align: center; color: var(--text-2); }
.sheet-grid a .icon { color: var(--red); }
.sheet-grid a.is-active { background: var(--red-tint); color: var(--red-700); box-shadow: inset 0 0 0 1px #F6CDCA; }
/* Slide-from-below open/close, used by the post composer's sheet (Alpine x-transition:enter/leave — see
   feed-composer.blade.php). ".sheet" alone still just appears/disappears instantly; this is opt-in per sheet
   so it's easy to give the same treatment to another one later without changing every sheet at once.
   Enter and leave use different timing on purpose: the same snappy, front-loaded curve that makes an open
   feel quick reads as an abrupt snap when reversed for the close, so the close is slightly longer and eases
   in instead of out. */
.sheet-anim-enter { transition: transform .28s cubic-bezier(.16, 1, .3, 1), opacity .28s ease; }
.sheet-anim-leave { transition: transform .38s cubic-bezier(.4, 0, .2, 1), opacity .32s ease-in; }
.sheet-anim-hidden { transform: translateY(100%); opacity: 0; }
.sheet-anim-visible { transform: translateY(0); opacity: 1; }
@media (min-width: 768px) { .sheet { left: 50%; right: auto; bottom: 50%; transform: translate(-50%, 50%); width: min(560px, 92vw); border-radius: 24px; }
    .sheet-anim-hidden { transform: translate(-50%, 100%); opacity: 0; }
    .sheet-anim-visible { transform: translate(-50%, 50%); opacity: 1; } }

/* ------------------------------------------------------------------ page header */
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 20px; }
.page-head .eyebrow { margin-bottom: 6px; }
.page-head .sub { color: var(--muted); margin-top: 8px; }
.back-link { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-weight: 700; font-size: .9rem; margin-bottom: 10px; min-height: 36px; }

/* ------------------------------------------------------------------ cards */
.card { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow); padding: 20px; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.card-head h2, .card-head h3 { font-size: 1.2rem; }
.card-link { color: var(--red); font-weight: 800; font-size: .88rem; display: inline-flex; align-items: center; gap: 4px; min-height: 32px; }
.card-flush { padding: 0; overflow: hidden; }
.card-flush > .card-head { padding: 18px 20px 0; }
.card-paper { background: var(--surface); }
.card-accent { box-shadow: var(--shadow), inset 4px 0 0 var(--red); }
/* Feed reminders (RSVP, next game, forms, fees, training) stand apart from the white posts around them. */
.feed-reminder {
  --reminder-accent: #FF6A61; --text: #FFFFFF; --text-2: #E4E5E8; --muted: #A9ABB2; --line: rgba(255, 255, 255, .12); --line-strong: rgba(255, 255, 255, .22); --surface: rgba(255, 255, 255, .08);
  background: linear-gradient(160deg, var(--ink-2), var(--ink)); color: var(--text); border-color: transparent;
  box-shadow: 0 10px 28px rgba(16, 18, 24, .22), inset 4px 0 0 var(--red);
}
.feed-reminder .eyebrow { color: #FF6A61 !important; }
.feed-reminder .icon-wrap { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; flex: none; background: rgba(var(--red-rgb), .2); color: #FF8A84; }
.feed-reminder .link { color: #FF8A84; }
.feed-reminder .hw-thumb { box-shadow: 0 0 0 1px rgba(255, 255, 255, .14); }

/* the dark card that gives depth: next game */
.card-hero {
  overflow: hidden; color: #fff; border: 0; border-radius: 26px;
  background: radial-gradient(480px 220px at 105% -20%, rgba(var(--red-rgb), .30), transparent 62%), linear-gradient(160deg, var(--ink-2), var(--ink) 70%);
  box-shadow: var(--shadow-dark);
}
.card-hero::before { content: ""; position: absolute; right: -90px; top: -90px; width: 260px; height: 260px; border-radius: 50%; border: 44px solid rgba(255, 255, 255, .035); pointer-events: none; }
.card-hero::after { content: ""; position: absolute; right: -110px; bottom: -150px; width: 240px; height: 240px; border-radius: 50%; border: 2px dashed rgba(var(--red-rgb), .45); pointer-events: none; }
.card-hero h1, .card-hero h2, .card-hero h3 { color: #fff; }
.card-hero .eyebrow { display: inline-block; color: #fff; background: var(--red); padding: 5px 11px; border-radius: 999px; letter-spacing: .1em; }
.card-hero .muted { color: rgba(255, 255, 255, .72); }
.card-hero .icon-sm { color: #FF6A61; }
.card-hero a:not(.btn) { color: #fff; }
.card-hero .btn-light { color: var(--text); }

/* ------------------------------------------------------------- dashboard hero + quick grid */
.dash-hero {
  /* Full-bleed: break out of .main's side padding so this runs edge to edge, not just another rounded card.
     Sized to its own content (logo, title, tiles) rather than forced to fill the whole first screen — that
     used to leave a large stretch of empty photo showing below the tiles on anything shorter than the
     tallest phones. */
  position: relative; z-index: 1; overflow: hidden; border-radius: 0; color: #fff; text-align: center;
  margin: 0 calc(-1 * var(--gutter));
  display: flex; flex-direction: column; justify-content: center;
  padding: 44px 20px 17px; background-size: cover; background-position: center;
  background-color: var(--ink);
  background-image: radial-gradient(600px 260px at 50% -30%, rgba(var(--red-rgb), .35), transparent 62%), linear-gradient(160deg, var(--ink-2), var(--ink) 75%);
  box-shadow: var(--shadow-dark);
}
@media (min-width: 1100px) { .dash-hero { margin: 0 -34px; } }
/* When a club photo exists, the box above stays visually transparent — the photo itself lives in
   .dash-hero-bg below, a genuinely `position: fixed` element rather than `background-attachment: fixed`
   on this box. The two look the same when nothing scrolls, but `background-attachment: fixed` is well
   known to bleed outside its own box on iOS Safari once this element (which needs `overflow: hidden` for
   its own layout) scrolls — the photo shows through over the content that's supposed to cover it. A real
   fixed sibling, positioned relative to the viewport instead of to this box, doesn't have that bug. */
.dash-hero.has-photo { background: none; }
/* z-index: 0, not a negative value — a negative z-index only reliably sits behind the page's own plain
   background when the browser propagates BODY's background to the canvas, which isn't guaranteed. Instead
   this and .dash-below-hero below are both explicitly stacked (0 then 1) within the same context, so which
   one wins is a plain, portable z-index comparison rather than that propagation edge case. */
.dash-hero-bg {
  /* top/bottom/right: 0 (true edge-to-edge, same as before) — only `left` is pulled in, and only on a
     screen wider than .shell-body's own centered max-width (1440px, margin: 0 auto), to match where the
     sidebar (which does respect that same centering) starts. Without it, inset: 0 here left the photo
     showing in the gutter to the left of the centered app, past the sidebar's own left edge, undoing the
     point of a solid sidebar in the first place. The right side has no sidebar to line up with, so it stays
     full-bleed all the way to the edge of the screen. */
  position: fixed; top: 0; bottom: 0; right: 0; left: max(0px, calc((100vw - 1440px) / 2)); z-index: 0;
  background-size: cover; background-position: center;
  background-image: var(--hero-bg-mobile);
}
@media (min-width: 768px) { .dash-hero-bg { background-image: var(--hero-bg-desktop); } }
.dash-hero-bg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(15, 16, 20, .18), rgba(15, 16, 20, .62)); }
/* Everything below the hero: its own opaque layer, stacked above .dash-hero-bg, so it fully covers the
   fixed photo (gaps between cards included) as it scrolls up over it — not just the cards themselves. Full
   width and full height of .main's own padding, for the same reason .dash-hero above breaks out of it:
   that padding is otherwise a gutter-width strip (sides, and below the last card) where nothing opaque
   sits, letting the fixed photo bleed through there as this scrolls past it. Matches .main's own padding
   values exactly (mobile default, then the >=1100px breakpoint) so the visible spacing is unchanged. */
.dash-below-hero {
  /* flex column + gap: this wraps what used to be a run of direct .stack-lg children (each spaced by
     .stack-lg's own 24px gap) into one .stack-lg item of its own — without its own flex/gap here, that
     24px rhythm between them (hero to the child-switcher, switcher to the next card, ...) would collapse
     to nothing, since a plain div has no gap system and each child's spacing was never its own margin. */
  display: flex; flex-direction: column; gap: 24px;
  position: relative; z-index: 1; background: var(--bg);
  margin: 0 calc(-1 * var(--gutter)) calc(-1 * (var(--bottom-h) + 32px));
  padding: 10px var(--gutter) calc(var(--bottom-h) + 32px);
}
@media (min-width: 1100px) { .dash-below-hero { margin: 0 -34px -48px; padding: 15px 34px 48px; } }
.dash-hero > * { position: relative; z-index: 1; }
.dash-hero .club-name { font-size: .74rem; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: rgba(255, 255, 255, .65); }
.dash-hero .logo { width: 132px; height: 132px; object-fit: contain; margin: 16px auto 10px; display: block; filter: drop-shadow(0 6px 16px rgba(0, 0, 0, .4)); }
.dash-hero .eyebrow { display: inline-block; color: #fff; background: var(--red); padding: 5px 12px; border-radius: 999px; letter-spacing: .1em; font-size: .7rem; font-weight: 800; text-transform: uppercase; margin-bottom: 8px; }
.dash-hero h1 { color: #fff; font-size: 1.6rem; margin: 2px 0 6px; }
.dash-hero .sub { color: rgba(255, 255, 255, .8); font-weight: 700; font-size: .9rem; }
/* Now living inside .dash-hero itself, so the dark card behind it stretches to cover the whole block —
   logo, title and buttons together, instead of the buttons sitting on the page's plain background below. */
.dash-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 28px; }
/* Bold tiles, not the plain white card — glass panels over the hero's own dark background so they still
   read as distinct buttons rather than blending into it. Three per row, kept square regardless of how much
   text a tile's hint line ends up needing. */
.dash-tile { aspect-ratio: 1 / 1; background: rgba(255, 255, 255, .16); border: 1px solid rgba(255, 255, 255, .24); border-radius: 16px; padding: 11px 10px; display: flex; flex-direction: column; gap: 6px; min-width: 0; text-align: left; overflow: hidden; }
.dash-tile .icon-wrap { width: 30px; height: 30px; border-radius: 10px; background: rgba(255, 255, 255, .2); color: var(--red); display: grid; place-items: center; }
.dash-tile .icon-wrap .icon-sm { width: 15px; height: 15px; }
.dash-tile .title { font-weight: 800; font-size: .84rem; color: #fff; line-height: 1.2; letter-spacing: -.005em; overflow-wrap: break-word; -webkit-hyphens: auto; hyphens: auto; }
/* Pushed to the bottom of the tile with auto margin — icon + title stay together up top, the info line
   anchors to the bottom edge no matter how many lines the title above it wraps to. */
.dash-tile .hint { margin-top: auto; padding-top: 4px; font-size: .78rem; color: rgba(255, 255, 255, .85); font-weight: 600; line-height: 1.25; overflow-wrap: break-word; word-break: break-word; }
.dash-tile.is-alert { box-shadow: 0 0 0 1.5px var(--red), var(--shadow-dark); }
/* Past phone-portrait width (a landscape phone, a tablet, desktop) three per row at 1:1 aspect ratio grows
   into huge squares — each column just gets as wide as the extra screen width allows. Six in a single row
   instead, sized by the row's own width rather than stretching to fill it, keeps every tile small and the
   whole grid capped at a sensible width no matter how wide the screen gets. */
@media (min-width: 640px) {
  .dash-grid { grid-template-columns: repeat(6, 1fr); gap: 10px; max-width: 640px; margin-left: auto; margin-right: auto; }
  .dash-tile { aspect-ratio: auto; padding: 10px 6px; gap: 6px; }
  .dash-tile .icon-wrap { width: 24px; height: 24px; }
  .dash-tile .icon-wrap .icon-sm { width: 13px; height: 13px; }
  .dash-tile .title { font-size: .74rem; line-height: 1.35; margin-top: 2px; letter-spacing: .02em; }
  .dash-tile .hint { font-size: .66rem; }
}
.dash-tile.is-alert .icon-wrap { background: var(--red); color: #fff; }

/* stat tiles */
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; display: flex; flex-direction: column; gap: 6px; min-width: 0; box-shadow: var(--shadow); }
.stat .label { font-size: .72rem; color: var(--muted); font-weight: 700; letter-spacing: .02em; text-transform: uppercase; display: flex; align-items: center; gap: 8px; min-width: 0; overflow-wrap: anywhere; }
.stat .value { font-family: var(--font-display); font-weight: 800; font-size: 2.1rem; line-height: 1; font-variant-numeric: tabular-nums; }
.stat .hint { font-size: .8rem; color: var(--muted); }
.stat .icon-wrap { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: var(--red-soft); color: var(--red); flex: none; }
.stat.is-alert { border-color: #F6CDCA; background: linear-gradient(180deg, var(--red-tint), var(--surface)); }
.card .stat { box-shadow: none; background: var(--surface-2); border-color: transparent; }
.money-sum { padding: 16px; }
.money-sum.is-alert { border-color: #F6CDCA; background: linear-gradient(180deg, var(--red-tint), var(--surface)); }
.money-sum-cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.money-sum-cols > div { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.money-sum-cols > div + div { border-left: 1px solid var(--line); padding-left: 10px; }
.money-sum-label { font-size: .68rem; color: var(--muted); font-weight: 800; letter-spacing: .03em; text-transform: uppercase; line-height: 1.2; }
.money-sum-value { font-family: var(--font-display); font-weight: 800; font-size: clamp(1.15rem, 5.4vw, 1.5rem); line-height: 1; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
@media (min-width: 768px) { .money-sum-value { font-size: 2rem; } .money-sum { padding: 20px; } }
.stat-link { cursor: pointer; transition: transform .12s ease, box-shadow .12s ease; }
.stat-link:hover, .stat-link:focus-visible { transform: translateY(-2px); box-shadow: 0 10px 22px rgba(16, 18, 24, .12); }

/* date block: red for the date line, used everywhere */
.datebox { flex: none; width: 64px; border-radius: 14px; overflow: hidden; text-align: center; background: var(--surface-2); color: var(--text); border: 1px solid var(--line); }
.datebox .dow { background: var(--red); color: #fff; font-weight: 800; font-size: .7rem; letter-spacing: .1em; padding: 4px 0; text-transform: uppercase; }
.datebox .day { font-family: var(--font-display); font-weight: 800; font-size: 1.7rem; line-height: 1.1; padding-top: 2px; }
.datebox .mon { font-weight: 800; font-size: .7rem; letter-spacing: .06em; text-transform: uppercase; padding-bottom: 5px; color: var(--red-600); }
.card-hero .datebox { background: #fff; border-color: #fff; color: var(--text); }

/* ------------------------------------------------------------------ buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 10px 20px; border-radius: 999px; border: 1px solid transparent; font-weight: 800; font-size: .98rem; line-height: 1.1; text-align: center; transition: transform .12s ease, box-shadow .15s ease, background .15s ease; }
.btn:active { transform: translateY(1px) scale(.99); }
.btn[disabled], .btn.is-disabled { opacity: .5; pointer-events: none; }
.btn-primary { background: var(--red); color: #fff; box-shadow: 0 8px 20px var(--red-glow); }
.btn-secondary { background: var(--surface); color: var(--text); border-color: var(--line-strong); box-shadow: 0 1px 2px rgba(16, 18, 24, .05); }
.btn-secondary .icon-sm, .btn-secondary .icon { color: var(--red); }
.btn-dark { background: var(--ink); color: #fff; }
.btn-ghost { background: transparent; color: var(--text-2); }
.btn-success { background: var(--green); color: #fff; }
.btn-danger { background: transparent; color: var(--red-600); border-color: #F2B8B3; }
.btn-light { background: #fff; color: var(--text); }
.btn-light .icon-sm { color: var(--red); }
.btn-lg { min-height: 58px; font-size: 1.05rem; padding: 12px 22px; }
.btn-sm { min-height: 38px; padding: 6px 14px; font-size: .86rem; }
.btn-block { width: 100%; }
.grid-4 > .btn { border-radius: 18px; }

/* RSVP pair */
.rsvp { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.rsvp-btn { min-height: 62px; border-radius: 999px; border: 2px solid transparent; font-weight: 800; font-size: clamp(.9rem, 3.9vw, 1.02rem); display: flex; align-items: center; justify-content: center; gap: 6px; padding: 8px 10px; text-align: center; line-height: 1.15; }
/* Smaller icon + tighter spacing so "Cannot attend" (and the NL/ES/PAP labels) fit on one line like "We are going" on phones. */
.rsvp-btn .icon { width: 20px; height: 20px; flex-shrink: 0; }
.rsvp-yes { background: #EAF8EF; color: var(--green-ink); border-color: #C5EBD2; }
.rsvp-no { background: var(--red-tint); color: var(--red-700); border-color: #F6CDCA; }
.rsvp-yes.is-on { background: var(--green); color: #fff; border-color: var(--green); box-shadow: 0 8px 20px rgba(22, 163, 74, .3); }
.rsvp-no.is-on { background: var(--red); color: #fff; border-color: var(--red); box-shadow: 0 8px 20px var(--red-glow); }

/* ------------------------------------------------------------------ badges */
.badge { display: inline-flex; align-items: center; gap: 5px; height: 26px; padding: 0 10px; border-radius: 13px; font-size: .77rem; font-weight: 800; white-space: nowrap; border: 1px solid transparent; background: var(--surface-3); color: var(--text-2); }
.badge .icon-sm { width: 14px; height: 14px; }
.badge-green { background: #E7F7EC; color: var(--green-ink); border-color: #C5EBD2; }
.badge-amber { background: #FFF4DE; color: var(--amber-ink); border-color: #F5DDA8; }
.badge-red { background: var(--red-soft); color: var(--red-700); border-color: #F6CDCA; }
.badge-grey { background: var(--surface-2); color: var(--text-2); border-color: var(--line); }
.badge-white { background: #fff; color: var(--text); }
.badge-solid-red { background: var(--red); color: #fff; }
.card-hero .badge-green { background: rgba(34, 197, 94, .18); color: #86EFAC; border-color: rgba(34, 197, 94, .35); }
.card-hero .badge-amber { background: rgba(245, 165, 36, .18); color: #FFD27A; border-color: rgba(245, 165, 36, .35); }
.demo-label { display: inline-flex; align-items: center; gap: 4px; font-size: .68rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--amber-ink); background: #FFF8EA; border: 1px dashed #EFC77A; padding: 2px 7px; border-radius: 6px; }

/* ------------------------------------------------------------------ lists */
.list { display: flex; flex-direction: column; }
.list-item { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); min-height: 60px; }
.list-item:first-child { border-top: 0; }
/* A list row can be a <button> (the message recipient picker). Without this it turns up wearing the
   browser's own button chrome — grey face, its own border, centred label — instead of matching the rows
   around it. Only the three sides are cleared, so .list-item keeps its own separating border-top. */
button.list-item { width: 100%; background: none; border-left: 0; border-right: 0; border-bottom: 0; font: inherit; color: inherit; text-align: left; cursor: pointer; }
/* A list used as a picker: short rows of plain text, not content cards. The default 60px row means only six
   fit inside the recipient picker's scroll area on a phone, which pushes the collapsed "Staff" and "Parents"
   headers out of sight — and a section nobody can see is a section nobody opens. */
.list-compact .list-item { min-height: 44px; padding: 9px 0; gap: 10px; }
/* A ticked recipient in the message picker, and — greyed — one that a ticked group already covers, so it is
   visibly included without being tickable again. The check sits at the far end so it lines up straight down
   the list whether the row starts with an avatar or an icon, and whether or not the row is indented. */
.list-item.is-picked::after, .list-item.is-covered::after { content: "✓"; margin-left: auto; padding-left: 10px; font-weight: 800; }
.list-item.is-picked { background: var(--red-tint); }
.list-item.is-picked::after { color: var(--red); }
.list-item.is-covered { opacity: .5; cursor: default; }
.list-item.is-covered::after { color: var(--muted); }
.list-item > .icon { color: var(--red); }
.card-flush .list-item { padding-left: 20px; padding-right: 20px; }
.list-title { font-weight: 700; }
.list-meta { color: var(--muted); font-size: .86rem; }
.chev { color: var(--line-strong); margin-left: auto; }
.avatar { flex: none; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: linear-gradient(135deg, #EEEFF2, #E1E3E8); border: 2px solid #fff; box-shadow: 0 0 0 1px var(--line); font-family: var(--font-display); font-weight: 800; font-size: 1rem; color: var(--text-2); overflow: hidden; position: relative; }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar-lg { width: 92px; height: 92px; font-size: 1.9rem; border-width: 3px; box-shadow: 0 0 0 3px var(--red), 0 10px 24px rgba(var(--red-rgb), .22); }
.avatar-sm { width: 34px; height: 34px; font-size: .82rem; }
.jersey { flex: none; min-width: 40px; height: 40px; padding: 0 6px; border-radius: 10px; display: grid; place-items: center; font-family: var(--font-display); font-weight: 800; font-size: 1.15rem; background: var(--ink); color: #fff; }
.jersey-red { background: var(--red); }

/* ------------------------------------------------------------------ forms */
.field { display: flex; flex-direction: column; gap: 6px; }
.label { font-weight: 700; font-size: .9rem; color: var(--text); }
.help { font-size: .82rem; color: var(--muted); }
.error { font-size: .85rem; color: var(--red-600); font-weight: 700; }
.input, .select, .textarea { width: 100%; min-height: 50px; padding: 12px 14px; border-radius: var(--radius-sm); background: var(--field); border: 1px solid var(--line-strong); color: var(--text); font-size: 1rem; }
.textarea { min-height: 110px; resize: vertical; }
/* Neutral focus (dark border + soft ring) — red is kept for errors only, so an empty autofocused field never looks wrong. */
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--text-2); background: #fff; box-shadow: 0 0 0 4px rgba(23, 24, 28, .08); }
.input.is-invalid:focus, .select.is-invalid:focus, .textarea.is-invalid:focus { border-color: var(--red); box-shadow: 0 0 0 4px rgba(var(--red-rgb), .12); }
.input.is-invalid, .select.is-invalid, .textarea.is-invalid { border-color: var(--red); background: var(--red-tint); }
.select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23E8261E' stroke-width='2.5'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; background-size: 18px; padding-right: 40px; }
.check { display: flex; align-items: flex-start; gap: 12px; min-height: 44px; cursor: pointer; }
.check input { width: 22px; height: 22px; margin: 1px 0 0; accent-color: var(--red); flex: none; }
.form-grid { display: grid; gap: 14px; grid-template-columns: 1fr; }
/* iPhone Safari gives date/time fields a built-in minimum width and ignores width: 100%, so on a narrow phone
   they stuck out past the right edge of forms (e.g. "Payment date"). Dropping the native look lets them size like
   every other field; the native date picker still opens on tap. Grid/flex children may shrink below their content. */
.input[type="date"], .input[type="time"], .input[type="datetime-local"], .input[type="month"] { -webkit-appearance: none; appearance: none; display: block; min-width: 0; max-width: 100%; text-align: left; }
.input::-webkit-date-and-time-value { text-align: left; min-height: 1.5em; }
.field { min-width: 0; }
.form-grid > * { min-width: 0; }
.form-grid-3-tight { grid-template-columns: repeat(3, 1fr); gap: 6px; }
.form-grid-3-tight .label { font-size: .58rem; }
.form-grid-3-tight .input { font-size: .68rem; padding: 4px 2px; min-height: 32px; text-align: center; }
.field-sm .label { font-size: .74rem; }
.field-sm .input { font-size: .78rem; padding: 6px 8px; min-height: 34px; }
@media (min-width: 768px) { .form-grid-2 { grid-template-columns: 1fr 1fr; } .form-grid-3 { grid-template-columns: 1fr 1fr 1fr; } .form-grid .full { grid-column: 1 / -1; } }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 6px 15px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line-strong); font-weight: 700; font-size: .88rem; color: var(--text-2); }
.chip.is-active { background: var(--red); border-color: var(--red); color: #fff; box-shadow: 0 4px 12px var(--red-glow); }
.chip.is-active .type-dot { background: #fff !important; box-shadow: none !important; }
.chip:disabled { opacity: .45; cursor: not-allowed; border-color: var(--line-strong); color: var(--text-2); }
.toolbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 16px; }
.search { position: relative; flex: 1; min-width: 200px; }
.search .icon { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--red); }
.search .input { padding-left: 44px; border-radius: 999px; background: var(--surface); }

.scale { display: flex; gap: 6px; }
.scale button { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line-strong); background: var(--surface); font-family: var(--font-display); font-weight: 800; font-size: 1.1rem; color: var(--text-2); }
.scale button.is-on { background: var(--red); border-color: var(--red); color: #fff; box-shadow: 0 6px 14px var(--red-glow); }
.stepper { display: inline-flex; align-items: center; border: 1px solid var(--line-strong); border-radius: 999px; overflow: hidden; background: var(--surface); }
.stepper button { width: 40px; height: 42px; border: 0; background: var(--surface-2); font-size: 1.2rem; font-weight: 800; color: var(--red); }
.stepper button:active { background: var(--red); color: #fff; }
.stepper .val { min-width: 36px; text-align: center; font-family: var(--font-display); font-weight: 800; font-size: 1.15rem; }

/* ------------------------------------------------------------------ tabs */
.tabs { display: flex; gap: 6px; overflow-x: auto; padding: 4px 6px 14px; margin: -4px -6px 4px; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tab { flex: none; min-height: 42px; padding: 8px 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--text-2); font-weight: 700; font-size: .9rem; display: inline-flex; align-items: center; gap: 6px; }
.tab .icon-sm { color: var(--red); }
.tab.is-active { background: var(--ink); border-color: var(--ink); color: #fff; box-shadow: 0 6px 16px rgba(16, 18, 24, .2); }
.tab.is-active .icon-sm { color: #FF6A61; }

/* ------------------------------------------------------------------ tables */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.table { width: 100%; border-collapse: collapse; font-size: .93rem; }
.table th { text-align: left; font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); font-weight: 800; padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; background: var(--surface-2); }
.table td { padding: 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tr:last-child td { border-bottom: 0; }
.table .num, .table th.num { text-align: right; }

/* ------------------------------------------------------------------ progress & charts */
.bar { height: 10px; border-radius: 5px; background: var(--surface-3); overflow: hidden; }
.bar > span { display: block; height: 100%; border-radius: 5px; background: linear-gradient(90deg, var(--red-600), var(--red-light)); transition: width .2s linear; }
.bar.green > span { background: linear-gradient(90deg, #15A34A, #4ADE80); }
.skill { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px 12px; align-items: center; }
.skill .bar { grid-column: 1 / -1; }
.skill-pips { display: flex; gap: 4px; }
.skill-pips i { width: 18px; height: 8px; border-radius: 4px; background: var(--surface-3); }
.skill-pips i.on { background: var(--red); }
.ring { --p: 0; width: 78px; height: 78px; border-radius: 50%; display: grid; place-items: center; background: conic-gradient(var(--red) calc(var(--p) * 1%), var(--surface-3) 0); flex: none; }
.ring > div { width: 62px; height: 62px; border-radius: 50%; background: var(--surface); display: grid; place-items: center; font-family: var(--font-display); font-weight: 800; font-size: 1.2rem; }
.ring.green { background: conic-gradient(var(--green) calc(var(--p) * 1%), var(--surface-3) 0); }
.chart { width: 100%; height: auto; overflow: visible; }
.chart .grid-line { stroke: var(--line); stroke-width: 1; }
.chart .axis { fill: var(--muted); font-size: 11px; font-family: var(--font); font-weight: 600; }
.chart .line { fill: none; stroke: var(--red); stroke-width: 3; stroke-linejoin: round; stroke-linecap: round; }
.chart .pt { fill: #fff; stroke: var(--red); stroke-width: 3; }

/* countdown (on the dark hero) */
.countdown { display: flex; gap: 8px; }
.countdown div { min-width: 60px; padding: 9px 6px; border-radius: 14px; background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .08); text-align: center; }
.countdown b { display: block; font-family: var(--font-display); font-weight: 800; font-size: 1.75rem; line-height: 1; font-variant-numeric: tabular-nums; color: #fff; }
.countdown span { font-size: .66rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: rgba(255, 255, 255, .7); }

.uniform { display: flex; align-items: center; gap: 14px; }
.shirt { flex: none; width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center; background: var(--red-soft); }
.shirt svg { width: 40px; height: 40px; }
.uniform-pick { display: block; width: 100%; text-align: left; background: var(--surface-2); border: 2px solid transparent; border-radius: var(--radius); padding: 10px 12px; cursor: pointer; }
.uniform-pick.is-active { border-color: var(--red); background: var(--red-tint); }
.uniform-pick .list-meta { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* ------------------------------------------------------------------ calendar */
.cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.cal-dow { text-align: center; font-size: .7rem; font-weight: 800; color: var(--muted); letter-spacing: .08em; text-transform: uppercase; padding: 6px 0; }
.cal-day { min-height: 66px; border-radius: 12px; background: var(--surface-2); border: 1px solid transparent; padding: 6px; display: flex; flex-direction: column; gap: 3px; text-align: left; }
.cal-day.is-out { opacity: .4; }
.cal-day.is-today { background: #fff; border-color: var(--red); box-shadow: 0 0 0 1px var(--red); }
.cal-day .d { font-family: var(--font-display); font-weight: 800; font-size: .95rem; }
.cal-ev { display: block; font-size: .68rem; font-weight: 800; padding: 2px 5px; border-radius: 5px; background: var(--surface-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cal-ev.t-game { background: var(--red); color: #fff; }
.cal-ev.t-practice { background: #E3F6EA; color: var(--green-ink); }
.cal-ev.t-meeting, .cal-ev.t-registration { background: #FFF1D6; color: var(--amber-ink); }
.cal-ev.t-fundraiser, .cal-ev.t-other { background: var(--ink); color: #fff; }
.cal-ev.t-speed_test { background: #E3EEFF; color: #1D4ED8; }
@media (max-width: 560px) { .cal-day { min-height: 52px; padding: 4px; } .cal-ev { font-size: 0; height: 6px; padding: 0; } }
.type-dot { width: 10px; height: 10px; border-radius: 50%; flex: none; background: var(--grey); }
.type-dot.t-game { background: var(--red); box-shadow: 0 0 0 3px var(--red-soft); }
.type-dot.t-practice { background: var(--green); }
.type-dot.t-meeting, .type-dot.t-registration { background: var(--amber); }
.type-dot.t-fundraiser, .type-dot.t-other { background: var(--ink); }
.type-dot.t-speed_test { background: #1D4ED8; }

/* ------------------------------------------------------------------ game day & lineup */
.field-svg { width: 100%; max-width: 440px; margin: 0 auto; border-radius: 18px; }
.pos-chip { cursor: pointer; }
.pos-chip rect { fill: rgba(23, 24, 28, .88); stroke: rgba(255, 255, 255, .25); stroke-width: 1.5; }
.pos-chip.is-filled rect { fill: #fff; stroke: #fff; }
.pos-chip .pos-code { fill: #FF6A61; font: 800 12px var(--font-display); }
.pos-chip.is-filled .pos-code { fill: var(--red); }
.pos-chip .pos-name { fill: #C9CBD1; font: 700 15px var(--font); }
.pos-chip.is-filled .pos-name { fill: var(--text); }
.pos-chip.is-selected rect { stroke: var(--red); stroke-width: 3; }
.order-list { display: flex; flex-direction: column; gap: 6px; }
.order-item { display: flex; align-items: center; gap: 10px; min-height: 58px; padding: 6px 8px 6px 6px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); box-shadow: 0 1px 2px rgba(16, 18, 24, .04); }
.order-item.is-out { opacity: .45; }
.order-item .n { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--red); color: #fff; font-family: var(--font-display); font-weight: 800; font-size: 1.05rem; flex: none; }
.order-item .handle { color: var(--muted); cursor: grab; padding: 6px; }
.order-item.dragging { opacity: .5; outline: 2px dashed var(--red); }
.order-item .mini { display: flex; gap: 2px; }
.order-item .mini button { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line-strong); background: var(--surface); display: grid; place-items: center; color: var(--red); }
.order-item .mini button[disabled] { opacity: .35; }
.pos-select { min-height: 40px; padding: 6px 30px 6px 12px; font-size: .9rem; font-weight: 800; width: auto; background-position: right 8px center; border-radius: 999px; }
.inning-cell { text-align: center; padding: 6px 4px; border-radius: 8px; background: var(--red-soft); color: var(--red-700); font-family: var(--font-display); font-weight: 800; }
.inning-cell.is-bench { background: transparent; border: 1px dashed var(--line-strong); color: var(--muted); }
.scoreboard { display: grid; grid-template-columns: 1fr repeat(3, 64px); background: var(--ink); color: #fff; border-radius: 16px; overflow: hidden; box-shadow: var(--shadow-dark); }
.scoreboard > div { padding: 10px 12px; border-bottom: 1px solid rgba(255, 255, 255, .08); display: flex; align-items: center; }
.scoreboard .h { font-size: .72rem; letter-spacing: .12em; color: #A6A8AF; font-weight: 800; justify-content: center; }
.scoreboard .team { font-family: var(--font-display); font-weight: 800; text-transform: uppercase; font-size: 1.05rem; }
.scoreboard .v { justify-content: center; font-family: var(--font-display); font-weight: 800; font-size: 1.6rem; color: #FF8A84; }
.scoreboard > div:nth-last-child(-n+4) { border-bottom: 0; }
.scoreboard.is-live { grid-template-columns: minmax(0, 1fr) repeat(3, minmax(58px, 72px)); }
.scoreboard.is-live .team { font-size: .95rem; line-height: 1.15; overflow-wrap: anywhere; }
.scoreboard.is-live .v { flex-direction: column; gap: 6px; padding: 10px 5px; }
.score-n { line-height: 1; }
.score-btn { display: grid; place-items: center; width: 100%; max-width: 56px; border: 0; border-radius: 12px; color: #fff; font-family: var(--font); font-weight: 800; line-height: 1; -webkit-tap-highlight-color: transparent; touch-action: manipulation; transition: transform .08s ease, filter .12s ease; }
.score-btn:active { transform: scale(.94); filter: brightness(1.1); }
.score-plus { min-height: 48px; font-size: 1.6rem; background: var(--red); box-shadow: 0 4px 12px var(--red-glow); }
.score-minus { min-height: 44px; font-size: 1.4rem; background: rgba(255, 255, 255, .1); color: #D5D6DA; }
.scoreboard .input { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .15); color: #fff; }
.reco { border: 1px dashed #EFC77A; background: #FFFBF1; border-radius: var(--radius); padding: 12px 14px; display: flex; gap: 10px; align-items: flex-start; }
.reco .icon { color: var(--amber-ink); margin-top: 2px; }
.avail { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.avail > div { border-radius: 16px; padding: 12px; text-align: center; background: var(--surface-2); }
.avail b { display: block; font-family: var(--font-display); font-weight: 800; font-size: 2.1rem; line-height: 1; }
.avail .g b { color: var(--green); } .avail .r b { color: var(--red); } .avail .a b { color: #D98A00; }

/* ------------------------------------------------------------------ messages */
.thread { display: flex; flex-direction: column; gap: 10px; }
.bubble { max-width: 84%; padding: 10px 14px; border-radius: 18px; background: var(--surface-2); border: 1px solid var(--line); }
.bubble.mine { align-self: flex-end; background: var(--red); border-color: var(--red); color: #fff; border-bottom-right-radius: 5px; }
.bubble.theirs { border-bottom-left-radius: 5px; }
.bubble .meta { font-size: .72rem; opacity: .75; margin-top: 4px; }
.composer { display: flex; gap: 8px; align-items: flex-end; }
.composer .textarea { min-height: 50px; border-radius: 24px; }
.composer-trigger { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 50px; padding: 8px 16px 8px 8px; border-radius: 999px; background: var(--field); border: 1px solid var(--line-strong); text-align: left; }
.composer-trigger:hover { border-color: var(--red); }
.composer-trigger-text { color: var(--muted); font-size: 1rem; }
.mention-dropdown { position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 5; background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--radius-sm); box-shadow: 0 12px 30px rgba(16, 18, 24, .18); max-height: 240px; overflow-y: auto; padding: 4px 12px; }
.mention-dropdown .list-item { min-height: 48px; padding: 8px 0; }
.unread-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--red); box-shadow: 0 0 0 3px var(--red-soft); flex: none; }

/* ------------------------------------------------------------------ modal */
.modal-backdrop { position: fixed; inset: 0; z-index: 80; background: rgba(16, 18, 24, .45); backdrop-filter: blur(3px); display: flex; align-items: flex-end; justify-content: center; }
.modal { width: 100%; max-height: 92vh; max-height: 92dvh; overflow-y: auto; background: var(--surface); border-radius: 24px 24px 0 0; padding: 20px 18px calc(22px + env(safe-area-inset-bottom)); box-shadow: 0 -20px 60px rgba(16, 18, 24, .22); border-top: 4px solid var(--red); }
.modal-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 16px; }
.modal-foot { display: flex; gap: 10px; justify-content: flex-end; margin-top: 18px; flex-wrap: wrap; }
@media (min-width: 768px) { .modal-backdrop { align-items: center; padding: 24px; } .modal { width: min(620px, 100%); border-radius: 24px; } .modal-wide { width: min(860px, 100%); } }

/* ------------------------------------------------------------------ toast */
.toasts { position: fixed; z-index: 90; left: 50%; transform: translateX(-50%); top: calc(var(--header-h) + 10px); width: min(460px, calc(100% - 24px)); display: flex; flex-direction: column; gap: 8px; pointer-events: none; }
.toast { pointer-events: auto; display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: 16px; background: var(--ink); color: #fff; font-weight: 700; box-shadow: 0 16px 40px rgba(16, 18, 24, .3); border-left: 6px solid var(--green); }
.toast.is-error { border-left-color: var(--red); }
.toast .icon { color: #4ADE80; }
.toast.is-error .icon { color: #FF6A61; }

/* ------------------------------------------------------------------ empty state & alerts */
.empty { text-align: center; padding: 34px 16px; color: var(--muted); display: flex; flex-direction: column; align-items: center; gap: 10px; }
.empty .icon-lg { color: var(--red); width: 44px; height: 44px; padding: 10px; box-sizing: content-box; border-radius: 50%; background: var(--red-soft); }
.empty strong { color: var(--text); font-family: var(--font-display); text-transform: uppercase; font-size: 1.15rem; }
.alert { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface-2); color: var(--text); }
.alert .icon { margin-top: 1px; color: var(--muted); }
.alert-red { border-color: #F6CDCA; background: #FEF3F2; }
.alert-red .icon { color: var(--red); }
.alert-amber { border-color: #F5DDA8; background: #FFFAF0; }
.alert-amber .icon { color: var(--amber-ink); }
.alert-green { border-color: #C5EBD2; background: #F1FBF4; }
.alert-green .icon { color: var(--green); }

/* child switcher */
/* Horizontal padding matches .card's own 20px so a pill's edge lines up with a card's text right below it
   — the row sits directly on .dash-below-hero's plain background, not inside a card of its own, so without
   this it reads as sitting closer to the edge than everything around it, even though the outer gutter is
   the same for both. */
.kids { display: flex; gap: 8px; overflow-x: auto; padding: 4px 20px 16px; margin: -4px 0 -10px; scrollbar-width: none; }
.kids::-webkit-scrollbar { display: none; }
.kid { flex: none; display: flex; align-items: center; gap: 10px; min-height: 54px; padding: 6px 18px 6px 6px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); font-weight: 800; box-shadow: 0 1px 2px rgba(16, 18, 24, .05); }
.kid.is-active { background: var(--ink); color: #fff; border-color: var(--ink); box-shadow: 0 8px 20px rgba(16, 18, 24, .22); }
.kid.is-active .avatar { box-shadow: 0 0 0 2px var(--red); border-color: var(--ink); }

/* ------------------------------------------------------------------ auth pages */
.auth { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 28px 16px 40px; background: radial-gradient(700px 320px at 50% -120px, rgba(var(--red-rgb), .10), transparent 65%), var(--bg); }
.auth-card { width: 100%; max-width: 420px; }
.auth-logo { width: 230px; margin: 0 auto 10px; filter: drop-shadow(0 10px 24px rgba(var(--red-rgb), .25)); }
.auth-title { text-align: center; font-size: 2.4rem; }
.auth-title span { color: var(--red); display: block; }
.auth-tagline { text-align: center; color: var(--muted); margin: 8px 0 22px; font-weight: 700; }
.auth-top { position: fixed; top: 14px; right: 14px; z-index: 5; }
.demo-accounts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.divider { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: .76rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; margin: 18px 0; }
.divider::before, .divider::after { content: ""; height: 1px; flex: 1; background: var(--line); }

/* ------------------------------------------------------------------ misc */
.kv { display: grid; grid-template-columns: minmax(110px, 38%) 1fr; gap: 8px 14px; font-size: .95rem; }
.kv dt { color: var(--muted); font-weight: 600; }
.kv dd { margin: 0; font-weight: 700; }
.pill-row { display: flex; gap: 6px; flex-wrap: wrap; }
.note { padding: 12px 14px; border-radius: 14px; background: var(--red-tint); border-left: 4px solid var(--red); }
.checklist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.checklist li { display: flex; align-items: center; gap: 10px; min-height: 40px; font-weight: 600; }
.checklist .box { width: 26px; height: 26px; border-radius: 50%; border: 2px solid var(--line-strong); display: grid; place-items: center; flex: none; background: #fff; }
.checklist .box.on { background: var(--green); border-color: var(--green); color: #fff; }
.money { font-family: var(--font-display); font-weight: 800; font-variant-numeric: tabular-nums; }
.divider-line { border: 0; border-top: 1px solid var(--line); margin: 14px 0; }
.link { color: var(--red); font-weight: 800; }
/* A person's name that quietly opens their account in Users & Roles (admin only, see x-person-link) — kept
   the same color/weight as the plain text it sits inside everywhere (list titles, comments, ...), so it
   never fights the surrounding hierarchy, but underlined so it doesn't look identical to unclickable text. */
.person-link { text-decoration: underline; text-decoration-color: var(--line-strong); text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
.person-link:hover, .person-link:focus-visible { text-decoration-color: currentColor; }
/* A tagged "@Name" in a post — unlike person-link above, this one is meant to stand out from the sentence
   around it at a glance, the way a mention does on any other social app, so it gets the brand red instead
   of just an underline. */
.mention-link { color: var(--red); font-weight: 800; text-decoration: none; }
.mention-link:hover, .mention-link:focus-visible { text-decoration: underline; }
.chip-tag { background: var(--red-tint); border-color: transparent; color: var(--red-700); font-weight: 800; }
.offline-banner { position: fixed; bottom: calc(var(--bottom-h) + 10px); left: 50%; transform: translateX(-50%); z-index: 50; background: var(--ink); color: #fff; font-weight: 700; padding: 8px 14px; border-radius: 999px; font-size: .88rem; box-shadow: 0 8px 20px rgba(16, 18, 24, .25); }
#wp-progress { position: fixed; top: 0; left: 0; height: 3px; width: 0%; background: var(--red); z-index: 250; pointer-events: none; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; } }
@media (max-width: 560px) {
  .demo-bar { flex-wrap: nowrap; gap: 8px; padding: 6px 12px; }
  .demo-bar .seg button { padding: 6px 10px; min-height: 32px; font-size: .82rem; }
}

/* ------------------------------------------------------------------ no zoom (owner's choice)
   Pinch and double-tap zoom are off; every form field is at least 16px so iPhones never zoom in on focus. */
html, body { touch-action: pan-x pan-y; }
input, select, textarea, .input, .select, .textarea, .pos-select { font-size: max(16px, 1em); }

/* ------------------------------------------------------------------ landing page ("coming soon") */
.lp { background: radial-gradient(1000px 420px at 85% -120px, rgba(var(--red-rgb), .10), transparent 60%), var(--bg); }
.lp-top { position: sticky; top: 0; z-index: 40; display: flex; align-items: center; gap: 10px; padding: 10px var(--gutter); background: rgba(255, 255, 255, .9); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.lp-top::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: var(--red); }
.lp-hero { max-width: 1240px; margin: 0 auto; padding: 36px var(--gutter) 20px; display: grid; gap: 34px; align-items: center; }
.lp-soon { display: inline-flex; align-items: center; gap: 10px; padding: 8px 16px; border-radius: 999px; background: var(--red); color: #fff; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; font-size: .8rem; box-shadow: 0 8px 22px var(--red-glow); }
.lp-soon-dark { background: rgba(255, 255, 255, .1); box-shadow: none; }
.lp-pulse { width: 9px; height: 9px; border-radius: 50%; background: #fff; animation: lp-pulse 1.6s ease-out infinite; }
@keyframes lp-pulse { 0% { box-shadow: 0 0 0 0 rgba(255, 255, 255, .8); } 100% { box-shadow: 0 0 0 12px rgba(255, 255, 255, 0); } }
.lp-title { margin-top: 18px; font-size: clamp(3.2rem, 13vw, 6.4rem); font-weight: 900; line-height: .86; letter-spacing: -.01em; }
.lp-title span { display: block; color: var(--red); }
.lp-slogan { margin-top: 14px; font-family: var(--font-display); font-weight: 800; font-size: clamp(1.6rem, 5vw, 2.3rem); text-transform: uppercase; }
.lp-intro { margin-top: 12px; max-width: 560px; font-size: 1.08rem; color: var(--text-2); }

/* dark stage with the devices — the one place with depth */
.lp-stage { position: relative; min-height: 400px; border-radius: 30px; overflow: hidden; box-shadow: var(--shadow-dark);
  background: radial-gradient(360px 200px at 12% 6%, rgba(255, 70, 55, .5), transparent 70%), radial-gradient(360px 200px at 92% 8%, rgba(255, 70, 55, .4), transparent 70%),
    linear-gradient(180deg, #121318 0%, #17181C 55%, #10301C 56%, #0C2415 100%); }
.lp-lights { position: absolute; top: 18px; left: 18px; display: grid; grid-template-columns: repeat(5, 12px); gap: 6px; filter: drop-shadow(0 0 16px rgba(255, 90, 70, .9)); }
.lp-lights i { width: 12px; height: 12px; border-radius: 50%; background: #FFE3DC; }
.lp-stage-logo { position: absolute; right: 16px; top: 14px; width: 120px; filter: drop-shadow(0 8px 20px rgba(var(--red-rgb), .45)); }
.lp-tablet { position: absolute; right: -40px; top: 90px; width: 78%; padding: 10px; border-radius: 22px; background: linear-gradient(145deg, #2c2e34, #0c0d10); box-shadow: 0 30px 60px rgba(0, 0, 0, .6); transform: rotate(-2deg); }
.lp-tablet img { width: 100%; height: auto; border-radius: 13px; display: block; }
.lp-phone { position: absolute; left: 18px; top: 70px; width: 38%; max-width: 230px; padding: 8px; border-radius: 34px; background: linear-gradient(145deg, #34363c, #0b0c0e); box-shadow: 0 30px 60px rgba(0, 0, 0, .7), 0 0 40px rgba(var(--red-rgb), .25); transform: rotate(-5deg); z-index: 2; }
.lp-phone img { width: 100%; height: auto; border-radius: 27px; display: block; }
.lp-notch { position: absolute; top: 7px; left: 50%; transform: translateX(-50%); width: 36%; height: 16px; border-radius: 10px; background: #0b0c0e; z-index: 2; }
.lp-stamp { position: absolute; right: 18px; bottom: 22px; z-index: 3; padding: 12px 22px; border-radius: 14px; background: var(--red); color: #fff; font-family: var(--font-display); font-weight: 900; font-size: clamp(1.5rem, 5vw, 2.2rem); letter-spacing: .04em; text-transform: uppercase; transform: rotate(-6deg); border: 3px solid #fff; box-shadow: 0 16px 36px rgba(var(--red-rgb), .55); }

.lp-section { max-width: 1240px; margin: 0 auto; padding: 34px var(--gutter); }
.lp-h2 { font-size: clamp(1.8rem, 5vw, 2.6rem); margin-bottom: 20px; }
.lp-features { display: grid; gap: 14px; grid-template-columns: 1fr; }
.lp-feature { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 20px; box-shadow: var(--shadow); }
.lp-feature h3 { margin-top: 14px; font-size: 1.25rem; }
.lp-feature p { margin-top: 6px; color: var(--text-2); }
.lp-ring { width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center; background: var(--ink); color: #fff; border: 4px solid var(--red); box-shadow: 0 0 22px rgba(var(--red-rgb), .35); }
.lp-duo { display: grid; gap: 16px; grid-template-columns: 1fr; }
.lp-list { list-style: none; padding: 0; margin: 14px 0 0; display: flex; flex-direction: column; gap: 10px; }
.lp-list li { display: flex; gap: 10px; align-items: flex-start; font-weight: 600; }
.lp-list .icon-sm { color: var(--green); margin-top: 3px; }
.lp-access { display: grid; gap: 20px; align-items: center; padding: 28px; border-radius: 26px; color: #fff; background: radial-gradient(420px 200px at 100% 0, rgba(var(--red-rgb), .35), transparent 65%), linear-gradient(160deg, var(--ink-2), var(--ink)); box-shadow: var(--shadow-dark); }
.lp-access h2 { color: #fff; font-size: clamp(1.6rem, 5vw, 2.2rem); }
.lp-code { display: grid; grid-template-columns: 1fr auto; gap: 10px; }
.lp-code .input { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .2); color: #fff; }
.lp-code .input::placeholder { color: rgba(255, 255, 255, .55); }
.lp-footer { display: flex; align-items: center; justify-content: center; gap: 12px; flex-wrap: wrap; padding: 28px var(--gutter) 40px; color: var(--muted); font-weight: 600; font-size: .9rem; }
@media (min-width: 768px) {
  .lp-features { grid-template-columns: repeat(3, 1fr); }
  .lp-duo { grid-template-columns: 1fr 1fr; }
  .lp-access { grid-template-columns: 1.2fr 1fr; padding: 36px; }
  .lp-stage { min-height: 460px; }
}
@media (min-width: 1100px) {
  .lp-hero { grid-template-columns: 1fr 1.05fr; padding-top: 56px; }
  .lp-features { grid-template-columns: repeat(5, 1fr); }
  .lp-stage { min-height: 520px; }
}
@media (max-width: 560px) { .lp-code { grid-template-columns: 1fr; } .lp-stage { min-height: 360px; } .lp-tablet { top: 110px; } }
@media (max-width: 560px) {
  .lp-brand-name { display: none; }
  .lp-stage-logo { width: 78px; right: 12px; top: 10px; }
  .lp-top .btn-sm { padding: 6px 12px; }
}

/* player profile header actions: full-width row on phones, compact row on larger screens */
.player-actions { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); }
@media (min-width: 768px) { .player-actions { display: flex; justify-content: flex-end; } }

/* ------------------------------------------------------------- player profile hero (photo + name overlay) */
.player-hero { position: relative; height: 300px; background: linear-gradient(160deg, var(--ink-2), var(--ink) 75%); }
/* A real phone photo is usually a tall portrait with the face near the top — centring the crop (the
   default) cuts the head off. Biasing toward the top keeps the face in frame for both a portrait photo
   and the square demo photos, which are already centred so this doesn't move them noticeably. */
.player-hero-img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 15%; display: block; }
.player-hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 40%, rgba(15, 16, 20, .9)); pointer-events: none; }
.player-hero-overlay { position: absolute; left: 18px; right: 18px; bottom: 16px; z-index: 1; }
.player-hero-num { display: block; color: var(--red); font-family: var(--font-display); font-weight: 800; letter-spacing: .04em; font-size: 1rem; }
.player-hero-overlay h1 { color: #fff; font-size: 1.4rem; margin: 2px 0; }
.player-hero-pos { color: rgba(255, 255, 255, .82); font-weight: 700; font-size: .82rem; text-transform: uppercase; letter-spacing: .06em; }
.player-hero-upload { position: absolute; top: 14px; right: 14px; z-index: 2; width: 38px; height: 38px; padding: 0; border-radius: 50%; background: rgba(15, 16, 20, .55); color: #fff; display: grid; place-items: center; cursor: pointer; border: 0; }
.player-hero-upload.player-hero-remove { right: 60px; background: rgba(var(--red-rgb), .75); }

/* Plain text underneath the photo, laid out as a grid — no card, no box, no background of its own. */
.player-meta-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px 8px; }
.player-meta-grid > div { min-width: 0; }
.player-meta-grid .k { display: block; color: var(--muted); font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; margin-bottom: 3px; }
.player-meta-grid .v { display: block; color: var(--text); font-weight: 800; font-size: .95rem; }

/* instant tap feedback: Livewire marks the element that started a request with data-loading */
.btn[data-loading], .rsvp-btn[data-loading], .chip[data-loading], .tab[data-loading], .scale button[data-loading], .stepper button[data-loading] { opacity: .6; cursor: progress; }
.btn[data-loading]::after { content: ""; width: 14px; height: 14px; margin-left: 4px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: wp-spin .7s linear infinite; }
@keyframes wp-spin { to { transform: rotate(360deg); } }

/* Who is online */
.online-dot { width: 10px; height: 10px; border-radius: 50%; background: #C9CBD1; flex: none; display: inline-block; }
.online-dot.is-on { background: #1FA35B; box-shadow: 0 0 0 3px rgba(31, 163, 91, .18); }

/* News feed */
.composer-input { min-height: 50px; }
.post-body { white-space: pre-line; overflow-wrap: anywhere; font-size: 1.02rem; line-height: 1.5; }
.post-actions { display: flex; gap: 4px; border-top: 1px solid var(--line); padding-top: 8px; }
.post-action { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 12px; border-radius: 999px; font-weight: 700; font-size: .9rem; background: transparent; border: 0; color: var(--text-2); }
.post-action.is-on { background: var(--red-tint); color: var(--red); }

.post-count { background: none; border: 0; color: inherit; font: inherit; display: inline-flex; align-items: center; gap: 4px; min-height: 32px; }
.comment { background: var(--surface-2); border-radius: var(--radius-sm); padding: 8px 12px; min-width: 0; }
.comments { border-top: 1px solid var(--line); padding-top: 10px; display: flex; flex-direction: column; gap: 8px; }
.comment-row { align-items: flex-start; gap: 8px; }
.comment { display: inline-block; max-width: 100%; }
.comment-meta { font-size: .75rem; color: var(--muted); padding: 2px 12px 0; }
.comment-input { min-height: 40px; padding: 8px 14px; border-radius: 999px; background: var(--surface-2); border-color: transparent; font-size: .95rem; }
.comment-send { color: var(--red); }
.comment-send:disabled { opacity: .5; }
.comment-actions { display: flex; align-items: center; gap: 14px; font-size: .78rem; font-weight: 700; color: var(--muted); padding: 2px 12px 0; }
.comment-actions button { background: none; border: 0; color: inherit; font: inherit; display: inline-flex; align-items: center; gap: 4px; min-height: 28px; }
.comment-actions button.is-on { color: var(--red); }
.comment-actions button.comment-like-count { padding: 0 9px; border-radius: 999px; background: var(--red-tint); color: var(--red); min-height: 26px; margin-left: -6px; }
.replies { margin-left: 44px; display: flex; flex-direction: column; gap: 8px; }

/* News feed: media */
.post-media-grid { display: grid; gap: 4px; border-radius: var(--radius-sm); overflow: hidden; }
.post-media-grid-1 { grid-template-columns: 1fr; }
.post-media-grid-1 .post-media-item { aspect-ratio: 4 / 3; }
.post-media-grid-2 .post-media-item, .post-media-grid-3 .post-media-item, .post-media-grid-4 .post-media-item { aspect-ratio: 1 / 1; }
.post-media-grid-2, .post-media-grid-3, .post-media-grid-4 { grid-template-columns: repeat(2, 1fr); }
.post-media-item { position: relative; display: block; padding: 0; margin: 0; border: 0; background: var(--surface-2); cursor: zoom-in; }
.post-media-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.post-media-lightbox { position: fixed; inset: 0; z-index: 90; background: rgba(10, 11, 14, .92); display: flex; align-items: center; justify-content: center; }
.post-media-lightbox-inner { max-width: 94vw; max-height: 88vh; display: flex; flex-direction: column; align-items: center; gap: 12px; }
.post-media-lightbox-inner img { max-width: 94vw; max-height: 78vh; object-fit: contain; border-radius: var(--radius-sm); }
.post-media-lightbox-bar { display: flex; align-items: center; gap: 10px; }
.post-media-lightbox-bar .icon-btn { color: #fff; }
.post-video { border-radius: var(--radius-sm); overflow: hidden; }
.post-video-wrap { position: relative; }
.post-video video { width: 100%; max-height: 70vh; background: #000; display: block; border-radius: var(--radius-sm); object-fit: contain; }
.post-video-spinner { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; pointer-events: none; }

/* On phones, a post's photos/video bleed edge-to-edge past the card's own 20px padding instead of
   sitting inset with rounded corners — full-width like the reference feed apps this club knows. Cropping
   to fill (object-fit: cover) only makes sense at that same edge-to-edge width: on desktop, inside the
   card's own padding, the whole frame stays visible (object-fit: contain, same capped height either way). */
@media (max-width: 560px) {
  .post-media-grid, .post-video { margin-left: -20px; margin-right: -20px; border-radius: 0; }
  .post-video-wrap, .post-video video { border-radius: 0; object-fit: cover; }
}
.spinner { width: 36px; height: 36px; border-radius: 50%; border: 3px solid rgba(255, 255, 255, .35); border-top-color: #fff; animation: wp-spin .8s linear infinite; }

/* Composer: selected photos/video before posting */
.composer-media-row { display: flex; gap: 8px; flex-wrap: wrap; }
.upload-progress { background: var(--surface-2); border-radius: var(--radius-sm); padding: 10px 12px; }
.media-picks { display: flex; gap: 8px; overflow-x: auto; padding: 2px; }
.media-pick { position: relative; flex: none; width: 84px; height: 84px; border-radius: var(--radius-sm); overflow: hidden; background: var(--surface-2); }
.media-pick img, .media-pick video { width: 100%; height: 100%; object-fit: cover; }
.media-pick-video { width: 140px; }
.media-pick-remove { position: absolute; top: 4px; right: 4px; width: 24px; height: 24px; border-radius: 50%; background: rgba(16, 18, 24, .65); color: #fff; border: 0; display: grid; place-items: center; }
.media-pick-progress { position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: rgba(255, 255, 255, .35); }
.media-pick-progress span { display: block; height: 100%; background: var(--red); transition: width .2s; }
.icon-btn:disabled { opacity: .4; }

/* All :hover styling lives here, gated to devices that can actually hover (a mouse/trackpad). On a touchscreen
   without this guard, iOS Safari treats a hover-styled element as needing a first tap just to "focus" it (to
   preview the hover state) and only a second tap to actually activate it — links and buttons across the app
   would need two taps instead of one. Every rule that also carries a non-hover state (an open dropdown, an
   active toggle) stays unconditional above; only the pure hover effect moves here. */
@media (hover: hover) {
    .icon-btn:hover { background: var(--surface-2); }
    .lang-btn:hover { border-color: var(--red); }
    .menu-item:hover { background: var(--surface-2); }
    .seg button:not(.is-active):hover, .seg a:not(.is-active):hover { background: rgba(255, 255, 255, .7); color: var(--text); }
    .nav-link:hover { background: var(--surface); color: var(--text); }
    .back-link:hover { color: var(--red); }
    a.card:hover, a.card-lift:hover { box-shadow: var(--shadow-lift); border-color: var(--line-strong); }
    .card-link:hover { text-decoration: underline; }
    .btn-primary:hover { background: var(--red-600); }
    .btn-secondary:hover { border-color: var(--red); color: var(--red-700); }
    .btn-ghost:hover { background: var(--surface-2); color: var(--text); }
    .btn-danger:hover { background: var(--red-tint); }
    .list-item.is-link:hover .list-title { color: var(--red-700); }
    .chip:hover:not(.is-active) { border-color: var(--red); color: var(--text); }
    .table tbody tr:hover { background: var(--red-tint); }
    .link:hover { text-decoration: underline; }
    .post-action:hover { background: var(--red-tint); color: var(--red); }
    .post-count:not(:disabled):hover { color: var(--red); }
    .comment-actions button:hover { text-decoration: underline; }
}

/* ------------------------------------------------------------------ first-login welcome animation */
.welcome-intro {
  position: fixed; inset: 0; z-index: 200; overflow: hidden;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 24px; text-align: center;
  opacity: 1; transform: scale(1);
  transition: opacity .8s ease, transform .8s ease;
}
.welcome-intro.is-leaving { opacity: 0; transform: scale(1.08); }

.welcome-intro-bg {
  position: absolute; inset: 0; z-index: 0;
  background: radial-gradient(120% 90% at 50% 18%, rgba(var(--red-rgb), .22), transparent 60%), linear-gradient(160deg, var(--ink) 0%, var(--ink-2) 55%, #0c0d0f 100%);
  opacity: 0; animation: wi-bg-fade .6s ease-out both;
}

.welcome-intro-content { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; gap: clamp(10px, 3vw, 20px); max-width: min(92vw, 560px); }

.welcome-intro-logo { width: min(46vw, 200px); height: auto; opacity: 0; filter: drop-shadow(0 18px 40px rgba(0, 0, 0, .5)); animation: wi-logo-pop .9s cubic-bezier(.34, 1.56, .64, 1) .15s both; }

.welcome-intro-text { position: relative; z-index: 1; opacity: 0; animation: wi-text-up .8s ease-out .55s both; }
.welcome-intro-eyebrow { margin: 0; font-family: var(--font); font-weight: 800; font-size: clamp(.74rem, 2.6vw, .92rem); letter-spacing: .22em; text-transform: uppercase; color: var(--red); }
.welcome-intro-title { margin: 6px 0 0; font-family: var(--font-display); font-weight: 800; text-transform: uppercase; letter-spacing: .01em; line-height: 1.05; font-size: clamp(1.6rem, 7vw, 2.6rem); color: #fff; }
.welcome-intro-rule { display: block; width: 120px; max-width: 40vw; height: 4px; margin: 14px auto 0; border-radius: 3px; background: var(--red); transform-origin: center; transform: scaleX(0); animation: wi-rule-grow .5s ease-out 1.05s both; }

.welcome-intro-confetti { position: absolute; inset: 0; z-index: 2; overflow: hidden; pointer-events: none; }
.wi-confetti-piece {
  position: absolute; top: -12%; border-radius: 2px; opacity: .95;
  animation-name: wi-fall; animation-timing-function: cubic-bezier(.4, 0, .6, 1); animation-iteration-count: infinite; animation-fill-mode: both;
}

@keyframes wi-bg-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes wi-logo-pop { 0% { opacity: 0; transform: scale(.4); } 55% { opacity: 1; transform: scale(1.08); } 75% { transform: scale(.97); } 100% { opacity: 1; transform: scale(1); } }
@keyframes wi-text-up { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: translateY(0); } }
@keyframes wi-rule-grow { to { transform: scaleX(1); } }
@keyframes wi-fall { 0% { transform: translateY(-10vh) translateX(0) rotate(0deg); } 100% { transform: translateY(115vh) translateX(var(--wi-drift, 0)) rotate(var(--wi-spin, 180deg)); } }

/* ------------------------------------------------------------------ live stream (YouTube embed) */
.yt-embed { position: relative; aspect-ratio: 16 / 9; border-radius: var(--radius-sm); overflow: hidden; background: #000; }
.yt-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* Filter chips that stay on one line and scroll sideways on phones (edge to edge, fading at the right). */
@media (max-width: 767px) {
  .chips-scroll { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; width: calc(100% + 2 * var(--gutter)); margin: 0 calc(-1 * var(--gutter)); padding: 2px var(--gutter) 8px; -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); }
  .chips-scroll::-webkit-scrollbar { display: none; }
  .chips-scroll .chip { flex-shrink: 0; white-space: nowrap; }
}

/* Lineup builder — Save bar pinned above the bottom nav on phones/tablets */
.lu-savebar { display: none; }
@media (max-width: 1099px) {
  .lu-save-top { display: none !important; }
  .lu-savebar { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; position: sticky; z-index: 30; bottom: calc(var(--bottom-h) + env(safe-area-inset-bottom) + 10px); padding: 10px; background: rgba(255, 255, 255, .96); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-lift); }
  .lu-savebar .btn { width: 100%; min-width: 0; }
  .lu-savebar.is-dirty { border-color: #F3D19B; box-shadow: var(--shadow-lift), 0 0 0 3px rgba(245, 165, 36, .18); }
}

/* Training → Drills */
.seg-count { margin-left: 4px; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--red); color: #fff; font-size: .72rem; font-weight: 800; display: inline-grid; place-items: center; }
.seg .is-active .seg-count { background: #fff; color: var(--red); }
.drill-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 768px) { .drill-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; } }
@media (min-width: 1300px) { .drill-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.drill-card { display: flex; flex-direction: column; min-width: 0; padding: 0; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); overflow: hidden; text-align: left; font: inherit; color: inherit; -webkit-tap-highlight-color: transparent; transition: transform .12s ease, box-shadow .15s ease; }
.drill-card:active { transform: scale(.98); }
.drill-thumb { position: relative; display: block; aspect-ratio: 4 / 5; background: var(--ink); overflow: hidden; }
.drill-thumb img { width: 100%; height: 100%; object-fit: cover; }
.drill-thumb-empty { position: absolute; inset: 0; display: grid; place-items: center; color: rgba(255, 255, 255, .35); background: radial-gradient(120% 90% at 50% 0%, #2B2D34, var(--ink)); }
.drill-thumb-empty .icon { width: 40px; height: 40px; }
.drill-play { position: absolute; left: 50%; top: 50%; width: 48px; height: 48px; margin: -24px 0 0 -24px; border-radius: 50%; display: grid; place-items: center; background: rgba(var(--red-rgb), .92); color: #fff; box-shadow: 0 6px 18px rgba(0, 0, 0, .3); }
.drill-play .icon { width: 20px; height: 20px; margin-left: 3px; fill: currentColor; }
.drill-src, .drill-dur { position: absolute; font-size: .66rem; font-weight: 800; letter-spacing: .03em; padding: 3px 7px; border-radius: 999px; color: #fff; background: rgba(0, 0, 0, .62); }
.drill-src { left: 8px; top: 8px; }
.drill-dur { right: 8px; bottom: 8px; font-variant-numeric: tabular-nums; }
.drill-body { display: flex; flex-direction: column; gap: 3px; padding: 10px 12px 12px; min-width: 0; }
.drill-cat { font-size: .66rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--red); }
.drill-title { font-weight: 700; font-size: .92rem; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.drill-done { display: inline-flex; align-items: center; gap: 4px; font-size: .74rem; font-weight: 700; color: var(--green-ink); margin-top: 2px; }
.drill-done .icon { width: 14px; height: 14px; }
.drill-player { position: relative; width: 100%; aspect-ratio: 16 / 9; border-radius: var(--radius-sm); overflow: hidden; background: #000; }
.drill-player.is-vertical { aspect-ratio: 9 / 16; width: min(100%, calc(72vh * 9 / 16)); margin: 0 auto; }
.drill-player iframe, .drill-player video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: #000; }
.drill-player video { object-fit: contain; }
.hw-thumb { position: relative; flex: none; width: 56px; height: 56px; border-radius: 12px; overflow: hidden; background: var(--ink); color: rgba(255, 255, 255, .5); display: grid; place-items: center; border: 0; padding: 0; }
.hw-thumb img { width: 100%; height: 100%; object-fit: cover; }
.hw-thumb-play { position: absolute; inset: 0; display: grid; place-items: center; color: #fff; background: rgba(0, 0, 0, .25); }
.hw-thumb-play .icon { width: 18px; height: 18px; fill: currentColor; }
.hw-item { text-align: left; width: 100%; border-left: 0; border-right: 0; border-bottom: 0; background: none; font: inherit; color: inherit; }
.drill-upload { display: flex; align-items: center; gap: 12px; padding: 10px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); }
.drill-upload video { width: 64px; height: 64px; object-fit: cover; border-radius: 10px; background: #000; flex: none; }

/* Indeterminate loading bar (a red stripe sliding across) + the "posting…" lock over the drill form */
.load-bar { position: relative; height: 6px; border-radius: 3px; background: var(--red-soft); overflow: hidden; }
.load-bar-sm { height: 4px; }
.load-bar > span { position: absolute; top: 0; bottom: 0; left: -40%; width: 40%; border-radius: 3px; background: linear-gradient(90deg, var(--red-600), var(--red-light)); animation: wp-load 1.1s ease-in-out infinite; }
@keyframes wp-load { 0% { left: -40%; } 100% { left: 100%; } }
@media (prefers-reduced-motion: reduce) { .load-bar > span { animation-duration: 2.5s; } }
.drill-saving { position: absolute; inset: -4px; z-index: 5; flex-direction: column; align-items: center; justify-content: flex-start; padding: 56px 16px 0; background: rgba(255, 255, 255, .72); border-radius: 12px; }
.drill-saving-box { width: min(300px, 100%); display: flex; flex-direction: column; gap: 12px; padding: 18px 18px 20px; text-align: center; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-lift); }
.mb-2 { margin-bottom: 8px; }
.views-count { display: inline-flex; align-items: center; gap: 4px; font-size: .74rem; font-weight: 700; color: var(--muted); font-variant-numeric: tabular-nums; margin-top: 2px; }
.views-count .icon { width: 14px; height: 14px; }
.views-count.is-liked { color: var(--red); }

/* Training → Rules & basics */
.lesson-num { flex: none; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-3); color: var(--text-2); font-family: var(--font-display); font-weight: 800; font-size: 1.05rem; }
.lesson-num.is-done { background: #EAF8EF; font-size: 1.1rem; }
.lesson-image { width: 100%; border-radius: var(--radius-sm); border: 1px solid var(--line); }
.lesson-video-cover { position: absolute; inset: 0; width: 100%; height: 100%; padding: 0; border: 0; background: radial-gradient(120% 90% at 50% 0%, #2B2D34, var(--ink)); cursor: pointer; }
.lesson-video-cover img { width: 100%; height: 100%; object-fit: cover; }
.lesson-body { font-size: 1.02rem; line-height: 1.6; }
.lesson-body p { margin: 0; }
.lesson-body p + p { margin-top: 12px; }
.quiz-q { border: 0; margin: 0; padding: 0; }
.quiz-q legend { padding: 0; font-size: 1rem; line-height: 1.35; }
.quiz-option { display: flex; align-items: center; gap: 12px; min-height: 50px; padding: 10px 14px; border: 1.5px solid var(--line-strong); border-radius: 14px; background: var(--surface); cursor: pointer; font-weight: 600; line-height: 1.3; transition: border-color .12s ease, background .12s ease; }
.quiz-option input { width: 20px; height: 20px; flex: none; accent-color: var(--red); }
.quiz-option:has(input:checked) { border-color: var(--red); background: var(--red-tint); }
.quiz-option.is-right { border-color: var(--green); background: #EAF8EF; color: var(--green-ink); }
.quiz-option.is-wrong { border-color: var(--red); background: var(--red-soft); color: var(--red-700); }
.quiz-option .icon-sm { flex: none; }
.quiz-why { padding: 8px 12px; border-radius: 10px; background: var(--surface-2); color: var(--text-2); }
.quiz-score { padding: 14px 16px; border-radius: var(--radius-sm); background: #FFF4DE; color: var(--amber-ink); text-align: center; }
.quiz-score.is-passed { background: #EAF8EF; color: var(--green-ink); }

/* Record payment → which months a multi-month payment covers */
.pay-months-preview { padding: 12px 14px; border-radius: var(--radius-sm); border: 1px solid #C5EBD2; background: #F1FBF4; transition: opacity .15s ease; }
.pay-months-preview.is-stale { opacity: .5; }
.pay-months-preview .badge.is-skipped { text-decoration: line-through; opacity: .75; }

/* Game Day → pitch count card (filled in live, or after the game before "Finish game") */
.pitch-row { align-items: center; }
.pitch-input { width: 76px; min-height: 42px; padding: 8px 10px; text-align: center; }
.pitch-over { color: var(--red-700); }
.pitch-add { display: grid; grid-template-columns: minmax(0, 1fr) 104px; gap: 8px; }
.pitch-add .btn { grid-column: 1 / -1; }
@media (min-width: 768px) { .pitch-add { grid-template-columns: minmax(0, 1fr) 100px auto; } .pitch-add .btn { grid-column: auto; } }

/* Badges: a badge's picture (or a placeholder medal until one is uploaded), and the grid on the player profile */
.badge-medal { position: relative; flex: none; display: inline-grid; place-items: center; border-radius: 50%; }
.badge-medal img { width: 100%; height: 100%; object-fit: contain; }
/* Badge pictures are not for saving: no iPhone press-to-preview zoom (it replayed on every tap) and no tap flash. */
.badge-medal, .badge-tile { -webkit-tap-highlight-color: transparent; -webkit-touch-callout: none; -webkit-user-select: none; user-select: none; }
.badge-medal img { pointer-events: none; -webkit-user-drag: none; }
.badge-medal-empty { width: 100%; height: 100%; border-radius: 50%; display: grid; place-items: center; color: #fff;
  background: radial-gradient(circle at 35% 30%, #FF6A61, var(--red) 55%, var(--red-700)); box-shadow: inset 0 0 0 4px #F5C542, 0 3px 10px rgba(16, 18, 24, .18); }
.badge-medal-empty .icon { width: 42%; height: 42%; }
.badge-medal.is-locked { filter: grayscale(1); opacity: .45; }
.badge-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 16px 10px; }
.badge-tile { display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center; min-width: 0; }
.badge-tile strong { line-height: 1.2; }

/* "You earned a badge!" popup — in front of everything (above the bottom nav and modals) until tapped */
.badge-pop-backdrop { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 20px; background: rgba(12, 13, 16, .78); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); animation: wp-fade .25s ease both; overflow: hidden; }
.badge-pop { position: relative; width: min(360px, 100%); display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; padding: 26px 22px 22px; border-radius: 28px; background: var(--surface); border-top: 5px solid var(--red); box-shadow: 0 30px 80px rgba(0, 0, 0, .45); animation: wp-pop .55s cubic-bezier(.2, 1.4, .4, 1) both; }
.badge-pop h2 { font-size: 1.9rem; line-height: 1.05; }
.badge-pop-text { font-weight: 700; font-size: 1.05rem; }
.badge-pop-medal { margin: 6px 0 4px; animation: wp-medal 1.1s cubic-bezier(.2, 1.2, .4, 1) .15s both; filter: drop-shadow(0 12px 24px rgba(var(--red-rgb), .35)); }
.badge-pop-confetti i { position: absolute; top: -12px; left: calc(var(--i) * 5.6%); width: 9px; height: 14px; border-radius: 2px; background: var(--red); opacity: .9; animation: wp-confetti 2.6s ease-in calc(var(--i) * 60ms) both; }
.badge-pop-confetti i:nth-child(3n) { background: #F5C542; }
.badge-pop-confetti i:nth-child(3n+1) { background: #fff; }
@keyframes wp-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes wp-pop { from { opacity: 0; transform: scale(.7) translateY(20px); } to { opacity: 1; transform: none; } }
@keyframes wp-medal { 0% { transform: scale(.2) rotate(-25deg); opacity: 0; } 60% { transform: scale(1.12) rotate(6deg); opacity: 1; } 100% { transform: none; } }
@keyframes wp-confetti { 0% { transform: translateY(0) rotate(0); } 100% { transform: translateY(110vh) rotate(540deg); opacity: .7; } }
@media (prefers-reduced-motion: reduce) { .badge-pop, .badge-pop-medal, .badge-pop-confetti i { animation: none; } .badge-pop-confetti { display: none; } }

/* Wolf Pack vs Wolf Pack: both teams' halves of the same game framed together in the schedule list. */
.list > .twin-group { margin: 8px 0; padding: 0 12px; border: 1px solid var(--line-strong); border-left: 4px solid var(--red); border-radius: var(--radius-sm); background: var(--red-tint); }
.twin-group > .list-item { border-top: 1px dashed var(--line-strong); }
.twin-group > .list-item:nth-child(2) { border-top: 0; }
.twin-group-head { display: flex; align-items: center; gap: 6px; padding: 8px 0 0; color: var(--red-700); font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; }
.twin-group-head .icon { width: 15px; height: 15px; }
.twin-tag { display: inline-flex; align-items: center; gap: 4px; padding: 1px 8px; border-radius: 999px; background: var(--red-soft); color: var(--red-700); font-size: .7rem; font-weight: 700; }
.twin-tag .icon { width: 13px; height: 13px; }

/* Announcements: the action button beside the title, long messages folded to 4 lines, calm read counter. */
.page-head.is-compact { display: grid; grid-template-columns: 1fr auto; align-items: start; column-gap: 12px; }
.page-head.is-compact > div:first-child { display: contents; }
.page-head.is-compact h1 { grid-column: 1; grid-row: 1; align-self: center; }
.page-head.is-compact .sub { grid-column: 1 / -1; }
.page-head.is-compact > .row { grid-column: 2; grid-row: 1; align-self: center; }
.ann-body { display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.ann-body.is-open { display: block; -webkit-line-clamp: unset; overflow: visible; }
.ann-more { border: 0; background: none; padding: 4px 0 0; color: var(--red); font-weight: 800; font-size: .88rem; cursor: pointer; }
.ann-reads { display: flex; align-items: center; gap: 6px; width: 100%; margin-top: 12px; padding: 0; border: 0; background: none; color: var(--text-2); font-weight: 700; font-size: .86rem; cursor: pointer; text-align: left; min-height: 32px; }
.ann-reads.is-done { color: var(--green-ink); }
.ann-bar { height: 6px; margin-top: 4px; }
.ann-bar > span { background: var(--grey); }
.ann-bar.green > span { background: linear-gradient(90deg, #15A34A, #4ADE80); }


/* Report a problem: the message box takes the free space, so the button sits just above the bottom menu
   instead of floating mid-screen — and the page fits the screen without scrolling. */
.report-page .textarea { min-height: 140px; height: max(140px, calc(100dvh - var(--header-h) - var(--demo-bar-h) - var(--bottom-h) - env(safe-area-inset-bottom) - 360px)); resize: none; }
@media (min-width: 1100px) { .report-page .textarea { height: 220px; resize: vertical; } }

/* The header's avatar/language menu hangs straight from the bottom edge of the top bar (square top corners);
   while it is open the page behind is blurred a little and can't scroll (lockScroll in the layout). */
.topbar .menu { top: calc(50% + var(--header-h) / 2); border-top: 0; border-radius: 0 0 var(--radius) var(--radius); }
.menu-backdrop { position: fixed; inset: 0; z-index: 41; background: rgba(16, 18, 24, .18); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); touch-action: none; }
.topbar .dropdown-left .menu { right: auto; left: 0; }

/* Feed reactions (hold Like to pick one): the emoji bar pops up above the button, the hovered emoji grows and
   shows its name, like Facebook. Long-pressing must not select text or open the iOS callout. */
.react-wrap { position: relative; display: inline-flex; }
.react-trigger { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
.react-emoji { font-size: 1.05rem; line-height: 1; }
.post-action.react-trigger.is-on { background: var(--red-tint); color: var(--red); }
.post-action.react-trigger.react-love, .comment-actions .react-trigger.react-love { color: #E0245E; }
.post-action.react-trigger.react-haha, .post-action.react-trigger.react-wow, .post-action.react-trigger.react-trophy, .comment-actions .react-trigger.react-haha, .comment-actions .react-trigger.react-wow, .comment-actions .react-trigger.react-trophy { color: #B7791F; }
.post-action.react-trigger.react-haha, .post-action.react-trigger.react-wow, .post-action.react-trigger.react-trophy { background: #FEF6E4; }
.post-action.react-trigger.react-love { background: #FDECF1; }
.react-bar { position: absolute; left: -4px; bottom: calc(100% + 8px); z-index: 30; display: flex; gap: 2px; padding: 6px 8px; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; box-shadow: 0 10px 30px rgba(16, 18, 24, .18); }
.react-wrap.is-small .react-bar { left: -10px; }
.react-option { position: relative; display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 50%; background: none; font-size: 1.9rem; line-height: 1; cursor: pointer; transition: transform .12s ease; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
.react-option:hover, .react-option.is-hover { transform: translateY(-6px) scale(1.3); }
.react-option.is-mine::after { content: ""; position: absolute; bottom: -3px; width: 5px; height: 5px; border-radius: 50%; background: var(--red); }
.react-label { position: absolute; bottom: calc(100% + 4px); left: 50%; transform: translateX(-50%); padding: 2px 8px; border-radius: 999px; background: rgba(16, 18, 24, .85); color: #fff; font-size: .62rem; font-weight: 700; white-space: nowrap; opacity: 0; pointer-events: none; transition: opacity .12s ease; }
.react-option:hover .react-label, .react-option.is-hover .react-label { opacity: 1; }
@media (hover: none) { .react-option:hover { transform: none; } .react-option:hover .react-label { opacity: 0; } .react-option.is-hover { transform: translateY(-6px) scale(1.3); } .react-option.is-hover .react-label { opacity: 1; } }
.react-stack { display: inline-flex; margin-right: 2px; }
.react-stack > span { display: grid; place-items: center; width: 20px; height: 20px; margin-left: -5px; border-radius: 50%; background: var(--surface); box-shadow: 0 0 0 2px var(--surface); font-size: .82rem; line-height: 1; }
.react-stack > span:first-child { margin-left: 0; }
.react-stack.is-small > span { width: 16px; height: 16px; font-size: .7rem; margin-left: -4px; }
.react-stack.is-small > span:first-child { margin-left: 0; }
.react-tabs { margin-bottom: 8px; }
.react-avatar { position: relative; display: inline-flex; flex: none; }
.react-avatar-emoji { position: absolute; right: -4px; bottom: -4px; display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; background: var(--surface); box-shadow: 0 1px 3px rgba(16, 18, 24, .25); font-size: .72rem; line-height: 1; }
.post-action { white-space: nowrap; }
.comment-actions { flex-wrap: wrap; column-gap: 12px; row-gap: 0; }
.comment-actions > span { white-space: nowrap; }
.comment-actions .react-bar .react-option { font-size: 1.9rem; line-height: 1; min-height: 0; width: 44px; height: 44px; padding: 0; color: inherit; }
.comment-actions .react-bar .react-label { font-size: .62rem; }
/* Reaction pictures (public/images/reactions): never draggable or long-pressable themselves — the press belongs to the button. */
.react-img { display: block; width: 100%; height: 100%; object-fit: contain; pointer-events: none; -webkit-user-drag: none; -webkit-touch-callout: none; user-select: none; }
.react-option .react-img { width: 40px; height: 40px; }
.comment-actions .react-bar .react-option .react-img { width: 40px; height: 40px; }
.react-img.react-img-btn { display: inline-block; width: 22px; height: 22px; vertical-align: -6px; }
.comment-actions .react-img.react-img-btn { width: 18px; height: 18px; vertical-align: -4px; }
.react-stack > span { background: transparent; box-shadow: none; }
.react-stack > span .react-img { width: 20px; height: 20px; }
.react-stack.is-small > span .react-img { width: 16px; height: 16px; }
.react-avatar-emoji .react-img { width: 16px; height: 16px; }
/* The reaction bar's pictures move: the 8-frame strip plays once each time the bar opens (steps = one frame each),
   then rests on frame 1 — the same picture as the stills. Still for anyone who asked their phone for less motion. */
.react-anim { --s: 40px; display: block; width: var(--s); height: var(--s); background-repeat: no-repeat; background-size: calc(var(--s) * 8) var(--s); background-position: 0 0; animation: react-play 1s steps(8) 1; pointer-events: none; }
@keyframes react-play { to { background-position: calc(var(--s) * -8) 0; } }
@media (prefers-reduced-motion: reduce) { .react-anim { animation: none; } }
.badge-link { text-decoration: none; cursor: pointer; } .badge-link:hover { filter: brightness(.96); text-decoration: underline; }

/* Contributions → How to pay: the club's bank accounts, each with a copy button for the banking app. */
.bank-list { display: grid; gap: 8px; }
.bank-item { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); }
.bank-name { font-weight: 800; }
.bank-number { font-size: 1.05rem; font-weight: 700; letter-spacing: .02em; overflow-wrap: anywhere; }
.bank-reference { background: var(--surface); border-style: dashed; }
.bank-ref-text { font-weight: 700; overflow-wrap: anywhere; }
.bank-item .btn { flex: none; }

/* A payment whose receipt the club still has to check (amber), or didn't accept (red) — on the card and in the totals. */
.proof-status { display: flex; align-items: flex-start; gap: 6px; margin-bottom: 0; padding: 8px 10px; border-radius: var(--radius-sm); font-size: .84rem; font-weight: 600; line-height: 1.35; }
.proof-status .icon { flex: none; width: 16px; height: 16px; margin-top: 1px; }
.proof-status.is-waiting { background: #FFF4DE; color: var(--amber-ink); }
.proof-status.is-rejected { background: var(--red-soft); color: var(--red-700); }
.proof-status .link { color: inherit; text-decoration: underline; }

/* The Platform (super admin): a plain frame above every club. */
.platform-top { position: sticky; top: 0; z-index: 42; display: flex; align-items: center; gap: 14px; padding: 12px var(--gutter); background: var(--ink); color: #fff; }
.platform-brand { display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-display); text-transform: uppercase; letter-spacing: .06em; }
.platform-nav { display: flex; gap: 4px; flex: 1; overflow-x: auto; }
.platform-nav a { padding: 6px 10px; border-radius: 999px; color: rgba(255, 255, 255, .75); font-weight: 700; font-size: .88rem; white-space: nowrap; }
.platform-nav a.is-active { background: rgba(255, 255, 255, .14); color: #fff; }
.platform-top .btn-ghost { color: #fff; }
.platform-main { max-width: 900px; margin: 0 auto; padding: 22px var(--gutter) 48px; }
.platform-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.platform-stats > div { padding: 10px; border-radius: var(--radius-sm); background: var(--surface-2); font-size: .78rem; color: var(--muted); font-weight: 700; }
.platform-stats span { display: block; font-size: 1.3rem; color: var(--text); font-weight: 800; }
/* Inside a club as super admin ("Help this club"): impossible to miss, with a way out. */
.help-bar { display: flex; align-items: center; gap: 10px; padding: 8px var(--gutter); background: #B91C1C; color: #fff; font-weight: 700; font-size: .88rem; }
.help-bar-stop { background: #fff; color: #B91C1C; border: 0; }

/* Player card for scouts (cards/partials/card-body): the scout's page and the parent's preview. */
.pcard-head { display: flex; gap: 14px; align-items: center; }
.pcard-photo { width: 84px; height: 84px; border-radius: 50%; object-fit: cover; flex: none; box-shadow: 0 0 0 3px var(--surface), 0 0 0 5px var(--red); }
.pcard-photo-empty { display: grid; place-items: center; background: var(--surface-3); color: var(--muted); }
.pcard-name { text-transform: none; font-family: var(--font); font-weight: 800; font-size: 1.35rem; }
.pcard-meta { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.pcard-meta span { padding: 2px 10px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--line); font-size: .8rem; font-weight: 700; color: var(--text-2); }
.pcard-bio { margin-top: 12px; color: var(--text-2); white-space: pre-line; }
.pcard-h { margin: 18px 0 8px; font-size: 1rem; }
.pcard-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.pcard-stats > div { padding: 10px; border-radius: var(--radius-sm); background: var(--surface-2); font-size: .75rem; color: var(--muted); font-weight: 700; text-transform: uppercase; }
.pcard-stats span { display: block; font-size: 1.3rem; color: var(--text); font-family: var(--font-display); }
.pcard-skill { display: flex; align-items: center; gap: 10px; padding: 6px 0; border-top: 1px solid var(--line); font-weight: 600; }
.pcard-skill:first-child { border-top: 0; }
.pcard-dots { display: inline-flex; gap: 4px; }
.pcard-dots i { width: 10px; height: 10px; border-radius: 50%; background: var(--surface-3); }
.pcard-dots i.on { background: var(--red); }
.pcard-badges { display: flex; flex-wrap: wrap; gap: 8px; }
.pcard-badges img { width: 48px; height: 48px; object-fit: contain; }
.pcard-videos { display: grid; gap: 8px; }
.pcard-video { position: relative; width: 100%; aspect-ratio: 16 / 9; border-radius: var(--radius-sm); overflow: hidden; background: #000; }
.pcard-video.is-vertical { aspect-ratio: 9 / 16; max-width: 320px; }
.pcard-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.card-parts { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 6px 12px; }
.card-part { display: flex; align-items: center; gap: 8px; font-weight: 600; min-height: 36px; }
.card-page { background: var(--bg); }
.card-page-top { display: flex; align-items: center; gap: 10px; padding: 10px var(--gutter); background: var(--surface); border-bottom: 1px solid var(--line); }
.card-page-top strong { flex: 1; font-family: var(--font-display); text-transform: uppercase; }
.card-page-lang .select { width: auto; min-height: 36px; padding-top: 4px; padding-bottom: 4px; }
.card-page-main { max-width: 640px; margin: 0 auto; padding: 18px var(--gutter) 40px; display: grid; gap: 14px; }
.card-page-logo { height: 40px; width: auto; flex: none; }
.card-page-main > * { min-width: 0; }
.card-page-top strong { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .9rem; }
.pcard-dots i { display: inline-block; flex: none; }
.pcard-meta span { max-width: 100%; overflow-wrap: anywhere; }

/* An adult's profile (/people/{user}). */
.person-head { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.person-name { font-size: 1.6rem; }
.person-stat { display: block; padding: 10px; border-radius: var(--radius-sm); background: var(--surface-2); font-size: .78rem; color: var(--muted); font-weight: 700; }
.person-stat span { display: block; font-size: 1.2rem; color: var(--text); font-weight: 800; }

/* The scout directory (/scouts/{token}). */
.scout-filters { display: grid; gap: 8px; }
.scout-filter-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 8px; }
.scout-row { display: flex; align-items: center; gap: 12px; color: inherit; text-decoration: none; padding: 12px 14px; }
.scout-photo { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; flex: none; }
.scout-more > summary { list-style: none; display: inline-flex; cursor: pointer; } .scout-more > summary::-webkit-details-marker { display: none; }

.masked { cursor: pointer; border-radius: 6px; }
.masked:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }

.push-ask-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 0 16px 14px 72px; }

.month-head { border: 0; background: none; padding: 0; font: inherit; font-family: var(--font-display, inherit); font-weight: 800; font-size: 1.05rem; text-transform: uppercase; color: var(--text); cursor: pointer; }
.text-red { color: var(--red); font-weight: 700; }

.post-link { color: var(--red); text-decoration: underline; word-break: break-all; }

/* "Type this number to confirm" (x-confirm-code): centred, the number as tiles, a big input that turns green on a match. */
.confirm-code { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 18px 12px; margin: 4px 0; background: var(--surface-2, #f6f7f9); border-radius: 18px; text-align: center; }
.confirm-code-label { font-weight: 700; font-size: .95rem; color: var(--text-2, #555); }
.confirm-code-digits { display: flex; gap: 10px; justify-content: center; }
.confirm-code-digits span { width: 52px; height: 62px; display: grid; place-items: center; border-radius: 14px; background: var(--card, #fff); box-shadow: var(--shadow); font-family: var(--font-display, inherit); font-size: 2rem; font-weight: 800; color: var(--red); }
.confirm-code-input { width: 100%; max-width: 236px; height: 60px; text-align: center; font-size: 1.8rem; font-weight: 800; letter-spacing: .5em; padding-left: .5em; border-width: 2px; }
.confirm-code-input.is-match { border-color: var(--green-ink, #2e7d32); background: var(--green-tint, #eaf6ec); color: var(--green-ink, #2e7d32); }
.confirm-code .error { margin: 0; }

/* Online now: the green dot sends out a soft ring, like a live signal. */
.online-dot.is-on { position: relative; }
.online-dot.is-on::after { content: ""; position: absolute; inset: 0; border-radius: 50%; background: #1FA35B; animation: online-ping 2s cubic-bezier(0, 0, .2, 1) infinite; }
@keyframes online-ping { 0% { transform: scale(1); opacity: .55; } 75%, 100% { transform: scale(2.6); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .online-dot.is-on::after { animation: none; display: none; } }

/* Windows slide up with a soft spring (desktop: a gentle zoom); the More sheet too. */
.modal-backdrop .modal, .sheet { animation: sheet-up .45s cubic-bezier(.22, 1.25, .36, 1) both; }
@keyframes sheet-up { from { transform: translateY(48px); opacity: .3; } to { transform: none; opacity: 1; } }
@media (min-width: 768px) { .modal-backdrop .modal { animation-name: modal-zoom; } @keyframes modal-zoom { from { transform: scale(.92); opacity: 0; } to { transform: none; opacity: 1; } } }
/* Toasts spring in from the side. */
.toast { animation: toast-in .5s cubic-bezier(.22, 1.3, .36, 1) both; }
@keyframes toast-in { from { transform: translateX(40px) scale(.95); opacity: 0; } to { transform: none; opacity: 1; } }
/* Bottom navigation: a real sliding line (motion.js) replaces the static one. */
.bottom-nav.has-ind .is-active::before { display: none; }
.nav-ind { position: absolute; top: 0; left: 0; width: 28px; height: 3px; border-radius: 0 0 3px 3px; background: var(--red); pointer-events: none; }
/* Forms ring on the parent's Forms tile. */
.ring-wrap { position: relative; }
.docs-ring { position: absolute; inset: -3px; width: calc(100% + 6px); height: calc(100% + 6px); transform: rotate(-90deg); }
.docs-ring circle { fill: none; stroke-width: 3.2; }
.ring-bg { stroke: rgba(0, 0, 0, .08); }
.ring-fg { stroke: var(--green-ink, #2e7d32); stroke-linecap: round; }
/* Speedometer needle turns around its base. */
.speedo { display: inline-flex; }
.speedo-needle { transform-origin: 22px 23px; transform-box: view-box; }
/* Pitch count bar: green, amber near the limit, red past it. */
.pitch-bar > span { background: var(--green, #1FA35B); transition: background .3s; }
.pitch-bar.is-near > span { background: #f2a900; }
.pitch-bar.is-over > span { background: var(--red); }
@media (prefers-reduced-motion: reduce) { .modal-backdrop .modal, .sheet, .toast { animation: none; } }
.ring-wrap > svg:not(.docs-ring) { position: relative; z-index: 1; }

/* The tab bar slides out of view while scrolling down, and back on a quick flick up (partials/bottom-nav-guard,
   animated there with the Web Animations API). Only the transform moves — position stays fixed. */

/* Badge tiles: the progress bar (and its "0 / 5") sit at the bottom of each tile, so a row of bars lines up whatever the text above. */
.badge-tile > .bar { margin-top: auto !important; }

/* Players list: attendance, AVG and badges in three equal boxes on one line. */
.player-mini-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.player-mini-stats > span { display: flex; flex-direction: column; gap: 1px; padding: 6px 8px; border-radius: 10px; background: var(--surface-2, #f4f5f7); min-width: 0; }
.player-mini-stats small { display: flex; align-items: center; gap: 3px; font-size: .68rem; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.player-mini-stats small svg { width: 12px; height: 12px; }
.player-mini-stats b { font-family: var(--font-display, inherit); font-size: 1.05rem; line-height: 1.1; }
.player-mini-stats .is-link { cursor: pointer; }
.player-mini-stats .is-link:hover { background: var(--red-tint); }

/* Contributions: a late due date stands out; "What do the statuses mean?" folds open. */
.due-late { color: var(--red); font-weight: 700; }
.status-info { position: absolute; top: 2px; right: 2px; width: 28px; height: 28px; min-height: 28px; padding: 0; color: var(--muted); }
.status-info svg { width: 15px; height: 15px; }
.status-pop { position: absolute; top: 44px; right: 8px; left: 8px; z-index: 5; max-width: 380px; margin-left: auto; padding: 12px 14px; border-radius: 16px; background: var(--surface); box-shadow: 0 16px 40px rgba(16, 18, 24, .22); border: 1px solid var(--line); text-align: left; }
