/* ============================================
   League Pages — Broadcast-Style Design System
   Shared across events, teams, stats, players
   ============================================ */

/* --- Auth Gate --- */
.auth-gate {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 24px;
  text-align: center;
  background: var(--color-navy-deep);
}
.auth-gate__logo { width: 80px; margin-bottom: 24px; }
.auth-gate__title {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--color-white);
  margin-bottom: 8px;
}
.auth-gate__desc { font-size: 14px; color: rgba(255,255,255,0.5); margin-bottom: 24px; }
.auth-gate__form { display: flex; gap: 8px; max-width: 320px; width: 100%; }
.auth-gate__input {
  flex: 1; height: 48px; padding: 0 16px;
  background: rgba(255,255,255,0.15);
  border: 1px solid rgba(255,255,255,0.35);
  border-radius: 4px; color: white;
  font-family: var(--font-body); font-size: 16px;
  -webkit-appearance: none;
}
.auth-gate__input::placeholder { color: rgba(255,255,255,0.5); }
.auth-gate__btn {
  height: 48px; padding: 0 20px;
  background: var(--color-red); color: white; border: none;
  border-radius: 4px; font-family: var(--font-body);
  font-size: 14px; font-weight: 600; text-transform: uppercase;
  letter-spacing: 1px; cursor: pointer;
}
.auth-gate__btn:hover { background: var(--color-red-hover); }
.auth-gate__error { display: none; color: var(--color-red); font-size: 14px; margin-top: 12px; }

/* --- League Nav --- */
.league-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(8, 14, 26, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.league-nav__inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  height: 56px;
  gap: 8px;
}
.league-nav__logo { height: 28px; margin-right: 16px; }
.league-nav__link {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: rgba(255,255,255,0.45);
  text-decoration: none;
  padding: 16px 14px;
  border-bottom: 2px solid transparent;
  transition: color 0.2s, border-color 0.2s;
  white-space: nowrap;
}
.league-nav__link:hover { color: rgba(255,255,255,0.8); }
.league-nav__link.is-active {
  color: var(--color-white);
  border-bottom-color: var(--color-red);
}
.league-nav__spacer { flex: 1; }
.league-nav__home {
  font-size: 13px;
  color: rgba(255,255,255,0.35);
  text-decoration: none;
  transition: color 0.2s;
}
.league-nav__home:hover { color: white; }

/* --- Page Container --- */
.lp { /* league page */
  max-width: 1100px;
  margin: 0 auto;
  padding: 32px 24px 80px;
  background: var(--color-navy-deep);
  min-height: calc(100vh - 56px);
}

/* --- Section Label --- */
.lp-label {
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 3px;
  color: var(--color-red);
  margin-bottom: 20px;
}

/* --- Page Title --- */
.lp-title {
  font-family: var(--font-display);
  font-size: 36px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--color-white);
  margin-bottom: 32px;
  letter-spacing: 1px;
}

/* --- Divider --- */
.lp-divider {
  height: 1px;
  background: rgba(255,255,255,0.08);
  margin: 36px 0;
}

/* --- Card --- */
.lp-card {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 6px;
  overflow: hidden;
  transition: border-color 0.2s, transform 0.15s;
}
.lp-card:hover {
  border-color: rgba(255,255,255,0.2);
  transform: translateY(-1px);
}

/* --- Broadcast Table --- */
.bc-table {
  width: 100%;
  border-collapse: collapse;
}
.bc-table th {
  font-family: var(--font-body);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: rgba(255,255,255,0.35);
  text-align: left;
  padding: 10px 14px;
  border-bottom: 2px solid rgba(255,255,255,0.1);
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
}
.bc-table th:hover { color: rgba(255,255,255,0.6); }
.bc-table th.is-sorted { color: var(--color-red); }
.bc-table th.align-center { text-align: center; }
.bc-table th.align-right { text-align: right; }

.bc-table td {
  padding: 12px 14px;
  font-size: 14px;
  color: rgba(255,255,255,0.8);
  border-bottom: 1px solid rgba(255,255,255,0.04);
  white-space: nowrap;
}
.bc-table td.align-center { text-align: center; }
.bc-table td.align-right { text-align: right; }

.bc-table tbody tr {
  transition: background 0.15s;
}
.bc-table tbody tr:hover {
  background: rgba(255,255,255,0.04);
}

/* Table data emphasis */
.bc-num {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--color-white);
}
.bc-num--lg {
  font-size: 20px;
}
.bc-num--highlight {
  color: var(--color-red);
}
.bc-num--positive { color: #4CAF50; }
.bc-num--negative { color: #E53935; }

.bc-rank {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  color: rgba(255,255,255,0.25);
  width: 36px;
  display: inline-block;
}
.bc-rank--1 { color: #FFD700; }
.bc-rank--2 { color: #C0C0C0; }
.bc-rank--3 { color: #CD7F32; }

/* Team color dot */
.bc-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-right: 8px;
  vertical-align: middle;
}

/* Player name in tables */
.bc-player { font-weight: 600; color: var(--color-white); }
.bc-player__team {
  font-size: 11px;
  color: rgba(255,255,255,0.4);
  font-weight: 400;
  margin-left: 8px;
}

/* Clickable row */
.bc-table--clickable tbody tr { cursor: pointer; }
.bc-table--clickable tbody tr:hover { background: rgba(255,255,255,0.06); }

/* --- Tabs --- */
.lp-tabs {
  display: flex;
  gap: 2px;
  margin-bottom: 24px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.lp-tabs::-webkit-scrollbar { display: none; }

.lp-tab {
  padding: 12px 20px;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  color: rgba(255,255,255,0.45);
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.2s, border-color 0.2s;
}
.lp-tab:hover { color: rgba(255,255,255,0.7); }
.lp-tab.is-active {
  color: var(--color-white);
  border-bottom-color: var(--color-red);
}

.lp-panel { display: none; }
.lp-panel.is-active { display: block; }

/* --- Badge --- */
.lp-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 3px 8px;
  border-radius: 3px;
}
.lp-badge--live { background: var(--color-red); color: white; }
.lp-badge--upcoming { background: rgba(255,255,255,0.1); color: rgba(255,255,255,0.7); }
.lp-badge--completed { background: rgba(255,255,255,0.06); color: rgba(255,255,255,0.4); }
/* Live match badge — pulsing red dot before the 'Live' text */
.mh-live-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.mh-live-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 0 0 rgba(255,255,255,0.7);
  animation: mh-live-pulse 1.4s ease-out infinite;
}
@keyframes mh-live-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(255,255,255,0.7); }
  80%  { box-shadow: 0 0 0 8px rgba(255,255,255,0); }
  100% { box-shadow: 0 0 0 0 rgba(255,255,255,0); }
}
/* Score-updated pulse — brief flash when a score changes via live listener */
.mh-score-pulse {
  animation: mh-score-pulse 0.9s ease-out;
}
@keyframes mh-score-pulse {
  0%   { transform: scale(1); color: var(--color-red); text-shadow: 0 0 24px rgba(212,43,43,0.7); }
  60%  { transform: scale(1.08); color: var(--color-red); text-shadow: 0 0 16px rgba(212,43,43,0.4); }
  100% { transform: scale(1); text-shadow: none; }
}
@media (prefers-reduced-motion: reduce) {
  .mh-live-dot, .mh-score-pulse { animation: none; }
}
.lp-badge--win { background: rgba(76,175,80,0.15); color: #4CAF50; }
.lp-badge--loss { background: rgba(229,57,53,0.15); color: #E53935; }

/* --- Team Card (grid) --- */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 12px;
}

.team-tile {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 6px;
  overflow: hidden;
  transition: border-color 0.2s, transform 0.15s;
  cursor: default;
}
.team-tile:hover {
  border-color: rgba(255,255,255,0.2);
  transform: translateY(-2px);
}

.team-tile__banner {
  height: 6px;
  width: 100%;
}
.team-tile__body { padding: 20px; }

.team-tile__header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 16px;
}
.team-tile__crest {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: white;
  flex-shrink: 0;
}
.team-tile__name {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--color-white);
  line-height: 1.2;
}
.team-tile__city {
  font-size: 12px;
  color: rgba(255,255,255,0.4);
}

