/* =====================================================================
   pop-warner theme overrides
   =====================================================================
   Applied via <body class="pw-theme"> — toggled on by pw-theme.js when
   the current tenant resolves to tier_v2 = 'league' OR 'team' OR slug
   starts with 'tc-popwarner'. P1 / Fusion / other tenants keep the
   gold palette untouched.

   Strategy: override the small set of CSS variables every P1 page
   reads (--gold, --gold-soft, --gold-bright, --gold-border) so the
   same component code renders with the Pop Warner palette automatically.
   Adds a few PW-specific variables for places where pages reach for
   gold-tinted backgrounds directly.

   Color palette (Pop Warner league/team):
     bg dark         : #0a0a0a
     panel           : #1a1a1a
     panel light     : #232323
     border          : rgba(255,255,255,.10)
     text primary    : #f4f4f4
     text muted      : #a8a8a8
     accent          : #e6e6e6 (silver)
     accent bright   : #ffffff
   ===================================================================== */

body.pw-theme {
  /* Override P1's gold variables. Same selectors P1 pages use, just
     different colors when this class is on the body. */
  --gold:         #e6e6e6;
  --gold-soft:    #c8c8c8;
  --gold-bright:  #ffffff;
  --gold-border:  rgba(255, 255, 255, 0.28);

  /* PW-specific variables for direct use on PW-only pages. */
  --pw-bg:           #0a0a0a;
  --pw-panel:        #1a1a1a;
  --pw-panel-light:  #232323;
  --pw-border:       rgba(255, 255, 255, 0.10);
  --pw-border-strong:rgba(255, 255, 255, 0.28);
  --pw-text:         #f4f4f4;
  --pw-text-muted:   #a8a8a8;
  --pw-text-dim:     #6b6b6b;
  --pw-accent:       #e6e6e6;
  --pw-accent-bright:#ffffff;
}

/* ============== Body backgrounds — kill the gold gradient ============== */
body.pw-theme {
  background:
    radial-gradient(70% 55% at 50% 0%, rgba(255, 255, 255, 0.06) 0%, rgba(255, 255, 255, 0.02) 32%, transparent 75%),
    linear-gradient(180deg, #1a1a1a 0%, #131313 45%, #0a0a0a 100%) !important;
  background-attachment: fixed !important;
}

body.pw-theme::before {
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px) !important;
}

