/* =========================================================
   La Polla Mundialista — app.css (Shared: player/register/admin)
   ✅ Tema claro/oscuro premium (data-theme="light|dark")
   ✅ Panels centrados / ancho controlado
   ✅ Modal (reset password) legible en dark/light
   ✅ Toast legible en dark/light
   ========================================================= */

/* -----------------------------
   1) TOKENS (LIGHT DEFAULT)
   ----------------------------- */
:root {
  /* Layout */
  --radius-lg: 22px;
  --radius: 18px;
  --radius-sm: 14px;
  --btn-primary-start: #128731;
  --btn-primary-end: #0d9c50;
  --intro-video-object-position: 50% 50%;
  --intro-media-max-width: 980px;
  --intro-media-max-height: 560px;

  /* Light theme */
  --bg0: #f5f7fb;
  --bg1: #eef2ff;

  --card: rgba(255, 255, 255, 0.92);
  --card-soft: rgba(255, 255, 255, 0.78);

  --text: rgba(15, 23, 42, 0.92);
  --muted: rgba(15, 23, 42, 0.62);
  --faint: rgba(15, 23, 42, 0.42);

  --border: rgba(15, 23, 42, 0.1);
  --border-2: rgba(15, 23, 42, 0.16);

  --primary: #2563eb;
  --primary-2: #1d4ed8;

  --danger: #ef4444;
  --ok: #22c55e;
  --warn: #f59e0b;

  --shadow: 0 20px 55px rgba(2, 6, 23, 0.1);
  --shadow-2: 0 10px 25px rgba(2, 6, 23, 0.08);

  --focus: rgba(37, 99, 235, 0.18);

  /* Toast */
  --toast-bg: rgba(15, 23, 42, 0.92);
  --toast-text: rgba(255, 255, 255, 0.92);
}

/* -----------------------------
   2) TOKENS (DARK PREMIUM)
   ----------------------------- */
html[data-theme="dark"],
body[data-theme="dark"] {
  --bg0: #0b1020;
  --bg1: #0a0f1c;

  /* glass */
  --card: rgba(255, 255, 255, 0.08);
  --card-soft: rgba(255, 255, 255, 0.06);

  --text: rgba(255, 255, 255, 0.92);
  --muted: rgba(255, 255, 255, 0.62);
  --faint: rgba(255, 255, 255, 0.4);

  --border: rgba(255, 255, 255, 0.12);
  --border-2: rgba(255, 255, 255, 0.18);

  --shadow: 0 22px 70px rgba(0, 0, 0, 0.45);
  --shadow-2: 0 10px 28px rgba(0, 0, 0, 0.35);

  --focus: rgba(59, 130, 246, 0.22);

  --toast-bg: rgba(17, 24, 38, 0.95);
  --toast-text: rgba(255, 255, 255, 0.92);
}

/* -----------------------------
   3) BASE
   ----------------------------- */
* {
  box-sizing: border-box;
}
html,
body {
  height: 100%;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
img,
video,
svg {
  display: block;
  max-width: 100%;
}
body {
  margin: 0;
  font-family:
    ui-sans-serif,
    system-ui,
    -apple-system,
    Segoe UI,
    Roboto,
    Arial;
  color: var(--text);
  background:
    radial-gradient(
      1100px 600px at 20% 10%,
      rgba(37, 99, 235, 0.14),
      transparent 60%
    ),
    radial-gradient(
      900px 540px at 80% 20%,
      rgba(34, 197, 94, 0.1),
      transparent 62%
    ),
    radial-gradient(
      1200px 700px at 50% 100%,
      rgba(168, 85, 247, 0.1),
      transparent 60%
    ),
    linear-gradient(180deg, var(--bg0), var(--bg1));
}

body.tenant-bg-enabled {
  background-image: var(--tenant-bg-image) !important;
  background-color: transparent;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-attachment: fixed;
}
html[data-theme="light"] body.tenant-bg-enabled,
body[data-theme="light"].tenant-bg-enabled {
  background-image: var(--tenant-bg-image) !important;
}

body.intro-active {
  height: 100svh;
  overflow: hidden;
}

body.intro-active .app-shell {
  display: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Helpers */
.hidden {
  display: none !important;
}
.view {
  display: block;
}
.muted {
  color: var(--muted) !important;
}
.small {
  font-size: 12px;
}
.w-auto {
  width: auto;
  margin-top: 0;
}
.row {
  display: flex;
  gap: 10px;
  align-items: center;
}
.row.wrap {
  flex-wrap: wrap;
}
.row.space-between {
  justify-content: space-between;
}

/* -----------------------------
   4) APP SHELL (shared)
   ----------------------------- */
#app {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Topbar/Header */
.topbar {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(12px);
  background: rgba(245, 247, 251, 0.7);
}
html[data-theme="dark"] .header,
html[data-theme="dark"] .topbar,
body[data-theme="dark"] .header,
body[data-theme="dark"] .topbar {
  background: rgba(9, 12, 16, 0.6);
}

.topbar .brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-dot {
  width: 12px;
  height: 12px;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--btn-primary-start), var(--btn-primary-end));
  box-shadow: 0 0 0 6px rgba(18, 135, 49, 0.08);
}

.brand-title {
  font-weight: 800;
  letter-spacing: -0.02em;
}

.brand-sub {
  font-size: 12px;
  color: var(--muted);
}

.brand-logo {
  width: 50px;
  height: 38px;
  object-fit: contain;
  display: block;
}

.login-logo-wrap {
  display: flex;
  justify-content: center;
  margin: 18px 0 14px;
}

.login-logo {
  width: min(140px, 40vw);
  height: auto;
  object-fit: contain;
}

html[data-theme="dark"] .logo,
body[data-theme="dark"] .logo {
  background: rgba(255, 255, 255, 0.08);
}
.title {
  font-weight: 800;
  letter-spacing: -0.02em;
}
.subtitle {
  font-size: 12px;
  color: var(--muted);
  margin-top: 2px;
}

/* Main area: control width to avoid “super extendido” */
.main {
  flex: 1;
  padding: 18px 18px 60px;
  width: 100%;
  max-width: 1080px; /* ✅ central panel */
  margin: 0 auto;
}
@media (min-width: 1100px) {
  .main {
    max-width: 1040px;
  }
}

/* ================================
   Admin – Top Grid Layout
   ================================ */

.admin-top-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr; /* derecha un poco más ancha */
  gap: 24px;
  margin-bottom: 28px;
}

/* Cards dentro del grid */
.admin-top-grid > .card {
  height: 100%;
}

/* Responsive: tablets y mobile */
@media (max-width: 1024px) {
  .admin-top-grid {
    grid-template-columns: 1fr;
  }
}

/* Sesión actual más visible */
#sessionBox {
  padding: 10px 12px;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.04);
  font-weight: 500;
}

/* Dark mode */
[data-theme="dark"] #sessionBox {
  background: rgba(255, 255, 255, 0.06);
}

.footer {
  padding: 14px 16px;
  border-top: 1px solid var(--border);
  text-align: center;
}
.logout-footer {
  max-width: 320px;
}
footer.footer {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 28px 16px 20px;
}

/* Espacio debajo del botón */
.footer #btnHeaderLogout {
  width: auto; /* ya no full width */
  min-width: 180px; /* tamaño cómodo */
  padding: 8px 18px; /* más pequeño */
  font-size: 14px;
  border-radius: 14px;
}

/* Centered auth layout (register/player login blocks) */
.center {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}
.auth-card {
  max-width: 520px;
  width: 100%;
}

/* -----------------------------
   5) CARDS / SECTIONS
   ----------------------------- */
.card,
section.card {
  background: linear-gradient(180deg, var(--card), var(--card-soft));
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px;
  box-shadow: var(--shadow-2);
  backdrop-filter: blur(14px);
  contain: layout paint;
}

h1,
h2,
h3 {
  letter-spacing: -0.02em;
}
h1 {
  margin: 0 0 10px;
  font-size: 22px;
  font-weight: 800;
}
h2 {
  margin: 0 0 10px;
  font-size: 16px;
  font-weight: 800;
}
h3 {
  margin: 0 0 10px;
  font-size: 15px;
  font-weight: 800;
}
p {
  margin: 8px 0 14px;
}

/* -----------------------------
   6) FORMS
   ----------------------------- */
label {
  display: block;
  margin: 10px 0 6px;
  font-size: 12px;
  color: var(--muted);
  font-weight: 600;
}
input,
select,
textarea {
  width: 100%;
  padding: 11px 12px;
  font-size: 15px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.92);
  color: var(--text);
  outline: none;
  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease,
    background 0.15s ease;
}
html[data-theme="dark"] input,
html[data-theme="dark"] select,
html[data-theme="dark"] textarea,
body[data-theme="dark"] input,
body[data-theme="dark"] select,
body[data-theme="dark"] textarea {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.12);
}
input::placeholder,
textarea::placeholder {
  color: rgba(15, 23, 42, 0.4);
}
html[data-theme="dark"] input::placeholder,
html[data-theme="dark"] textarea::placeholder,
body[data-theme="dark"] input::placeholder,
body[data-theme="dark"] textarea::placeholder {
  color: rgba(255, 255, 255, 0.38);
}
input:focus,
select:focus,
textarea:focus {
  border-color: rgba(37, 99, 235, 0.55);
  box-shadow: 0 0 0 4px var(--focus);
}

/* -----------------------------
   7) BUTTONS
   ----------------------------- */
button,
.btn {
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(4, 166, 150, 0.3);
  background: linear-gradient(
    180deg,
    var(--btn-primary-start),
    var(--btn-primary-end)
  );
  color: #fff;
  cursor: pointer;
  font-weight: 700;
  box-shadow: 0 12px 24px rgba(37, 99, 235, 0.16);
  transition:
    transform 0.08s ease,
    filter 0.12s ease,
    box-shadow 0.12s ease;
}
button:hover,
.btn:hover {
  filter: brightness(1.03);
}
button:active,
.btn:active {
  transform: translateY(1px);
}
button:disabled,
.btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  box-shadow: none;
}

.btn {
  width: 100%;
  margin-top: 12px;
}
.btn.primary {
  background: linear-gradient(
    180deg,
    var(--btn-primary-start),
    var(--btn-primary-end)
  );
}
.btn.danger,
button.danger,
.btn-danger {
  background: linear-gradient(180deg, #ef4444, #dc2626) !important;
  border: 1px solid rgba(239, 68, 68, 0.5) !important;
  box-shadow: 0 12px 24px rgba(239, 68, 68, 0.22) !important;
}
html[data-theme="dark"] .btn.danger,
html[data-theme="dark"] button.danger,
html[data-theme="dark"] .btn-danger,
body[data-theme="dark"] .btn.danger,
body[data-theme="dark"] button.danger,
body[data-theme="dark"] .btn-danger {
  background: linear-gradient(180deg, #f87171, #ef4444) !important;
  border-color: rgba(248, 113, 113, 0.55) !important;
  box-shadow: 0 12px 24px rgba(248, 113, 113, 0.22) !important;
}
.btn.ghost {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text);
  box-shadow: none;
}

/* ✅ Ghost readable in LIGHT (like “Atrás”, “Cancelar”) */
body[data-theme="light"] .btn.ghost,
html[data-theme="light"] .btn.ghost {
  background: rgba(15, 23, 42, 0.06);
  color: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(15, 23, 42, 0.12);
}
body[data-theme="light"] .btn.ghost:hover,
html[data-theme="light"] .btn.ghost:hover {
  background: rgba(15, 23, 42, 0.1);
}
/* ✅ Ghost readable in DARK */
body[data-theme="dark"] .btn.ghost,
html[data-theme="dark"] .btn.ghost {
  background: rgba(255, 255, 255, 0.07);
  color: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.btn.secondary,
button.secondary,
.btn-secondary {
  background: rgba(15, 23, 42, 0.06) !important;
  color: rgba(15, 23, 42, 0.86) !important;
  border: 1px solid rgba(15, 23, 42, 0.1) !important;
  box-shadow: none !important;
}
html[data-theme="dark"] .btn.secondary,
html[data-theme="dark"] button.secondary,
html[data-theme="dark"] .btn-secondary,
body[data-theme="dark"] .btn.secondary,
body[data-theme="dark"] button.secondary,
body[data-theme="dark"] .btn-secondary {
  background: rgba(255, 255, 255, 0.07) !important;
  color: rgba(255, 255, 255, 0.88) !important;
  border: 1px solid rgba(255, 255, 255, 0.14) !important;
}

/* Icon button (theme toggle) */
.btn-icon,
#btnThemeToggle,
#btnTheme {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  margin-top: 0;
  background: rgba(255, 255, 255, 0.7) !important;
  border: 1px solid var(--border) !important;
  color: var(--text) !important;
  box-shadow: var(--shadow-2);
}
html[data-theme="dark"] .btn-icon,
html[data-theme="dark"] #btnThemeToggle,
html[data-theme="dark"] #btnTheme,
body[data-theme="dark"] .btn-icon,
body[data-theme="dark"] #btnThemeToggle,
body[data-theme="dark"] #btnTheme {
  background: rgba(255, 255, 255, 0.07) !important;
  border-color: rgba(255, 255, 255, 0.12) !important;
}

/* Logout button text contrast */
#btnHeaderLogout,
#btnLogout {
  color: inherit;
}

/* -----------------------------
   8) TABS / PILLS
   ----------------------------- */
.tabs {
  display: flex;
  gap: 10px;
  margin: 12px 0;
}
.tab {
  flex: 1;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.6);
  cursor: pointer;
  font-weight: 800;
  color: var(--text);
}
html[data-theme="dark"] .tab,
body[data-theme="dark"] .tab {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
}
.tab.active {
  border-color: rgba(37, 99, 235, 0.35);
  background: rgba(37, 99, 235, 0.14);
}

/* Player: tabs legibles sobre cualquier fondo */
body.player-page .tab,
html body.player-page .tab {
  background: rgba(255, 255, 255, 0.78);
  border-color: rgba(15, 23, 42, 0.18);
  color: #0f172a;
  backdrop-filter: blur(10px) saturate(140%);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.12);
}
body.player-page .tab.active,
html body.player-page .tab.active {
  background: linear-gradient(180deg, #0ea5e9, #2563eb);
  border-color: rgba(37, 99, 235, 0.7);
  color: #fff;
  text-shadow: 0 1px 0 rgba(15, 23, 42, 0.25);
  box-shadow:
    0 10px 22px rgba(37, 99, 235, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.35);
}
body.player-page[data-theme="dark"] .tab,
html[data-theme="dark"] body.player-page .tab {
  background: rgba(15, 23, 42, 0.55);
  border-color: rgba(148, 163, 184, 0.22);
  color: #e2e8f0;
  box-shadow: 0 8px 18px rgba(2, 6, 23, 0.35);
}

.pill {
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.6);
  color: var(--text);
  padding: 8px 10px;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 800;
}
html[data-theme="dark"] .pill,
body[data-theme="dark"] .pill {
  background: rgba(255, 255, 255, 0.09);
}

/* -----------------------------
   9) PLAYER MATCH CARDS
   ----------------------------- */
.list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.match {
  background: linear-gradient(180deg, var(--card), var(--card-soft));
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 14px;
  box-shadow: var(--shadow-2);
  contain: layout paint;
}

.match--prediction {
  background:
    radial-gradient(120% 120% at 0% 0%, rgba(37, 99, 235, 0.08), transparent 42%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(248, 250, 252, 0.94));
  border-color: rgba(148, 163, 184, 0.18);
  box-shadow:
    0 18px 36px rgba(15, 23, 42, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

html[data-theme="dark"] .match--prediction,
body[data-theme="dark"] .match--prediction {
  background:
    radial-gradient(120% 120% at 0% 0%, rgba(37, 99, 235, 0.16), transparent 42%),
    linear-gradient(180deg, rgba(21, 28, 42, 0.94), rgba(13, 18, 30, 0.94));
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow:
    0 18px 36px rgba(0, 0, 0, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
}
.match-top {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
}
.match-head {
  min-width: 0;
}
.teams-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  margin-top: 12px;
}
.team {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  text-align: center;
  min-width: 0;
}
.team-flag {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  font-size: 24px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-2);
  overflow: hidden;
}
.team-flag-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
html[data-theme="dark"] .team-flag,
body[data-theme="dark"] .team-flag {
  background: rgba(255, 255, 255, 0.08);
}
.team-flag-placeholder {
  font-size: 18px;
  color: var(--faint);
}
.team-name {
  font-weight: 900;
  line-height: 1.2;
  text-wrap: balance;
  text-transform: uppercase;
}
.team.is-pending .team-name {
  color: var(--muted);
}
.teams-vs {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.meta {
  font-size: 12px;
  color: var(--muted);
  margin-top: 4px;
}
.countdown {
  color: var(--ok);
  font-weight: 800;
  letter-spacing: 0.02em;
}

.badge {
  font-size: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  height: fit-content;
  color: var(--text);
  background: rgba(255, 255, 255, 0.55);
}
html[data-theme="dark"] .badge,
body[data-theme="dark"] .badge {
  background: rgba(255, 255, 255, 0.08);
}
.badge.open {
  border-color: rgba(34, 197, 94, 0.25);
  background: rgba(34, 197, 94, 0.12);
}
.badge.live {
  border-color: rgba(239, 68, 68, 0.25);
  background: rgba(239, 68, 68, 0.12);
}
.badge.final {
  border-color: var(--border);
}

.pred-row {
  display: flex;
  gap: 10px;
  margin-top: 12px;
  align-items: center;
}
.pred-row input {
  text-align: center;
  font-weight: 900;
  padding: 10px 0;
  color: rgba(15, 23, 42, 0.92);
  -webkit-text-fill-color: rgba(15, 23, 42, 0.92);
  caret-color: rgba(15, 23, 42, 0.92);
}

.pred-row input::placeholder {
  color: rgba(100, 116, 139, 0.68);
  -webkit-text-fill-color: rgba(100, 116, 139, 0.68);
}

.pred-row input:disabled {
  color: rgba(15, 23, 42, 0.58);
  -webkit-text-fill-color: rgba(15, 23, 42, 0.58);
  opacity: 1;
}
.pred-row .dash {
  color: var(--muted);
  font-weight: 900;
}

.match-footer {
  margin-top: 10px;
  font-size: 13px;
  color: var(--muted);
  display: grid;
  gap: 8px;
  overflow-wrap: anywhere;
}

.match-footer__line {
  min-width: 0;
}
.kpi {
  margin-top: 8px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.chip {
  font-size: 12px;
  border: 1px solid var(--border);
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.6);
  color: var(--text);
}
html[data-theme="dark"] .chip,
body[data-theme="dark"] .chip {
  background: rgba(255, 255, 255, 0.06);
}
.chip.ok {
  border-color: rgba(34, 197, 94, 0.25);
  background: rgba(34, 197, 94, 0.1);
}
.chip.warn {
  border-color: rgba(245, 158, 11, 0.25);
  background: rgba(245, 158, 11, 0.1);
}
.chip.bad {
  border-color: rgba(239, 68, 68, 0.25);
  background: rgba(239, 68, 68, 0.1);
}

.chip.live-red {
  border-color: rgba(239, 68, 68, 0.35);
  background: rgba(239, 68, 68, 0.14);
  color: #dc2626;
}

html[data-theme="dark"] .chip.live-red,
body[data-theme="dark"] .chip.live-red {
  border-color: rgba(248, 113, 113, 0.32);
  background: rgba(127, 29, 29, 0.32);
  color: #fca5a5;
}

#viewRules .row.space-between {
  gap: 14px;
}

#viewRules .row.space-between > div:first-child,
#viewRules .row.space-between > div:last-child {
  min-width: 0;
}