.team-tile__stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px;
  margin-bottom: 16px;
}
.team-tile__stat { text-align: center; padding: 8px 0; }
.team-tile__stat-val {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  color: var(--color-white);
  line-height: 1;
}
.team-tile__stat-lbl {
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: rgba(255,255,255,0.3);
  margin-top: 4px;
}

.team-tile__roster {
  border-top: 1px solid rgba(255,255,255,0.06);
  padding-top: 12px;
}
.team-tile__roster-label {
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: rgba(255,255,255,0.3);
  margin-bottom: 8px;
}
.team-tile__roster-list {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}
.team-tile__player {
  font-size: 12px;
  color: rgba(255,255,255,0.6);
  background: rgba(255,255,255,0.04);
  padding: 2px 8px;
  border-radius: 3px;
}

/* --- Event Card --- */
.event-card {
  border-radius: 6px;
  overflow: hidden;
  margin-bottom: 12px;
  border: 1px solid rgba(255,255,255,0.08);
  transition: border-color 0.2s;
}
.event-card:hover { border-color: rgba(255,255,255,0.18); }

.event-card__accent { height: 4px; }
.event-card__body { padding: 24px; }

.event-card__top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 10px;
}
.event-card__name {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--color-white);
  letter-spacing: 0.5px;
}
.event-card__meta {
  display: flex;
  gap: 20px;
  font-size: 13px;
  color: rgba(255,255,255,0.5);
  margin-bottom: 12px;
  flex-wrap: wrap;
}
.event-card__desc {
  font-size: 14px;
  color: rgba(255,255,255,0.6);
  line-height: 1.6;
}

/* Match scoreline */
.match-line {
  display: flex;
  align-items: center;
  padding: 10px 14px;
  background: rgba(255,255,255,0.02);
  border-radius: 4px;
  margin-top: 6px;
}
.match-line__team {
  font-size: 14px;
  font-weight: 500;
  color: rgba(255,255,255,0.8);
  flex: 1;
}
.match-line__team--winner { color: var(--color-white); font-weight: 700; }
.match-line__score {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  color: var(--color-white);
  min-width: 40px;
  text-align: center;
}
.match-line__score--winner { color: var(--color-red); }
.match-line__dash {
  font-size: 16px;
  color: rgba(255,255,255,0.2);
  margin: 0 8px;
}
/* Scheduled-match time pill — centered between team names, reads as a
   time (not a score). Used when a match is upcoming / no score yet. */
.match-line__time {
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: rgba(255,255,255,0.75);
  background: rgba(255,255,255,0.06);
  padding: 6px 12px;
  border-radius: 999px;
  white-space: nowrap;
  flex-shrink: 0;
  min-width: 100px;
  text-align: center;
}
.match-line--scheduled { align-items: center; }
.match-line__label {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: rgba(255,255,255,0.3);
  padding: 10px 14px 4px;
}

/* --- Player Profile --- */
.pp-hero {
  display: flex;
  gap: 28px;
  align-items: flex-start;
  margin-bottom: 32px;
}
.pp-avatar {
  width: 96px;
  height: 96px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 700;
  color: white;
  flex-shrink: 0;
  position: relative;
  overflow: hidden;
}
.pp-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.pp-avatar__number {
  position: absolute;
  bottom: -6px;
  right: -6px;
  background: var(--color-navy-deep);
  border: 2px solid rgba(255,255,255,0.15);
  border-radius: 6px;
  padding: 2px 7px;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  color: var(--color-white);
}
.pp-info { flex: 1; }
.pp-role {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: rgba(255,255,255,0.35);
  margin-bottom: 4px;
}
.pp-name {
  font-family: var(--font-display);
  font-size: 42px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--color-white);
  line-height: 1.05;
  margin-bottom: 10px;
  letter-spacing: 1px;
}
.pp-meta {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 13px;
  color: rgba(255,255,255,0.5);
}
.pp-team-badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 3px;
  font-size: 11px;
  font-weight: 700;
  color: white;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Big stats grid */
.pp-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  gap: 8px;
  margin-bottom: 36px;
}
.pp-stat {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 6px;
  padding: 16px;
  text-align: center;
}
.pp-stat--primary {
  border-color: var(--color-red);
  background: rgba(212,43,43,0.08);
}
.pp-stat__val {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 700;
  color: var(--color-white);
  line-height: 1;
  margin-bottom: 4px;
}
.pp-stat--primary .pp-stat__val { color: var(--color-red); }
.pp-stat__lbl {
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: rgba(255,255,255,0.35);
}

