:root {
  --bg-deep: #071226;
  --bg-navy: #0c1f3f;
  --bg-teal: #0f7b7a;
  --accent-mint: #24e5b5;
  --accent-cyan: #38bdf8;
  --accent-lav: #a78bfa;
  --accent-gold: #f5b942;
  --accent-red: #f43f5e;
  --text-main: #f4f8ff;
  --text-soft: #c3d6ec;
  --text-muted: #7f9bb8;
  --hairline: rgba(255, 255, 255, 0.13);
  --glass-bg: rgba(9, 23, 46, 0.56);
  --glass-hover: rgba(255, 255, 255, 0.08);
  --radius: 10px;
  --font-main: 'Segoe UI', -apple-system, BlinkMacSystemFont, Roboto, Helvetica, Arial, sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  height: 100%;
  background: var(--bg-deep);
  color: var(--text-main);
  font-family: var(--font-main);
  font-size: 14px;
  line-height: 1.45;
  overflow-x: hidden;
}

.hidden { display: none !important; }
.muted { color: var(--text-muted); }
.text-mint { color: var(--accent-mint); }
.text-gold { color: var(--accent-gold); }
.text-red { color: var(--accent-red); }
.text-cyan { color: var(--accent-cyan); }
.text-right { text-align: right; }
.mono { font-variant-numeric: tabular-nums; }

/* === DEEP NAVY TO EMERALD-TEAL BACKDROP WITH FAINT GEOMETRIC PATTERN === */
.bg-backdrop {
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(ellipse 75% 65% at 72% 18%, rgba(20, 178, 166, 0.48), transparent 65%),
    radial-gradient(ellipse 65% 60% at 15% 88%, rgba(30, 58, 138, 0.55), transparent 65%),
    linear-gradient(145deg, #061022 0%, #0b2242 48%, #0a1834 100%);
}
.bg-backdrop::after {
  content: '';
  position: absolute;
  inset: 0;
  opacity: 0.09;
  background-image:
    linear-gradient(30deg, rgba(255,255,255,0.22) 1px, transparent 1px),
    linear-gradient(150deg, rgba(255,255,255,0.18) 1px, transparent 1px);
  background-size: 90px 156px;
}

/* === BOOT / NEW CAREER SCREEN === */
.boot-screen {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
}
.boot-card {
  width: 100%;
  max-width: 960px;
  background: rgba(8, 20, 42, 0.72);
  backdrop-filter: blur(18px);
  border: 1px solid var(--hairline);
  border-radius: 16px;
  padding: 28px;
}
.boot-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--hairline);
  margin-bottom: 22px;
}
.boot-title-group { display: flex; align-items: center; gap: 14px; }
.boot-title-group h1 { font-size: 24px; letter-spacing: 0.8px; font-weight: 800; }

.league-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}
.pill-btn {
  background: rgba(255,255,255,0.06);
  color: var(--text-soft);
  border: 1px solid var(--hairline);
  padding: 7px 14px;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 600;
  font-size: 12px;
  transition: 0.16s;
}
.pill-btn.active, .pill-btn:hover {
  background: rgba(36, 229, 181, 0.18);
  border-color: var(--accent-mint);
  color: #fff;
}

.club-select-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(205px, 1fr));
  gap: 10px;
  max-height: 360px;
  overflow-y: auto;
  padding-right: 4px;
}
.club-pick {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--hairline);
  border-radius: 10px;
  cursor: pointer;
  transition: 0.15s;
}
.club-pick:hover { background: rgba(255,255,255,0.09); }
.club-pick.selected {
  border-color: var(--accent-mint);
  background: rgba(36, 229, 181, 0.14);
}
.club-swatch {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 11px;
  border: 2px solid rgba(255,255,255,0.35);
}

/* === APP SHELL & TOP CONSOLE RIBBON === */
.app-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.top-ribbon {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 24px;
  border-bottom: 1px solid var(--hairline);
  background: rgba(7, 18, 38, 0.55);
  backdrop-filter: blur(14px);
  position: sticky;
  top: 0;
  z-index: 40;
}
.ribbon-left, .ribbon-right {
  display: flex;
  align-items: center;
  gap: 16px;
}
.mc-emblem {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.85);
  display: grid;
  place-items: center;
  font-weight: 900;
  font-size: 12px;
  letter-spacing: 0.5px;
  flex-shrink: 0;
}
.mc-emblem.lg { width: 46px; height: 46px; font-size: 16px; border-color: var(--accent-mint); }

.brand-breadcrumb { display: flex; align-items: center; gap: 8px; }
.brand-fc { font-weight: 900; letter-spacing: 1px; font-size: 15px; }
.brand-fc small { color: var(--accent-mint); font-size: 11px; }
.crumb-sep { color: var(--text-muted); }
.crumb-title { font-weight: 700; color: var(--text-soft); }

