:root {
  --bg: #0b1510;
  --bg2: #102018;
  --card: #15261d;
  --card2: #1b3025;
  --line: #264233;
  --text: #e9f3ec;
  --muted: #93ab9c;
  --accent: #35d07f;
  --accent2: #1fa862;
  --gold: #f2c14e;
  --red: #ef5b5b;
  --blue: #4f9dff;
  --orange: #ff9f43;
  --radius: 14px;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: radial-gradient(1200px 600px at 50% -200px, #1a3a28 0%, var(--bg) 60%) fixed, var(--bg);
  color: var(--text);
  line-height: 1.45;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
button { font: inherit; }
h1, h2, h3, h4 { margin: 0 0 .5rem; line-height: 1.2; }
h2 { font-size: 1.35rem; }
h3 { font-size: 1.05rem; color: var(--accent); margin-top: .25rem; }
h4 { font-size: .95rem; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.center { text-align: center; justify-content: center; }
.error { color: var(--red); min-height: 1.2em; margin: .25rem 0; }

/* ---------- layout ---------- */
.topbar {
  position: sticky; top: 0; z-index: 10;
  display: flex; justify-content: space-between; align-items: center;
  padding: .6rem 16px;
  background: rgba(11, 21, 16, .92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--line);
}
.brand { background: none; border: 0; color: var(--text); font-weight: 800; font-size: 1.1rem; cursor: pointer; padding: 0; }
.brand span { background: linear-gradient(90deg, var(--accent), var(--gold)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.container { width: 100%; max-width: 1100px; margin: 0 auto; padding: 16px; flex: 1; }
.foot { text-align: center; color: var(--muted); font-size: .75rem; padding: 1rem 16px 1.5rem; }
.grid2 { display: grid; gap: 16px; grid-template-columns: 1fr; margin-bottom: 16px; }
@media (min-width: 860px) { .grid2 { grid-template-columns: 1fr 1fr; } }

.card {
  background: linear-gradient(180deg, var(--card2), var(--card));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 16px;
}
.grid2 > .card { margin-bottom: 0; }

/* ---------- botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
  padding: .6rem 1rem; border-radius: 10px; cursor: pointer;
  border: 1px solid var(--line); background: var(--card2); color: var(--text);
  font-weight: 600; transition: transform .08s, background .15s, border-color .15s;
}
.btn:hover { border-color: var(--accent); }
.btn:active { transform: scale(.97); }
.btn-primary { background: linear-gradient(180deg, var(--accent), var(--accent2)); border-color: transparent; color: #04140b; }
.btn-primary:hover { filter: brightness(1.08); }
.btn-danger { border-color: var(--red); color: var(--red); background: transparent; }
.btn-lg { padding: .85rem 1.4rem; font-size: 1.05rem; }
.btn-sm { padding: .35rem .7rem; font-size: .85rem; }
.btn-block { width: 100%; margin-top: .75rem; }
.btn.sel { border-color: var(--accent); color: var(--accent); }
.row-btns { display: flex; gap: .6rem; flex-wrap: wrap; justify-content: center; margin-top: 1rem; }
.stack { display: flex; flex-direction: column; gap: .6rem; align-items: center; margin-top: 1.25rem; }

.chip {
  padding: .35rem .8rem; border-radius: 999px; border: 1px solid var(--line);
  background: var(--card); color: var(--text); cursor: pointer; font-size: .85rem; font-weight: 600;
}
.chip.sel, .chip:hover { border-color: var(--accent); color: var(--accent); }
.chips { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; margin: .35rem 0; }
.chip-label { color: var(--muted); font-size: .8rem; min-width: 80px; }

.tag {
  display: inline-block; font-size: .72rem; font-weight: 700; padding: .15rem .5rem; border-radius: 6px;
  background: rgba(79, 157, 255, .15); color: var(--blue); margin: .3rem .3rem .3rem 0; align-self: flex-start;
}
.role-starter { background: rgba(53, 208, 127, .15); color: var(--accent); }
.role-rotation { background: rgba(242, 193, 78, .15); color: var(--gold); }
.role-prospect { background: rgba(147, 171, 156, .15); color: var(--muted); }
.lvl { background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: .1rem .45rem; font-weight: 800; font-size: .85rem; }
.stars { color: var(--gold); letter-spacing: 1px; }

/* ---------- home ---------- */
.hero { text-align: center; padding: 2.5rem 0 1.5rem; }
.hero h1 { font-size: clamp(2.2rem, 7vw, 3.6rem); background: linear-gradient(90deg, var(--accent), var(--gold)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero .lead { max-width: 560px; margin: 0 auto; color: var(--muted); font-size: 1.05rem; }
.hero-ball { font-size: 3.5rem; animation: bounce 2.2s infinite ease-in-out; }
@keyframes bounce { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-12px) rotate(180deg); } }
.features { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); margin: 1.5rem 0; }
.feat { margin: 0; display: flex; flex-direction: column; gap: .25rem; }
.feat span { color: var(--muted); font-size: .9rem; }

/* ---------- formulario ---------- */
.form { max-width: 640px; margin: 0 auto 16px; }
.field { display: block; margin: 1rem 0; }
.field > span { display: block; font-size: .85rem; color: var(--muted); margin-bottom: .35rem; font-weight: 600; }
input, select {
  width: 100%; padding: .7rem .8rem; border-radius: 10px; border: 1px solid var(--line);
  background: var(--bg2); color: var(--text); font: inherit;
}
textarea { width: 100%; padding: .7rem .8rem; border-radius: 10px; border: 1px solid var(--line); background: var(--bg2); color: var(--text); font: inherit; resize: vertical; }
.link-btn { background: none; border: 0; padding: 0; color: inherit; font: inherit; text-decoration: underline; cursor: pointer; }
.link-btn:hover { color: var(--accent); }
textarea:focus, input:focus, select:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.choice-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .5rem; }
@media (min-width: 600px) { .choice-grid { grid-template-columns: repeat(4, 1fr); } }
.choice {
  display: flex; flex-direction: column; gap: .2rem; text-align: left; padding: .7rem; border-radius: 10px;
  border: 1px solid var(--line); background: var(--bg2); color: var(--text); cursor: pointer;
}
.choice small { color: var(--muted); font-size: .75rem; }
.choice.sel { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent) inset; }

/* ---------- ofertas ---------- */
.offers { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); margin-bottom: 16px; }
.offers .card { margin: 0; display: flex; flex-direction: column; gap: .2rem; }
.offers .card .btn-block { margin-top: auto; }
.offer-head { display: flex; justify-content: space-between; align-items: center; gap: .5rem; }
.offer-head h3 { margin: 0; color: var(--text); }
.pmini { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; margin: .5rem 0; }
.ovr-badge { background: var(--gold); color: #1d1600; border-radius: 8px; padding: .15rem .5rem; font-weight: 900; }

/* ---------- hub ---------- */
.tabs { display: grid; grid-template-columns: repeat(3, 1fr); gap: .3rem; margin-bottom: 16px; }
@media (min-width: 700px) { .tabs { grid-template-columns: repeat(6, 1fr); } }
.tab {
  padding: .6rem .4rem; border: 1px solid var(--line); background: var(--card); color: var(--muted);
  border-radius: 10px; cursor: pointer; font-weight: 700; white-space: nowrap;
}
.tab.active { color: #04140b; background: var(--accent); border-color: var(--accent); }
.pc-top { display: flex; gap: 1rem; align-items: center; }
.pc-ovr {
  width: 78px; height: 92px; flex-shrink: 0; border-radius: 12px; display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: linear-gradient(160deg, var(--gold), #b98a1d); color: #1d1600; box-shadow: 0 6px 20px rgba(242, 193, 78, .2);
}
.pc-ovr b { font-size: 2.2rem; line-height: 1; }
.pc-ovr span { font-weight: 800; font-size: .8rem; }
.pc-info h2 { margin: 0; overflow-wrap: anywhere; }
.pc-team { font-weight: 700; margin-top: .2rem; }
.kv { display: grid; grid-template-columns: 1fr 1fr; gap: .5rem .9rem; margin: 1rem 0 .5rem; }
.kv > div { display: flex; flex-direction: column; gap: .1rem; }
.kv span { color: var(--muted); font-size: .75rem; }
.fdots { display: flex; gap: 3px; flex-wrap: wrap; }
.fdot { font-style: normal; font-size: .7rem; padding: .1rem .3rem; border-radius: 4px; font-weight: 800; }
.meter { display: inline-block; width: 100%; max-width: 140px; height: 8px; background: var(--bg); border-radius: 99px; overflow: hidden; vertical-align: middle; }
.meter i { display: block; height: 100%; background: linear-gradient(90deg, var(--orange), var(--accent)); }
.rival { font-size: .88rem; color: var(--muted); padding: .5rem .7rem; background: var(--bg2); border-radius: 8px; margin: .4rem 0; }
.rival b { color: var(--text); }
.status { padding: .5rem .7rem; border-radius: 8px; background: rgba(242, 193, 78, .12); color: var(--gold); margin: .5rem 0; }
.status.bad { background: rgba(239, 91, 91, .12); color: var(--red); }
.stats { display: grid; grid-template-columns: repeat(5, 1fr); gap: .4rem; margin-top: .75rem; }
.stats > div { background: var(--bg2); border-radius: 10px; padding: .5rem .3rem; text-align: center; display: flex; flex-direction: column; }
.stats b { font-size: 1.15rem; }
.stats span { font-size: .68rem; color: var(--muted); }
.next { display: flex; flex-direction: column; }
.next .btn-block { margin-top: auto; }
.nf { padding: 1rem 0; }
.nf-teams { display: flex; flex-direction: column; align-items: center; gap: .2rem; font-size: 1.25rem; font-weight: 800; text-align: center; padding: .75rem 0; }
.nf-teams em { font-size: .8rem; color: var(--muted); font-style: normal; }
.mine { color: var(--accent); }
.euro-status { padding: .5rem .7rem; background: rgba(79, 157, 255, .1); color: var(--blue); border-radius: 8px; margin-bottom: .5rem; font-size: .9rem; }
.news, .list { list-style: none; padding: 0; margin: 0; }
.news li, .list li { padding: .45rem 0; border-bottom: 1px solid var(--line); font-size: .9rem; }
.news li:last-child, .list li:last-child { border-bottom: 0; }

/* ---------- tablas ---------- */
.table-wrap { overflow-x: auto; }
.tbl { width: 100%; border-collapse: collapse; font-size: .85rem; }
.tbl th { color: var(--muted); font-weight: 600; font-size: .75rem; padding: .35rem .3rem; text-align: center; border-bottom: 1px solid var(--line); }
.tbl td { padding: .38rem .3rem; text-align: center; border-bottom: 1px solid rgba(38, 66, 51, .5); }
.tbl .tl { text-align: left; }
.tbl tr td:first-child { border-left: 3px solid transparent; }
.tbl tr.z-ucl td:first-child { border-left-color: var(--blue); }
.tbl tr.z-uel td:first-child { border-left-color: var(--orange); }
.tbl tr.z-uecl td:first-child { border-left-color: #2bb5a0; }
.legend .z-uecl i { background: #2bb5a0; }
.tbl tr.z-lib td:first-child { border-left-color: #a07cf2; }
.legend .z-lib i { background: #a07cf2; }
.tbl tr.z-pro td:first-child { border-left-color: var(--accent); }
.tbl tr.z-rel td:first-child { border-left-color: var(--red); }
.tbl tr.z-po td:first-child { border-left-color: var(--gold); }
.legend .z-po i { background: var(--gold); }
.euro-status.po { background: rgba(242, 193, 78, .12); color: var(--gold); }
.tbl tr.me td { background: rgba(53, 208, 127, .12); font-weight: 700; }
.tbl.mini td { padding: .25rem .25rem; }
@media (max-width: 520px) { .hide-s { display: none; } }
.legend { display: flex; flex-wrap: wrap; gap: .8rem; font-size: .75rem; color: var(--muted); margin-top: .5rem; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: .3rem; vertical-align: middle; }
.legend .z-ucl i { background: var(--blue); } .legend .z-uel i { background: var(--orange); }
.legend .z-pro i { background: var(--accent); } .legend .z-rel i { background: var(--red); }
.results { list-style: none; padding: 0; margin: 0; }
.results li { display: grid; grid-template-columns: 1fr auto 1fr; gap: .5rem; align-items: center; padding: .35rem 0; border-bottom: 1px solid rgba(38, 66, 51, .5); font-size: .85rem; }
.results li span:first-child { text-align: right; }
.results li b { background: var(--bg2); padding: .1rem .5rem; border-radius: 6px; white-space: nowrap; }
.results li.me { color: var(--accent); font-weight: 700; }
.results .win { font-weight: 800; }
.groups { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
.grp { margin: 0; }
.banner { text-align: center; padding: .8rem; border-radius: 10px; background: rgba(53, 208, 127, .12); color: var(--accent); font-weight: 800; margin: .75rem 0; }
.banner.gold { background: rgba(242, 193, 78, .14); color: var(--gold); }

/* ---------- estadísticas de liga ---------- */
.leaders-grid { display: grid; gap: 12px; grid-template-columns: 1fr; }
@media (min-width: 700px) { .leaders-grid { grid-template-columns: repeat(3, 1fr); } }
.leaders { background: var(--bg2); border-radius: 10px; padding: .7rem .8rem; }
.leaders h4 { margin-bottom: .4rem; }
.leaders ol { margin: 0; padding: 0; list-style: none; counter-reset: pos; }
.leaders li { counter-increment: pos; display: flex; align-items: center; gap: .6rem; padding: .35rem 0; border-bottom: 1px solid rgba(38, 66, 51, .5); }
.leaders li:last-child { border-bottom: 0; }
.leaders li::before { content: counter(pos); width: 1.4rem; height: 1.4rem; border-radius: 50%; background: var(--card2); display: inline-flex; align-items: center; justify-content: center; font-size: .75rem; font-weight: 800; flex-shrink: 0; }
.leaders li:first-child::before { background: var(--gold); color: #1d1600; }
.leaders li span { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.leaders li small { color: var(--muted); font-size: .75rem; }
.leaders li em { font-style: normal; font-weight: 900; font-size: 1.1rem; }
.leaders li.me b { color: var(--accent); }

/* ---------- partido ---------- */
.comp-label { text-align: center; color: var(--muted); font-size: .85rem; font-weight: 600; margin-bottom: .5rem; }
.prematch { max-width: 620px; margin: 0 auto 16px; text-align: center; }
.vs { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: .6rem; margin: 1.25rem 0; }
/* portería interactiva (penaltis y faltas) */
.goal-scene { display: block; width: 100%; max-width: 420px; margin: .6rem auto; border-radius: 12px; overflow: hidden; box-shadow: 0 8px 24px rgba(0, 0, 0, .35); touch-action: manipulation; }
.goal-scene .gz { cursor: pointer; }
.goal-scene .gz rect { fill: rgba(53, 208, 127, .08); stroke: rgba(53, 208, 127, .55); stroke-width: 1.5; stroke-dasharray: 5 4; transition: fill .15s; }
.goal-scene .gz:hover rect, .goal-scene .gz:active rect { fill: rgba(53, 208, 127, .32); stroke-dasharray: none; }
.goal-scene .gz text { fill: #fff; font: 700 11px system-ui, sans-serif; paint-order: stroke; stroke: rgba(0, 0, 0, .55); stroke-width: 3px; pointer-events: none; }
.goal-scene .ball, .goal-scene .gk { transition: transform .55s cubic-bezier(.2, .8, .3, 1); }
.goal-scene .gk { transition-delay: .05s; }
.goal-scene.aimed .gz:not(.picked) { opacity: .35; }
.goal-scene .gz.picked rect { fill: rgba(242, 193, 78, .3); stroke: var(--gold); stroke-dasharray: none; }
/* barra de potencia del penalti */
.power { margin: .4rem 0 .2rem; animation: fadein .2s; }
.power-bar { position: relative; height: 18px; border-radius: 99px; overflow: hidden; background: linear-gradient(90deg, #3a2323, #4a3a1c 40%, #1d4a31 55%, #1d4a31 85%, #5a2020 93%); box-shadow: 0 0 0 1px rgba(255, 255, 255, .08) inset; }
.power-sweet { position: absolute; top: 0; bottom: 0; left: 55%; width: 30%; background: rgba(53, 208, 127, .55); box-shadow: 0 0 12px rgba(53, 208, 127, .6) inset; }
.power-over { position: absolute; top: 0; bottom: 0; left: 93%; right: 0; background: rgba(239, 91, 91, .7); }
.power-needle { position: absolute; top: -2px; bottom: -2px; left: 0; width: 5px; margin-left: -2.5px; border-radius: 3px; background: #fff; box-shadow: 0 0 8px #fff; animation: needle linear infinite alternate; }
.power-needle.still { animation: none; }
@keyframes needle { from { left: 0; } to { left: 100%; } }
.power-res { display: flex; align-items: center; gap: .6rem; justify-content: center; font-size: .85rem; color: var(--muted); margin: .3rem 0; }
.power-bar.mini { width: 140px; height: 10px; }
.power-res b { color: var(--text); font-variant-numeric: tabular-nums; }
/* mano a mano */
.dec-opts.two { grid-template-columns: 1fr 1fr; }
.dec-opts.two .dec-opt { padding: .6rem .7rem; font-size: .88rem; }
.goal-scene.p1v1 { max-width: 360px; }
.p1v1 .p-path { fill: none; stroke: rgba(255, 255, 255, .45); stroke-width: 2; stroke-dasharray: 5 5; animation: dash 1s linear infinite; pointer-events: none; }
@keyframes dash { to { stroke-dashoffset: -20; } }
.p1v1 .p-target circle { fill: rgba(242, 193, 78, .22); stroke: var(--gold); stroke-width: 2; transition: fill .15s; animation: pulse 1.4s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
.p1v1 .p-target:hover circle { fill: rgba(242, 193, 78, .5); }
@keyframes pulse { 50% { transform: scale(1.12); } }
.p1v1 .ball { transition: transform .6s var(--ease, ease-out); }
/* celebración */
.goal-burst { position: fixed; inset: 0; pointer-events: none; z-index: 80; overflow: hidden; display: flex; align-items: center; justify-content: center; }
.goal-burst b { font-size: clamp(3rem, 14vw, 6rem); font-weight: 900; color: var(--gold); text-shadow: 0 6px 30px rgba(0, 0, 0, .6); animation: burst 1.6s ease-out forwards; }
.goal-burst i { position: absolute; top: -10px; width: 9px; height: 14px; border-radius: 2px; animation: confetti 1.8s ease-in forwards; }
@keyframes burst { 0% { transform: scale(.3) rotate(-8deg); opacity: 0; } 25% { transform: scale(1.15) rotate(3deg); opacity: 1; } 70% { transform: scale(1); opacity: 1; } 100% { transform: scale(1.1); opacity: 0; } }
@keyframes confetti { to { transform: translateY(110vh) rotate(720deg); } }
.scoreboard.shake { animation: shake .5s; }
.scoreboard.flash { animation: flash .9s; }
@keyframes shake { 0%, 100% { transform: translateX(0); } 20% { transform: translateX(-8px); } 40% { transform: translateX(7px); } 60% { transform: translateX(-5px); } 80% { transform: translateX(3px); } }
@keyframes flash { 0% { box-shadow: 0 0 0 0 rgba(53, 208, 127, .0); } 30% { box-shadow: 0 0 0 6px rgba(53, 208, 127, .55); } 100% { box-shadow: 0 0 0 0 rgba(53, 208, 127, 0); } }
@media (prefers-reduced-motion: reduce) { .goal-burst, .scoreboard.shake, .scoreboard.flash { animation: none; } .goal-burst { display: none; } }

/* fichajes */
.tf-team h4 { margin: 0 0 .4rem; display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; color: var(--text); }
.tf-h { font-size: .8rem; font-weight: 700; color: var(--muted); margin: .4rem 0 .2rem; }
.tf-team .list li, .card ol.list li { display: flex; flex-wrap: wrap; align-items: baseline; gap: .35rem; }
.tf-team .list li b, .card ol.list li b { margin-left: auto; color: var(--gold); }

/* alineaciones en la previa */
/* previa: en el móvil la tarjeta del partido arriba y las dos alineaciones debajo, lado a lado;
   en pantallas grandes, cada alineación al lado de su equipo y todo a la vista sin bajar */
.pre-layout.has-lu { display: grid; grid-template-columns: 1fr 1fr; grid-template-areas: "main main" "h a"; gap: 12px; margin-bottom: 16px; align-items: start; }
.pre-layout.has-lu > .prematch { grid-area: main; margin-bottom: 0; }
.pre-layout.has-lu > .lu { margin: 0; min-width: 0; }
.pre-layout.has-lu > .lu:first-child { grid-area: h; }
.pre-layout.has-lu > .lu:last-child { grid-area: a; }
.lu-label { font-size: .68rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); font-weight: 700; margin-bottom: .2rem; }
.lu-list li { min-width: 0; }
.lu-list li > a, .lu-list li > span:not(.lu-pos) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
@media (min-width: 1150px) {
  .pre-layout.has-lu { grid-template-columns: minmax(0, 1fr) minmax(420px, 560px) minmax(0, 1fr); grid-template-areas: "h main a"; gap: 16px;
    width: min(1440px, calc(100vw - 48px)); margin-left: 50%; transform: translateX(-50%); }
  .pre-layout.has-lu > .prematch { max-width: none; align-self: stretch; display: flex; flex-direction: column; justify-content: center; }
}
.lu h4 { margin: 0 0 .4rem; font-size: .95rem; color: var(--text); }
.lu-list { list-style: none; margin: 0; padding: 0; font-size: .85rem; }
.lu-list li { display: flex; align-items: center; gap: .4rem; padding: .22rem 0; border-bottom: 1px solid var(--line); }
.lu-list li b { margin-left: auto; color: var(--gold); }
.lu-list li.me { color: var(--accent); font-weight: 700; }
.lu-pos { flex: 0 0 2.2rem; font-size: .7rem; color: var(--muted); font-weight: 700; }
.lu-facts { margin-top: .5rem; font-size: .8rem; color: var(--muted); display: grid; gap: .2rem; }
@media (max-width: 420px) { .pre-layout.has-lu { gap: 8px; } .pre-layout .lu { padding: 12px 10px; } .lu-list { font-size: .78rem; } }

/* fichas de club y de jugador */
.modal-box { max-height: calc(100vh - 32px); overflow-y: auto; }
.tlink { cursor: pointer; }
.tlink:hover { text-decoration: underline; text-decoration-color: var(--accent); }
.tbl.clickable tbody tr { cursor: pointer; }
.tbl.clickable tbody tr:hover td { background: rgba(53, 208, 127, .08); }
.tbl tr.tot td { border-top: 1px solid var(--line); }
.tbl th.sortable { cursor: pointer; user-select: none; white-space: nowrap; }
.tbl th.sortable:hover, .tbl th.sorted { color: var(--accent); }
.tm-head { display: flex; align-items: center; gap: .8rem; margin-bottom: .5rem; }
.tm-head h3 { margin: 0; color: var(--text); }
.team-modal h4, .player-modal h4 { margin: 1rem 0 .4rem; color: var(--accent); }
.player-modal .pc-ovr { flex-shrink: 0; }

/* escudos (js/crests.js) */
.crest { display: inline-block; vertical-align: -0.28em; margin-right: .4em; flex-shrink: 0; filter: drop-shadow(0 1px 1px rgba(0, 0, 0, .45)); }
.crest.crest-r { margin: 0 0 0 .4em; }
.sb-team .crest { display: block; margin: 0 auto .3rem; }
.vs-team .crest { margin: 0; }
.offer-head h2 .crest, .offer-head h3 .crest { vertical-align: middle; }
.vs-team { display: flex; flex-direction: column; align-items: center; gap: .35rem; }
.vs-team b { font-size: 1.2rem; }
.vs-team small { color: var(--muted); }
.vs-team.mine b { color: var(--accent); }
.vs-mid { font-weight: 900; color: var(--gold); font-size: 1.3rem; }
.role { padding: .8rem; border-radius: 10px; background: var(--bg2); margin: .75rem 0; }
.role-start { background: rgba(53, 208, 127, .12); }
.role-sub { background: rgba(242, 193, 78, .12); }
.role-bench, .role-inj, .role-susp { background: rgba(239, 91, 91, .1); }

.match { max-width: 720px; margin: 0 auto; }
.scoreboard {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: .5rem;
  background: linear-gradient(180deg, #0f2a1b, #0a1c12); border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem;
  background-image: repeating-linear-gradient(90deg, rgba(255, 255, 255, .025) 0 40px, transparent 40px 80px);
}
.sb-team { font-weight: 800; text-align: center; font-size: 1.05rem; overflow-wrap: anywhere; }
.sb-team.mine { color: var(--accent); }
.sb-mid { text-align: center; }
.sb-score { font-size: 2.4rem; font-weight: 900; letter-spacing: 2px; font-variant-numeric: tabular-nums; }
.sb-min { color: var(--gold); font-weight: 800; }
.mprog { height: 5px; background: var(--card); border-radius: 99px; overflow: hidden; margin: .6rem 0; }
.mprog i { display: block; height: 100%; width: 0; background: var(--accent); transition: width .1s linear; }
.mstatus { text-align: center; font-size: .9rem; color: var(--muted); margin: .4rem 0; }
.mstatus b { color: var(--text); }
.mcontrols { display: flex; justify-content: center; gap: .4rem; margin: .6rem 0; }
.feed { list-style: none; padding: 0; margin: 0; max-height: 52vh; overflow-y: auto; }
.feed li { display: flex; gap: .6rem; padding: .5rem .7rem; border-radius: 8px; margin-bottom: .3rem; background: var(--card); font-size: .9rem; animation: fadein .25s; }
.fmin { color: var(--gold); font-weight: 800; min-width: 2.2rem; }
.feed .goal-me { background: rgba(53, 208, 127, .18); font-weight: 700; }
.feed .goal-op { background: rgba(239, 91, 91, .15); }
.feed .ok { background: rgba(53, 208, 127, .08); }
.feed .ko { background: rgba(239, 91, 91, .08); }
.feed .info { color: var(--muted); }
.feed .card-y { background: rgba(242, 193, 78, .15); }
.feed .card-r { background: rgba(239, 91, 91, .25); }
.feed .dec-line { border-left: 3px solid var(--gold); }
@keyframes fadein { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }

/* ---------- modal de decisión ---------- */
.modal { position: fixed; inset: 0; z-index: 50; background: rgba(0, 0, 0, .7); display: flex; align-items: center; justify-content: center; padding: 16px; }
.modal.hidden { display: none; }
.modal-box {
  width: 100%; max-width: 480px; background: linear-gradient(180deg, #1e3a2b, var(--card)); border: 1px solid var(--accent);
  border-radius: 18px; padding: 18px; box-shadow: 0 20px 60px rgba(0, 0, 0, .5); animation: pop .2s ease-out;
}
@keyframes pop { from { transform: scale(.92); opacity: 0; } to { transform: none; opacity: 1; } }
.dec-head { display: flex; justify-content: space-between; gap: .5rem; font-size: .8rem; color: var(--muted); margin-bottom: .6rem; }
.dec-min { color: var(--gold); font-weight: 800; }
.dec h3 { color: var(--text); font-size: 1.15rem; }
.dec-ctx { background: rgba(79, 157, 255, .12); color: #b9d6ff; padding: .6rem .7rem; border-radius: 10px; font-size: .92rem; }
.timer { height: 6px; background: var(--bg); border-radius: 99px; overflow: hidden; margin: .8rem 0; }
.timer i { display: block; height: 100%; background: linear-gradient(90deg, var(--red), var(--gold), var(--accent)); transform-origin: left; animation: shrink linear forwards; }
@keyframes shrink { from { transform: scaleX(1); } to { transform: scaleX(0); } }
.dec-opts { display: grid; gap: .5rem; }
.dec-opt { padding: .85rem; font-size: 1rem; justify-content: flex-start; }
.dec-opt:hover { background: var(--card2); }
.dec-result { text-align: center; }
.dec-big { font-size: 3.2rem; }
.dec-result p { font-size: 1.05rem; }
.dec-result.ok { }
.card-note { color: var(--gold); }

/* ---------- post-partido ---------- */
.post { max-width: 720px; margin: 0 auto 16px; text-align: center; }
.post h2 { font-size: 1.8rem; }
.post-W h2 { color: var(--accent); } .post-L h2 { color: var(--red); } .post-D h2 { color: var(--gold); }
.final-score { display: grid; grid-template-columns: 1fr auto 1fr; gap: .6rem; align-items: center; font-weight: 700; margin: .75rem 0; }
.final-score b { font-size: 2rem; }
.perf { display: flex; gap: 1rem; align-items: center; justify-content: center; flex-wrap: wrap; margin: 1rem 0; }
.perf .stats { grid-template-columns: repeat(4, 1fr); flex: 1; min-width: 240px; margin: 0; }
.rating { width: 84px; height: 84px; border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; font-size: 1.8rem; font-weight: 900; }
.rating small { font-size: .65rem; font-weight: 700; }
.r-great { background: #1f7a4a; color: #fff; } .r-good { background: var(--accent); color: #04140b; }
.r-ok { background: var(--gold); color: #1d1600; } .r-bad { background: var(--red); color: #fff; }
.notes { list-style: none; padding: 0; text-align: left; }
.notes li { padding: .5rem .7rem; background: var(--bg2); border-radius: 8px; margin-bottom: .3rem; }

/* ---------- resumen ---------- */
.move { padding: .5rem 0; border-bottom: 1px solid var(--line); }
.move:last-child { border-bottom: 0; }
.move h4 { margin-bottom: .25rem; }
.up { color: var(--accent); } .down { color: var(--red); }

/* ---------- tienda, selección y contratos ---------- */
.money { color: var(--gold); }
.money.big { font-size: 1.3rem; }
.lvl-bar { color: var(--accent); letter-spacing: 2px; font-size: .9rem; }
.item h3 { font-size: 1rem; }
.btn:disabled { opacity: .45; cursor: not-allowed; filter: grayscale(.6); }
.btn-ad { background: linear-gradient(180deg, #ffcf5c, #e0a82e); color: #1d1600; border-color: transparent; }
.status .btn-ad { margin-left: .5rem; }
.sponsor { border-color: rgba(242, 193, 78, .4); }
.euro-status.nat { background: rgba(242, 193, 78, .1); color: var(--gold); }
.renew { background: rgba(53, 208, 127, .08); border: 1px solid rgba(53, 208, 127, .3); border-radius: 10px; padding: .75rem; margin: .5rem 0; }
.renew p { margin: 0 0 .5rem; }

.share { max-width: 620px; margin: 0 auto 16px; text-align: center; }
#modal .share { text-align: center; }
.lang-list { display: grid; gap: 8px; }

/* multijugador */
.mp-bar { margin: 8px auto 0; padding: 8px 14px; border-radius: 12px; font-size: .85rem; background: rgba(53, 208, 127, .1); border: 1px solid rgba(53, 208, 127, .3); }
.mp-bar.wait { background: rgba(242, 193, 78, .1); border-color: rgba(242, 193, 78, .4); }
.mp-bar.bad { background: rgba(239, 91, 91, .12); border-color: rgba(239, 91, 91, .45); }
#mpBar:empty { display: none; }
/* tanda de penaltis entre amigos */
.pk { text-align: center; }
.pk-score { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 8px; margin: 10px 0; }
.pk-score b { display: block; } .pk-score span { font-size: .85rem; }
.pk-score i { font-style: normal; font-size: 2rem; font-weight: 900; color: var(--gold); }
.pk-dirs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin: 8px 0; }
.rep-grid { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.tg-item { display: flex; flex-direction: column; align-items: center; gap: 2px; margin: 8px 0; opacity: 0; animation: fadein .6s forwards; }
.hof-card .stats div b { font-size: 1.1rem; }
/* reacciones en el partido compartido */
.reacts { display: flex; gap: 4px; flex-wrap: wrap; justify-content: center; margin-top: 6px; }
.react { font-size: 1.3rem; background: var(--card2); border: 1px solid var(--line); border-radius: 10px; padding: 2px 8px; cursor: pointer; }
.react:active { transform: scale(.9); }
.react-box { position: relative; height: 0; }
.react-pop { position: absolute; left: 50%; top: -60px; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center;
  animation: reactUp 2.6s ease-out forwards; pointer-events: none; z-index: 5; }
.react-pop b { font-size: 2.2rem; }
.react-pop span { font-size: .75rem; background: rgba(0, 0, 0, .55); padding: 1px 8px; border-radius: 999px; }
.react-pop.mine span { background: rgba(53, 208, 127, .5); }
@keyframes reactUp { 0% { opacity: 0; transform: translate(-50%, 10px) scale(.6); } 15% { opacity: 1; transform: translate(-50%, 0) scale(1.1); } 100% { opacity: 0; transform: translate(-50%, -70px) scale(1); } }
.tag.captain { background: rgba(242, 193, 78, .2); color: var(--gold); }
.nat-switch { margin: 6px 0; padding: 8px 10px; border: 1px dashed var(--line); border-radius: 10px; }
/* amigos (otros jugadores humanos) en plantillas, alineaciones y goleadores */
tr.friend td, li.friend { color: var(--blue); font-weight: 700; }
tr.friend td { background: rgba(79, 157, 255, .1); }
.ftag { display: inline-block; margin-left: .3rem; padding: 0 .35rem; border-radius: 6px; font-size: .72rem; font-weight: 700; color: var(--blue); background: rgba(79, 157, 255, .15); white-space: nowrap; max-width: 9rem; overflow: hidden; text-overflow: ellipsis; vertical-align: middle; }
.mp-code { font-size: 2.6rem; font-weight: 900; letter-spacing: .3em; color: var(--gold); margin: 6px 0 10px; }
.mp-list { text-align: left; max-width: 420px; margin: 10px auto; }

/* continentes en los selectores de ligas y copas */
.cont-tabs { display: flex; justify-content: center; gap: 8px; margin-bottom: 10px; }
.cont-tab { display: inline-flex; align-items: center; gap: 8px; padding: 8px 16px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--card2); color: var(--text); font-weight: 800; cursor: pointer; }
.cont-tab.sel { border-color: var(--accent); background: rgba(53, 208, 127, .15); color: var(--accent); }
.cont-row { margin-bottom: 6px; }
.cont-row small { display: block; margin-bottom: 4px; }

/* modos de juego, retos y némesis */
.mode-grid, .ch-grid { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.ch-card { border-color: rgba(242, 193, 78, .4); }
.ch-card.done { box-shadow: 0 0 0 1px var(--gold), 0 10px 30px -12px rgba(242, 193, 78, .5); }
.nem-vs { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; text-align: center; margin: 8px 0; }
.nem-vs b { display: block; }
.nem-vs span { font-size: .78rem; color: var(--muted); }
.nem-vs i { font-style: normal; font-weight: 900; color: var(--red); font-size: 1.2rem; }
.nem-tbl td { text-align: center; }
.nem-tbl td.win b { color: var(--accent); }
.ev-opts { display: grid; gap: 8px; margin-top: 10px; }
.ev-opts .btn { white-space: normal; text-align: left; }
.ev-eff { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
.ev-eff span { padding: 4px 10px; border-radius: 999px; font-size: .82rem; font-weight: 700; background: var(--card2); }
.ev-eff .good { color: var(--accent); } .ev-eff .bad { color: var(--red); }
.tip { display: flex; align-items: center; gap: 10px; justify-content: space-between; border-color: rgba(79, 157, 255, .45); background: rgba(79, 157, 255, .08); }
.tip p { margin: 0; font-size: .9rem; }
.tag.badge { background: rgba(242, 193, 78, .2); color: var(--gold); }

/* negociar contrato */
.offer.gone { opacity: .55; }
details.neg { margin: 8px 0; border: 1px dashed var(--line); border-radius: 10px; padding: 6px 10px; }
details.neg summary { cursor: pointer; font-weight: 700; color: var(--gold); }
.neg-btns { display: grid; gap: 6px; margin-top: 6px; }
.neg-btns .btn { white-space: normal; text-align: left; }

/* dorsal */
.dorsal { display: inline-flex; align-items: center; justify-content: center; min-width: 1.9em; height: 1.9em; padding: 0 .3em; border-radius: 8px;
  background: var(--gold); color: #1d1600; font-weight: 900; font-size: .8em; vertical-align: middle; }
.num-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(40px, 1fr)); gap: 6px; margin-top: 8px; }
.num { height: 38px; border-radius: 8px; border: 1px solid var(--line); background: var(--card2); color: var(--text); font-weight: 800; cursor: pointer; }
.num:hover:not(:disabled) { border-color: var(--accent); background: var(--accent2); }
.num:disabled { opacity: .3; cursor: not-allowed; text-decoration: line-through; }
.num.fav { border-color: var(--accent); }
.num.homage { border-color: var(--gold); background: rgba(242, 193, 78, .2); }

/* gráficas de la carrera */
.charts { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 760px) { .charts { grid-template-columns: 1fr; } }
.chart { width: 100%; height: auto; display: block; }
.chart text { fill: var(--muted); font-size: 12px; }
.ch-grid { stroke: var(--line); stroke-width: 1; }
.ch-line { fill: none; stroke: var(--accent); stroke-width: 3; stroke-linejoin: round; }
.ch-area { fill: rgba(53, 208, 127, .12); }
.ch-dot { fill: var(--gold); }
.ch-g { fill: var(--accent); }
.ch-a { fill: var(--blue); }
.ch-leg-g i { background: var(--accent); }
.ch-leg-a i { background: var(--blue); }

/* Equipo del Año */
.toty { display: grid; gap: 10px; margin-top: 10px; padding: 14px 8px; border-radius: 12px;
  background: repeating-linear-gradient(0deg, rgba(53, 208, 127, .07) 0 40px, rgba(53, 208, 127, .03) 40px 80px); border: 1px solid var(--line); }
.toty-row { display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; }
.toty-p { min-width: 92px; max-width: 140px; text-align: center; background: var(--card2); border-radius: 10px; padding: 6px 8px; border: 1px solid var(--line); }
.toty-p b { display: block; font-size: .85rem; }
.toty-p span { font-size: .72rem; color: var(--muted); }
.toty-p.me { border-color: var(--gold); box-shadow: 0 0 0 1px var(--gold); }

/* partido homenaje */
.tm-head { position: relative; overflow: hidden; text-align: center; }
.tm-score { display: flex; align-items: center; justify-content: center; gap: 18px; font-weight: 800; }
.tm-score b { font-size: 2.4rem; color: var(--gold); }
.tm-xi { list-style: none; padding: 0; margin: 0; display: grid; gap: 4px; }
.tm-xi li.me { color: var(--gold); font-weight: 800; }
.hidden { display: none !important; }
.career-img { width: 100%; max-width: 420px; border-radius: 14px; border: 1px solid var(--line); box-shadow: 0 12px 40px rgba(0, 0, 0, .4); }

.names-list { max-height: 55vh; overflow-y: auto; display: grid; gap: .5rem; margin: .75rem 0; padding-right: .25rem; }
.names-list label { display: flex; flex-direction: column; gap: .15rem; }
.names-list input { padding: .5rem .6rem; }

/* ---------- anuncio con recompensa (demo) ---------- */
.ad-layer { z-index: 60; }
.ad-box { text-align: center; border-color: var(--gold); }
.ad-count { font-size: 3rem; font-weight: 900; color: var(--gold); margin: .5rem 0; }

/* ---------- anuncios ---------- */
.foot a { color: var(--muted); }
.ad-frame { display: block; border: 0; max-width: 100%; }
.ad-big { display: flex; justify-content: center; min-height: 250px; margin: .5rem 0; }
.ad-sticky { position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; display: flex; justify-content: center; padding: 4px 0; background: rgba(11, 21, 16, .96); border-top: 1px solid var(--line); }
.consent-bar { position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 70; max-width: 560px; margin: 0 auto; padding: 12px 16px; background: var(--card2); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 8px 30px rgba(0, 0, 0, .5); }
.consent-bar p { margin: 0 0 10px; font-size: .9rem; }
.consent-bar a { color: var(--accent); }
.ad-wrap { margin: 0 0 16px; min-height: 100px; text-align: center; }
.ad-tag { display: block; font-size: .65rem; color: var(--muted); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 2px; }
.ad-slot {
  min-height: 90px; margin: 0 0 16px; border: 1px dashed var(--line); border-radius: 10px;
  display: flex; align-items: center; justify-content: center; color: var(--muted); font-size: .75rem; opacity: .6;
}

@media (max-width: 520px) {
  .container { padding: 12px 16px; }
  .stats { grid-template-columns: repeat(3, 1fr); }
  .sb-score { font-size: 2rem; }
  .sb-team { font-size: .9rem; }
}

/* =====================================================================
   Diseño v2: capa visual por encima de lo anterior (solo CSS, sin fuentes ni imágenes externas)
   ===================================================================== */
:root {
  --shadow: 0 1px 0 rgba(255, 255, 255, .04) inset, 0 10px 30px -12px rgba(0, 0, 0, .55);
  --glow: 0 0 0 1px rgba(53, 208, 127, .35), 0 8px 28px -8px rgba(53, 208, 127, .45);
  --ease: cubic-bezier(.2, .8, .3, 1);
}
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  background:
    radial-gradient(900px 480px at 85% -120px, rgba(242, 193, 78, .07), transparent 70%),
    radial-gradient(1100px 620px at 10% -180px, rgba(53, 208, 127, .16), transparent 65%),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, .012) 0 64px, transparent 64px 128px),
    var(--bg);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
::selection { background: rgba(53, 208, 127, .35); }
* { scrollbar-width: thin; scrollbar-color: var(--line) transparent; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-thumb { background: var(--line); border-radius: 99px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
h2 { letter-spacing: -.01em; }
h3 { display: flex; align-items: center; gap: .45rem; letter-spacing: .01em; }
.card > h3:first-child::before { content: ''; width: 4px; height: 1em; border-radius: 4px; background: linear-gradient(180deg, var(--accent), var(--gold)); flex-shrink: 0; }

/* barra superior */
.topbar { background: rgba(9, 18, 13, .78); backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px); border-bottom: 0; box-shadow: 0 1px 0 rgba(255, 255, 255, .04), 0 6px 20px -10px rgba(0, 0, 0, .6); }
.topbar::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: linear-gradient(90deg, transparent, rgba(53, 208, 127, .5), rgba(242, 193, 78, .4), transparent); }
.brand { display: inline-flex; align-items: center; gap: .5rem; font-size: 1.15rem; letter-spacing: -.01em; }
.brand .logo { filter: drop-shadow(0 2px 6px rgba(242, 193, 78, .35)); transition: transform .3s var(--ease); }
.brand:hover .logo { transform: rotate(-8deg) scale(1.06); }

/* tarjetas */
.card { border-color: rgba(53, 208, 127, .13); background: linear-gradient(180deg, rgba(31, 56, 43, .92), rgba(19, 35, 27, .92)); box-shadow: var(--shadow); }
.feat, .offers .card, .item { transition: transform .2s var(--ease), border-color .2s, box-shadow .2s; }
.feat:hover, .offers .card:hover { transform: translateY(-3px); border-color: rgba(53, 208, 127, .4); box-shadow: var(--shadow), 0 14px 30px -14px rgba(53, 208, 127, .35); }

/* botones */
.btn { border-radius: 12px; transition: transform .12s var(--ease), background .15s, border-color .15s, box-shadow .2s, filter .15s; }
.btn:hover { box-shadow: 0 0 0 1px rgba(53, 208, 127, .25); }
.btn-primary { position: relative; overflow: hidden; background: linear-gradient(180deg, #48e08f, #1fa862); box-shadow: 0 1px 0 rgba(255, 255, 255, .35) inset, 0 8px 22px -10px rgba(53, 208, 127, .8); text-shadow: 0 1px 0 rgba(255, 255, 255, .25); }
.btn-primary::after { content: ''; position: absolute; inset: 0; background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, .35) 50%, transparent 70%); transform: translateX(-120%); transition: transform .6s var(--ease); pointer-events: none; }
.btn-primary:hover::after { transform: translateX(120%); }
.btn-glow { animation: glow 2.6s ease-in-out infinite; }
@keyframes glow { 0%, 100% { box-shadow: 0 1px 0 rgba(255, 255, 255, .35) inset, 0 8px 22px -10px rgba(53, 208, 127, .8); } 50% { box-shadow: 0 1px 0 rgba(255, 255, 255, .35) inset, 0 10px 34px -6px rgba(53, 208, 127, .95); } }
.btn-ad { box-shadow: 0 1px 0 rgba(255, 255, 255, .4) inset, 0 8px 22px -12px rgba(242, 193, 78, .9); }
.chip { transition: border-color .15s, color .15s, background .15s; }
.chip.sel { background: rgba(53, 208, 127, .12); }

/* portada */
.hero { position: relative; isolation: isolate; padding: 2.75rem 0 1.75rem; }
.hero-pitch { position: absolute; z-index: -1; left: 50%; bottom: 0; width: min(100%, 760px); height: 100%; transform: translateX(-50%); -webkit-mask-image: linear-gradient(180deg, transparent, #000 45%, transparent); mask-image: linear-gradient(180deg, transparent, #000 45%, transparent); }
.hero h1 { letter-spacing: -.03em; font-weight: 900; filter: drop-shadow(0 6px 24px rgba(53, 208, 127, .25)); }
.hero-ball { display: inline-block; filter: drop-shadow(0 10px 14px rgba(0, 0, 0, .5)); }
.hero-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: .5rem; max-width: 520px; margin: 1.6rem auto 0; }
.hero-stats div { display: flex; flex-direction: column; padding: .6rem .3rem; border-radius: 12px; background: rgba(16, 32, 24, .7); border: 1px solid rgba(53, 208, 127, .14); }
.hero-stats b { font-size: 1.45rem; font-weight: 900; color: var(--gold); font-variant-numeric: tabular-nums; line-height: 1.1; }
.hero-stats span { font-size: .7rem; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.feat { padding: 18px; }
.feat i { font-style: normal; font-size: 1.35rem; width: 2.6rem; height: 2.6rem; border-radius: 12px; display: inline-flex; align-items: center; justify-content: center; background: linear-gradient(145deg, rgba(53, 208, 127, .22), rgba(242, 193, 78, .12)); border: 1px solid rgba(53, 208, 127, .25); margin-bottom: .4rem; }
.feat b { font-size: 1.02rem; }

/* pestañas: una sola fila que se desliza en el móvil */
.tabs { position: relative; display: flex; gap: .35rem; overflow-x: auto; padding: 4px; margin: 0 0 16px; background: rgba(9, 18, 13, .6); border: 1px solid rgba(53, 208, 127, .12); border-radius: 14px; scroll-snap-type: x proximity; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tab { flex: 1 0 auto; display: inline-flex; align-items: center; justify-content: center; gap: .35rem; border: 0; background: transparent; padding: .6rem .8rem; border-radius: 10px; scroll-snap-align: start; transition: background .15s, color .15s; }
.tab i { font-style: normal; font-size: .95em; }
.tab:hover { color: var(--text); background: rgba(255, 255, 255, .04); }
.tab.active { background: linear-gradient(180deg, #48e08f, #1fa862); color: #04140b; box-shadow: 0 6px 16px -8px rgba(53, 208, 127, .9); }

/* ficha del jugador */
.pc-ovr { position: relative; overflow: hidden; background: linear-gradient(160deg, #ffe08a, var(--gold) 45%, #b98a1d); box-shadow: 0 1px 0 rgba(255, 255, 255, .5) inset, 0 10px 26px -8px rgba(242, 193, 78, .55); }
.pc-ovr::after { content: ''; position: absolute; inset: -40% -60%; background: linear-gradient(115deg, transparent 40%, rgba(255, 255, 255, .45) 50%, transparent 60%); animation: sheen 5s ease-in-out infinite; }
@keyframes sheen { 0%, 70% { transform: translateX(-60%); } 100% { transform: translateX(60%); } }
.stats > div, .kv > div { transition: background .15s; }
.stats > div { border: 1px solid rgba(53, 208, 127, .08); }
.stats b { color: var(--text); font-variant-numeric: tabular-nums; }
.meter { height: 9px; box-shadow: 0 0 0 1px rgba(255, 255, 255, .04) inset; }
.meter i { border-radius: 99px; box-shadow: 0 0 10px rgba(53, 208, 127, .45); }

/* tablas */
.tbl { font-variant-numeric: tabular-nums; }
.tbl thead th { position: sticky; top: 0; background: rgba(21, 38, 29, .96); text-transform: uppercase; letter-spacing: .04em; font-size: .68rem; }
.tbl tbody tr:nth-child(even) td { background: rgba(255, 255, 255, .018); }
.tbl tbody tr:hover td { background: rgba(53, 208, 127, .06); }
.tbl tr.me td { background: rgba(53, 208, 127, .16) !important; }

/* marcador */
.scoreboard { position: relative; overflow: hidden; border-color: rgba(53, 208, 127, .25); box-shadow: var(--shadow), 0 0 40px -18px rgba(53, 208, 127, .6); }
.scoreboard::before { content: ''; position: absolute; left: 50%; top: 50%; width: 120px; height: 120px; border: 2px solid rgba(255, 255, 255, .05); border-radius: 50%; transform: translate(-50%, -50%); pointer-events: none; }
.sb-score { background: linear-gradient(180deg, #fff, #c9e8d5); -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: none; filter: drop-shadow(0 4px 12px rgba(0, 0, 0, .45)); }
.sb-min { display: inline-block; padding: .05rem .5rem; border-radius: 99px; background: rgba(242, 193, 78, .14); font-variant-numeric: tabular-nums; }
.mprog { height: 6px; }
.mprog i { background: linear-gradient(90deg, var(--accent2), var(--accent), var(--gold)); box-shadow: 0 0 10px rgba(53, 208, 127, .6); }
.feed li { border-left: 3px solid transparent; background: rgba(21, 38, 29, .85); }
.feed .goal-me { border-left-color: var(--accent); background: linear-gradient(90deg, rgba(53, 208, 127, .26), rgba(53, 208, 127, .08)); }
.feed .goal-op { border-left-color: var(--red); background: linear-gradient(90deg, rgba(239, 91, 91, .22), rgba(239, 91, 91, .06)); }
.feed .card-y { border-left-color: var(--gold); }
.feed .card-r { border-left-color: var(--red); }

/* previa */
.vs-mid { width: 3rem; height: 3rem; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: radial-gradient(circle, rgba(242, 193, 78, .22), transparent 70%); }
.vs-team .crest { transition: transform .3s var(--ease); }
.vs-team:hover .crest { transform: scale(1.08) rotate(-3deg); }

/* modales */
.modal { background: rgba(3, 8, 5, .66); backdrop-filter: blur(5px); -webkit-backdrop-filter: blur(5px); }
.modal-box { border-color: rgba(53, 208, 127, .5); background: linear-gradient(180deg, #213f2f, #14251c 70%); box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .8), 0 0 0 1px rgba(255, 255, 255, .03) inset; animation: pop .25s var(--ease); }
.dec-opt { border-radius: 12px; text-align: left; }
.dec-opt:hover { border-color: var(--accent); background: rgba(53, 208, 127, .1); transform: translateX(3px); }
.rating { box-shadow: 0 10px 28px -10px rgba(0, 0, 0, .6), 0 0 0 4px rgba(255, 255, 255, .05); }

/* banner fijo de abajo: una tarjeta flotante en lugar de una franja negra de lado a lado */
.ad-sticky { background: none; border-top: 0; padding: 0 0 6px; pointer-events: none; }
.ad-sticky-in { pointer-events: auto; display: flex; flex-direction: column; align-items: center; padding: 3px 6px 6px; border-radius: 12px 12px 10px 10px;
  background: rgba(14, 28, 20, .9); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); border: 1px solid rgba(53, 208, 127, .22); box-shadow: 0 -6px 24px -10px rgba(0, 0, 0, .7); }
.ad-sticky-in .ad-tag { margin: 0 0 2px; font-size: .58rem; opacity: .8; }
.ad-sticky-slot { line-height: 0; border-radius: 6px; overflow: hidden; }
.top-actions { display: flex; gap: .4rem; align-items: center; }
#soundBtn { padding: .35rem .6rem; line-height: 1; }

/* selector de liga: banderas y, debajo, las ligas del país */
.lpick-flags { display: flex; flex-wrap: wrap; justify-content: center; gap: .5rem; }
.lp-flag { display: flex; flex-direction: column; align-items: center; gap: .3rem; min-width: 74px; padding: .55rem .5rem .45rem; border-radius: 12px; border: 1px solid var(--line); background: var(--bg2); color: var(--muted); cursor: pointer; font: inherit; font-size: .75rem; font-weight: 700; transition: transform .15s var(--ease), border-color .15s, color .15s, background .15s; }
.lp-flag:hover { transform: translateY(-2px); color: var(--text); border-color: rgba(53, 208, 127, .45); }
.lp-flag.sel { color: var(--text); border-color: var(--accent); background: rgba(53, 208, 127, .12); box-shadow: 0 6px 18px -10px rgba(53, 208, 127, .9); }
.flag { display: block; border-radius: 3px; box-shadow: 0 0 0 1px rgba(255, 255, 255, .12), 0 2px 6px rgba(0, 0, 0, .4); }
.lp-flag:not(.sel) .flag { filter: saturate(.75); }
.lpick-leagues { margin-top: .8rem; padding-top: .8rem; border-top: 1px solid var(--line); animation: fadein .25s; }
@media (max-width: 520px) { .lp-flag { min-width: 0; flex: 1 0 22%; padding: .45rem .3rem; font-size: .68rem; } }

/* tienda: 8 mejoras en filas completas (4 · 2 · 1 columnas) */
.offers.shop-grid { grid-template-columns: repeat(4, 1fr); gap: 12px; }
.offers.shop-grid .card { padding: 14px; }
.offers.shop-grid .card h3 { font-size: .95rem; }
@media (max-width: 960px) { .offers.shop-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 460px) { .offers.shop-grid { grid-template-columns: 1fr; } }

/* gala del Balón de Oro: 3.º, 2.º y, tras el redoble, el ganador (los retrasos van en línea en cada .gala-step) */
.modal-box:has(.gala) { max-width: 640px; background: radial-gradient(120% 80% at 50% 0%, #3a2f12 0%, #14251c 55%, #0b1510 100%); border-color: rgba(242, 193, 78, .6); }
.gala { position: relative; text-align: center; overflow: hidden; }
.gala-lights { position: absolute; inset: -40% -20% auto; height: 120%; pointer-events: none;
  background: conic-gradient(from 200deg at 50% 0%, transparent 0 10deg, rgba(255, 236, 170, .14) 14deg, transparent 20deg 160deg, rgba(255, 236, 170, .12) 166deg, transparent 172deg);
  animation: lights 6s ease-in-out infinite alternate; }
@keyframes lights { from { transform: rotate(-8deg); } to { transform: rotate(8deg); } }
.gala-title { position: relative; color: var(--gold); font-size: clamp(1.2rem, 4.5vw, 1.6rem); margin: .2rem 0 1rem; text-shadow: 0 2px 12px rgba(0, 0, 0, .6); }
.gala-podium { position: relative; display: flex; align-items: flex-end; justify-content: center; gap: 10px; min-height: 250px; }
.gala-step { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: .2rem; opacity: 0; transform: translateY(24px) scale(.9);
  animation: galaIn .7s var(--ease, ease-out) forwards; }
.gala-step.place-2 { order: 1; } .gala-step.place-1 { order: 2; } .gala-step.place-3 { order: 3; }
@keyframes galaIn { to { opacity: 1; transform: none; } }
.gala-medal { font-size: 2rem; line-height: 1; }
.place-1 .gala-medal { font-size: 2.8rem; filter: drop-shadow(0 0 14px rgba(242, 193, 78, .8)); }
.gala-name { font-size: .95rem; line-height: 1.2; overflow-wrap: anywhere; }
.place-1 .gala-name { font-size: 1.15rem; color: var(--gold); }
.gala-team { font-size: .75rem; color: var(--muted); display: inline-flex; align-items: center; }
.gala-stats { font-size: .72rem; color: var(--muted); }
.gala-block { width: 100%; margin-top: .35rem; border-radius: 10px 10px 0 0; display: flex; align-items: center; justify-content: center; font-weight: 900; font-size: 1.6rem;
  color: rgba(0, 0, 0, .45); box-shadow: 0 -1px 0 rgba(255, 255, 255, .35) inset; }
.place-1 .gala-block { height: 96px; background: linear-gradient(180deg, #ffe08a, #c9951f); box-shadow: 0 0 30px rgba(242, 193, 78, .45); }
.place-2 .gala-block { height: 68px; background: linear-gradient(180deg, #e9eef2, #9aa6b0); }
.place-3 .gala-block { height: 50px; background: linear-gradient(180deg, #f0b47a, #a8652c); }
.gala-drum { position: relative; margin: .8rem 0 0; font-weight: 800; color: var(--text); opacity: 0; animation: galaDrum 1.6s ease-in-out 3.3s forwards; }
@keyframes galaDrum { 0% { opacity: 0; transform: scale(.9); } 30%, 80% { opacity: 1; transform: scale(1.05); } 100% { opacity: 0; } }
.gala-final { position: relative; margin: -1.2rem 0 0; font-size: 1.25rem; font-weight: 900; color: var(--gold); opacity: 0; animation: galaIn .6s ease-out 5.3s forwards; }
.gala-me .gala-final { font-size: 1.4rem; text-shadow: 0 0 18px rgba(242, 193, 78, .6); }
.gala-skip .gala-step, .gala-skip .gala-final { animation: none; opacity: 1; transform: none; }
.gala-skip .gala-drum { display: none; }
.gala-skip .gala-final { margin-top: .8rem; }
.gala .goal-burst b { font-size: 4rem; }
@media (max-width: 420px) { .gala-podium { gap: 6px; min-height: 230px; } .gala-name { font-size: .8rem; } .place-1 .gala-name { font-size: .95rem; } }

/* dificultad: 3 tarjetas en fila (en el móvil, una debajo de otra) */
.choice-grid.diff-grid { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 560px) { .choice-grid.diff-grid { grid-template-columns: 1fr; } }

/* mercado: pedir un club */
.req-row { display: flex; gap: .5rem; flex-wrap: wrap; }
.req-row select { flex: 1 1 220px; width: auto; }
.req-msg { margin: .7rem 0 0; padding: .55rem .75rem; border-radius: 10px; font-size: .92rem; }
.req-msg.ok { background: rgba(53, 208, 127, .14); color: var(--accent); }
.req-msg.ko { background: rgba(239, 91, 91, .12); color: #ffb3b3; }

/* calendario */
.cal { list-style: none; margin: .6rem 0 0; padding: 0; }
.cal-row { display: grid; grid-template-columns: 2.6rem minmax(0, 1.2fr) minmax(0, 1fr) 5.5rem; gap: .6rem; align-items: center; padding: .5rem .6rem; border-radius: 10px; font-size: .88rem; border-left: 3px solid transparent; }
.cal-row:nth-child(even) { background: rgba(255, 255, 255, .02); }
.cal-row.next { background: rgba(242, 193, 78, .1); border-left-color: var(--gold); }
.cal-row.r-W { border-left-color: var(--accent); } .cal-row.r-L { border-left-color: var(--red); } .cal-row.r-D { border-left-color: var(--muted); }
.cal-row.tbd { opacity: .6; }
.cal-w { color: var(--muted); font-size: .75rem; font-variant-numeric: tabular-nums; }
.cal-comp { color: var(--muted); font-size: .78rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cal-opp { display: flex; align-items: center; gap: .3rem; min-width: 0; overflow: hidden; white-space: nowrap; }
.cal-ha { font-style: normal; font-size: .65rem; font-weight: 800; color: var(--muted); border: 1px solid var(--line); border-radius: 5px; padding: 0 .3rem; }
.cal-res { text-align: right; font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.cal-badge { display: inline-block; width: 1.3rem; text-align: center; border-radius: 5px; font-size: .72rem; color: #04140b; }
.cal-badge.W { background: var(--accent); } .cal-badge.D { background: var(--muted); } .cal-badge.L { background: var(--red); color: #fff; }
.cal-next { color: var(--gold); font-size: .78rem; }
@media (max-width: 560px) { .cal-row { grid-template-columns: 2.2rem minmax(0, 1fr) 4.6rem; } .cal-comp { grid-column: 2 / 4; grid-row: 2; } }
/* archivo de temporadas */
.tbl tr.was-me td { background: rgba(242, 193, 78, .14) !important; font-weight: 700; }
.hist-ko li.was-me { background: rgba(242, 193, 78, .12); border-radius: 8px; }

/* prensa y logros tras el partido */
.press { margin: .8rem auto 0; max-width: 520px; padding: .7rem .9rem; border-radius: 12px; background: #f3efe6; color: #1b1b1b; text-align: left;
  box-shadow: 0 8px 20px -10px rgba(0, 0, 0, .6); transform: rotate(-.6deg); font-family: Georgia, "Times New Roman", serif; }
.press-src { display: block; font: 800 .68rem system-ui, sans-serif; letter-spacing: .08em; text-transform: uppercase; color: #8a1d1d; margin-bottom: .2rem; }
.press b { font-size: 1.05rem; line-height: 1.25; }
.ach-toast { display: grid; gap: .4rem; max-width: 420px; margin: .7rem auto 0; }
.ach-toast > div { display: flex; align-items: center; gap: .6rem; padding: .5rem .7rem; border-radius: 12px; text-align: left;
  background: linear-gradient(90deg, rgba(242, 193, 78, .28), rgba(242, 193, 78, .08)); border: 1px solid rgba(242, 193, 78, .5); animation: pop .4s var(--ease); }
.ach-toast i { font-style: normal; font-size: 1.6rem; }
.ach-toast small { display: block; font-size: .65rem; text-transform: uppercase; letter-spacing: .06em; color: var(--gold); }
/* vestuario */
.locker-btns { display: grid; grid-template-columns: 1fr 1fr; gap: .45rem; margin-top: .6rem; }
.locker-btns .btn { font-size: .85rem; padding: .55rem .6rem; }
@media (max-width: 460px) { .locker-btns { grid-template-columns: 1fr; } }
.locker-msg { margin: .6rem 0 0; padding: .5rem .7rem; border-radius: 10px; background: var(--bg2); font-size: .88rem; }
/* logros */
.ach-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: .5rem; }
.ach { display: flex; flex-direction: column; align-items: center; text-align: center; gap: .2rem; padding: .6rem .4rem; border-radius: 12px; background: var(--bg2); border: 1px solid var(--line); font-size: .75rem; }
.ach i { font-style: normal; font-size: 1.5rem; }
.ach.off { opacity: .35; filter: grayscale(1); }
.ach.on { border-color: rgba(242, 193, 78, .55); background: linear-gradient(180deg, rgba(242, 193, 78, .16), var(--bg2)); }
.ach small { color: var(--muted); }
/* récords */
.rec-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; }
@media (max-width: 520px) { .rec-grid { grid-template-columns: 1fr; } }
.rec-line { font-size: .85rem; color: var(--muted); margin-top: .5rem; }
.rec-line b { color: var(--gold); }

/* tus carreras (3 huecos) */
.slots { max-width: 900px; margin: 0 auto 16px; }
.slot-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: .6rem; }
@media (max-width: 640px) { .slot-grid { grid-template-columns: 1fr; } }
.slot { display: flex; flex-direction: column; gap: .25rem; padding: .8rem; border-radius: 12px; background: var(--bg2); border: 1px solid var(--line); }
.slot.cur { border-color: var(--accent); box-shadow: 0 0 0 1px rgba(53, 208, 127, .25) inset; }
.slot.empty { border-style: dashed; opacity: .85; }
.slot-name { font-weight: 800; font-size: 1.05rem; overflow-wrap: anywhere; }
.slot .row-btns { justify-content: flex-start; margin-top: .4rem; }

/* lesión con decisión */
.inj-card { max-width: 560px; margin: .8rem auto 0; padding: .8rem; border-radius: 12px; text-align: left; background: rgba(239, 91, 91, .1); border: 1px solid rgba(239, 91, 91, .45); }
.inj-card h3 { color: #ffb3b3; margin-top: 0; }
.inj-card.done { background: var(--bg2); border-color: var(--line); }

/* partidos especiales */
.special { margin: .6rem 0; padding: .55rem .8rem; border-radius: 10px; font-weight: 800; animation: pulseGlow 2s ease-in-out infinite; }
.special-derby { background: linear-gradient(90deg, rgba(239, 91, 91, .25), rgba(239, 91, 91, .08)); color: #ffc9c9; border: 1px solid rgba(239, 91, 91, .5); }
.special-final { background: linear-gradient(90deg, rgba(242, 193, 78, .3), rgba(242, 193, 78, .08)); color: var(--gold); border: 1px solid rgba(242, 193, 78, .55); }
@keyframes pulseGlow { 50% { box-shadow: 0 0 18px -4px currentColor; } }
.feed .late { border-left-color: var(--gold) !important; background: linear-gradient(90deg, rgba(242, 193, 78, .3), rgba(53, 208, 127, .12)) !important; }

/* pretemporada */
.pre { max-width: 620px; margin: 0 auto 16px; }
.pre-steps { display: flex; gap: .4rem; flex-wrap: wrap; margin: .5rem 0 1rem; }
.pre-steps span { padding: .3rem .6rem; border-radius: 99px; background: var(--bg2); font-size: .8rem; color: var(--muted); border: 1px solid var(--line); }
.pre-steps .cur { color: var(--text); border-color: var(--accent); }
.pre-steps .done { color: var(--accent); }
.pre-bar { height: 26px; margin: .8rem 0 1rem; }
.btn.react { min-height: 120px; font-size: 1.5rem; font-weight: 900; background: #5a2020; border-color: #7a2a2a; }
.btn.react.go { background: linear-gradient(180deg, #48e08f, #1fa862); color: #04140b; border-color: transparent; }
.pre-scores { display: grid; grid-template-columns: repeat(3, 1fr); gap: .6rem; margin: 1rem 0; }
.pre-scores div { display: flex; flex-direction: column; align-items: center; padding: .8rem .4rem; border-radius: 12px; background: var(--bg2); }
.pre-scores i { font-style: normal; font-size: 1.6rem; }
.pre-scores b { font-size: 1.8rem; font-weight: 900; color: var(--gold); }
.pre-scores span { font-size: .75rem; color: var(--muted); }
.pre-verdict { text-align: center; font-weight: 800; font-size: 1.1rem; }

/* historia familiar */
.fam { border: 1px solid var(--line); border-radius: 12px; padding: .6rem .8rem; margin-top: .5rem; background: var(--bg2); }
.fam summary { cursor: pointer; list-style: none; }
.fam summary::-webkit-details-marker { display: none; }
.fam summary::before { content: '▸ '; color: var(--accent); }
.fam[open] summary::before { content: '▾ '; }

/* redes sociales, duplas, Mundial de Clubes, repeticiones y nube */
.soc-feed { display: grid; gap: .5rem; margin: .7rem 0; }
.soc-post { background: var(--bg2); border: 1px solid var(--line); border-radius: 12px; padding: .55rem .75rem; text-align: left; }
.soc-post p { margin: .25rem 0 .2rem; font-size: .92rem; }
.soc-head { display: flex; align-items: center; gap: .4rem; font-size: .85rem; }
.soc-head i { font-style: normal; }
.soc-head b { color: #7fb8ff; }
.soc-rival .soc-head b { color: #ef8b8b; }
.soc-troll { opacity: .85; }
.cwc-group { margin: .35rem 0; }
.cwc-group > b { font-size: .8rem; color: var(--muted); display: block; margin-bottom: .15rem; }
.cwc-teams { display: flex; flex-wrap: wrap; gap: .4rem .8rem; }
.cwc-teams span { font-size: .85rem; }
.cwc-teams .mine { font-weight: 800; color: var(--accent); }
.replay-btns { display: flex; flex-wrap: wrap; justify-content: center; gap: .4rem; margin: .6rem 0; }
.rp-canvas { width: 100%; max-width: 480px; height: auto; aspect-ratio: 8 / 5; display: block; margin: .5rem auto; border-radius: 10px; background: #24803f; }
.cloud-code { font: 800 1.5rem/1.2 ui-monospace, monospace; letter-spacing: .08em; text-align: center; padding: .7rem; margin: .6rem 0; border-radius: 12px; background: var(--bg2); border: 1px dashed var(--accent); user-select: all; }
.cloud input, .cloud select { width: 100%; }
.cloud #cloudCode { font-family: ui-monospace, monospace; text-transform: uppercase; letter-spacing: .06em; }

/* "Cargando…" en los cálculos largos: invisible al principio, aparece si tarda más de 0,3 s */
.busy { position: fixed; inset: 0; z-index: 9000; display: grid; place-items: center; background: rgba(5, 14, 9, .72); opacity: 0; animation: busyIn .25s .3s forwards; cursor: progress; }
.busy-box { display: flex; flex-direction: column; align-items: center; gap: .4rem; padding: 1.4rem 1.8rem; border-radius: 16px; background: var(--card); border: 1px solid var(--line); text-align: center; max-width: 320px; }
.busy-box b { font-size: 1.1rem; color: var(--accent); }
.busy-box span { font-size: .9rem; color: var(--muted); }
.busy-ball { font-style: normal; font-size: 2.2rem; display: inline-block; animation: busySpin 1s linear infinite; will-change: transform; }
@keyframes busyIn { to { opacity: 1; } }
@keyframes busySpin { to { transform: rotate(360deg); } }

/* pizarra táctica (previa) */
.form-board { width: 100%; max-width: 230px; display: block; margin: .4rem auto .6rem; }
.fb-p circle { fill: #d9e8dd; stroke: rgba(0,0,0,.4); stroke-width: 1; }
.fb-p.me circle { fill: var(--accent); stroke: #fff; stroke-width: 2; }
.fb-p.friend circle { fill: var(--blue); stroke: #fff; stroke-width: 2; }
.fb-p text { font: 800 9px system-ui, sans-serif; text-anchor: middle; fill: #10241a; }
.fb-p text.fb-n { font: 700 8.5px system-ui, sans-serif; fill: #fff; paint-order: stroke; stroke: rgba(0,0,0,.55); stroke-width: 2.4px; }

/* campo en directo del partido */
.live-wrap { margin: .6rem auto .2rem; max-width: 460px; }
.live-pitch { width: 100%; height: auto; display: block; border-radius: 10px; box-shadow: inset 0 0 0 1px rgba(255,255,255,.08); }
.lp-dot { transition: transform var(--lpt, 420ms) cubic-bezier(.45,.05,.35,1); }
.lp-me { fill: var(--accent); stroke: rgba(0,0,0,.45); stroke-width: 1; }
.lp-op { fill: #d04a3c; stroke: rgba(0,0,0,.45); stroke-width: 1; }
.lp-you { fill: #fff; stroke: var(--accent); stroke-width: 2.4; transition: transform var(--lpt, 420ms) cubic-bezier(.45,.05,.35,1), opacity .3s; }
.lp-ball { fill: #fff; stroke: #111; stroke-width: 1; filter: drop-shadow(0 1px 1px rgba(0,0,0,.6)); }
.lp-flash { font: 900 22px system-ui, sans-serif; fill: #f2c14e; opacity: 0; paint-order: stroke; stroke: rgba(0,0,0,.6); stroke-width: 3px; }
.lp-flash.on { animation: lpFlash 1.6s ease-out; }
@keyframes lpFlash { 0% { opacity: 0; } 12% { opacity: 1; } 75% { opacity: 1; } 100% { opacity: 0; } }
.live-dom { display: flex; align-items: center; gap: .5rem; font-size: .75rem; color: var(--muted); margin-top: .3rem; }
.dom-bar { flex: 1; height: 6px; border-radius: 4px; background: #d04a3c; overflow: hidden; }
.dom-bar i { display: block; height: 100%; width: 50%; background: var(--accent); transition: width .6s; }
.dec-canvas { max-width: 420px; }

/* pie */
.foot { opacity: .85; }
.foot a:hover, .foot .link-btn:hover { color: var(--accent); }

@media (max-width: 520px) {
  .hero { padding-top: 1.6rem; }
  .hero-stats b { font-size: 1.2rem; }
  .hero-stats span { font-size: .6rem; }
  .tab { padding: .55rem .7rem; font-size: .9rem; }
  .chips .chip { padding: .3rem .65rem; font-size: .8rem; }
  .chip-label { min-width: 0; width: 100%; margin-top: .2rem; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}

/* botón para volver al menú principal desde la temporada (también en la app, que no tiene barra de direcciones) */
.hub-menu { margin: 22px 0 10px; }
/* en móviles estrechos el botón 🏠 Menú de la cabecera se queda en icono (si no, no cabe junto al título) */
@media (max-width: 420px) { #menuBtn .mb-label { display: none; } }

/* aviso de versión nueva (js/update.js, app de Android) */
.upd-box { position: fixed; inset: 0; z-index: 9999; display: flex; align-items: center; justify-content: center; padding: 16px; background: rgba(0, 0, 0, .6); }
.upd-card { max-width: 420px; width: 100%; text-align: center; }

/* ---------- App de Android a pantalla completa (edge-to-edge) ----------
   En los Android y WebView nuevos la app se dibuja también debajo de la barra de estado y de la de navegación:
   se deja ese hueco. env() lo da el WebView; --safe-area-inset-* lo pone Capacitor (SystemBars). En la web valen 0. */
:root {
  --sat: max(env(safe-area-inset-top, 0px), var(--safe-area-inset-top, 0px));
  --sab: max(env(safe-area-inset-bottom, 0px), var(--safe-area-inset-bottom, 0px));
  --sal: max(env(safe-area-inset-left, 0px), var(--safe-area-inset-left, 0px));
  --sar: max(env(safe-area-inset-right, 0px), var(--safe-area-inset-right, 0px));
}
.topbar { padding-top: calc(.6rem + var(--sat)); padding-left: calc(16px + var(--sal)); padding-right: calc(16px + var(--sar)); }
.container { padding-left: calc(16px + var(--sal)); padding-right: calc(16px + var(--sar)); }
.foot { padding-bottom: calc(1.5rem + var(--sab)); }
.modal, .upd-box { padding-top: calc(16px + var(--sat)); padding-bottom: calc(16px + var(--sab)); }
.consent-bar { bottom: calc(12px + var(--sab)); }
