/* =====================================================================
   LIGA — sistema visual
   Noche de estadio: fondos casi negros, verde césped profundo y un
   acento lima eléctrico. Títulos y números en Barlow Condensed.
   ===================================================================== */

@font-face { font-family: "Barlow Condensed"; font-weight: 600; font-display: swap; src: url(/fonts/barlow-condensed-latin-600-normal.woff2) format("woff2"); }
@font-face { font-family: "Barlow Condensed"; font-weight: 700; font-display: swap; src: url(/fonts/barlow-condensed-latin-700-normal.woff2) format("woff2"); }
@font-face { font-family: "Barlow Condensed"; font-weight: 800; font-display: swap; src: url(/fonts/barlow-condensed-latin-800-normal.woff2) format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 100 900; font-display: swap; src: url(/fonts/inter-latin-wght-normal.woff2) format("woff2"); }

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

  --bg: #070b14;
  --bg-glow: radial-gradient(120% 60% at 50% -10%, #13213f 0%, rgba(7, 11, 20, 0) 60%);
  --surface: #0d1424;
  --surface-2: #121b2f;
  --surface-3: #1a253d;
  --line: rgba(255, 255, 255, .07);
  --line-strong: rgba(255, 255, 255, .13);
  --text: #f5f7fb;
  --text-2: #c5ccd8;
  --muted: #7d8aa5;

  --accent: #d4af5a;          /* oro de la marca */
  --accent-ink: #e3c27a;      /* oro usado como texto */
  --on-accent: #0a0f1c;
  --accent-soft: rgba(212, 175, 90, .13);
  --gold-grad: linear-gradient(160deg, #f1d68f 0%, #d4af5a 45%, #a87f2c 100%);
  --pitch-1: #1c2f57;
  --pitch-2: #0e1a33;
  --pitch-3: #070b14;

  --win: #2fd17a;
  --draw: #8b9690;
  --loss: #ff5468;
  --danger: #ff5468;
  --danger-soft: rgba(255, 84, 104, .12);
  --warn: #ffb547;
  --warn-soft: rgba(255, 181, 71, .12);
  --ok-soft: rgba(47, 209, 122, .12);
  --gold: #ffd75e;
  --silver: #d6dde1;
  --bronze: #e3a26f;
  --yellow: #ffd23f;
  --red: #ff3b4f;
  /* probabilidades local / empate / visitante (validadas para daltonismo) */
  --p-home: #ae8838;
  --p-draw: #3a4458;
  --p-away: #4f7dff;

  --r-sm: 10px;
  --r: 18px;
  --r-lg: 26px;
  --shadow: 0 1px 0 rgba(255, 255, 255, .04) inset, 0 10px 30px -12px rgba(0, 0, 0, .65);
  --shadow-pop: 0 20px 50px -12px rgba(0, 0, 0, .75);
  --glass: rgba(10, 16, 30, .8);

  --top-h: 60px;
  --nav-h: 70px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
  color-scheme: dark;
}

:root[data-theme="light"] {
  --bg: #f2f4f8;
  --bg-glow: radial-gradient(120% 60% at 50% -10%, #dfe6f3 0%, rgba(242, 244, 248, 0) 60%);
  --surface: #ffffff;
  --surface-2: #f4f6fa;
  --surface-3: #e8ecf3;
  --line: rgba(14, 26, 51, .08);
  --line-strong: rgba(14, 26, 51, .16);
  --text: #0e1a33;
  --text-2: #3a4763;
  --muted: #6b7690;
  --accent: #d4af5a;
  --accent-ink: #8a6420;
  --on-accent: #0a0f1c;
  --accent-soft: rgba(168, 127, 44, .12);
  --win: #12924f;
  --loss: #d92d43;
  --danger: #d92d43;
  --warn: #a8650b;
  --p-home: #a87f2c;
  --p-draw: #d5dae3;
  --p-away: #3d63d6;
  --shadow: 0 1px 2px rgba(14, 26, 51, .05), 0 10px 30px -14px rgba(14, 26, 51, .22);
  --shadow-pop: 0 20px 50px -12px rgba(14, 26, 51, .35);
  --glass: rgba(255, 255, 255, .82);
  color-scheme: light;
}

/* ---------------------------------------------------------------- base */
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
[hidden] { display: none !important; }
html, body { margin: 0; }
body {
  font: 15px/1.5 var(--font);
  font-feature-settings: "cv11", "ss01";
  background: var(--bg-glow), var(--bg);
  background-attachment: fixed;
  color: var(--text);
  min-height: 100vh;
  overscroll-behavior-y: none;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button { font: inherit; color: inherit; }
svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
code { font-size: .9em; background: var(--surface-3); padding: 1px 6px; border-radius: 6px; }
::selection { background: var(--accent); color: var(--on-accent); }

.display { font-family: var(--display); font-weight: 800; text-transform: uppercase; letter-spacing: .01em; line-height: .95; }
.num { font-family: var(--display); font-weight: 700; font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.xs { font-size: 11.5px; }
.center { text-align: center; }
.accent { color: var(--accent-ink); }
.row { display: flex; align-items: center; gap: 10px; }
.row.wrap { flex-wrap: wrap; }
.spacer { flex: 1; }
.grow { flex: 1; min-width: 0; }
.ellipsis { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ------------------------------------------------------------- topbar */
.topbar {
  position: sticky; top: 0; z-index: 30;
  display: flex; align-items: center; gap: 6px;
  height: calc(var(--top-h) + var(--safe-t)); padding: var(--safe-t) 10px 0 14px;
  background: var(--glass);
  backdrop-filter: saturate(160%) blur(18px); -webkit-backdrop-filter: saturate(160%) blur(18px);
  border-bottom: 1px solid var(--line);
}
.topbar h1 {
  flex: 1; margin: 0; min-width: 0;
  font: 800 22px/1 var(--display); text-transform: uppercase; letter-spacing: .02em;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.brand { display: flex; align-items: center; gap: 9px; margin-right: 6px; }
.brand img { width: 30px; height: 35px; filter: drop-shadow(0 2px 6px rgba(0, 0, 0, .4)); }
.brand .wm { display: none; flex-direction: column; line-height: 1; }
.brand .wm small { font: 700 10px/1 var(--display); letter-spacing: .38em; color: var(--accent-ink); margin-bottom: 3px; }
.brand .wm b { font: 800 19px/1 var(--display); letter-spacing: .02em; }
.top-actions { display: flex; gap: 4px; }
.icon-btn {
  display: inline-grid; place-items: center; width: 42px; height: 42px; flex: none;
  border: 0; border-radius: 14px; background: transparent; color: inherit; cursor: pointer;
  transition: background .15s;
}
.icon-btn:hover { background: var(--surface-2); }
.icon-btn:active { transform: scale(.94); }
.topbar .back:not([hidden]) + .brand { display: none; }

/* ---------------------------------------------------- nav (flotante) */
.nav {
  position: fixed; z-index: 30;
  left: 12px; right: 12px; bottom: calc(10px + var(--safe-b));
  display: grid; grid-template-columns: repeat(5, 1fr); align-items: center;
  height: var(--nav-h); padding: 0 6px;
  background: var(--glass);
  backdrop-filter: saturate(170%) blur(20px); -webkit-backdrop-filter: saturate(170%) blur(20px);
  border: 1px solid var(--line-strong); border-radius: 24px;
  box-shadow: var(--shadow-pop);
}
.nav a {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  height: 56px; border-radius: 18px; color: var(--muted);
  font-size: 10.5px; font-weight: 600; letter-spacing: .02em; transition: color .2s;
}
.nav a svg { width: 23px; height: 23px; transition: transform .2s; }
.nav a.active { color: var(--text); }
.nav a.active::after {
  content: ""; position: absolute; bottom: 3px; width: 18px; height: 3px; border-radius: 3px; background: var(--gold-grad);
}
.nav a:active svg { transform: scale(.9); }
.nav .nav-main { color: var(--on-accent); }
.nav .nav-main svg {
  width: 54px; height: 54px; padding: 14px; margin-top: -30px;
  background: var(--gold-grad); border-radius: 19px;
  box-shadow: 0 10px 24px -6px rgba(212, 175, 90, .55), 0 0 0 5px var(--bg);
  stroke-width: 2.4;
}
.nav .nav-main span { color: var(--muted); }
.nav .nav-main.active span { color: var(--text); }
.nav .nav-main.active::after { display: none; }

.app {
  max-width: 1120px; margin: 0 auto;
  padding: 14px 16px calc(var(--nav-h) + var(--safe-b) + 40px);
}

@media (min-width: 960px) {
  .brand .wm { display: flex; }
  .topbar { padding-left: 22px; }
  .topbar .back:not([hidden]) + .brand { display: flex; }
  .topbar h1 { font-size: 24px; padding-left: 12px; border-left: 1px solid var(--line-strong); }
  .nav {
    top: calc(var(--top-h) + var(--safe-t) + 16px); left: 16px; right: auto; bottom: auto;
    width: 220px; height: auto; padding: 10px;
    display: flex; flex-direction: column; gap: 4px; border-radius: 22px;
  }
  .nav a { flex-direction: row; justify-content: flex-start; gap: 12px; height: 46px; padding: 0 14px; font-size: 14.5px; width: 100%; }
  .nav a.active { background: var(--surface-3); }
  .nav a.active::after { left: 0; top: 12px; bottom: auto; width: 3px; height: 22px; }
  .nav .nav-main { color: inherit; order: -1; background: var(--gold-grad); color: var(--on-accent) !important; margin-bottom: 8px; }
  .nav .nav-main svg { width: 23px; height: 23px; padding: 0; margin: 0; background: none; box-shadow: none; }
  .nav .nav-main span { color: var(--on-accent) !important; font-weight: 700; }
  .app { padding: 28px 36px 60px; margin-left: 252px; }
}
@media (min-width: 1400px) { .app { margin-left: auto; } }

/* ------------------------------------------------------- animaciones */
.app > * { animation: rise .45s cubic-bezier(.2, .8, .2, 1) both; }
.app > *:nth-child(2) { animation-delay: .04s; }
.app > *:nth-child(3) { animation-delay: .08s; }
.app > *:nth-child(4) { animation-delay: .12s; }
.app > *:nth-child(5) { animation-delay: .16s; }
.app > *:nth-child(n+6) { animation-delay: .2s; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }

/* ---------------------------------------------------- encabezados */
.section-h {
  display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
  margin: 26px 2px 12px;
}
.section-h h2 { margin: 0; font: 800 22px/1 var(--display); text-transform: uppercase; letter-spacing: .02em; }
.section-h a, .section-h .link { font-size: 13px; font-weight: 600; color: var(--accent-ink); }
h3.sub-h { margin: 18px 2px 10px; font: 700 15px/1 var(--display); text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }

/* --------------------------------------------------------- hero */
.hero {
  position: relative; overflow: hidden; isolation: isolate;
  border-radius: var(--r-lg); padding: 22px 20px;
  background: linear-gradient(160deg, var(--pitch-1) 0%, var(--pitch-2) 48%, var(--pitch-3) 100%);
  color: #fff; box-shadow: var(--shadow);
}
.hero::before { /* líneas de cancha */
  content: ""; position: absolute; inset: 0; z-index: -1; opacity: .07;
  background:
    radial-gradient(circle at 100% 50%, transparent 0 62px, #fff 63px 64px, transparent 65px),
    linear-gradient(90deg, transparent calc(100% - 1px), #fff calc(100% - 1px)),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, .5) 0 46px, transparent 46px 92px);
  background-size: 100% 100%, 100% 100%, 100% 100%;
  mask-image: linear-gradient(90deg, transparent, #000 60%);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 60%);
}
.hero::after { /* brillo */
  content: ""; position: absolute; z-index: -1; width: 340px; height: 340px; right: -120px; top: -160px;
  background: radial-gradient(circle, rgba(212, 175, 90, .35), transparent 65%);
}
.hero { border: 1px solid rgba(212, 175, 90, .18); }
.hero .eyebrow { font: 700 13px/1 var(--display); letter-spacing: .2em; text-transform: uppercase; color: #e3c27a; margin-bottom: 10px; }
.hero .eyebrow::before { content: ""; display: inline-block; width: 22px; height: 2px; margin-right: 10px; vertical-align: 4px; background: var(--gold-grad); }
.hero .hero-mark { position: absolute; z-index: -1; right: 16px; top: 16px; width: 64px; filter: drop-shadow(0 10px 20px rgba(0, 0, 0, .5)); }
.hero.has-mark h2 { font-size: clamp(30px, 9vw, 60px); margin-top: 26px; }
@media (min-width: 720px) {
  .hero .hero-mark { top: 50%; right: 34px; transform: translateY(-50%); width: 170px; }
  .hero.has-mark { padding: 34px 230px 30px 32px; }
  .hero.has-mark h2 { margin-top: 0; }
}
.hero .gold { background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero h2 { margin: 0; font: 800 clamp(34px, 9vw, 52px)/.92 var(--display); text-transform: uppercase; letter-spacing: .005em; }
.hero p { margin: 8px 0 0; color: rgba(255, 255, 255, .75); }
.hero .hero-stats { display: flex; flex-wrap: wrap; gap: 12px 22px; margin-top: 18px; }
.hero .hero-stats div b { display: block; font: 800 30px/1 var(--display); }
.hero .hero-stats div span { font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: rgba(255, 255, 255, .65); }

/* -------------------------------------------------------- tarjetas */
.card {
  position: relative; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r); padding: 16px; margin-bottom: 12px; box-shadow: var(--shadow);
}
.card.flat { box-shadow: none; background: var(--surface-2); }
.card-title {
  display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 0 0 14px;
  font: 800 18px/1 var(--display); text-transform: uppercase; letter-spacing: .03em;
}
.grid { display: grid; gap: 12px; }
@media (min-width: 640px) { .grid.cols-2 { grid-template-columns: 1fr 1fr; } .grid.cols-3 { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 960px) { .grid.lg-2 { grid-template-columns: 1fr 1fr; align-items: start; } }

/* --------------------------------------------------------- botones */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 0 18px; border-radius: 15px;
  border: 1px solid var(--line-strong); background: var(--surface-2); color: var(--text);
  font: 650 14.5px/1 var(--font); cursor: pointer; text-align: center; white-space: nowrap;
  transition: transform .12s, background .15s, box-shadow .15s, border-color .15s;
}
.btn:hover { background: var(--surface-3); }
.btn svg { width: 18px; height: 18px; }
.btn.primary {
  background: var(--gold-grad); color: var(--on-accent); border-color: transparent; font-weight: 750;
  box-shadow: 0 8px 22px -10px rgba(212, 175, 90, .7);
}
.btn.primary:hover { filter: brightness(1.05); }
.btn.danger { color: var(--danger); border-color: color-mix(in srgb, var(--danger) 40%, transparent); background: var(--danger-soft); }
.btn.ghost { border-color: transparent; background: transparent; color: var(--accent-ink); }
.btn.sm { min-height: 38px; padding: 0 13px; font-size: 13px; border-radius: 12px; }
.btn.block { width: 100%; }
.btn.lg { min-height: 56px; font-size: 16px; border-radius: 18px; }
.btn:disabled { opacity: .45; cursor: default; }
.btn:active:not(:disabled) { transform: scale(.97); }
.btn-row { display: flex; flex-wrap: wrap; gap: 8px; }
.btn-row > .btn { flex: 1 1 auto; }

/* acciones tipo "tile" (iconos grandes) */
.actions { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 8px; margin-bottom: 14px; }
.action {
  display: flex; flex-direction: column; align-items: flex-start; justify-content: space-between; gap: 14px;
  min-height: 92px; padding: 13px; border-radius: var(--r); cursor: pointer; text-align: left;
  background: var(--surface); border: 1px solid var(--line); color: var(--text); font-weight: 650; font-size: 13.5px; line-height: 1.2;
  transition: transform .12s, border-color .15s;
}
.action:hover { border-color: var(--line-strong); }
.action:active { transform: scale(.97); }
.action .ic { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 12px; background: var(--surface-3); color: var(--accent-ink); }
.action .ic svg { width: 20px; height: 20px; }
.action.primary { background: var(--gold-grad); color: var(--on-accent); border-color: transparent; }
.action.primary .ic { background: rgba(0, 0, 0, .12); color: var(--on-accent); }
@media (max-width: 719px) {
  .actions { display: flex; overflow-x: auto; scrollbar-width: none; margin: 0 -16px 14px; padding: 2px 16px; scroll-padding-inline: 16px; }
  .actions::-webkit-scrollbar { display: none; }
  .action { flex: 0 0 118px; min-height: 104px; scroll-snap-align: start; }
}

.fab {
  position: fixed; right: 18px; bottom: calc(var(--nav-h) + var(--safe-b) + 26px); z-index: 25;
  display: inline-flex; align-items: center; gap: 8px; height: 56px; padding: 0 22px 0 18px; border-radius: 20px; border: 0;
  background: var(--gold-grad); color: var(--on-accent); font-weight: 750; cursor: pointer;
  box-shadow: 0 14px 30px -8px rgba(212, 175, 90, .6), 0 4px 10px rgba(0, 0, 0, .3);
}
.fab:active { transform: scale(.96); }
@media (min-width: 960px) { .fab { bottom: 28px; right: 28px; } }

/* --------------------------------------------------------- formularios */
label.field { display: block; margin-bottom: 14px; }
label.field > span { display: block; font-size: 12px; font-weight: 650; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
input, select, textarea {
  width: 100%; min-height: 50px; padding: 12px 14px; border-radius: 14px;
  border: 1px solid var(--line-strong); background: var(--surface-2); color: var(--text);
  font: 500 16px/1.3 var(--font); transition: border-color .15s, box-shadow .15s, background .15s;
}
select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237d8a83' stroke-width='2.5' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; background-size: 18px; padding-right: 38px; }
textarea { min-height: 120px; resize: vertical; }
input::placeholder, textarea::placeholder { color: var(--muted); opacity: .8; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); background: var(--surface); }
input[type="checkbox"] {
  appearance: none; width: 24px; height: 24px; min-height: 0; padding: 0; flex: none; cursor: pointer;
  border-radius: 8px; border: 2px solid var(--line-strong); background: var(--surface-2); display: grid; place-items: center;
}
input[type="checkbox"]:checked { background: var(--accent); border-color: var(--accent); }
input[type="checkbox"]:checked::after {
  content: ""; width: 6px; height: 11px; border: solid var(--on-accent); border-width: 0 2.6px 2.6px 0; transform: translateY(-1px) rotate(45deg);
}
input[type="color"] { padding: 5px; height: 50px; cursor: pointer; }
input[type="date"], input[type="time"] { color-scheme: inherit; }
.check { display: flex; align-items: center; gap: 12px; min-height: 46px; cursor: pointer; font-weight: 500; }
details > summary { list-style: none; cursor: pointer; }
details > summary::-webkit-details-marker { display: none; }
details > summary::before { content: "+"; display: inline-grid; place-items: center; width: 20px; height: 20px; margin-right: 8px; border-radius: 6px; background: var(--surface-3); font-weight: 700; color: var(--accent-ink); }
details[open] > summary::before { content: "–"; }

/* --------------------------------------------------------- tabs & chips */
.tabs {
  position: sticky; top: calc(var(--top-h) + var(--safe-t)); z-index: 20;
  display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none;
  margin: 0 -16px 16px; padding: 10px 16px 0;
  background: linear-gradient(var(--bg) 70%, transparent);
  border-bottom: 1px solid var(--line);
}
.tabs::-webkit-scrollbar { display: none; }
.tabs a {
  position: relative; flex: none; padding: 10px 14px 14px;
  font: 700 15px/1 var(--display); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); white-space: nowrap;
  transition: color .2s;
}
.tabs a.active { color: var(--text); }
.tabs a.active::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: -1px; height: 3px; border-radius: 3px 3px 0 0; background: var(--accent); }
@media (min-width: 960px) { .tabs { margin: 0 0 18px; padding: 10px 0 0; } }

.chips { display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 6px; margin: 0 -2px 10px; scrollbar-width: none; scroll-snap-type: x proximity; }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none; scroll-snap-align: start; padding: 9px 15px; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--line-strong); background: var(--surface); color: var(--text-2);
  font: 700 14px/1 var(--display); letter-spacing: .05em; text-transform: uppercase; white-space: nowrap;
}
.chip.active { background: var(--text); color: var(--bg); border-color: transparent; }
.chip.done { color: var(--muted); }
.chip .dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); margin-left: 6px; vertical-align: 2px; }

.badge {
  display: inline-flex; align-items: center; gap: 4px; padding: 3px 9px; border-radius: 999px;
  font: 700 12px/1.3 var(--display); letter-spacing: .06em; text-transform: uppercase;
  background: var(--surface-3); color: var(--text-2);
}
.badge.ok { background: var(--ok-soft); color: var(--win); }
.badge.warn { background: var(--warn-soft); color: var(--warn); }
.badge.danger { background: var(--danger-soft); color: var(--danger); }
.badge.accent { background: var(--gold-grad); color: var(--on-accent); }
.cardy, .cardr { display: inline-block; width: 10px; height: 14px; border-radius: 2.5px; vertical-align: -2px; box-shadow: 0 1px 2px rgba(0, 0, 0, .3); }
.cardy { background: var(--yellow); }
.cardr { background: var(--red); }

.alert { padding: 12px 14px; border-radius: 14px; margin: 10px 0; font-size: 14px; border: 1px solid transparent; }
.alert.warn { background: var(--warn-soft); color: var(--warn); border-color: color-mix(in srgb, var(--warn) 25%, transparent); }
.alert.danger { background: var(--danger-soft); color: var(--danger); border-color: color-mix(in srgb, var(--danger) 25%, transparent); }
.alert.ok { background: var(--ok-soft); color: var(--win); border-color: color-mix(in srgb, var(--win) 25%, transparent); }
.alert ul { margin: 6px 0 0; padding-left: 18px; }
.alert li + li { margin-top: 3px; }

.empty { text-align: center; padding: 44px 20px; color: var(--muted); }
.empty .art { width: 120px; height: 120px; margin: 0 auto 14px; display: grid; place-items: center; border-radius: 36px; background: var(--surface); border: 1px solid var(--line); color: var(--accent-ink); }
.empty .art svg { width: 54px; height: 54px; stroke-width: 1.6; }
.empty h3 { margin: 0 0 6px; color: var(--text); font: 800 22px/1 var(--display); text-transform: uppercase; }
.empty p { margin: 0 auto 18px; max-width: 320px; }

/* --------------------------------------------------------- KPIs */
.kpis { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin: 14px 0; }
@media (min-width: 720px) { .kpis { grid-template-columns: repeat(4, 1fr); } }
.kpi {
  position: relative; overflow: hidden; padding: 14px 15px; border-radius: var(--r);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow);
}
.kpi .ic { position: absolute; right: 12px; top: 12px; color: var(--muted); opacity: .7; }
.kpi .ic svg { width: 20px; height: 20px; }
.kpi b { display: block; font: 800 40px/1 var(--display); letter-spacing: -.01em; }
.kpi span { font-size: 12px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.kpi.hot { background: linear-gradient(140deg, color-mix(in srgb, var(--danger) 22%, var(--surface)), var(--surface)); }
.kpi.hot b { color: var(--danger); }

/* --------------------------------------------------------- escudos */
.crest {
  position: relative; flex: none; display: grid; place-items: center;
  width: 36px; height: 36px; color: #fff;
  font: 800 13px/1 var(--display); letter-spacing: .02em;
}
.crest .shape {
  position: absolute; inset: 0;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 46'%3E%3Cpath d='M20 0 L39 6 C39 26 33 38 20 46 C7 38 1 26 1 6 Z'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 46'%3E%3Cpath d='M20 0 L39 6 C39 26 33 38 20 46 C7 38 1 26 1 6 Z'/%3E%3C/svg%3E") center / contain no-repeat;
}
.crest .ini { position: relative; margin-top: 12%; text-shadow: 0 1px 2px rgba(0, 0, 0, .3); }
.crest .shape::after { content: ""; position: absolute; inset: 0; background: linear-gradient(135deg, rgba(255, 255, 255, .28), transparent 45%, rgba(0, 0, 0, .22)); }
.crest.photo img { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 2px 4px rgba(0, 0, 0, .35)); }
.crest.sm { width: 26px; height: 26px; font-size: 10px; }
.crest.md { width: 48px; height: 48px; font-size: 17px; }
.crest.lg { width: 76px; height: 76px; font-size: 26px; }
.crest.xl { width: 104px; height: 104px; font-size: 36px; }

.avatar {
  flex: none; display: grid; place-items: center; overflow: hidden;
  width: 40px; height: 40px; border-radius: 13px;
  background: linear-gradient(145deg, var(--surface-3), var(--surface-2));
  color: var(--text-2); font: 800 15px/1 var(--display); border: 1px solid var(--line);
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar.lg { width: 72px; height: 72px; border-radius: 22px; font-size: 26px; }
.avatar.xl { width: 128px; height: 128px; border-radius: 36px; font-size: 44px; }

/* --------------------------------------------------------- listas */
.list { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); overflow: hidden; margin-bottom: 12px; }
.list-item {
  display: flex; align-items: center; gap: 13px; width: 100%; padding: 12px 15px; min-height: 62px;
  border: 0; border-bottom: 1px solid var(--line); background: none; color: var(--text); text-align: left; cursor: pointer;
  transition: background .15s;
}
.list-item:last-child { border-bottom: 0; }
a.list-item:hover, button.list-item:hover { background: var(--surface-2); }
.list-item .title { font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.list-item .sub { font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chev { color: var(--muted); width: 18px; height: 18px; }
.rank { width: 26px; text-align: center; font: 800 18px/1 var(--display); color: var(--muted); }

/* --------------------------------------------- tarjeta de partido */
.mc {
  display: grid; grid-template-columns: 58px 1fr auto; align-items: stretch;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r);
  margin-bottom: 8px; overflow: hidden; box-shadow: var(--shadow); transition: border-color .15s, transform .12s;
}
.mc:hover { border-color: var(--line-strong); }
.mc:active { transform: scale(.99); }
.mc .when {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  border-right: 1px solid var(--line); background: var(--surface-2); padding: 8px 4px;
}
.mc .when .d { font: 700 12px/1 var(--display); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.mc .when .n { font: 800 22px/1 var(--display); }
.mc .when .t { font-size: 11px; font-weight: 650; color: var(--text-2); }
.mc .body { padding: 10px 12px; min-width: 0; display: flex; flex-direction: column; justify-content: center; gap: 6px; }
.mc .tm { display: flex; align-items: center; gap: 10px; min-width: 0; }
.mc .tm .name { flex: 1; min-width: 0; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mc .tm .sc { font: 800 22px/1 var(--display); min-width: 18px; text-align: right; font-variant-numeric: tabular-nums; }
.mc .tm .sc small { font-size: 13px; color: var(--muted); margin-right: 4px; font-weight: 700; }
.mc.done .tm.lose { color: var(--muted); }
.mc.done .tm.lose .sc { color: var(--muted); }
.mc.done .tm.win .name { font-weight: 750; }
.mc .side {
  display: flex; flex-direction: column; align-items: flex-end; justify-content: center; gap: 6px;
  padding: 10px 12px 10px 0; text-align: right;
}
.mc .meta { font-size: 11.5px; color: var(--muted); white-space: nowrap; max-width: 110px; overflow: hidden; text-overflow: ellipsis; }
.status {
  display: inline-block; padding: 4px 8px; border-radius: 8px;
  font: 800 11.5px/1 var(--display); letter-spacing: .1em; text-transform: uppercase;
  background: var(--surface-3); color: var(--text-2);
}
.status.ft { background: var(--text); color: var(--bg); }
.status.next { background: var(--accent-soft); color: var(--accent-ink); }
.status.susp { background: var(--danger-soft); color: var(--danger); }
.status.late { background: var(--warn-soft); color: var(--warn); }

/* partido destacado (inicio) */
.feature {
  position: relative; overflow: hidden; isolation: isolate; display: block;
  border-radius: var(--r-lg); padding: 18px 16px 20px; color: #fff; box-shadow: var(--shadow-pop);
  background: #0b0f0d;
}
.feature .bg { position: absolute; inset: 0; z-index: -1; display: grid; grid-template-columns: 1fr 1fr; }
.feature .bg i { display: block; opacity: .9; }
.feature .bg i:first-child { clip-path: polygon(0 0, 100% 0, 82% 100%, 0 100%); }
.feature .bg i:last-child { clip-path: polygon(18% 0, 100% 0, 100% 100%, 0 100%); margin-left: -18%; }
.feature::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(0, 0, 0, .15), rgba(0, 0, 0, .55)), repeating-linear-gradient(115deg, rgba(255, 255, 255, .04) 0 2px, transparent 2px 14px); }
.feature .top { display: flex; justify-content: space-between; gap: 10px; font: 700 13px/1 var(--display); letter-spacing: .14em; text-transform: uppercase; opacity: .9; }
.feature .vs { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; margin-top: 18px; }
.feature .t { display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; font: 800 19px/1 var(--display); text-transform: uppercase; letter-spacing: .02em; text-shadow: 0 2px 8px rgba(0, 0, 0, .4); }
.feature .crest { filter: drop-shadow(0 6px 14px rgba(0, 0, 0, .45)); }
.feature .mid { text-align: center; }
.feature .mid b { display: block; font: 800 46px/1 var(--display); text-shadow: 0 4px 16px rgba(0, 0, 0, .5); }
.feature .mid span { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; opacity: .85; }
.feature .foot { margin-top: 16px; text-align: center; font-size: 13px; opacity: .85; }

/* ----------------------------------------------- marcador (partido) */
.scoreboard { padding: 18px 14px 20px; }
.scoreboard .crumbs { text-align: center; font: 700 13px/1 var(--display); letter-spacing: .14em; text-transform: uppercase; opacity: .85; }
.scoreboard .vs { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 8px; margin-top: 20px; }
.scoreboard .t { display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; font: 800 20px/1 var(--display); text-transform: uppercase; }
.scoreboard .big { font: 800 64px/.9 var(--display); letter-spacing: -.01em; text-shadow: 0 6px 24px rgba(0, 0, 0, .5); white-space: nowrap; }
.scoreboard .big i { font-style: normal; opacity: .5; margin: 0 4px; }
.scoreboard .scorers { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 16px; font-size: 12.5px; line-height: 1.6; opacity: .9; }
.scoreboard .scorers div:last-child { text-align: right; }
.scoreboard .info { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 14px; margin-top: 18px; padding-top: 14px; border-top: 1px solid rgba(255, 255, 255, .15); font-size: 13px; opacity: .9; }
.scoreboard .info span { display: inline-flex; align-items: center; gap: 6px; }
.scoreboard .info svg { width: 15px; height: 15px; opacity: .8; }

.lineups { display: grid; gap: 12px; }
@media (min-width: 720px) { .lineups { grid-template-columns: 1fr 1fr; } }
.lu-item { display: flex; align-items: center; gap: 11px; padding: 9px 14px; border-bottom: 1px solid var(--line); }
.lu-item:last-child { border-bottom: 0; }
.lu-item .n { width: 24px; font: 800 17px/1 var(--display); color: var(--muted); text-align: center; }
.lu-item .ev { display: flex; align-items: center; gap: 5px; font-size: 13px; }
.lu-head { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-bottom: 1px solid var(--line); font: 800 16px/1 var(--display); text-transform: uppercase; letter-spacing: .04em; }

/* ------------------------------------------------- tabla de posiciones */
.table-wrap { overflow-x: auto; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); margin-bottom: 12px; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { padding: 10px 6px; text-align: center; border-bottom: 1px solid var(--line); white-space: nowrap; font-variant-numeric: tabular-nums; }
th { font: 700 12px/1 var(--display); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); padding-top: 13px; padding-bottom: 11px; }
td.l, th.l { text-align: left; }
tr:last-child td { border-bottom: 0; }
tbody tr { transition: background .15s; }
tbody tr:hover { background: var(--surface-2); }
td.pts { font: 800 19px/1 var(--display); color: var(--text); padding-right: 14px; }
td.pts sup.adj { color: var(--danger); font-size: 13px; margin-left: 1px; cursor: help; }
td .row { gap: 10px; }
td.team-cell { max-width: 46vw; overflow: hidden; text-overflow: ellipsis; font-weight: 600; }
td.team-cell a { display: flex; align-items: center; gap: 10px; min-width: 0; }
td.team-cell span { overflow: hidden; text-overflow: ellipsis; }
.pos { position: relative; display: inline-grid; place-items: center; width: 26px; font: 800 16px/1 var(--display); color: var(--muted); }
tr.q td:first-child { box-shadow: inset 3px 0 0 var(--accent); }
tr.q .pos { color: var(--accent-ink); }
.form { display: inline-flex; gap: 3px; }
.form i { display: inline-grid; place-items: center; width: 19px; height: 19px; border-radius: 6px; color: #fff; font: 800 11px/1 var(--display); font-style: normal; }
.form .G { background: var(--win); } .form .E { background: var(--draw); } .form .P { background: var(--loss); }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 12px; color: var(--muted); margin: 4px 2px 14px; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; background: var(--accent); margin-right: 6px; vertical-align: -1px; }
@media (max-width: 520px) { .hide-sm { display: none; } }

/* --------------------------------------------------------- podio */
.podium { display: grid; grid-template-columns: 1fr 1.15fr 1fr; align-items: end; gap: 8px; margin: 6px 0 16px; }
.podium .p {
  position: relative; display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center;
  padding: 16px 8px 14px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow);
}
.podium .p.first { padding-top: 22px; background: linear-gradient(180deg, color-mix(in srgb, var(--gold) 20%, var(--surface)), var(--surface) 70%); border-color: color-mix(in srgb, var(--gold) 40%, transparent); }
.podium .medal { position: absolute; top: -12px; display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; font: 800 14px/1 var(--display); color: #1a1405; }
.podium .p:nth-child(1) .medal { background: var(--silver); }
.podium .p:nth-child(2) .medal { background: var(--gold); }
.podium .p:nth-child(3) .medal { background: var(--bronze); }
.podium .avatar { width: 62px; height: 62px; border-radius: 20px; font-size: 22px; }
.podium .first .avatar { width: 78px; height: 78px; border-radius: 24px; }
.podium .nm { font-weight: 700; font-size: 13.5px; line-height: 1.15; }
.podium .tm { font-size: 11.5px; color: var(--muted); }
.podium .g { font: 800 34px/1 var(--display); }
.podium .first .g { font-size: 44px; background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.podium .g small { font-size: 12px; letter-spacing: .1em; color: var(--muted); margin-left: 3px; }

/* --------------------------------------------------------- llave */
.bracket { display: flex; gap: 22px; overflow-x: auto; padding: 4px 2px 12px; scroll-snap-type: x mandatory; }
.bracket .col { flex: 0 0 min(76vw, 250px); display: flex; flex-direction: column; justify-content: space-around; gap: 14px; scroll-snap-align: start; }
.bracket .col h3 { margin: 0 0 2px; text-align: center; font: 800 15px/1 var(--display); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.bracket .bm { position: relative; display: block; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); }
.bracket .col:not(:last-child) .bm::after { content: ""; position: absolute; right: -23px; top: 50%; width: 22px; height: 2px; background: var(--line-strong); }
.bracket .bm .r { display: flex; align-items: center; gap: 9px; padding: 9px 11px; }
.bracket .bm .r + .r { border-top: 1px solid var(--line); }
.bracket .bm .r .name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; font-size: 14px; }
.bracket .bm .r .s { font: 800 18px/1 var(--display); }
.bracket .bm .r.w .name, .bracket .bm .r.w .s { color: var(--accent-ink); }
.bracket .bm .r.l { opacity: .55; }
.bracket .bm .when { padding: 6px 11px; border-top: 1px solid var(--line); font-size: 11.5px; color: var(--muted); }
.champion {
  position: relative; overflow: hidden; display: flex; align-items: center; gap: 16px; margin-bottom: 16px; padding: 18px 20px;
  border-radius: var(--r-lg); color: #241900;
  background: linear-gradient(120deg, #ffe58a, #ffc93c 45%, #f5a623);
  box-shadow: 0 18px 40px -16px rgba(245, 166, 35, .6);
}
.champion::after { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(115deg, rgba(255, 255, 255, .18) 0 2px, transparent 2px 16px); }
.champion .lbl { font: 800 13px/1 var(--display); letter-spacing: .2em; text-transform: uppercase; opacity: .75; }
.champion .nm { font: 800 32px/1 var(--display); text-transform: uppercase; }
.champion .trophy { font-size: 40px; line-height: 1; }

/* ----------------------------------------------------- hero de equipo */
.team-hero {
  position: relative; overflow: hidden; isolation: isolate; border-radius: var(--r-lg);
  padding: 22px 18px 18px; color: #fff; box-shadow: var(--shadow-pop); margin-bottom: 4px;
}
.team-hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--tc1); }
.team-hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(115deg, transparent 52%, var(--tc2) 52% 58%, transparent 58% 63%, var(--tc2) 63% 65%, transparent 65%),
    linear-gradient(180deg, rgba(0, 0, 0, .05), rgba(0, 0, 0, .6));
  opacity: .9;
}
.team-hero .in { display: flex; align-items: center; gap: 16px; }
.team-hero h2 { margin: 0; font: 800 clamp(30px, 8vw, 44px)/.92 var(--display); text-transform: uppercase; text-shadow: 0 2px 12px rgba(0, 0, 0, .35); }
.team-hero .meta { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.team-hero .pill { padding: 5px 10px; border-radius: 999px; background: rgba(0, 0, 0, .3); backdrop-filter: blur(6px); font-size: 12px; font-weight: 600; }
.team-hero .pill a { text-decoration: underline; text-underline-offset: 2px; }
.team-hero .crest { filter: drop-shadow(0 8px 18px rgba(0, 0, 0, .45)); }
.photo-edit { position: relative; display: inline-block; flex: none; }
.photo-edit .icon-btn { position: absolute; right: -8px; bottom: -6px; width: 36px; height: 36px; border-radius: 12px; background: var(--accent); color: var(--on-accent); box-shadow: 0 4px 12px rgba(0, 0, 0, .4); }
.photo-edit .icon-btn svg { width: 18px; height: 18px; }

/* --------------------------------------------- figuritas de jugadores */
.cards-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
@media (max-width: 360px) { .cards-grid { grid-template-columns: 1fr 1fr; gap: 8px; } }
.pcard {
  position: relative; overflow: hidden; isolation: isolate; display: flex; flex-direction: column; align-items: center;
  aspect-ratio: 3 / 4; padding: 14px 10px 12px; border-radius: 20px; color: #fff;
  background: linear-gradient(160deg, var(--tc1) 0%, color-mix(in srgb, var(--tc1) 45%, #000) 100%);
  box-shadow: 0 12px 28px -14px rgba(0, 0, 0, .8), inset 0 0 0 1px rgba(255, 255, 255, .12);
  transition: transform .2s;
}
.pcard:hover { transform: translateY(-3px); }
.pcard:active { transform: scale(.98); }
.pcard::before { /* franja diagonal */
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(120deg, transparent 58%, color-mix(in srgb, var(--tc2) 55%, transparent) 58% 62%, transparent 62%),
              radial-gradient(90% 60% at 50% 0%, rgba(255, 255, 255, .22), transparent 70%);
}
.pcard .bignum { position: absolute; z-index: -1; right: -6px; top: -14px; font: 800 120px/1 var(--display); color: rgba(255, 255, 255, .13); letter-spacing: -.04em; }
.pcard .num { position: absolute; left: 12px; top: 10px; font: 800 26px/1 var(--display); text-shadow: 0 2px 6px rgba(0, 0, 0, .35); }
.pcard .pos { position: absolute; left: 12px; top: 38px; font: 700 11px/1 var(--display); letter-spacing: .1em; width: auto; color: rgba(255, 255, 255, .85); }
.pcard .ph {
  width: 64%; aspect-ratio: 1; margin-top: 16px; border-radius: 50%; overflow: hidden; display: grid; place-items: center;
  background: rgba(0, 0, 0, .25); border: 3px solid rgba(255, 255, 255, .85); box-shadow: 0 8px 20px rgba(0, 0, 0, .35);
  font: 800 30px/1 var(--display);
}
.pcard .ph img { width: 100%; height: 100%; object-fit: cover; }
.pcard .nm { margin-top: auto; text-align: center; line-height: 1; width: 100%; }
.pcard .nm b { display: block; font: 800 21px/1 var(--display); text-transform: uppercase; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-shadow: 0 2px 6px rgba(0, 0, 0, .35); }
.pcard .nm span { font-size: 12px; opacity: .85; }
.pcard .flag { position: absolute; right: 10px; top: 10px; }
.pcard.light { color: #111; }
.pcard.light .num, .pcard.light .nm b { text-shadow: none; }
.pcard.light .bignum { color: rgba(0, 0, 0, .08); }
.pcard.light .pos { color: rgba(0, 0, 0, .65); }

/* tarjetas de equipo */
.pcard.team { aspect-ratio: auto; min-height: 196px; justify-content: center; gap: 14px; padding: 22px 12px 16px; }
.pcard.team .crest { filter: drop-shadow(0 8px 16px rgba(0, 0, 0, .4)); }
.pcard.team .nm { margin-top: 0; }
.pcard.team .nm b { white-space: normal; font-size: 21px; line-height: 1; margin-bottom: 4px; }

/* ------------------------------------------------- ficha de jugador */
.player-hero { text-align: center; padding: 26px 18px 20px; }
.player-hero .ph {
  width: 136px; height: 136px; margin: 0 auto; border-radius: 50%; overflow: hidden; display: grid; place-items: center;
  border: 4px solid rgba(255, 255, 255, .9); box-shadow: 0 14px 34px rgba(0, 0, 0, .45); background: rgba(0, 0, 0, .25);
  font: 800 48px/1 var(--display);
}
.player-hero .ph img { width: 100%; height: 100%; object-fit: cover; }
.player-hero h2 { margin: 16px 0 4px; font: 800 36px/.95 var(--display); text-transform: uppercase; }
.player-hero h2 small { display: block; font-size: 18px; font-weight: 600; opacity: .8; letter-spacing: .04em; }
.player-hero .meta { display: flex; justify-content: center; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.player-hero .photo-edit .icon-btn { right: 2px; bottom: 2px; }

dl.data { display: grid; grid-template-columns: auto 1fr; gap: 0; margin: 0; }
dl.data dt, dl.data dd { padding: 11px 0; border-bottom: 1px solid var(--line); }
dl.data dt { color: var(--muted); font-size: 12px; font-weight: 650; letter-spacing: .06em; text-transform: uppercase; padding-right: 16px; }
dl.data dd { margin: 0; font-weight: 550; word-break: break-word; text-align: right; }
dl.data dt:nth-last-of-type(1), dl.data dd:last-of-type { border-bottom: 0; }

/* ------------------------------------------- carga desde el celular */
.live {
  position: relative;
  border-radius: var(--r-lg); padding: 14px; margin-bottom: 14px;
  background: linear-gradient(160deg, var(--pitch-1), var(--pitch-3)); color: #fff; box-shadow: var(--shadow-pop);
}
.live .seg { display: inline-flex; padding: 3px; border-radius: 12px; background: rgba(0, 0, 0, .3); margin-bottom: 12px; }
.live .seg button { border: 0; background: none; color: rgba(255, 255, 255, .7); padding: 7px 14px; border-radius: 10px; font: 700 13px/1 var(--display); letter-spacing: .1em; text-transform: uppercase; cursor: pointer; }
.live .seg button.on { background: #fff; color: #0a120d; }
.live .sb { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; }
.live .sb .t { display: flex; flex-direction: column; align-items: center; gap: 6px; font: 800 14px/1.05 var(--display); text-transform: uppercase; text-align: center; }
.live .sb .score { display: flex; align-items: center; gap: 6px; }
.live .sb input {
  width: 62px; height: 66px; padding: 0; text-align: center; border-radius: 16px;
  font: 800 44px/1 var(--display); background: rgba(0, 0, 0, .35); color: #fff; border: 1px solid rgba(255, 255, 255, .2);
}
.live .sb input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(212, 175, 90, .3); }
.live .hint { text-align: center; font-size: 12px; opacity: .75; margin-top: 10px; }
.live .hint a { color: var(--accent); font-weight: 700; }
.live .pens { display: flex; justify-content: center; align-items: center; gap: 8px; margin-top: 10px; font-size: 13px; }
.live .pens input { width: 52px; height: 42px; font-size: 22px; border-radius: 12px; }

.side-switch { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 5px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); margin-bottom: 10px; }
.side-switch button {
  display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; border: 0; border-radius: 14px; cursor: pointer;
  background: none; color: var(--muted); font-weight: 650; font-size: 14px; min-width: 0;
}
.side-switch button span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side-switch button.on { background: var(--surface-3); color: var(--text); }
.side-switch .cnt { flex: none; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 8px; background: var(--accent); color: var(--on-accent); font: 800 13px/22px var(--display); }

.prow { border-bottom: 1px solid var(--line); transition: background .2s; }
.prow:last-child { border-bottom: 0; }
.prow .top { display: flex; align-items: center; gap: 12px; padding: 11px 14px; cursor: pointer; }
.prow .n { width: 26px; font: 800 20px/1 var(--display); color: var(--muted); text-align: center; }
.prow .nm { flex: 1; min-width: 0; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.prow.off .nm, .prow.off .avatar { opacity: .5; }
.prow.on { background: color-mix(in srgb, var(--accent) 5%, transparent); }
.prow .tags { display: flex; gap: 4px; align-items: center; }
.prow .ctrls { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; padding: 0 12px 14px; }
@media (min-width: 560px) { .prow .ctrls { grid-template-columns: repeat(4, minmax(0, 1fr)); padding-left: 52px; } }
.prow.off .ctrls { display: none; }
.stepper {
  display: flex; align-items: center; justify-content: space-between; gap: 4px; padding: 4px; border-radius: 14px;
  background: var(--surface-2); border: 1px solid var(--line);
}
.stepper { min-width: 0; }
.stepper .lb { display: flex; align-items: center; gap: 5px; min-width: 0; padding-left: 6px; font-size: 12px; font-weight: 650; color: var(--text-2); white-space: nowrap; overflow: hidden; }
.stepper .lb .ico { font-size: 15px; }
@media (max-width: 420px) { .stepper .lb .t { display: none; } .stepper .lb { padding-left: 10px; } }
.stepper .v { display: flex; align-items: center; gap: 2px; }
.stepper button { width: 32px; height: 34px; flex: none; border-radius: 10px; border: 0; background: var(--surface-3); color: var(--text); font-size: 20px; font-weight: 600; line-height: 1; cursor: pointer; }
.stepper button:active { transform: scale(.9); background: var(--accent); color: var(--on-accent); }
.stepper b { min-width: 22px; text-align: center; font: 800 20px/1 var(--display); }
.stepper.has b { color: var(--accent-ink); }
.redbtn {
  display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; border-radius: 14px; cursor: pointer;
  background: var(--surface-2); border: 1px solid var(--line); font-size: 13px; font-weight: 650; color: var(--text-2);
}
.redbtn.on { background: var(--danger-soft); border-color: color-mix(in srgb, var(--danger) 50%, transparent); color: var(--danger); }
.redbtn input { display: none; }

/* --------------------------------------------------------- modales */
.modal-backdrop {
  position: fixed; inset: 0; z-index: 60; background: rgba(0, 0, 0, .6);
  backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
  display: flex; align-items: flex-end; justify-content: center; animation: fade .2s;
}
.modal {
  width: 100%; max-height: 92vh; overflow-y: auto; overscroll-behavior: contain;
  background: var(--surface); border: 1px solid var(--line-strong); border-bottom: 0;
  border-radius: 28px 28px 0 0; padding: 10px 18px calc(18px + var(--safe-b));
  animation: up .32s cubic-bezier(.2, .9, .25, 1); box-shadow: var(--shadow-pop);
}
.modal::before { content: ""; display: block; width: 42px; height: 5px; border-radius: 5px; background: var(--line-strong); margin: 0 auto 14px; }
.modal h2 { margin: 2px 0 16px; font: 800 28px/1 var(--display); text-transform: uppercase; letter-spacing: .01em; }
.modal-actions { position: sticky; bottom: calc(-18px - var(--safe-b)); display: flex; gap: 8px; margin: 18px -18px calc(-18px - var(--safe-b)); padding: 12px 18px calc(18px + var(--safe-b)); background: linear-gradient(transparent, var(--surface) 22%); }
.modal-actions .btn { flex: 1; }
@media (min-width: 720px) {
  .modal-backdrop { align-items: center; }
  .modal { max-width: 580px; border-radius: 28px; border-bottom: 1px solid var(--line-strong); padding: 24px 26px 24px; }
  .modal::before { display: none; }
  .modal-actions { bottom: -24px; margin: 20px -26px -24px; padding: 14px 26px 24px; }
}
@keyframes up { from { transform: translateY(60px); opacity: 0; } }
@keyframes fade { from { opacity: 0; } }

.toast {
  position: fixed; left: 50%; bottom: calc(var(--nav-h) + var(--safe-b) + 26px); z-index: 80;
  transform: translate(-50%, 16px) scale(.96); opacity: 0; pointer-events: none;
  display: flex; align-items: center; gap: 10px; max-width: calc(100% - 32px); padding: 13px 18px; border-radius: 16px;
  background: var(--text); color: var(--bg); font-weight: 650; font-size: 14px; transition: .25s cubic-bezier(.2, .9, .25, 1);
  box-shadow: var(--shadow-pop);
}
.toast::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--win); flex: none; }
.toast.show { opacity: 1; transform: translate(-50%, 0) scale(1); }
.toast.error { background: var(--danger); color: #fff; }
.toast.error::before { background: #fff; }
@media (min-width: 960px) { .toast { bottom: 32px; } }

.dropzone {
  position: relative; overflow: hidden; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
  padding: 34px 20px; border-radius: var(--r-lg); text-align: center; cursor: pointer; color: var(--text-2);
  background: var(--surface); border: 2px dashed var(--line-strong); transition: border-color .2s, background .2s;
}
.dropzone:hover, .dropzone.drag { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 6%, var(--surface)); }
.dropzone .ic { display: grid; place-items: center; width: 70px; height: 70px; border-radius: 22px; background: var(--gold-grad); color: var(--on-accent); box-shadow: 0 12px 28px -10px rgba(212, 175, 90, .7); }
.dropzone .ic svg { width: 32px; height: 32px; stroke-width: 2.4; }
.dropzone b { color: var(--text); font: 800 22px/1.05 var(--display); text-transform: uppercase; }

.steps { counter-reset: s; list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.steps li { counter-increment: s; display: grid; grid-template-columns: 30px 1fr; gap: 12px; align-items: start; font-size: 14px; color: var(--text-2); }
.steps li::before { content: counter(s); display: grid; place-items: center; width: 30px; height: 30px; border-radius: 10px; background: var(--surface-3); color: var(--accent-ink); font: 800 16px/1 var(--display); }

.spinner { width: 34px; height: 34px; border: 3px solid var(--line-strong); border-top-color: var(--accent); border-radius: 50%; animation: spin .7s linear infinite; margin: 60px auto; }
@keyframes spin { to { transform: rotate(360deg); } }

.login-wrap { min-height: calc(100vh - 220px); display: grid; place-items: center; }
.login { width: 100%; max-width: 400px; }
.login .hero { text-align: center; padding: 30px 20px; margin-bottom: 14px; }
.login .hero img { width: min(250px, 72%); height: auto; margin: 0 auto 6px; filter: drop-shadow(0 14px 30px rgba(0, 0, 0, .45)); }

.theme-switch { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; padding: 5px; border-radius: 16px; background: var(--surface-2); }
.theme-switch button { min-height: 40px; border: 0; border-radius: 12px; background: none; color: var(--muted); font-weight: 650; cursor: pointer; }
.theme-switch button.on { background: var(--surface); color: var(--text); box-shadow: var(--shadow); }

/* los diseños SVG (credenciales, planillas) no heredan el estilo de los íconos */
.cred-stage svg, .mosaic svg, #printRoot svg, .modal .pl-preview svg { fill: initial; stroke: none; stroke-width: 1; width: auto; height: auto; }
.cred-stage svg, .mosaic svg, #printRoot .slot svg { width: 100%; height: 100%; }

/* --------------------------------------------- planilla imprimible A4 */
.psheet { page: planilla; position: relative; width: 210mm; height: 297mm; padding: 9mm 10mm 8mm; box-sizing: border-box; background: #fff; color: #0E1A33;
  font: 8.5pt/1.3 Inter, system-ui, sans-serif; overflow: hidden; break-after: page; display: flex; flex-direction: column; gap: 3mm;
  -webkit-print-color-adjust: exact; print-color-adjust: exact; }
.psheet > * { position: relative; z-index: 1; }
#printRoot .psheet .pl-pitch, .psheet .pl-pitch { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .05; z-index: 0; }
.psheet b, .psheet .bc { font-family: "Barlow Condensed", "Arial Narrow", sans-serif; font-weight: 800; letter-spacing: .01em; }
.pl-head { display: grid; grid-template-columns: 13mm 1fr auto 24mm; align-items: center; gap: 4mm; padding: 3mm 4mm; border-radius: 4mm;
  background: linear-gradient(120deg, #16264A, #0E1A33 55%, #070B14); color: #fff; border-bottom: 1.2mm solid #D4AF5A; }
.pl-head img { width: 12mm; height: auto; }
.pl-head .brand small { display: block; font: 700 6.5pt/1 "Barlow Condensed", sans-serif; letter-spacing: .4em; color: #D4AF5A; }
.pl-head .brand b { display: block; font-size: 15pt; line-height: 1.05; }
.pl-head .brand span { display: block; font-size: 7.5pt; color: #C5CCD8; margin-top: .6mm; }
.pl-head .ttl { text-align: right; line-height: 1; }
.pl-head .ttl b { display: block; font-size: 21pt; color: #E3C27A; }
.pl-head .ttl small { display: block; font: 700 7pt "Barlow Condensed", sans-serif; letter-spacing: .25em; color: #C5CCD8; }
.pl-head .ttl span { display: inline-block; margin-top: 1.2mm; padding: .4mm 2mm; border-radius: 1mm; background: rgba(255, 255, 255, .12); font-size: 6.5pt; }
.pl-head .qr { background: #fff; border-radius: 2mm; padding: 1mm 1mm .6mm; text-align: center; }
.pl-head .qr svg { display: block; width: 100% !important; height: auto; }
.pl-head .qr small { display: block; color: #0E1A33; font: 700 5.6pt "Barlow Condensed", sans-serif; letter-spacing: .08em; text-transform: uppercase; }
.pl-match { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 4mm; padding: 1mm 0; }
.pl-match .side { display: flex; flex-direction: column; align-items: center; gap: 1.4mm; text-align: center; }
.pl-match .side b { font-size: 15pt; line-height: 1; }
.pl-match .side small, .pl-match .pens small { font: 700 6.5pt "Barlow Condensed", sans-serif; letter-spacing: .25em; color: #7D8AA5; }
.pl-match .boxes { display: flex; align-items: center; gap: 3mm; }
.pl-match .boxes i { width: 19mm; height: 19mm; border: .7mm solid #0E1A33; border-radius: 3mm; box-shadow: inset 0 0 0 .8mm #F6EBCF; }
.pl-match .boxes span, .pl-match .pens span { font: 800 18pt "Barlow Condensed", sans-serif; color: #A87F2C; }
.pl-match .pens { display: flex; align-items: center; justify-content: center; gap: 2mm; margin-top: 1.5mm; }
.pl-match .pens i { width: 8mm; height: 7mm; border: .4mm solid #0E1A33; border-radius: 1.5mm; }
.pl-crest { display: block; }
.pl-info { display: grid; grid-template-columns: 1fr 1fr 1.6fr 1.6fr 2fr; gap: 2mm; }
.pl-info > div { border: .3mm solid #D5DAE3; border-radius: 2mm; padding: 1.2mm 2.5mm; background: rgba(255, 255, 255, .85); }
.pl-info small { display: block; font: 700 6pt "Barlow Condensed", sans-serif; letter-spacing: .18em; text-transform: uppercase; color: #A87F2C; }
.pl-info span { display: flex; align-items: center; gap: 1.2mm; min-height: 4.6mm; font-size: 8.5pt; font-weight: 600; }
.pl-legend { display: flex; justify-content: center; flex-wrap: wrap; gap: 2mm 6mm; font-size: 6.8pt; color: #5B6785; }
.pl-legend span { display: inline-flex; align-items: center; gap: 1.2mm; }
.pl-teams { flex: 1; display: grid; grid-template-columns: 1fr 1fr; gap: 4mm; align-items: start; }
.pl-team { border: .3mm solid #D5DAE3; border-radius: 2.5mm; overflow: hidden; background: rgba(255, 255, 255, .92); }
.pl-team header { display: flex; align-items: center; gap: 2.5mm; padding: 1.6mm 3mm; background: var(--tc); color: var(--ti); }
.pl-team header small { display: block; font: 700 5.8pt "Barlow Condensed", sans-serif; letter-spacing: .3em; opacity: .85; }
.pl-team header b { display: block; font-size: 11pt; line-height: 1; }
.pl-team table { width: 100%; border-collapse: collapse; font-size: 7.4pt; }
.pl-team th { background: #0E1A33; color: #fff; font: 700 6.2pt "Barlow Condensed", sans-serif; letter-spacing: .12em; text-transform: uppercase; padding: 1.1mm .8mm; text-align: center; }
.pl-team th.nm { text-align: left; padding-left: 1.5mm; }
.pl-team td { height: var(--rh, 5.5mm); padding: 0 .8mm; border-bottom: .25mm solid #E3E7EE; text-align: center; white-space: nowrap; }
.pl-team tbody tr:nth-child(even) td { background: #F6F8FB; }
.pl-team td.n { width: 6mm; font: 800 9pt "Barlow Condensed", sans-serif; }
.pl-team td.nm { text-align: left; padding-left: 1.5mm; max-width: 40mm; overflow: hidden; text-overflow: ellipsis; }
.pl-team td.nm b { font-family: Inter, sans-serif; font-weight: 700; font-size: 7.2pt; letter-spacing: 0; }
.pl-team td.nm small { margin-left: 1mm; font-size: 5.4pt; color: #7D8AA5; font-weight: 700; }
.pl-team .ck { width: 8mm; } .pl-team .gl { width: 19mm; } .pl-team .cd { width: 15mm; }
.pl-team td.gl, .pl-team td.cd { letter-spacing: 0; }
.psheet i.box { display: inline-block; width: 3.3mm; height: 3.3mm; border: .3mm solid #0E1A33; border-radius: .6mm; vertical-align: middle; }
.psheet i.o { display: inline-block; width: 3.1mm; height: 3.1mm; margin: 0 .25mm; border: .3mm solid #0E1A33; border-radius: 50%; vertical-align: middle; }
.psheet i.ycard, .psheet i.rcard { display: inline-block; width: 2.6mm; height: 3.6mm; margin: 0 .3mm; border-radius: .4mm; vertical-align: middle; }
.psheet i.ycard { border: .3mm solid #C99A00; background: #FFF3C4; }
.psheet i.rcard { border: .3mm solid #C62839; background: #FDE3E6; }
.psheet i.sq { display: inline-block; width: 8mm; height: 4.4mm; border: .35mm solid #0E1A33; border-radius: .8mm; vertical-align: middle; }
.psheet i.sq.sm { width: 5mm; }
.pl-team tr.susp td { background: #FDECEE !important; }
.pl-team tr.susp td.nm b { text-decoration: line-through; color: #C62839; }
.pl-team .tag { display: inline-block; margin-left: 1mm; padding: .2mm 1mm; border-radius: .8mm; font: 800 5.4pt "Barlow Condensed", sans-serif; letter-spacing: .08em; vertical-align: middle; }
.pl-team .tag.red { background: #C62839; color: #fff; } .pl-team .tag.warn { background: #FFE6A8; color: #7A5200; }
.pl-team tr.blank .ph { color: #B5BCC9; font-style: italic; font-size: 6.4pt; }
.pl-team tfoot td { background: #F6EBCF; font: 700 6.6pt "Barlow Condensed", sans-serif; letter-spacing: .12em; text-transform: uppercase; height: 6.5mm; border: 0; }
.pl-team tfoot td:first-child { text-align: right; padding-right: 2mm; }
.pl-obs { border: .3mm solid #D5DAE3; border-radius: 2mm; padding: 1.5mm 3mm 2mm; background: rgba(255, 255, 255, .9); }
.pl-obs small, .pl-sign small { font: 700 6pt "Barlow Condensed", sans-serif; letter-spacing: .18em; text-transform: uppercase; color: #A87F2C; }
.pl-obs .lines i { display: block; height: 5mm; border-bottom: .25mm dashed #C5CCD8; }
.pl-rate { display: flex; align-items: center; gap: 6mm; margin-top: 2mm; font-size: 7.5pt; color: #0E1A33; }
.pl-rate b { display: inline-block; width: 9mm; height: 6mm; margin-left: 2mm; vertical-align: middle; border: .3mm solid #0E1A33; border-radius: 1mm; }
.pl-sign { display: grid; grid-template-columns: repeat(3, 1fr); gap: 7mm; padding: 0 2mm; }
.pl-sign div { text-align: center; }
.pl-sign i { display: block; height: 9mm; border-bottom: .3mm solid #0E1A33; }
.pl-sign small { display: block; margin-top: .8mm; color: #0E1A33; }
.pl-sign small.ac { color: #9AA3B5; letter-spacing: .1em; margin-top: 2.4mm; border-top: .2mm dotted #C5CCD8; padding-top: .6mm; }
.pl-foot { display: flex; justify-content: space-between; padding-top: 1.4mm; border-top: .35mm solid #D4AF5A; font-size: 6pt; color: #7D8AA5; }
@page planilla { size: A4 portrait; margin: 0; }
body.show-print #printRoot { display: flex !important; flex-direction: column; gap: 10mm; align-items: center; position: fixed; inset: 0; z-index: 9999; overflow: auto; background: #555; padding: 10mm; }

/* --------------------------------------------- editor de credenciales */
.cred-layout { display: grid; gap: 16px; margin-top: 16px; }
@media (min-width: 1040px) { .cred-layout { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); align-items: start; } .cred-preview { position: sticky; top: calc(var(--top-h) + 20px); } }
.cred-stage { aspect-ratio: 856 / 540; width: 100%; max-width: 640px; margin: 0 auto; filter: drop-shadow(0 24px 40px rgba(0, 0, 0, .55)); }
.cred-stage svg { display: block; width: 100%; height: 100%; }
.mosaic-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 10px; }
.mosaic { display: flex; flex-direction: column; gap: 6px; padding: 6px; border-radius: 14px; border: 2px solid transparent; background: var(--surface-2); cursor: pointer; color: var(--text-2); }
.mosaic .thumb { display: block; aspect-ratio: 856 / 540; border-radius: 9px; overflow: hidden; }
.mosaic .thumb svg { display: block; width: 100%; height: 100%; }
.mosaic .lbl { font: 700 13px/1 var(--display); letter-spacing: .08em; text-transform: uppercase; text-align: center; padding-bottom: 2px; }
.mosaic.on { border-color: var(--accent); color: var(--text); box-shadow: 0 0 0 4px var(--accent-soft); }
#printRoot { display: none; }

/* =====================================================================
   CAPA 2026 — aurora, vidrio y bento
   Fondo con luces de estadio que se mueven lento, superficies de vidrio
   esmerilado, bordes con brillo y tipografía display enorme.
   ===================================================================== */
:root {
  --bg: #04060c;
  --surface: rgba(16, 22, 38, .66);
  --surface-2: rgba(26, 34, 56, .6);
  --surface-3: rgba(42, 52, 80, .6);
  --solid: #0c1220;
  --line: rgba(255, 255, 255, .07);
  --line-strong: rgba(255, 255, 255, .14);
  --blue: #4f7dff;
  --violet: #9a6bff;
  --glow-gold: rgba(232, 190, 96, .55);
  --r: 22px;
  --r-lg: 30px;
  --shadow: inset 0 1px 0 rgba(255, 255, 255, .06), 0 18px 40px -22px rgba(0, 0, 0, .9);
  --glass: rgba(8, 12, 22, .55);
  --ease: cubic-bezier(.2, .8, .2, 1);
}
:root[data-theme="light"] {
  --bg: #eef1f7;
  --surface: rgba(255, 255, 255, .72);
  --surface-2: rgba(255, 255, 255, .6);
  --surface-3: rgba(226, 231, 241, .8);
  --solid: #ffffff;
  --glass: rgba(255, 255, 255, .6);
  --shadow: inset 0 1px 0 rgba(255, 255, 255, .9), 0 16px 36px -22px rgba(14, 26, 51, .35);
}

/* fondo aurora + grano */
body { background: var(--bg); }
body::before, body::after { content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none; }
body::before {
  background:
    radial-gradient(40vw 40vw at 12% 8%, rgba(79, 125, 255, .22), transparent 60%),
    radial-gradient(38vw 38vw at 88% 0%, rgba(232, 190, 96, .2), transparent 62%),
    radial-gradient(46vw 40vw at 70% 95%, rgba(154, 107, 255, .16), transparent 60%);
  filter: blur(20px);
  animation: aurora 22s ease-in-out infinite alternate;
}
body::after {
  opacity: .06; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
:root[data-theme="light"] body::before { opacity: .55; }
@keyframes aurora {
  0% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(-3%, 2%, 0) scale(1.08); }
  100% { transform: translate3d(3%, -2%, 0) scale(1.02); }
}

/* topbar y navegación de vidrio */
.topbar { background: var(--glass); border-bottom-color: transparent; box-shadow: 0 1px 0 var(--line); }
.topbar h1 { font-size: 20px; letter-spacing: .06em; color: var(--text-2); }
.nav { background: var(--glass); border-color: var(--line-strong); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06), 0 24px 60px -18px rgba(0, 0, 0, .8); }
.nav a { transition: color .2s, background .25s var(--ease); }
.nav a:hover { color: var(--text); }
@media (min-width: 960px) {
  .topbar h1 { border-left-color: var(--line); }
  .nav { border-radius: 26px; padding: 12px; }
  .nav a { border-radius: 16px; }
  .nav a:hover:not(.active):not(.nav-main) { background: var(--surface-2); }
  .nav a.active:not(.nav-main) {
    background: linear-gradient(100deg, rgba(232, 190, 96, .16), rgba(79, 125, 255, .1));
    box-shadow: inset 0 0 0 1px rgba(232, 190, 96, .22);
  }
  .nav a.active::after { box-shadow: 0 0 12px var(--glow-gold); }
  .nav .nav-main { box-shadow: 0 10px 30px -10px var(--glow-gold); }
}

/* tarjetas y listas de vidrio */
.card, .list, .table-wrap, .kpi, .mc, .podium .p, .bracket .bm, .action, .side-switch, .dropzone {
  backdrop-filter: blur(16px) saturate(140%); -webkit-backdrop-filter: blur(16px) saturate(140%);
}
.modal { background: var(--solid); }
.modal-actions { background: linear-gradient(transparent, var(--solid) 22%); }
input, select, textarea { background: var(--surface-2); }
input:focus, select:focus, textarea:focus { background: var(--solid); }

.mc { border-radius: 20px; transition: border-color .2s, transform .25s var(--ease), box-shadow .25s; }
.mc:hover { transform: translateY(-2px); border-color: rgba(232, 190, 96, .3); box-shadow: var(--shadow), 0 14px 30px -18px var(--glow-gold); }
.mc .when { background: transparent; }

.btn { border-radius: 14px; transition: transform .15s var(--ease), background .2s, box-shadow .25s, border-color .2s; }
.btn.primary { box-shadow: 0 10px 28px -10px var(--glow-gold), inset 0 1px 0 rgba(255, 255, 255, .35); }
.btn.primary:hover { transform: translateY(-1px); box-shadow: 0 14px 34px -10px var(--glow-gold), inset 0 1px 0 rgba(255, 255, 255, .35); }
.btn.glass { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .16); color: #fff; backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.btn.glass:hover { background: rgba(255, 255, 255, .14); }

.section-h { margin-top: 30px; }
.section-h h2 { display: flex; align-items: center; gap: 10px; font-size: 24px; letter-spacing: .04em; }
.section-h h2::before { content: ""; width: 6px; height: 20px; border-radius: 3px; background: var(--gold-grad); box-shadow: 0 0 14px var(--glow-gold); }

.hero { border-radius: var(--r-lg); border-color: rgba(232, 190, 96, .22); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08), 0 30px 60px -30px rgba(0, 0, 0, .9); }

.soft-empty {
  display: flex; align-items: center; gap: 14px; padding: 18px; border-radius: var(--r);
  border: 1px dashed var(--line-strong); background: color-mix(in srgb, var(--surface) 60%, transparent); color: var(--muted); font-weight: 550;
}
.soft-empty svg { width: 38px; height: 38px; padding: 9px; border-radius: 12px; background: var(--surface-3); color: var(--accent-ink); }

/* ---------------------------------------------------------- bento */
.bento { display: grid; gap: 14px; grid-template-columns: repeat(3, 1fr); }
.bento > * { min-width: 0; }
.b-hero {
  grid-column: 1 / -1; position: relative; overflow: hidden; isolation: isolate; container-type: inline-size;
  display: flex; flex-direction: column; align-items: flex-start;
  padding: 26px 22px 24px; border-radius: var(--r-lg); color: #fff;
  background:
    radial-gradient(120% 90% at 100% 0%, rgba(232, 190, 96, .28), transparent 55%),
    radial-gradient(90% 100% at 0% 100%, rgba(79, 125, 255, .3), transparent 60%),
    linear-gradient(150deg, #13214a 0%, #0a1230 50%, #060914 100%);
  border: 1px solid rgba(232, 190, 96, .25);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .1), 0 40px 80px -40px rgba(0, 0, 0, .95);
}
.b-hero::before { /* líneas de cancha */
  content: ""; position: absolute; inset: 0; z-index: -1; opacity: .1;
  background:
    radial-gradient(circle at 78% 50%, transparent 0 110px, #fff 111px 112px, transparent 113px),
    linear-gradient(90deg, transparent calc(78% - 1px), #fff calc(78% - 1px) 78%, transparent 78%),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, .45) 0 60px, transparent 60px 120px);
  mask-image: linear-gradient(90deg, transparent 10%, #000 70%); -webkit-mask-image: linear-gradient(90deg, transparent 10%, #000 70%);
}
.b-hero::after { /* barrido de luz */
  content: ""; position: absolute; inset: -50% auto -50% -30%; width: 40%; z-index: -1;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .09), transparent);
  transform: skewX(-18deg); animation: sweep 7s ease-in-out infinite;
}
@keyframes sweep { 0%, 55% { left: -40%; } 100% { left: 130%; } }
.b-hero h2 { margin: 16px 0 0; font: 800 clamp(34px, 10.4cqi, 96px)/.86 var(--display); text-transform: uppercase; letter-spacing: -.005em; }
.b-hero h2 .gold { background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 6px 26px rgba(232, 190, 96, .35)); }
.b-hero p { margin: 14px 0 0; max-width: 420px; color: rgba(255, 255, 255, .72); font-size: 15.5px; }
.b-cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.b-live {
  display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px 6px 10px; border-radius: 999px;
  background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .14);
  font: 700 12.5px/1 var(--display); letter-spacing: .16em; text-transform: uppercase; color: #f1d68f;
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.b-live i { width: 7px; height: 7px; border-radius: 50%; background: #2fd17a; box-shadow: 0 0 0 0 rgba(47, 209, 122, .6); animation: ping 1.8s infinite; }
@keyframes ping { 70% { box-shadow: 0 0 0 9px rgba(47, 209, 122, 0); } 100% { box-shadow: 0 0 0 0 rgba(47, 209, 122, 0); } }
.b-warn { display: inline-flex; align-items: center; gap: 8px; margin-top: 16px; padding: 8px 12px; border-radius: 12px; background: rgba(255, 181, 71, .14); color: #ffc56b; font-size: 13px; font-weight: 650; }
.b-warn svg { width: 16px; height: 16px; }
.b-orbit { position: absolute; z-index: -1; right: -40px; top: -30px; width: 190px; height: 190px; display: grid; place-items: center; opacity: .5; }
.b-orbit img { width: 62%; filter: drop-shadow(0 20px 40px rgba(0, 0, 0, .6)); animation: float 6s ease-in-out infinite; }
.b-orbit::before, .b-orbit::after { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 1px dashed rgba(232, 190, 96, .35); animation: spin 40s linear infinite; }
.b-orbit::after { inset: 14%; border-style: solid; border-color: rgba(255, 255, 255, .08); border-top-color: rgba(232, 190, 96, .7); animation-duration: 9s; }
@keyframes float { 50% { transform: translateY(-8px) rotate(-2deg); } }

.b-stat {
  position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end; gap: 4px;
  min-height: 132px; padding: 64px 16px 16px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line);
  box-shadow: var(--shadow); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  transition: transform .3s var(--ease), border-color .3s;
}
.b-stat:hover { transform: translateY(-3px); border-color: var(--line-strong); }
.b-stat::before { content: ""; position: absolute; width: 160px; height: 160px; right: -60px; top: -70px; border-radius: 50%; background: var(--tone); opacity: .28; filter: blur(30px); }
.b-stat.gold { --tone: #e8be60; } .b-stat.blue { --tone: var(--blue); } .b-stat.violet { --tone: var(--violet); }
.b-ic { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 13px; background: color-mix(in srgb, var(--tone, var(--accent)) 18%, transparent); color: var(--tone, var(--accent-ink)); border: 1px solid color-mix(in srgb, var(--tone, var(--accent)) 30%, transparent); }
.b-stat .b-ic { position: absolute; top: 14px; left: 16px; }
.b-ic svg { width: 20px; height: 20px; }
.b-stat > b { font: 800 clamp(38px, 9vw, 58px)/.9 var(--display); letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
.b-stat > b small { font-size: .45em; color: var(--muted); margin-left: 2px; }
.b-stat > span:last-child, .b-stat > span:not(.b-ic) { font-size: 11.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.b-bar { height: 4px; margin-top: 8px; border-radius: 4px; background: var(--surface-3); overflow: hidden; }
.b-bar i { display: block; height: 100%; border-radius: 4px; background: linear-gradient(90deg, var(--violet), var(--blue)); box-shadow: 0 0 10px var(--violet); }

.b-next { grid-column: 1 / -1; }
.b-empty {
  display: flex; align-items: center; gap: 16px; flex-wrap: wrap; height: 100%; padding: 20px; border-radius: var(--r);
  background: var(--surface); border: 1px dashed var(--line-strong); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
}
.b-empty .b-ic { width: 52px; height: 52px; border-radius: 16px; --tone: #e8be60; }
.b-empty > div { flex: 1; min-width: 180px; }
.b-empty b { display: block; font: 800 22px/1.05 var(--display); text-transform: uppercase; letter-spacing: .02em; }
.b-empty span { color: var(--muted); font-size: 14px; }

@media (max-width: 559px) {
  .bento { grid-template-columns: 1fr 1fr; gap: 10px; }
  .b-stat { min-height: 116px; padding: 60px 14px 14px; }
  .b-stat.violet { grid-column: 1 / -1; min-height: 0; }
  .b-orbit { width: 140px; height: 140px; right: -36px; top: -26px; }
}
@media (min-width: 960px) {
  .bento { grid-template-columns: repeat(4, 1fr); }
  .b-hero { grid-column: 1 / 4; grid-row: 1 / 4; padding: 36px 40px 36px; justify-content: flex-end; min-height: 460px; }
  .b-hero p { font-size: 16.5px; }
  .b-orbit { right: 28px; top: 24px; width: 200px; height: 200px; opacity: .85; }
  .bento > .b-stat { grid-column: 4; }
  .b-next { grid-column: 1 / -1; }
}

/* próximo partido */
.nm-tile {
  position: relative; overflow: hidden; isolation: isolate; display: block; padding: 18px 18px 20px;
  border-radius: var(--r-lg); color: #fff; background: #070a12; border: 1px solid rgba(255, 255, 255, .1);
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .9); transition: transform .3s var(--ease);
}
.nm-tile:hover { transform: translateY(-2px); }
.nm-tile .bg { position: absolute; inset: 0; z-index: -2; display: grid; grid-template-columns: 1fr 1fr; opacity: .85; }
.nm-tile .bg i:first-child { clip-path: polygon(0 0, 100% 0, 82% 100%, 0 100%); }
.nm-tile .bg i:last-child { clip-path: polygon(18% 0, 100% 0, 100% 100%, 0 100%); margin-left: -18%; }
.nm-tile::after { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(60% 90% at 50% 50%, transparent, rgba(0, 0, 0, .55)), repeating-linear-gradient(115deg, rgba(255, 255, 255, .035) 0 2px, transparent 2px 14px); }
.nm-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; font: 700 13px/1 var(--display); letter-spacing: .14em; text-transform: uppercase; color: rgba(255, 255, 255, .8); }
.nm-vs { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; margin-top: 20px; }
.nm-vs .t { display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; font: 800 clamp(17px, 4vw, 26px)/1 var(--display); text-transform: uppercase; text-shadow: 0 2px 10px rgba(0, 0, 0, .5); }
.nm-vs .crest { filter: drop-shadow(0 10px 20px rgba(0, 0, 0, .5)); }
.nm-vs .mid { text-align: center; }
.nm-vs .mid b { display: block; font: 800 clamp(44px, 10vw, 72px)/1 var(--display); text-shadow: 0 6px 30px rgba(0, 0, 0, .6); }
.nm-vs .mid b i { font-style: normal; opacity: .5; margin: 0 4px; }
.nm-vs .mid span { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; opacity: .85; }
.countdown { display: flex; justify-content: center; gap: 8px; margin-top: 18px; }
.countdown div { min-width: 62px; padding: 10px 6px 8px; text-align: center; border-radius: 14px; background: rgba(0, 0, 0, .35); border: 1px solid rgba(255, 255, 255, .12); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.countdown b { display: block; font: 800 28px/1 var(--display); font-variant-numeric: tabular-nums; }
.countdown small { font-size: 10px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; opacity: .7; }
.countdown.done { display: none; }
.nm-foot { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 16px; font-size: 13px; opacity: .85; }
.nm-foot svg { width: 15px; height: 15px; }

/* ticker de resultados */
.ticker { display: flex; align-items: center; margin-top: 14px; border-radius: 999px; overflow: hidden; background: var(--surface); border: 1px solid var(--line); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); }
.t-lbl { flex: none; padding: 12px 16px; background: var(--gold-grad); color: var(--on-accent); font: 800 13px/1 var(--display); letter-spacing: .14em; text-transform: uppercase; }
.t-track { flex: 1; overflow: hidden; mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); }
.t-run { display: flex; width: max-content; animation: marquee 40s linear infinite; }
.ticker:hover .t-run { animation-play-state: paused; }
.t-run a { display: inline-flex; align-items: center; gap: 8px; padding: 0 22px; white-space: nowrap; font-weight: 600; font-size: 14px; border-right: 1px solid var(--line); }
.t-run a b { font: 800 18px/1 var(--display); color: var(--accent-ink); }
@keyframes marquee { to { transform: translateX(-50%); } }

/* entrada escalonada del bento */
.bento > * { animation: rise .6s var(--ease) both; }
.bento > :nth-child(2) { animation-delay: .06s; }
.bento > :nth-child(3) { animation-delay: .12s; }
.bento > :nth-child(4) { animation-delay: .18s; }
.bento > :nth-child(5) { animation-delay: .24s; }

/* ---------------------------------------------- cabecera de torneo */
.t-hero { display: grid; gap: 14px; }
.t-main {
  position: relative; overflow: hidden; isolation: isolate; container-type: inline-size;
  padding: 24px 22px 22px; padding-right: 150px; border-radius: var(--r-lg); color: #fff;
  background:
    radial-gradient(90% 120% at 100% 0%, rgba(232, 190, 96, .25), transparent 55%),
    radial-gradient(80% 100% at 0% 100%, rgba(79, 125, 255, .28), transparent 60%),
    linear-gradient(150deg, #13214a, #0a1230 55%, #060914);
  border: 1px solid rgba(232, 190, 96, .22); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .1), 0 30px 60px -34px rgba(0, 0, 0, .95);
}
.t-main::after { content: ""; position: absolute; inset: -50% auto -50% -30%; width: 40%; z-index: -1; background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .08), transparent); transform: skewX(-18deg); animation: sweep 8s ease-in-out infinite; }
.t-main h2 { margin: 14px 0 0; font: 800 clamp(34px, 9cqi, 72px)/.9 var(--display); text-transform: uppercase; }
.t-champ { margin: 8px 0 0; color: #f1d68f; }
.t-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.t-chips span { padding: 7px 12px; border-radius: 999px; background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .12); font-size: 13px; color: rgba(255, 255, 255, .75); }
.t-chips b { font: 800 17px/1 var(--display); color: #fff; margin-right: 2px; }
.ring { position: absolute; right: 22px; top: 50%; transform: translateY(-50%); width: 112px; height: 112px; display: grid; place-items: center; }
.ring svg { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); }
.ring circle { fill: none; stroke-width: 8; }
.ring .trk { stroke: rgba(255, 255, 255, .1); }
.ring .val { stroke: #e8be60; stroke-linecap: round; filter: drop-shadow(0 0 6px rgba(232, 190, 96, .7)); transition: stroke-dashoffset 1.2s var(--ease); }
.ring span { text-align: center; line-height: 1; }
.ring b { display: block; font: 800 28px/1 var(--display); }
.ring small { font-size: 10px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; opacity: .65; }
.t-cards { display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.t-card {
  position: relative; overflow: hidden; display: flex; align-items: center; gap: 13px; min-width: 0;
  padding: 14px 16px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); transition: transform .25s var(--ease), border-color .2s;
}
a.t-card:hover { transform: translateY(-2px); border-color: rgba(232, 190, 96, .3); }
.t-card[style*="--tc1"]::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(110deg, color-mix(in srgb, var(--tc1) 30%, transparent), transparent 70%); }
.t-card .avatar { width: 48px; height: 48px; border-radius: 15px; }
.t-card .grow { display: flex; flex-direction: column; gap: 2px; }
.t-card small { font-size: 10.5px; font-weight: 750; letter-spacing: .14em; text-transform: uppercase; color: var(--accent-ink); }
.t-card b { font: 800 22px/1 var(--display); text-transform: uppercase; }
.t-card .grow > span { font-size: 12.5px; color: var(--muted); }
.t-card .b-ic { width: 48px; height: 48px; border-radius: 15px; }
@media (max-width: 559px) {
  .t-main { padding-right: 22px; }
  .t-chips { padding-right: 84px; }
  .ring { top: auto; bottom: 18px; right: 16px; transform: none; width: 76px; height: 76px; }
  .ring b { font-size: 20px; }
  .ring small { font-size: 8.5px; }
  .t-cards { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; margin: 0 -16px; padding: 2px 16px; }
  .t-cards::-webkit-scrollbar { display: none; }
  .t-card { flex: 0 0 82%; scroll-snap-align: start; }
}

/* tabs tipo píldora */
.tabs { background: transparent; border-bottom: 0; padding-top: 14px; gap: 6px; position: static; }
.tabs a { padding: 10px 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); transition: color .2s, background .2s, border-color .2s; }
.tabs a:hover { color: var(--text); border-color: var(--line-strong); }
.tabs a.active { color: var(--on-accent); background: var(--gold-grad); border-color: transparent; box-shadow: 0 8px 22px -10px var(--glow-gold); }
.tabs a.active::after { display: none; }
.chip { backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
.chip.active { background: var(--text); box-shadow: 0 6px 18px -8px rgba(255, 255, 255, .4); }

/* tabla: podio de la tabla */
tbody tr:nth-child(1) .pos { color: #1a1405; background: var(--gold); border-radius: 8px; height: 26px; }
tbody tr:nth-child(2) .pos { color: #1a1405; background: var(--silver); border-radius: 8px; height: 26px; }
tbody tr:nth-child(3) .pos { color: #1a1405; background: var(--bronze); border-radius: 8px; height: 26px; }
tbody tr:nth-child(1) { background: linear-gradient(90deg, rgba(232, 190, 96, .12), transparent 70%); }
.form i { border-radius: 50%; width: 21px; height: 21px; box-shadow: inset 0 -2px 0 rgba(0, 0, 0, .2); }
.podium .p { backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); }
.podium .p.first { box-shadow: 0 20px 50px -24px var(--glow-gold); }
.podium .avatar { border: 2px solid var(--line-strong); }
.podium .first .avatar { border-color: var(--gold); box-shadow: 0 0 0 4px rgba(255, 215, 94, .15), 0 10px 26px -8px var(--glow-gold); }

/* --------------------------------------------- campaña del equipo */
.season { display: grid; gap: 10px; margin-top: 14px; grid-template-columns: auto 1fr; }
.season > * { border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); padding: 14px 16px; min-width: 0; }
.season small { display: block; font-size: 10.5px; font-weight: 750; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.s-pos { display: flex; flex-direction: column; justify-content: center; min-width: 110px; background: linear-gradient(150deg, color-mix(in srgb, var(--accent) 22%, var(--surface)), var(--surface)) !important; border-color: rgba(232, 190, 96, .3) !important; }
.s-pos small { color: var(--accent-ink); }
.s-pos b { font: 800 54px/.95 var(--display); background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.s-pos span { font-size: 12px; color: var(--muted); }
.s-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; align-items: center; }
.s-kpis div { text-align: center; }
.s-kpis b { display: block; font: 800 30px/1 var(--display); }
.s-kpis small { margin-top: 4px; font-size: 9.5px; letter-spacing: .08em; }
.s-form, .s-scorers { grid-column: 1 / -1; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.s-form small, .s-scorers small { min-width: 120px; }
.s-scorers a { display: inline-flex; align-items: center; gap: 8px; padding: 4px 12px 4px 4px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--line); font-weight: 600; font-size: 13.5px; max-width: 200px; }
.s-scorers .avatar { width: 30px; height: 30px; border-radius: 50%; }
.s-scorers b { font: 800 18px/1 var(--display); color: var(--accent-ink); }
@media (min-width: 960px) { .season { grid-template-columns: auto 1.4fr 1fr; } .s-form { grid-column: auto; } .s-form small { min-width: 0; } }
@media (max-width: 480px) { .s-scorers small, .s-form small { width: 100%; min-width: 0; } .s-kpis b { font-size: 24px; } .s-pos { min-width: 92px; } .s-pos b { font-size: 44px; } }

/* --------------------------------------------- ficha: carta coleccionable */
.p-hero { display: grid; gap: 22px; align-items: center; padding: 22px; border-radius: var(--r-lg); position: relative; overflow: hidden; isolation: isolate;
  background: radial-gradient(80% 120% at 0% 0%, color-mix(in srgb, var(--tc1) 45%, transparent), transparent 60%), linear-gradient(150deg, #0e1530, #060914);
  border: 1px solid var(--line-strong); box-shadow: 0 30px 60px -34px rgba(0, 0, 0, .95); color: #fff; }
.p-card {
  position: relative; overflow: hidden; isolation: isolate; width: min(100%, 270px); margin: 0 auto; aspect-ratio: 5 / 7;
  display: flex; flex-direction: column; align-items: center; padding: 16px 16px 14px; border-radius: 24px;
  background: linear-gradient(160deg, color-mix(in srgb, var(--tc1) 85%, #fff) 0%, var(--tc1) 35%, color-mix(in srgb, var(--tc1) 40%, #000) 100%);
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .8), inset 0 0 0 2px rgba(255, 255, 255, .18), inset 0 0 0 6px rgba(232, 190, 96, .35);
  transform: perspective(900px) rotateY(-6deg) rotateX(3deg); transition: transform .5s var(--ease);
}
.p-card:hover { transform: perspective(900px) rotateY(0) rotateX(0) scale(1.02); }
.p-card::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(120deg, transparent 55%, color-mix(in srgb, var(--tc2) 55%, transparent) 55% 60%, transparent 60%), radial-gradient(80% 50% at 50% 0%, rgba(255, 255, 255, .3), transparent 70%); }
.p-card::after { content: ""; position: absolute; inset: 0; background: linear-gradient(115deg, transparent 30%, rgba(255, 255, 255, .25) 45%, transparent 60%); background-size: 250% 100%; animation: holo 5s ease-in-out infinite; mix-blend-mode: overlay; pointer-events: none; }
@keyframes holo { 0%, 100% { background-position: 100% 0; } 50% { background-position: 0 0; } }
.p-top { display: flex; align-items: center; gap: 8px; width: 100%; }
.p-top .crest { width: 34px; height: 34px; }
.p-top b { font: 800 44px/.9 var(--display); text-shadow: 0 2px 8px rgba(0, 0, 0, .35); }
.p-top > span:not(.crest) { flex: 1; font: 800 15px/1 var(--display); letter-spacing: .14em; opacity: .9; }
.p-card .photo-edit { margin-top: 4px; }
.p-card .ph { width: 150px; height: 150px; border-radius: 50%; overflow: hidden; display: grid; place-items: center; border: 4px solid rgba(255, 255, 255, .9); box-shadow: 0 14px 30px rgba(0, 0, 0, .45); background: rgba(0, 0, 0, .25); font: 800 48px/1 var(--display); }
.p-card .ph img { width: 100%; height: 100%; object-fit: cover; }
.p-name { margin-top: auto; text-align: center; font: 800 30px/.95 var(--display); text-transform: uppercase; text-shadow: 0 2px 10px rgba(0, 0, 0, .4); }
.p-name small { display: block; font-size: 15px; font-weight: 700; opacity: .85; letter-spacing: .06em; }
.p-attrs { display: flex; justify-content: center; gap: 6px; width: 100%; margin-top: 10px; padding-top: 10px; border-top: 1px solid rgba(255, 255, 255, .3); }
.p-attrs span { flex: 1; text-align: center; font: 700 11px/1 var(--display); letter-spacing: .12em; opacity: .9; }
.p-attrs b { display: block; font-size: 24px; margin-bottom: 2px; letter-spacing: 0; }
.p-card.light { color: #14110a; }
.p-card.light .p-attrs { border-top-color: rgba(0, 0, 0, .2); }
.p-info h2 { margin: 14px 0 0; font: 800 clamp(40px, 9vw, 76px)/.86 var(--display); text-transform: uppercase; }
.p-info h2 .gold { background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.p-info .meta { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.p-info .pill { display: inline-flex; align-items: center; gap: 7px; padding: 6px 12px; border-radius: 999px; background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .14); font-size: 13px; font-weight: 600; }
.p-info .pill .crest { width: 20px; height: 20px; }
.p-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: 18px; }
.p-stats div { padding: 12px 10px; border-radius: 16px; background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .1); }
.p-stats b { display: block; font: 800 38px/1 var(--display); }
.p-stats .gold b { background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.p-stats small { display: flex; align-items: center; gap: 5px; margin-top: 4px; font-size: 10.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: rgba(255, 255, 255, .6); }
.p-hero + .grid { margin-top: 14px; }
@media (min-width: 760px) { .p-hero { grid-template-columns: 270px 1fr; padding: 30px; gap: 34px; } }
@media (max-width: 480px) { .p-stats { grid-template-columns: repeat(2, 1fr); } }

/* --------------------------------------------- comparación de partido */
.compare { padding: 16px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); }
.c-head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; font: 800 15px/1 var(--display); text-transform: uppercase; letter-spacing: .06em; }
.c-row { padding: 9px 0; }
.c-row + .c-row { border-top: 1px solid var(--line); }
.c-lbl { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 7px; }
.c-lbl span { font-size: 12px; font-weight: 650; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.c-lbl b { font: 800 20px/1 var(--display); min-width: 26px; }
.c-lbl b:last-child { text-align: right; }
.c-bar { display: flex; gap: 4px; height: 8px; }
.c-bar i { display: block; height: 100%; border-radius: 6px; opacity: .35; transition: width .8s var(--ease); }
.c-bar i.lead { opacity: 1; }
.c-bar .h { background: var(--hc); box-shadow: 0 0 10px color-mix(in srgb, var(--hc) 60%, transparent); }
.c-bar .a { background: var(--ac); box-shadow: 0 0 10px color-mix(in srgb, var(--ac) 60%, transparent); }

/* marcador del partido */
.scoreboard { border-radius: var(--r-lg); border: 1px solid rgba(255, 255, 255, .1); }
.scoreboard .big { font-size: clamp(64px, 14vw, 104px); }
.scoreboard .crest.xl { filter: drop-shadow(0 12px 24px rgba(0, 0, 0, .55)); }

/* equipos: hero con más presencia */
.team-hero { border-radius: var(--r-lg); padding: 28px 24px 24px; border: 1px solid rgba(255, 255, 255, .12); }
.team-hero h2 { font-size: clamp(36px, 8vw, 64px); }
.team-hero .pill { background: rgba(0, 0, 0, .35); border: 1px solid rgba(255, 255, 255, .14); }
.pcard { box-shadow: 0 16px 34px -18px rgba(0, 0, 0, .9), inset 0 0 0 1px rgba(255, 255, 255, .14); transition: transform .3s var(--ease), box-shadow .3s; }
.pcard:hover { transform: translateY(-4px) rotate(-.6deg); box-shadow: 0 24px 40px -18px rgba(0, 0, 0, .9), inset 0 0 0 1px rgba(255, 255, 255, .25), 0 0 0 2px rgba(232, 190, 96, .45); }

@media print {
  body.printing > :not(#printRoot) { display: none !important; }
  body.printing #printRoot { display: block; }
  body.printing { background: #fff; }
  #printRoot .sheet { page: credencial; position: relative; width: 210mm; height: 297mm; overflow: hidden; break-after: page; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  #printRoot .slot { position: absolute; width: 85.6mm; height: 54mm; }
  #printRoot .slot svg { display: block; width: 100%; height: 100%; }
  #printRoot .cm { position: absolute; background: #000; }
  #printRoot .cm.v { width: .2mm; height: 5mm; margin-left: -.1mm; }
  #printRoot .cm.h { height: .2mm; width: 5mm; margin-top: -.1mm; }
}
@page credencial { size: A4 portrait; margin: 0; }

@media print {
  .topbar, .nav, .fab, .tabs, .btn, .actions, .no-print { display: none !important; }
  .app { margin: 0; padding: 0; max-width: none; }
  body { background: #fff; color: #000; }
  .pcard { break-inside: avoid; }
}

/* ---------------------------------------------------------------- análisis */
.probbar { display: flex; gap: 2px; height: 22px; margin-top: 8px; }
.probbar i { min-width: 3px; border-radius: 4px; font: 700 11px/22px var(--font); font-style: normal; text-align: center; color: #fff; overflow: hidden; white-space: nowrap; }
.probbar .pb-draw { color: var(--text); }
.pb-home { background: var(--p-home) !important; }
.pb-draw { background: var(--p-draw) !important; }
.pb-away { background: var(--p-away) !important; }
.proj-match { display: block; }
table.proj td { white-space: nowrap; }
.pbar { display: inline-block; width: 44px; height: 6px; margin-right: 8px; border-radius: 3px; background: var(--surface-3); vertical-align: middle; overflow: hidden; }
.pbar i { display: block; height: 100%; border-radius: 0 3px 3px 0; background: var(--accent); }
.big-num { font: 800 28px/1.1 var(--display); color: var(--text); margin: 4px 0 2px; }

/* ---------------------------------------------------------------- árbitros */
.rate-row { display: grid; grid-template-columns: minmax(0, 1fr) 110px; gap: 6px 10px; align-items: center; padding: 8px 0; border-top: 1px solid var(--line); }
.rate-row:first-of-type { border-top: 0; }
.rate-row .rate-who { font-weight: 600; font-size: 14px; }
.rate-row select { min-height: 40px; }
.rate-row input { grid-column: 1 / -1; min-height: 40px; }
.score-pill { display: inline-flex; align-items: center; justify-content: center; min-width: 34px; height: 28px; padding: 0 8px; border-radius: 8px; font: 800 15px/1 var(--display); background: var(--surface-3); color: var(--text); }
.score-pill.sm { min-width: 24px; height: 20px; font-size: 12px; padding: 0 5px; border-radius: 6px; }
.score-pill.high { background: var(--ok-soft); color: var(--win); }
.score-pill.low { background: var(--danger-soft); color: var(--danger); }
.histo { display: flex; align-items: flex-end; gap: 6px; height: 150px; padding-top: 18px; }
.histo .hcol { flex: 1; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; min-width: 0; }
.histo .hcol i { display: block; width: 100%; max-width: 36px; min-height: 2px; border-radius: 4px 4px 0 0; background: var(--accent); }
.histo .hcol:hover i { filter: brightness(1.15); }
.histo .hval { font-size: 12px; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.histo .hlab { font-size: 12px; color: var(--muted); margin-top: 6px; }
.rate-hero { text-align: center; }
.rate-score { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; margin: 10px 0 4px; font-weight: 700; }
.rate-score span:first-child { text-align: right; }
.rate-score span:last-child { text-align: left; }
.rate-score b { font: 800 34px/1 var(--display); }
.rate-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; }
.rate-grid button { min-height: 52px; border-radius: 12px; border: 1px solid var(--line-strong); background: var(--surface-2); color: var(--text); font: 800 22px/1 var(--display); cursor: pointer; }
.rate-grid button.on { background: var(--accent); border-color: var(--accent); color: #111; }
.rate-grid button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.qr-box { margin-top: 10px; display: flex; justify-content: center; }
.qr-box svg { width: 200px; height: 200px; border-radius: 8px; }