/* ============== Hero card — silver instead of gold ============== */
body.pw-theme .hero {
  background:
    radial-gradient(140% 80% at 50% 0%, rgba(255, 255, 255, 0.18) 0%, transparent 55%),
    linear-gradient(180deg, #f4f4f4 0%, #c8c8c8 55%, #8a8a8a 100%) !important;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.30),
    0 14px 32px rgba(0, 0, 0, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.5) !important;
}

body.pw-theme .hero::after {
  background: linear-gradient(180deg, #1a1a1a 0%, #0a0a0a 100%) !important;
}

body.pw-theme .hero h1 {
  background: linear-gradient(180deg, #ffffff 0%, #c8c8c8 100%) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
}

body.pw-theme .hero-sub,
body.pw-theme .hero-kicker {
  color: #b0b0b0 !important;
}

/* ============== Back link ============== */
body.pw-theme .back-link {
  background: rgba(255, 255, 255, 0.06) !important;
  border-color: rgba(255, 255, 255, 0.12) !important;
}
body.pw-theme .back-link:hover {
  background: rgba(255, 255, 255, 0.14) !important;
  border-color: rgba(255, 255, 255, 0.35) !important;
  color: #ffffff !important;
}

/* ============== Action tiles (.btn-action) ============== */
body.pw-theme .btn-action {
  background: linear-gradient(180deg, #1f1f1f, #131313) !important;
  border-color: rgba(255, 255, 255, 0.10) !important;
}
body.pw-theme .btn-action:hover {
  border-color: rgba(255, 255, 255, 0.28) !important;
  background: linear-gradient(180deg, #252525, #1a1a1a) !important;
}
body.pw-theme .btn-action.is-disabled {
  opacity: .55 !important;
}
body.pw-theme .btn-action-icon svg {
  color: #e0e0e0 !important;
  stroke: #e0e0e0 !important;
}

/* ============== Cards / panels ============== */
body.pw-theme .card,
body.pw-theme .content-card,
body.pw-theme .panel,
body.pw-theme .progress-card,
body.pw-theme .resource-card,
body.pw-theme .topic-section,
body.pw-theme .summary-card,
body.pw-theme .team-card {
  background: linear-gradient(180deg, #1f1f1f, #131313) !important;
  border-color: rgba(255, 255, 255, 0.10) !important;
}

/* ============== Modal — same shape, different palette ============== */
body.pw-theme .modal-panel,
body.pw-theme .modal-backdrop > *,
body.pw-theme .p1-tenant-modal-panel {
  background: linear-gradient(180deg, #1a1a1a 0%, #0a0a0a 100%) !important;
  border-color: rgba(255, 255, 255, 0.18) !important;
}

/* ============== Topic / section labels ============== */
body.pw-theme .topic-title,
body.pw-theme .section-title,
body.pw-theme .progress-label {
  color: #e6e6e6 !important;
}

/* ============== Pills & badges ============== */
body.pw-theme .meta-pill {
  background: rgba(255, 255, 255, 0.05) !important;
  border-color: rgba(255, 255, 255, 0.12) !important;
  color: #c8c8c8 !important;
}
body.pw-theme .meta-pill.required {
  background: rgba(255, 255, 255, 0.12) !important;
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.35) !important;
}

body.pw-theme .resource-open {
  background: rgba(255, 255, 255, 0.10) !important;
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.30) !important;
}
body.pw-theme .resource-open:hover {
  background: rgba(255, 255, 255, 0.20) !important;
}

/* ============== Tenant pill ============== */
body.pw-theme .p1-tenant-pill {
  background: linear-gradient(180deg, rgba(40, 40, 40, .92), rgba(20, 20, 20, .94)) !important;
  border-color: rgba(255, 255, 255, 0.35) !important;
  color: #ffffff !important;
}
body.pw-theme .p1-tenant-pill-dot {
  background: radial-gradient(circle at 30% 30%, #ffffff 0%, #c8c8c8 70%) !important;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.18) !important;
}

/* ============== Nav menu ============== */
body.pw-theme .p1-nav-toggle,
body.pw-theme .p1-nav-panel {
  background: linear-gradient(180deg, #1f1f1f, #131313) !important;
  border-color: rgba(255, 255, 255, 0.12) !important;
}
body.pw-theme .p1-nav-panel a {
  color: #e6e6e6 !important;
}
body.pw-theme .p1-nav-panel a:hover {
  background: rgba(255, 255, 255, 0.08) !important;
  color: #ffffff !important;
}

/* ============== Form inputs ============== */
body.pw-theme input[type="text"],
body.pw-theme input[type="email"],
body.pw-theme input[type="number"],
body.pw-theme input[type="date"],
body.pw-theme input[type="time"],
body.pw-theme input[type="tel"],
body.pw-theme select,
body.pw-theme textarea,
body.pw-theme .field-input,
body.pw-theme .field-select {
  background: #1a1a1a !important;
  color: #f4f4f4 !important;
  border-color: rgba(255, 255, 255, 0.15) !important;
}

body.pw-theme input::placeholder,
body.pw-theme textarea::placeholder {
  color: #6b6b6b !important;
}

/* ============== Defensive — guarantee any black-on-black hover that
   leaned on gold contrast is still readable. Forces any element with
   white text on dark backgrounds to be readable. ============== */
body.pw-theme .small,
body.pw-theme .status,
body.pw-theme .empty,
body.pw-theme .loading,
body.pw-theme .muted {
  color: #a8a8a8 !important;
}

/* ============== Parent-edit specific gold leaks ============== */

/* The "Parent HQ" two-line hero text — second line has class
   hero-line--gold with a gold gradient as text fill. Swap to white. */
body.pw-theme .hero h1 .hero-line--gold {
  background: linear-gradient(180deg, #ffffff 0%, #d8d8d8 50%, #a8a8a8 100%) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  filter: drop-shadow(0 6px 14px rgba(255, 255, 255, 0.15)) !important;
}

/* The action stack tile tray — large gold gradient that frames the
   navigation tiles. This is the "tray behind the menu" — replace
   gold with a dark silver-edged panel. */
body.pw-theme .action-stack {
  background:
    radial-gradient(140% 80% at 50% 0%, rgba(255, 255, 255, 0.10) 0%, transparent 55%),
    linear-gradient(180deg, #2a2a2a 0%, #1a1a1a 55%, #0e0e0e 100%) !important;
  border: 1.5px solid #0e0e0e !important;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.18),
    0 0 90px rgba(255, 255, 255, 0.06),
    0 40px 80px rgba(0, 0, 0, 0.6),
    inset 0 1px 0 rgba(255, 255, 255, 0.18) !important;
}

/* The top-edge white shine pseudo-element stays — it's already white. */

/* Hero eyebrow (the small uppercase text above the heading) — was
   gold-tinted on P1 pages. */
body.pw-theme .hero-eyebrow {
  background: rgba(255, 255, 255, 0.06) !important;
  border-color: rgba(255, 255, 255, 0.25) !important;
  color: #e0e0e0 !important;
}

/* Hero outer gold halo glow that some pages render around the hero. */
body.pw-theme .hero,
body.pw-theme .hero::before {
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.30),
    0 14px 32px rgba(0, 0, 0, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.5) !important;
}

/* The radial gold halo behind the action stack (some pages have a
   ::before pseudo-element on body or .wrap that bleeds gold). */
body.pw-theme,
body.pw-theme .wrap {
  --pw-overrride-gold-halo: 1;
}

/* ============== Splash screen — was gold ============== */
body.pw-theme #p1Splash {
  background:
    radial-gradient(60% 80% at 50% 0%, rgba(255, 255, 255, 0.10), transparent 70%),
    linear-gradient(180deg, #1a1a1a 0%, #0a0a0a 100%) !important;
}

/* ============== Tenant pill text leak ============== */
body.pw-theme .p1-tenant-pill,
body.pw-theme .tenant-pill {
  color: #ffffff !important;
}
body.pw-theme .p1-tenant-pill-label,
body.pw-theme .tenant-pill .tenant-name {
  color: #ffffff !important;
}

/* ============== Modal close button + accents ============== */
body.pw-theme .modal-close,
body.pw-theme .modal-panel button[type="button"]:not(.btn-primary):not(.btn-action) {
  color: #c8c8c8 !important;
}

/* ============== Status/badge "maybe" pill — was #c9a227 ============== */
body.pw-theme .book-status-pill.maybe,
body.pw-theme .book-status-pill.waitlist {
  background: rgba(255, 255, 255, 0.10) !important;
  color: #d8d8d8 !important;
  border-color: rgba(255, 255, 255, 0.28) !important;
}
body.pw-theme .rsvp-pill-group .book-status-pill.is-active.maybe {
  background: rgba(255, 255, 255, 0.20) !important;
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.55) !important;
}

/* ============== Splash logo gold ring ============== */
body.pw-theme #p1Splash img {
  box-shadow:
    0 18px 44px rgba(0, 0, 0, 0.55),
    0 0 0 1px rgba(255, 255, 255, 0.35) !important;
}

/* ============== Any background-attached element with a gold gradient ============== */
/* Belt + suspenders: catch any element that uses the P1 gradient pattern
   by selecting any descendant of body.pw-theme. We can't override every
   exact selector, but we can rule out the most painful gold-tinted glass
   surfaces by targeting common patterns. */
body.pw-theme [class*="--gold"] {
  /* fall through to base class styles — but text color forced */
  color: #ffffff !important;
}

/* ============== "COMMAND CENTER" eyebrow + side rules ============== */
/* The pill that says "COMMAND CENTER" above the action stack — has
   gold border + gold-tinted background. */
body.pw-theme .command-center-eyebrow {
  border-color: rgba(255, 255, 255, 0.28) !important;
  background: rgba(255, 255, 255, 0.08) !important;
  color: #ffffff !important;
}

/* The gold dashes on either side of "COMMAND CENTER" — pure decorative
   gold gradient lines. Replace with silver/white. */
body.pw-theme .command-center-rule {
  background: linear-gradient(90deg, #ffffff 0%, #c8c8c8 50%, #888888 100%) !important;
  filter: drop-shadow(0 0 6px rgba(255, 255, 255, 0.18)) !important;
}

/* ============== Tile icon backgrounds (.btn-action-icon) ============== */
/* The colored gradient square next to each tile label — bright gold on
   P1. Switch to dark grey with silver icon stroke. */
body.pw-theme .btn-action-icon {
  background: linear-gradient(180deg, #3a3a3a 0%, #2a2a2a 55%, #1a1a1a 100%) !important;
  border-color: #0e0e0e !important;
  color: #ffffff !important;
}
body.pw-theme .btn-action-icon svg {
  stroke: #ffffff !important;
  fill: none !important;
}
body.pw-theme .btn-action:hover .btn-action-icon {
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.35) !important,
    0 10px 22px rgba(0, 0, 0, 0.55) !important,
    inset 0 1px 0 rgba(255, 255, 255, 0.20) !important;
}

/* Red alert tile icon stays red — that's a semantic state, not a brand color. */

/* ============== layout-edit.js inline-styled "EDIT LAYOUT" pill ============== */
/* layout-edit.js inlines its own stylesheet with hex gold values; we
   override via the .pw-theme parent selector with !important. */
body.pw-theme .layout-edit-btn {
  background: #0e0e0e !important;
  color: #ffffff !important;
  border: 1.5px solid rgba(255, 255, 255, 0.55) !important;
}
body.pw-theme .layout-edit-btn:hover {
  background: #1a1a1a !important;
  color: #ffffff !important;
  border-color: #ffffff !important;
}
body.pw-theme .layout-edit-btn.is-on {
  background: linear-gradient(180deg, #c8c8c8, #888888) !important;
  color: #0e0e0e !important;
  border-color: #0e0e0e !important;
}

/* Any layout-edit ghost / drag handles in layout-edit.js that use gold
   coloring — kill them. */
body.pw-theme [class*="layout-edit"] {
  --gold-soft: #c8c8c8 !important;
}

/* Buttons inside layout-edit bar / overlay that use gold backgrounds. */
body.pw-theme .layout-edit-handle,
body.pw-theme .layout-edit-actions button,
body.pw-theme .layout-edit-row {
  background: rgba(255, 255, 255, 0.10) !important;
  border-color: rgba(255, 255, 255, 0.30) !important;
  color: #e0e0e0 !important;
}

/* ============== Modal header / footer borders that used gold ============== */
body.pw-theme .modal-panel,
body.pw-theme .modal-panel .modal-header,
body.pw-theme .modal-panel .modal-footer {
  border-color: rgba(255, 255, 255, 0.18) !important;
}

/* ============== Auth card splash gold gradient ============== */
body.pw-theme .auth-card,
body.pw-theme .auth-card::before {
  background: linear-gradient(180deg, #1a1a1a 0%, #0a0a0a 100%) !important;
}

/* ============== Any chip/pill/badge that uses --gold-soft text ============== */
body.pw-theme .chip,
body.pw-theme .badge,
body.pw-theme .pill {
  color: #e6e6e6 !important;
}

/* ============== TEAM-CHAT specific gold leaks ============== */

/* Topbar title text + back link + kebab — gold color text. */
body.pw-theme .chat-topbar-title,
body.pw-theme .chat-topbar-back,
body.pw-theme .chat-topbar-kebab,
body.pw-theme .chat-topbar-close,
body.pw-theme .chat-topbar-btn {
  color: #ffffff !important;
}
body.pw-theme .chat-topbar-back-label {
  color: #ffffff !important;
}

/* User avatar circle at bottom of channel list — gold gradient. */
body.pw-theme .chat-user-pill-avatar,
body.pw-theme .user-block-avatar {
  background: linear-gradient(180deg, #f4f4f4, #888888) !important;
  color: #0e0e0e !important;
}

/* User pill border hover — gold. */
body.pw-theme .chat-user-pill {
  border-color: rgba(255, 255, 255, 0.18) !important;
}
body.pw-theme .chat-user-pill:hover {
  border-color: rgba(255, 255, 255, 0.55) !important;
}
body.pw-theme .chat-user-pill .role-pill {
  background: linear-gradient(180deg, #c8c8c8, #888888) !important;
  color: #0e0e0e !important;
}

/* The +Add channel / +Add DM buttons — solid gold gradients. */
body.pw-theme .chat-section-add,
body.pw-theme .channel-add,
body.pw-theme .dm-add,
body.pw-theme [class*="chat-section"][class*="add"] {
  background: linear-gradient(180deg, #c8c8c8, #888888) !important;
  color: #0e0e0e !important;
  border-color: #0e0e0e !important;
}

/* Any inline "role" badge in chat user lists. */
body.pw-theme .role-pill,
body.pw-theme [style*="#f0c862"],
body.pw-theme [style*="#c9a227"] {
  background: rgba(255, 255, 255, 0.12) !important;
  color: #ffffff !important;
}

/* Section labels ("CHANNELS", "DIRECT MESSAGES") if gold-tinted. */
body.pw-theme .chat-section-label {
  color: #888888 !important;
}

/* Channel row "active" indicator. */
body.pw-theme .chat-channel-row.is-active,
body.pw-theme .chat-channel-row[aria-selected="true"] {
  background: rgba(255, 255, 255, 0.08) !important;
  border-left-color: #ffffff !important;
}

/* ============== Catch-all for ANY element with inline gold gradient ============== */
/* Many P1 pages use inline `style="background:linear-gradient(... #c9a227...)"`
   for buttons/avatars. CSS can't perfectly override inline styles, but
   we can at least kill the gold backgrounds via attribute selectors. */
body.pw-theme [style*="#c9a227"][style*="background"],
body.pw-theme [style*="#f0c862"][style*="background"] {
  background: linear-gradient(180deg, #2a2a2a, #1a1a1a) !important;
  color: #ffffff !important;
}

/* ============== HERO sizing — match P1 hero text sizing only ============== */
/* Only override text sizing inside the hero. Do NOT touch layout / display
   / flex on the hero itself — different pages (coach.html, parent-edit,
   board.html) have different inner pseudo-element mask boxes and forcing
   flex broke them. Leave layout alone, just style the text. */
body.pw-theme .hero {
  text-align: center !important;
}

body.pw-theme .hero h1 {
  margin: 0 0 18px !important;
  font-size: clamp(38px, 6vw, 72px) !important;
  line-height: .95 !important;
  font-weight: 900 !important;
  letter-spacing: -.02em !important;
  text-transform: uppercase !important;
  text-wrap: balance !important;
}

body.pw-theme .hero h1 .hero-line {
  display: block !important;
}
body.pw-theme .hero h1 .hero-line--white {
  color: #ffffff !important;
  text-shadow: 0 4px 20px rgba(0, 0, 0, 0.5) !important;
  -webkit-text-fill-color: #ffffff !important;
}
/* Already overridden above — restated here for clarity. */
body.pw-theme .hero h1 .hero-line--gold {
  background: linear-gradient(180deg, #ffffff 0%, #d8d8d8 50%, #a8a8a8 100%) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
}

/* Hero eyebrow chip (small uppercase label above the title). */
body.pw-theme .hero-eyebrow,
body.pw-theme .hero-kicker {
  display: inline-block !important;
  padding: 7px 16px !important;
  border-radius: 999px !important;
  border: 1px solid rgba(255, 255, 255, 0.28) !important;
  background: rgba(255, 255, 255, 0.06) !important;
  color: #ffffff !important;
  font-size: 11px !important;
  font-weight: 900 !important;
  letter-spacing: .28em !important;
  text-transform: uppercase !important;
  margin-bottom: 14px !important;
}

/* Hero sub line — neutral light grey, matches P1's understated subtitle. */
body.pw-theme .hero-sub {
  max-width: 580px !important;
  margin: 0 auto !important;
  font-size: clamp(14px, 1.5vw, 17px) !important;
  line-height: 1.55 !important;
  color: rgba(255, 255, 255, 0.72) !important;
}

/* ============== NAV MENU (accordion) — full PW override ============== */
/* nav-menu.css uses gold throughout — trigger button border, panel
   border, current-page indicator, section labels, etc. Override all
   to silver/white. */

/* The trigger button itself (hamburger that opens the menu). */
body.pw-theme .p1-nav-trigger {
  background: rgba(255, 255, 255, 0.06) !important;
  border-color: rgba(255, 255, 255, 0.28) !important;
  color: #ffffff !important;
}
body.pw-theme .p1-nav-trigger:hover,
body.pw-theme .p1-nav-trigger:focus-visible {
  background: rgba(255, 255, 255, 0.14) !important;
  border-color: rgba(255, 255, 255, 0.55) !important;
  color: #ffffff !important;
}
body.pw-theme .p1-nav.is-open .p1-nav-trigger {
  background: rgba(255, 255, 255, 0.16) !important;
  border-color: rgba(255, 255, 255, 0.55) !important;
}

/* Trigger icon + chevron. */
body.pw-theme .p1-nav-trigger-icon,
body.pw-theme .p1-nav-trigger-chev,
body.pw-theme .p1-nav-section-label {
  color: #ffffff !important;
}

/* The dropdown panel itself. */
body.pw-theme .p1-nav-panel {
  background: linear-gradient(180deg, #1f1f1f 0%, #131313 100%) !important;
  border-color: rgba(255, 255, 255, 0.20) !important;
}

/* List items. */
body.pw-theme .p1-nav-list a {
  color: #e0e0e0 !important;
}
body.pw-theme .p1-nav-list a:hover,
body.pw-theme .p1-nav-list a:focus-visible {
  background: rgba(255, 255, 255, 0.08) !important;
  color: #ffffff !important;
}
body.pw-theme .p1-nav-list a.is-current {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.12) 0%, rgba(255, 255, 255, 0.04) 100%) !important;
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.35) !important;
}
body.pw-theme .p1-nav-list a.is-current::after {
  background: #ffffff !important;
}
body.pw-theme .p1-nav-list .p1-nav-num {
  background: rgba(255, 255, 255, 0.10) !important;
  color: #c8c8c8 !important;
}
body.pw-theme .p1-nav-list a.is-current .p1-nav-num {
  background: #ffffff !important;
  color: #0a0a0a !important;
}

/* Section dividers. */
body.pw-theme .p1-nav-section + .p1-nav-section {
  border-top-color: rgba(255, 255, 255, 0.10) !important;
}

/* ============== COACH-HQ action-tray (the gold tile tray) ============== */
/* coach.html uses .action-tray (not .action-stack like parent-edit).
   Same gold gradient background — needs the same override. */
body.pw-theme .action-tray {
  background:
    radial-gradient(140% 80% at 50% 0%, rgba(255, 255, 255, 0.10) 0%, transparent 55%),
    linear-gradient(180deg, #2a2a2a 0%, #1a1a1a 55%, #0e0e0e 100%) !important;
  border: 1.5px solid #0e0e0e !important;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.18),
    0 0 90px rgba(255, 255, 255, 0.06),
    0 40px 80px rgba(0, 0, 0, 0.6),
    inset 0 1px 0 rgba(255, 255, 255, 0.18) !important;
}

/* ============== SCOREBOARD — full PW override ============== */
body.pw-theme .filter-pill {
  background: rgba(0, 0, 0, 0.4) !important;
  color: #e0e0e0 !important;
}
body.pw-theme .filter-pill:hover {
  background: rgba(255, 255, 255, 0.08) !important;
}
body.pw-theme .filter-pill.is-active {
  background: linear-gradient(180deg, #d8d8d8, #888888) !important;
  color: #0e0e0e !important;
  border-color: rgba(255, 255, 255, 0.5) !important;
}

body.pw-theme .status-pill {
  background: rgba(255, 255, 255, 0.08) !important;
  color: #e0e0e0 !important;
  border-color: rgba(255, 255, 255, 0.2) !important;
}
body.pw-theme .status-pill.final {
  background: linear-gradient(180deg, #d8d8d8, #888888) !important;
  color: #0e0e0e !important;
}

body.pw-theme .game-card {
  background: linear-gradient(180deg, #1f1f1f, #131313) !important;
  border-color: rgba(255, 255, 255, 0.10) !important;
}
body.pw-theme .game-card.is-final {
  border-color: rgba(255, 255, 255, 0.32) !important;
}

body.pw-theme .section-head,
body.pw-theme .week-head,
body.pw-theme .week-label {
  color: #e6e6e6 !important;
}

body.pw-theme .btn-enter-score {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.10), rgba(255, 255, 255, 0.04)) !important;
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.35) !important;
}
body.pw-theme .btn-enter-score:hover {
  background: rgba(255, 255, 255, 0.18) !important;
  border-color: #ffffff !important;
}

/* ============== Generic — any element where gold color was set inline ============== */
body.pw-theme [style*="color: #f4dd87"],
body.pw-theme [style*="color:#f4dd87"],
body.pw-theme [style*="color: #e7c45d"],
body.pw-theme [style*="color:#e7c45d"],
body.pw-theme [style*="color: #c9a227"],
body.pw-theme [style*="color:#c9a227"] {
  color: #ffffff !important;
}

/* Legacy back-link hide removed — nav-menu.js's stripLegacyBacklinks
   already handles this via JS, and the CSS version was hiding real
   navigation elements on some pages. */

/* ============== TEAM-CHAT — DISABLED in PW context (data isolation) ============== */
/* chat_channels + chat_messages don't have tenant_id columns yet, so
   the channel list, DM list, and member roster all leak cross-tenant
   data. Until Phase 2 ships proper tenant scoping for chat, we hide
   the chat UI in PW context and show a placeholder. */
body.pw-theme .chat-shell,
body.pw-theme .chat-drawer,
body.pw-theme .chat-main {
  position: relative;
}
body.pw-theme .chat-shell::before {
  content: "";
  position: fixed;
  inset: 0;
  background: linear-gradient(180deg, #1a1a1a 0%, #0a0a0a 100%);
  z-index: 9000;
}
body.pw-theme .chat-shell::after {
  content: "Team Chat for Pop Warner ships in Phase 2. \A\A For now, use Calendar, RSVPs, and Volunteer Signups to coordinate with families.";
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 16px;
  line-height: 1.6;
  color: #e0e0e0;
  padding: 60px 30px;
  white-space: pre-wrap;
  z-index: 9001;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  max-width: 480px;
  margin: auto;
}

/* =====================================================================
   PW hero — TC Youth Football logo + text swap.
   Pages opt in by adding three elements inside their existing .hero:
     1) <img class="hero-pw-mark" src="/tc-popwarner-logo.png" ... />
     2) (optional) keep the existing P1 <p class="hero-sub">…</p>
     3) <p class="hero-sub hero-sub--pw">PW-specific copy</p>
   All three live in the HTML at all times. CSS hides PW pieces by
   default and hides P1 pieces under body.pw-theme — no JS needed.
   ===================================================================== */
.hero-pw-mark { display: none; }
.hero-sub.hero-sub--pw { display: none; }

body.pw-theme .hero-pw-mark {
  display: block !important;
  margin: 14px auto 6px !important;
  max-width: 200px;
  width: 60%;
  height: auto;
  /* `screen` blend mode lets dark pixels drop out into whatever sits
     behind them. The TC logo's football has a dark textured body —
     without this, that body shows as a slightly-different shade of
     dark than the hero gradient, which Jeremy clocked as "logo
     background is off." With screen blend, only the silver outline,
     white lettering, and colored laces remain visible; the dark
     football body dissolves into the hero gradient. */
  mix-blend-mode: screen;
}
body.pw-theme .hero-sub:not(.hero-sub--pw) {
  display: none !important;
}
body.pw-theme .hero-sub.hero-sub--pw {
  display: block !important;
}
/* On PW, drop the "Welcome to Your" prefix line so the title is just
   "Coaches HQ." / "Parent HQ." centered above the logo. */
body.pw-theme #heroLineWelcome {
  display: none !important;
}

@media (max-width: 480px) {
  body.pw-theme .hero-pw-mark {
    max-width: 150px;
    margin: 10px auto 4px !important;
  }
}