/* Player profile About grid */
.pp-about-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 6px;
  overflow: hidden;
  margin-bottom: 24px;
}
.pp-fact {
  background: rgba(15,26,48,0.6);
  padding: 14px 16px;
}
.pp-fact__label {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: rgba(255,255,255,0.35);
  margin-bottom: 4px;
}
.pp-fact__value {
  font-size: 15px;
  font-weight: 600;
  color: var(--color-white);
}

/* GPR bar chart */
.gpr-bars { margin-bottom: 36px; }
.gpr-bar-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}
.gpr-bar-label {
  width: 70px;
  font-size: 12px;
  color: rgba(255,255,255,0.45);
  text-align: right;
  flex-shrink: 0;
}
.gpr-bar-track {
  flex: 1;
  height: 24px;
  background: rgba(255,255,255,0.04);
  border-radius: 3px;
  overflow: hidden;
}
.gpr-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--color-red), #ff5252);
  border-radius: 3px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding-right: 8px;
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  color: white;
  min-width: 36px;
  transition: width 0.6s ease;
}

/* Stat breakdown grid */
.stat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}
.stat-grid__item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  background: rgba(255,255,255,0.03);
  border-radius: 4px;
}
.stat-grid__label { font-size: 13px; color: rgba(255,255,255,0.5); }
.stat-grid__val {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 700;
  color: var(--color-white);
}

/* --- Sample disclaimer --- */
.lp-disclaimer {
  text-align: center;
  color: rgba(255,255,255,0.2);
  font-size: 12px;
  margin: 48px 0 0;          /* no horizontal auto needed — we override p max-width */
  padding-top: 24px;
  border-top: 1px solid rgba(255,255,255,0.05);
  max-width: none;            /* override base.css `p { max-width: 640px }` */
}

/* --- Match Detail Hero --- */
.match-hero {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin-bottom: 12px;
}
.match-hero__team {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  justify-content: flex-end;
}
.match-hero__team--away {
  justify-content: flex-start;
}
.match-hero__name {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--color-white);
}
.match-hero__scores {
  display: flex;
  align-items: center;
  gap: 12px;
}
.match-hero__score {
  font-family: var(--font-display);
  font-size: 48px;
  font-weight: 700;
  color: rgba(255,255,255,0.4);
  line-height: 1;
}
.match-hero__score--winner {
  color: var(--color-red);
}
.match-hero__vs {
  font-size: 20px;
  color: rgba(255,255,255,0.2);
}

/* --- Team Badge (logo or color dot) ---
   Shape-neutral by default so transparent logos keep their natural outline.
   Circular crop + background are applied only when there's no <img> child
   (i.e. the color-dot fallback). */
.team-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  margin-right: 10px;
  flex-shrink: 0;
  vertical-align: middle;
  overflow: hidden;  /* bound the logo regardless of its native aspect ratio */
}
/* max-width/max-height lets any aspect ratio scale down to fit the box
   without base.css's `img { height: auto }` overriding a fixed height. */
.team-badge img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
}
/* No-logo fallback: make it a color dot */
.team-badge:not(:has(img)) {
  border-radius: 50%;
}
.team-badge--sm { width: 24px; height: 24px; margin-right: 8px; }
.team-badge--lg { width: 48px; height: 48px; margin-right: 12px; }
.team-badge--xl { width: 64px; height: 64px; margin-right: 16px; }

/* --- Player Thumbnail --- */
.player-thumb {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  margin-right: 8px;
  flex-shrink: 0;
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 700;
  color: var(--color-white);
  overflow: hidden;
}
.player-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.player-thumb--sm { width: 22px; height: 22px; font-size: 8px; }

/* --- Match Totals Row --- */
.bc-totals td {
  border-top: 2px solid rgba(255,255,255,0.15);
  padding-top: 10px;
}

/* --- Match Link (listing + events) --- */
a.match-link {
  text-decoration: none;
  color: inherit;
  display: block;
  border-radius: 4px;
  transition: background 0.2s;
}
a.match-link:hover {
  background: rgba(255,255,255,0.04);
}

/* --- Responsive --- */
@media (max-width: 767px) {
  .league-nav__inner { overflow-x: visible; }     /* drawer replaces the scroll row */
  .league-nav__link { display: none; }             /* hide inline links — they live in the drawer now */
  .league-nav__home { display: none; }
  .league-nav__spacer { display: none; }
  .lp { padding: 24px 16px 60px; }
  .lp-title { font-size: 28px; }
  .pp-hero { flex-direction: column; align-items: center; text-align: center; }
  .pp-name { font-size: 28px; }
  .pp-meta { justify-content: center; }
  .pp-stats { grid-template-columns: repeat(3, 1fr); }
  .stat-grid { grid-template-columns: 1fr; }
  .team-grid { grid-template-columns: 1fr; }
  .event-card__top { flex-direction: column; gap: 8px; }
  .match-hero { flex-direction: column; gap: 8px; }
  .match-hero__team { justify-content: center; }
  .match-hero__team--away { justify-content: center; }
  .match-hero__name { font-size: 15px; }
  .match-hero__score { font-size: 36px; }
}

/* ============================================================
   PLAYER PROFILE v2 (.pf-*) — NBA.com-inspired
   ============================================================ */

