/* ACGT — identidad: los cuatro colores de la secuenciación Sanger */
:root {
  --bg: #F5F2EA; --surface: #FFFFFF; --surface2: #EFEBE0; --ink: #141A22; --muted: #667082; --line: #E2DDCF;
  --A: #2DAA5B; --C: #2C74DB; --G: #F0A315; --T: #E2474C;
  --A-soft: #DDF3E5; --C-soft: #DCE8FB; --G-soft: #FCEFCF; --T-soft: #FBDFE0;
  --ok: var(--A); --bad: var(--T); --accent: #4B50E6; --on-color: #fff; --on-G: #2B1E00;
  --shadow: 0 1px 0 rgba(20,26,34,.06), 0 8px 24px -12px rgba(20,26,34,.18);
  --r: 18px; --r-sm: 12px;
  --font-d: 'Gabarito', 'Trebuchet MS', system-ui, sans-serif;
  --font-b: 'Figtree', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-m: 'DM Mono', ui-monospace, Menlo, monospace;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #0D1117; --surface: #161C25; --surface2: #1D2530; --ink: #EEF1F5; --muted: #8E99AA; --line: #263040;
  --A: #3FCB7A; --C: #5B9BFF; --G: #FFBE3D; --T: #FF6B70;
  --A-soft: #12301F; --C-soft: #15284A; --G-soft: #3A2C0A; --T-soft: #3B1719;
  --accent: #7C80FF; --plate: #E9E3D5; --on-G: #1E1500;
  --shadow: 0 1px 0 rgba(0,0,0,.4), 0 10px 28px -14px rgba(0,0,0,.7);
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0D1117; --surface: #161C25; --surface2: #1D2530; --ink: #EEF1F5; --muted: #8E99AA; --line: #263040;
    --A: #3FCB7A; --C: #5B9BFF; --G: #FFBE3D; --T: #FF6B70;
    --A-soft: #12301F; --C-soft: #15284A; --G-soft: #3A2C0A; --T-soft: #3B1719;
    --accent: #7C80FF; --plate: #E9E3D5; --on-G: #1E1500; color-scheme: dark;
    --shadow: 0 1px 0 rgba(0,0,0,.4), 0 10px 28px -14px rgba(0,0,0,.7);
  }
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--font-b); font-size: 16px; line-height: 1.4; }
body { min-height: 100dvh; overscroll-behavior-y: none; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; padding: 0; }
input { font: inherit; color: inherit; }
h1, h2, h3 { font-family: var(--font-d); margin: 0; line-height: 1.1; letter-spacing: -.01em; }
.mono { font-family: var(--font-m); }
.muted { color: var(--muted); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
#app { max-width: 520px; margin: 0 auto; min-height: 100dvh; display: flex; flex-direction: column; position: relative; }
.view { flex: 1; padding: 16px 16px 96px; animation: rise .28s ease both; }
.view.noNav { padding-bottom: 24px; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { * { animation-duration: .001s !important; transition-duration: .001s !important; } }

/* Botones */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 52px; padding: 0 22px; border-radius: 16px;
  font-family: var(--font-d); font-weight: 700; font-size: 18px; background: var(--ink); color: var(--bg); box-shadow: 0 4px 0 rgba(0,0,0,.28); transition: transform .08s, box-shadow .08s; width: 100%; }
.btn:active:not(:disabled) { transform: translateY(3px); box-shadow: 0 1px 0 rgba(0,0,0,.28); }
.btn:disabled { opacity: .45; cursor: default; }
.btn.alt { background: var(--surface); color: var(--ink); border: 2px solid var(--line); box-shadow: 0 3px 0 var(--line); }
.btn.go { background: var(--A); color: #fff; box-shadow: 0 4px 0 color-mix(in srgb, var(--A) 60%, #000); }
.btn.sm { min-height: 40px; font-size: 15px; padding: 0 14px; width: auto; border-radius: 12px; }
.btn.ghost { background: transparent; color: var(--muted); box-shadow: none; border: 0; min-height: 44px; font-size: 15px; font-weight: 600; }
.card { background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); padding: 16px; border: 1px solid var(--line); }
.row { display: flex; align-items: center; gap: 10px; }
.between { justify-content: space-between; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.grow { flex: 1; min-width: 0; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px; border-radius: 999px; background: var(--surface2); font-weight: 700; font-size: 14px; }
.ico { width: 22px; height: 22px; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* Cabecera */
.top { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.avatar { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; font-family: var(--font-d); font-weight: 800; font-size: 22px; color: #fff; flex: none; }
.lvl { height: 8px; border-radius: 99px; background: var(--surface2); overflow: hidden; margin-top: 5px; }
.lvl > i { display: block; height: 100%; background: linear-gradient(90deg, var(--A), var(--C)); border-radius: 99px; transition: width .6s cubic-bezier(.2,.8,.2,1); }
.pill { display: inline-flex; align-items: center; gap: 5px; padding: 7px 11px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); font-weight: 800; font-size: 15px; box-shadow: var(--shadow); }
.pill.fire { color: var(--G); } .pill.fire.cold { color: var(--muted); }
.pill.atp { color: var(--C); }
.flame-risk { animation: flick 1s ease-in-out infinite; }
@keyframes flick { 50% { transform: scale(1.15) rotate(-6deg); } }

/* Reto del día */
.hero { position: relative; overflow: hidden; border-radius: 24px; padding: 20px 18px 18px; color: #fff; background: #141A22; box-shadow: var(--shadow); }
:root[data-theme="dark"] .hero { background: #1E2735; }
.hero h2 { font-size: 30px; margin: 2px 0 4px; }
.hero .kicker { font-family: var(--font-m); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; opacity: .7; }
.hero .strandbar { display: flex; gap: 4px; margin: 14px 0 16px; }
.hero .strandbar i { height: 8px; flex: 1; border-radius: 99px; }
.hero .btn { background: #fff; color: #141A22; box-shadow: 0 4px 0 rgba(255,255,255,.35); }
.hero .sub { opacity: .8; font-size: 14px; }
.hero.done { background: linear-gradient(160deg, #1B3A2A, #141A22); }
.dots { display: flex; justify-content: space-between; gap: 6px; margin-top: 14px; }
.dot { flex: 1; text-align: center; font-size: 11px; font-weight: 700; opacity: .85; }
.dot b { display: block; width: 28px; height: 28px; margin: 0 auto 3px; border-radius: 50%; border: 2px solid rgba(255,255,255,.35); display: grid; place-items: center; }
.dot.done b { background: var(--A); border-color: var(--A); } .dot.perfect b { background: var(--G); border-color: var(--G); color: #2B1E00; }
.dot.today b { border-color: #fff; border-style: dashed; } .dot.missed b { opacity: .4; }
.pattern { display: flex; gap: 5px; }
.pattern i { width: 22px; height: 22px; border-radius: 6px; }
.pattern .G { background: var(--A); } .pattern .Y { background: var(--G); } .pattern .R { background: var(--T); }
.proof { font-size: 13px; opacity: .85; margin-top: 10px; }
.tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.tile { text-align: left; padding: 14px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 6px; min-height: 108px; position: relative; overflow: hidden; }
.tile h3 { font-size: 18px; } .tile p { margin: 0; font-size: 13px; color: var(--muted); }
.tile .badgeN { position: absolute; top: 10px; right: 10px; background: var(--T); color: #fff; font-weight: 800; font-size: 12px; min-width: 24px; height: 24px; border-radius: 99px; display: grid; place-items: center; padding: 0 6px; }
.tile .i { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; color: #fff; }
.tile:disabled { opacity: .5; }
.groupbar { height: 14px; border-radius: 99px; overflow: hidden; display: flex; background: var(--surface2); }
.groupbar i { display: block; height: 100%; transition: width .6s; }
.sectitle { font-family: var(--font-d); font-weight: 800; font-size: 20px; margin: 20px 2px 10px; }

/* Navegación */
.nav { position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); width: 100%; max-width: 520px; display: grid; grid-template-columns: repeat(5, 1fr);
  background: color-mix(in srgb, var(--surface) 92%, transparent); backdrop-filter: blur(10px); border-top: 1px solid var(--line); padding: 6px 6px calc(6px + env(safe-area-inset-bottom)); z-index: 20; }
.nav a { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 0; font-size: 11px; font-weight: 700; color: var(--muted); text-decoration: none; border-radius: 12px; }
.nav a.on { color: var(--ink); } .nav a.on .ico { stroke: var(--accent); }

/* Ronda ------------------------------------------------------------------
   Color de la pregunta (--cell) = tipo de pregunta, nunca acierto/fallo.
   Verde y rojo se reservan para el resultado. */
.rbar { display: flex; align-items: center; gap: 10px; }
.rbar > .btn.ghost { width: 40px; min-height: 40px; padding: 0; flex: none; }
.strand { display: flex; gap: 4px; flex: 1; min-width: 0; }
.strand i { flex: 1; min-width: 0; height: 16px; border-radius: 99px; background: var(--surface2); border: 2px solid transparent; display: grid; place-items: center; transition: background .3s, border-color .3s; }
.strand i .ico { width: 11px; height: 11px; stroke: #fff; stroke-width: 3.5; }
.strand.many i { height: 10px; } .strand.many i .ico { display: none; }
.strand i.ok { background: var(--A); }
.strand i.fixed { background: var(--A); border-color: var(--G); }
.strand i.bad { background: var(--T); }
.strand i.current { background: var(--surface); border-color: var(--ink); animation: pulse 1.2s ease-in-out infinite; }
.strand i.repair:not(.ok):not(.bad):not(.fixed):not(.current) { border: 1.5px dashed color-mix(in srgb, var(--muted) 60%, transparent); background: transparent; }
@keyframes pulse { 50% { transform: scaleY(1.35); } }
.score { font-family: var(--font-d); font-weight: 900; font-size: 18px; padding: 6px 12px; border-radius: 99px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); min-width: 52px; text-align: center; flex: none; }
.combo { position: absolute; right: 18px; top: 58px; font-family: var(--font-d); font-weight: 900; font-size: 20px; color: var(--G); transform-origin: right; text-shadow: 0 2px 0 color-mix(in srgb, var(--G) 25%, transparent); }
.combo.pop { animation: pop .35s cubic-bezier(.2,1.6,.4,1); }
@keyframes pop { from { transform: scale(.4); opacity: 0; } to { transform: none; opacity: 1; } }
.rinfo { display: flex; justify-content: space-between; align-items: center; font-size: 13px; font-weight: 700; color: var(--muted); margin-top: 10px; gap: 8px; }
.rcount { display: flex; gap: 10px; font-family: var(--font-m); } .rcount .okc { color: var(--A); } .rcount .badc { color: var(--T); }
.trow { display: flex; align-items: center; gap: 10px; margin: 10px 0 14px; }
.timer { flex: 1; height: 8px; border-radius: 99px; background: var(--surface2); overflow: hidden; }
.timer > i { display: block; height: 100%; width: 100%; background: var(--cell, var(--C)); border-radius: 99px; transform-origin: left; }
.timer.low > i { background: var(--G); }
.tnum { font-family: var(--font-m); font-weight: 700; font-size: 14px; min-width: 42px; text-align: right; color: var(--muted); }
.trow.low .tnum { color: #B77800; animation: flick 1s ease-in-out infinite; }
:root[data-theme="dark"] .trow.low .tnum { color: var(--G); }

.qcard { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: 22px; padding: 22px 18px 18px; box-shadow: inset 0 5px 0 var(--cell, var(--C)), var(--shadow); transition: background .2s, border-color .2s; }
.qkind { display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-m); font-size: 11.5px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; color: var(--cell, var(--C)); background: color-mix(in srgb, var(--cell, var(--C)) 12%, var(--surface)); padding: 4px 10px; border-radius: 99px; }
.qkind .ico { width: 15px; height: 15px; }
.qprompt { font-family: var(--font-d); font-size: 21px; font-weight: 600; line-height: 1.28; margin-top: 12px; overflow-wrap: break-word; hyphens: auto; }
.qprompt.long { font-size: 19px; } .qprompt.xlong { font-size: 17.5px; line-height: 1.32; }
.qprompt.term { font-size: 28px; font-weight: 800; line-height: 1.15; hyphens: manual; }
.qprompt.term.long { font-size: 23px; }

.opts { display: grid; gap: 10px; margin-top: 16px; }
.opt { position: relative; display: flex; align-items: center; text-align: left; min-height: 56px; padding: 12px 44px 12px 52px; border-radius: 16px; min-width: 0;
  background: var(--surface); color: var(--ink); border: 2px solid var(--line); border-bottom: 5px solid color-mix(in srgb, var(--c) 70%, var(--line));
  font-weight: 700; font-size: 17px; line-height: 1.25; overflow-wrap: break-word; transition: transform .08s, border-color .15s, background .2s, opacity .25s; }
.opt::before { content: attr(data-b); position: absolute; left: 11px; top: 50%; transform: translateY(-50%); width: 30px; height: 30px; border-radius: 9px; background: var(--c); color: #fff;
  display: grid; place-items: center; font-family: var(--font-m); font-weight: 700; font-size: 15px; }
.opt[data-b="G"]::before { color: var(--on-G); }
@media (hover: hover) { .opt:hover:not(:disabled) { border-color: var(--ink); } }
.opt:active:not(:disabled) { transform: translateY(3px); border-bottom-width: 2px; margin-bottom: 3px; }
.opt.defopt { font-size: 15px; font-weight: 600; line-height: 1.32; }
.opt > .ico { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); width: 24px; height: 24px; stroke: #fff; stroke-width: 3.5; }
.opt.removed { opacity: .18; pointer-events: none; text-decoration: line-through; }
.opt.right { background: var(--A); border-color: var(--A); border-bottom-color: color-mix(in srgb, var(--A) 65%, #000); color: #fff; opacity: 1; }
.opt.wrong { background: var(--T); border-color: var(--T); border-bottom-color: color-mix(in srgb, var(--T) 65%, #000); color: #fff; opacity: 1; }
.opt.right::before, .opt.wrong::before { background: rgba(255,255,255,.25); color: #fff; }
.opt.dim, .opt:disabled:not(.right):not(.wrong) { opacity: .4; }
.qcard.ok { background: color-mix(in srgb, var(--A) 9%, var(--surface)); border-color: var(--A); box-shadow: inset 0 5px 0 var(--A), var(--shadow); }
.qcard.bad { background: color-mix(in srgb, var(--T) 8%, var(--surface)); border-color: var(--T); box-shadow: inset 0 5px 0 var(--T), var(--shadow); }
.qcard.shake { animation: shake .35s; }
.cardverdict { position: absolute; top: -14px; right: 14px; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; box-shadow: 0 4px 10px -2px rgba(0,0,0,.3); animation: pop .3s cubic-bezier(.2,1.6,.4,1) both; }
.cardverdict.ok { background: var(--A); } .cardverdict.bad { background: var(--T); }
.cardverdict .ico { stroke: #fff; stroke-width: 3.5; width: 22px; height: 22px; }

/* Escribir: un hueco por letra; tamaño calculado en play.js (--cw) */
.maskbox { position: relative; cursor: text; margin: 18px 0 6px; }
.maskbox .winput { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; font-size: 16px; border: 0; }
.mask { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 14px; }
.mask .w { display: flex; gap: 3px; }
.cellb { width: var(--cw, 32px); height: calc(var(--cw, 32px) * 1.22); border-radius: 8px; border: 2px solid var(--line); background: var(--surface2);
  display: grid; place-items: center; font-family: var(--font-m); font-weight: 700; font-size: calc(var(--cw, 32px) * .58); text-transform: uppercase; transition: background .15s, border-color .15s; }
.cellb.rev { background: var(--G-soft); border-color: var(--G); color: var(--ink); }
.cellb.newrev { animation: pop .45s cubic-bezier(.2,1.6,.4,1); }
.cellb.typed { background: var(--surface); border-color: var(--C); color: var(--ink); }
.cellb.cursor { background: var(--surface); border-color: var(--ink); box-shadow: 0 0 0 3px var(--C-soft); }
.maskbox:not(:focus-within) .cellb.cursor { box-shadow: none; border-color: var(--line); background: var(--surface2); }
.cellb.fx { border: 0; background: none; width: auto; min-width: 8px; color: var(--muted); }
.cellb.good { background: var(--A); border-color: var(--A); color: #fff; }
.cellb.miss { background: var(--T); border-color: var(--T); color: #fff; }
.mhelp { text-align: center; font-size: 13px; color: var(--muted); font-weight: 600; margin: 8px 0 0; }
.nextletter { display: flex; align-items: center; justify-content: center; gap: 6px; flex-wrap: wrap; font-size: 12.5px; font-weight: 700; color: #9A6500; margin-top: 6px; text-align: center; }
:root[data-theme="dark"] .nextletter { color: var(--G); }
.nextletter .ico { width: 15px; height: 15px; }

/* Ayudas */
.helpbar { display: flex; justify-content: space-between; align-items: center; margin-top: 16px; font-size: 13px; font-weight: 700; color: var(--muted); }
.atplink { display: inline-flex; align-items: center; gap: 5px; padding: 5px 11px; border-radius: 99px; background: var(--C-soft); color: var(--C); font-weight: 800; font-size: 14px; }
.atplink .ico { width: 17px; height: 17px; }
.helps { display: flex; gap: 8px; margin-top: 8px; }
.help { flex: 1; min-width: 0; display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 48px; padding: 6px 8px; border-radius: 14px; background: var(--surface); border: 1.5px solid var(--line);
  font-weight: 700; font-size: 14px; line-height: 1.15; text-align: left; box-shadow: 0 2px 0 var(--line); }
.help .ico { width: 18px; height: 18px; color: var(--C); }
.help small { display: block; color: var(--C); font-weight: 800; font-size: 12px; white-space: nowrap; }
.help:disabled { opacity: .4; }

/* Hoja de resultado */
.sheet { position: fixed; left: 50%; bottom: 0; transform: translateX(-50%); width: 100%; max-width: 520px; z-index: 40; padding: 18px 18px calc(16px + env(safe-area-inset-bottom));
  border-radius: 26px 26px 0 0; background: var(--sheet-bg); border-top: 4px solid var(--sheet-line); animation: slideUp .28s cubic-bezier(.2,.9,.3,1) both; box-shadow: 0 -14px 40px -12px rgba(0,0,0,.35); max-height: 78dvh; overflow: auto; }
@keyframes slideUp { from { transform: translate(-50%, 100%); } to { transform: translate(-50%, 0); } }
.sheet.good { --sheet-bg: var(--A-soft); --sheet-line: var(--A); } .sheet.badv { --sheet-bg: var(--T-soft); --sheet-line: var(--T); } .sheet.near { --sheet-bg: var(--G-soft); --sheet-line: var(--G); }
.sheet h3 { font-size: 23px; display: flex; align-items: center; gap: 10px; }
.sheet h3 .ico { width: 30px; height: 30px; padding: 5px; border-radius: 50%; color: #fff; stroke: #fff; stroke-width: 3.2; background: var(--sheet-line); }
.sheet.good h3 { color: color-mix(in srgb, var(--A) 80%, var(--ink)); } .sheet.badv h3 { color: var(--T); } .sheet.near h3 { color: #8A5A00; }
:root[data-theme="dark"] .sheet.near h3 { color: var(--G); } :root[data-theme="dark"] .sheet.good h3 { color: var(--A); }
.sheet .def { margin: 10px 0; font-size: 15px; line-height: 1.4; overflow-wrap: break-word; }
.sheet .twin { margin-top: 8px; padding: 10px 12px; border-radius: 12px; background: color-mix(in srgb, var(--surface) 70%, transparent); font-size: 14px; border-left: 4px solid var(--G); }
.xpf { font-family: var(--font-m); font-size: 13px; font-weight: 700; display: flex; gap: 10px; flex-wrap: wrap; margin: 6px 0 4px; }
.xpf span { padding: 2px 8px; border-radius: 99px; background: color-mix(in srgb, var(--surface) 65%, transparent); }
.mline { display: flex; align-items: center; gap: 8px; font-size: 14px; margin: 10px 0; font-weight: 600; padding: 9px 12px; border-radius: 12px; background: color-mix(in srgb, var(--surface) 65%, transparent); }
.mline.win { color: var(--A); font-weight: 800; font-size: 15px; }
.mpips { display: inline-flex; gap: 4px; flex: none; }
.mpips i { width: 13px; height: 13px; border-radius: 50%; border: 2px solid var(--muted); display: inline-block; }
.mpips i.f { background: var(--A); border-color: var(--A); }
.float { position: fixed; z-index: 60; pointer-events: none; font-family: var(--font-d); font-weight: 900; font-size: 28px; color: var(--A); animation: floatUp 1s ease-out forwards; text-shadow: 0 2px 0 rgba(0,0,0,.15); }
@keyframes floatUp { from { transform: translateY(0) scale(.7); opacity: 0; } 20% { opacity: 1; transform: scale(1.1);} to { transform: translateY(-80px); opacity: 0; } }
.shake { animation: shake .4s; } @keyframes shake { 20%,60% { transform: translateX(-7px); } 40%,80% { transform: translateX(7px); } }

/* Resultado */
.big { font-family: var(--font-d); font-weight: 900; font-size: 64px; line-height: 1; }
.center { text-align: center; }
.rewards { display: grid; grid-template-columns: repeat(auto-fit, minmax(70px, 1fr)); gap: 8px; margin: 14px 0; }
.rew { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 10px 6px; text-align: center; }
.rew b { display: block; font-family: var(--font-d); font-size: 22px; } .rew span { font-size: 12px; color: var(--muted); font-weight: 600; }
.badgepop { display: flex; gap: 12px; align-items: center; padding: 12px; background: var(--G-soft); border-radius: 16px; border: 2px solid var(--G); animation: pop .5s cubic-bezier(.2,1.6,.4,1) both; }
.medal { width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; color: var(--on-G); background: var(--G); flex: none; }
.medal.off { background: var(--surface2); color: var(--muted); opacity: .6; }
.lvlup { text-align: center; padding: 18px; border-radius: 20px; background: linear-gradient(135deg, var(--accent), var(--C)); color: #fff; animation: pop .5s cubic-bezier(.2,1.6,.4,1) both; }
.lvlup b { font-family: var(--font-d); font-size: 44px; display: block; }
canvas#fx { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 80; }

/* Ligas */
.tabs { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: 12px 0; }
.tabs button { padding: 9px 14px; border-radius: 999px; background: var(--surface); border: 1.5px solid var(--line); font-weight: 700; font-size: 14px; white-space: nowrap; }
.tabs button.on { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.lrow { display: flex; align-items: center; gap: 12px; padding: 11px 12px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); margin-bottom: 8px; }
.lrow.me { border: 2px solid var(--accent); background: color-mix(in srgb, var(--accent) 8%, var(--surface)); }
.rk { width: 30px; height: 30px; border-radius: 10px; display: grid; place-items: center; font-family: var(--font-d); font-weight: 800; background: var(--surface2); flex: none; }
.rk.r1 { background: var(--G); color: var(--on-G); } .rk.r2 { background: #B8C0CC; color: #222; } .rk.r3 { background: #CD8A55; color: #2b1500; }
.gtag { font-size: 11px; font-weight: 800; padding: 2px 6px; border-radius: 6px; color: #fff; }
.gtag.A { background: var(--C); } .gtag.B { background: var(--T); }
.val { font-family: var(--font-d); font-weight: 800; font-size: 18px; }
.duel { display: grid; grid-template-columns: 1fr auto 1fr; gap: 10px; align-items: center; text-align: center; }
.duel .g { padding: 14px 6px; border-radius: 16px; color: #fff; } .duel .g.A { background: var(--C); } .duel .g.B { background: var(--T); }
.duel .g b { font-family: var(--font-d); font-size: 34px; display: block; line-height: 1; }

/* Cariotipo */
.karyo { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.chrom { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 10px 6px 10px; text-align: center; box-shadow: var(--shadow); }
.chrom svg { width: 70px; height: 110px; }
.chrom small { display: block; font-size: 11px; color: var(--muted); font-weight: 600; margin-top: 4px; }
.chrom b { font-size: 13px; display: block; line-height: 1.15; min-height: 30px; }
.terms li { list-style: none; padding: 12px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); margin-bottom: 8px; }
.terms ul { padding: 0; margin: 0; }
.tbox { display: inline-flex; gap: 2px; vertical-align: middle; } .tbox i { width: 6px; height: 14px; border-radius: 2px; background: var(--line); } .tbox i.f { background: var(--A); }
.badgegrid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.bg1 { text-align: center; font-size: 11px; font-weight: 700; line-height: 1.1; } .bg1 .medal { margin: 0 auto 4px; }

/* Auth */
.logo { font-family: var(--font-d); font-weight: 900; font-size: 64px; letter-spacing: .02em; display: flex; gap: 2px; justify-content: center; }
.logo span:nth-child(1) { color: var(--A); } .logo span:nth-child(2) { color: var(--C); } .logo span:nth-child(3) { color: var(--G); } .logo span:nth-child(4) { color: var(--T); }
.field { display: flex; flex-direction: column; gap: 6px; } .field label { font-weight: 700; font-size: 14px; }
.input { height: 52px; border-radius: 14px; border: 2px solid var(--line); background: var(--surface); padding: 0 14px; font-size: 18px; outline: none; width: 100%; }
.input:focus { border-color: var(--accent); }
.seg { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.seg button { height: 56px; border-radius: 14px; border: 2px solid var(--line); background: var(--surface); font-family: var(--font-d); font-weight: 800; font-size: 20px; }
.seg button.on:not([data-g]) { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.seg button.on[data-g="A"] { background: var(--C); border-color: var(--C); color: #fff; } .seg button.on[data-g="B"] { background: var(--T); border-color: var(--T); color: #fff; }
.code { font-family: var(--font-m); font-size: 44px; font-weight: 700; letter-spacing: .08em; text-align: center; padding: 18px; background: var(--surface); border: 2px dashed var(--accent); border-radius: 18px; user-select: all; }
.err { color: var(--T); font-weight: 700; font-size: 14px; min-height: 18px; }
.toast { position: fixed; left: 50%; bottom: 100px; transform: translateX(-50%); background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 12px; font-weight: 700; z-index: 90; animation: rise .2s both; }
.modal { position: fixed; inset: 0; background: rgba(0,0,0,.55); z-index: 70; display: grid; place-items: center; padding: 20px; }
.modal > div { background: var(--surface); border-radius: 22px; padding: 22px; max-width: 420px; width: 100%; animation: pop .35s cubic-bezier(.2,1.4,.4,1) both; }
.toggle { display: flex; justify-content: space-between; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); font-weight: 600; }
.switch { width: 48px; height: 28px; border-radius: 99px; background: var(--surface2); position: relative; border: 1px solid var(--line); transition: background .2s; }
.switch::after { content: ''; position: absolute; top: 2px; left: 2px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.3); transition: transform .2s; }
.switch.on { background: var(--A); } .switch.on::after { transform: translateX(20px); }
.skeleton { height: 120px; border-radius: 20px; background: linear-gradient(90deg, var(--surface2), var(--surface), var(--surface2)); background-size: 200% 100%; animation: sk 1.2s infinite; }
@keyframes sk { to { background-position: -200% 0; } }
table.t { width: 100%; border-collapse: collapse; font-size: 14px; } table.t td, table.t th { padding: 6px 4px; border-bottom: 1px solid var(--line); text-align: left; }


/* Relámpago --------------------------------------------------------------- */
.tf { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 16px; }
.tf button { height: 86px; border-radius: 20px; font-family: var(--font-d); font-weight: 900; font-size: clamp(19px, 6vw, 25px); color: #fff; letter-spacing: .02em; box-shadow: 0 5px 0 rgba(0,0,0,.25); transition: transform .08s, box-shadow .08s; }
.tf .t { background: var(--C); } .tf .f { background: var(--accent); }
.tf button:active { transform: translateY(4px); box-shadow: 0 1px 0 rgba(0,0,0,.25); }
.blitzcard { min-height: 200px; display: flex; flex-direction: column; justify-content: center; text-align: center; overflow: hidden; }
.blitzcard .qprompt.term { margin-top: 0; }
.blitzcard .bdef { font-family: var(--font-b); font-size: 17px; font-weight: 500; line-height: 1.38; margin-top: 12px; overflow-wrap: break-word; }
.blitzcard .bdef.long { font-size: 15.5px; }
.qcard.vflash-ok { background: var(--A); border-color: var(--A); box-shadow: inset 0 5px 0 var(--A), var(--shadow); }
.qcard.vflash-bad { background: var(--T); border-color: var(--T); box-shadow: inset 0 5px 0 var(--T), var(--shadow); }
.qcard.vflash-ok > :not(.vbig), .qcard.vflash-bad > :not(.vbig) { opacity: 0; }
.vbig { position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none; animation: vbig .45s both; }
.vbig .ico { width: 92px; height: 92px; stroke: #fff; stroke-width: 3.2; filter: drop-shadow(0 4px 10px rgba(0,0,0,.25)); }
@keyframes vbig { 0% { transform: scale(.4); opacity: 0; } 40% { transform: scale(1.12); opacity: 1; } 100% { transform: scale(1); opacity: 1; } }
.blitz-hint { text-align: center; font-size: 14px; min-height: 44px; color: var(--muted); margin-top: 6px; padding: 0 4px; overflow-wrap: break-word; }
.blitz-hint b { color: var(--ink); }
.bhead { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.bclock { display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-m); font-weight: 700; font-size: 22px; }

/* Inicio: secciones, ayuda, siguiente paso -------------------------------- */
.top .grow > div:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.top .pill { padding: 7px 10px; flex: none; }
.sec { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; font-family: var(--font-d); font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); font-weight: 800; margin: 10px 2px -2px; }
.sec small { text-transform: none; letter-spacing: 0; font-weight: 600; font-family: var(--font-b); font-size: 12.5px; opacity: .85; }
.helpbtn { width: 36px; height: 36px; flex: none; border-radius: 50%; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); font-weight: 900; color: var(--muted); font-family: var(--font-d); font-size: 17px; }
.pill.atp { cursor: pointer; } button.pill { font: inherit; font-weight: 800; }
.d2card { display: grid; grid-template-columns: auto 1fr; gap: 6px 12px; align-items: center; }
.d2card .medal { width: 46px; height: 46px; }
.d2card .grow b { font-family: var(--font-d); font-size: 18px; }
.d2card .btn, .d2card .pattern { grid-column: 1 / -1; }
.d2card .btn { margin-top: 6px; }
.nextstep { display: flex; gap: 12px; align-items: center; padding: 14px; border-radius: var(--r); background: linear-gradient(135deg, color-mix(in srgb, var(--C) 14%, var(--surface)), var(--surface)); border: 1.5px solid color-mix(in srgb, var(--C) 45%, var(--line)); }
.nextstep b { color: var(--C); display: block; font-family: var(--font-d); font-size: 16px; }
.nextstep .btn { flex: none; }
.tile h3 { font-size: 17px; line-height: 1.15; overflow-wrap: break-word; }
.tile { transition: transform .1s, box-shadow .1s; }
.tile:active:not(:disabled) { transform: translateY(2px); }

/* Tutorial y ATP --------------------------------------------------------- */
.modal > div { max-height: calc(100dvh - 40px); overflow: auto; }
.modal .tutstep { text-align: center; }
.modal .tutstep p { font-size: 15.5px; }
.modal .tutico { width: 76px; height: 76px; border-radius: 24px; display: grid; place-items: center; margin: 0 auto 4px; color: #fff; box-shadow: 0 8px 20px -8px rgba(0,0,0,.35); }
.modal .tutico .ico { width: 38px; height: 38px; }
.dotsrow { display: flex; gap: 6px; justify-content: center; margin: 2px 0; }
.dotsrow i { width: 8px; height: 8px; border-radius: 99px; background: var(--line); transition: width .2s; } .dotsrow i.on { background: var(--accent); width: 22px; }
.atpgrid { display: grid; gap: 6px; }
.atpgrid .lrow { padding: 10px 12px; margin: 0; gap: 10px; }
.atpgrid .lrow b { font-size: 15px; } .atpgrid .lrow > b, .atpgrid .lrow > .val { flex: none; color: var(--C); font-family: var(--font-d); }
.atpgrid small { color: var(--muted); display: block; font-weight: 600; font-size: 12.5px; line-height: 1.25; }
.modal .sec { margin-top: 6px; }

/* Ligas: textos largos */
.lrow .grow b { overflow-wrap: anywhere; }
.lrow { min-width: 0; }

/* Pantallas estrechas ---------------------------------------------------- */
@media (max-width: 380px) {
  .view { padding-left: 12px; padding-right: 12px; }
  .qcard { padding: 20px 14px 14px; }
  .qprompt { font-size: 19px; } .qprompt.long { font-size: 17.5px; } .qprompt.xlong { font-size: 16.5px; }
  .qprompt.term { font-size: 25px; } .qprompt.term.long { font-size: 21px; }
  .opt { font-size: 16px; padding: 10px 40px 10px 48px; min-height: 52px; } .opt.defopt { font-size: 14px; }
  .opt::before { left: 9px; width: 28px; height: 28px; }
  .help { font-size: 13px; gap: 4px; padding: 6px; } .help .ico { width: 16px; height: 16px; }
  .hero h2 { font-size: 26px; }
  .tiles { gap: 10px; } .tile { padding: 12px; }
  .top { gap: 8px; } .avatar { width: 42px; height: 42px; }
  .pill { font-size: 14px; } .top .pill { padding: 6px 8px; }
  .rewards .rew b { font-size: 19px; }
  .karyo { gap: 8px; } .chrom svg { width: 60px; height: 96px; }
  .badgegrid { grid-template-columns: repeat(3, 1fr); }
  .modal { padding: 12px; } .modal > div { padding: 18px; }
  .sheet { padding-left: 14px; padding-right: 14px; }
}
.d2card .btn { background: var(--C); color: #fff; box-shadow: 0 4px 0 color-mix(in srgb, var(--C) 60%, #000); }

.qcard .btn:disabled { background: var(--surface2); color: var(--muted); box-shadow: none; opacity: 1; }
.plegend { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; font-size: 12.5px; color: var(--muted); font-weight: 600; margin-top: 6px; }
.plegend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 4px; vertical-align: -1px; }
@media (max-width: 359px) { .top .avatar { display: none; } .top .grow > div:first-child { font-size: 16px !important; } }

/* ===================== Mascota, plásmidos, cápsides y duelos ===================== */
.mascot { display: block; overflow: visible; }
.mascot .m-bob { animation: mbob 2.8s ease-in-out infinite; transform-origin: 100px 190px; }
.mascot .m-float { animation: mfloat 3.4s ease-in-out infinite; }
.mascot .m-eyes { animation: mblink 4.6s infinite; transform-box: fill-box; transform-origin: center; }
.mascot.still .m-bob, .mascot.still .m-float, .mascot.still .m-eyes { animation: none; }
@keyframes mbob { 0%, 100% { transform: translateY(0) scale(1, 1); } 50% { transform: translateY(-5px) scale(1.01, .99); } }
@keyframes mfloat { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-7px) rotate(-4deg); } }
@keyframes mblink { 0%, 92%, 100% { transform: scaleY(1); } 95% { transform: scaleY(.1); } }
@media (prefers-reduced-motion: reduce) { .mascot .m-bob, .mascot .m-float, .mascot .m-eyes { animation: none; } }

.avatar.pet { padding: 0; border: 2px solid var(--g, var(--line)); background: var(--surface); overflow: hidden; display: grid; place-items: center; box-shadow: var(--shadow); cursor: pointer; }
.avatar.pet svg { width: 100%; height: 100%; transform: translateY(3px) scale(1.08); }
.wallet { display: flex; flex-direction: column; gap: 4px; flex: none; }
.top .wallet .pill { padding: 3px 9px; font-size: 13px; min-height: 26px; justify-content: flex-start; }
.top .wallet .pill .ico { width: 15px; height: 15px; }
.pill.plas { color: var(--accent); }
button.pill.plas { cursor: pointer; }

.banner { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 10px 14px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); font: inherit; color: var(--ink); cursor: pointer; }
.banner b { display: block; font-family: var(--font-d); font-size: 16px; }
.banner small { color: var(--muted); font-weight: 600; }
.banner .medal { width: 44px; height: 44px; }
.banner.chestb { border-color: color-mix(in srgb, var(--C) 45%, var(--line)); background: linear-gradient(100deg, var(--C-soft), var(--surface) 70%); }
.banner.chestb .capsid { animation: wobble 2.4s ease-in-out infinite; }
.banner.duelb { border-color: color-mix(in srgb, var(--T) 45%, var(--line)); background: linear-gradient(100deg, var(--T-soft), var(--surface) 70%); }
@keyframes wobble { 0%, 80%, 100% { transform: rotate(0); } 85% { transform: rotate(-9deg); } 90% { transform: rotate(8deg); } 95% { transform: rotate(-4deg); } }

.petcard { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 14px 14px 12px; background: radial-gradient(circle at 50% 40%, var(--surface2), var(--surface) 70%); }
.petstage { width: 210px; height: 210px; max-width: 70vw; max-height: 70vw; }
.petstage svg { width: 100%; height: 100%; }
.petname { display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-d); font-weight: 800; font-size: 22px; background: none; border: 0; color: var(--ink); padding: 2px 6px; border-radius: 10px; cursor: pointer; }
.petname .ico { width: 16px; height: 16px; stroke: var(--muted); }
.petform { font-size: 13px; font-weight: 600; text-align: center; }
.evotrack { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; width: 100%; margin: 6px 0 4px; }
.evo { display: flex; flex-direction: column; align-items: center; gap: 2px; opacity: .38; filter: grayscale(1); }
.evo.got { opacity: 1; filter: none; }
.evo.now .msvg { outline: 2px solid var(--accent); border-radius: 12px; background: var(--surface); }
.evo small { font-size: 10px; font-weight: 700; color: var(--muted); text-align: center; line-height: 1.1; }
.evo .msvg svg { display: block; }
.linkbtn { background: none; border: 0; color: var(--accent); font: inherit; font-weight: 700; font-size: 13px; cursor: pointer; padding: 0; margin-left: auto; }

.chestrow { display: flex; gap: 10px; overflow-x: auto; padding: 2px 2px 8px; scroll-snap-type: x mandatory; }
.chest { flex: none; width: 118px; scroll-snap-align: start; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 10px 8px; border-radius: var(--r); background: var(--surface); border: 2px solid var(--line); box-shadow: var(--shadow); font: inherit; color: var(--ink); cursor: pointer; }
.chest b { font-size: 13px; } .chest small { font-size: 11px; color: var(--muted); font-weight: 600; text-align: center; line-height: 1.2; }
.chest.normal { border-color: color-mix(in srgb, var(--C) 50%, var(--line)); }
.chest.rara { border-color: color-mix(in srgb, var(--accent) 60%, var(--line)); }
.chest.epica { border-color: var(--G); background: linear-gradient(180deg, var(--G-soft), var(--surface)); }
.chest .capsid { animation: wobble 2.4s ease-in-out infinite; }

.slottabs { display: flex; flex-wrap: wrap; gap: 6px; }
.slottabs button { flex: 1 0 auto; padding: 8px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--muted); font: inherit; font-weight: 800; font-size: 14px; cursor: pointer; }
.slottabs button.on { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.itemgrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.itemtile { display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 8px 4px 9px; border-radius: 14px; background: var(--surface); border: 2px solid var(--line); font: inherit; color: var(--ink); cursor: pointer; min-width: 0; }
.itemtile .msvg svg { width: 76px; height: 76px; display: block; }
.itemtile b { font-size: 12px; line-height: 1.15; text-align: center; min-height: 2.3em; display: flex; align-items: center; overflow-wrap: anywhere; }
.itemtile.sel { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 25%, transparent); }
.itemtile.locked .msvg { opacity: .9; }
.itag { display: inline-flex; align-items: center; gap: 3px; font-size: 12px; font-weight: 800; color: var(--rc, var(--muted)); padding: 2px 8px; border-radius: 99px; background: var(--surface2); }
.itag .ico { width: 13px; height: 13px; }
.tryaction { display: flex; align-items: center; gap: 10px; }
.tryaction:empty { display: none; }
.tryaction { position: sticky; top: 8px; z-index: 3; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 10px 12px; box-shadow: var(--shadow); }
.tryaction b { display: block; } .tryaction small { font-weight: 700; }
.tryaction .btn { width: auto; flex: none; padding: 0 16px; }

.chestmodal .capsidbig { display: grid; place-items: center; margin: 10px auto; }
.capsidbig.shake { animation: shake .5s ease-in-out infinite; }
.capsidbig.burst { animation: burst .38s ease-in forwards; }
@keyframes shake { 0%, 100% { transform: rotate(0) scale(1); } 25% { transform: rotate(-7deg) scale(1.03); } 75% { transform: rotate(7deg) scale(1.03); } }
@keyframes burst { to { transform: scale(1.6); opacity: 0; } }
.prize { display: flex; flex-direction: column; align-items: center; gap: 2px; animation: pop .45s cubic-bezier(.2,1.6,.4,1) both; }
.prizeline { display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-d); font-weight: 800; font-size: 22px; color: var(--accent); animation: pop .45s .1s cubic-bezier(.2,1.6,.4,1) both; }
.prizeline.atp { color: var(--C); }

.duelnote { display: flex; align-items: center; gap: 8px; justify-content: center; margin-top: 12px; font-size: 13px; font-weight: 700; color: var(--muted); }
.duelnote .ico { width: 16px; height: 16px; }
.duelrow { display: flex; flex-direction: column; gap: 10px; }
.duelrow.in { border-color: color-mix(in srgb, var(--T) 40%, var(--line)); }
.duelrow .row .btn { flex: 1; }
.rangef { display: grid; grid-template-columns: auto 1fr 34px; align-items: center; gap: 10px; font-weight: 700; font-size: 14px; }
.rangef input { width: 100%; accent-color: var(--accent); }
.rangef b { text-align: right; font-family: var(--font-m); }
.dtag { font-size: 12px; font-weight: 800; margin-left: 10px; min-width: 64px; text-align: right; }
.duelres { text-align: center; display: flex; flex-direction: column; gap: 8px; }
.duelres > b { font-family: var(--font-d); font-size: 20px; }
.duelres.win { border-color: var(--A); background: linear-gradient(180deg, var(--A-soft), var(--surface)); }
.duelres.lose { border-color: var(--T); }
.duelvs { display: flex; align-items: center; justify-content: center; gap: 18px; }
.duelvs > div { display: flex; flex-direction: column; min-width: 80px; }
.duelvs small { color: var(--muted); font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 110px; }
.duelvs strong { font-family: var(--font-d); font-size: 30px; }
.duelvs > span { color: var(--muted); font-weight: 800; }
.nav a { font-size: 10.5px; }
@media (max-width: 380px) { .itemtile .msvg svg { width: 64px; height: 64px; } .chest { width: 104px; } }
@media (max-width: 359px) { .top .wallet .pill { font-size: 12px; padding: 2px 7px; } }
.top .grow > div:nth-child(2) { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.petcard .btn.ghost.sm { font-size: 13px; padding: 0 6px; white-space: nowrap; }
@media (max-width: 380px) { .helpbtn { width: 30px; height: 30px; font-size: 15px; } .top { gap: 6px; } }

/* En modo oscuro la mascota va sobre una placa clara para que se vean sus contornos */
.petstage, .avatar.pet, .itemtile .msvg, .evo .msvg, .prize .msvg { background: var(--plate, transparent); border-radius: 16px; }
.petstage { border-radius: 50%; }
.avatar.pet { background: var(--plate, var(--surface)); }
.duelmode button { display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
.duelmode .ico { width: 18px; height: 18px; }
.duelmode button { height: 46px; font-size: 16px; }
.mstate { font-size: 12px; font-weight: 700; color: var(--muted); margin-left: 6px; }
.mstate.ok { color: var(--A); }
.fvisit { display: flex; gap: 12px; align-items: flex-end; padding: 12px 14px; border-radius: var(--r); background: color-mix(in srgb, var(--accent) 10%, var(--surface)); border: 1px solid color-mix(in srgb, var(--accent) 35%, var(--line)); animation: pop .35s both; }
.fvisit b { font-family: var(--font-d); font-size: 16px; }
.fvisit p { margin: 4px 0 0; font-size: 14px; line-height: 1.45; }
.fvisit .btn { width: auto; flex: none; padding: 0 14px; }
@media (max-width: 380px) { .fvisit { flex-direction: column; align-items: stretch; } }
.rpet { width: 36px; height: 36px; flex: none; border-radius: 10px; background: var(--plate, var(--surface2)); overflow: hidden; }
.rpet svg { width: 100%; height: 100%; display: block; }
.aliashint { font-size: 13px; margin-top: 6px; line-height: 1.4; }
.aliashint.ok { color: var(--A); font-weight: 700; }
.aliashint.bad { color: var(--T); font-weight: 700; }
.flabel { display: flex; flex-direction: column; gap: 2px; font-weight: 800; font-size: 14px; }
.flabel small { font-weight: 600; color: var(--muted); font-size: 12.5px; }
.psugg { display: flex; flex-direction: column; gap: 6px; }
.psugg:empty { display: none; }
.psug { display: flex; align-items: center; gap: 10px; padding: 6px 10px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); font: inherit; color: var(--ink); cursor: pointer; text-align: left; }
.psug.on { border-color: var(--accent); }
.psug b { flex: 1; } .psug small { color: var(--muted); font-weight: 700; }
.psug .rpet { width: 30px; height: 30px; }
.inbox { position: relative; width: 40px; height: 40px; flex: none; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); display: grid; place-items: center; cursor: pointer; box-shadow: var(--shadow); }
.inbox .ico { width: 22px; height: 22px; }
.inbox .dot { position: absolute; top: -6px; right: -6px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 99px; background: var(--T); color: #fff; font-size: 12px; font-weight: 800; display: grid; place-items: center; border: 2px solid var(--bg); animation: pop .4s both; }
.pill.atp.full { box-shadow: 0 0 0 2px var(--G) inset; }
.dmsgs { display: flex; flex-direction: column; gap: 6px; }
.dmsgs:empty { display: none; }
.dmsg { align-self: flex-start; max-width: 85%; padding: 6px 12px; border-radius: 14px 14px 14px 4px; background: var(--surface2); font-size: 14px; font-weight: 600; }
.dmsg small { display: block; font-size: 11px; color: var(--muted); font-weight: 700; }
.dmsg.mine { align-self: flex-end; border-radius: 14px 14px 4px 14px; background: color-mix(in srgb, var(--accent) 14%, var(--surface)); }
.dsay summary { cursor: pointer; display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 800; color: var(--accent); list-style: none; }
.dsay summary::-webkit-details-marker { display: none; }
.dsay .ico { width: 16px; height: 16px; }
.dchips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.chipbtn { padding: 6px 10px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; }
.hrow + .hrow { border-top: 1px solid var(--line); }
.hrow .lrow { border: 0; }
@media (max-width: 380px) { .inbox { width: 36px; height: 36px; } }
.tile.alert { border-color: var(--T); box-shadow: 0 0 0 2px color-mix(in srgb, var(--T) 30%, transparent), var(--shadow); }
.tile.alert .badgeN { animation: pop .5s both, bpulse 1.6s 1s ease-in-out infinite; font-size: 15px; }
@keyframes bpulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.18); } }
.dstats { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; }
.dstats > div { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 8px 2px; text-align: center; display: flex; flex-direction: column; }
.dstats b { font-family: var(--font-d); font-size: 20px; }
.dstats small { font-size: 10.5px; font-weight: 700; color: var(--muted); }
.tiles > .tile:last-child:nth-child(odd) { grid-column: 1 / -1; }
.duelcard { position: relative; }
.duelcard .btn { background: var(--accent); color: #fff; box-shadow: 0 4px 0 color-mix(in srgb, var(--accent) 60%, #000); }
.duelcard.alert { border-color: var(--T); box-shadow: 0 0 0 2px color-mix(in srgb, var(--T) 30%, transparent), var(--shadow); }
.duelcard .badgeN { position: absolute; top: 10px; right: 10px; background: var(--T); color: #fff; font-weight: 800; font-size: 15px; min-width: 26px; height: 26px; border-radius: 99px; display: grid; place-items: center; animation: pop .5s both, bpulse 1.6s 1s ease-in-out infinite; }
.weekcard { width: 100%; text-align: left; font: inherit; color: var(--ink); cursor: pointer; gap: 12px; }
.weekcard .medal { width: 44px; height: 44px; flex: none; }

/* ===== Llama de la racha (6 fases) ===== */
.pill.fire { cursor: pointer; font: inherit; font-weight: 800; color: var(--ink); gap: 4px; transition: transform .2s; }
.pill.fire b { font-size: 16px; }
.pill.fire .flw { display: grid; place-items: center; }
.flame { overflow: visible; }
.flame .fl-out, .flame .fl-mid, .flame .fl-side { transform-box: fill-box; transform-origin: 50% 100%; }
.pill.ft0 { color: var(--muted); }
.pill.ft1 b { color: #E07A10; }
.pill.ft2 { border-color: color-mix(in srgb, #EE5A24 45%, var(--line)); } .pill.ft2 b { color: #E0501A; }
.pill.ft3 { border-color: #E0301E; background: linear-gradient(180deg, color-mix(in srgb, #FFB627 18%, var(--surface)), var(--surface)); box-shadow: 0 0 0 2px color-mix(in srgb, #E0301E 18%, transparent), 0 0 14px color-mix(in srgb, #FF8A1F 45%, transparent); }
.pill.ft3 b { color: #D9341F; }
.pill.ft4 { border-color: #2F6BFF; background: linear-gradient(180deg, color-mix(in srgb, #5BC0FF 20%, var(--surface)), var(--surface)); box-shadow: 0 0 0 2px color-mix(in srgb, #2F6BFF 20%, transparent), 0 0 16px color-mix(in srgb, #5BC0FF 55%, transparent); }
.pill.ft4 b { color: #2F6BFF; }
.pill.ft5 { border-color: #8B3DFF; background: linear-gradient(135deg, color-mix(in srgb, #FF4FD8 22%, var(--surface)), color-mix(in srgb, #8B3DFF 22%, var(--surface))); box-shadow: 0 0 0 2px color-mix(in srgb, #8B3DFF 25%, transparent), 0 0 20px color-mix(in srgb, #FF4FD8 55%, transparent); }
.pill.ft5 b { background: linear-gradient(90deg, #8B3DFF, #FF4FD8); -webkit-background-clip: text; background-clip: text; color: transparent; }
.flame.t1 .fl-out { animation: flk 2.4s ease-in-out infinite; }
.flame.t2 .fl-out, .flame.t2 .fl-mid { animation: flk 1.6s ease-in-out infinite; }
.flame.t2 .fl-mid { animation-delay: -.5s; }
.flame.t3 .fl-out, .flame.t4 .fl-out, .flame.t5 .fl-out { animation: flk 1.1s ease-in-out infinite; }
.flame.t3 .fl-mid, .flame.t4 .fl-mid, .flame.t5 .fl-mid { animation: flk .8s ease-in-out infinite reverse; }
.flame .fl-side { animation: flks 1.3s ease-in-out infinite; } .flame .fl-side.r { animation-delay: -.6s; }
.flame .fl-spark { animation: spark 1.8s ease-out infinite; } .flame .s1 { animation-delay: .6s; } .flame .s2 { animation-delay: 1.2s; }
.flame.t5 .fl-out { filter: drop-shadow(0 0 2px #FF4FD8); }
@keyframes flk { 0%, 100% { transform: scale(1, 1) skewX(0); } 30% { transform: scale(.96, 1.06) skewX(-2deg); } 60% { transform: scale(1.03, .96) skewX(2deg); } }
@keyframes flks { 0%, 100% { transform: scale(1); opacity: .9; } 50% { transform: scale(.75, 1.15); opacity: .6; } }
@keyframes spark { 0% { transform: translateY(4px); opacity: 0; } 30% { opacity: 1; } 100% { transform: translateY(-6px); opacity: 0; } }
.pill.fire.risk .flw { animation: riskp 1.2s ease-in-out infinite; }
@keyframes riskp { 50% { opacity: .35; } }
@media (prefers-reduced-motion: reduce) { .flame *, .pill.fire.risk .flw { animation: none !important; } }
.bigflame { display: grid; place-items: center; margin: 4px auto 0; }
.flameladder { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; }
.flameladder .fl { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 2px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); opacity: .45; filter: grayscale(.8); }
.flameladder .fl.got { opacity: 1; filter: none; }
.flameladder .fl.now { border-color: var(--accent); box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent) 25%, transparent); }
.flameladder b { font-size: 11px; text-align: center; line-height: 1.1; } .flameladder small { font-size: 10px; color: var(--muted); font-weight: 700; }
.nav a { position: relative; }
.ndot { position: absolute; top: 0; left: calc(50% + 6px); min-width: 18px; height: 18px; padding: 0 4px; border-radius: 99px; background: var(--T); color: #fff; font-size: 11px; font-weight: 800; display: grid; place-items: center; border: 2px solid var(--surface); line-height: 1; }
.banner.chestb { padding: 0; gap: 0; cursor: default; }
.banner .banbody { flex: 1; display: flex; align-items: center; gap: 12px; padding: 10px 6px 10px 14px; background: none; border: 0; font: inherit; color: inherit; text-align: left; cursor: pointer; min-width: 0; }
.banner .banx { flex: none; width: 40px; align-self: stretch; display: grid; place-items: center; background: none; border: 0; border-left: 1px solid var(--line); color: var(--muted); cursor: pointer; }
.banner .banx .ico { width: 18px; height: 18px; }
/* Armario: lo tuyo en color, lo que no tienes en gris */
.itemtile { position: relative; }
.itemtile.locked .msvg { filter: grayscale(1); opacity: .55; }
.itemtile.locked b { color: var(--muted); }
.itemtile .lock { position: absolute; top: 8px; right: 8px; width: 22px; height: 22px; border-radius: 99px; background: var(--surface2); display: grid; place-items: center; }
.itemtile .lock .ico { width: 13px; height: 13px; stroke: var(--muted); }
.itemtile.have { border-color: color-mix(in srgb, var(--A) 30%, var(--line)); }
.itemtile.on { border-color: var(--A); }
.itemtile.fresh { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 20%, transparent); }
.itag.on { color: #fff !important; background: var(--A); }
.itag.new { color: #fff !important; background: var(--accent); }
.itag .ico { width: 13px; height: 13px; }
.slottabs button.mine { font-weight: 800; }
.slottabs button.on.mine { background: var(--accent); border-color: var(--accent); color: #fff; }
.newdot { display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 4px; margin-left: 6px; border-radius: 99px; background: var(--T); color: #fff; font-size: 11px; font-weight: 800; }
.mascot .m-shine path { animation: twinkle 2.2s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
.mascot .m-shine path:nth-child(2n) { animation-delay: 1.1s; }
.mascot.still .m-shine path { animation: none; }
@keyframes twinkle { 0%, 100% { opacity: .2; transform: scale(.6); } 50% { opacity: 1; transform: scale(1.1); } }
/* Insignias: el anillo se va llenando con el progreso */
.bg1 { background: none; border: 0; font: inherit; color: var(--ink); cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 2px; }
.bg1 span { font-size: 11px; font-weight: 700; line-height: 1.15; text-align: center; }
.bg1:not(.got) span { color: var(--muted); }
.bring { width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center; background: var(--line); }
/* el anillo de progreso solo se pinta si hay progreso: con 0 % el degradado cónico deja una raya dorada arriba */
.bring.prog { background: conic-gradient(var(--G) var(--p, 0%), var(--line) 0); }
.bring .medal { margin: 0 !important; width: 48px; height: 48px; border: 3px solid var(--surface); }
.bg1.got .bring { background: var(--G); }
.bring.big { width: 104px; height: 104px; }
.bring.big .medal { width: 90px; height: 90px; }
.bring.big .medal .ico { width: 40px; height: 40px; }
.bprog { width: 100%; display: flex; align-items: center; gap: 10px; }
.bbar { flex: 1; height: 10px; border-radius: 99px; background: var(--line); overflow: hidden; }
.bbar i { display: block; height: 100%; background: var(--G); border-radius: 99px; }
.bstate { font-weight: 700; color: var(--muted); display: inline-flex; gap: 6px; align-items: center; justify-content: center; }
.bstate.ok { color: var(--A); }
.bstate .ico { width: 18px; height: 18px; }
.slottabs button.mine { flex-basis: 100%; display: inline-flex; align-items: center; justify-content: center; gap: 6px; margin-top: 2px; }
.slottabs button.mine .ico { width: 18px; height: 18px; }
.coinseg { margin-bottom: 4px; }
.coinseg button { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 44px; font-size: 16px; }
.coinseg .ico { width: 18px; height: 18px; }
.banner.instb { padding: 0; gap: 0; cursor: default; border-color: color-mix(in srgb, var(--A) 40%, var(--line)); background: linear-gradient(100deg, var(--A-soft), var(--surface) 70%); }
.istep { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); font-size: 15px; line-height: 1.4; }
.inum { width: 28px; height: 28px; flex: none; border-radius: 99px; background: var(--ink); color: var(--bg); display: grid; place-items: center; font-weight: 800; }
.iico { flex: none; display: grid; place-items: center; }

/* Multiplicador dentro de la fila de aciertos y fallos (antes flotaba y se montaba encima) */
.combo.in { position: static; font-size: 17px; line-height: 1; margin-left: 2px; text-shadow: none; transform-origin: center; }
.rinfo .rcount { align-items: center; }
/* Verdadero o falso dentro de las rondas */
.vfdef { margin-top: 12px; padding: 14px 16px; border-radius: 16px; background: var(--surface2); font-size: 18px; line-height: 1.4; font-weight: 600; }
.vfdef.long { font-size: 16px; }
.tf.vf button { height: 64px; font-size: clamp(17px, 5vw, 22px); padding: 0 8px; display: flex; align-items: center; justify-content: center; gap: 6px; }
.tf.vf button.dim { opacity: .35; }
.tf.vf button.right { outline: 3px solid var(--A); outline-offset: 2px; }
.tf.vf button.wrong { outline: 3px solid var(--T); outline-offset: 2px; }

/* Pantalla «Por clase» */
.classcard { display: block; width: 100%; text-align: left; padding: 14px 16px; }
.classcard:disabled { opacity: .5; }

/* ---- Tipografía más grande y menos letra pequeña (estética de juego) ---- */
.sec { font-size: 21px; letter-spacing: 0; text-transform: none; color: var(--ink); font-weight: 900; margin: 18px 2px 2px; }
.sec small { display: none; }
.modal .sec { font-size: 17px; }
.tile { min-height: 116px; gap: 8px; }
.tile h3 { font-size: 20px; }
.tile p { font-size: 14.5px; font-weight: 600; }
.tile .i { width: 44px; height: 44px; border-radius: 14px; }
.nav a { font-size: 0; gap: 0; padding: 10px 0; }
.nav a .ico { width: 28px; height: 28px; }
.nav a.on { background: color-mix(in srgb, var(--accent) 12%, transparent); }
.nav a .ndot { font-size: 11px; }
.banner b { font-size: 17px; }
.petform { display: flex; align-items: baseline; justify-content: center; gap: 12px; margin-top: 2px; }
.petrank { font-family: var(--font-d); font-size: 26px; font-weight: 900; color: var(--accent); }
.petlvl { font-family: var(--font-d); font-size: 20px; font-weight: 800; color: var(--ink); background: var(--surface2); padding: 3px 12px; border-radius: 999px; }
.evotrack small { font-size: 12px; font-weight: 700; }
.hero .sub { font-size: 15px; }
.hero h2 { font-size: 30px; }
.classcard b { font-size: 19px !important; }
.lrow b { font-size: 16px; }
.rinfo { font-size: 14px; }
.tabs button { font-size: 15px; padding: 10px 15px; }

/* Escribir: cada palabra en su «bandeja» y, si no caben juntas, una por línea */
.mask .w { padding: 5px; border-radius: 12px; background: color-mix(in srgb, var(--ink) 5%, transparent); }
.mask.stacked { flex-direction: column; align-items: center; gap: 8px; }
.mask .w.cont { position: relative; margin-right: 10px; }
.mask .w.cont::after { content: '-'; position: absolute; right: -11px; top: 50%; transform: translateY(-50%); font-weight: 900; color: var(--muted); font-size: 20px; }

/* Revisión de respuestas */
.revmodal > .stack { max-height: 86vh; overflow-y: auto; }
.revitem { border-radius: 16px; padding: 12px 14px; background: var(--surface2); border-left: 5px solid var(--A); }
.revitem.bad { border-left-color: var(--T); }
.revhead { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 800; color: var(--muted); }
.revmark { width: 22px; height: 22px; border-radius: 99px; display: grid; place-items: center; color: #fff; background: var(--A); }
.revitem.bad .revmark { background: var(--T); }
.revmark .ico { width: 14px; height: 14px; stroke: #fff; }
.revterm { display: block; font-size: 18px; margin: 4px 0 2px; }
.revdef { font-size: 14.5px; line-height: 1.35; }
.revans { margin-top: 6px; font-size: 14.5px; font-weight: 600; }
.revans .bad { color: var(--T); font-weight: 800; } .revans .ok { color: var(--A); font-weight: 800; }
/* Marcador de duelo */
.dboard { display: grid; gap: 6px; margin: 8px 0; }
.dbrow { display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 14px; padding: 8px 12px; border-radius: 12px; background: var(--surface2); }
.dbrow.win { background: color-mix(in srgb, var(--A) 16%, var(--surface)); outline: 2px solid var(--A); }
.dbname { font-size: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dbstat { display: flex; flex-direction: column; align-items: flex-end; line-height: 1.05; min-width: 58px; }
.dbstat strong { font-size: 20px; font-family: var(--font-d); }
.dbstat strong small { font-size: 13px; color: var(--muted); }
.dbstat > small { font-size: 11.5px; color: var(--muted); font-weight: 700; }
/* Pantallas que se abren desde Inicio */
.pagehead { display: flex; align-items: center; gap: 8px; }
.pagehead h2 { margin: 0; font-size: 28px; flex: 1; }
.pagehero { padding: 22px 16px; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.pagehero h3 { margin: 4px 0 0; font-size: 22px; }
.pagehero p { margin: 0; font-size: 15px; font-weight: 600; }
.medal.big { width: 72px; height: 72px; }
.medal.big .ico { width: 34px; height: 34px; }
.chip.prize { font-size: 14px; font-weight: 800; padding: 6px 12px; background: color-mix(in srgb, var(--G) 18%, var(--surface)); }
.pstats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pstats.three { grid-template-columns: 1fr 1fr 1fr; }
.pstat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); padding: 14px 8px; display: flex; flex-direction: column; align-items: center; gap: 2px; }
.pstat b { font-family: var(--font-d); font-size: 30px; line-height: 1; }
.pstat span { font-size: 13.5px; font-weight: 700; color: var(--muted); text-align: center; }
.btn.big { font-size: 22px; padding: 18px; }
.sparkc { padding: 12px 16px; }
.spark { display: flex; align-items: flex-end; gap: 6px; height: 68px; margin-top: 6px; }
.spark i { flex: 1; border-radius: 6px 6px 2px 2px; background: color-mix(in srgb, var(--T) 70%, transparent); }
.spark i:last-child { background: var(--T); }
/* Sin seleccionar ni copiar el texto del juego (sí en campos de escritura, el código de recuperación y el panel docente) */
body { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
input, textarea, .code, .docent, .docent * { -webkit-user-select: text; user-select: text; -webkit-touch-callout: default; }
.code { user-select: all; -webkit-user-select: all; }
/* Panel docente: subir sesiones */
.packed .grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
@media (max-width: 480px) { .packed .grid2 { grid-template-columns: 1fr; } }
.packrow { border: 1px solid var(--line); border-radius: 14px; padding: 10px; display: grid; gap: 6px; background: var(--surface2); }
.packrow .input { font-size: 15px; padding: 8px 10px; }
.okmsg { color: var(--A); font-weight: 700; } .errmsg { color: var(--T); font-weight: 600; font-size: 14px; } .warnmsg { color: var(--G); font-weight: 600; font-size: 14px; }
.flabel { display: grid; gap: 4px; font-size: 13px; font-weight: 700; color: var(--muted); }
.chip.prize { display: inline-flex; align-items: center; gap: 6px; }
.classcard.row { display: flex; }

/* Palabra larga: varias líneas dentro de la misma bandeja (sin guion) */
.mask .w { flex-direction: column; align-items: flex-start; }
.mask .w .wl { display: flex; gap: 3px; }
.mask .w.multi { gap: 4px; border: 2px solid color-mix(in srgb, var(--ink) 12%, transparent); }
.mask .w.cont::after { content: none; }
.mask .w .wl { gap: 2px; }
.mask .w { padding: 5px 4px; }

/* Historial de duelos: filtro por rival y barra de cara a cara */
.hchips { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
.hchip { flex: none; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-weight: 800; font-size: 15px; color: var(--ink); }
.hchip.on { background: var(--ink); color: var(--surface); border-color: var(--ink); }
.h2hbar { display: flex; height: 30px; border-radius: 999px; overflow: hidden; gap: 2px; background: var(--surface2); }
.h2hbar i { display: grid; place-items: center; color: #fff; font-style: normal; font-weight: 900; font-size: 15px; min-width: 28px; }
.h2hbar i.w { background: var(--A); } .h2hbar i.t { background: #9AA3AE; } .h2hbar i.l { background: var(--T); }
.h2hlab { display: flex; justify-content: space-between; gap: 8px; font-size: 14px; font-weight: 800; margin-top: 4px; flex-wrap: wrap; }
.h2hlab .w { color: var(--A); } .h2hlab .t { color: var(--muted); } .h2hlab .l { color: var(--T); }

.countnum { font-size: 140px; padding-top: 60px; animation: pop .5s both; text-align: center; width: 100%; }
.spark i { position: relative; }
.spark i span { position: absolute; top: -18px; left: 0; right: 0; text-align: center; font-size: 11px; font-weight: 800; color: var(--muted); font-style: normal; }
.spark { margin-top: 22px; }
.bline { display: flex; justify-content: space-around; gap: 8px; font-size: 14px; font-weight: 700; color: var(--muted); }
.bline b { color: var(--ink); font-family: var(--font-d); font-size: 19px; margin-right: 2px; }

/* Estadísticas de cada modo: una tarjeta, rejilla de 3 */
.statcard { padding: 14px 10px; }
.stattitle { font-size: 13px; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; padding: 0 6px 8px; }
.statgrid { display: grid; grid-template-columns: repeat(3, 1fr); row-gap: 14px; }
.statcell { display: flex; flex-direction: column; align-items: center; gap: 2px; text-align: center; }
.statcell b { font-family: var(--font-d); font-size: 26px; line-height: 1.05; }
.statcell span { font-size: 12.5px; font-weight: 700; color: var(--muted); line-height: 1.2; }
.statcard .spark { margin: 26px 6px 0; }
.chip.prize { white-space: nowrap; flex-wrap: nowrap; }
.statcard .spark { margin: 22px 6px 0; height: 56px; }
.heroline { white-space: nowrap; font-size: 15px; font-weight: 600; color: var(--muted); }
.heroline b { color: var(--ink); font-weight: 800; }

.rprizes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.rprize { display: flex; gap: 8px; align-items: center; background: var(--surface2); border-radius: 12px; padding: 8px; min-width: 0; }
.rprize b { display: block; font-size: 13px; line-height: 1.15; }
.rprize small { display: block; font-size: 12px; font-weight: 700; color: var(--muted); }
.rprize .rk { width: 26px; height: 26px; }