#viewRules .row.wrap {
  gap: 10px;
}

#viewRules .row.wrap .pill {
  margin-top: 0;
}

#viewRules .integrated-card,
#viewRules h2,
#viewRules p.muted,
#viewRules .hint,
#rulesMount,
#rulesMount .rules-section,
#rulesMount .table-card,
#rulesMount .table-scroll {
  min-width: 0;
  max-width: 100%;
}

#viewRules .integrated-card {
  width: 100%;
  overflow: visible;
}

#rulesMount {
  min-width: 0;
}

#rulesMount .rules-section + .rules-section {
  margin-top: 18px;
}

#rulesMount .rules-accordion-item {
  margin-top: 12px;
}

#rulesMount .rules-accordion-trigger {
  min-height: 52px;
  padding-inline: 14px;
}

#rulesMount .rules-accordion-body {
  overflow-wrap: anywhere;
}

#rulesMount .rules-bullets {
  overflow-wrap: anywhere;
}

#rulesMount .rules-examples-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

#rulesMount .rules-example-card .row.space-between {
  gap: 10px;
}

#rulesMount .rules-scoring-mobile {
  display: none;
  gap: 10px;
}

#rulesMount .rules-score-card {
  padding: 12px;
}

#rulesMount .rules-score-card__head,
#rulesMount .rules-example-card__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
}

#rulesMount .rules-score-card__title,
#rulesMount .rules-example-card__title {
  min-width: 0;
  overflow-wrap: anywhere;
}

#rulesMount .rules-score-card__points {
  flex: 0 0 auto;
}

#rulesMount .rules-score-card__desc {
  margin-top: 8px;
  overflow-wrap: anywhere;
}

#rulesMount .table-scroll {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

#rulesMount .table {
  min-width: 620px;
  width: max-content;
  table-layout: auto;
}

#rulesMount .table th,
#rulesMount .table td {
  vertical-align: top;
  overflow-wrap: anywhere;
  word-break: break-word;
}

#rulesMount .table th:nth-child(2),
#rulesMount .table td:nth-child(2) {
  text-align: center;
 }

#viewRules {
  padding-bottom: calc(var(--bn-h) + env(safe-area-inset-bottom) + 20px);
}

@media (min-width: 769px) {
  #viewRules,
  #viewRules .integrated-card,
  #rulesMount,
  #rulesMount .rules-section {
    width: 100%;
    min-width: 0;
    max-width: 100%;
  }

  #rulesMount .rules-scoring-table {
    overflow-x: hidden;
  }

  #rulesMount .table {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    table-layout: fixed;
  }

  #rulesMount .table th:nth-child(1),
  #rulesMount .table td:nth-child(1) {
    width: 24%;
  }

  #rulesMount .table th:nth-child(2),
  #rulesMount .table td:nth-child(2) {
    width: 10%;
  }

  #rulesMount .table th:nth-child(3),
  #rulesMount .table td:nth-child(3) {
    width: 66%;
  }
}

/* -----------------------------
   10) LEADERBOARD LIST
   ----------------------------- */
.lb-list {
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.lb-item {
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.7);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
html[data-theme="dark"] .lb-item,
body[data-theme="dark"] .lb-item {
  background: rgba(255, 255, 255, 0.06);
}
.lb-left {
  display: flex;
  gap: 10px;
  align-items: center;
}
.rank {
  width: 28px;
  text-align: center;
  color: var(--muted);
  font-weight: 900;
}
.me {
  border-color: rgba(37, 99, 235, 0.35);
  background: rgba(37, 99, 235, 0.12);
}

.lb-item.lb-pinned {
  border-color: rgba(34, 197, 94, 0.38);
  background: rgba(34, 197, 94, 0.12);
  box-shadow: 0 8px 18px rgba(16, 185, 129, 0.14);
}

/* -----------------------------
   11) TABLES (ADMIN)
   ----------------------------- */
.table-scroll {
  overflow: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-x pan-y pinch-zoom;
}

.tabulator-tableholder {
  touch-action: pan-x pan-y pinch-zoom;
}
.table {
  width: 100%;
  border-collapse: collapse;
  min-width: 680px;
}
.table th,
.table td {
  padding: 10px;
  border-bottom: 1px solid var(--border);
}
.table th {
  text-align: left;
  font-size: 13px;
  color: var(--muted);
  font-weight: 900;
}
.table .right {
  text-align: right;
}

.table-card {
  margin-top: 12px;
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
html[data-theme="dark"] .table-card,
body[data-theme="dark"] .table-card {
  background: rgba(255, 255, 255, 0.04);
}
.table-card__header {
  padding: 10px 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid var(--border);
}
.table-card__title {
  font-weight: 900;
}

/* Hints / JSON blocks */
.hint {
  margin: 8px 0;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(37, 99, 235, 0.1);
  color: var(--muted);
}
html[data-theme="light"] .hint,
body[data-theme="light"] .hint {
  background: rgba(255, 255, 255, 0.92);
  border-left: 4px solid rgba(37, 99, 235, 0.85);
}
html[data-theme="dark"] .hint,
body[data-theme="dark"] .hint {
  background: rgba(255, 255, 255, 0.06);
  color: var(--muted);
  border-left: 4px solid rgba(59, 130, 246, 0.7);
}

pre,
.json-example {
  margin: 8px 0 12px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(2, 6, 23, 0.06);
  color: var(--text);
  overflow-x: auto;
  white-space: pre-wrap;
}
html[data-theme="dark"] pre,
html[data-theme="dark"] .json-example,
body[data-theme="dark"] pre,
body[data-theme="dark"] .json-example {
  background: rgba(0, 0, 0, 0.25);
  border-color: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.88);
}

/* Separators */
hr,
.sep {
  border: none;
  border-top: 1px solid var(--border);
  margin: 14px 0;
}

/* -----------------------------
   12) TOAST
   ----------------------------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%);
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--toast-bg);
  color: var(--toast-text);
  box-shadow: var(--shadow-2);
  font-weight: 800;
  z-index: 9999;
}
.toast.success {
  color: #ecfeff;
}
.toast.error {
  color: #fee2e2;
}

/* -----------------------------
   13) SELECT (tenant dropdown)
   ----------------------------- */
#tenantSelect,
#tenantId {
  color: var(--text) !important;
  opacity: 1 !important;
  background: rgba(255, 255, 255, 0.7) !important;
  border: 1px solid var(--border) !important;
}
html[data-theme="dark"] #tenantSelect,
html[data-theme="dark"] #tenantId,
body[data-theme="dark"] #tenantSelect,
body[data-theme="dark"] #tenantId {
  background: rgba(255, 255, 255, 0.08) !important;
  border-color: rgba(255, 255, 255, 0.18) !important;
}
/* Opciones del desplegable (Chrome/Safari) */
#tenantSelect option {
  color: #111 !important;
  background: #fff !important;
}
#tenantSelect option[value=""] {
  color: #666 !important;
}

/* -----------------------------
   14) MODAL (Reset Password)
   ----------------------------- */
.modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none; /* hidden by default */
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(2, 6, 23, 0.55);
  backdrop-filter: blur(8px);
}
.modal:not(.hidden) {
  display: flex;
}

.modal-card {
  width: min(520px, 100%);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, var(--card), var(--card-soft));
  color: var(--text);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  padding: 16px;
}

.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.icon-btn {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.5);
  color: var(--text);
  cursor: pointer;
  font-weight: 900;
}
html[data-theme="dark"] .icon-btn,
body[data-theme="dark"] .icon-btn {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.92);
}

.modal-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  margin-top: 14px;
}

/* Ensure cancel/ghost in modal always readable */
.modal .btn.ghost {
  margin-top: 0;
}

/* -----------------------------
   15) MISC
   ----------------------------- */
.msg {
  margin-top: 10px;
  font-size: 13px;
  color: var(--muted);
  min-height: 18px;
}
.msg.is-visible {
  min-height: 0;
}
.msg.error {
  color: #ffb4b4;
}
.msg.ok {
  color: #b6ffce;
}

.auth-panel .msg {
  display: none;
  margin-top: 14px;
  min-height: 0;
}

.auth-panel .msg.is-visible {
  display: block;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid transparent;
  line-height: 1.45;
  font-size: 13px;
  font-weight: 700;
  box-shadow: 0 14px 34px rgba(2, 6, 23, 0.14);
}

.auth-panel .msg.error {
  color: #ffd6d6;
  border-color: rgba(248, 113, 113, 0.3);
  background:
    linear-gradient(180deg, rgba(127, 29, 29, 0.44), rgba(69, 10, 10, 0.3)),
    rgba(255, 255, 255, 0.03);
}

.auth-panel .msg.ok {
  color: #dcfce7;
  border-color: rgba(34, 197, 94, 0.28);
  background:
    linear-gradient(180deg, rgba(20, 83, 45, 0.4), rgba(20, 83, 45, 0.26)),
    rgba(255, 255, 255, 0.03);
}

body[data-theme="light"] .auth-panel .msg.error {
  color: #991b1b;
  border-color: rgba(239, 68, 68, 0.16);
  background: linear-gradient(180deg, rgba(254, 242, 242, 0.98), rgba(254, 226, 226, 0.96));
  box-shadow: 0 16px 28px rgba(239, 68, 68, 0.08);
}

body[data-theme="light"] .auth-panel .msg.ok {
  color: #166534;
  border-color: rgba(34, 197, 94, 0.16);
  background: linear-gradient(180deg, rgba(240, 253, 244, 0.98), rgba(220, 252, 231, 0.96));
  box-shadow: 0 16px 28px rgba(34, 197, 94, 0.08);
}

.stats-head {
  gap: 16px;
}

.stats-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.stats-kpi {
  border: 1px solid var(--border);
  background: var(--card-soft);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow-2);
}

.stats-kpi__value {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.stats-kpi__label {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}

.stats-toolbar {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.stats-filter {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.stats-panels-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 18px;
}

.stats-panel {
  border: 1px solid var(--border);
  background: var(--card-soft);
  border-radius: var(--radius);
  padding: 16px;
  min-width: 0;
}

.stats-panel__title {
  font-weight: 700;
  margin-bottom: 12px;
}

.module-guide {
  margin: 16px 0 18px;
  padding: 16px;
  border-radius: var(--radius);
  border: 1px solid rgba(15, 23, 42, 0.08);
  background:
    radial-gradient(circle at top right, rgba(37, 99, 235, 0.08), transparent 32%),
    linear-gradient(180deg, rgba(255,255,255,0.96), rgba(247,250,252,0.92));
  box-shadow: var(--shadow-2);
}

html[data-theme="dark"] .module-guide,
body[data-theme="dark"] .module-guide {
  border-color: rgba(255,255,255,0.08);
  background:
    radial-gradient(circle at top right, rgba(59, 130, 246, 0.14), transparent 32%),
    linear-gradient(180deg, rgba(11,18,35,0.92), rgba(13,20,38,0.88));
  box-shadow: none;
}

.module-guide__head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 14px;
}

.module-guide__eyebrow {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted);
}

.module-guide__head h3 {
  margin-top: 6px;
  font-size: 24px;
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.module-guide__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.module-guide__item {
  display: grid;
  gap: 6px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255,255,255,0.54);
}

html[data-theme="dark"] .module-guide__item,
body[data-theme="dark"] .module-guide__item {
  border-color: rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.04);
}

.module-guide__item strong {
  font-size: 15px;
  letter-spacing: -0.02em;
}

.module-guide__item span {
  color: var(--muted);
  line-height: 1.45;
  font-size: 14px;
}

.stats-chart {
  width: 100%;
  min-height: 320px;
}

.stats-team-snapshot {
  min-height: 320px;
}

.stats-team-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.stats-team-card__name {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.stats-team-card__summary-note {
  font-size: 13px;
  color: var(--muted);
}

.stats-team-card__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.stats-team-card__grid--compact {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.stats-team-card__grid div {
  border-radius: var(--radius-sm);
  background: var(--card);
  border: 1px solid var(--border);
  padding: 14px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.stats-team-card__stat {
  flex: 1 1 112px;
  min-width: 112px;
}

.stats-team-card__grid strong {
  font-size: 22px;
}

.stats-team-card__grid span {
  color: var(--muted);
  font-size: 12px;
}

.stats-team-card__abbr {
  display: block;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.stats-team-card__stat small {
  display: block;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.25;
}

.stats-breakdown {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.stats-breakdown__block {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px;
  background: var(--card);
}

.stats-breakdown__label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--muted);
  margin-bottom: 12px;
}

.stats-meter {
  display: grid;
  grid-template-columns: 88px 1fr minmax(78px, 92px);
  gap: 10px;
  align-items: center;
  margin-bottom: 10px;
}

.stats-meter__track {
  position: relative;
  height: 10px;
  border-radius: 999px;
  background: rgba(18, 135, 49, 0.12);
  overflow: hidden;
}

.stats-meter__track i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #128731, #0d9c50);
}

.stats-meter__track--warn {
  background: rgba(245, 158, 11, 0.14);
}

.stats-meter__track--warn i {
  background: linear-gradient(90deg, #f59e0b, #fbbf24);
}

.stats-meter__track--danger {
  background: rgba(239, 68, 68, 0.14);
}

.stats-meter__track--danger i {
  background: linear-gradient(90deg, #ef4444, #f87171);
}

.stats-team-recent {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px;
  background: var(--card);
}

.stats-recent-item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  align-items: start;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
}

.stats-recent-item:last-child {
  border-bottom: 0;
}

.stats-table {
  min-height: 320px;
}

.stats-compare-toolbar {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.stats-compare-mount {
  min-height: 120px;
}

.stats-compare-note {
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 13px;
}

.stats-compare-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  align-items: start;
}

.stats-compare-stage {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.stats-compare-team {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--card);
  padding: 14px;
}

.stats-compare-team--right {
  text-align: right;
}

.stats-compare-team__name {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.stats-compare-team__meta {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}

.stats-compare-recent {
  margin-top: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.stats-compare-recent__item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 8px;
  align-items: center;
}

#viewStats .tabulator {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: transparent;
}

#viewStats .tabulator .tabulator-header,
#viewStats .tabulator .tabulator-footer {
  background: var(--card);
  border-color: var(--border);
}

#viewStats .tabulator .tabulator-row {
  background: transparent;
  border-color: var(--border);
}

#viewStats .tabulator .tabulator-cell,
#viewStats .tabulator .tabulator-col {
  border-color: var(--border);
}

#viewStats .tabulator .tabulator-row.tabulator-row-even {
  background: rgba(255, 255, 255, 0.03);
}

.world-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 220px;
}

.world-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  margin-top: 18px;
  padding: 24px;
  border-radius: 34px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background:
    radial-gradient(120% 120% at 0% 0%, rgba(115, 190, 255, 0.18), transparent 42%),
    radial-gradient(140% 140% at 100% 100%, rgba(74, 222, 128, 0.1), transparent 46%),
    linear-gradient(145deg, rgba(14, 24, 40, 0.98), rgba(24, 36, 72, 0.94) 56%, rgba(20, 32, 58, 0.98));
  color: #f8fafc;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 20px;
  align-items: end;
  box-shadow:
    0 18px 44px rgba(15, 23, 42, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.1),
    inset 0 -1px 0 rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(22px) saturate(1.08);
}

.world-hero::before,
.world-hero::after {
  content: "";
  position: absolute;
  inset: auto;
  pointer-events: none;
  z-index: -1;
}

.world-hero::before {
  top: -82px;
  right: -38px;
  width: 240px;
  height: 240px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0));
  opacity: 0.8;
}

.world-hero::after {
  left: 22px;
  bottom: 18px;
  width: 180px;
  height: 1px;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.28), rgba(255, 255, 255, 0));
}

body[data-theme="light"] .world-hero {
  border-color: rgba(148, 163, 184, 0.24);
  background:
    radial-gradient(120% 120% at 0% 0%, rgba(96, 165, 250, 0.18), transparent 42%),
    radial-gradient(140% 140% at 100% 100%, rgba(125, 211, 252, 0.12), transparent 46%),
    linear-gradient(145deg, rgba(249, 251, 255, 0.96), rgba(236, 242, 255, 0.92) 54%, rgba(229, 237, 250, 0.94));
  color: rgba(15, 23, 42, 0.96);
  box-shadow:
    0 22px 48px rgba(148, 163, 184, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.88),
    inset 0 -1px 0 rgba(148, 163, 184, 0.08);
}

body[data-theme="light"] .world-hero::before {
  background: radial-gradient(circle, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0));
  opacity: 0.92;
}

body[data-theme="light"] .world-hero::after {
  background: linear-gradient(90deg, rgba(148, 163, 184, 0.28), rgba(148, 163, 184, 0));
}

.world-hero__eyebrow {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  font-weight: 800;
  opacity: 0.66;
}

.world-hero__title {
  margin-top: 8px;
  font-size: clamp(28px, 3vw, 44px);
  line-height: 0.96;
  font-weight: 900;
  letter-spacing: -0.055em;
  max-width: 10ch;
  text-wrap: balance;
}

.world-hero__copy {
  margin-top: 14px;
  max-width: 34ch;
  font-size: 17px;
  line-height: 1.42;
  color: rgba(248, 250, 252, 0.76);
}

body[data-theme="light"] .world-hero__copy {
  color: rgba(15, 23, 42, 0.68);
}

.world-status-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: flex-end;
  align-self: stretch;
  align-content: flex-end;
}

.world-status-badges .chip {
  min-width: 168px;
  padding: 12px 16px;
  border-radius: 18px;
  border-color: rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.08);
  color: rgba(248, 250, 252, 0.94);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 12px 26px rgba(8, 15, 32, 0.12);
  backdrop-filter: blur(14px);
}