/* Full-bleed team-color hero that breaks out of .lp container */
.pf-hero {
  position: relative;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  padding: 40px calc(50vw - 50% + 24px) 24px;
  background: var(--color-navy);
  overflow: hidden;
  min-height: 320px;
  display: flex;
  align-items: flex-end;
  gap: 32px;
  margin-bottom: 0;
}
.pf-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0,0,0,0.35) 0%, rgba(0,0,0,0.15) 40%, rgba(0,0,0,0) 70%);
  pointer-events: none;
}
.pf-hero__team-logo {
  position: absolute;
  top: 20px;
  left: 24px;
  width: 72px;
  height: 72px;
  object-fit: contain;
  z-index: 2;
}
.pf-hero__photo {
  position: relative;
  z-index: 2;
  width: 240px;
  height: 280px;
  flex-shrink: 0;
  border-radius: 8px;
  background: rgba(0,0,0,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.pf-hero__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
  align-self: flex-end;
}
.pf-hero__photo-initials {
  font-family: var(--font-display);
  font-size: 96px;
  font-weight: 700;
  color: rgba(255,255,255,0.85);
  line-height: 1;
}
.pf-hero__info {
  position: relative;
  z-index: 2;
  flex: 1;
  min-width: 0;
  padding-bottom: 8px;
}
.pf-hero__role {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: rgba(255,255,255,0.85);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.pf-hero__role-sep { opacity: 0.5; }
.pf-hero__name {
  font-family: var(--font-display);
  font-size: 72px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--color-white);
  line-height: 0.95;
  letter-spacing: 1px;
  margin: 0;
  text-shadow: 0 2px 16px rgba(0,0,0,0.3);
  word-break: break-word;
}
.pf-hero__handle {
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  color: rgba(255,255,255,0.65);
  margin-top: 8px;
  letter-spacing: 0.5px;
}
.pf-hero__actions {
  position: absolute;
  top: 20px;
  right: 24px;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.pf-follow-btn {
  background: rgba(0,0,0,0.35);
  border: 1.5px solid rgba(255,255,255,0.8);
  color: var(--color-white);
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 10px 20px;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
  box-shadow: 0 2px 8px rgba(0,0,0,0.25);
}
.pf-follow-btn:hover {
  background: rgba(255,255,255,0.15);
  border-color: var(--color-white);
}
.pf-follow-btn:disabled { opacity: 0.7; cursor: not-allowed; }
.pf-edit-btn {
  display: inline-block;
  background: var(--color-red);
  color: var(--color-white);
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 10px 18px;
  border-radius: 4px;
  text-decoration: none;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
  transition: background 0.2s, transform 0.15s;
}
.pf-edit-btn:hover {
  background: var(--color-red-hover, #c42d2b);
  transform: translateY(-1px);
}

/* Share button — used on player, team, and event detail pages.
   Outlined style so it sits next to primary actions (Edit / Follow)
   without competing for attention. */
.pf-share-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(0,0,0,0.35);
  border: 1.5px solid rgba(255,255,255,0.7);
  color: var(--color-white);
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 8px 14px;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}
.pf-share-btn:hover {
  background: rgba(255,255,255,0.12);
  border-color: var(--color-white);
}
.pf-share-btn::before {
  content: '';
  display: inline-block;
  width: 12px;
  height: 12px;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M18 16.08c-.76 0-1.44.3-1.96.77L8.91 12.7c.05-.23.09-.46.09-.7s-.04-.47-.09-.7l7.05-4.11c.54.5 1.25.81 2.04.81 1.66 0 3-1.34 3-3s-1.34-3-3-3-3 1.34-3 3c0 .24.04.47.09.7L8.04 9.81C7.5 9.31 6.79 9 6 9c-1.66 0-3 1.34-3 3s1.34 3 3 3c.79 0 1.5-.31 2.04-.81l7.12 4.16c-.05.21-.08.43-.08.65 0 1.61 1.31 2.92 2.92 2.92s2.92-1.31 2.92-2.92-1.31-2.92-2.92-2.92z'/></svg>") no-repeat center / contain;
          mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M18 16.08c-.76 0-1.44.3-1.96.77L8.91 12.7c.05-.23.09-.46.09-.7s-.04-.47-.09-.7l7.05-4.11c.54.5 1.25.81 2.04.81 1.66 0 3-1.34 3-3s-1.34-3-3-3-3 1.34-3 3c0 .24.04.47.09.7L8.04 9.81C7.5 9.31 6.79 9 6 9c-1.66 0-3 1.34-3 3s1.34 3 3 3c.79 0 1.5-.31 2.04-.81l7.12 4.16c-.05.21-.08.43-.08.65 0 1.61 1.31 2.92 2.92 2.92s2.92-1.31 2.92-2.92-1.31-2.92-2.92-2.92z'/></svg>") no-repeat center / contain;
}

/* ============================================================
   INFO STRIP — horizontal labeled-value band
   ============================================================ */
.info-strip {
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  padding: 0 calc(50vw - 50% + 24px);
  background: #0A1524;
  border-top: 1px solid rgba(255,255,255,0.06);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  margin-bottom: 32px;
}
.info-strip__row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.info-strip__row:last-child { border-bottom: none; }
.info-strip__cell {
  padding: 20px 24px;
  border-right: 1px solid rgba(255,255,255,0.06);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.info-strip__cell:last-child { border-right: none; }
.info-strip__label {
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: rgba(255,255,255,0.5);
}
.info-strip__value {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 700;
  color: var(--color-white);
  line-height: 1;
}
.info-strip__value--sm {
  font-size: 16px;
  font-weight: 600;
  font-family: var(--font-body);
}
.info-strip__value--muted { color: rgba(255,255,255,0.4); }

/* ============================================================
   PLAYER PROFILE SUBNAV
   ============================================================ */
.pf-subnav {
  display: flex;
  gap: 0;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  margin-bottom: 24px;
  justify-content: space-between;
  flex-wrap: wrap;
}
.pf-subnav__left, .pf-subnav__right {
  display: flex;
  gap: 0;
}
.pf-subnav__link {
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: rgba(255,255,255,0.5);
  padding: 14px 18px;
  text-decoration: none;
  border-bottom: 2px solid transparent;
  transition: color 0.2s, border-color 0.2s;
  cursor: pointer;
  background: none;
  border-top: none;
  border-left: none;
  border-right: none;
}
.pf-subnav__link:hover { color: var(--color-white); }
.pf-subnav__link.is-active {
  color: var(--color-white);
  border-bottom-color: var(--color-red);
}

/* Bio tab layout */
.pf-bio-header {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: rgba(255,255,255,0.4);
  margin-bottom: 6px;
}
.pf-bio-title {
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--color-white);
  margin-bottom: 18px;
  line-height: 1.05;
}
.pf-bio-body {
  font-size: 16px;
  line-height: 1.75;
  color: rgba(255,255,255,0.75);
  max-width: 720px;
}
.pf-bio-body p + p { margin-top: 14px; }

/* ============================================================
   LEAGUE ROSTER (.roster-*) — players list page
   ============================================================ */
.roster-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 20px;
}
.roster-title {
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--color-white);
  margin: 0;
}
.roster-count {
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1.5px;
  color: rgba(255,255,255,0.5);
  text-transform: uppercase;
}
.roster-filters {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
  padding: 12px 0;
  border-top: 1px solid rgba(255,255,255,0.06);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  margin-bottom: 16px;
}
.roster-select, .roster-search {
  height: 34px;
  padding: 0 12px;
  background: transparent;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 3px;
  color: var(--color-white);
  font-family: var(--font-body);
  font-size: 13px;
}
.roster-select { padding-right: 28px; cursor: pointer; }
.roster-search { min-width: 200px; }
.roster-thumb {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  background: rgba(255,255,255,0.08);
}
.roster-thumb--fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  color: rgba(255,255,255,0.55);
}
.roster-name-cell {
  display: flex;
  align-items: center;
  gap: 10px;
}
.roster-name-stack {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
  min-width: 0;
}
.roster-handle {
  font-size: 11px;
  font-weight: 500;
  color: rgba(255,255,255,0.4);
  margin-top: 1px;
  letter-spacing: 0.2px;
}
.roster-team-link {
  color: #5BC4D4;
  font-weight: 600;
  text-decoration: none;
}
.roster-team-link:hover { text-decoration: underline; }