.main-tabs { display: flex; gap: 4px; margin-left: 10px; }
.main-tab {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-weight: 700;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  padding: 7px 12px;
  border-radius: 6px;
  cursor: pointer;
  transition: 0.15s;
}
.main-tab:hover { color: #fff; background: rgba(255,255,255,0.06); }
.main-tab.active {
  color: #fff;
  background: rgba(36, 229, 181, 0.16);
  box-shadow: inset 0 -2px 0 var(--accent-mint);
}

.club-chip { display: flex; align-items: center; gap: 8px; }
.club-dot { width: 12px; height: 12px; border-radius: 50%; border: 2px solid #fff; }
.club-chip-text { display: flex; flex-direction: column; line-height: 1.15; }
.club-chip-text strong { font-size: 12px; }
.club-chip-text span { font-size: 11px; color: var(--accent-mint); font-weight: 700; }

.date-chip {
  display: flex;
  flex-direction: column;
  text-align: right;
  line-height: 1.15;
  padding-left: 12px;
  border-left: 1px solid var(--hairline);
}
.date-chip span { font-size: 10px; color: var(--text-muted); }
.date-chip strong { font-size: 12px; letter-spacing: 0.4px; }

.btn-advance {
  background: linear-gradient(95deg, #24e5b5, #22c1dc);
  color: #051624;
  border: none;
  font-weight: 900;
  font-size: 12px;
  letter-spacing: 0.8px;
  padding: 9px 18px;
  border-radius: 6px;
  cursor: pointer;
  transition: 0.15s;
  white-space: nowrap;
}
.btn-advance:hover { filter: brightness(1.08); transform: translateY(-1px); }
.btn-advance.matchday {
  background: linear-gradient(95deg, #f5b942, #fb7185);
  color: #16090c;
}

/* === BORDERLESS SUB-RIBBON === */
.sub-ribbon {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 10px 24px;
  border-bottom: 1px solid var(--hairline);
  background: rgba(7, 18, 38, 0.25);
  overflow-x: auto;
}
.sub-tab {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 600;
  padding: 4px 2px;
  cursor: pointer;
  position: relative;
  white-space: nowrap;
}
.sub-tab:hover { color: #fff; }
.sub-tab.active { color: #fff; font-weight: 700; }
.sub-tab.active::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: -11px;
  height: 2px;
  background: var(--accent-mint);
}

/* === MAIN VIEWPORT === */
.main-view {
  flex: 1;
  width: 100%;
  max-width: 1340px;
  margin: 0 auto;
  padding: 22px 24px 86px;
}

/* === COMMON BORDERLESS PANELS & BUTTONS === */
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--hairline);
  margin-bottom: 18px;
}
.section-head h2 {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.glass-panel {
  background: var(--glass-bg);
  border: 1px solid var(--hairline);
  border-radius: var(--radius);
  padding: 16px;
  backdrop-filter: blur(10px);
}
.borderless-block {
  padding: 14px 0;
  border-bottom: 1px solid var(--hairline);
}

.btn {
  background: rgba(255,255,255,0.09);
  color: #fff;
  border: 1px solid var(--hairline);
  padding: 8px 14px;
  border-radius: 6px;
  font-weight: 700;
  font-size: 12px;
  cursor: pointer;
  transition: 0.15s;
}
.btn:hover { background: rgba(255,255,255,0.16); }
.btn:disabled { opacity: 0.45; cursor: not-allowed; }
.btn-primary {
  background: linear-gradient(95deg, #24e5b5, #1cb8c9);
  color: #041824;
  border: none;
}
.btn-danger { background: rgba(244, 63, 94, 0.22); border-color: rgba(244, 63, 94, 0.6); color: #fecdd3; }
/* Iconic light-blue to lavender Show Actions button from FC 27 UI */
.btn-actions-grad {
  width: 100%;
  background: linear-gradient(90deg, #9ce6f5 0%, #c6b7f7 100%);
  color: #0b1630;
  border: none;
  padding: 10px 16px;
  border-radius: 4px;
  font-weight: 800;
  font-size: 13px;
  cursor: pointer;
  transition: 0.15s;
}
.btn-actions-grad:hover { filter: brightness(1.06); }

.input, .select {
  background: rgba(6, 16, 34, 0.72);
  color: #fff;
  border: 1px solid var(--hairline);
  padding: 8px 11px;
  border-radius: 6px;
  font-size: 13px;
  outline: none;
}
.input:focus, .select:focus { border-color: var(--accent-mint); }

/* === FC 27 BORDERLESS PLAYER PROFILE SCREEN === */
.profile-layout {
  display: grid;
  grid-template-columns: 270px 1fr;
  gap: 32px;
  align-items: start;
}
.profile-hero {
  position: relative;
  padding-top: 10px;
}
.jersey-watermark {
  position: absolute;
  top: 120px;
  left: -4px;
  font-size: 72px;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1;
  pointer-events: none;
  letter-spacing: -2px;
}
.avatar-stage {
  height: 220px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  margin-bottom: 14px;
  position: relative;
}
.jersey-svg { width: 175px; height: 185px; filter: drop-shadow(0 16px 26px rgba(0,0,0,0.45)); }
.hero-bio {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 18px;
}
.bio-item small { display: block; color: var(--text-muted); font-size: 11px; }
.bio-item strong { font-size: 13px; font-weight: 700; }

.profile-header {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 16px;
}
.ovr-diamond {
  width: 62px;
  height: 62px;
  display: grid;
  place-items: center;
  position: relative;
  flex-shrink: 0;
}
.ovr-diamond::before {
  content: '';
  position: absolute;
  inset: 6px;
  border: 2px solid rgba(255,255,255,0.65);
  transform: rotate(45deg);
  border-radius: 4px;
  background: rgba(255,255,255,0.06);
}
.ovr-diamond span {
  position: relative;
  font-size: 26px;
  font-weight: 900;
  z-index: 1;
}
.profile-identity .pos-line {
  font-size: 12px;
  color: var(--text-soft);
  font-weight: 700;
  letter-spacing: 0.8px;
}
.profile-identity h1 {
  font-size: 28px;
  font-weight: 900;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  line-height: 1.1;
  margin: 2px 0 6px;
}
.role-pills { display: flex; flex-wrap: wrap; gap: 6px; }
.role-pill {
  font-size: 11px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 4px;
  background: rgba(36, 229, 181, 0.16);
  border: 1px solid rgba(36, 229, 181, 0.45);
  color: var(--accent-mint);
}
.growth-tag {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 4px;
  background: rgba(167, 139, 250, 0.18);
  border: 1px solid rgba(167, 139, 250, 0.45);
  color: #ddd6fe;
}

.status-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  padding: 14px 0;
  border-top: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
  margin-bottom: 18px;
}
.status-cell small { display: block; color: var(--text-muted); font-size: 11px; margin-bottom: 2px; }
.status-cell strong { font-size: 13px; font-weight: 800; letter-spacing: 0.5px; }

.data-grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.data-col { display: flex; flex-direction: column; gap: 16px; }
.kv-item small { display: block; color: var(--text-muted); font-size: 11px; margin-bottom: 2px; }
.kv-item strong { font-size: 14px; font-weight: 800; }

.attr-list { display: flex; flex-direction: column; gap: 8px; }
.attr-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  padding-bottom: 4px;
}
.attr-val { font-weight: 900; font-size: 15px; }
.stars { color: var(--accent-mint); letter-spacing: 2px; font-size: 14px; }
.stars .dim { color: rgba(255,255,255,0.22); }

/* === CENTRAL HUB GRID === */
.hub-grid {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: 20px;
}
.next-match-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 18px;
  background: linear-gradient(125deg, rgba(16, 125, 122, 0.34), rgba(9, 23, 46, 0.72));
  border: 1px solid rgba(36, 229, 181, 0.32);
  border-radius: 12px;
  margin-bottom: 16px;
}
.match-team-col { display: flex; flex-direction: column; align-items: center; gap: 6px; flex: 1; text-align: center; }
.match-vs { font-size: 12px; font-weight: 900; color: var(--accent-mint); text-align: center; }

/* === CLEAN DATA TABLES (CM 17 ERGONOMICS) === */
.table-wrap { overflow-x: auto; }
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.data-table th {
  text-align: left;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: var(--text-muted);
  padding: 10px 10px;
  border-bottom: 1px solid var(--hairline);
  white-space: nowrap;
}
.data-table td {
  padding: 10px 10px;
  border-bottom: 1px solid rgba(255,255,255,0.07);
  white-space: nowrap;
}
.data-table tr.clickable:hover { background: var(--glass-hover); cursor: pointer; }
.data-table tr.user-row { background: rgba(36, 229, 181, 0.12); }

.pos-badge {
  display: inline-block;
  min-width: 34px;
  text-align: center;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 800;
}
.pos-GK { background: rgba(245, 185, 66, 0.22); color: #fde68a; }
.pos-DEF { background: rgba(56, 189, 248, 0.22); color: #bae6fd; }
.pos-MID { background: rgba(36, 229, 181, 0.22); color: #a7f3d0; }
.pos-ATT { background: rgba(244, 63, 94, 0.24); color: #fecdd3; }

/* === CHAMP MAN 17 TACTICAL PITCH & FC IQ === */
.tactics-grid {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: 20px;
  align-items: start;
}
.pitch-board {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 5;
  max-height: 600px;
  border-radius: 12px;
  border: 2px solid rgba(255,255,255,0.28);
  background:
    repeating-linear-gradient(
      0deg,
      rgba(16, 118, 76, 0.88) 0%,
      rgba(16, 118, 76, 0.88) 10%,
      rgba(14, 102, 66, 0.88) 10%,
      rgba(14, 102, 66, 0.88) 20%
    );
  overflow: hidden;
  box-shadow: inset 0 0 40px rgba(0,0,0,0.35);
}
.pitch-lines { position: absolute; inset: 0; pointer-events: none; }
.pitch-node {
  position: absolute;
  transform: translate(-50%, -50%);
  width: 82px;
  text-align: center;
  cursor: pointer;
  user-select: none;
  transition: transform 0.14s;
}
.pitch-node:hover { transform: translate(-50%, -50%) scale(1.06); }
.pitch-node.selected .node-circle {
  box-shadow: 0 0 0 3px var(--accent-mint), 0 0 18px var(--accent-mint);
}
.node-circle {
  width: 40px;
  height: 40px;
  margin: 0 auto 3px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 900;
  font-size: 14px;
  border: 2px solid #fff;
  box-shadow: 0 4px 10px rgba(0,0,0,0.4);
}
.node-name {
  background: rgba(6, 16, 34, 0.84);
  padding: 2px 5px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.node-fit {
  height: 4px;
  width: 46px;
  margin: 3px auto 0;
  background: rgba(0,0,0,0.5);
  border-radius: 99px;
  overflow: hidden;
}
.node-fit > i { display: block; height: 100%; background: var(--accent-mint); }

/* === CM 17 FACILITIES & PROGRESS BARS === */
.facility-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 14px;
}
.meter {
  height: 7px;
  background: rgba(255,255,255,0.12);
  border-radius: 99px;
  overflow: hidden;
  margin: 8px 0;
}
.meter > div {
  height: 100%;
  background: linear-gradient(90deg, var(--accent-mint), var(--accent-cyan));
}

/* === FULLSCREEN 2D MATCHDAY OVERLAY === */
.match-overlay {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: #061022;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}
.match-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 12px 20px;
  background: rgba(9, 23, 46, 0.92);
  border-bottom: 1px solid var(--hairline);
}
.scorebug {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 17px;
  font-weight: 900;
}
.scorebug .clock {
  background: var(--accent-mint);
  color: #051624;
  padding: 3px 10px;
  border-radius: 4px;
  font-size: 14px;
}
.match-body {
  flex: 1;
  display: grid;
  grid-template-columns: 1.5fr 0.85fr;
  gap: 16px;
  padding: 16px 20px;
  max-width: 1360px;
  width: 100%;
  margin: 0 auto;
}
.canvas-wrap {
  background: #0b4a2f;
  border: 1px solid var(--hairline);
  border-radius: 10px;
  overflow: hidden;
  position: relative;
}
#match-canvas {
  width: 100%;
  height: auto;
  display: block;
  aspect-ratio: 16 / 10;
}
.commentary-box {
  height: 260px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-size: 12px;
}
.comm-line {
  padding: 6px 8px;
  border-left: 2px solid var(--hairline);
  background: rgba(255,255,255,0.03);
}
.comm-line.goal { border-left-color: var(--accent-mint); background: rgba(36, 229, 181, 0.14); font-weight: 700; }

/* === MODALS & TOASTS === */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(3, 10, 22, 0.78);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}
.modal-box {
  width: 100%;
  max-width: 560px;
  max-height: 88vh;
  overflow-y: auto;
  background: linear-gradient(155deg, #0d2347, #08152c);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 14px;
  padding: 22px;
}
.toast-container {
  position: fixed;
  bottom: 76px;
  right: 18px;
  z-index: 120;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.toast {
  background: rgba(9, 25, 48, 0.94);
  border: 1px solid var(--accent-mint);
  color: #fff;
  padding: 10px 16px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  box-shadow: 0 10px 24px rgba(0,0,0,0.45);
}

/* === MOBILE NAVIGATION & RESPONSIVE BREAKPOINTS === */
.mobile-bottom-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 50;
  background: rgba(7, 18, 38, 0.95);
  backdrop-filter: blur(14px);
  border-top: 1px solid var(--hairline);
  grid-template-columns: repeat(5, 1fr);
  padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
}
.mob-tab {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 700;
  padding: 8px 4px;
  cursor: pointer;
}
.mob-tab.active { color: var(--accent-mint); }

@media (max-width: 960px) {
  .main-tabs, .brand-breadcrumb { display: none; }
  .mobile-bottom-nav { display: grid; }
  .top-ribbon { padding: 10px 14px; }
  .main-view { padding: 14px 14px 86px; }
  .profile-layout { grid-template-columns: 1fr; gap: 18px; }
  .data-grid-4 { grid-template-columns: repeat(2, 1fr); }
  .status-strip { grid-template-columns: repeat(2, 1fr); }
  .hub-grid, .tactics-grid, .match-body { grid-template-columns: 1fr; }
}

/* FC 27 broadcast-inspired visual pass */
:root {
  --bg-deep: #071326;
  --bg-navy: #0a1b35;
  --accent-mint: #62e6c1;
  --accent-cyan: #55c8ee;
  --accent-lav: #a98aff;
  --hairline: rgba(205, 224, 255, 0.14);
  --glass-bg: rgba(10, 22, 44, 0.76);
  --radius: 16px;
}

html, body { min-height: 100%; }
body { letter-spacing: 0.01em; }
.bg-backdrop {
  background:
    radial-gradient(ellipse 70% 52% at 76% 0%, rgba(17, 177, 158, 0.42), transparent 68%),
    radial-gradient(ellipse 58% 48% at 8% 100%, rgba(106, 61, 192, 0.34), transparent 70%),
    linear-gradient(150deg, #071326 0%, #0b2140 54%, #101630 100%);
}
.bg-backdrop::after {
  opacity: 0.055;
  background-size: 116px 190px;
}
.boot-card {
  background: linear-gradient(145deg, rgba(13, 34, 62, 0.88), rgba(10, 19, 43, 0.84));
  border-color: rgba(132, 234, 219, 0.24);
  border-radius: 22px;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.34), inset 0 1px rgba(255,255,255,0.08);
}
.boot-title-group h1 { letter-spacing: 1.6px; }
.club-pick, .pill-btn, .btn, .sub-tab, .mob-tab, .main-tab, .btn-advance {
  transition: background-color .18s ease, border-color .18s ease, color .18s ease, transform .18s ease, box-shadow .18s ease;
}
.club-pick { border-radius: 14px; color: inherit; font: inherit; text-align: left; width: 100%; }
.club-pick.selected {
  box-shadow: inset 0 0 0 1px rgba(98, 230, 193, 0.22), 0 8px 24px rgba(18, 186, 159, 0.12);
}
.top-ribbon {
  background: linear-gradient(100deg, rgba(5, 17, 36, 0.94), rgba(8, 27, 49, 0.9));
  border-bottom-color: rgba(112, 219, 213, 0.2);
  box-shadow: 0 10px 30px rgba(0,0,0,.12);
}
.mc-emblem { box-shadow: 0 0 22px rgba(98, 230, 193, .16); }
.main-tab.active { background: linear-gradient(180deg, rgba(98, 230, 193, .16), rgba(98, 230, 193, .06)); }
.sub-ribbon {
  max-width: 100%;
  scrollbar-width: none;
  background: rgba(6, 17, 36, .58);
}
.sub-ribbon::-webkit-scrollbar { display: none; }
.sub-tab { flex: 0 0 auto; }
.main-view { max-width: 1440px; }
.glass-panel {
  background: linear-gradient(145deg, rgba(13, 29, 55, .88), rgba(8, 19, 39, .78));
  border-color: rgba(195, 220, 255, .13);
  box-shadow: 0 14px 36px rgba(0, 0, 0, .12), inset 0 1px rgba(255,255,255,.035);
}
.section-head h2 { letter-spacing: .9px; }
.next-match-banner {
  position: relative;
  overflow: hidden;
  min-height: 160px;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(76, 224, 195, .22), transparent 58%),
    linear-gradient(115deg, rgba(11, 93, 105, .58), rgba(18, 31, 68, .92) 70%);
  border: 1px solid rgba(98, 230, 193, .34);
  border-radius: 20px;
  box-shadow: inset 0 1px rgba(255,255,255,.08), 0 18px 38px rgba(0,0,0,.16);
}
.next-match-banner::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(115deg, transparent 38%, rgba(255,255,255,.035) 38.2%, transparent 38.6%);
}
.match-team-col .club-swatch {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  box-shadow: 0 8px 22px rgba(0,0,0,.24);
}
.match-team-col strong { font-size: 15px; }
.match-vs { min-width: 82px; }
.ovr-diamond::before {
  background: linear-gradient(145deg, rgba(98,230,193,.2), rgba(169,138,255,.12));
  border-color: rgba(210, 240, 255, .8);
  box-shadow: 0 0 28px rgba(98,230,193,.1);
}
.profile-hero {
  padding: 18px;
  overflow: hidden;
  border: 1px solid rgba(98,230,193,.22);
  border-radius: 20px;
  background:
    radial-gradient(ellipse at 76% 14%, rgba(34,173,170,.22), transparent 54%),
    linear-gradient(155deg, rgba(16,40,67,.88), rgba(8,20,42,.76));
  box-shadow: 0 18px 44px rgba(0,0,0,.2);
}
.profile-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: .5;
  background: linear-gradient(135deg, transparent 62%, rgba(141,104,237,.13));
}
.avatar-stage { height: 240px; }
.jersey-svg { filter: drop-shadow(0 18px 26px rgba(0,0,0,.5)); }
.jersey-watermark { color: rgba(218,238,255,.52); }
.hero-bio { position: relative; }
.status-strip { border-color: rgba(157,208,231,.2); }
.role-pill, .growth-tag { border-radius: 999px; }
.data-table th { color: #9ab0cb; }
.data-table tbody tr { transition: background-color .16s ease; }
.data-table tbody tr:hover { background: rgba(255,255,255,.035); }
.btn-advance {
  background: linear-gradient(105deg, #62e6c1, #55c8ee);
  box-shadow: 0 8px 22px rgba(65,208,191,.18);
}
.btn-advance.matchday { background: linear-gradient(105deg, #f6c45f, #f28ab3); }
.mobile-bottom-nav {
  background: rgba(6, 17, 36, .96);
  border-top-color: rgba(123, 207, 215, .2);
  box-shadow: 0 -10px 30px rgba(0,0,0,.18);
}
.mob-tab.active { text-shadow: 0 0 18px rgba(98,230,193,.28); }
:focus-visible { outline: 2px solid var(--accent-cyan); outline-offset: 3px; }

@media (max-width: 600px) {
  .top-ribbon {
    gap: 8px;
    padding: 9px 12px;
  }
  .ribbon-left, .ribbon-right { gap: 10px; }
  .club-chip-text strong { max-width: 112px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .date-chip { padding-left: 9px; }
  .date-chip strong { font-size: 11px; }
  .btn-advance { padding: 10px 12px; font-size: 11px; }
  .sub-ribbon { gap: 16px; padding: 10px 16px; }
  .main-view { padding: 12px 12px calc(82px + env(safe-area-inset-bottom)); }
  .next-match-banner { min-height: 136px; padding: 14px 10px; gap: 7px; }
  .match-team-col { min-width: 0; gap: 5px; }
  .match-team-col strong { max-width: 110px; font-size: 12px; line-height: 1.25; }
  .match-team-col .club-swatch { width: 40px; height: 40px; font-size: 9px; }
  .match-vs { min-width: 64px; font-size: 11px; }
  .match-vs div:nth-child(2) { font-size: 18px !important; }
  .glass-panel { padding: 13px; border-radius: 15px; }
  .section-head { gap: 8px; }
  .section-head h2 { font-size: 15px; }
  .table-wrap { border-radius: 12px; scrollbar-width: thin; }
  .data-table { font-size: 12px; }
  .data-table th, .data-table td { padding: 8px 7px; }
  .profile-layout {
    display: grid;
    grid-template-columns: minmax(102px, .78fr) minmax(0, 1.42fr);
    align-items: start;
    gap: 12px;
  }
  .profile-layout > aside { grid-column: 1; grid-row: 1 / span 3; }
  .profile-layout > div { display: contents; }
  .profile-header { grid-column: 2; grid-row: 1; align-items: flex-start; gap: 8px; margin-bottom: 8px; }
  .status-strip { grid-column: 2; grid-row: 2; grid-template-columns: 1fr 1fr; gap: 8px; padding: 9px 0; margin-bottom: 8px; }
  .profile-layout > div > :not(.profile-header):not(.status-strip) { grid-column: 1 / -1; min-width: 0; }
  .profile-hero { padding: 9px; }
  .avatar-stage { height: 145px; margin-bottom: 8px; }
  .jersey-svg { width: 105px; height: 130px; }
  .jersey-watermark { top: 82px; font-size: 46px; }
  .hero-bio { gap: 8px; margin-bottom: 10px; }
  .bio-item small { font-size: 9px; }
  .bio-item strong { font-size: 11px; }
  .btn-actions-grad { padding: 8px 6px; font-size: 11px; }
  .profile-identity h1 { font-size: clamp(16px, 4.6vw, 20px); overflow-wrap: anywhere; }
  .profile-identity .pos-line { font-size: 10px; letter-spacing: .2px; }
  .ovr-diamond { width: 42px; height: 42px; }
  .ovr-diamond span { font-size: 20px; }
  .status-cell small { font-size: 9px; }
  .status-cell strong { font-size: 10px; letter-spacing: 0; }
  .mobile-bottom-nav { padding-bottom: calc(6px + env(safe-area-inset-bottom)); }
  .mob-tab { padding: 9px 2px; font-size: 10px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

/* Console game shell: safe-area viewport, club identity, and tactile controls */
:root {
  --bg-deep: #050d1d;
  --bg-navy: #0a1830;
  --bg-teal: #0d7a78;
  --club-primary: #24e5b5;
  --font-main: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-display: 'Barlow Condensed', 'Chakra Petch', 'Inter', sans-serif;
}

html, body {
  height: 100%;
  min-height: 100%;
  overflow-x: hidden;
}
body {
  height: 100dvh;
  overflow-y: hidden;
  overscroll-behavior: none;
  color-scheme: dark;
  background: #050d1d;
}
.boot-screen {
  height: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  overflow-y: auto;
  overscroll-behavior-y: contain;
  padding: calc(24px + env(safe-area-inset-top, 0px)) 16px calc(24px + env(safe-area-inset-bottom, 0px));
}
.app-shell {
  height: 100vh;
  height: 100dvh;
  min-height: 0;
  overflow: hidden;
}
.top-ribbon {
  flex-shrink: 0;
  padding: calc(12px + env(safe-area-inset-top, 0px)) 24px 12px;
  background: linear-gradient(105deg, rgba(5, 13, 29, .98), rgba(7, 35, 52, .94));
  border-bottom-color: rgba(98, 230, 193, .24);
}
.ribbon-left { min-width: 0; }
.ribbon-right { flex-shrink: 0; gap: 12px; }
.club-chip { flex-shrink: 0; }
.club-dot {
  width: 32px;
  height: 32px;
  display: grid;
  flex: 0 0 32px;
  place-items: center;
  border: 1px solid rgba(255,255,255,.68);
  border-radius: 8px;
  font-size: 8px;
  font-weight: 900;
  letter-spacing: -.3px;
  box-shadow: 0 0 18px color-mix(in srgb, var(--club-primary) 38%, transparent);
}
.club-chip-text span { color: color-mix(in srgb, var(--club-primary) 58%, white); }
.club-chip-text strong { max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.brand-fc, .section-head h2, .boot-title-group h1, .profile-identity h1, .scorebug, .ovr-diamond span {
  font-family: var(--font-display);
  font-stretch: condensed;
  letter-spacing: .025em;
}
.brand-fc, .section-head h2, .boot-title-group h1, .profile-identity h1 { text-transform: uppercase; }
.main-tabs { flex-shrink: 1; }
.main-tab { border-radius: 4px; }
.main-tab.active {
  color: #fff;
  background: linear-gradient(180deg, color-mix(in srgb, var(--club-primary) 23%, transparent), transparent);
  box-shadow: inset 0 -2px var(--club-primary), 0 0 20px color-mix(in srgb, var(--club-primary) 12%, transparent);
}
.sub-ribbon {
  flex-shrink: 0;
  border-bottom-color: rgba(255,255,255,.1);
  background: rgba(5, 13, 29, .58);
}
.sub-tab { min-height: 36px; }
.sub-tab.active::after { background: color-mix(in srgb, var(--club-primary) 58%, white); height: 3px; }
.main-view {
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior-y: contain;
  -webkit-overflow-scrolling: touch;
  padding-bottom: calc(86px + env(safe-area-inset-bottom, 0px));
}
.glass-panel {
  border-color: transparent;
  background: linear-gradient(145deg, rgba(13, 29, 55, .82), rgba(6, 15, 32, .66));
  box-shadow: inset 0 1px rgba(255,255,255,.045);
}
.next-match-banner {
  border-color: color-mix(in srgb, var(--club-primary) 42%, transparent);
  background:
    radial-gradient(ellipse at 50% 0%, color-mix(in srgb, var(--club-primary) 20%, transparent), transparent 62%),
    linear-gradient(115deg, rgba(13, 122, 120, .42), rgba(8, 18, 39, .92) 72%);
}
.data-table th { color: #a6bbd6; }
.data-table tbody tr.user-row { box-shadow: inset 3px 0 var(--club-primary); }
.input, .select {
  min-height: 44px;
  color-scheme: dark;
  background-color: rgba(5, 14, 31, .92);
  border-color: rgba(255,255,255,.15);
  border-radius: 5px;
}
.select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 38px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23a6bbd6' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
}
.select option { color: #f4f8ff; background: #08152b; }
button {
  touch-action: manipulation;
  -webkit-user-select: none;
  user-select: none;
}
button:not(:disabled):active { transform: scale(.96); }
.btn, .pill-btn, .main-tab, .mob-tab { min-height: 44px; border-radius: 5px; }
.btn-primary, .btn-advance {
  box-shadow: inset 0 1px rgba(255,255,255,.25), 0 8px 24px color-mix(in srgb, var(--club-primary) 18%, transparent);
}
.btn-advance {
  min-height: 46px;
  clip-path: polygon(6px 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%, 0 6px);
}
.btn-advance.matchday {
  box-shadow: inset 0 1px rgba(255,255,255,.24), 0 0 24px rgba(246,196,95,.22);
}
#main-view.scene-enter { animation: sceneEnter .24s ease-out both; }
@keyframes sceneEnter {
  from { opacity: 0; transform: translateY(7px); }
  to { opacity: 1; transform: translateY(0); }
}
.mobile-bottom-nav {
  padding: 5px 6px calc(5px + env(safe-area-inset-bottom, 0px));
  background: rgba(4, 12, 27, .97);
  border-top-color: rgba(255,255,255,.1);
  box-shadow: 0 -10px 32px rgba(0,0,0,.3);
}
.mob-tab {
  position: relative;
  display: flex;
  min-height: 52px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  padding: 5px 2px;
  font-size: 10px;
  letter-spacing: .02em;
}
.dock-icon {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.mob-tab.active { color: color-mix(in srgb, var(--club-primary) 58%, white); }
.mob-tab.active::before {
  content: '';
  position: absolute;
  top: -6px;
  left: calc(50% - 12px);
  width: 24px;
  height: 3px;
  border-radius: 0 0 4px 4px;
  background: color-mix(in srgb, var(--club-primary) 58%, white);
  box-shadow: 0 0 14px color-mix(in srgb, var(--club-primary) 75%, transparent);
}
.match-overlay {
  height: 100vh;
  height: 100dvh;
  padding: calc(10px + env(safe-area-inset-top, 0px)) 0 calc(10px + env(safe-area-inset-bottom, 0px));
  overflow-x: hidden;
  overscroll-behavior-y: contain;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(17, 122, 120, .2), transparent 46%),
    #050d1d;
}
.match-topbar {
  position: sticky;
  top: 0;
  z-index: 3;
  flex-shrink: 0;
  flex-wrap: wrap;
  background: rgba(5, 13, 29, .96);
  backdrop-filter: blur(16px);
}
:focus-visible { outline: 2px solid var(--club-primary); outline-offset: 3px; }

@media (max-width: 960px) {
  .top-ribbon { gap: 8px; padding-left: 14px; padding-right: 14px; }
  .ribbon-left, .ribbon-right { gap: 9px; }
  .ribbon-right { margin-left: auto; }
  .club-chip-text strong { max-width: 104px; }
  .date-chip { padding-left: 9px; }
  .main-view { padding-bottom: calc(78px + env(safe-area-inset-bottom, 0px)); }
  .match-topbar { padding: 8px 10px; }
  .scorebug { gap: 7px; font-size: 15px; }
  .match-body { padding: 10px; gap: 10px; }
  .commentary-box { height: 180px; }
}
@media (max-width: 600px) {
  .top-ribbon {
    gap: 6px;
    padding: calc(7px + env(safe-area-inset-top, 0px)) 10px 7px;
  }
  .ribbon-left, .ribbon-right { gap: 7px; }
  .mc-emblem { width: 29px; height: 29px; font-size: 10px; }
  .club-chip { gap: 6px; }
  .club-dot { width: 30px; height: 30px; flex-basis: 30px; font-size: 7px; }
  .club-chip-text strong { max-width: 82px; font-size: 10px; }
  .club-chip-text span { font-size: 10px; }
  .date-chip { padding-left: 7px; }
  .date-chip span { font-size: 9px; }
  .date-chip strong { font-size: 10px; }
  .btn-advance { min-height: 42px; padding: 8px 9px; font-size: 10px; letter-spacing: .3px; }
  .sub-ribbon { gap: 12px; padding: 6px 12px; }
  .sub-tab { min-height: 36px; font-size: 12px; }
  .main-view { padding: 10px 12px calc(76px + env(safe-area-inset-bottom, 0px)); }
  .mobile-bottom-nav { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .mob-tab { min-height: 48px; font-size: 9px; }
  .dock-icon { width: 18px; height: 18px; }
  .boot-card { padding: 18px 14px; }
  .boot-header { align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  #main-view.scene-enter { animation: none; }
}

/* Handheld console layout: landscape stays widescreen, portrait keeps the dock. */
@media (min-width: 641px) {
  .main-tabs { display: flex; }
  .brand-breadcrumb { display: flex; }
  .mobile-bottom-nav { display: none !important; }
  .main-view { padding-bottom: 22px; }
  .hub-grid { grid-template-columns: 1.15fr 1fr; }
  .profile-layout { grid-template-columns: 220px minmax(0, 1fr); gap: 24px; }
  .data-grid-4, .status-strip { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .tactics-grid { grid-template-columns: 1fr 1.05fr; }
  .match-body { grid-template-columns: 1.45fr .85fr; }
}

@media (max-width: 640px) and (orientation: portrait) {
  .main-tabs, .brand-breadcrumb { display: none; }
  .mobile-bottom-nav { display: grid; }
  .main-view { padding-bottom: calc(76px + env(safe-area-inset-bottom, 0px)); }
  .hub-grid, .profile-layout, .tactics-grid, .match-body { grid-template-columns: 1fr; }
  .data-grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .status-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (orientation: landscape) and (max-height: 520px) {
  .mobile-bottom-nav { display: none !important; }
  .main-tabs { display: flex !important; }
  .brand-breadcrumb { display: none; }
  .top-ribbon {
    height: 42px;
    min-height: 42px;
    padding: 0 max(16px, env(safe-area-inset-right)) 0 max(16px, env(safe-area-inset-left));
    gap: 8px;
  }
  .ribbon-left, .ribbon-right { gap: 10px; }
  .mc-emblem { width: 28px; height: 28px; font-size: 10px; }
  .main-tabs { margin-left: 2px; gap: 2px; }
  .main-tab { min-height: 32px; padding: 5px 9px; font-size: 11px; }
  .club-chip { gap: 6px; }
  .club-dot { width: 27px; height: 27px; flex-basis: 27px; }
  .club-chip-text strong { max-width: 95px; font-size: 10px; }
  .club-chip-text span { font-size: 9px; }
  .date-chip { padding-left: 8px; }
  .date-chip span, .date-chip strong { font-size: 9px; }
  .btn-advance { min-height: 32px; padding: 5px 10px; font-size: 10px; }
  .sub-ribbon { height: 28px; min-height: 28px; padding: 0 max(16px, env(safe-area-inset-left)); gap: 18px; border-bottom: 1px solid rgba(255,255,255,.1); }
  .sub-tab { min-height: 28px; padding: 2px 0; font-size: 11px; }
  .sub-tab.active::after { bottom: -1px; height: 2px; }
  .main-view { padding: 10px 16px 12px; }
  .section-head { margin-bottom: 9px; padding-bottom: 7px; }
  .glass-panel { padding: 10px; }
  .hub-grid { grid-template-columns: 1.15fr 1fr; gap: 12px; }
  .next-match-banner { min-height: 0; padding: 10px; margin-bottom: 9px; border-radius: 12px; }
  .match-team-col .club-swatch { width: 36px; height: 36px; }
  .match-team-col { gap: 3px; }
  .profile-layout { grid-template-columns: 190px minmax(0, 1fr); gap: 14px; }
  .profile-hero { padding: 10px; }
  .avatar-stage { height: 124px; margin-bottom: 6px; }
  .jersey-svg { width: 100px; height: 115px; }
  .jersey-watermark { top: 68px; font-size: 48px; }
  .hero-bio { gap: 4px; margin-bottom: 7px; }
  .bio-item small, .status-cell small, .kv-item small { font-size: 9px; }
  .bio-item strong, .kv-item strong { font-size: 10px; }
  .btn-actions-grad { padding: 7px; font-size: 11px; }
  .profile-header { gap: 10px; margin-bottom: 8px; }
  .ovr-diamond { width: 46px; height: 46px; }
  .ovr-diamond span { font-size: 21px; }
  .profile-identity h1 { font-size: 21px; }
  .status-strip { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; padding: 8px 0; margin-bottom: 9px; }
  .status-cell strong { font-size: 10px; }
  .data-grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
  .data-col { gap: 8px; }
  .attr-row { font-size: 10px; }
  .attr-val { font-size: 11px; }
  .tactics-grid { grid-template-columns: 1fr 1.05fr; gap: 12px; }
  .pitch-board { width: auto; height: min(100%, calc(100dvh - 125px)); max-height: calc(100dvh - 125px); aspect-ratio: 4 / 5; }
  .match-overlay { padding: 0; overflow: hidden; }
  .match-topbar { height: 42px; min-height: 42px; flex-wrap: nowrap; padding: 4px 12px; gap: 8px; }
  .match-topbar > div:last-child { flex-wrap: nowrap !important; }
  .match-topbar .btn { min-height: 30px; padding: 4px 8px; font-size: 10px; }
  .match-body { min-height: 0; grid-template-columns: 1.45fr .85fr; gap: 10px; padding: 8px 12px; overflow: auto; }
  .match-body > div { min-width: 0; gap: 7px !important; }
  .canvas-wrap { max-height: calc(100dvh - 125px); }
  #match-canvas { width: 100%; height: auto; max-height: calc(100dvh - 125px); object-fit: contain; }
  .commentary-box { height: clamp(70px, 21dvh, 100px); }
  .match-body .glass-panel { padding: 8px; }
  .match-body .select { min-height: 32px; }
}

/* =====================================================================
   STEP 2 · CINEMATIC CLUB SELECTION + EA FC 27 CONSOLE HUB
   ===================================================================== */
:root { --club-secondary: #ffffff; }
.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* ---------- Club selection shell ---------- */
.boot-screen.cs-mode {
  position: relative; display: block;
  height: 100vh; height: 100dvh; min-height: 0;
  padding: 0; overflow: hidden;
}
.cs-ambient {
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background:
    linear-gradient(104deg, transparent 0 22%, rgba(255,255,255,.035) 22% 23.5%, transparent 23.5% 41%, rgba(255,255,255,.025) 41% 42%, transparent 42%),
    radial-gradient(ellipse 55% 75% at 22% 42%, color-mix(in srgb, var(--club-primary) 38%, transparent), transparent 70%),
    radial-gradient(ellipse 50% 45% at 92% 105%, color-mix(in srgb, var(--club-primary) 18%, transparent), transparent 70%),
    linear-gradient(180deg, rgba(5,13,29,.15), rgba(5,13,29,.82));
}
.cs-shell {
  position: relative; z-index: 1; height: 100%;
  max-width: 1320px; margin: 0 auto;
  display: grid; grid-template-columns: minmax(0, 44fr) minmax(0, 56fr); gap: 18px;
  padding: calc(18px + env(safe-area-inset-top, 0px)) max(20px, env(safe-area-inset-right, 0px)) calc(18px + env(safe-area-inset-bottom, 0px)) max(20px, env(safe-area-inset-left, 0px));
}
.cs-stage {
  position: relative; min-height: 0; overflow: hidden; isolation: isolate;
  display: flex; flex-direction: column; justify-content: center; gap: 16px;
  padding: 22px; border-radius: 18px;
  background: linear-gradient(160deg, color-mix(in srgb, var(--c1, var(--club-primary)) 26%, rgba(8,18,38,.92)), rgba(5,12,26,.9) 64%);
  box-shadow: inset 0 1px rgba(255,255,255,.09), 0 24px 60px rgba(0,0,0,.35);
}
.cs-stage::after {
  content: ''; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: linear-gradient(118deg, transparent 55%, color-mix(in srgb, var(--c2, #fff) 7%, transparent) 55% 57%, transparent 57%);
}
.cs-stage.cs-stage-enter > * { animation: csEnter .34s cubic-bezier(.2,.8,.2,1) both; }
.cs-stage.cs-stage-enter > :nth-child(2) { animation-delay: .05s; }
.cs-stage.cs-stage-enter > :nth-child(3) { animation-delay: .1s; }
@keyframes csEnter { from { opacity: 0; transform: translateX(-10px); } to { opacity: 1; transform: none; } }

.cs-hero { display: flex; align-items: center; gap: 18px; min-height: 0; }
.cs-kit { position: relative; flex: 0 0 auto; width: clamp(116px, 15vw, 196px); aspect-ratio: 180 / 190; display: grid; place-items: center; }
.cs-kit::before {
  content: ''; position: absolute; inset: -18%; z-index: -1; border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--c1, var(--club-primary)) 60%, transparent), transparent 66%);
  filter: blur(8px);
}
.cs-kit .jersey-svg { width: 100%; height: 100%; animation: csFloat 5s ease-in-out infinite; }
@keyframes csFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
.cs-identity { min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 7px; }
.cs-league { font-size: 12px; font-weight: 600; color: var(--text-soft); }
.cs-club-name {
  font-family: var(--font-display); font-style: italic; font-weight: 900; text-transform: uppercase;
  font-size: clamp(30px, 4.3vw, 58px); line-height: .9; overflow-wrap: anywhere;
  text-shadow: 0 6px 28px rgba(0,0,0,.4);
}
.cs-ucl, .cs-domestic { font-size: 10px; font-weight: 800; letter-spacing: .1em; padding: 4px 9px; border-radius: 3px; }
.cs-ucl { color: #fde68a; background: rgba(245,185,66,.16); box-shadow: inset 0 0 0 1px rgba(245,185,66,.5); }
.cs-domestic { color: var(--text-soft); background: rgba(255,255,255,.06); box-shadow: inset 0 0 0 1px rgba(255,255,255,.14); }
.cs-ratings { display: grid; grid-template-columns: auto auto auto minmax(0, 1fr); border-top: 1px solid rgba(255,255,255,.12); border-bottom: 1px solid rgba(255,255,255,.12); }
.cs-rating { padding: 10px 14px; border-left: 1px solid rgba(255,255,255,.1); min-width: 0; }
.cs-rating:first-child { border-left: 0; padding-left: 0; }
.cs-rating dt { font-size: 10px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 3px; }
.cs-rating dd { font-family: var(--font-display); font-weight: 800; font-size: 22px; line-height: 1.05; white-space: nowrap; }
.cs-rating dd.cs-vision { font-size: 15px; white-space: normal; }
.cs-stars { display: inline-flex; gap: 2px; vertical-align: middle; --star: 16px; }
.cs-star { position: relative; display: inline-block; width: var(--star); height: var(--star); }
.cs-star svg { display: block; width: 100%; height: 100%; fill: rgba(255,255,255,.2); }
.cs-star.on svg, .cs-star-fill svg { fill: #f6c45f; }
.cs-star-fill { position: absolute; inset: 0; width: 50%; overflow: hidden; }
.cs-star-fill svg { width: var(--star); }
.cs-keyplayers h3 { font-size: 10px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 6px; }
.cs-key-list { list-style: none; display: flex; flex-direction: column; }
.cs-key-list li { display: grid; grid-template-columns: 40px minmax(0,1fr) auto 30px; align-items: center; gap: 10px; padding: 6px 0; border-bottom: 1px solid rgba(255,255,255,.07); font-size: 13px; }
.cs-key-name { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cs-key-meta { font-size: 11px; color: var(--text-muted); }
.cs-key-ovr { font-family: var(--font-display); font-size: 18px; font-weight: 900; text-align: right; }
.cs-key-empty { font-size: 12px; color: var(--text-soft); }

.cs-panel {
  min-height: 0; display: flex; flex-direction: column; gap: 12px; padding: 16px; border-radius: 18px;
  background: rgba(6, 14, 30, .8); backdrop-filter: blur(16px);
  box-shadow: inset 0 1px rgba(255,255,255,.06), 0 24px 60px rgba(0,0,0,.28);
}
.cs-topbar { display: flex; align-items: center; gap: 12px; min-width: 0; }
.cs-brand { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }
.cs-brand h1 { font-family: var(--font-display); font-style: italic; font-weight: 900; text-transform: uppercase; font-size: 20px; line-height: 1; letter-spacing: .03em; }
.cs-brand h1 span { color: var(--accent-mint); }
.cs-brand small { display: block; font-size: 10px; color: var(--text-muted); margin-top: 2px; }
.cs-top-actions { flex: 1; min-width: 0; display: flex; align-items: center; justify-content: flex-end; gap: 8px; }
.cs-continue { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; min-width: 0; }
.cs-continue::-webkit-scrollbar { display: none; }
.cs-continue-pill {
  flex: 0 0 auto; display: flex; align-items: center; gap: 8px; min-height: 38px; padding: 3px 12px 3px 3px;
  border: 0; border-radius: 999px; background: rgba(255,255,255,.07); color: #fff; font: inherit; text-align: left; cursor: pointer;
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--c) 50%, transparent);
}
.cs-continue-pill:hover { background: color-mix(in srgb, var(--c) 22%, rgba(255,255,255,.05)); }
.cs-continue-dot { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; font-size: 10px; font-weight: 900; background: var(--c); color: #fff; text-shadow: 0 1px 2px rgba(0,0,0,.6); box-shadow: inset 0 0 0 2px rgba(255,255,255,.4); }
.cs-continue-text { display: flex; flex-direction: column; line-height: 1.15; }
.cs-continue-text strong { font-size: 11px; max-width: 120px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cs-continue-text small { font-size: 9px; color: var(--text-muted); }
.cs-icon-btn { position: relative; flex: 0 0 auto; width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; cursor: pointer; color: var(--text-soft); background: rgba(255,255,255,.07); box-shadow: inset 0 0 0 1px rgba(255,255,255,.12); }
.cs-icon-btn:hover { color: #fff; background: rgba(255,255,255,.12); }
.cs-icon-btn:focus-within { outline: 2px solid var(--club-primary); outline-offset: 2px; }
.cs-icon-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.cs-leagues { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; flex-shrink: 0; }
.cs-leagues::-webkit-scrollbar { display: none; }
.cs-league-pill { flex: 0 0 auto; min-height: 36px; padding: 6px 13px; border: 0; border-radius: 4px; background: rgba(255,255,255,.05); color: var(--text-soft); font: inherit; font-size: 12px; font-weight: 700; cursor: pointer; }
.cs-league-pill:hover { color: #fff; background: rgba(255,255,255,.09); }
.cs-league-pill[aria-pressed="true"] { color: #fff; background: color-mix(in srgb, var(--club-primary) 26%, rgba(255,255,255,.04)); box-shadow: inset 0 -2px color-mix(in srgb, var(--club-primary) 60%, white); }
.cs-grid { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; align-content: start; padding: 3px; scrollbar-width: thin; }
.cs-club { display: flex; align-items: center; gap: 9px; min-width: 0; min-height: 54px; padding: 8px 10px; border: 0; border-radius: 10px; cursor: pointer; background: rgba(255,255,255,.04); color: #fff; font: inherit; text-align: left; box-shadow: inset 0 0 0 1px rgba(255,255,255,.06); }
.cs-club:hover { background: rgba(255,255,255,.08); }
.cs-club[aria-pressed="true"] { background: linear-gradient(135deg, color-mix(in srgb, var(--c1) 34%, transparent), rgba(255,255,255,.04)); box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--c1) 55%, white), 0 0 22px color-mix(in srgb, var(--c1) 30%, transparent); }
.cs-crest { flex: 0 0 auto; width: 32px; height: 36px; display: grid; place-items: center; filter: drop-shadow(0 0 1px rgba(255,255,255,.7)) drop-shadow(0 3px 6px rgba(0,0,0,.4)); }
.cs-crest > span { width: 100%; height: 100%; display: grid; place-items: center; padding-bottom: 5px; background: linear-gradient(160deg, var(--c1) 0 62%, color-mix(in srgb, var(--c1) 70%, #000) 62%); color: var(--c2); font-size: 8.5px; font-weight: 900; text-shadow: 0 1px 2px rgba(0,0,0,.55); clip-path: polygon(0 0, 100% 0, 100% 62%, 50% 100%, 0 62%); }
.cs-club-text { min-width: 0; display: flex; flex-direction: column; line-height: 1.2; }
.cs-club-text strong { font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cs-club-text small { font-size: 10px; color: var(--text-muted); }
.cs-club-ucl { color: #fde68a; font-weight: 800; }
.cs-club-ovr { margin-left: auto; font-family: var(--font-display); font-weight: 900; font-size: 19px; }
.cs-actionbar { flex-shrink: 0; display: flex; align-items: flex-end; gap: 8px; padding-top: 12px; border-top: 1px solid rgba(255,255,255,.1); }
.cs-field { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.cs-field > span { font-size: 9px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--text-muted); }
.cs-field-name { flex: 1 1 120px; }
.cs-field-nat { flex: 0 0 102px; }
.cs-field .input, .cs-field .select { width: 100%; min-height: 42px; }
.cs-slots { display: flex; gap: 3px; }
.cs-slot { position: relative; width: 38px; min-height: 42px; border: 0; border-radius: 5px; cursor: pointer; background: rgba(255,255,255,.06); color: var(--text-soft); font: inherit; font-size: 11px; font-weight: 800; box-shadow: inset 0 0 0 1px rgba(255,255,255,.12); }
.cs-slot.used::after { content: ''; position: absolute; top: 5px; right: 5px; width: 6px; height: 6px; border-radius: 50%; background: var(--accent-gold); }
.cs-slot[aria-pressed="true"] { color: #04121f; background: color-mix(in srgb, var(--club-primary) 55%, white); box-shadow: 0 0 16px color-mix(in srgb, var(--club-primary) 40%, transparent); }
.cs-start {
  flex: 0 0 auto; min-height: 46px; padding: 0 22px; border: 0; cursor: pointer;
  font-family: var(--font-display); font-style: italic; font-weight: 900; font-size: 18px; letter-spacing: .05em;
  color: #04121f; background: linear-gradient(105deg, #62e6c1, #55c8ee);
  clip-path: polygon(10px 0, 100% 0, calc(100% - 10px) 100%, 0 100%);
  animation: csPulse 2.8s ease-in-out infinite;
}
.cs-start:hover { filter: brightness(1.08); }
.cs-start:disabled { opacity: .6; cursor: progress; animation: none; }
@keyframes csPulse { 0%, 100% { filter: brightness(1); } 50% { filter: brightness(1.14); } }

/* ---------- Console Central Hub ---------- */
.hub-console { display: grid; grid-template-columns: minmax(0, 58fr) minmax(0, 42fr); gap: 16px; height: calc(100dvh - 180px); min-height: 470px; }
.hub-stage { min-height: 0; display: flex; flex-direction: column; gap: 12px; }
.hub-hero {
  position: relative; flex: 1 1 auto; min-height: 0; isolation: isolate; overflow: hidden;
  display: flex; flex-direction: column; justify-content: space-between; gap: 12px;
  padding: 18px 20px; border-radius: 16px;
  background: linear-gradient(112deg, var(--home) 0 49.6%, var(--away) 50.4% 100%);
  box-shadow: 0 18px 44px rgba(0,0,0,.28);
}
.hub-hero::before { content: ''; position: absolute; inset: 0; z-index: -1; background: radial-gradient(ellipse 70% 60% at 50% 45%, rgba(255,255,255,.08), transparent 70%), linear-gradient(180deg, rgba(4,10,22,.58), rgba(4,10,22,.86)); }
.hub-hero::after { content: ''; position: absolute; inset: -10% 0; z-index: -1; pointer-events: none; background: linear-gradient(112deg, transparent 49.3%, rgba(255,255,255,.38) 49.8%, transparent 50.3%); }
.hub-hero-top { display: flex; align-items: center; gap: 8px; min-width: 0; }
.hub-comp { flex: 0 0 auto; font-size: 10px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; padding: 4px 9px; border-radius: 3px; }
.hub-comp.league { color: #8ff0cc; background: rgba(16,185,129,.18); box-shadow: inset 0 0 0 1px rgba(52,211,153,.5); }
.hub-comp.ucl { color: #fde68a; background: linear-gradient(90deg, rgba(245,185,66,.24), rgba(56,189,248,.14)); box-shadow: inset 0 0 0 1px rgba(245,185,66,.55); }
.hub-meta { flex: 1; min-width: 0; font-size: 11px; color: var(--text-soft); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hub-days { flex: 0 0 auto; font-size: 10px; font-weight: 900; letter-spacing: .1em; padding: 4px 10px; border-radius: 999px; background: rgba(255,255,255,.12); color: #fff; }
.hub-days.today { color: #1b0d05; background: linear-gradient(90deg, #f6c45f, #f28ab3); animation: hubGlow 1.8s ease-in-out infinite; }
@keyframes hubGlow { 0%, 100% { box-shadow: 0 0 0 rgba(246,196,95,0); } 50% { box-shadow: 0 0 18px rgba(246,196,95,.6); } }
.hub-matchup { display: grid; grid-template-columns: minmax(0,1fr) auto minmax(0,1fr); align-items: center; gap: 10px; }
.hub-side { min-width: 0; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px; }
.hub-kit { width: clamp(58px, 8vw, 96px); aspect-ratio: 180 / 190; flex: 0 0 auto; }
.hub-kit .jersey-svg { width: 100%; height: 100%; filter: drop-shadow(0 10px 18px rgba(0,0,0,.5)); }
.hub-team { max-width: 100%; font-family: var(--font-display); font-style: italic; font-weight: 900; text-transform: uppercase; font-size: clamp(16px, 2.1vw, 26px); line-height: 1.05; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hub-side.is-user .hub-team { text-shadow: 0 0 18px color-mix(in srgb, var(--club-primary) 70%, transparent); }
.hub-team-meta { display: flex; gap: 8px; font-size: 11px; color: var(--text-soft); font-variant-numeric: tabular-nums; }
.hub-team-meta b { color: #fff; }
.hub-vs { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.hub-vs span { font-family: var(--font-display); font-style: italic; font-weight: 900; font-size: 30px; line-height: 1; }
.hub-vs small { font-size: 9px; font-weight: 800; letter-spacing: .12em; color: var(--text-muted); }
.hub-hero-cta { display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; }
.hub-cta, .hub-cta-sec { min-height: 44px; border: 0; cursor: pointer; font-family: var(--font-display); font-style: italic; font-weight: 900; letter-spacing: .05em; clip-path: polygon(10px 0, 100% 0, calc(100% - 10px) 100%, 0 100%); }
.hub-cta { padding: 0 28px; font-size: 17px; color: #04121f; background: linear-gradient(105deg, #62e6c1, #55c8ee); }
.hub-cta.play { color: #1b0d05; background: linear-gradient(105deg, #f6c45f, #f28ab3); }
.hub-cta-sec { padding: 0 18px; font-size: 15px; color: #fff; background: rgba(255,255,255,.14); }
.hub-cta:hover, .hub-cta-sec:hover { filter: brightness(1.1); }
.hub-cta:disabled, .hub-cta-sec:disabled { opacity: .55; cursor: progress; }
.hub-idle-body { display: flex; align-items: center; gap: 16px; }
.hub-idle-title { font-family: var(--font-display); font-style: italic; font-weight: 900; text-transform: uppercase; font-size: 26px; line-height: 1; }
.hub-idle-copy { font-size: 12px; color: var(--text-soft); margin-top: 4px; }
.hub-tiles { flex-shrink: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.hub-tile { position: relative; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 3px; padding: 12px 14px; border: 0; border-radius: 12px; cursor: pointer; text-align: left; color: #fff; font: inherit; background: linear-gradient(145deg, rgba(255,255,255,.08), rgba(255,255,255,.025)); box-shadow: inset 0 1px rgba(255,255,255,.07); overflow: hidden; }
.hub-tile::before { content: ''; position: absolute; left: 0; top: 12px; bottom: 12px; width: 3px; border-radius: 0 3px 3px 0; background: color-mix(in srgb, var(--club-primary) 60%, white); opacity: .55; }
.hub-tile:hover { background: linear-gradient(145deg, color-mix(in srgb, var(--club-primary) 16%, rgba(255,255,255,.06)), rgba(255,255,255,.03)); }
.hub-tile:hover::before { opacity: 1; }
.hub-tile-label { display: flex; align-items: center; gap: 6px; font-size: 10px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--text-muted); white-space: nowrap; }
.hub-tile-value { font-family: var(--font-display); font-weight: 900; font-size: 24px; line-height: 1.05; }
.hub-tile-sub { max-width: 100%; font-size: 11px; color: var(--text-soft); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hub-tile-sub b { color: #fff; }
.hub-window { font-size: 8.5px; padding: 1px 5px; border-radius: 3px; background: rgba(255,255,255,.1); color: var(--text-muted); }
.hub-window.open { color: #04121f; background: var(--accent-mint); }
.hub-feed { min-height: 0; display: flex; flex-direction: column; overflow: hidden; border-radius: 16px; background: linear-gradient(160deg, rgba(13,29,55,.88), rgba(6,15,32,.78)); box-shadow: inset 0 1px rgba(255,255,255,.05); }
.hub-status { flex-shrink: 0; display: grid; grid-template-columns: 1.1fr 1fr 1.1fr; gap: 10px; padding: 12px 14px; border-bottom: 1px solid rgba(255,255,255,.08); }
.hub-stat { min-width: 0; }
.hub-stat small { display: block; font-size: 9px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 2px; }
.hub-stat strong { font-family: var(--font-display); font-size: 20px; font-weight: 900; line-height: 1.1; white-space: nowrap; }
.hub-stat strong span { font-size: 12px; color: var(--text-soft); font-weight: 700; }
.hub-hairline { height: 3px; margin-top: 5px; border-radius: 99px; background: rgba(255,255,255,.1); overflow: hidden; }
.hub-hairline i { display: block; height: 100%; background: linear-gradient(90deg, var(--accent-mint), var(--accent-cyan)); }
.hub-form { display: flex; gap: 3px; margin-top: 2px; }
.hub-form-dot { width: 20px; height: 20px; border-radius: 4px; display: grid; place-items: center; font-size: 10px; font-weight: 900; }
.hub-form-dot.W { background: #22c58b; color: #03140c; }
.hub-form-dot.D { background: #8193a8; color: #0b1220; }
.hub-form-dot.L { background: #f43f5e; color: #1a0207; }
.hub-form-empty { font-size: 11px; color: var(--text-muted); }
.hub-feed-dynamic { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.hub-feed-tabs { flex-shrink: 0; display: flex; padding: 0 8px; border-bottom: 1px solid rgba(255,255,255,.08); }
.hub-feed-tabs [role="tab"] { position: relative; flex: 1; min-height: 42px; border: 0; background: none; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 6px; color: var(--text-muted); font: inherit; font-size: 11px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.hub-feed-tabs [role="tab"]:hover, .hub-feed-tabs [role="tab"][aria-selected="true"] { color: #fff; }
.hub-feed-tabs [role="tab"][aria-selected="true"]::after { content: ''; position: absolute; left: 18%; right: 18%; bottom: -1px; height: 2px; background: color-mix(in srgb, var(--club-primary) 60%, white); }
.hub-badge { min-width: 18px; height: 18px; padding: 0 5px; border-radius: 99px; display: inline-grid; place-items: center; font-size: 10px; letter-spacing: 0; color: #fff; background: var(--accent-red); }
.hub-feed-body { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 4px 14px 12px; }
.hub-feed-body:focus-visible { outline-offset: -2px; }
.hub-empty { padding: 20px 0; font-size: 12px; color: var(--text-muted); text-align: center; }
.hub-list { list-style: none; }
.hub-msg { position: relative; width: 100%; display: flex; flex-direction: column; gap: 3px; padding: 10px 4px 10px 14px; border: 0; border-bottom: 1px solid rgba(255,255,255,.07); background: none; color: var(--text-soft); font: inherit; text-align: left; cursor: pointer; }
.hub-msg:hover { background: rgba(255,255,255,.035); }
.hub-msg.unread { color: #fff; }
.hub-msg.unread::before { content: ''; position: absolute; left: 2px; top: 16px; width: 6px; height: 6px; border-radius: 50%; background: var(--club-primary); box-shadow: 0 0 8px var(--club-primary); }
.hub-msg-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.hub-msg-head small { font-size: 10px; color: var(--text-muted); }
.hub-msg strong { font-size: 13px; }
.hub-msg-body { font-size: 12px; color: var(--text-muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.hub-tag { font-size: 9px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; padding: 2px 7px; border-radius: 3px; white-space: nowrap; }
.hub-tag.mint { color: #8ff0cc; background: rgba(98,230,193,.14); }
.hub-tag.gold { color: #fde68a; background: rgba(245,185,66,.16); }
.hub-tag.cyan { color: #bae6fd; background: rgba(56,189,248,.16); }
.hub-tag.red { color: #fecdd3; background: rgba(244,63,94,.18); }
.hub-tag.lav { color: #ddd6fe; background: rgba(167,139,250,.18); }
.hub-tag.muted { color: var(--text-soft); background: rgba(255,255,255,.08); }
.hub-post { padding: 10px 0; border-bottom: 1px solid rgba(255,255,255,.07); }
.hub-post-head { display: flex; align-items: center; gap: 8px; margin-bottom: 5px; }
.hub-avatar { width: 28px; height: 28px; flex: 0 0 28px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: 900; background: rgba(255,255,255,.1); }
.hub-post-id { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.2; }
.hub-post-id strong { font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hub-post-id small { font-size: 10px; color: var(--text-muted); }
.hub-post p { font-size: 12px; color: var(--text-soft); }
.hub-table-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 0 6px; font-size: 11px; font-weight: 700; color: var(--text-muted); }
.hub-link { min-height: 32px; border: 0; background: none; cursor: pointer; font: inherit; font-size: 11px; font-weight: 800; color: color-mix(in srgb, var(--club-primary) 55%, white); }
.hub-link:hover { text-decoration: underline; }
.hub-mini-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.hub-mini-table th { padding: 6px 4px; font-size: 9px; font-weight: 800; letter-spacing: .08em; text-align: right; color: var(--text-muted); border-bottom: 1px solid rgba(255,255,255,.1); }
.hub-mini-table th:nth-child(-n+2) { text-align: left; }
.hub-mini-table td { padding: 8px 4px; text-align: right; border-bottom: 1px solid rgba(255,255,255,.06); }
.hub-mini-table td:nth-child(-n+2) { text-align: left; }
.hub-mini-table td:nth-child(2) { max-width: 0; width: 100%; }
.hub-mini-table tr.user-row td { background: color-mix(in srgb, var(--club-primary) 16%, transparent); }
.hub-mini-table tr.user-row td:first-child { box-shadow: inset 3px 0 var(--club-primary); }
.hub-gap td { text-align: center !important; padding: 2px; color: var(--text-muted); border-bottom: 0; }
.hub-pos { display: inline-grid; place-items: center; min-width: 22px; height: 20px; border-radius: 4px; font-weight: 800; }
.hub-pos.ucl { background: rgba(56,189,248,.18); color: #bae6fd; }
.hub-pos.rel { background: rgba(244,63,94,.18); color: #fecdd3; }
.hub-club-cell { display: flex; align-items: center; gap: 7px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hub-club-cell i { flex: 0 0 12px; width: 12px; height: 12px; border-radius: 3px; }

/* ---------- Landscape handheld (~852x393) ---------- */
@media (orientation: landscape) and (max-height: 520px) {
  .cs-shell { gap: 10px; padding: max(8px, env(safe-area-inset-top, 0px)) max(12px, env(safe-area-inset-right, 0px)) max(8px, env(safe-area-inset-bottom, 0px)) max(12px, env(safe-area-inset-left, 0px)); }
  .cs-stage { padding: 12px 14px; gap: 9px; border-radius: 14px; }
  .cs-hero { gap: 12px; }
  .cs-kit { width: 100px; }
  .cs-club-name { font-size: 30px; }
  .cs-league { font-size: 10px; }
  .cs-ucl, .cs-domestic { font-size: 9px; padding: 3px 7px; }
  .cs-rating { padding: 6px 9px; }
  .cs-rating dt { font-size: 8px; }
  .cs-rating dd { font-size: 16px; }
  .cs-rating dd.cs-vision { font-size: 11px; }
  .cs-stars { --star: 12px; }
  .cs-keyplayers h3 { font-size: 9px; margin-bottom: 2px; }
  .cs-key-list li { grid-template-columns: 34px minmax(0,1fr) auto 24px; gap: 7px; padding: 3px 0; font-size: 11px; }
  .cs-key-list .pos-badge { min-width: 30px; font-size: 9px; padding: 1px 4px; }
  .cs-key-ovr { font-size: 14px; }
  .cs-panel { padding: 10px; gap: 7px; border-radius: 14px; }
  .cs-brand h1 { font-size: 15px; }
  .cs-brand small { display: none; }
  .cs-brand .mc-emblem { width: 26px; height: 26px; font-size: 9px; }
  .cs-continue-pill { min-height: 30px; padding-right: 9px; }
  .cs-continue-dot { width: 24px; height: 24px; font-size: 9px; }
  .cs-continue-text small { display: none; }
  .cs-icon-btn { width: 32px; height: 32px; }
  .cs-league-pill { min-height: 28px; padding: 4px 10px; font-size: 11px; }
  .cs-grid { gap: 5px; }
  .cs-club { min-height: 40px; padding: 4px 8px; gap: 7px; }
  .cs-crest { width: 24px; height: 28px; }
  .cs-crest > span { font-size: 7px; padding-bottom: 4px; }
  .cs-club-text strong { font-size: 11px; }
  .cs-club-text small { font-size: 9px; }
  .cs-club-ovr { font-size: 16px; }
  .cs-actionbar { padding-top: 7px; gap: 6px; }
  .cs-field > span { font-size: 8px; }
  .cs-field .input, .cs-field .select { min-height: 34px; padding-top: 4px; padding-bottom: 4px; font-size: 12px; }
  .cs-field-nat { flex-basis: 88px; }
  .cs-slot { width: 32px; min-height: 34px; font-size: 10px; }
  .cs-start { min-height: 36px; padding: 0 16px; font-size: 15px; }

  .hub-console { height: calc(100dvh - 92px); min-height: 0; gap: 10px; }
  .hub-stage { gap: 8px; }
  .hub-hero { padding: 9px 12px; gap: 5px; border-radius: 12px; }
  .hub-comp, .hub-days { font-size: 9px; padding: 3px 7px; }
  .hub-meta { font-size: 10px; }
  .hub-kit { width: 46px; }
  .hub-team { font-size: 16px; }
  .hub-team-meta { font-size: 10px; }
  .hub-vs span { font-size: 20px; }
  .hub-cta, .hub-cta-sec { min-height: 32px; }
  .hub-cta { padding: 0 20px; font-size: 14px; }
  .hub-cta-sec { padding: 0 14px; font-size: 13px; }
  .hub-idle-title { font-size: 19px; }
  .hub-idle-copy { font-size: 11px; }
  .hub-tiles { gap: 8px; }
  .hub-tile { padding: 7px 10px; gap: 1px; border-radius: 10px; }
  .hub-tile::before { top: 8px; bottom: 8px; }
  .hub-tile-label { font-size: 8.5px; }
  .hub-tile-value { font-size: 17px; }
  .hub-tile-sub { font-size: 10px; }
  .hub-feed { border-radius: 12px; }
  .hub-status { padding: 7px 10px; gap: 8px; }
  .hub-stat strong { font-size: 15px; }
  .hub-stat strong span { font-size: 10px; }
  .hub-form-dot { width: 16px; height: 16px; font-size: 9px; }
  .hub-feed-tabs [role="tab"] { min-height: 30px; font-size: 10px; }
  .hub-badge { min-width: 15px; height: 15px; font-size: 9px; }
  .hub-feed-body { padding: 2px 10px 8px; }
  .hub-msg { padding: 6px 2px 6px 12px; }
  .hub-msg.unread::before { top: 12px; }
  .hub-msg strong { font-size: 11px; }
  .hub-msg-body { font-size: 10px; -webkit-line-clamp: 1; }
  .hub-post { padding: 6px 0; }
  .hub-post p { font-size: 11px; }
  .hub-table-head { padding: 4px 0; }
  .hub-link { min-height: 26px; }
  .hub-mini-table { font-size: 11px; }
  .hub-mini-table td { padding: 4px; }
}

/* ---------- Portrait phones ---------- */
@media (max-width: 640px) and (orientation: portrait) {
  .boot-screen.cs-mode { overflow-y: auto; }
  .cs-shell { height: auto; min-height: 100%; grid-template-columns: 1fr; gap: 12px; padding: calc(12px + env(safe-area-inset-top, 0px)) 12px 0; }
  .cs-stage { padding: 14px; gap: 12px; }
  .cs-kit { width: 92px; }
  .cs-club-name { font-size: 30px; }
  .cs-ratings { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cs-rating { padding: 8px 10px; border-left: 0; }
  .cs-rating:nth-child(even) { border-left: 1px solid rgba(255,255,255,.1); }
  .cs-rating:nth-child(-n+2) { border-bottom: 1px solid rgba(255,255,255,.1); }
  .cs-rating:nth-child(odd) { padding-left: 0; }
  .cs-panel { padding: 12px 12px 0; border-radius: 16px 16px 0 0; }
  .cs-topbar { flex-wrap: wrap; }
  .cs-top-actions { flex-basis: 100%; justify-content: space-between; }
  .cs-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); overflow: visible; flex: none; }
  .cs-actionbar { position: sticky; bottom: 0; z-index: 2; flex-wrap: wrap; margin: 0 -12px; padding: 10px 12px calc(10px + env(safe-area-inset-bottom, 0px)); background: rgba(5, 12, 26, .96); backdrop-filter: blur(14px); }
  .cs-field-name { flex-basis: calc(100% - 110px); }
  .cs-start { flex: 1; }

  .hub-console { grid-template-columns: 1fr; height: auto; min-height: 0; }
  .hub-hero { padding: 14px; min-height: 250px; }
  .hub-hero-top { flex-wrap: wrap; }
  .hub-meta { order: 3; flex-basis: 100%; }
  .hub-team { font-size: 17px; }
  .hub-tile { padding: 10px; }
  .hub-tile-label { font-size: 8.5px; white-space: normal; flex-wrap: wrap; }
  .hub-tile-value { font-size: 18px; }
  .hub-tile-sub { font-size: 10px; white-space: normal; }
  .hub-feed-body { max-height: 420px; }
}

@media (prefers-reduced-motion: reduce) {
  .cs-kit .jersey-svg, .cs-start, .hub-days.today, .cs-stage.cs-stage-enter > * { animation: none !important; }
}


/* =====================================================================
   STEP 1 (v1.0.5) · SHARED BADGES + BROADCAST 2D MATCHDAY ENGINE (.bc-*)
   ===================================================================== */

/* ---------- Shared badges & tactical node indicators ---------- */
.derby-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex: 0 0 auto;
  padding: 3px 8px;
  border-radius: 3px;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 900;
  font-size: 11px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: #fff6e0;
  background: linear-gradient(105deg, #e11d48, #f59e0b);
  box-shadow: 0 0 14px rgba(244, 63, 94, .45), inset 0 1px rgba(255, 255, 255, .28);
  clip-path: polygon(5px 0, 100% 0, calc(100% - 5px) 100%, 0 100%);
}

.avail-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .05em;
  line-height: 1.1;
  text-transform: uppercase;
}
.avail-tag.inj {
  color: #ffe4e6;
  background: rgba(244, 63, 94, .28);
  box-shadow: inset 0 0 0 1px rgba(244, 63, 94, .65);
}
.avail-tag.sus {
  color: #fef3c7;
  background: rgba(245, 158, 11, .26);
  box-shadow: inset 0 0 0 1px rgba(245, 185, 66, .68);
}

.node-cap {
  position: absolute;
  top: -5px;
  right: -5px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-family: var(--font-main);
  font-size: 9px;
  font-weight: 900;
  line-height: 1;
  color: #1c1200;
  background: linear-gradient(135deg, #fde047, #f59e0b);
  box-shadow: 0 0 0 1.5px #071226, 0 2px 6px rgba(0, 0, 0, .55);
}
.node-out {
  position: absolute;
  bottom: -6px;
  left: 50%;
  transform: translateX(-50%);
  padding: 1px 5px;
  border-radius: 3px;
  font-family: var(--font-main);
  font-size: 8px;
  font-weight: 900;
  letter-spacing: .06em;
  line-height: 1.1;
  color: #fff;
  background: #e11d48;
  box-shadow: 0 0 0 1.5px #071226;
}

.hub-hero-idle {
  justify-content: space-between;
}
.cs-brand-text {
  min-width: 0;
  display: flex;
  flex-direction: column;
}
.cs-field-slot {
  flex: 0 0 auto;
}

/* ---------- Broadcast 2D Matchday Shell (#match-overlay.bc-mode) ---------- */
body.match-open {
  overflow: hidden !important;
}

.match-overlay.bc-mode {
  position: fixed;
  inset: 0;
  z-index: 95;
  height: 100vh;
  height: 100dvh;
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(ellipse 68% 44% at 32% 0%, rgba(15, 123, 122, .26), transparent 64%),
    radial-gradient(ellipse 52% 45% at 88% 100%, color-mix(in srgb, var(--club-primary) 16%, transparent), transparent 68%),
    #040b18;
}

/* Top TV Broadcast Scorebug Bar */
.bc-topbar {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 52px;
  padding: calc(6px + env(safe-area-inset-top, 0px)) max(18px, env(safe-area-inset-right, 0px)) 6px max(18px, env(safe-area-inset-left, 0px));
  background: linear-gradient(100deg, rgba(5, 13, 29, .98), rgba(8, 25, 48, .94));
  border-bottom: 1px solid rgba(130, 224, 214, .2);
  box-shadow: 0 8px 26px rgba(0, 0, 0, .38);
}

.bc-scorebug {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 5px 14px;
  border-radius: 6px;
  background: linear-gradient(135deg, rgba(16, 36, 68, .92), rgba(7, 17, 36, .95));
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14), 0 6px 20px rgba(0, 0, 0, .35);
}
.bc-bug-team {
  display: flex;
  align-items: center;
  gap: 7px;
  flex: 0 0 auto;
}
.bc-swatch {
  width: 16px;
  height: 16px;
  border-radius: 4px;
  flex: 0 0 16px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, .45);
}
.bc-short {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 18px;
  letter-spacing: .04em;
  text-transform: uppercase;
  line-height: 1;
}
.bc-bug-score {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2px 10px;
  border-radius: 4px;
  background: rgba(255, 255, 255, .08);
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 24px;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  color: #fff;
}
.bc-dash {
  color: var(--text-muted);
  font-weight: 700;
  font-size: 16px;
}
.bc-clock {
  padding: 3px 9px;
  border-radius: 4px;
  background: linear-gradient(100deg, #24e5b5, #38bdf8);
  color: #031522;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 16px;
  font-variant-numeric: tabular-nums;
  letter-spacing: .04em;
  line-height: 1;
  min-width: 44px;
  text-align: center;
}
.bc-comp {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .04em;
  color: var(--text-soft);
  text-transform: uppercase;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 210px;
  padding-left: 8px;
  border-left: 1px solid rgba(255, 255, 255, .14);
}
.bc-derby {
  font-size: 10px;
  padding: 2px 7px;
}

/* Broadcast Controls */
.bc-controls {
  display: flex;
  align-items: center;
  gap: 7px;
  flex: 0 0 auto;
}
.bc-btn {
  min-height: 36px;
  padding: 0 13px;
  border: 0;
  border-radius: 5px;
  cursor: pointer;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 14px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #e8f2ff;
  background: rgba(255, 255, 255, .09);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .15);
  transition: background-color .15s, filter .15s, transform .12s;
  white-space: nowrap;
}
.bc-btn:hover:not(:disabled) {
  background: rgba(255, 255, 255, .16);
}
.bc-btn:disabled {
  opacity: .38;
  cursor: not-allowed;
}
.bc-btn-primary {
  color: #031623;
  background: linear-gradient(105deg, #62e6c1, #55c8ee);
  box-shadow: inset 0 1px rgba(255, 255, 255, .3), 0 6px 18px rgba(36, 229, 181, .24);
  clip-path: polygon(6px 0, 100% 0, calc(100% - 6px) 100%, 0 100%);
  padding: 0 16px;
}
.bc-btn-primary:hover:not(:disabled) {
  background: linear-gradient(105deg, #62e6c1, #55c8ee);
  filter: brightness(1.08);
}
.bc-btn-warn {
  color: #1c0905;
  background: linear-gradient(105deg, #f5b942, #fb7185);
  box-shadow: 0 0 16px rgba(245, 185, 66, .42);
}

.bc-seg {
  display: inline-flex;
  padding: 2px;
  border-radius: 5px;
  background: rgba(255, 255, 255, .06);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .12);
}
.bc-seg-btn {
  min-height: 32px;
  min-width: 34px;
  padding: 0 8px;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: var(--text-muted);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 13px;
  cursor: pointer;
  transition: background-color .14s, color .14s;
}
.bc-seg-btn:hover { color: #fff; }
.bc-seg-btn.on {
  color: #031522;
  background: var(--accent-mint);
}

/* Main Split Body (Stage + Touchline Console) */
.bc-body {
  flex: 1 1 0;
  min-height: 0;
  width: 100%;
  max-width: 1480px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 62fr) minmax(0, 38fr);
  gap: 12px;
  padding: 12px max(18px, env(safe-area-inset-right, 0px)) max(12px, env(safe-area-inset-bottom, 0px)) max(18px, env(safe-area-inset-left, 0px));
  overflow: hidden;
}

/* Left Pitch Stage */
.bc-stage {
  min-height: 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  overflow: hidden;
}
.bc-canvas-wrap {
  position: relative;
  flex: 1 1 0;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #072216;
  border: 1px solid rgba(155, 220, 210, .18);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 18px 42px rgba(0, 0, 0, .42), inset 0 0 0 1px rgba(255, 255, 255, .04);
}
.bc-mode #match-canvas {
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  aspect-ratio: auto;
  object-fit: contain;
  display: block;
}

/* Goal Broadcast Lower-Third Banner */
.bc-goal-banner {
  position: absolute;
  left: 50%;
  bottom: 14px;
  transform: translateX(-50%);
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  min-width: 240px;
  max-width: 90%;
  padding: 8px 22px;
  border-radius: 6px;
  background: linear-gradient(120deg, rgba(4, 12, 26, .95), rgba(10, 24, 48, .92));
  border-left: 5px solid var(--goal-c, var(--accent-mint));
  border-right: 5px solid var(--goal-c, var(--accent-mint));
  box-shadow: 0 14px 36px rgba(0, 0, 0, .65), 0 0 26px color-mix(in srgb, var(--goal-c, #24e5b5) 40%, transparent);
  text-align: center;
  pointer-events: none;
  animation: bcBannerIn .28s cubic-bezier(.16, 1, .3, 1) both;
}
@keyframes bcBannerIn {
  from { opacity: 0; transform: translate(-50%, 16px) scale(.94); }
  to { opacity: 1; transform: translate(-50%, 0) scale(1); }
}
.bc-gb-tag {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 12px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--accent-mint);
}
.bc-gb-name {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 900;
  font-size: 26px;
  letter-spacing: .04em;
  text-transform: uppercase;
  line-height: 1;
  color: #fff;
}
.bc-gb-sub {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-soft);
}

/* Slow-Mo Replay Pill */
.bc-replay-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  right: 10px;
  z-index: 12;
  display: flex;
  align-items: center;
  justify-content: space-between;
  pointer-events: none;
}
.bc-rec {
  padding: 4px 10px;
  border-radius: 4px;
  background: rgba(225, 29, 72, .9);
  color: #fff;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 13px;
  letter-spacing: .12em;
  box-shadow: 0 4px 16px rgba(225, 29, 72, .45);
  animation: bcPulseRec 1.1s ease-in-out infinite;
}
@keyframes bcPulseRec {
  0%, 100% { opacity: 1; }
  50% { opacity: .55; }
}
.bc-skip {
  pointer-events: auto;
  min-height: 30px;
  padding: 0 12px;
  border: 0;
  border-radius: 4px;
  background: rgba(5, 13, 29, .86);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .28);
}
.bc-skip:hover {
  background: rgba(255, 255, 255, .18);
}

/* Live Stats Strip Under Pitch */
.bc-stats {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 7px 14px;
  border-radius: 8px;
  background: rgba(7, 17, 36, .88);
  border: 1px solid rgba(255, 255, 255, .1);
}
.bc-stat {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  white-space: nowrap;
}
.bc-stat-poss {
  flex: 1 1 200px;
  min-width: 140px;
}
.bc-stat-k {
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.bc-poss-bar {
  flex: 1;
  height: 6px;
  min-width: 48px;
  display: flex;
  border-radius: 99px;
  overflow: hidden;
  background: rgba(255, 255, 255, .12);
}
.bc-poss-bar > span {
  display: block;
  height: 100%;
  transition: width .35s ease;
}

/* Stage Overlays: Half-Time Dressing Room, Shootout, Full-Time Broadcast Report */
.bc-stage-overlay {
  position: absolute;
  inset: 0;
  z-index: 20;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 12px;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  background: rgba(4, 10, 22, .84);
  backdrop-filter: blur(8px);
}
/* Full-Time report expands cleanly across full matchday viewport so score, MOTM, stats & table breathe */
.bc-stage-overlay:has(.bc-ov-card.wide) {
  position: fixed;
  inset: 0;
  z-index: 105;
  padding: calc(12px + env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) calc(12px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px));
  background: rgba(3, 9, 20, .92);
}

.bc-ov-card {
  width: 100%;
  max-width: 480px;
  margin: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 16px 18px;
  border-radius: 14px;
  background: linear-gradient(155deg, rgba(13, 30, 58, .96), rgba(6, 15, 32, .96));
  border: 1px solid rgba(120, 218, 210, .25);
  box-shadow: 0 24px 60px rgba(0, 0, 0, .55);
}
.bc-ov-card.wide {
  max-width: 680px;
}
.bc-ov-head,
.bc-ft-head {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 3px;
}
.bc-ov-kicker {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--accent-mint);
}
.bc-ov-score {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 900;
  font-size: 28px;
  letter-spacing: .04em;
  line-height: 1.05;
}
.bc-talks {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
.bc-talk {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
  padding: 10px;
  border: 0;
  border-radius: 8px;
  cursor: pointer;
  text-align: left;
  color: #fff;
  font: inherit;
  background: rgba(255, 255, 255, .06);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .13);
  transition: background-color .15s, box-shadow .15s;
}
.bc-talk:hover:not(:disabled) {
  background: rgba(36, 229, 181, .14);
  box-shadow: inset 0 0 0 1px rgba(36, 229, 181, .5);
}
.bc-talk.on {
  background: rgba(36, 229, 181, .2);
  box-shadow: inset 0 0 0 1.5px var(--accent-mint);
}
.bc-talk:disabled:not(.on) {
  opacity: .45;
  cursor: default;
}
.bc-talk strong { font-size: 12px; }
.bc-talk span { font-size: 10.5px; color: var(--text-soft); }

.bc-ov-cta {
  width: 100%;
  min-height: 40px;
  margin-top: 2px;
}

/* Penalty Shootout Log */
.bc-so-log {
  list-style: none;
  max-height: 210px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding-right: 4px;
}
.bc-so-log li {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 12px;
  background: rgba(255, 255, 255, .05);
}
.bc-so-log li.ok strong { margin-left: auto; color: var(--accent-mint); }
.bc-so-log li.miss strong { margin-left: auto; color: var(--accent-red); }
.bc-so-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex: 0 0 10px;
  box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, .6);
}

/* Full-Time Report Details */
.bc-ft-score {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 900;
  font-size: 26px;
  text-transform: uppercase;
}
.bc-ft-score strong {
  font-style: normal;
  font-size: 34px;
  padding: 2px 14px;
  border-radius: 6px;
  background: rgba(255, 255, 255, .08);
  color: #fff;
}
.bc-ft-pens {
  font-size: 11px;
  font-weight: 800;
  color: var(--accent-gold);
}
.bc-ft-scorers {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  font-size: 11px;
  color: var(--text-soft);
}
.bc-ft-scorers > span:first-child { text-align: right; }
.bc-ft-scorers > span:last-child { text-align: left; }

.bc-motm {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 2px;
  padding: 8px 12px;
  border-radius: 8px;
  background: linear-gradient(120deg, color-mix(in srgb, var(--motm-c, #24e5b5) 26%, rgba(8, 20, 42, .9)), rgba(8, 20, 42, .85));
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--motm-c, #24e5b5) 50%, transparent);
}
.bc-motm-k {
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .14em;
  color: var(--accent-gold);
}
.bc-motm strong {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 900;
  font-size: 20px;
  text-transform: uppercase;
  line-height: 1.05;
}
.bc-motm .mono { font-size: 11px; color: var(--text-soft); }

.bc-cmp {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.bc-cmp-row {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr) 56px;
  align-items: center;
  gap: 8px;
  font-size: 11px;
}
.bc-cmp-row > span:first-child { text-align: right; font-weight: 700; }
.bc-cmp-row > span:last-child { text-align: left; font-weight: 700; }
.bc-cmp-mid {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}
.bc-cmp-k {
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.bc-cmp-bar {
  width: 100%;
  height: 5px;
  display: flex;
  border-radius: 99px;
  overflow: hidden;
  background: rgba(255, 255, 255, .1);
}
.bc-cmp-bar > i {
  display: block;
  height: 100%;
}

.bc-ft-table {
  max-height: 150px;
  overflow-y: auto;
  border-top: 1px solid rgba(255, 255, 255, .1);
  border-bottom: 1px solid rgba(255, 255, 255, .1);
}

/* Right Touchline Console Panel */
.bc-console {
  min-height: 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  border-radius: 12px;
  background: linear-gradient(160deg, rgba(11, 25, 49, .92), rgba(5, 13, 29, .9));
  border: 1px solid rgba(255, 255, 255, .11);
  overflow: hidden;
}
.bc-tabs {
  flex: 0 0 auto;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-bottom: 1px solid rgba(255, 255, 255, .1);
  background: rgba(4, 11, 24, .55);
}
.bc-tab {
  position: relative;
  min-height: 38px;
  padding: 0 6px;
  border: 0;
  background: transparent;
  color: var(--text-muted);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 13px;
  letter-spacing: .07em;
  text-transform: uppercase;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  white-space: nowrap;
}
.bc-tab:hover,
.bc-tab.on {
  color: #fff;
}
.bc-tab.on::after {
  content: '';
  position: absolute;
  left: 12%;
  right: 12%;
  bottom: 0;
  height: 2.5px;
  background: var(--accent-mint);
  box-shadow: 0 0 10px rgba(36, 229, 181, .55);
}
.bc-tab-count {
  font-size: 10px;
  font-weight: 800;
  padding: 1px 5px;
  border-radius: 99px;
  background: rgba(255, 255, 255, .1);
  color: var(--accent-mint);
}
.bc-tab-panel {
  flex: 1 1 0;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding: 10px 12px;
}

/* Tab 1: Live Commentary Feed */
.bc-feed {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.bc-comm {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 6px;
  padding: 6px 8px;
  border-radius: 6px;
  border-left: 2px solid rgba(255, 255, 255, .14);
  background: rgba(255, 255, 255, .035);
  font-size: 12px;
  line-height: 1.35;
}
.bc-comm.is-goal {
  border-left-color: var(--accent-mint);
  background: rgba(36, 229, 181, .14);
}
.bc-comm-min {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 13px;
  font-variant-numeric: tabular-nums;
  color: var(--accent-cyan);
  min-width: 26px;
}
.bc-comm-text {
  flex: 1 1 150px;
  color: var(--text-soft);
}
.bc-comm.is-goal .bc-comm-text {
  color: #fff;
}
.bc-badge {
  display: inline-block;
  padding: 1px 6px;
  border-radius: 3px;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .07em;
  text-transform: uppercase;
  flex: 0 0 auto;
}
.bc-badge.b-goal { background: var(--accent-mint); color: #031522; }
.bc-badge.b-save { background: rgba(56, 189, 248, .24); color: #bae6fd; }
.bc-badge.b-card { background: rgba(244, 63, 94, .26); color: #fecdd3; }
.bc-badge.b-sub { background: rgba(167, 139, 250, .24); color: #ddd6fe; }
.bc-badge.b-set-piece { background: rgba(245, 185, 66, .24); color: #fde68a; }

/* Tab 2: Live Tactics */
.bc-tac {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.bc-label {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: 2px;
}
.bc-pills {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}
.bc-pills-wrap {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.bc-pill {
  min-height: 34px;
  padding: 5px 8px;
  border: 0;
  border-radius: 5px;
  cursor: pointer;
  background: rgba(255, 255, 255, .06);
  color: var(--text-soft);
  font: inherit;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .04em;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .12);
}
.bc-pill:hover { color: #fff; background: rgba(255, 255, 255, .11); }
.bc-pill.on {
  color: #031623;
  background: var(--accent-mint);
  box-shadow: 0 0 14px rgba(36, 229, 181, .3);
}
.bc-select {
  width: 100%;
  min-height: 36px;
  padding-top: 6px;
  padding-bottom: 6px;
}
.bc-hint {
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.35;
}

/* Tab 3: Live Substitutions */
.bc-subs {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 8px;
  margin-top: 6px;
}
.bc-subs > div {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.bc-row {
  width: 100%;
  min-height: 32px;
  padding: 4px 7px;
  border: 0;
  border-radius: 5px;
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, .045);
  color: #fff;
  font: inherit;
  font-size: 11px;
  text-align: left;
  cursor: pointer;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .08);
}
.bc-row:hover:not(:disabled) {
  background: rgba(255, 255, 255, .1);
}
.bc-row:disabled {
  opacity: .42;
  cursor: not-allowed;
}
.bc-row.sel {
  background: rgba(36, 229, 181, .18);
  box-shadow: inset 0 0 0 1.5px var(--accent-mint);
}
.bc-row-pos {
  flex: 0 0 28px;
  font-size: 10px;
  font-weight: 900;
  color: var(--accent-mint);
}
.bc-row-name {
  flex: 1;
  min-width: 0;
  font-weight: 700;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.bc-row-rt {
  min-width: 24px;
  text-align: right;
  font-weight: 800;
  color: var(--text-soft);
}

/* Tab 4: Live Ratings Table & Card Pips */
.bc-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11.5px;
  font-variant-numeric: tabular-nums;
}
.bc-table th {
  padding: 5px 4px;
  text-align: left;
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--text-muted);
  border-bottom: 1px solid rgba(255, 255, 255, .12);
}
.bc-table th:nth-child(n+3),
.bc-table td:nth-child(n+3) {
  text-align: center;
}
.bc-table th:last-child,
.bc-table td:last-child {
  text-align: right;
}
.bc-table td {
  padding: 5px 4px;
  border-bottom: 1px solid rgba(255, 255, 255, .06);
  white-space: nowrap;
}
.bc-table tr.is-off {
  opacity: .52;
}
.bc-cap {
  display: inline-grid;
  place-items: center;
  width: 15px;
  height: 15px;
  border-radius: 50%;
  font-size: 9px;
  font-weight: 900;
  color: #1c1200;
  background: var(--accent-gold);
  vertical-align: middle;
}
.bc-yc,
.bc-rc {
  display: inline-block;
  width: 8px;
  height: 11px;
  border-radius: 1.5px;
  vertical-align: middle;
}
.bc-yc { background: #facc15; box-shadow: 0 0 6px rgba(250, 204, 21, .45); }
.bc-rc { background: #f43f5e; box-shadow: 0 0 6px rgba(244, 63, 94, .5); }

/* ---------- iPhone 15 Pro Landscape (~852x393) No-Scroll Broadcast Mode ---------- */
@media (orientation: landscape) and (max-height: 520px) {
  .bc-topbar {
    height: 40px;
    min-height: 40px;
    padding: 0 max(12px, env(safe-area-inset-right, 0px)) 0 max(12px, env(safe-area-inset-left, 0px));
    gap: 8px;
  }
  .bc-scorebug {
    padding: 3px 9px;
    gap: 7px;
  }
  .bc-swatch { width: 12px; height: 12px; flex-basis: 12px; }
  .bc-short { font-size: 14px; }
  .bc-bug-score { font-size: 18px; padding: 1px 7px; gap: 4px; }
  .bc-dash { font-size: 12px; }
  .bc-clock { font-size: 13px; padding: 2px 6px; min-width: 34px; }
  .bc-comp { font-size: 9.5px; max-width: 125px; padding-left: 6px; }
  .bc-controls { gap: 5px; }
  .bc-btn { min-height: 28px; padding: 0 9px; font-size: 11.5px; }
  .bc-btn-primary { padding: 0 12px; }
  .bc-seg-btn { min-height: 24px; min-width: 26px; padding: 0 5px; font-size: 11px; }

  .bc-body {
    grid-template-columns: minmax(0, 61fr) minmax(0, 39fr);
    gap: 8px;
    padding: 6px max(12px, env(safe-area-inset-right, 0px)) max(6px, env(safe-area-inset-bottom, 0px)) max(12px, env(safe-area-inset-left, 0px));
  }
  .bc-stage { gap: 5px; }
  .bc-canvas-wrap { border-radius: 8px; }
  .bc-stats { padding: 4px 9px; gap: 8px; border-radius: 6px; }
  .bc-stat { font-size: 10.5px; gap: 5px; }
  .bc-stat-k { font-size: 8.5px; }
  .bc-stat-poss { min-width: 110px; }
  .bc-poss-bar { height: 5px; }

  .bc-console { border-radius: 8px; }
  .bc-tab { min-height: 30px; font-size: 11.5px; }
  .bc-tab-count { font-size: 9px; padding: 0 4px; }
  .bc-tab-panel { padding: 6px 8px; }
  .bc-comm { padding: 4px 6px; font-size: 10.5px; gap: 5px; }
  .bc-comm-min { font-size: 11px; min-width: 22px; }
  .bc-badge { font-size: 8px; padding: 1px 4px; }
  .bc-tac { gap: 5px; }
  .bc-label { font-size: 8.5px; }
  .bc-pill { min-height: 26px; font-size: 10px; padding: 3px 6px; }
  .bc-select { min-height: 30px; font-size: 11px; }
  .bc-hint { font-size: 10px; }
  .bc-subs { gap: 5px; margin-top: 4px; }
  .bc-row { min-height: 25px; padding: 2px 5px; font-size: 10px; gap: 4px; }
  .bc-row-pos { flex-basis: 24px; font-size: 9px; }
  .bc-table { font-size: 10.5px; }
  .bc-table th, .bc-table td { padding: 3px; }
  .bc-table .pos-badge { min-width: 28px; font-size: 9px; padding: 1px 4px; }

  .bc-goal-banner { bottom: 8px; padding: 5px 14px; min-width: 190px; }
  .bc-gb-tag { font-size: 10px; }
  .bc-gb-name { font-size: 19px; }
  .bc-gb-sub { font-size: 9.5px; }
  .bc-replay-badge { top: 6px; left: 6px; right: 6px; }
  .bc-rec { font-size: 10.5px; padding: 2px 7px; }
  .bc-skip { min-height: 24px; font-size: 9.5px; padding: 0 8px; }

  .bc-stage-overlay { padding: 6px; }
  .bc-ov-card { padding: 10px 12px; gap: 6px; border-radius: 10px; }
  .bc-ov-score { font-size: 20px; }
  .bc-talks { gap: 5px; }
  .bc-talk { padding: 6px 7px; }
  .bc-talk strong { font-size: 10.5px; }
  .bc-talk span { font-size: 9px; }
  .bc-ov-cta { min-height: 32px; font-size: 12px; }
  .bc-ft-score { font-size: 20px; }
  .bc-ft-score strong { font-size: 26px; padding: 1px 10px; }
  .bc-motm { padding: 5px 8px; }
  .bc-motm strong { font-size: 16px; }
  .bc-ft-table { max-height: 105px; }
}

/* ---------- Portrait Phones (~390x844) Stacked Broadcast Mode ---------- */
@media (max-width: 640px) and (orientation: portrait) {
  .bc-topbar {
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
    padding: calc(8px + env(safe-area-inset-top, 0px)) 10px 8px;
  }
  .bc-scorebug {
    justify-content: center;
    flex-wrap: wrap;
    padding: 5px 8px;
    gap: 6px;
  }
  .bc-comp {
    display: none;
  }
  .bc-controls {
    justify-content: space-between;
    gap: 5px;
  }
  .bc-btn {
    min-height: 34px;
    padding: 0 9px;
    font-size: 12px;
  }
  .bc-seg-btn {
    min-height: 30px;
    min-width: 28px;
    padding: 0 6px;
    font-size: 11px;
  }
  .bc-body {
    grid-template-columns: 1fr;
    grid-template-rows: auto minmax(0, 1fr);
    gap: 8px;
    padding: 8px 10px calc(8px + env(safe-area-inset-bottom, 0px));
  }
  .bc-canvas-wrap {
    flex: 0 0 auto;
    aspect-ratio: 1200 / 760;
    width: 100%;
  }
  .bc-stats {
    flex-wrap: wrap;
    padding: 6px 8px;
    gap: 6px 10px;
  }
  .bc-stat-poss {
    flex-basis: 100%;
  }
  .bc-talks {
    grid-template-columns: 1fr;
  }
  .bc-subs {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  .bc-goal-banner,
  .bc-rec {
    animation: none !important;
  }
}


/* =====================================================================
   STEP 2 (v1.0.6) · CONSOLE SQUAD HUB, FC 27 PROFILE & 3-TAB FC IQ PITCH
   ===================================================================== */

/* ---------- 1. Console Squad Hub (.sq-*) ---------- */
.sq-console {
  display: flex;
  flex-direction: column;
  gap: 10px;
  height: calc(100dvh - 180px);
  min-height: 440px;
}
.sq-bar {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--hairline);
}
.sq-bar-left,
.sq-bar-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.sq-title {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 900;
  font-size: 21px;
  letter-spacing: .04em;
  text-transform: uppercase;
  line-height: 1;
}
.sq-sort-lbl {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .1em;
  color: var(--text-muted);
}
.sq-pills {
  display: inline-flex;
  gap: 4px;
  padding: 2px;
  border-radius: 6px;
  background: rgba(255, 255, 255, .05);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .1);
}
.sq-pill {
  min-height: 30px;
  padding: 0 10px;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: var(--text-muted);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 13px;
  letter-spacing: .06em;
  cursor: pointer;
  transition: background-color .14s, color .14s;
}
.sq-pill:hover { color: #fff; }
.sq-pill.on {
  color: #031623;
  background: var(--accent-mint);
}

.sq-roster-wrap {
  flex: 1 1 0;
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  border-radius: 12px;
  background: linear-gradient(155deg, rgba(11, 25, 49, .88), rgba(5, 13, 29, .82));
  border: 1px solid rgba(255, 255, 255, .09);
}
.sq-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.sq-table thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: rgba(6, 16, 34, .96);
  backdrop-filter: blur(8px);
  text-align: left;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 9px 10px;
  border-bottom: 1px solid rgba(255, 255, 255, .12);
  white-space: nowrap;
}
.sq-row {
  cursor: pointer;
  transition: background-color .14s;
}
.sq-row:hover,
.sq-row:focus-visible {
  background: color-mix(in srgb, var(--club-primary) 14%, rgba(255, 255, 255, .04));
  outline: none;
}
.sq-row td {
  padding: 8px 10px;
  border-bottom: 1px solid rgba(255, 255, 255, .06);
  white-space: nowrap;
}
.sq-name-cell {
  display: flex;
  align-items: center;
  gap: 6px;
}
.sq-ovr {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 900;
  color: #fff;
}
.sq-role {
  display: inline-block;
  padding: 1px 6px;
  border-radius: 3px;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .05em;
}
.sq-role.xi { background: rgba(36, 229, 181, .2); color: var(--accent-mint); }
.sq-role.sub { background: rgba(56, 189, 248, .2); color: var(--accent-cyan); }
.sq-role.res { background: rgba(255, 255, 255, .08); color: var(--text-muted); }

.sq-fit-cell {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
}
.sq-fit-bar {
  width: 34px;
  height: 5px;
  border-radius: 99px;
  background: rgba(255, 255, 255, .12);
  overflow: hidden;
  display: inline-block;
}
.sq-fit-bar > i {
  display: block;
  height: 100%;
}

/* ---------- 2. Signature FC 27 Borderless Player Profile (.pf-*) ---------- */
.pf-console {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.pf-topbar {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--hairline);
}
.pf-tabs {
  display: flex;
  align-items: center;
  gap: 18px;
  overflow-x: auto;
  scrollbar-width: none;
}
.pf-tabs::-webkit-scrollbar { display: none; }
.pf-tab {
  position: relative;
  min-height: 32px;
  padding: 4px 2px;
  border: 0;
  background: transparent;
  color: var(--text-muted);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 15px;
  letter-spacing: .06em;
  text-transform: uppercase;
  cursor: pointer;
  white-space: nowrap;
}
.pf-tab:hover,
.pf-tab.on { color: #fff; }
.pf-tab.on::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: -9px;
  height: 2.5px;
  background: var(--accent-mint);
  box-shadow: 0 0 10px rgba(36, 229, 181, .5);
}

.pf-nav {
  display: flex;
  align-items: center;
  gap: 5px;
  flex: 0 0 auto;
}
.pf-arrow,
.pf-counter,
.pf-back {
  min-height: 32px;
  border: 0;
  border-radius: 5px;
  cursor: pointer;
  color: #fff;
  background: rgba(255, 255, 255, .08);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14);
  font: inherit;
  font-size: 12px;
  font-weight: 800;
  transition: background-color .14s;
}
.pf-arrow {
  width: 34px;
  display: grid;
  place-items: center;
  font-size: 11px;
}
.pf-counter {
  padding: 0 11px;
  letter-spacing: .04em;
  color: var(--accent-mint);
}
.pf-back {
  padding: 0 12px;
}
.pf-arrow:hover,
.pf-counter:hover,
.pf-back:hover {
  background: rgba(255, 255, 255, .16);
}

.pf-stage {
  min-height: 0;
}
.pf-details {
  min-width: 0;
  display: flex;
  flex-direction: column;
}
.pf-body {
  min-height: 0;
}
.pf-mood-note {
  font-size: 11.5px;
  align-self: center;
  margin-left: 4px;
}

.pf-attr-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.pf-attr-side {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.pf-card {
  padding: 12px 14px;
  border-radius: 10px;
  background: rgba(9, 22, 44, .72);
  border: 1px solid rgba(255, 255, 255, .09);
}
.pf-card-h {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 14px;
  letter-spacing: .07em;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.pf-meter-row { margin-bottom: 7px; }
.pf-meter-row:last-child { margin-bottom: 0; }
.pf-meter-head {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.pf-meter-row .meter { height: 5px; margin: 4px 0 0; }
.pf-gp-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
  font-size: 12px;
}
.pf-desc { font-size: 12px; line-height: 1.4; }
.pf-ps-chip {
  font-size: 10.5px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 999px;
  color: #fff;
  background: rgba(56, 189, 248, .18);
  border: 1px solid rgba(56, 189, 248, .42);
}
.pf-btn-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.pf-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.pf-stat-box {
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(9, 22, 44, .72);
  border: 1px solid rgba(255, 255, 255, .09);
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.pf-stat-box small {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--text-muted);
}
.pf-stat-box strong {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 900;
  line-height: 1.05;
}

/* ---------- 3. No-Scroll Interactive FC IQ Tactics Console (.tac-*) ---------- */
.tac-console {
  display: grid;
  grid-template-columns: minmax(0, 50fr) minmax(0, 50fr);
  gap: 14px;
  height: calc(100dvh - 180px);
  min-height: 490px;
}

.tac-pitch-stage {
  min-height: 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.tac-stage-bar {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.tac-ratings {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-soft);
}
.tac-ratings strong {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 900;
}
.tac-autopick {
  min-height: 32px;
  padding: 0 13px;
  border: 0;
  border-radius: 4px;
  cursor: pointer;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 13px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #031522;
  background: linear-gradient(100deg, #62e6c1, #55c8ee);
  clip-path: polygon(6px 0, 100% 0, calc(100% - 6px) 100%, 0 100%);
}
.tac-autopick:hover { filter: brightness(1.08); }

.tac-pitch-wrap {
  flex: 1 1 0;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.tac-pitch-wrap .pitch-board {
  height: 100%;
  width: auto;
  max-width: 100%;
  max-height: 100%;
  aspect-ratio: 4 / 5;
}
.node-pos-lbl {
  font-size: 9px;
  font-weight: 800;
  text-shadow: 0 1px 3px #000;
  line-height: 1.1;
}

.tac-rolebar {
  flex: 0 0 auto;
  padding: 8px 10px;
  border-radius: 8px;
  background: rgba(7, 17, 36, .88);
  border: 1px solid rgba(255, 255, 255, .1);
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.tac-rb-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.tac-rb-id {
  display: flex;
  align-items: baseline;
  gap: 8px;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  font-size: 12px;
}
.tac-rb-id strong {
  overflow: hidden;
  text-overflow: ellipsis;
}
.tac-rb-roles {
  display: flex;
  gap: 5px;
  overflow-x: auto;
  scrollbar-width: none;
}
.tac-rb-roles::-webkit-scrollbar { display: none; }
.tac-role-chip {
  flex: 0 0 auto;
  min-height: 26px;
  padding: 0 9px;
  border: 0;
  border-radius: 4px;
  background: rgba(255, 255, 255, .07);
  color: var(--text-soft);
  font: inherit;
  font-size: 10.5px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .12);
  white-space: nowrap;
}
.tac-role-chip b { color: var(--accent-mint); }
.tac-role-chip.on {
  color: #031522;
  background: var(--accent-mint);
}
.tac-role-chip.on b { color: #031522; }

.tac-mini-btn {
  flex: 0 0 auto;
  min-height: 26px;
  padding: 0 9px;
  border: 0;
  border-radius: 4px;
  background: rgba(255, 255, 255, .12);
  color: #fff;
  font: inherit;
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
}
.tac-mini-btn:hover { background: rgba(255, 255, 255, .2); }
.tac-hint {
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.35;
}

/* Right 3-Tab Tactics Console Panel */
.tac-panel {
  min-height: 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  border-radius: 12px;
  background: linear-gradient(160deg, rgba(11, 25, 49, .9), rgba(5, 13, 29, .86));
  border: 1px solid rgba(255, 255, 255, .1);
  overflow: hidden;
}
.tac-tabs {
  flex: 0 0 auto;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-bottom: 1px solid rgba(255, 255, 255, .1);
  background: rgba(4, 11, 24, .55);
}
.tac-tab {
  position: relative;
  min-height: 38px;
  padding: 0 6px;
  border: 0;
  background: transparent;
  color: var(--text-muted);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 13.5px;
  letter-spacing: .07em;
  text-transform: uppercase;
  cursor: pointer;
}
.tac-tab:hover,
.tac-tab.on { color: #fff; }
.tac-tab.on::after {
  content: '';
  position: absolute;
  left: 14%;
  right: 14%;
  bottom: 0;
  height: 2.5px;
  background: var(--accent-mint);
  box-shadow: 0 0 10px rgba(36, 229, 181, .5);
}

.tac-panel-body {
  flex: 1 1 0;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding: 10px 12px;
}

.tac-list-group { margin-bottom: 12px; }
.tac-list-group:last-child { margin-bottom: 0; }
.tac-group-h {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 6px;
}
.tac-sub-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.tac-sub-row {
  width: 100%;
  min-height: 34px;
  padding: 4px 8px;
  border: 0;
  border-radius: 6px;
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, .04);
  color: #fff;
  font: inherit;
  font-size: 12px;
  text-align: left;
  cursor: pointer;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .07);
}
.tac-sub-row:hover { background: rgba(255, 255, 255, .09); }
.tac-sub-row.sel {
  background: rgba(36, 229, 181, .18);
  box-shadow: inset 0 0 0 1.5px var(--accent-mint);
}
.tac-sub-row.is-out { opacity: .68; }
.tac-sub-name {
  flex: 1;
  min-width: 0;
  font-weight: 700;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tac-sub-ovr {
  font-family: var(--font-display);
  font-size: 16px;
  min-width: 24px;
  text-align: right;
}
.tac-sub-fit {
  min-width: 44px;
  text-align: right;
  font-size: 11px;
  font-weight: 700;
}

/* Tactics Tab Pills */
.tac-setup {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.tac-pill-grid {
  display: grid;
  gap: 6px;
}
.tac-pill-grid.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.tac-pill-grid.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.tac-pill-grid.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.tac-opt-pill {
  min-height: 34px;
  padding: 4px 8px;
  border: 0;
  border-radius: 5px;
  cursor: pointer;
  background: rgba(255, 255, 255, .06);
  color: var(--text-soft);
  font: inherit;
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: .04em;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .11);
}
.tac-opt-pill:hover { color: #fff; background: rgba(255, 255, 255, .12); }
.tac-opt-pill.on {
  color: #031522;
  background: var(--accent-mint);
  box-shadow: 0 0 14px rgba(36, 229, 181, .28);
}
.tac-vis-desc {
  padding: 8px 10px;
  border-radius: 6px;
  background: rgba(255, 255, 255, .04);
  border-left: 3px solid var(--accent-mint);
  font-size: 11.5px;
  color: var(--text-soft);
}

/* Set Pieces Cards & Instant Picker Modal */
.tac-sp-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.tac-sp-card {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 10px 12px;
  border: 0;
  border-radius: 8px;
  background: rgba(255, 255, 255, .05);
  color: #fff;
  font: inherit;
  text-align: left;
  cursor: pointer;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .1);
}
.tac-sp-card:hover {
  background: color-mix(in srgb, var(--club-primary) 16%, rgba(255, 255, 255, .06));
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--club-primary) 50%, white);
}
.tac-sp-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}
.tac-sp-lbl {
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.tac-sp-badge {
  padding: 2px 6px;
  border-radius: 3px;
  font-size: 9px;
  font-weight: 900;
  background: rgba(56, 189, 248, .22);
  color: #bae6fd;
}
.tac-sp-badge.gold {
  background: var(--accent-gold);
  color: #1c1200;
}
.tac-sp-name {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 18px;
  letter-spacing: .02em;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tac-sp-meta {
  display: flex;
  justify-content: space-between;
  font-size: 10.5px;
  color: var(--text-soft);
}

.tac-pick-list {
  display: flex;
  flex-direction: column;
  gap: 5px;
  max-height: 55vh;
  overflow-y: auto;
}
.tac-pick-item {
  width: 100%;
  min-height: 38px;
  padding: 6px 10px;
  border: 0;
  border-radius: 6px;
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, .05);
  color: #fff;
  font: inherit;
  font-size: 12.5px;
  text-align: left;
  cursor: pointer;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .09);
}
.tac-pick-item:hover { background: rgba(255, 255, 255, .12); }
.tac-pick-item.on {
  background: rgba(36, 229, 181, .18);
  box-shadow: inset 0 0 0 1.5px var(--accent-mint);
}
.tac-pick-name {
  flex: 1;
  min-width: 0;
  font-weight: 700;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tac-pick-stat {
  color: var(--accent-mint);
  font-size: 12px;
}

/* ---------- iPhone 15 Pro Landscape (~852x393) No-Scroll Step 2 Polish ---------- */
@media (orientation: landscape) and (max-height: 520px) {
  .sq-console {
    height: calc(100dvh - 92px);
    min-height: 0;
    gap: 6px;
  }
  .sq-bar { padding-bottom: 5px; gap: 6px; }
  .sq-title { font-size: 15px; }
  .sq-pill { min-height: 24px; padding: 0 7px; font-size: 11px; }
  .sq-table { font-size: 11px; }
  .sq-table thead th { padding: 5px 6px; font-size: 9px; }
  .sq-row td { padding: 4px 6px; }
  .sq-ovr { font-size: 14px; }
  .sq-fit-bar { width: 24px; height: 4px; }
  .sq-col-form { display: none; }

  .pf-console {
    height: calc(100dvh - 92px);
    gap: 7px;
    overflow: hidden;
  }
  .pf-topbar { padding-bottom: 4px; gap: 8px; }
  .pf-tab { min-height: 24px; font-size: 12.5px; padding: 2px 0; }
  .pf-tab.on::after { bottom: -5px; }
  .pf-arrow, .pf-counter, .pf-back { min-height: 24px; font-size: 10.5px; }
  .pf-arrow { width: 26px; }
  .pf-counter { padding: 0 8px; }
  .pf-stage {
    flex: 1 1 0;
    min-height: 0;
    align-items: stretch;
  }
  .pf-details {
    min-height: 0;
    overflow: hidden;
  }
  .pf-body {
    flex: 1 1 0;
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
  }
  .pf-mood-note { display: none; }
  .pf-card { padding: 8px 10px; }
  .pf-card-h { font-size: 11.5px; margin-bottom: 5px; }
  .pf-stats-grid { gap: 6px; }
  .pf-stat-box { padding: 6px 8px; }
  .pf-stat-box strong { font-size: 18px; }

  .tac-console {
    height: calc(100dvh - 92px);
    min-height: 0;
    grid-template-columns: minmax(0, 48fr) minmax(0, 52fr);
    gap: 10px;
    overflow: hidden;
  }
  .tac-pitch-stage { gap: 4px; }
  .tac-ratings { gap: 8px; font-size: 10.5px; }
  .tac-ratings strong { font-size: 14px; }
  .tac-autopick { min-height: 24px; padding: 0 9px; font-size: 11px; }
  .tac-pitch-wrap .pitch-node { width: 64px; }
  .tac-pitch-wrap .node-circle { width: 27px; height: 27px; font-size: 11px; margin-bottom: 1px; border-width: 1.5px; }
  .tac-pitch-wrap .node-cap { width: 13px; height: 13px; font-size: 7.5px; top: -4px; right: -4px; }
  .tac-pitch-wrap .node-out { font-size: 7px; padding: 0 3px; bottom: -5px; }
  .tac-pitch-wrap .node-name { font-size: 8.5px; padding: 1px 3px; }
  .tac-pitch-wrap .node-pos-lbl { font-size: 7.5px; }
  .tac-pitch-wrap .node-fit { width: 32px; height: 3px; margin-top: 1px; }

  .tac-rolebar { padding: 4px 7px; gap: 3px; border-radius: 6px; }
  .tac-rb-id { font-size: 10.5px; }
  .tac-role-chip { min-height: 22px; padding: 0 7px; font-size: 9.5px; }
  .tac-mini-btn { min-height: 22px; padding: 0 7px; font-size: 10px; }
  .tac-hint { font-size: 9.5px; }

  .tac-panel { border-radius: 8px; }
  .tac-tab { min-height: 28px; font-size: 11.5px; }
  .tac-panel-body { padding: 6px 8px; }
  .tac-group-h { font-size: 8.5px; margin-bottom: 4px; }
  .tac-sub-row { min-height: 26px; padding: 2px 6px; font-size: 10.5px; gap: 6px; }
  .tac-sub-row .pos-badge { min-width: 28px; font-size: 9px; padding: 1px 4px; }
  .tac-sub-ovr { font-size: 13.5px; }
  .tac-sub-fit { font-size: 10px; min-width: 36px; }
  .tac-setup { gap: 5px; }
  .tac-pill-grid { gap: 4px; }
  .tac-opt-pill { min-height: 25px; font-size: 10px; padding: 2px 5px; }
  .tac-vis-desc { padding: 5px 8px; font-size: 10px; }
  .tac-sp-grid { gap: 6px; }
  .tac-sp-card { padding: 6px 8px; gap: 2px; }
  .tac-sp-name { font-size: 14px; }
  .tac-sp-meta { font-size: 9.5px; }
}

/* ---------- Portrait Phones (~390x844) Step 2 Stacked Mode ---------- */
@media (max-width: 640px) and (orientation: portrait) {
  .sq-console { height: auto; min-height: 0; }
  .sq-col-gp, .sq-col-form { display: none; }
  .sq-table { font-size: 12px; }
  .sq-row td, .sq-table thead th { padding: 7px 6px; }

  .pf-topbar { flex-wrap: wrap; gap: 8px; }
  .pf-attr-grid { grid-template-columns: 1fr; }
  .pf-stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .tac-console {
    grid-template-columns: 1fr;
    height: auto;
    min-height: 0;
  }
  .tac-pitch-wrap .pitch-board {
    width: 100%;
    height: auto;
    max-height: 460px;
  }
  .tac-panel-body { max-height: 360px; }
  .tac-pill-grid.cols-4 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .tac-sp-grid { grid-template-columns: 1fr; }
}