.world-status-badges .chip b {
  display: block;
  margin-bottom: 4px;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  opacity: 0.66;
}

body[data-theme="light"] .world-status-badges .chip {
  border-color: rgba(148, 163, 184, 0.2);
  background: rgba(255, 255, 255, 0.54);
  color: rgba(15, 23, 42, 0.88);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.82),
    0 10px 24px rgba(148, 163, 184, 0.14);
}

.world-status-badges .chip.ok {
  border-color: rgba(52, 211, 153, 0.24);
  background: linear-gradient(180deg, rgba(16, 185, 129, 0.14), rgba(16, 185, 129, 0.08));
}

body[data-theme="light"] .world-status-badges .chip.ok {
  border-color: rgba(16, 185, 129, 0.24);
  background: linear-gradient(180deg, rgba(16, 185, 129, 0.14), rgba(236, 253, 245, 0.86));
}

.world-panel {
  overflow: hidden;
}

.world-panel--upcoming,
.world-panel--recent,
.world-panel--table {
  background: linear-gradient(180deg, rgba(255,255,255,0.9), rgba(255,255,255,0.75));
}

html[data-theme="dark"] .world-panel--upcoming,
html[data-theme="dark"] .world-panel--recent,
html[data-theme="dark"] .world-panel--table,
body[data-theme="dark"] .world-panel--upcoming,
body[data-theme="dark"] .world-panel--recent,
body[data-theme="dark"] .world-panel--table {
  background: linear-gradient(180deg, rgba(17,24,39,0.9), rgba(17,24,39,0.75));
}

.world-live-board,
.world-fixture-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 220px;
}

#worldUpcomingList,
#worldRecentList {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(240px, 280px);
  gap: 12px;
  overflow-x: auto;
  overflow-y: visible;
  overscroll-behavior-x: contain;
  overscroll-behavior-y: auto;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-x pan-y pinch-zoom;
  scroll-snap-type: x proximity;
  padding-bottom: 6px;
}

#worldUpcomingList > *,
#worldRecentList > * {
  scroll-snap-align: start;
}

.world-empty {
  min-height: 180px;
  display: grid;
  place-items: center;
  text-align: center;
  color: var(--muted);
  border: 1px dashed var(--border);
  border-radius: var(--radius-sm);
  padding: 16px;
}

.world-empty--live {
  background: linear-gradient(180deg, rgba(255,255,255,0.04), rgba(255,255,255,0.02));
}

.world-empty__title {
  font-weight: 900;
  letter-spacing: -0.03em;
}

.world-empty__copy {
  color: var(--muted);
  max-width: 30ch;
}

.world-live-card,
.world-fixture-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px;
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(8px);
}

.world-fixture-card {
  background:
    radial-gradient(120% 120% at 50% 0%, rgba(99, 102, 241, 0.08), transparent 38%),
    linear-gradient(145deg, rgba(249, 250, 255, 0.98), rgba(239, 244, 255, 0.94));
  min-height: 220px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow:
    0 14px 32px rgba(148, 163, 184, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.84);
}

html[data-theme="dark"] .world-fixture-card,
body[data-theme="dark"] .world-fixture-card {
  border-color: rgba(255,255,255,0.08);
  background:
    radial-gradient(120% 120% at 50% 0%, rgba(96, 165, 250, 0.14), transparent 40%),
    linear-gradient(145deg, rgba(11, 18, 39, 0.98), rgba(27, 32, 68, 0.94));
  box-shadow:
    0 18px 38px rgba(2, 6, 23, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.world-live-card__top,
.world-fixture-card__top {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
  align-items: center;
}

.world-fixture-card__date {
  font-size: 12px;
  color: var(--muted);
  font-weight: 700;
}

.world-fixture-card__headline {
  margin-bottom: 12px;
  text-align: center;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.world-live-card__match,
.world-fixture-card__teams {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 10px;
  align-items: center;
}

.world-live-card__team--right {
  text-align: right;
}

.world-live-card__score {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 68px;
  padding: 8px 10px;
  border-radius: 999px;
  background: linear-gradient(180deg, #0b1537, #101a44);
  color: #fff;
  font-weight: 800;
}

.world-fixture-card__divider {
  color: var(--muted);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 12px;
}

.world-fixture-card__teams--showcase {
  gap: 14px;
  align-items: center;
}

.world-fixture-card__team {
  display: grid;
  justify-items: center;
  gap: 10px;
  min-width: 0;
  text-align: center;
}

.world-fixture-card__team--away {
  justify-items: center;
}

.world-fixture-card__crest {
  width: 54px;
  height: 54px;
  border-radius: 999px;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(148, 163, 184, 0.2);
  box-shadow: 0 8px 18px rgba(148, 163, 184, 0.14);
}

html[data-theme="dark"] .world-fixture-card__crest,
body[data-theme="dark"] .world-fixture-card__crest {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: 0 8px 20px rgba(2, 6, 23, 0.2);
}

.world-fixture-card__crest img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.world-fixture-card__team-name {
  min-width: 0;
  font-size: 15px;
  line-height: 1.18;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

.world-fixture-card__center {
  display: grid;
  justify-items: center;
  gap: 8px;
}

.world-fixture-card__calendar {
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
}

.world-fixture-card__score-pill {
  min-width: 84px;
  min-height: 38px;
  padding: 0 16px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.98), rgba(30, 41, 59, 0.94));
  color: #fff;
  font-size: 16px;
  font-weight: 900;
  letter-spacing: -0.03em;
  box-shadow: 0 12px 20px rgba(15, 23, 42, 0.18);
}

html[data-theme="dark"] .world-fixture-card__score-pill,
body[data-theme="dark"] .world-fixture-card__score-pill {
  background: linear-gradient(180deg, rgba(7, 12, 29, 0.98), rgba(12, 18, 42, 0.98));
  box-shadow: 0 12px 22px rgba(2, 6, 23, 0.3);
}

.world-fixture-card__meta {
  margin-top: 14px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 10px;
  text-align: center;
  font-size: 12px;
  color: var(--muted);
}

.world-fixture-card__meta span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.world-table {
  min-height: 240px;
}

.world-card-actions {
  margin-top: 12px;
  display: flex;
  justify-content: flex-end;
}

.match-center-shell {
  margin-top: 18px;
  display: grid;
  grid-template-columns: minmax(280px, 360px) minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.match-center-rail,
.match-center-column {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.world-panel--detail {
  background:
    radial-gradient(circle at top right, rgba(37, 99, 235, 0.08), transparent 34%),
    linear-gradient(180deg, rgba(255,255,255,0.98), rgba(244,247,252,0.94));
  border: 1px solid rgba(15, 23, 42, 0.08);
}

html[data-theme="dark"] .world-panel--detail,
body[data-theme="dark"] .world-panel--detail {
  background:
    radial-gradient(circle at top right, rgba(59, 130, 246, 0.12), transparent 32%),
    linear-gradient(180deg, rgba(8,13,25,0.96), rgba(13,19,35,0.94));
  border-color: rgba(255,255,255,0.08);
}

.match-center-stage {
  min-height: 180px;
}

.match-center-header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
}

.match-center-event {
  margin-top: 8px;
  font-size: 28px;
  line-height: 1.02;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.match-center-meta {
  margin-top: 8px;
  color: var(--muted);
}

.match-center-status {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

.match-center-scoreboard {
  margin-top: 18px;
  padding: 16px 18px;
  border: 1px solid rgba(15, 23, 42, 0.10);
  border-radius: var(--radius);
  background:
    radial-gradient(circle at top left, rgba(18, 135, 49, 0.12), transparent 32%),
    linear-gradient(135deg, rgba(9, 17, 42, 0.98), rgba(17, 28, 68, 0.94));
  color: #f8fafc;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 18px;
  align-items: center;
}

html[data-theme="dark"] .match-center-scoreboard,
body[data-theme="dark"] .match-center-scoreboard {
  border-color: rgba(255,255,255,0.10);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.32);
}

.match-center-team {
  font-size: 18px;
}

.match-center-team--right {
  text-align: right;
}

.match-center-score {
  min-width: 112px;
  text-align: center;
  font-size: 32px;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.match-center-stage-insights {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 14px;
}

.match-center-stage-column {
  min-width: 0;
  padding: 14px 14px 12px;
  border-radius: 18px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.68);
}

html[data-theme="dark"] .match-center-stage-column,
body[data-theme="dark"] .match-center-stage-column {
  border-color: rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
}

.match-center-stage-column--right {
  text-align: right;
}

.match-center-stage-column__title {
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 10px;
}

.match-center-stage-events {
  display: grid;
  gap: 8px;
}

.match-center-stage-events__empty,
.match-center-penalties__empty {
  font-size: 13px;
  color: var(--muted);
}

.match-center-stage-event {
  display: grid;
  grid-template-columns: auto auto minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  min-width: 0;
  font-size: 13px;
}

.match-center-stage-event--away {
  grid-template-columns: minmax(0, 1fr) auto auto;
}

.match-center-stage-event--away .match-center-stage-event__minute,
.match-center-stage-event--away .match-center-stage-event__icon {
  order: 2;
}

.match-center-stage-event--away .match-center-stage-event__label {
  order: 1;
}

.match-center-stage-event__minute {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  min-height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  background: rgba(59, 130, 246, 0.1);
  color: #1d4ed8;
  font-size: 11px;
  font-weight: 900;
}

html[data-theme="dark"] .match-center-stage-event__minute,
body[data-theme="dark"] .match-center-stage-event__minute {
  background: rgba(37, 99, 235, 0.24);
  color: #bfdbfe;
}

.match-center-stage-event__icon,
.match-center-penalties__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.06);
}

html[data-theme="dark"] .match-center-stage-event__icon,
html[data-theme="dark"] .match-center-penalties__icon,
body[data-theme="dark"] .match-center-stage-event__icon,
body[data-theme="dark"] .match-center-penalties__icon {
  background: rgba(255, 255, 255, 0.08);
}

.match-center-stage-event__label {
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-weight: 600;
}

.match-center-penalties {
  margin-top: 14px;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background:
    linear-gradient(180deg, rgba(59, 130, 246, 0.08), rgba(255, 255, 255, 0.78));
}

html[data-theme="dark"] .match-center-penalties,
body[data-theme="dark"] .match-center-penalties {
  border-color: rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(180deg, rgba(37, 99, 235, 0.16), rgba(255, 255, 255, 0.04));
}

.match-center-penalties__title {
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.match-center-penalties__score {
  margin-top: 6px;
  font-size: 18px;
  font-weight: 900;
  letter-spacing: -0.03em;
}

.match-center-penalties__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 12px;
}

.match-center-penalties__item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  min-width: 0;
}

.match-center-penalties__item--away {
  justify-content: flex-end;
  text-align: right;
}

.match-center-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.match-center-block {
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: var(--radius-sm);
  background: linear-gradient(180deg, rgba(255,255,255,0.92), rgba(255,255,255,0.82));
  padding: 14px;
  min-height: 180px;
  box-shadow: var(--shadow-2);
}

.btnOpenMatchCenter {
  margin-top: 10px;
}

html[data-theme="dark"] .match-center-block,
body[data-theme="dark"] .match-center-block {
  border-color: rgba(255,255,255,0.08);
  background: linear-gradient(180deg, rgba(255,255,255,0.06), rgba(255,255,255,0.04));
  box-shadow: none;
}

.match-center-timeline {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(260px, 320px);
  gap: 10px;
  overflow-x: auto;
  overflow-y: visible;
  overscroll-behavior-x: contain;
  overscroll-behavior-y: auto;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-x pan-y pinch-zoom;
  scroll-snap-type: x proximity;
  padding-bottom: 4px;
}

.match-center-timeline__item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  align-items: start;
  padding: 14px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255,255,255,0.94), rgba(247,250,252,0.9));
  min-height: 132px;
  scroll-snap-align: start;
}

html[data-theme="dark"] .match-center-timeline__item,
body[data-theme="dark"] .match-center-timeline__item {
  border-color: rgba(255,255,255,0.08);
  background: linear-gradient(180deg, rgba(255,255,255,0.05), rgba(255,255,255,0.03));
}

.match-center-timeline__headline {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
}

.match-center-timeline__team {
  margin-top: 8px;
}

.match-center-timeline__icon {
  width: 30px;
  height: 30px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 800;
  background: rgba(100, 116, 139, 0.12);
  color: var(--text);
  flex: 0 0 auto;
}

.match-center-timeline__minute {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  min-width: 44px;
  border-radius: 999px;
  background: rgba(239, 68, 68, 0.08);
  color: #dc2626;
  font-weight: 900;
  font-size: 12px;
}

.match-center-timeline__card-body {
  display: grid;
  gap: 10px;
  min-width: 0;
}

html[data-theme="dark"] .match-center-timeline__minute,
body[data-theme="dark"] .match-center-timeline__minute {
  background: rgba(127, 29, 29, 0.28);
  color: #fca5a5;
}

.match-center-timeline__item--goal .match-center-timeline__icon {
  background: rgba(18, 135, 49, 0.14);
  color: #128731;
}

.match-center-timeline__item--yellow .match-center-timeline__icon {
  background: rgba(234, 179, 8, 0.18);
  color: #a16207;
}

.match-center-timeline__item--red .match-center-timeline__icon {
  background: rgba(220, 38, 38, 0.14);
  color: #b91c1c;
}

.match-center-timeline__item--substitution .match-center-timeline__icon {
  background: rgba(37, 99, 235, 0.14);
  color: #1d4ed8;
}

.match-center-timeline__item--penalty .match-center-timeline__icon {
  background: rgba(124, 58, 237, 0.12);
  color: #6d28d9;
}

.match-center-timeline__item--corner .match-center-timeline__icon {
  background: rgba(14, 165, 233, 0.12);
  color: #0369a1;
}

.match-center-timeline__item--offside .match-center-timeline__icon {
  background: rgba(249, 115, 22, 0.12);
  color: #c2410c;
}

.match-center-timeline__item--foul .match-center-timeline__icon {
  background: rgba(244, 63, 94, 0.12);
  color: #be123c;
}

.match-center-timeline__item--freekick .match-center-timeline__icon {
  background: rgba(6, 182, 212, 0.12);
  color: #0f766e;
}

.match-center-timeline__item--shot .match-center-timeline__icon {
  background: rgba(59, 130, 246, 0.12);
  color: #1d4ed8;
}

.match-center-timeline__item--var .match-center-timeline__icon {
  background: rgba(15, 23, 42, 0.10);
  color: #0f172a;
  font-size: 11px;
  letter-spacing: 0.04em;
}

.match-center-lineups__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  min-width: 0;
}

.match-center-lineup-card {
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 14px;
  padding: 12px;
  background: rgba(255,255,255,0.58);
  min-width: 0;
  width: 100%;
  overflow: hidden;
}

html[data-theme="dark"] .match-center-lineup-card,
body[data-theme="dark"] .match-center-lineup-card {
  border-color: rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.03);
}

.match-center-lineup-card__title {
  font-weight: 800;
  margin-bottom: 8px;
}

.match-center-lineup-card__head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  margin-bottom: 8px;
  min-width: 0;
  flex-wrap: wrap;
}

.match-center-lineup-card__formation {
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #16a34a;
  background: rgba(22, 163, 74, 0.10);
  border: 1px solid rgba(22, 163, 74, 0.18);
  border-radius: 999px;
  padding: 6px 10px;
  white-space: normal;
  max-width: 100%;
  text-align: center;
}

html[data-theme="dark"] .match-center-lineup-card__formation,
body[data-theme="dark"] .match-center-lineup-card__formation {
  color: #86efac;
  background: rgba(22, 163, 74, 0.14);
  border-color: rgba(134, 239, 172, 0.16);
}

.match-center-lineup-pitch {
  position: relative;
  display: grid;
  gap: 14px;
  padding: 18px 14px 20px;
  border-radius: 18px;
  border: 1px solid rgba(16, 24, 40, 0.10);
  min-height: 480px;
  background:
    radial-gradient(circle at 50% 45%, rgba(134, 239, 172, 0.18), transparent 0 18%),
    linear-gradient(180deg, rgba(20, 141, 64, 0.72), rgba(16, 112, 51, 0.84)),
    repeating-linear-gradient(
      180deg,
      rgba(255,255,255,0.08) 0,
      rgba(255,255,255,0.08) 24px,
      rgba(255,255,255,0.03) 24px,
      rgba(255,255,255,0.03) 48px
    );
  overflow: hidden;
  min-width: 0;
  width: 100%;
}

html[data-theme="dark"] .match-center-lineup-pitch,
body[data-theme="dark"] .match-center-lineup-pitch {
  border-color: rgba(255,255,255,0.10);
  background:
    radial-gradient(circle at 50% 45%, rgba(134, 239, 172, 0.14), transparent 0 18%),
    linear-gradient(180deg, rgba(21, 128, 61, 0.72), rgba(20, 83, 45, 0.88)),
    repeating-linear-gradient(
      180deg,
      rgba(255,255,255,0.08) 0,
      rgba(255,255,255,0.08) 24px,
      rgba(255,255,255,0.03) 24px,
      rgba(255,255,255,0.03) 48px
    );
}

.match-center-lineup-pitch__half {
  position: absolute;
  left: 10%;
  right: 10%;
  top: 50%;
  border-top: 1px solid rgba(255,255,255,0.38);
}

.match-center-lineup-pitch__circle {
  position: absolute;
  top: calc(50% - 28px);
  left: calc(50% - 28px);
  width: 56px;
  height: 56px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.34);
}

.match-center-lineup-lane {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 10px;
  align-content: center;
}

.match-center-lineup-lane__label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: rgba(255,255,255,0.86);
  text-align: center;
  font-weight: 800;
}

.match-center-lineup-lane__players {
  display: grid;
  grid-template-columns: repeat(var(--lineup-player-count, 1), minmax(0, 1fr));
  gap: 10px;
  align-items: start;
  min-width: 0;
}

.match-center-lineup-player {
  display: grid;
  justify-items: center;
  gap: 2px;
  padding: 4px 2px;
  text-align: center;
  min-height: 58px;
  min-width: 0;
  width: 100%;
  align-content: start;
}

.match-center-lineup-player__chip {
  min-height: 24px;
  min-width: 24px;
  padding: 0 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(255,255,255,0.92);
  border: 1px solid rgba(15, 23, 42, 0.08);
  font-size: 10px;
  font-weight: 900;
  color: #16a34a;
}

html[data-theme="dark"] .match-center-lineup-player__chip,
body[data-theme="dark"] .match-center-lineup-player__chip {
  background: rgba(8, 15, 30, 0.86);
  border-color: rgba(255,255,255,0.08);
  color: #86efac;
}