/* ============================================================
   TEAMS INDEX — logo grid (.logo-*, .conf-*, .div-*)
   ============================================================ */
.conf-block + .conf-block { margin-top: 48px; }
.conf-title {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--color-white);
  padding-bottom: 12px;
  border-bottom: 2px solid var(--color-red);
  margin-bottom: 24px;
}
.div-block + .div-block { margin-top: 32px; }
.div-title {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: rgba(255,255,255,0.5);
  margin-bottom: 16px;
}
.logo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 8px;
}
.logo-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 28px 16px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 6px;
  text-decoration: none;
  transition: transform 0.2s, background 0.2s, border-color 0.2s;
}
.logo-tile:hover {
  transform: translateY(-2px);
  background: rgba(255,255,255,0.06);
  border-color: rgba(255,255,255,0.12);
}
.logo-tile__crest {
  width: 96px;
  height: 96px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
}
.logo-tile__crest img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.logo-tile__crest-fallback {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 40px;
  font-weight: 700;
  color: var(--color-white);
  background: var(--color-navy);
}
.logo-tile__name {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--color-white);
  text-align: center;
  line-height: 1.15;
}

/* ============================================================
   TEAM DETAIL (.th-*) — full-bleed hero + 2-col grid
   ============================================================ */
.th-hero {
  position: relative;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  padding: 56px calc(50vw - 50% + 24px);
  background: var(--color-navy);
  display: flex;
  align-items: center;
  gap: 32px;
  margin-bottom: 32px;
  min-height: 220px;
  overflow: hidden;
}
.th-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 85% 50%, rgba(255,255,255,0.08), transparent 60%);
  pointer-events: none;
}
.th-hero__crest {
  position: relative;
  z-index: 2;
  width: 140px;
  height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.th-hero__crest img { width: 100%; height: 100%; object-fit: contain; }
.th-hero__crest-fallback {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: rgba(255,255,255,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 64px;
  font-weight: 700;
  color: var(--color-white);
}
.th-hero__info { position: relative; z-index: 2; flex: 1; min-width: 0; }
.th-hero__city {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: rgba(255,255,255,0.7);
  margin-bottom: 4px;
}
.th-hero__name {
  font-family: var(--font-display);
  font-size: 56px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--color-white);
  line-height: 0.95;
  letter-spacing: 1px;
  margin: 0 0 12px;
  text-shadow: 0 2px 12px rgba(0,0,0,0.3);
}
.th-hero__record {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: var(--color-white);
  letter-spacing: 1px;
  opacity: 0.9;
}

.th-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 32px;
}
.th-grid__main { min-width: 0; }
.th-grid__side { min-width: 0; }
.th-widget {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 6px;
  padding: 18px;
  margin-bottom: 16px;
}
.th-widget__title {
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: rgba(255,255,255,0.5);
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

/* ============================================================
   ADMIN TABS
   ============================================================ */
.admin-tabs {
  display: flex;
  gap: 0;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  margin-bottom: 32px;
  overflow-x: auto;
  scrollbar-width: none;
}
.admin-tabs::-webkit-scrollbar { display: none; }
.admin-tab {
  background: transparent;
  border: none;
  border-bottom: 3px solid transparent;
  color: rgba(255,255,255,0.5);
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  padding: 14px 20px;
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.15s, border-color 0.15s;
}
.admin-tab:hover { color: rgba(255,255,255,0.85); }
.admin-tab.is-active {
  color: var(--color-white);
  border-bottom-color: var(--color-red);
}

.admin-quick-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin-bottom: 24px;
}
.admin-quick-card {
  padding: 20px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 6px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.admin-quick-card__value {
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 700;
  color: var(--color-white);
  line-height: 1;
}
.admin-quick-card__label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: rgba(255,255,255,0.4);
}

/* ============================================================
   NAV USER AVATAR + DROPDOWN
   ============================================================ */
.nav-user {
  position: relative;
  display: inline-flex;
  align-items: center;
}
.nav-user__btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px 6px 6px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 24px;
  color: rgba(255,255,255,0.7);
  font-family: var(--font-body);
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.nav-user__btn:hover {
  background: rgba(255,255,255,0.05);
  border-color: rgba(255,255,255,0.08);
}
.nav-user__btn[aria-expanded="true"] {
  background: rgba(255,255,255,0.06);
  border-color: rgba(255,255,255,0.1);
}
.nav-user__caret {
  font-size: 10px;
  color: rgba(255,255,255,0.5);
}
.nav-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
  overflow: hidden;
  flex-shrink: 0;
}
.nav-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.nav-avatar__initials {
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  color: rgba(255,255,255,0.75);
  letter-spacing: 0.5px;
}

.nav-dd {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 260px;
  background: #0F1B30;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 6px;
  box-shadow: 0 12px 32px rgba(0,0,0,0.45);
  z-index: 1000;
  overflow: hidden;
}

/* ------------------------------------------------------------
   Mobile hamburger for league-nav (injected via nav-user.js).
   Desktop: hidden entirely. Mobile: replaces the inline text-link
   row with a hamburger + drop-down drawer.
   ------------------------------------------------------------ */
/* Admin-only UI (Edit buttons, admin nav link, etc.) — hidden by default,
   revealed once nav-user.js confirms the visitor has admin-tier access.
   Prevents flash-of-Edit-button for regular fans/players. */
.admin-only { display: none !important; }
body[data-role="admin"] .admin-only,
body[data-role="commissioner"] .admin-only { display: initial !important; }
/* For flex/inline-flex contexts, reset display correctly when revealed */
body[data-role="admin"] a.admin-only,
body[data-role="commissioner"] a.admin-only { display: inline-block !important; }