.match-center-lineup-player__name {
  font-size: 11px;
  line-height: 1.1;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #f8fafc;
  text-shadow: 0 1px 2px rgba(0,0,0,0.28);
  max-width: 100%;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
  word-break: break-word;
  text-wrap: balance;
}

.match-center-lineup-player__role {
  font-size: 9px;
  color: rgba(255,255,255,0.74);
  line-height: 1.1;
  max-width: 100%;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  word-break: break-word;
}

.match-center-lineup-bench {
  margin-top: 12px;
  display: grid;
  gap: 8px;
}

.match-center-lineup-bench__label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 800;
  color: var(--muted);
}

.match-center-lineup-bench__list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.match-center-lineup-bench__item {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255,255,255,0.7);
  font-size: 12px;
  font-weight: 700;
}

html[data-theme="dark"] .match-center-lineup-bench__item,
body[data-theme="dark"] .match-center-lineup-bench__item {
  border-color: rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.05);
}

.match-center-team-mini {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.match-center-team-mini--right {
  justify-content: flex-end;
}

.match-center-team-mini__media {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,0.14);
  flex: 0 0 auto;
}

.match-center-team-mini__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.match-center-team-mini__label {
  min-width: 0;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.match-center-empty {
  min-height: 120px;
  display: grid;
  place-items: center;
  text-align: center;
  gap: 8px;
  padding: 16px;
  border: 1px dashed var(--border);
  border-radius: 14px;
  background: rgba(255,255,255,0.32);
}

html[data-theme="dark"] .match-center-empty,
body[data-theme="dark"] .match-center-empty {
  background: rgba(255,255,255,0.02);
}

.match-center-empty__title {
  font-weight: 800;
  letter-spacing: -0.02em;
}

.match-center-empty__copy {
  color: var(--muted);
  max-width: 34ch;
}

.match-center-stats__table {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.match-center-stats__row {
  display: grid;
  grid-template-columns: 58px 1fr 58px;
  gap: 10px;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}

.match-center-stats__row:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.match-center-stats__label {
  text-align: center;
  color: var(--muted);
}

.match-center-stats__value {
  font-weight: 800;
}

.match-center-stats__value--right {
  text-align: right;
}

.match-center-predictions__hero {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.match-center-predictions__card {
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 16px;
  padding: 14px;
  background: linear-gradient(180deg, rgba(255,255,255,0.98), rgba(248,250,252,0.92));
}

html[data-theme="dark"] .match-center-predictions__card,
body[data-theme="dark"] .match-center-predictions__card {
  border-color: rgba(255,255,255,0.08);
  background: linear-gradient(180deg, rgba(255,255,255,0.05), rgba(255,255,255,0.03));
}

.match-center-predictions__card--mine {
  background:
    radial-gradient(circle at top left, rgba(18, 135, 49, 0.14), transparent 36%),
    linear-gradient(180deg, rgba(255,255,255,0.98), rgba(246,250,247,0.92));
}

.match-center-predictions__card--community {
  background:
    radial-gradient(circle at top left, rgba(37, 99, 235, 0.12), transparent 36%),
    linear-gradient(180deg, rgba(255,255,255,0.98), rgba(246,249,255,0.92));
}

html[data-theme="dark"] .match-center-predictions__card--mine,
body[data-theme="dark"] .match-center-predictions__card--mine {
  background:
    radial-gradient(circle at top left, rgba(18, 135, 49, 0.18), transparent 36%),
    linear-gradient(180deg, rgba(15, 30, 20, 0.55), rgba(10, 18, 14, 0.42));
}

html[data-theme="dark"] .match-center-predictions__card--community,
body[data-theme="dark"] .match-center-predictions__card--community {
  background:
    radial-gradient(circle at top left, rgba(37, 99, 235, 0.18), transparent 36%),
    linear-gradient(180deg, rgba(12, 20, 42, 0.55), rgba(10, 16, 32, 0.42));
}

.match-center-predictions__eyebrow {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted);
}

.match-center-predictions__score {
  margin-top: 10px;
  font-size: 34px;
  line-height: 1;
  font-weight: 900;
  letter-spacing: -0.05em;
}

.match-center-predictions__score span {
  opacity: 0.6;
}

.match-center-predictions__headline {
  margin-top: 10px;
  font-size: 26px;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.match-center-predictions__caption {
  margin-top: 10px;
  color: var(--muted);
}

.match-center-predictions__trends {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.match-center-predictions__trend {
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 14px;
  padding: 12px;
  background: rgba(255,255,255,0.58);
}

html[data-theme="dark"] .match-center-predictions__trend,
body[data-theme="dark"] .match-center-predictions__trend {
  border-color: rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.03);
}

.match-center-predictions__trend-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.match-center-predictions__bar {
  height: 10px;
  border-radius: 999px;
  background: rgba(18, 135, 49, 0.12);
  overflow: hidden;
}

.match-center-predictions__bar i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #128731, #23b35a);
}

.match-center-predictions__bar--draw {
  background: rgba(245, 158, 11, 0.14);
}

.match-center-predictions__bar--draw i {
  background: linear-gradient(90deg, #d97706, #f59e0b);
}

.match-center-predictions__bar--away {
  background: rgba(37, 99, 235, 0.14);
}

.match-center-predictions__bar--away i {
  background: linear-gradient(90deg, #2563eb, #60a5fa);
}

.match-center-predictions__top {
  margin-top: 14px;
}

.match-center-predictions__scoreline {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}

.match-center-predictions__scoreline-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.match-center-predictions__rank {
  width: 24px;
  height: 24px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(37, 99, 235, 0.12);
  color: #2563eb;
  font-size: 12px;
  font-weight: 800;
}

.match-center-predictions__scoreline:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

/* Responsive spacing */
@media (max-width: 520px) {
  .main {
    padding: 16px 12px 56px;
  }
  .card,
  .match {
    padding: 14px;
    border-radius: 18px;
  }
}

/* =========================================
   Responsive UX (Phone / Tablet / iPad)
   ========================================= */
@media (max-width: 1024px) {
  /* Evita zoom global al enfocar campos en iOS/Safari:
     controles con 16px o más en tablet/móvil */
  input,
  select,
  textarea,
  button {
    font-size: 16px;
  }

  .center {
    align-items: flex-start;
    padding: 12px;
  }

  .auth-card,
  .card,
  .match {
    width: 100%;
    max-width: 100%;
  }

  .tabs {
    gap: 8px;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding-bottom: 2px;
  }

  .tabs::-webkit-scrollbar {
    display: none;
  }

  .tab {
    flex: 0 0 auto;
    min-width: 132px;
    white-space: nowrap;
  }

  .row.space-between {
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 10px;
  }

  #viewLeaderboard .row.space-between .row {
    width: 100%;
    flex-wrap: wrap;
    gap: 8px;
  }

  .pill {
    min-height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  #viewMatches .match-top {
    flex-wrap: wrap;
  }

  #viewMatches .badge {
    align-self: flex-start;
  }
}

@media (max-width: 768px) {
  .player-page .main {
    max-width: 100%;
    padding: 12px 10px calc(var(--bn-h) + env(safe-area-inset-bottom) + 12px);
  }

  .player-page .view {
    width: 100%;
  }

  .player-page .card,
  .player-page .match {
    border-radius: 16px;
    padding: 13px;
  }

  .player-page .list {
    gap: 10px;
  }

  .pred-row {
    gap: 8px;
  }

  .teams-grid {
    gap: 8px;
  }

  .pred-row input {
    min-height: 44px;
    font-size: 18px;
    font-weight: 800;
  }

  .lb-list {
    gap: 8px;
  }

  .lb-item {
    padding: 10px;
  }

  .bottom-nav {
    gap: 4px;
    padding-left: 6px;
    padding-right: 6px;
  }

  .bottom-nav .bn-item {
    border-radius: 12px;
    padding: 8px 4px;
    gap: 5px;
  }

  .bottom-nav .bn-txt {
    font-size: 10px;
    letter-spacing: 0.15px;
  }

  #viewMatches .match {
    padding: 18px 16px;
    border-radius: 24px;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow: hidden;
  }

  #viewMatches .match-top {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    gap: 10px;
  }

  #viewMatches .teams-grid {
    grid-template-columns: minmax(0, 1fr) 34px minmax(0, 1fr);
    gap: 12px;
    margin-top: 18px;
  }

  #viewMatches .teams-vs {
    justify-self: center;
    align-self: center;
  }

  #viewMatches .pred-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    gap: 10px;
    align-items: center;
    width: 100%;
    max-width: none;
    margin-inline: auto;
    margin-top: 18px;
  }

  #viewMatches .pred-row input {
    min-width: 0;
    min-height: 70px;
    padding: 0;
    border-radius: 18px;
    font-size: 28px;
    background: rgba(255, 255, 255, 0.96);
    border-color: rgba(148, 163, 184, 0.22);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75);
  }

  #viewMatches .btnSubmit,
  #viewMatches .btnOpenMatchCenter {
    min-height: 52px;
    border-radius: 18px;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    white-space: normal;
    overflow-wrap: anywhere;
    line-height: 1.15;
  }

  #viewMatches .btnSubmit {
    margin-top: 16px;
    font-size: 18px;
    font-weight: 900;
  }

  #viewMatches .btnOpenMatchCenter {
    margin-top: 10px;
    font-size: 15px;
  }

  #viewMatches .team {
    gap: 10px;
  }

  #viewMatches .team-flag {
    width: 54px;
    height: 54px;
  }

  #viewMatches .team-name {
    font-size: 15px;
    letter-spacing: -0.02em;
  }

  #viewMatches .meta {
    font-size: 13px;
    line-height: 1.45;
    overflow-wrap: anywhere;
  }

  #viewMatches .countdown {
    display: inline-block;
    margin-top: 2px;
  }

  #viewMatches .match-footer {
    font-size: 12px;
    min-width: 0;
  }

  #viewMatches .kpi {
    gap: 6px;
  }

  #viewMatches .kpi .chip {
    max-width: 100%;
    white-space: normal;
  }

  #viewRules .integrated-card {
    padding: 18px;
  }

  #viewRules .row.space-between {
    flex-direction: column;
    align-items: stretch;
  }

  #viewRules .row.wrap {
    width: 100%;
    justify-content: stretch !important;
  }

  #viewRules .row.wrap .pill {
    width: 100%;
    justify-content: center;
  }

  #rulesMount .table-scroll {
    margin-inline: -2px;
    padding-bottom: 4px;
  }

  #rulesMount .table {
    min-width: 540px;
  }

  #rulesMount .rules-scoring-table {
    display: none;
  }

  #rulesMount .rules-scoring-mobile {
    display: grid;
  }

  #rulesMount .rules-examples-grid {
    grid-template-columns: 1fr;
  }

  #rulesMount .rules-accordion-trigger {
    min-height: 48px;
    padding-inline: 12px;
  }
}

@media (max-width: 480px) {
  .main {
    padding: 12px 10px 56px;
  }

  .login-logo-wrap {
    margin: 12px 0 10px;
  }

  .brand-logo-large {
    width: 118px;
    max-width: 48vw;
  }

  .header .header-inner {
    gap: 8px;
  }

  .header .brand-company {
    font-size: 17px;
  }

  .header .brand-meta {
    font-size: 11px;
  }

  #viewMatches .match,
  #viewRules .integrated-card {
    padding: 14px;
    border-radius: 18px;
  }

  #viewMatches,
  #viewMatches .list,
  #viewMatches .match-top,
  #viewMatches .match-head,
  #viewMatches .teams-grid,
  #viewMatches .team,
  #viewMatches .pred-row,
  #viewMatches .match-footer {
    min-width: 0;
    max-width: 100%;
  }

  #viewMatches .pred-row {
    grid-template-columns: minmax(0, 1fr) 18px minmax(0, 1fr);
    gap: 6px;
    max-width: none;
  }

  #viewMatches .pred-row .dash {
    text-align: center;
  }

  #viewMatches .teams-grid {
    grid-template-columns: minmax(0, 1fr) 26px minmax(0, 1fr);
    gap: 6px;
  }

  #viewMatches .teams-vs {
    font-size: 11px;
  }

  #viewMatches .team-flag {
    width: 48px;
    height: 48px;
  }

  #viewMatches .team-name {
    font-size: 14px;
    line-height: 1.1;
    overflow-wrap: anywhere;
    word-break: break-word;
  }

  #viewMatches .badge {
    font-size: 11px;
    padding: 5px 9px;
  }

  #viewMatches .meta,
  #viewMatches .match-footer {
    font-size: 12px;
  }

  #viewMatches .btnSubmit,
  #viewMatches .btnOpenMatchCenter {
    font-size: 15px;
    padding-inline: 12px;
  }

  #viewMatches .pred-row input {
    min-height: 64px;
    font-size: 24px;
  }

  #viewMatches .btnSubmit {
    min-height: 50px;
  }

  #viewMatches .match-top {
    grid-template-columns: minmax(0, 1fr);
  }

  #viewMatches .badge {
    justify-self: start;
  }

  #rulesMount .table {
    min-width: 520px;
  }

  #rulesMount .table th,
  #rulesMount .table td {
    padding: 8px 6px;
    font-size: 12px;
    line-height: 1.35;
  }

  #rulesMount .rules-accordion-item {
    padding: 10px !important;
  }

  #rulesMount .rules-bullets {
    padding-left: 16px !important;
    gap: 6px !important;
  }

  #rulesMount .rules-example-card__head {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ================================
   LOGO LOGIN / REGISTER (UNIFICADO)
   ================================ */

/* Tokens (una sola vez) */
:root {
  --brand-logo-h: 140px; /* altura estable */
  --brand-logo-maxw: 520px; /* ancho máximo */
}

/* Contenedor */
/* Logo grande (login y matches) */
.login-logo-wrap {
  display: flex;
  justify-content: center;
  margin: 18px 0 12px;
}

.brand-logo-large {
  width: 140px;
  max-width: 42vw;
  height: auto;
  opacity: 0.95;
}

/* ✅ Regla única del logo */
.login-logo-wrap img {
  height: var(--brand-logo-h);
  width: auto;
  max-width: min(var(--brand-logo-maxw), 92vw);
  object-fit: contain;
  display: block;
}

/* Mobile */
@media (max-width: 520px) {
  :root {
    --brand-logo-h: 120px;
  }
  .login-logo-wrap {
    padding: 16px 0 8px;
  }
}

/* -----------------------------
   TRANSICION DEL HEADER
   ----------------------------- */
/* Intro hero con video */
.intro-hero {
  position: relative;
  min-height: 100svh;
  width: 100%;
  display: grid;
  place-items: center;
  padding: clamp(14px, 2.6vh, 28px) clamp(10px, 1.8vw, 18px);
  overflow: clip;
  isolation: isolate;
  background: #0b1018;
}

.intro-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(1100px 700px at 12% 14%, rgba(71, 85, 105, 0.34), transparent 58%),
    radial-gradient(900px 620px at 86% 14%, rgba(30, 41, 59, 0.48), transparent 62%),
    linear-gradient(160deg, #0f172a 0%, #0b1018 40%, #090d14 100%);
}

.intro-noise {
  position: absolute;
  inset: 0;
  opacity: 0.18;
  pointer-events: none;
  background-image: radial-gradient(rgba(255, 255, 255, 0.08) 1px, transparent 1px);
  background-size: 4px 4px;
  mix-blend-mode: soft-light;
}

.intro-content {
  position: relative;
  z-index: 2;
  width: min(1040px, 100%);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: clamp(10px, 1.9vh, 18px);
  height: calc(100svh - 2 * clamp(14px, 2.6vh, 28px));
  padding: clamp(86px, 14vh, 132px) 0 clamp(10px, 2vh, 20px);
}

.intro-logo-wrap {
  position: absolute;
  left: 50%;
  top: clamp(4px, 1.4vh, 18px);
  transform: translateX(-50%);
  width: clamp(190px, 24vw, 330px);
  height: clamp(64px, 12vh, 132px);
  max-width: min(84vw, 420px);
  margin: 0;
  display: grid;
  place-items: center;
  pointer-events: none;
  flex: 0 0 auto;
}

.intro-logo {
  position: relative;
  z-index: 3;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  object-fit: contain;
  object-position: center;
  opacity: 0.98;
  filter: drop-shadow(0 10px 24px rgba(0, 0, 0, 0.52));
}

.intro-logo-bursts {
  position: absolute;
  z-index: 2;
  inset: -28% -26%;
  pointer-events: none;
}

.intro-logo-spark {
  position: absolute;
  width: 4px;
  height: 4px;
  border-radius: 999px;
  background: rgba(248, 250, 252, 0.98);
  box-shadow:
    0 0 12px rgba(248, 250, 252, 0.9),
    0 0 24px rgba(56, 189, 248, 0.7);
}

.intro-logo-flash {
  position: absolute;
  inset: 44% auto auto 50%;
  width: 14px;
  height: 14px;
  border-radius: 999px;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(248, 250, 252, 0.95), rgba(248, 250, 252, 0));
  box-shadow:
    0 0 22px rgba(248, 250, 252, 0.88),
    0 0 42px rgba(251, 191, 36, 0.55);
  pointer-events: none;
}

.intro-media {
  position: relative;
  width: min(var(--intro-media-max-width), 94vw, calc((100svh - 300px) * (16 / 9)));
  aspect-ratio: 16 / 9;
  max-height: min(54svh, var(--intro-media-max-height));
  margin: 0 auto;
  border-radius: 26px;
  overflow: visible;
  background: transparent;
  flex: 0 1 auto;
}

.intro-media-frame {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.28);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.05),
    0 30px 86px rgba(2, 6, 23, 0.52);
  background: #111827;
}

.intro-video {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: var(--intro-video-object-position);
  transform: scale(1.02);
  transform-origin: center;
  filter: saturate(0.84) brightness(0.74) contrast(1.06);
  backface-visibility: hidden;
  -webkit-transform: translateZ(0) scale(1.02);
  will-change: transform;
}

.intro-media-shade {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background:
    radial-gradient(600px 240px at 50% 102%, rgba(15, 23, 42, 0.75), transparent 62%),
    linear-gradient(180deg, rgba(2, 6, 23, 0.1) 0%, rgba(2, 6, 23, 0.56) 82%);
}

.intro-neon {
  position: absolute;
  border-radius: 999px;
  pointer-events: none;
  filter: blur(28px);
  opacity: 0.65;
  mix-blend-mode: screen;
}

.intro-neon-a {
  width: 42%;
  height: 26%;
  left: -8%;
  top: -4%;
  background: radial-gradient(circle at 50% 50%, rgba(56, 189, 248, 0.85), rgba(56, 189, 248, 0));
}

.intro-neon-b {
  width: 46%;
  height: 28%;
  right: -10%;
  bottom: -8%;
  background: radial-gradient(circle at 50% 50%, rgba(20, 184, 166, 0.78), rgba(20, 184, 166, 0));
}

.intro-stars,
.intro-bursts {
  position: absolute;
  inset: -8%;
  pointer-events: none;
  z-index: 0;
}

.intro-star {
  position: absolute;
  width: 2px;
  height: 2px;
  border-radius: 50%;
  background: rgba(226, 232, 240, 0.95);
  box-shadow: 0 0 10px rgba(148, 163, 184, 0.7);
}

.intro-burst {
  position: absolute;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: rgba(125, 211, 252, 0.95);
  box-shadow:
    0 0 12px rgba(56, 189, 248, 0.9),
    0 0 32px rgba(45, 212, 191, 0.68);
}

.intro-audio-controls {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 4;
  display: flex;
  align-items: center;
  gap: 8px;
}

.intro-replay,
.intro-sound {
  position: static;
  border: 1px solid rgba(148, 163, 184, 0.45);
  background: linear-gradient(
    130deg,
    rgba(15, 23, 42, 0.44),
    rgba(15, 23, 42, 0.2)
  );
  color: rgba(226, 232, 240, 0.96);
  border-radius: 999px;
  padding: 7px 13px;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: lowercase;
  cursor: pointer;
  backdrop-filter: blur(8px);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.03) inset,
    0 10px 20px rgba(2, 6, 23, 0.3);
  transition:
    transform 0.24s ease,
    box-shadow 0.24s ease,
    border-color 0.24s ease;
}

.intro-replay {
  min-width: 78px;
  opacity: 0.92;
}

.intro-sound.is-on {
  background: linear-gradient(
    130deg,
    rgba(13, 148, 136, 0.45),
    rgba(20, 184, 166, 0.22)
  );
  border-color: rgba(45, 212, 191, 0.62);
}

.intro-replay:hover,
.intro-sound:hover {
  transform: translateY(-1px);
  border-color: rgba(125, 211, 252, 0.85);
  box-shadow:
    0 0 24px rgba(56, 189, 248, 0.48),
    0 12px 24px rgba(2, 6, 23, 0.36);
}

.intro-title {
  margin: 2px 0 0;
  font-size: clamp(30px, 4.2vw, 52px);
  line-height: 1.06;
  font-weight: 900;
  letter-spacing: -0.03em;
  color: rgba(248, 250, 252, 0.98);
}

.intro-text {
  margin: 0;
  max-width: min(760px, 90vw);
  color: rgba(203, 213, 225, 0.88);
  font-size: clamp(15px, 2.2vw, 18px);
  line-height: 1.38;
}

.intro-line {
  width: min(340px, 70vw);
  height: 20px;
}

.intro-line path {
  fill: none;
  stroke: rgba(148, 163, 184, 0.72);
  stroke-width: 2;
  stroke-linecap: round;
}

.intro-start {
  position: relative;
  left: auto;
  bottom: auto;
  transform: none;
  z-index: 3;
  width: auto;
  min-width: min(170px, 72vw);
  min-height: 42px;
  padding: 9px 22px;
  border: 1px solid rgba(226, 232, 240, 0.32);
  border-radius: 999px;
  background: linear-gradient(
    120deg,
    rgba(255, 255, 255, 0.12),
    rgba(148, 163, 184, 0.08),
    rgba(255, 255, 255, 0.12)
  );
  color: #f8fafc;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  backdrop-filter: blur(12px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    0 12px 26px rgba(2, 6, 23, 0.44);
  margin-top: 2px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  transition:
    transform 0.26s ease,
    box-shadow 0.26s ease,
    border-color 0.26s ease,
    filter 0.26s ease;
}

@media (max-width: 1200px) {
  :root {
    --intro-media-max-width: 760px;
    --intro-media-max-height: 460px;
    --intro-video-object-position: 50% 46%;
  }

  .intro-content {
    height: calc(100svh - 2 * clamp(12px, 2.2vh, 24px));
    padding-top: clamp(78px, 13vh, 118px);
    padding-bottom: clamp(10px, 1.8vh, 18px);
  }

  .intro-media {
    width: min(92vw, var(--intro-media-max-width), calc((100svh - 288px) * (16 / 9)));
    max-height: min(50svh, var(--intro-media-max-height));
  }

  .intro-logo-wrap {
    width: clamp(176px, 30vw, 290px);
    height: clamp(60px, 11vh, 114px);
  }
  .stats-summary-grid,
  .stats-compare-toolbar,
  .stats-toolbar,
  .stats-panels-grid,
  .stats-team-card__grid,
  .stats-breakdown,
  .stats-compare-grid,
  .world-hero,
  .module-guide__grid {
    grid-template-columns: 1fr;
  }
  .stats-chart,
  .stats-team-snapshot,
  .stats-table {
    min-height: 280px;
  }
  .world-status-badges {
    justify-content: flex-start;
  }

  .world-hero {
    padding: 22px 20px;
    border-radius: 28px;
  }

  .world-hero__title {
    max-width: 12ch;
  }

  .world-status-badges .chip {
    min-width: min(220px, 100%);
  }

  #worldUpcomingList,
  #worldRecentList {
    grid-auto-columns: minmax(220px, 78vw);
  }
  .match-center-timeline {
    grid-auto-columns: minmax(240px, 82vw);
  }
  .module-guide__head {
    flex-direction: column;
  }
  .match-center-lineup-card__head {
    flex-direction: column;
    align-items: flex-start;
  }
  .match-center-lineup-pitch {
    gap: 10px;
    padding: 15px 10px 18px;
    border-radius: 16px;
    min-height: 420px;
  }
  .match-center-lineup-pitch__half {
    left: 8%;
    right: 8%;
  }
  .match-center-lineup-pitch__circle {
    width: 44px;
    height: 44px;
    top: calc(50% - 22px);
    left: calc(50% - 22px);
  }
  .match-center-lineup-lane {
    gap: 6px;
  }
  .match-center-lineup-lane__label {
    font-size: 10px;
  }
  .match-center-lineup-lane__players {
    gap: 8px 6px;
  }
  .match-center-lineup-player {
    min-height: 52px;
    padding: 3px 1px;
  }
  .match-center-lineup-player__chip {
    min-width: 22px;
    min-height: 22px;
    padding: 0 5px;
    font-size: 9px;
  }
  .match-center-lineup-player__name {
    font-size: 10px;
    line-height: 1.02;
    -webkit-line-clamp: 2;
  }
  .match-center-lineup-player__role {
    font-size: 8px;
    line-height: 1.02;
    -webkit-line-clamp: 1;
  }
  .match-center-lineup-bench__item {
    font-size: 11px;
    padding: 6px 8px;
  }
}

@media (max-width: 420px) {
  .match-center-lineup-card {
    padding: 10px;
  }
  .match-center-lineup-card__title {
    font-size: 13px;
    margin-bottom: 6px;
  }
  .match-center-lineup-card__formation {
    font-size: 10px;
    padding: 5px 9px;
  }
  .match-center-lineup-pitch {
    padding: 12px 8px 14px;
    gap: 7px;
    min-height: 388px;
  }
  .match-center-lineup-pitch__half {
    left: 6%;
    right: 6%;
  }
  .match-center-lineup-pitch__circle {
    width: 36px;
    height: 36px;
    top: calc(50% - 18px);
    left: calc(50% - 18px);
  }
  .match-center-lineup-lane__players {
    gap: 7px 4px;
  }
  .match-center-lineup-player {
    min-height: 48px;
  }
  .match-center-lineup-player__chip {
    min-width: 20px;
    min-height: 20px;
    padding: 0 4px;
    font-size: 8px;
  }
  .match-center-lineup-player__name {
    font-size: 9px;
    line-height: 1;
  }
  .match-center-lineup-player__role {
    font-size: 7px;
    line-height: 1;
  }
}

@media (max-width: 560px) {
  .match-center-lineup-card__head {
    gap: 8px;
    align-items: flex-start;
  }

  .match-center-lineup-card__title {
    min-width: 0;
    width: 100%;
  }

  .match-center-lineup-card__formation {
    width: 100%;
    justify-content: center;
  }

  .match-center-lineup-lane__players {
    gap: 8px 6px;
  }

  .match-center-lineup-player__name,
  .match-center-lineup-player__role {
    width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
  }
}

.intro-start::before {
  content: "";
  position: absolute;
  inset: -70% -20%;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.4) 50%,
    rgba(255, 255, 255, 0) 100%
  );
  transform: translateX(-120%) rotate(8deg);
  pointer-events: none;
  animation: introLiquidSweep 2.8s ease-in-out infinite;
}

@keyframes introLiquidSweep {
  0%,
  18% {
    transform: translateX(-120%) rotate(8deg);
  }
  56%,
  100% {
    transform: translateX(120%) rotate(8deg);
  }
}

.intro-start:hover {
  transform: translateY(-1px);
  filter: brightness(1.04);
  border-color: rgba(248, 250, 252, 0.56);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.28),
    0 16px 30px rgba(2, 6, 23, 0.52);
}

.intro-start:active {
  transform: translateY(0);
}

.intro-skip {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 4;
  border: 1px solid rgba(148, 163, 184, 0.45);
  background: linear-gradient(
    130deg,
    rgba(15, 23, 42, 0.44),
    rgba(15, 23, 42, 0.2)
  );
  color: rgba(226, 232, 240, 0.96);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: lowercase;
  border-radius: 999px;
  padding: 7px 13px;
  backdrop-filter: blur(8px);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.03) inset,
    0 10px 20px rgba(2, 6, 23, 0.3);
  cursor: pointer;
  transition:
    transform 0.24s ease,
    box-shadow 0.24s ease,
    border-color 0.24s ease;
}

.intro-skip:hover {
  transform: translateY(-1px);
  border-color: rgba(125, 211, 252, 0.85);
  box-shadow:
    0 0 24px rgba(56, 189, 248, 0.48),
    0 12px 24px rgba(2, 6, 23, 0.36);
}

.is-hidden {
  display: none !important;
}

.intro-exit {
  pointer-events: none;
}

@media (max-width: 900px) {
  :root {
    --intro-media-max-width: 560px;
    --intro-media-max-height: 390px;
    --intro-video-object-position: 50% 42%;
  }

  .intro-hero {
    padding: 14px 10px 18px;
  }

  .intro-content {
    gap: clamp(8px, 1.6vh, 12px);
    height: calc(100svh - 2 * 14px);
    padding-top: clamp(70px, 12.4vh, 102px);
    padding-bottom: clamp(8px, 1.6vh, 14px);
  }

  .intro-logo-wrap {
    top: clamp(2px, 1vh, 10px);
    width: clamp(160px, 52vw, 250px);
    height: clamp(56px, 11.5vh, 98px);
    max-width: 86vw;
  }

  .intro-logo {
    width: 100%;
    height: 100%;
  }

  .intro-media {
    width: min(96vw, var(--intro-media-max-width), calc((100svh - 260px) * (16 / 10)));
    aspect-ratio: 16 / 10;
    max-height: min(44svh, var(--intro-media-max-height));
    border-radius: 20px;
  }

  .intro-title {
    letter-spacing: -0.02em;
  }

  .intro-replay,
  .intro-sound {
    padding: 6px 10px;
    font-size: 12px;
  }

  .intro-audio-controls {
    top: 10px;
    right: 10px;
    gap: 6px;
  }

  .intro-skip {
    top: 10px;
    left: 10px;
    padding: 6px 10px;
    font-size: 12px;
  }

  .intro-start {
    min-width: min(154px, 74vw);
    min-height: 40px;
    padding: 8px 18px;
    font-size: 12px;
    letter-spacing: 0.04em;
  }
}

@media (max-height: 760px) {
  .intro-hero {
    padding-top: 10px;
    padding-bottom: 12px;
  }

  .intro-content {
    gap: 8px;
    padding-top: 66px;
    padding-bottom: 8px;
  }

  .intro-logo-wrap {
    top: 0;
    height: clamp(52px, 10vh, 82px);
  }

  .intro-media {
    max-height: min(38svh, 300px);
  }

  .intro-line {
    height: 10px;
  }

  .intro-text {
    font-size: 13px;
    line-height: 1.28;
  }
}

@media (max-width: 640px) {
  :root {
    --intro-media-max-width: 520px;
    --intro-media-max-height: 340px;
    --intro-video-object-position: 50% 40%;
  }

  .intro-content {
    padding-top: clamp(66px, 11vh, 92px);
  }

  .intro-media {
    width: min(100%, 96vw);
    aspect-ratio: 4 / 5;
    max-height: min(46svh, var(--intro-media-max-height));
    border-radius: 18px;
  }

  .intro-media-frame {
    border-radius: inherit;
  }

  .intro-text {
    max-width: min(92vw, 520px);
    font-size: 14px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .intro-bg,
  .intro-video,
  .intro-start,
  .intro-sound {
    animation: none !important;
    transition: none !important;
  }
}



/*____________________________________*/

/*____________Contenedor tipo banner_______________________*/
.banner-stadium {
  --banner-bg: rgba(10, 14, 20, 0.82);
  --banner-border: rgba(255, 255, 255, 0.22);
  --banner-text: rgba(255, 255, 255, 0.98);
  --banner-speed: 20s;
  position: relative;
  overflow: hidden;
  white-space: nowrap;
  border: 1px solid var(--banner-border);
  border-radius: 14px;
  background: var(--banner-bg);
  backdrop-filter: blur(12px) saturate(140%);
  margin: 8px 0 12px;
}

body[data-theme="light"] .banner-stadium,
html[data-theme="light"] .banner-stadium {
  --banner-bg: rgba(248, 250, 252, 0.82);
  --banner-border: rgba(15, 23, 42, 0.22);
  --banner-text: rgba(15, 23, 42, 0.96);
}

.banner-track {
  display: flex;
  align-items: center;
  width: max-content;
  padding: 8px 0;
  will-change: transform;
  transform: translate3d(0, 0, 0);
  backface-visibility: hidden;
  animation: stadiumSlide var(--banner-speed) linear infinite;
}

.tenant-banner-text {
  display: inline-block;
  color: var(--banner-text);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding-inline-end: 2.2rem;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}

@keyframes stadiumSlide {
  from {
    transform: translate3d(0, 0, 0);
  }
  to {
    transform: translate3d(-50%, 0, 0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .banner-track {
    animation: none !important;
  }
}

/*____________________________________*/

/* =============================
   Bottom Nav (iOS / SF-style)
   ============================= */
:root {
  --bn-h: 74px; /* alto del bottom nav */
}

/* evita que el nav tape contenido (ya lo tienes, lo dejamos) */
.player-page .main {
  padding-bottom: calc(var(--bn-h) + env(safe-area-inset-bottom));
}

/* contenedor fijo */
.bottom-nav {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: 0;
  width: min(calc(100% - 24px), 1280px);
  height: calc(var(--bn-h) + env(safe-area-inset-bottom));
  padding: 8px 8px calc(8px + env(safe-area-inset-bottom));
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  gap: 0;
  z-index: 50;

  background: rgba(88, 91, 102, 0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-bottom: 0;
  border-radius: 18px 18px 0 0;
  box-shadow: 0 -10px 30px rgba(2, 6, 23, 0.16);
}

.bottom-nav::before {
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: inherit;
  pointer-events: none;
  opacity: 0;
  background: linear-gradient(90deg, rgba(34, 211, 238, 0.24), rgba(59, 130, 246, 0.34), rgba(16, 185, 129, 0.24));
  filter: blur(12px);
}

.bottom-nav--session-glow::before {
  animation: bottomNavSessionGlow 2.2s ease-out;
}

@keyframes bottomNavSessionGlow {
  0% {
    opacity: 0;
    transform: scaleX(0.96);
  }
  18% {
    opacity: 0.95;
    transform: scaleX(1);
  }
  55% {
    opacity: 0.72;
  }
  100% {
    opacity: 0;
    transform: scaleX(1.02);
  }
}

/* 🔑 IMPORTANTÍSIMO: pisar el estilo global de button (gradiente/sombra) */
.bottom-nav .bn-item {
  appearance: none;
  -webkit-appearance: none;

  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  filter: none !important;

  color: rgba(255, 255, 255, 0.74);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 7px;

  padding: 10px 6px;
  border-radius: 0;
  cursor: pointer;
  user-select: none;
  -webkit-tap-highlight-color: transparent;

  transition:
    transform 0.18s ease,
    color 0.18s ease,
    background 0.18s ease;
}

.bottom-nav .bn-item.hidden,
.bottom-nav .bn-item[hidden] {
  display: none !important;
}

/* wrapper tipo “pill” detrás del icono */
.bottom-nav.ios .bn-icoWrap {
  position: relative;
  width: 42px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 999px;
}

/* Iconos SVG (estilo SF) */
.bottom-nav.ios .bn-ico {
  width: 24px;
  height: 24px;
  display: block;
  color: currentColor;
}

/* Outline vs Filled (si estás usando 2 SVG por item) */
.bottom-nav.ios .bn-ico-filled {
  opacity: 0;
  transform: scale(0.98);
  position: absolute;
  inset: 0;
  margin: auto;
}
.bottom-nav.ios .bn-ico-outline {
  opacity: 1;
}

/* texto */
.bottom-nav .bn-txt {
  font-size: 12px;
  line-height: 1;
  letter-spacing: 0.2px;
  opacity: 0.95;
  white-space: nowrap;
  font-weight: 700;
}

/* hover/tap */
.bottom-nav .bn-item:hover {
  background: rgba(255, 255, 255, 0.04);
  color: rgba(255, 255, 255, 0.94);
}
.bottom-nav .bn-item:active {
  transform: scale(0.98);
}

/* active: iOS highlight sutil (pill + filled) */
.bottom-nav .bn-item.active {
  color: rgba(255, 255, 255, 0.98);
}
.bottom-nav.ios .bn-item.active .bn-icoWrap {
  background: rgba(255, 255, 255, 0.16);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.18),
    0 8px 18px rgba(0, 0, 0, 0.16);
}
.bottom-nav.ios .bn-item.active .bn-ico-filled {
  opacity: 1;
  transform: scale(1);
}
.bottom-nav.ios .bn-item.active .bn-ico-outline {
  opacity: 0;
}

/* compact */
@media (max-width: 360px) {
  :root {
    --bn-h: 68px;
  }
  .bottom-nav.ios .bn-txt {
    font-size: 10px;
  }
}

/* =========================================
   Premium Responsive Header (Dark + Light)
   ========================================= */

/* Tokens del header por defecto (DARK) */
body {
  --header-bg: rgba(10, 14, 20, 0.72);
  --header-border: rgba(255, 255, 255, 0.08);
  --header-shadow: 0 18px 40px rgba(0, 0, 0, 0.4);
  --header-glow: rgba(59, 130, 246, 0.18);

  --header-title: rgba(233, 238, 247, 0.95);
  --header-subtitle: rgba(233, 238, 247, 0.65);

  --header-control-bg: rgba(255, 255, 255, 0.06);
  --header-control-border: rgba(255, 255, 255, 0.1);
  --header-control-hover: rgba(255, 255, 255, 0.1);
  --header-focus: rgba(59, 130, 246, 0.45);
}

/* Tokens del header para LIGHT */
body[data-theme="light"] {
  --header-bg: rgba(255, 255, 255, 0.76);
  --header-border: rgba(16, 24, 40, 0.1);
  --header-shadow: 0 18px 40px rgba(16, 24, 40, 0.1);
  --header-glow: rgba(245, 158, 11, 0.18);

  --header-title: rgba(17, 24, 39, 0.92);
  --header-subtitle: rgba(17, 24, 39, 0.6);

  --header-control-bg: rgba(17, 24, 39, 0.05);
  --header-control-border: rgba(17, 24, 39, 0.1);
  --header-control-hover: rgba(17, 24, 39, 0.08);
  --header-focus: rgba(245, 158, 11, 0.35);
}

/* Header base */
.header {
  position: sticky;
  top: 0;
  z-index: 55;
  padding: 14px 14px 12px;
  background: var(--header-bg);
  border-bottom: 1px solid var(--header-border);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: var(--header-shadow);
  transition:
    background 0.25s ease,
    box-shadow 0.25s ease,
    border-color 0.25s ease;
}

/* Glow suave superior */
.header::before {
  content: "";
  position: absolute;
  left: 10px;
  right: 10px;
  top: -18px;
  height: 42px;
  background: radial-gradient(
    closest-side,
    var(--header-glow),
    transparent 70%
  );
  filter: blur(10px);
  opacity: 0.9;
  pointer-events: none;
}

/* Línea brillante sutil */
.header::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.18),
    transparent
  );
  opacity: 0.35;
  pointer-events: none;
}