.league-nav__toggle {
  display: none;
  background: none;
  border: none;
  padding: 10px 8px;
  margin-right: 4px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.league-nav__toggle-bar {
  display: block;
  width: 22px;
  height: 2px;
  background: rgba(255,255,255,0.85);
  border-radius: 2px;
  margin: 4px 0;
  transition: transform 0.25s ease, opacity 0.25s ease;
  transform-origin: center;
}
.league-nav__toggle.is-open .league-nav__toggle-bar:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.league-nav__toggle.is-open .league-nav__toggle-bar:nth-child(2) { opacity: 0; }
.league-nav__toggle.is-open .league-nav__toggle-bar:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

.league-nav__drawer {
  display: none;     /* desktop — hidden entirely */
}
.league-nav__drawer-link {
  display: block;
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: rgba(255, 255, 255, 0.8);
  padding: 14px 6px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  text-decoration: none;
}
.league-nav__drawer-link:last-child { border-bottom: none; }
.league-nav__drawer-link.is-active { color: var(--color-red); }
.league-nav__drawer-link:hover { color: var(--color-white); }

@media (max-width: 767px) {
  .league-nav__toggle { display: block; }
  .league-nav__drawer {
    display: block;
    position: fixed;
    top: 56px;
    left: 0;
    right: 0;
    background: rgba(8, 14, 26, 0.98);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding: 8px 20px 16px;
    z-index: 100;
    box-shadow: 0 12px 32px rgba(0,0,0,0.4);
  }
  .league-nav__drawer[hidden] { display: none; }
}

/* Mobile: .league-nav__inner is overflow-x:auto (horizontal scroll for
   nav links) which also clips overflow-y. Anything inside it that tries
   to render a popover (like the avatar dropdown) gets hidden, and iOS
   has quirks with tap events on sticky-positioned elements inside
   horizontally-scrollable parents. Pin the avatar button AND its
   dropdown to the viewport so they escape the scroll container entirely. */
@media (max-width: 767px) {
  .nav-user {
    position: fixed;
    /* Vertically center inside the 56px nav bar. Button is ~46px tall
       with border + padding, so (56 - 46) / 2 = 5px from the top. */
    top: 5px;
    right: 12px;
    z-index: 101;   /* above .league-nav (z-index 100) */
    /* touch-action manipulation removes the old 300ms tap delay on older
       iOS and ensures the tap is handled as a click without ceremony */
    touch-action: manipulation;
  }
  .nav-user__btn {
    background: rgba(15, 27, 48, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
  }
  .nav-dd {
    position: fixed;
    top: 58px;   /* sits just below the 56px nav bar */
    right: 12px;
    left: auto;
    max-width: calc(100vw - 24px);
    min-width: 240px;
  }
}
.nav-dd[hidden] { display: none; }
.nav-dd__header {
  padding: 16px 18px 14px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.nav-dd__name {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  color: var(--color-white);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.nav-dd__email {
  font-size: 12px;
  color: rgba(255,255,255,0.45);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.nav-dd__roles {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  margin-top: 8px;
}
.nav-dd__role-badge {
  font-family: var(--font-display);
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 2px 6px;
  border-radius: 2px;
  background: rgba(255,255,255,0.08);
  color: rgba(255,255,255,0.65);
}
.nav-dd__menu { padding: 6px 0; }
.nav-dd__footer {
  border-top: 1px solid rgba(255,255,255,0.06);
  padding: 6px 0;
}
.nav-dd__item {
  display: block;
  width: 100%;
  padding: 10px 18px;
  font-family: var(--font-body);
  font-size: 13px;
  color: rgba(255,255,255,0.75);
  text-decoration: none;
  background: transparent;
  border: none;
  text-align: left;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.nav-dd__item:hover {
  background: rgba(255,255,255,0.06);
  color: var(--color-white);
}
.nav-dd__item--accent {
  color: var(--color-red);
  font-weight: 600;
}
.nav-dd__item--accent:hover {
  color: var(--color-red);
}
.nav-dd__signout {
  color: rgba(255,255,255,0.55);
}
.nav-dd__signout:hover {
  color: var(--color-red);
  background: rgba(212,43,43,0.08);
}

@media (max-width: 520px) {
  .nav-dd {
    right: -16px;
    min-width: 240px;
  }
}

/* ============================================================
   BACK NAV BAR — full-bleed container that holds .back-btn
   ============================================================ */
.back-nav-bar {
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  margin-top: -32px; /* cancel .lp top padding so back button sits near nav */
  padding: 16px 24px;
  margin-bottom: 16px;
}

/* ============================================================
   BACK BUTTON — shared
   ============================================================ */
.back-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 4px;
  color: rgba(255,255,255,0.75);
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  text-decoration: none;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}
.back-btn:hover {
  background: rgba(255,255,255,0.12);
  color: var(--color-white);
  border-color: rgba(255,255,255,0.25);
}
.back-btn__arrow { font-size: 14px; line-height: 1; }

/* ============================================================
   EMPTY STATE BLOCK — shared
   ============================================================ */
.empty-block {
  text-align: center;
  padding: 36px 24px;
  background: rgba(255,255,255,0.02);
  border: 1px dashed rgba(255,255,255,0.1);
  border-radius: 6px;
  color: rgba(255,255,255,0.45);
}
.empty-block__title {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: rgba(255,255,255,0.65);
  margin-bottom: 6px;
}
.empty-block__body {
  font-size: 13px;
  line-height: 1.5;
  max-width: 380px;
  margin: 0 auto;
}

/* ============================================================
   MOBILE — v2 components
   ============================================================ */
@media (max-width: 900px) {
  .th-grid { grid-template-columns: 1fr; }
  .th-hero { flex-direction: column; text-align: center; padding: 40px 24px; gap: 20px; }
  .th-hero__name { font-size: 40px; }
  .th-hero__info { text-align: center; }
}
@media (max-width: 720px) {
  .pf-hero {
    flex-direction: column;
    align-items: flex-start;
    min-height: 0;
    padding: 20px 20px 20px;  /* no top reserve — team logo is in-flow now */
    gap: 14px;
  }
  /* Team logo: out of absolute positioning, sits as a small chip at the top
     of the column above the photo, matching NBA.com's mobile hero pattern.
     Prevents the photo from colliding with the logo. */
  .pf-hero__team-logo {
    position: static;
    width: 44px;
    height: 44px;
    top: auto;
    left: auto;
  }
  .pf-hero__photo { width: 140px; height: 170px; }
  .pf-hero__photo-initials { font-size: 56px; padding-bottom: 16px; }
  .pf-hero__name { font-size: 40px; }
  .pf-hero__actions { top: 16px; right: 16px; }
  .info-strip__cell { padding: 14px 16px; }
  .info-strip__value { font-size: 22px; }
  .pf-subnav { overflow-x: auto; flex-wrap: nowrap; }
  .pf-subnav__link { padding: 12px 14px; white-space: nowrap; }
}
@media (max-width: 520px) {
  .logo-grid { grid-template-columns: repeat(2, 1fr); }
  .logo-tile__crest, .logo-tile__crest-fallback { width: 72px; height: 72px; }
  .logo-tile__crest-fallback { font-size: 28px; }
}

/* ============================================================
   SKELETONS — shimmer placeholders while real data loads
   Usage: add a .sk-* element wherever the real thing will land;
   when data arrives, replace the element. The shimmer is driven
   by a single keyframe so dozens of skeletons stay in sync.
   ============================================================ */
@keyframes sk-shimmer {
  0%   { background-position: -400px 0; }
  100% { background-position: 400px 0; }
}
.sk,
.sk-line,
.sk-circle,
.sk-card,
.sk-rect {
  background: linear-gradient(
    90deg,
    rgba(255,255,255,0.04) 0%,
    rgba(255,255,255,0.09) 40%,
    rgba(255,255,255,0.04) 80%
  );
  background-size: 800px 100%;
  animation: sk-shimmer 1.2s linear infinite;
  border-radius: 4px;
  will-change: background-position;
}
.sk-line {
  height: 14px;
  margin: 6px 0;
  border-radius: 3px;
}
.sk-line--short { width: 30%; }
.sk-line--medium { width: 55%; }
.sk-line--long { width: 85%; }
.sk-line--title { height: 20px; width: 40%; margin-bottom: 12px; }
.sk-circle {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  flex-shrink: 0;
}
.sk-circle--lg { width: 64px; height: 64px; }
.sk-rect {
  width: 100%;
  height: 80px;
}
.sk-card {
  height: 96px;
  margin-bottom: 8px;
  border-radius: 6px;
}
.sk-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}
.sk-row__stack {
  flex: 1;
  min-width: 0;
}
.sk-tile {
  aspect-ratio: 1 / 1;
  border-radius: 8px;
}
/* Respect reduced-motion — keep the gradient, drop the shimmer */
@media (prefers-reduced-motion: reduce) {
  .sk, .sk-line, .sk-circle, .sk-card, .sk-rect { animation: none; }
}

/* ============================================================
   Shared modal (.ngl-modal) — used on /admin and /account.
   Add .is-open to reveal. Pairs with .ngl-modal__dialog / __header
   / __title / __close / __body / __intro.
   ============================================================ */
.ngl-modal {
  position: fixed; inset: 0; z-index: 1000;
  background: rgba(5, 10, 22, 0.75);
  display: none; align-items: flex-start; justify-content: center;
  padding: 64px 20px 20px; overflow-y: auto;
  -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
}
.ngl-modal.is-open { display: flex; }
.ngl-modal__dialog {
  background: #0f1a2e;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  width: 100%; max-width: 520px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
  animation: nglModalIn 160ms ease-out;
}
@keyframes nglModalIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}
.ngl-modal__header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 22px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.ngl-modal__title {
  font-family: var(--font-display);
  font-size: 16px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 1.5px;
  color: var(--color-white); margin: 0;
}
.ngl-modal__close {
  background: none; border: none; color: rgba(255,255,255,0.5);
  font-size: 24px; line-height: 1; cursor: pointer; padding: 4px 8px;
  border-radius: 4px;
}
.ngl-modal__close:hover { color: var(--color-white); background: rgba(255,255,255,0.05); }
.ngl-modal__body { padding: 22px; }
.ngl-modal__body p.ngl-modal__intro {
  font-size: 13px; color: rgba(255,255,255,0.5);
  margin: 0 0 16px; line-height: 1.5;
}

/* ============================================================
   MOBILE RESPONSIVE PASS — tablet + phone refinements
   Complements the existing breakpoints above. Targets:
   - 767px: tablet portrait / small laptop
   - 520px: phone landscape / small tablet
   - 420px: typical phone portrait (iPhone 13/14 width)
   - 360px: narrow phones (iPhone SE, small Android)
   ============================================================ */

/* Tables that risk overflow at narrow widths — let them scroll horizontally
   by wrapping in a scroll-x container. .bc-table-wrap can be used in HTML;
   we also auto-scroll any .bc-table that's a direct child of a scrollable
   surface on phone widths. */
.bc-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}
.bc-table-wrap .bc-table { min-width: 560px; }

/* Any element that directly contains a .bc-table gets horizontal scroll
   at narrow widths — avoids touching every call site. */
@media (max-width: 640px) {
  *:has(> .bc-table) {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
}

@media (max-width: 640px) {
  /* Nav: tighter spacing, smaller logo, hide the home URL */
  .league-nav__inner { padding: 0 12px; gap: 4px; }
  .league-nav__logo { height: 22px; margin-right: 8px; }
  .league-nav__link { padding: 14px 8px; font-size: 11px; letter-spacing: 1px; }
  .league-nav__home { display: none; }

  /* Page container: less horizontal padding */
  .lp { padding: 20px 14px 56px; }
  .lp-title { font-size: 26px; }

  /* bc-table: compress, and fall back to horizontal scroll at the element
     level so overflow is contained rather than blowing out the page. */
  .bc-table { font-size: 12px; min-width: 560px; }
  .bc-table th, .bc-table td { padding: 8px 6px; }

  /* Match line: compress so teams fit at 380px */
  .match-line { padding: 8px 10px; }
  .match-line__team { font-size: 12px; min-width: 0; }
  .match-line__team span:not(.team-badge) { overflow: hidden; text-overflow: ellipsis; }
  .match-line__score { font-size: 18px; min-width: 28px; }
  .match-line__dash { margin: 0 4px; font-size: 13px; }

  /* Event card */
  .event-card__body { padding: 16px 14px; }
  .event-card__name { font-size: 17px; }
  .event-card__meta { flex-wrap: wrap; gap: 6px; font-size: 11px; }

  /* Roster list head + filters stack */
  .roster-head { flex-direction: column; align-items: flex-start; gap: 6px; }
  .roster-filters { gap: 6px; }
  .roster-search, .roster-select { font-size: 12px; height: 34px; }
  .roster-search { min-width: 140px; flex: 1; }

  /* Logo tiles grid — 2 columns already drops at 520px; tile sizing tightens too */
  .logo-tile__name { font-size: 11px; letter-spacing: 0.5px; }

  /* Info strip — force a tighter 2-col at narrow widths */
  .info-strip__row { grid-template-columns: 1fr 1fr !important; }
  .info-strip__cell { padding: 12px 14px; }
  .info-strip__value { font-size: 20px; }
  .info-strip__value--sm { font-size: 15px; }

  /* Player profile v2 hero */
  .pf-hero { padding: 16px 16px 20px; gap: 12px; }  /* team logo is in-flow → no top reserve */
  .pf-hero__team-logo { width: 40px; height: 40px; }
  .pf-hero__photo { width: 120px; height: 144px; }
  .pf-hero__name { font-size: 32px; }
  .pf-hero__actions { top: 12px; right: 12px; }
  .pf-edit-btn, .pf-follow-btn { font-size: 10px; padding: 8px 14px; }

  /* Team hero */
  .th-hero { padding: 32px 16px; gap: 16px; }
  .th-hero__name { font-size: 30px; letter-spacing: 0.5px; }
  .th-hero__city { font-size: 12px; }
  .th-hero__crest, .th-hero__crest-fallback { width: 80px; height: 80px; }

  /* Admin tabs + sections */
  .admin-tab { padding: 12px 12px; font-size: 11px; letter-spacing: 1px; }
  .admin-section { padding: 16px; }
  .admin-quick-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .admin-quick-card { padding: 16px 14px; }
  .admin-quick-card__value { font-size: 28px; }

  /* Modal: reduce outer padding so dialog gets the whole viewport */
  .ngl-modal { padding: 48px 12px 12px; }
  .ngl-modal__dialog { max-width: 100%; }
  .ngl-modal__header { padding: 14px 16px; }
  .ngl-modal__body { padding: 16px; }

  /* pf-subnav: already scrolls on 720px breakpoint; tighten further */
  .pf-subnav__link { font-size: 11px; padding: 10px 12px; }
}

@media (max-width: 420px) {
  /* Phone portrait — tighten titles and force single column on any remaining 2-col layouts */
  .lp-title { font-size: 22px; letter-spacing: 0.5px; }

  /* Admin quick stats: single column if 2 doesn't fit */
  .admin-quick-grid { grid-template-columns: 1fr; }

  /* Player profile: stacks with more vertical room */
  .pf-hero__name { font-size: 28px; }
  .pf-hero__photo { width: 104px; height: 124px; }

  /* Team hero */
  .th-hero__name { font-size: 24px; }
  .th-hero__crest, .th-hero__crest-fallback { width: 68px; height: 68px; }

  /* Match line — even tighter */
  .match-line { padding: 6px 8px; gap: 4px; }
  .match-line__team { font-size: 11px; }
  .match-line__score { font-size: 16px; min-width: 22px; }

  /* Nav: only 5-6 items fit comfortably. Scroll is fine, just tighter */
  .league-nav__link { padding: 14px 6px; font-size: 10px; }

  /* Info strip: allow single column if 2 still too tight */
  .info-strip__value { font-size: 18px; }

  /* Logo tile: stacked name under smaller crest */
  .logo-tile__crest, .logo-tile__crest-fallback { width: 60px; height: 60px; }
  .logo-tile__crest-fallback { font-size: 22px; }

  /* Roster filters: filters full-width on separate lines */
  .roster-filters { flex-direction: column; align-items: stretch; }
  .roster-search, .roster-select { width: 100%; }
}

/* ============================================================
   League Footer — shared across every league page
   ------------------------------------------------------------
   Provides the secondary surface for Resources / Legal / Social
   links so the top nav can stay at 5 tabs without losing
   discoverability of non-transactional content (Rules, About,
   FAQ, Contact, etc).
   ============================================================ */
.league-footer {
  margin-top: 72px;
  padding: 48px 24px 32px;
  background: #0A1628;
  border-top: 1px solid rgba(255,255,255,0.06);
  color: rgba(255,255,255,0.65);
  font-size: 13px;
  line-height: 1.6;
}
.league-footer__inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr 1fr;
  gap: 40px;
  align-items: start;
}
.league-footer__brand {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.league-footer__logo {
  height: 44px;
  width: auto;
  object-fit: contain;
  margin-bottom: 4px;
}
.league-footer__tag {
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: rgba(255,255,255,0.4);
}
.league-footer__blurb {
  font-size: 12px;
  color: rgba(255,255,255,0.45);
  max-width: 260px;
  line-height: 1.55;
}
.league-footer__col-title {
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--color-white);
  margin-bottom: 14px;
}
.league-footer__list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.league-footer__link {
  color: rgba(255,255,255,0.55);
  text-decoration: none;
  font-size: 13px;
  transition: color 0.15s ease;
}
.league-footer__link:hover {
  color: var(--color-white);
}
.league-footer__link--soon {
  color: rgba(255,255,255,0.25);
  cursor: not-allowed;
  font-size: 12px;
}
.league-footer__link--soon:hover {
  color: rgba(255,255,255,0.25);
}
.league-footer__soon-tag {
  font-size: 9px;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: rgba(255,255,255,0.3);
  margin-left: 4px;
  font-weight: 700;
}
.league-footer__bottom {
  max-width: 1200px;
  margin: 40px auto 0;
  padding-top: 24px;
  border-top: 1px solid rgba(255,255,255,0.06);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 11px;
  color: rgba(255,255,255,0.35);
}
.league-footer__home-link {
  color: rgba(255,255,255,0.5);
  text-decoration: none;
  letter-spacing: 1px;
  font-weight: 600;
}
.league-footer__home-link:hover {
  color: var(--color-white);
}

/* Mobile: stack to two columns, then one */
@media (max-width: 900px) {
  .league-footer__inner {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
  .league-footer__brand {
    grid-column: 1 / -1;
  }
}
@media (max-width: 520px) {
  .league-footer {
    padding: 40px 20px 24px;
  }
  .league-footer__inner {
    grid-template-columns: 1fr;
    gap: 28px;
  }
  .league-footer__bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
}