/* Paneles con color por tenant (no dependen del tema) */
body.tenant-panel-theme-enabled .header,
body.tenant-panel-theme-enabled .topbar,
body.tenant-panel-theme-enabled .unified-header {
  background: var(--tenant-header-panel-bg) !important;
}
body.tenant-panel-theme-enabled .header::before,
body.tenant-panel-theme-enabled .header::after {
  opacity: 0 !important;
}
body.tenant-panel-theme-enabled .bottom-nav {
  background: var(--tenant-bottom-panel-bg) !important;
}
body.tenant-panel-theme-enabled .bottom-nav::before {
  opacity: 0 !important;
}

/* Brand */
.header .brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0; /* permite truncar texto en móvil */
}

/* Logo premium */
.header .logo {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;

  background:
    radial-gradient(
      14px 14px at 30% 25%,
      rgba(255, 255, 255, 0.22),
      transparent 65%
    ),
    linear-gradient(135deg, rgba(59, 130, 246, 0.35), rgba(245, 158, 11, 0.18));
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.22);

  transform: translateZ(0);
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease;
}
.header.scrolled {
  backdrop-filter: blur(18px);
  background: rgba(10, 14, 20, 0.85);
}


body[data-theme="light"] .header .logo {
  border-color: rgba(17, 24, 39, 0.1);
  box-shadow: 0 14px 28px rgba(16, 24, 40, 0.1);
}

.header .brand:hover .logo {
  transform: translateY(-1px);
}

/* Texto */
.header .title {
  color: var(--header-title);
  font-weight: 800;
  letter-spacing: 0.2px;
  font-size: 16px;
  line-height: 1.1;
}

.header .subtitle {
  color: var(--header-subtitle);
  font-size: 12px;
  line-height: 1.2;
  margin-top: 3px;

  /* truncado elegante */
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  max-width: 52vw;
}

/* Controles derecha */
.header .row {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Botón tema + select estilo premium */
.header .btn.ghost,
.header select.select {
  background: var(--header-control-bg);
  border: 1px solid var(--header-control-border);
  border-radius: 14px;
  transition:
    background 0.18s ease,
    border-color 0.18s ease,
    transform 0.18s ease,
    box-shadow 0.18s ease;
}

.header .btn.ghost:hover,
.header select.select:hover {
  background: var(--header-control-hover);
  transform: translateY(-1px);
}

.header .btn.ghost:active,
.header select.select:active {
  transform: translateY(0px);
}

.header .btn.ghost:focus-visible,
.header select.select:focus-visible {
  outline: none;
  box-shadow: 0 0 0 4px var(--header-focus);
}

/* Badge (si aplica) */
.header .auth-badge {
  background: var(--header-control-bg);
  border: 1px solid var(--header-control-border);
  border-radius: 999px;
  padding: 6px 10px;
  color: var(--header-title);
}

.header .header-inner {
  width: min(1100px, 100%);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  position: relative; /* para ::before/::after si los usas */
}

@media (max-width: 560px) {
  .header {
    padding: 2px;
  }

  .header .header-inner {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  /* Empresa protagonista */
  :root {
    --brand-company-size: 18px;
  }

  .header .brand-company {
    font-weight: 900;
    letter-spacing: 0.1px;
  }

  .header .brand-meta {
    font-size: 11px;
    margin-top: 2px;
  }  


  .header .row {
    width: 100%;
    justify-content: space-between;
  }

  .header #tenantHeaderSelect {
    flex: 1;
    min-width: 0;
  }

  .header #btnThemeToggle {
    width: 40px;
    height: 38px;
  }
}



/* Respeta accesibilidad */
@media (prefers-reduced-motion: reduce) {
  .header,
  .header .logo,
  .header .btn.ghost,
  .header select.select {
    transition: none !important;
  }
}

/* =========================================
   Header Brand Hierarchy + Shimmer Company
   Empresa (protagonista) > Evento > App
   Compatible con dark/light (tokens actuales)
   ========================================= */

:root {
  --brand-company-size: 18px;
  --brand-meta-size: 12px;

  /* Shimmer */
  --shine-a: rgba(255, 255, 255, 0.08);
  --shine-b: rgba(255, 255, 255, 0.38);
  --shine-c: rgba(255, 255, 255, 0.1);

  /* En light un dorado sutil */
  --shine-b-light: rgba(245, 158, 11, 0.42);
}

html[data-theme="dark"] .header,
body[data-theme="dark"] .header {
  /* dark: shimmer más frío */
  --shine-a: rgba(255, 255, 255, 0.08);
  --shine-b: rgba(255, 255, 255, 0.4);
  --shine-c: rgba(255, 255, 255, 0.1);
}

html[data-theme="light"] .header,
body[data-theme="light"] .header {
  /* light: shimmer dorado premium */
  --shine-a: rgba(17, 24, 39, 0.06);
  --shine-b: var(--shine-b-light);
  --shine-c: rgba(17, 24, 39, 0.08);
}

/* Contenedor del texto del brand */
.header .brand-text {
  min-width: 0; /* permite ellipsis */
  display: flex;
  flex-direction: column;
}

/* EMPRESA protagonista */
.header .brand-company {
  font-weight: 900;
  letter-spacing: 0.2px;
  line-height: 1.05;
  font-size: var(--brand-company-size);
  color: var(--header-title);

  max-width: min(66vw, 640px);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;

  position: relative;
}

/* Meta: Evento • Liga */
.header .brand-meta {
  margin-top: 4px;
  display: flex;
  align-items: center;
  gap: 8px;

  font-size: var(--brand-meta-size);
  line-height: 1.2;
  color: var(--header-subtitle);

  max-width: min(74vw, 720px);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.header .brand-event {
  font-weight: 800;
  opacity: 0.95;
}

.header .brand-app {
  font-weight: 800;
  opacity: 0.82;
}

.header .brand-meta .dot {
  opacity: 0.55;
}

/* -------------------------
   Shimmer transversal (shine)
   ------------------------- */
.header .shimmer::after {
  content: "";
  position: absolute;
  top: -55%;
  left: -40%;
  width: 44%;
  height: 210%;
  pointer-events: none;

  background: linear-gradient(
    90deg,
    transparent,
    var(--shine-a),
    var(--shine-b),
    var(--shine-c),
    transparent
  );

  transform: rotate(18deg) translateX(-160%);
  filter: blur(1px);
  opacity: 0;
  animation: brandShine 4.2s ease-in-out infinite;
}

/* Hace el brillo “cruzar” */
@keyframes brandShine {
  0% {
    transform: rotate(18deg) translateX(-160%);
    opacity: 0;
  }
  10% {
    opacity: 0.95;
  }
  35% {
    transform: rotate(18deg) translateX(260%);
    opacity: 0.85;
  }
  55% {
    opacity: 0;
  }
  100% {
    transform: rotate(18deg) translateX(260%);
    opacity: 0;
  }
}

/* Mobile: aún más protagonista la empresa */
@media (max-width: 560px) {
  :root {
    --brand-company-size: 19px;
    --brand-meta-size: 12px;
  }
  .header .brand-company,
  .header .brand-meta {
    max-width: 100%;
  }
}

/* Accesibilidad */
@media (prefers-reduced-motion: reduce) {
  .header .shimmer::after {
    animation: none !important;
    opacity: 0 !important;
  }
}

/* Reserva espacio global para bottom-nav en la app */
.player-page #app {
  padding-bottom: calc(var(--bn-h) + env(safe-area-inset-bottom));
}

/* ================================
   Leaderboard – Top buttons
   ================================ */

.lb-top-actions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-top: 12px;
}

/* Botones con mismo alto */
.lb-top-actions .btn {
  width: 100%;
  height: 46px;
  font-weight: 600;
}

/* Mobile: se apilan */
@media (max-width: 640px) {
  .lb-top-actions {
    grid-template-columns: 1fr;
  }
}

/* ================================
   Admin — Partidos en 2 columnas
   ================================ */

.admin-matches-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr; /* derecha un poco más ancha por la tabla */
  gap: 22px;
  margin-top: 12px;
}

/* Para que no “bailen” las cards internas */
.admin-col {
  min-width: 0;
}

/* Tablet/Mobile: se apila */
@media (max-width: 1024px) {
  .admin-matches-grid {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 1025px) {
  .admin-matches-grid .table-scroll {
    max-height: 520px;
    overflow: auto;
  }
}

/* ================================
   Admin — Partidos: 2 paneles + lista
   ================================ */
/* =========================================
   Igualar ancho de paneles (arriba y abajo)
   ========================================= */

/* Grid superior (Contexto + Sesión | Provisionar) */
.admin-top-grid {
  display: grid;
  grid-template-columns: 1fr 1fr; /* mismo ancho */
  gap: 22px;
  align-items: stretch;
}

/* Grid de paneles (Admin Partidos | Operaciones) */
.admin-panels-grid {
  display: grid;
  grid-template-columns: 1fr 1fr; /* mismo ancho */
  gap: 22px;
  align-items: stretch;
}

.admin-config-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  align-items: start;
  margin-top: 18px;
}
/* Branding panel: una sola columna */
.admin-panel-view[data-admin-panel="branding"] .admin-config-grid {
  grid-template-columns: 1fr;
}
/* Branding panel: inputs en una columna también */
.admin-panel-view[data-admin-panel="branding"] .grid {
  grid-template-columns: 1fr;
  gap: 12px;
}

.integration-hero-card {
  margin-bottom: 18px;
}

.integration-hero {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 18px;
  align-items: end;
}

.integration-hero__eyebrow {
  margin-bottom: 8px;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted);
}

.integration-hero__checklist {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.integration-status-banner {
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(37, 99, 235, 0.08);
  color: var(--text);
  font-weight: 700;
}

/* Branding: logo + fondo */
.branding-media-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 16px;
}
@media (max-width: 900px) {
  .branding-media-grid {
    grid-template-columns: 1fr;
  }
}
.branding-preview-card {
  border-radius: 16px;
  padding: 12px;
  border: 1px solid var(--border-2);
  background: var(--card-soft);
  text-align: center;
}
.branding-preview-card img {
  width: 100%;
  height: 160px;
  border-radius: 12px;
  object-fit: contain;
  background: rgba(15, 23, 42, 0.06);
  display: none;
}
.branding-preview-card.branding-preview-bg img {
  object-fit: cover;
}
.branding-preview-card.has-image img {
  display: block;
}
.branding-preview-empty {
  height: 160px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.06);
  font-size: 0.95rem;
}
.branding-preview-card.has-image .branding-preview-empty {
  display: none;
}

/* Preview de gradiente para botones */
.color-preview-label {
  margin-top: 10px;
  font-weight: 700;
  color: var(--muted);
}
.color-preview {
  height: 44px;
  border-radius: 12px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-2);
  background: linear-gradient(90deg, #128731, #0d9c50);
}

/* Color input: mostrar el color seleccionado */
.color-input {
  appearance: none;
  -webkit-appearance: none;
  width: 100%;
  height: 48px;
  padding: 0;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: transparent;
  cursor: pointer;
}
.color-input::-webkit-color-swatch-wrapper {
  padding: 6px;
}
.color-input::-webkit-color-swatch {
  border: none;
  border-radius: 8px;
}
.color-input::-moz-color-swatch {
  border: none;
  border-radius: 8px;
}

.integration-step {
  margin-top: 16px;
  padding: 16px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.32);
}

html[data-theme="dark"] .integration-step,
body[data-theme="dark"] .integration-step {
  background: rgba(255, 255, 255, 0.03);
}

.integration-step__header {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  align-items: start;
  margin-bottom: 14px;
}

.integration-step__header h3 {
  margin: 0 0 4px;
  font-size: 18px;
}

.integration-step__header p {
  margin: 0;
}

.integration-step__number {
  width: 32px;
  height: 32px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  color: #fff;
  background: linear-gradient(180deg, #128731, #0d9c50);
  box-shadow: 0 8px 18px rgba(13, 156, 80, 0.24);
}

.integration-step__actions {
  margin-top: 12px;
}

.integration-endpoint-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.integration-next-list {
  display: grid;
  gap: 10px;
  color: var(--text);
}

/* Las cards dentro del grid ocupan todo y no desbordan */
.admin-top-grid > .card,
.admin-panels-grid > .card,
.admin-config-grid > .card {
  width: 100%;
  min-width: 0;
}

/* Inputs/select siempre al 100% (evita “panel más angosto”) */
.admin-top-grid input,
.admin-top-grid select,
.admin-panels-grid input,
.admin-panels-grid select {
  width: 100%;
  box-sizing: border-box;
}

/* Pre/code y ayudas largas: que NO empujen el layout */
.json-example,
.admin-log,
.console {
  max-width: 100%;
  white-space: pre-wrap;
  word-break: break-word;
  overflow-x: auto; /* por si hay algo mega largo */
}

/* Hint con wrap correcto */
.hint {
  max-width: 100%;
  overflow: hidden;
}

/* Responsive */
@media (max-width: 1024px) {
  .admin-top-grid,
  .admin-panels-grid,
  .admin-config-grid {
    grid-template-columns: 1fr;
  }

  .integration-hero {
    grid-template-columns: 1fr;
  }

  .integration-hero__checklist {
    justify-content: flex-start;
  }
}

@media (max-width: 640px) {
  .integration-endpoint-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================================
   Evitar overflow de textos largos (JSON)
   ========================================= */

/* Cualquier texto largo dentro de cards */
.card,
.admin-panel,
.admin-subpanel {
  overflow-wrap: break-word;
  word-wrap: break-word;
}

/* Ejemplos JSON y textos largos */
.json-example,
.format-example,
.admin-log,
.console {
  max-width: 100%;
  white-space: pre-wrap; /* respeta saltos y permite wrap */
  word-break: break-word; /* rompe palabras largas */
  overflow-x: auto; /* scroll solo si es necesario */
}

/* Texto plano largo (como "Formato mínimo: [...]") */
.card p,
.card .muted {
  overflow-wrap: anywhere; /* 🔑 rompe strings largos */
}

/* ✅ En login: ocultar logo del header */
body.player-page.lm-auth #headerLogo {
  display: none !important;
}

/* ✅ En login: mostrar el logo grande */
body.player-page.lm-auth .login-logo-wrap {
  display: flex !important;
}

/* ✅ Fuera de login: ocultar el logo grande */
body.player-page:not(.lm-auth) .login-logo-wrap {
  display: none !important;
}

/* ✅ Fuera de login: mostrar logo header */
body.player-page:not(.lm-auth) #headerLogo {
  display: block !important;
}

/* =========================================================
   LIGA MUNDIALISTA — CANVAS en <main>
   ✅ LIGHT: patrón oscuro suave (visible)
   ✅ DARK: patrón claro suave (premium)
   No cambia el contraste del tema, solo agrega textura.
   ========================================================= */

/* Canvas aplicado a toda la pantalla del jugador */
body.player-page {
  position: relative;
  isolation: isolate;
}

/* Asegura contenido por encima del canvas */
body.player-page > #app {
  position: relative;
  z-index: 1;
}

/* -----------------------------
   DARK CANVAS
   ----------------------------- */
body.player-page[data-theme="dark"]::before,
html[data-theme="dark"] body.player-page::before {
  content: none;
}

/* Glow dark (muy suave) */
body.player-page[data-theme="dark"]::after,
html[data-theme="dark"] body.player-page::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.55;

  background:
    radial-gradient(
      1000px 520px at 18% 12%,
      rgba(37, 99, 235, 0.16),
      transparent 60%
    ),
    radial-gradient(
      900px 520px at 85% 18%,
      rgba(245, 158, 11, 0.1),
      transparent 62%
    ),
    radial-gradient(
      1200px 700px at 50% 110%,
      rgba(34, 197, 94, 0.09),
      transparent 60%
    );

  mix-blend-mode: normal;
}

/* -----------------------------
   LIGHT CANVAS
   ----------------------------- */
body.player-page[data-theme="light"]::before,
html[data-theme="light"] body.player-page::before {
  content: none;
}

/* Glow light (más limpio, sin oscurecer) */
body.player-page[data-theme="light"]::after,
html[data-theme="light"] body.player-page::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.45;

  background:
    radial-gradient(
      1000px 520px at 18% 12%,
      rgba(37, 99, 235, 0.1),
      transparent 60%
    ),
    radial-gradient(
      900px 520px at 85% 18%,
      rgba(245, 158, 11, 0.08),
      transparent 62%
    ),
    radial-gradient(
      1200px 700px at 50% 110%,
      rgba(34, 197, 94, 0.07),
      transparent 60%
    );

  mix-blend-mode: normal;
}

/* Si hay fondo del tenant, no aplicar glow extra (color 100%). */
body.player-page.tenant-bg-enabled::after,
html body.player-page.tenant-bg-enabled::after {
  opacity: 0 !important;
}
body.player-page.tenant-bg-enabled::before,
html body.player-page.tenant-bg-enabled::before {
  content: none !important;
  opacity: 0 !important;
}

/* Forzar paneles por tenant (máxima prioridad) */
body.player-page.tenant-panel-theme-enabled .unified-header,
html body.player-page.tenant-panel-theme-enabled .unified-header,
body.player-page.tenant-panel-theme-enabled .header,
html body.player-page.tenant-panel-theme-enabled .header,
body.player-page.tenant-panel-theme-enabled .topbar,
html body.player-page.tenant-panel-theme-enabled .topbar {
  background: var(--tenant-header-panel-bg) !important;
  background-image: none !important;
  border-bottom-color: rgba(255, 255, 255, 0.08) !important;
}
body.player-page.tenant-panel-theme-enabled .bottom-nav,
html body.player-page.tenant-panel-theme-enabled .bottom-nav {
  background: var(--tenant-bottom-panel-bg) !important;
  background-image: none !important;
}

/* Móvil: un poco más suave */
@media (max-width: 520px) {
  body.player-page[data-theme="dark"]::before {
    opacity: 0.14;
  }
  body.player-page[data-theme="dark"]::after {
    opacity: 0.5;
  }

  body.player-page[data-theme="light"]::before {
    opacity: 0.26;
  }
  body.player-page[data-theme="light"]::after {
    opacity: 0.4;
  }
}

.admin-tenant-pinned {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 9999;
  display: flex;
  gap: 8px;
  align-items: center;
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid var(--border-2);
  background: rgba(255, 255, 255, 0.92);
  color: var(--text);
  box-shadow: var(--shadow-2);
  backdrop-filter: blur(8px);
}

.admin-tenant-pinned code {
  max-width: min(44vw, 420px);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

html[data-theme="dark"] .admin-tenant-pinned,
body[data-theme="dark"] .admin-tenant-pinned {
  background: rgba(15, 23, 42, 0.9);
}

@media (max-width: 700px) {
  .admin-tenant-pinned {
    left: 10px;
    right: 10px;
    bottom: 10px;
    justify-content: center;
    flex-wrap: wrap;
    border-radius: 14px;
  }

  .admin-tenant-pinned code {
    max-width: 70vw;
  }
}

.match-progress-card--highlight {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.2);
  background:
    radial-gradient(120% 160% at 0% 0%, rgba(37, 99, 235, 0.2), transparent 45%),
    radial-gradient(120% 160% at 100% 0%, rgba(16, 185, 129, 0.14), transparent 42%),
    linear-gradient(135deg, rgba(15, 23, 42, 0.7), rgba(15, 23, 42, 0.46));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 18px 42px rgba(2, 6, 23, 0.26);
}

.match-progress-card--highlight::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.03), transparent 30%, transparent 70%, rgba(255, 255, 255, 0.04));
}

.match-progress-kicker {
  position: relative;
  z-index: 1;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(191, 219, 254, 0.86);
}

.match-progress-title {
  position: relative;
  z-index: 1;
  margin-top: 6px;
  font-size: clamp(22px, 3vw, 30px);
  font-weight: 900;
  letter-spacing: -0.03em;
  color: #f8fafc;
}

.match-progress-metrics {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.match-progress-pill {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid rgba(191, 219, 254, 0.18);
  background: rgba(255, 255, 255, 0.08);
  color: rgba(241, 245, 249, 0.94);
  font-size: 14px;
  font-weight: 800;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.match-progress-note {
  position: relative;
  z-index: 1;
  margin-top: 14px;
  font-size: 14px;
  line-height: 1.45;
  color: rgba(226, 232, 240, 0.82);
  max-width: 720px;
}

@media (max-width: 640px) {
  .match-progress-title {
    font-size: 22px;
  }

  .match-progress-metrics {
    gap: 8px;
  }

  .match-progress-pill {
    min-height: 34px;
    padding: 7px 12px;
    font-size: 13px;
  }

  .match-progress-note {
    font-size: 13px;
  }
}

/* ================================
   Admin Shell (menu + paneles)
   ================================ */

body.admin-page .main {
  max-width: 1360px;
}

.admin-context-dock {
  margin-bottom: 14px;
}

.admin-context-inner {
  width: 100%;
  margin: 0;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.45);
  box-shadow: 0 12px 30px rgba(17, 24, 39, 0.12);
  border-radius: 16px;
  backdrop-filter: blur(10px);
  padding: 10px 12px;
  box-sizing: border-box;
  contain: layout paint;
}

html[data-theme="dark"] .admin-context-inner,
body[data-theme="dark"] .admin-context-inner {
  background: rgba(15, 23, 42, 0.82);
  border-color: rgba(255, 255, 255, 0.14);
}

.admin-mobile-tenant-status {
  display: none;
  margin-top: 8px;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.admin-shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}

.admin-sidebar {
  position: sticky;
  top: 84px;
  max-height: calc(100vh - 96px);
  overflow: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  background: linear-gradient(180deg, rgba(180, 185, 194, 0.42), rgba(144, 150, 160, 0.34));
  border: 1px solid rgba(255, 255, 255, 0.34);
  border-radius: 24px;
  box-shadow: 0 18px 44px rgba(17, 24, 39, 0.22);
  backdrop-filter: blur(16px);
  padding: 14px;
  z-index: 30;
  transition: transform 0.24s ease, opacity 0.24s ease, box-shadow 0.24s ease;
  contain: layout paint;
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .topbar,
  .card,
  section.card,
  .modal,
  .intro-replay,
  .intro-sound,
  .intro-start,
  .intro-skip,
  .header,
  .admin-context-inner,
  .admin-sidebar,
  .admin-tenant-pinned {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }
}

.admin-sidebar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: 10px;
  font-weight: 800;
}

.admin-sidebar-head .btn {
  height: 30px;
  padding: 0 10px;
  border-radius: 999px;
}

.admin-nav {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.admin-nav-item {
  width: 100%;
  text-align: left;
  margin-top: 0;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.42);
  background: rgba(255, 255, 255, 0.48);
  color: var(--text);
  padding: 12px 14px;
  font-weight: 700;
  box-shadow: 0 5px 14px rgba(15, 23, 42, 0.1);
}

html[data-theme="dark"] .admin-nav-item,
body[data-theme="dark"] .admin-nav-item {
  background: rgba(255, 255, 255, 0.05);
}

.admin-nav-item.is-active {
  border-color: rgba(37, 99, 235, 0.52);
  background: rgba(37, 99, 235, 0.2);
}

.admin-main {
  min-width: 0;
}

.admin-panel-view {
  display: none;
}

.admin-panel-view.is-active {
  display: block;
}

.admin-nav-toggle {
  display: none;
  width: auto !important;
  min-width: 0;
  margin-top: 0 !important;
  padding: 8px 12px;
  flex: 0 0 auto;
  align-self: center;
}

.admin-header-filters {
  display: flex;
  gap: 10px;
  align-items: flex-end;
  justify-content: center;
}

.admin-filter-item {
  display: grid;
  gap: 4px;
}

.admin-filter-item label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.admin-filter-item input,
.admin-filter-item select {
  min-width: 190px;
  height: 38px;
  border-radius: 12px;
}

body.admin-sidebar-unpinned .admin-shell {
  grid-template-columns: minmax(0, 1fr);
}

body.admin-sidebar-unpinned .admin-sidebar {
  position: fixed;
  top: 84px;
  left: 16px;
  width: min(320px, calc(100vw - 32px));
  max-height: calc(100vh - 104px);
  transform: translateX(-112%);
  opacity: 0;
  pointer-events: none;
}

body.admin-sidebar-unpinned .admin-sidebar.is-open {
  transform: translateX(0);
  opacity: 1;
  pointer-events: auto;
}

body.admin-sidebar-unpinned .admin-nav-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

@media (max-width: 1024px) {
  .admin-context-inner {
    padding: 10px;
  }

  .admin-shell {
    grid-template-columns: 1fr;
  }

  .admin-nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: auto !important;
    max-width: fit-content;
  }

  .admin-sidebar {
    position: fixed;
    top: 76px;
    left: 12px;
    width: min(320px, calc(100vw - 24px));
    max-height: calc(100vh - 88px);
    overflow: auto;
    transform: translateX(-112%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.2s ease, opacity 0.2s ease;
  }

  .admin-sidebar.is-open {
    transform: translateX(0);
    opacity: 1;
    pointer-events: auto;
  }

  .admin-header-filters {
    width: 100%;
    flex-direction: column;
    gap: 8px;
    align-items: center;
    justify-content: center;
  }

  .admin-filter-item {
    width: 100%;
    max-width: 420px;
    align-items: center;
  }

  .admin-filter-item label {
    text-align: center;
  }

  .admin-filter-item input,
  .admin-filter-item select {
    min-width: 100%;
    width: 100%;
    max-width: 420px;
  }

  .admin-mobile-tenant-status {
    display: flex;
  }
}

@media (max-width: 560px) {
  .admin-context-inner {
    width: 100%;
    border-radius: 14px;
    padding: 10px;
  }

  .admin-filter-item {
    max-width: 100%;
  }
}

/* ================================
   Unified Player + Home Experience
   ================================ */

body.app-unified {
  background:
    radial-gradient(1200px 720px at 12% 8%, rgba(25, 91, 255, 0.22), transparent 58%),
    radial-gradient(980px 680px at 88% 12%, rgba(13, 156, 80, 0.18), transparent 54%),
    radial-gradient(1200px 760px at 50% 100%, rgba(249, 115, 22, 0.12), transparent 60%),
    linear-gradient(180deg, #08111f 0%, #0d1726 52%, #08111f 100%);
}

body.app-unified[data-theme="light"] {
  background:
    radial-gradient(1200px 720px at 12% 8%, rgba(37, 99, 235, 0.14), transparent 58%),
    radial-gradient(980px 680px at 88% 12%, rgba(22, 163, 74, 0.12), transparent 54%),
    radial-gradient(1200px 760px at 50% 100%, rgba(249, 115, 22, 0.08), transparent 60%),
    linear-gradient(180deg, #f5f7fb 0%, #edf3ff 52%, #f7fafc 100%);
}

body.modal-open {
  overflow: hidden;
}

.app-shell--integrated {
  min-height: 100vh;
}

.unified-header {
  position: sticky;
  top: 0;
  z-index: 80;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background:
    radial-gradient(
      120% 180% at 0% 0%,
      rgba(255, 255, 255, 0.08),
      transparent 38%
    ),
    linear-gradient(180deg, rgba(78, 83, 98, 0.96), rgba(58, 63, 78, 0.96));
  backdrop-filter: blur(18px);
  box-shadow: 0 14px 34px rgba(2, 6, 23, 0.18);
}

body[data-theme="light"] .unified-header {
  background:
    radial-gradient(
      120% 180% at 0% 0%,
      rgba(255, 255, 255, 0.74),
      transparent 36%
    ),
    linear-gradient(180deg, rgba(234, 240, 248, 0.96), rgba(220, 228, 240, 0.96));
  border-bottom-color: rgba(86, 94, 114, 0.18);
  box-shadow: 0 14px 28px rgba(15, 23, 42, 0.08);
}

.unified-header__inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 14px 20px;
  gap: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.topbar-inner {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  min-height: 78px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.topbar-brand {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex: 1 1 auto;
}
.games-menu-button:hover {
  transform: translateY(-1px);
}

.brand-lockup {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 14px;
  color: inherit;
  text-decoration: none;
  cursor: pointer;
  padding: 8px 12px;
  border-radius: 24px;
  transition:
    background 0.2s ease,
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.brand-lockup:hover {
  background: rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

body[data-theme="light"] .brand-lockup:hover {
  background: rgba(255, 255, 255, 0.52);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

.brand-lockup-logo,
.unified-brand__logo {
  width: 140px;
  height: 140px;
  border-radius: 0;
  object-fit: contain;
  padding: 0;
  background: transparent;
  border: 0;
  flex: 0 0 auto;
}

.brand-lockup-copy {
  min-width: 0;
  display: grid;
  align-content: center;
  gap: 0;
}

body.player-page.brand-has-logo #brandLockup .brand-lockup-copy {
  display: none;
}

body.player-page:not(.brand-has-logo) #brandLockup .brand-lockup-copy {
  display: grid;
}

body.lm-default-brand .brand-lockup-copy {
  display: none;
}

body.lm-default-brand .brand-lockup {
  gap: 0;
}

body.lm-default-brand .brand-lockup-logo,
body.lm-default-brand .unified-brand__logo {
  width: 180px;
  height: 88px;
}

#brandCompany {
  cursor: pointer;
}

.brand-meta {
  display: none !important;
}

.brand-company {
  display: block;
  line-height: 1.04;
  font-weight: 900;
  color: var(--brand-text-color, rgba(255, 255, 255, 0.97));
  text-shadow: var(--brand-text-shadow, 0 2px 8px rgba(0, 0, 0, 0.35));
  letter-spacing: -0.03em;
}

body[data-theme="light"] .brand-company {
  color: var(--brand-text-color, rgba(31, 41, 55, 0.96));
  text-shadow: var(--brand-text-shadow, 0 2px 8px rgba(255, 255, 255, 0.35));
}

.nav-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  flex: 0 0 auto;
  margin-left: auto;
}

@media (min-width: 1024px) {
  .unified-header__inner.topbar-inner,
  .topbar-inner.unified-header__inner {
    width: min(1320px, calc(100% - 56px));
    min-height: 100px;
    padding-top: 8px;
    padding-bottom: 8px;
    padding-left: 12px;
    padding-right: 12px;
    gap: 24px;
  }

  .topbar-brand {
    display: flex;
    align-items: center;
    min-width: 0;
    flex: 1 1 auto;
  }

  .brand-lockup {
    min-height: 80px;
    padding: 8px 14px;
    gap: 16px;
  }

  body.lm-default-brand .brand-lockup {
    padding-left: 6px;
    padding-right: 10px;
  }

  .brand-lockup-logo,
  .unified-brand__logo {
    width: 140px;
    height: 140px;
  }

  body.lm-default-brand .brand-lockup-logo,
  body.lm-default-brand .unified-brand__logo {
    width: 164px;
    height: 80px;
  }

  .nav-actions {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: max-content;
    align-items: center;
    justify-content: end;
    gap: 16px;
    flex: 0 0 auto;
    min-height: 80px;
    margin-left: auto;
  }

  .nav-actions .account-chip {
    min-height: 64px;
    max-width: min(340px, 28vw);
    padding: 8px 18px 8px 8px;
  }

  .nav-actions .account-chip-copy {
    max-width: min(210px, 18vw);
  }

  .nav-actions .account-chip-avatar {
    width: 40px;
    height: 40px;
  }

  .games-menu-wrap {
    align-self: center;
  }

  .nav-actions .games-menu-button {
    width: 56px;
    min-width: 56px;
    min-height: 56px;
    border-radius: 20px;
  }
}

@media (min-width: 1280px) {
  .unified-header__inner.topbar-inner,
  .topbar-inner.unified-header__inner {
    width: min(1380px, calc(100% - 72px));
    gap: 28px;
  }

  .nav-actions {
    gap: 18px;
  }

  .nav-actions .account-chip {
    max-width: 380px;
  }

  .nav-actions .account-chip-copy {
    max-width: 240px;
  }
}

.account-chip {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  width: auto;
  margin-top: 0;
  padding: 8px 16px 8px 8px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.96);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 12px 26px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(12px);
  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

body[data-theme="light"] .account-chip {
  background: rgba(255, 255, 255, 0.66);
  border-color: rgba(86, 94, 114, 0.14);
  color: rgba(31, 41, 55, 0.94);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.8),
    0 10px 22px rgba(15, 23, 42, 0.08);
}

.account-chip:hover {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.16);
}

body[data-theme="light"] .account-chip:hover {
  background: rgba(255, 255, 255, 0.86);
  border-color: rgba(86, 94, 114, 0.2);
}

.account-chip-avatar {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0.04em;
  flex: 0 0 auto;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.14),
    0 8px 18px rgba(2, 6, 23, 0.16);
}

body[data-theme="light"] .account-chip-avatar {
  background: rgba(88, 91, 102, 0.16);
  color: rgba(31, 41, 55, 0.96);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.65),
    0 8px 18px rgba(15, 23, 42, 0.08);
}

.account-chip-copy {
  min-width: 0;
  display: grid;
  text-align: left;
  gap: 2px;
}

.profile-trigger__name,
.account-chip-copy strong {
  display: block;
  font-size: 14px;
  font-weight: 900;
  line-height: 1.08;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.account-chip-copy small {
  display: block;
  font-size: 12px;
  line-height: 1.08;
  color: rgba(226, 232, 240, 0.72);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

body[data-theme="light"] .account-chip-copy small {
  color: rgba(15, 23, 42, 0.56);
}

.games-menu-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.games-menu-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  min-width: 52px;
  min-height: 52px;
  padding: 0;
  gap: 4px;
  flex-direction: column;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.08);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 10px 24px rgba(2, 6, 23, 0.16);
  color: rgba(255, 255, 255, 0.94);
  line-height: 1;
  overflow: hidden;
  backdrop-filter: blur(14px);
  transition:
    transform 0.22s ease,
    border-color 0.22s ease,
    background 0.22s ease,
    box-shadow 0.22s ease;
}

body[data-theme="light"] .games-menu-button {
  border-color: rgba(86, 94, 114, 0.14);
  background: rgba(255, 255, 255, 0.66);
  color: rgba(31, 41, 55, 0.9);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.8),
    0 10px 24px rgba(15, 23, 42, 0.08);
}

.games-menu-button:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.16);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.12),
    0 12px 26px rgba(2, 6, 23, 0.18);
}

body[data-theme="light"] .games-menu-button:hover {
  background: rgba(255, 255, 255, 0.84);
  border-color: rgba(86, 94, 114, 0.2);
}

.games-menu-button[aria-expanded="true"] {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.18);
}

body[data-theme="light"] .games-menu-button[aria-expanded="true"] {
  background: rgba(255, 255, 255, 0.94);
  border-color: rgba(86, 94, 114, 0.22);
}

.games-menu-button span {
  display: block;
  width: 20px;
  height: 2px;
  flex: 0 0 auto;
  border-radius: 999px;
  background: currentColor;
  transition: transform 0.24s ease, opacity 0.24s ease;
}

.games-menu-button[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(6.5px) rotate(45deg);
}

.games-menu-button[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.games-menu-button[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-6.5px) rotate(-45deg);
}

.games-menu {
  position: absolute;
  top: calc(100% + 14px);
  right: 0;
  z-index: 90;
  width: min(360px, calc(100vw - 28px));
  padding: 14px;
  border-radius: 26px;
  border: 1px solid rgba(150, 198, 255, 0.14);
  background:
    radial-gradient(120% 160% at 100% 0%, rgba(37, 99, 235, 0.18), transparent 38%),
    linear-gradient(180deg, rgba(10, 20, 33, 0.98), rgba(9, 16, 28, 0.98));
  box-shadow:
    0 24px 56px rgba(2, 6, 23, 0.34),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(16px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-8px) scale(0.97);
  transform-origin: top right;
}

body[data-theme="light"] .games-menu {
  border-color: rgba(15, 23, 42, 0.08);
  background:
    radial-gradient(120% 160% at 100% 0%, rgba(37, 99, 235, 0.08), transparent 38%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(241, 245, 249, 0.98));
}

.games-menu-wrap.is-open .games-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}

.games-menu-section + .games-menu-section {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

body[data-theme="light"] .games-menu-section + .games-menu-section {
  border-top-color: rgba(15, 23, 42, 0.08);
}

.games-menu-title {
  margin-bottom: 10px;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--faint);
}

.games-menu-item,
.games-menu .select,
.games-menu .auth-badge {
  width: 100%;
}

.games-menu-item {
  display: grid;
  justify-items: start;
  gap: 3px;
  min-height: 58px;
  margin-top: 0;
  padding: 14px 16px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  box-shadow: none;
}

.games-menu-item + .games-menu-item,
.games-menu .select + .games-menu-item,
.games-menu .auth-badge + .games-menu-item {
  margin-top: 10px;
}

body[data-theme="light"] .games-menu-item,
body[data-theme="light"] .games-menu .select,
body[data-theme="light"] .games-menu .auth-badge {
  background: rgba(255, 255, 255, 0.86);
  border-color: rgba(15, 23, 42, 0.08);
}

.games-menu-item strong {
  font-size: 14px;
  font-weight: 900;
  line-height: 1.1;
}

.games-menu-item span {
  font-size: 12px;
  line-height: 1.3;
  color: var(--muted);
}

.games-menu .select {
  min-height: 54px;
  border-radius: 18px;
}

.games-menu #btnThemeToggle {
  display: grid;
  justify-items: start;
  width: 100%;
  height: auto;
  min-height: 58px;
  padding: 14px 16px;
  border-radius: 18px;
  box-shadow: none;
}

.games-menu .auth-badge {
  display: flex;
  justify-content: center;
  min-height: 46px;
  padding: 10px 14px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.05);
}

.games-menu .auth-badge.hidden,
.games-menu .auth-badge[hidden] {
  display: none !important;
}

.btn-inline,
.btn-inline-lg {
  width: auto;
  margin-top: 0;
}

.btn-inline-lg {
  min-width: 170px;
  min-height: 48px;
}

.unified-main {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 28px 20px 140px;
}

.app-container {
  display: grid;
  gap: 22px;
  width: 100%;
  min-width: 0;
}

#viewMatches {
  width: min(100%, 980px);
  margin: 0 auto;
  min-width: 0;
}

.integrated-card {
  padding: 22px;
}

.home-hero {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
  gap: 24px;
  padding: 28px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background:
    radial-gradient(120% 120% at 0% 0%, rgba(37, 99, 235, 0.22), transparent 42%),
    radial-gradient(120% 120% at 100% 0%, rgba(13, 156, 80, 0.18), transparent 38%),
    linear-gradient(135deg, rgba(4, 12, 24, 0.92), rgba(8, 17, 31, 0.84));
}

body[data-theme="light"] .home-hero {
  border-color: rgba(15, 23, 42, 0.08);
  background:
    radial-gradient(120% 120% at 0% 0%, rgba(37, 99, 235, 0.14), transparent 42%),
    radial-gradient(120% 120% at 100% 0%, rgba(13, 156, 80, 0.11), transparent 38%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.94), rgba(241, 245, 249, 0.96));
}

.home-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.04), transparent 24%, transparent 76%, rgba(255, 255, 255, 0.04)),
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), transparent 48%);
}

.home-hero__copy,
.home-hero__media {
  position: relative;
  z-index: 1;
  min-width: 0;
}

.home-hero__eyebrow {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid rgba(191, 219, 254, 0.18);
  background: rgba(255, 255, 255, 0.06);
  color: rgba(226, 232, 240, 0.88);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

body[data-theme="light"] .home-hero__eyebrow {
  background: rgba(15, 23, 42, 0.05);
  color: rgba(15, 23, 42, 0.74);
  border-color: rgba(15, 23, 42, 0.08);
}

.home-hero__title {
  margin: 18px 0 14px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 0.96;
  font-weight: 900;
  color: #f8fafc;
  text-wrap: balance;
}

body[data-theme="light"] .home-hero__title {
  color: #0f172a;
}

.home-hero__text {
  max-width: 640px;
  margin: 0;
  font-size: 17px;
  line-height: 1.6;
  color: rgba(226, 232, 240, 0.82);
}

body[data-theme="light"] .home-hero__text {
  color: rgba(15, 23, 42, 0.72);
}

.home-hero__cta {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin: 24px 0 18px;
}

body.lm-logged .home-hero__cta {
  display: none;
}

.home-hero__trust {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-video-card {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(2, 6, 23, 0.52);
  min-height: 360px;
  aspect-ratio: 16 / 10;
  box-shadow: 0 18px 52px rgba(2, 6, 23, 0.32);
}

.home-hero__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #000;
}

.onboarding-panel {
  margin-top: 18px;
  padding: 24px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  box-shadow: 0 20px 44px rgba(15, 23, 42, 0.08);
}

body[data-theme="dark"] .onboarding-panel {
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.28);
}

.onboarding-panel__head {
  margin-bottom: 16px;
}

.onboarding-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.onboarding-item {
  display: grid;
  gap: 8px;
  min-height: 130px;
  padding: 18px;
  border-radius: 18px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.04);
}

body[data-theme="light"] .onboarding-item {
  background: rgba(255, 255, 255, 0.72);
}

.onboarding-item__number {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-bottom: 6px;
  border-radius: 14px;
  background: linear-gradient(180deg, var(--btn-primary-start), var(--btn-primary-end));
  color: #fff;
  font-size: 18px;
  font-weight: 900;
  box-shadow: 0 12px 24px rgba(13, 156, 80, 0.24);
}

.onboarding-item strong {
  font-size: 16px;
}

.onboarding-item span {
  color: var(--muted);
  line-height: 1.55;
}

.modal-screen {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  padding: 20px;
}

.modal-screen.hidden {
  display: none !important;
}

.modal-screen__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 6, 23, 0.76);
  backdrop-filter: blur(8px);
}

.modal-screen__dialog {
  position: relative;
  z-index: 1;
  width: min(100%, 560px);
  max-height: calc(100vh - 40px);
  overflow: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  border-radius: 28px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background:
    radial-gradient(120% 160% at 0% 0%, rgba(37, 99, 235, 0.18), transparent 38%),
    linear-gradient(180deg, rgba(8, 17, 31, 0.98), rgba(10, 15, 28, 0.96));
  box-shadow: 0 28px 90px rgba(2, 6, 23, 0.54);
}

body[data-theme="light"] .modal-screen__dialog {
  border-color: rgba(15, 23, 42, 0.08);
  background:
    radial-gradient(120% 160% at 0% 0%, rgba(37, 99, 235, 0.09), transparent 38%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(241, 245, 249, 0.98));
}

.modal-screen__dialog--profile {
  width: min(100%, 980px);
}

.stats-panel,
.world-panel,
.match-center-column,
.match-center-detail,
.match-center-rail,
.module-shell,
.integrated-card {
  min-width: 0;
}

.modal-screen__close {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 2;
}

.auth-panel,
.profile-shell {
  padding: 28px;
}

.auth-panel__logo {
  margin: 0 0 16px;
  justify-content: flex-start;
}

.profile-shell__title {
  margin-bottom: 10px;
  font-size: clamp(32px, 4vw, 56px);
  color: #f8fafc;
}

body[data-theme="light"] .profile-shell__title {
  color: #0f172a;
}

.profile-shell__intro {
  margin-top: 0;
  margin-bottom: 22px;
  font-size: 18px;
}

.profile-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.profile-field {
  display: grid;
  gap: 8px;
  min-height: 118px;
  padding: 20px;
  border-radius: 22px;
  border: 1px solid rgba(59, 130, 246, 0.16);
  background: rgba(2, 6, 23, 0.34);
}

body[data-theme="light"] .profile-field {
  background: rgba(255, 255, 255, 0.82);
  border-color: rgba(15, 23, 42, 0.08);
}

.profile-field span {
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.profile-field strong {
  font-size: 24px;
  line-height: 1.2;
  text-wrap: balance;
}

.bottom-nav .bn-item:disabled,
.bottom-nav .bn-item.is-disabled {
  opacity: 0.62;
  filter: none;
  cursor: not-allowed;
  pointer-events: none;
}

.bottom-nav .bn-item.is-disabled .bn-txt {
  color: rgba(255, 255, 255, 0.6);
}

@media (max-width: 1280px) {
  .bottom-nav {
    width: min(calc(100% - 28px), calc(100vw - 28px));
  }
}

@media (max-width: 1024px) {
  .home-hero {
    grid-template-columns: 1fr;
  }

  .onboarding-grid,
  .profile-grid {
    grid-template-columns: 1fr 1fr;
  }

  .stats-toolbar,
  .stats-compare-toolbar {
    grid-template-columns: 1fr;
  }

  .stats-panels-grid,
  .stats-compare-grid,
  .world-hero {
    grid-template-columns: 1fr;
  }

  .match-center-status,
  .world-status-badges {
    align-items: flex-start;
    justify-content: flex-start;
  }

  .match-center-stage-insights,
  .match-center-penalties__grid {
    grid-template-columns: 1fr;
  }

  .match-center-stage-column--right,
  .match-center-penalties__item--away {
    text-align: left;
    justify-content: flex-start;
  }

  .match-center-stage-event--away {
    grid-template-columns: auto auto minmax(0, 1fr);
  }

  .match-center-stage-event--away .match-center-stage-event__minute,
  .match-center-stage-event--away .match-center-stage-event__icon,
  .match-center-stage-event--away .match-center-stage-event__label {
    order: initial;
  }

  .world-hero {
    padding: 20px 18px;
    border-radius: 24px;
    gap: 16px;
  }

  .world-status-badges .chip {
    width: 100%;
    min-width: 0;
    padding: 11px 14px;
  }

  .world-live-card__match,
  .world-fixture-card__teams {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .world-live-card__team--right {
    text-align: center;
  }

  .world-fixture-card {
    min-height: 236px;
  }

  .world-fixture-card__teams--showcase {
    gap: 10px;
  }

  .world-fixture-card__team-name {
    font-size: 14px;
  }

  .world-fixture-card__score-pill {
    min-width: 92px;
  }
}

@media (max-width: 820px) {
  .match-center-shell,
  .match-center-grid,
  .match-center-predictions__hero,
  .match-center-predictions__trends {
    grid-template-columns: 1fr;
  }

  .match-center-header,
  .match-center-status {
    align-items: flex-start;
  }

  .match-center-scoreboard {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .match-center-team--right {
    text-align: center;
  }
}

@media (max-width: 834px) {
  .unified-header {
    padding: 0;
  }

  .unified-header__inner.topbar-inner,
  .topbar-inner.unified-header__inner {
    width: 100%;
    max-width: none;
    min-height: 67px;
    gap: 10px;
    padding-top: 5px;
    padding-bottom: 5px;
    padding-left: 10px;
    padding-right: 10px;
  }

  .player-page .main.unified-main,
  .unified-main {
    max-width: none;
    padding-left: 12px;
    padding-right: 12px;
  }

  #viewMatches,
  #viewMatches .list,
  #viewMatches .match-top,
  #viewMatches .match-head,
  #viewMatches .teams-grid,
  #viewMatches .team,
  #viewMatches .pred-row,
  #viewMatches .match-footer {
    min-width: 0;
    max-width: 100%;
  }

  #viewMatches .match {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow: hidden;
  }

  #viewMatches .match-top {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    gap: 10px;
  }

  #viewMatches .teams-grid {
    grid-template-columns: minmax(0, 1fr) 32px minmax(0, 1fr);
    gap: 10px;
  }

  #viewMatches .pred-row {
    width: 100%;
    grid-template-columns: minmax(0, 1fr) 18px minmax(0, 1fr);
    gap: 8px;
    max-width: none;
  }

  #viewMatches .pred-row input {
    min-width: 0;
  }

  #viewMatches .badge {
    justify-self: start;
    align-self: start;
  }

  .bottom-nav {
    left: 0;
    right: 0;
    width: 100%;
    max-width: none;
    transform: none;
  }
}

@media (max-width: 720px) {
  .topbar-inner,
  .unified-main {
    padding-left: 14px;
    padding-right: 14px;
  }

  .topbar-inner {
    gap: 10px;
    min-height: 63px;
    padding-top: 8px;
    padding-bottom: 8px;
  }

  .topbar-brand {
    gap: 5px;
    min-width: 0;
    margin-left: -6px;
  }

  .brand-lockup {
    gap: 10px;
    padding-left: 6px;
    padding-right: 8px;
  }

  .brand-lockup-logo,
  .unified-brand__logo {
    width: 78px;
    height: 72px;
  }

  body.lm-default-brand .brand-lockup-logo,
  body.lm-default-brand .unified-brand__logo {
    width: 156px;
    height: 76px;
  }

  .brand-lockup-copy {
    gap: 2px;
  }

  .brand-company {
    font-size: 17px;
    line-height: 1;
  }

  .brand-meta {
    flex-wrap: wrap;
    gap: 4px;
    font-size: 11px;
    margin-top: 2px;
  }

  .nav-actions {
    gap: 10px;
    margin-left: 0;
    margin-right: -2px;
  }

  .games-menu-wrap {
    justify-content: flex-end;
  }

  .account-chip {
    display: none;
  }

  .games-menu {
    width: min(340px, calc(100vw - 20px));
    right: -2px;
    padding: 14px;
  }

  .games-menu-button {
    width: 48px;
    min-width: 48px;
    min-height: 48px;
    border-radius: 16px;
    margin-top: 0;
  }

  .home-hero,
  .integrated-card,
  .auth-panel,
  .profile-shell {
    padding: 20px;
  }

  .app-container {
    gap: 16px;
  }

  .home-hero__title {
    font-size: 34px;
  }

  .home-hero__text,
  .world-hero__copy,
  .muted {
    overflow-wrap: anywhere;
  }

  .onboarding-grid,
  .profile-grid {
    grid-template-columns: 1fr;
  }

  .hero-video-card {
    min-height: 260px;
    aspect-ratio: 16 / 9;
  }

  .tabs {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 4px;
    scrollbar-width: none;
  }

  .tabs::-webkit-scrollbar {
    display: none;
  }

  .tab {
    flex: 0 0 auto;
    min-width: 140px;
  }

  .row.space-between {
    flex-direction: column;
    align-items: flex-start;
  }

  .world-hero__title,
  .match-center-event {
    font-size: 24px;
  }

  .world-hero__copy {
    font-size: 15px;
  }

  .match-center-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .match-center-stage {
    min-height: 0;
  }

  .profile-field strong {
    font-size: 20px;
  }

  .btn-inline-lg {
    width: 100%;
  }

  .bottom-nav {
    left: 0;
    right: 0;
    width: 100%;
    max-width: none;
    transform: none;
    padding-left: 8px;
    padding-right: 8px;
    gap: 2px;
    border-radius: 18px 18px 0 0;
  }

  .bottom-nav .bn-item {
    padding: 8px 4px;
  }

  .bottom-nav .bn-txt {
    font-size: 10px;
  }
}

@media (max-width: 560px) {
  .topbar-inner {
    gap: 10px;
    min-height: 78px;
    padding-top: 8px;
    padding-bottom: 8px;
  }

  .topbar-brand {
    margin-left: -8px;
  }

  .brand-lockup {
    gap: 8px;
    padding-left: 4px;
    padding-right: 6px;
  }

  .brand-lockup-logo,
  .unified-brand__logo {
    width: 85px;
    height: 50px;
    padding: 0;
  }

  .brand-company {
    font-size: 15px;
  }

  .games-menu-button {
    width: 46px;
    min-width: 46px;
    height: 46px;
    min-height: 46px;
    margin-right: 0;
  }

  .home-hero,
  .integrated-card,
  .auth-panel,
  .profile-shell,
  .modal-screen__dialog {
    border-radius: 22px;
  }

  .hero-video-card {
    min-height: 220px;
  }

  .onboarding-item,
  .profile-field {
    padding: 16px;
  }

  .modal-screen {
    padding: 12px;
  }

  .modal-screen__dialog,
  .modal-screen__dialog--profile {
    width: 100%;
    max-height: calc(100vh - 24px);
  }

  .bottom-nav {
    left: 0;
    right: 0;
    width: 100%;
    max-width: none;
    transform: none;
    padding-left: 6px;
    padding-right: 6px;
    padding-top: 8px;
    padding-bottom: calc(8px + env(safe-area-inset-bottom));
    border-radius: 16px 16px 0 0;
  }
}

@media (max-width: 420px) {
  .unified-main {
    padding-left: 10px;
    padding-right: 10px;
    padding-top: 18px;
  }

  .topbar-inner {
    padding-left: 10px;
    padding-right: 10px;
  }

  .topbar-brand {
    margin-left: -10px;
  }

  .brand-lockup {
    padding-left: 2px;
    padding-right: 4px;
  }

  .brand-company {
    font-size: 13px;
  }

  body.lm-default-brand .brand-lockup-logo,
  body.lm-default-brand .unified-brand__logo {
    width: 142px;
    height: 68px;
  }

  .brand-meta {
    font-size: 10px;
  }

  .games-menu-button {
    width: 44px;
    height: 44px;
    min-width: 44px;
  }

  .home-hero__title {
    font-size: 28px;
  }

  .home-hero__text {
    font-size: 15px;
  }

  .tab {
    min-width: 124px;
  }

  .bottom-nav .bn-icoWrap {
    width: 34px;
    height: 24px;
  }

  .bottom-nav .bn-ico {
    width: 20px;
    height: 20px;
  }

  .bottom-nav .bn-txt {
    font-size: 9px;
  }
}

@media (max-width: 430px) {
  .hero-video-card {
    min-height: 0;
    aspect-ratio: 16 / 11;
    background: #000;
  }

  .home-hero__video {
    object-fit: contain;
    object-position: center center;
  }
}

@media (prefers-reduced-motion: reduce) {
  .bottom-nav--session-glow::before {
    animation: none !important;
    opacity: 0 !important;
  }
}
