@font-face { font-family: 'Lexend'; src: url('/assets/fonts/Lexend-400.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Lexend'; src: url('/assets/fonts/Lexend-500.woff2') format('woff2'); font-weight: 500; font-display: swap; }
@font-face { font-family: 'Lexend'; src: url('/assets/fonts/Lexend-600.woff2') format('woff2'); font-weight: 600; font-display: swap; }
@font-face { font-family: 'Lexend'; src: url('/assets/fonts/Lexend-700.woff2') format('woff2'); font-weight: 700; font-display: swap; }
@font-face { font-family: 'Lexend'; src: url('/assets/fonts/Lexend-800.woff2') format('woff2'); font-weight: 800; font-display: swap; }
:root {
  /* Blanco, negro y gris (referencias: login de cristal, Forma AI, Salesrocket y SEOtalos).
     El único color es el burdeos, para lo importante (errores, derrotas, avisos); las rarezas
     de las skins mantienen su color propio (--tier, viene de los datos). */
  --bg: #000000;
  --bg-2: #060606;
  --surface: #0d0d0d;
  --surface-2: #161616;
  --border: #222222;
  --border-strong: #363636;
  /* Nombres heredados: «purple» ya es gris. Relleno oscuro para insignias, claro para bordes activos. */
  --purple: #2a2a2a;
  --purple-hover: #d9d9d9;
  --purple-deep: #141414;
  --blue: #9a9a9a;
  --lavender: #cfcfcf;
  --grad: linear-gradient(180deg, #ffffff 0%, #d6d6d6 100%);
  --grad-bar: linear-gradient(90deg, #4a4a4a, #b5b5b5 60%, #ffffff);
  --glow: rgba(255, 255, 255, 0.16);
  --glow-soft: rgba(255, 255, 255, 0.07);
  --silver: #d6d6d6;
  --win: #f2f2f2;
  --loss: #c4374f;
  --burgundy: #7a1c30;
  --burgundy-soft: rgba(122, 28, 48, .35);
  --ink: #000000;
  --glass: rgba(255, 255, 255, .045);
  --glass-border: rgba(255, 255, 255, .14);
  --text: #f5f5f5;
  --text-dim: #a3a3a3;
  --text-faint: #6b6b6b;
  --radius: 14px;
  --header-h: 64px;
  /* Alto real de la cabecera fija: incluye la zona de la barra de estado del iPhone (notch). */
  --header-total: calc(var(--header-h) + env(safe-area-inset-top));
  --bottom-nav-h: 0px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  /* Lexend en toda la web, con pesos altos (texto en negrita) */
  --display: 'Lexend', system-ui, sans-serif;
  --body: 'Lexend', system-ui, sans-serif;
  --mono: 'Lexend', system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-total) + 16px); }
html, body { overflow-x: hidden; }
@supports (overflow: clip) { html, body { overflow-x: clip; } }
body { margin: 0; background: var(--bg); color: var(--text); font: 500 15px/1.6 var(--body); font-variant-numeric: tabular-nums; min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }
@media (min-width: 768px) { body { font-size: 16px; } }
main { flex: 1; }
h1, h2, h3 { font-family: var(--display); font-weight: 800; letter-spacing: -0.02em; line-height: 1.12; margin: 0 0 .5rem; }
h1 { font-size: clamp(1.65rem, 5vw, 2.6rem); letter-spacing: -0.03em; }
h2 { font-size: 1.15rem; font-weight: 700; margin-top: 2.25rem; margin-bottom: .9rem; }
h3 { font-size: 1.05rem; font-weight: 700; letter-spacing: -0.01em; }
p { margin: 0 0 1rem; }
a { color: var(--text); text-underline-offset: 3px; }
img { display: block; max-width: 100%; }
svg { flex-shrink: 0; }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }
strong, b { font-weight: 700; }
.dim { color: var(--text-dim); }
.accent { color: var(--lavender); }
.grad { background: linear-gradient(90deg, #dedede, var(--lavender) 40%, #7d7d7d); -webkit-background-clip: text; background-clip: text; color: transparent; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 2px solid var(--lavender); outline-offset: 2px; border-radius: 6px; }
[hidden] { display: none !important; }
.wrap { width: 100%; max-width: 1160px; margin-inline: auto; padding-inline: 16px; }
@media (min-width: 768px) { .wrap { padding-inline: 32px; } }
.skip { position: absolute; left: 16px; top: -100px; z-index: 100; background: var(--purple); color: #ffffff; padding: .5rem 1rem; border-radius: 8px; }
.skip:focus { top: 12px; }

/* Vista activa: landing (sin sesión) o app (con sesión) */
body:not([data-view="landing"]) .only-landing { display: none !important; }
body:not([data-view="app"]) .only-app { display: none !important; }
body[data-view="loading"] main { visibility: hidden; }

/* ---------- Botones ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .45rem; font: 600 .92rem var(--body); color: var(--text); background: var(--surface-2); border: 1px solid var(--border-strong); border-radius: 10px; padding: .62rem 1.1rem; cursor: pointer; text-decoration: none; white-space: nowrap; transition: border-color .2s, background .2s, box-shadow .2s, transform .2s var(--ease); }
.btn:hover { border-color: var(--lavender); transform: translateY(-1px); }
.btn--primary { background: var(--purple); border-color: var(--purple); color: #ffffff; box-shadow: 0 0 0 0 var(--glow-soft); }
.btn--primary:hover { background: var(--purple-hover); border-color: var(--purple-hover); box-shadow: 0 6px 26px var(--glow); }
.btn--outline { background: transparent; border-color: var(--border-strong); }
.btn--ghost { background: transparent; padding: .45rem .85rem; font-size: .85rem; }
.btn--lg { padding: .85rem 1.4rem; font-size: 1rem; border-radius: 12px; }
.btn[disabled] { opacity: .6; cursor: progress; transform: none; }

/* ---------- Cabecera ---------- */
.topbar { position: sticky; top: 0; z-index: 50; height: var(--header-h); border-bottom: 1px solid rgba(34, 34, 34, .7); }
/* El desenfoque va en un pseudo-elemento: un backdrop-filter en .topbar atraparía los menús position: fixed */
.topbar::before { content: ''; position: absolute; inset: 0; z-index: -1; background: rgba(0, 0, 0, .72); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.topbar__inner { display: flex; align-items: center; gap: 1rem; height: 100%; min-width: 0; }
.topbar__inner > * { min-width: 0; }
.brand { display: inline-flex; align-items: center; gap: .55rem; text-decoration: none; font-family: var(--display); font-weight: 800; font-size: 1.1rem; letter-spacing: -0.01em; color: var(--silver); }
.brand b { color: var(--lavender); font-weight: 800; margin-left: .2rem; }

.site-nav { margin-left: auto; display: flex; align-items: center; gap: 1.75rem; }
.site-nav a:not(.btn) { color: var(--text-dim); text-decoration: none; font-size: .92rem; transition: color .2s; }
.site-nav a:not(.btn):hover { color: var(--text); }
.burger { display: none; margin-left: auto; width: 44px; height: 44px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); cursor: pointer; position: relative; }
.burger span { position: absolute; left: 12px; right: 12px; height: 2px; background: var(--silver); border-radius: 2px; transition: transform .3s var(--ease), top .3s var(--ease); }
.burger span:first-child { top: 16px; }
.burger span:last-child { top: 25px; }
.burger[aria-expanded="true"] span:first-child { top: 21px; transform: rotate(45deg); }
.burger[aria-expanded="true"] span:last-child { top: 21px; transform: rotate(-45deg); }

@media (max-width: 767px) {
  .burger { display: block; }
  .site-nav { position: fixed; inset: var(--header-total) 0 0; flex-direction: column; align-items: stretch; gap: 0; padding: 1rem 16px 2rem; background: var(--bg); visibility: hidden; opacity: 0; transform: translateY(-8px); transition: opacity .25s var(--ease), transform .25s var(--ease), visibility 0s .25s; }
  .site-nav.is-open { visibility: visible; opacity: 1; transform: none; transition: opacity .25s var(--ease), transform .25s var(--ease); }
  .site-nav a:not(.btn) { font-family: var(--display); font-weight: 700; font-size: 1.5rem; color: var(--text); padding: 1rem 0; border-bottom: 1px solid var(--border); }
  .site-nav__cta { margin-top: 1.5rem; padding: 1rem; font-size: 1rem; }
  body.menu-open { overflow: hidden; }
}

/* Menú de la app (pestañas) */
.app-nav { display: flex; gap: .25rem; margin-left: auto; padding: 4px; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; }
.tab { display: inline-flex; align-items: center; gap: .45rem; font: 600 .9rem var(--body); color: var(--text-dim); background: none; border: 0; border-radius: 9px; padding: .5rem .95rem; cursor: pointer; transition: color .2s, background .2s; }
.tab svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.tab:hover { color: var(--text); }
.tab[aria-selected="true"] { color: #ffffff; background: var(--purple); box-shadow: 0 2px 16px var(--glow-soft); }

.account { position: relative; }
.account__btn { display: inline-flex; align-items: center; gap: .55rem; max-width: 240px; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 5px 10px 5px 5px; color: var(--text); font: 600 .9rem var(--body); cursor: pointer; }
.account__btn:hover { border-color: var(--border-strong); }
.avatar { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 8px; background: linear-gradient(135deg, var(--purple-hover), var(--purple-deep)); color: #ffffff; font-family: var(--display); font-weight: 800; font-size: .9rem; }
.account__name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chev { width: 16px; height: 16px; fill: none; stroke: var(--text-dim); stroke-width: 2; transition: transform .2s; }
.account__btn[aria-expanded="true"] .chev { transform: rotate(180deg); }
.menu { position: absolute; right: 0; top: calc(100% + 8px); min-width: 230px; background: var(--surface); border: 1px solid var(--border-strong); border-radius: 12px; padding: .5rem; box-shadow: 0 18px 50px rgba(0, 0, 0, .7), 0 0 0 1px rgba(70, 70, 70, .08); }
.menu__meta { display: flex; align-items: center; gap: .4rem; font-size: .8rem; color: var(--text-dim); margin: 0; padding: .45rem .65rem; }
.menu__item { display: block; width: 100%; text-align: left; font: 600 .9rem var(--body); color: var(--text); background: none; border: 0; border-radius: 8px; padding: .6rem .65rem; text-decoration: none; cursor: pointer; }
.menu__item:hover { background: var(--surface-2); }
.menu__item--danger { color: var(--loss); }
.menu__meta + .menu__item { margin-top: .35rem; border-top: 1px solid var(--border); border-radius: 0 0 8px 8px; padding-top: .75rem; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--win); box-shadow: 0 0 8px var(--win); }

@media (max-width: 1023px) {
  body[data-view="app"] { --bottom-nav-h: calc(68px + env(safe-area-inset-bottom)); }
  .account { margin-left: auto; }
  .account__name { max-width: 34vw; }
  /* En móvil las pestañas pasan a una barra inferior fija, al alcance del pulgar */
  .app-nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; margin: 0; border-radius: 0; border: 0; border-top: 1px solid var(--border); background: rgba(0, 0, 0, .9); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); padding: 6px 8px calc(6px + env(safe-area-inset-bottom)); justify-content: space-around; }
  .tab { flex: 1; flex-direction: column; gap: 2px; font-size: .72rem; padding: .5rem .25rem; }
  .tab svg { width: 22px; height: 22px; }
  .app-nav .tab { max-width: 160px; }
  .tab[aria-selected="true"] { background: var(--glow-soft); color: var(--lavender); box-shadow: none; }
}

/* ---------- Hero (landing) ---------- */
.hero { position: relative; isolation: isolate; overflow: hidden; padding: clamp(4.5rem, 12vw, 8.5rem) 0 clamp(5rem, 12vw, 9rem); text-align: center; }
.hero__web { position: absolute; inset: 0; z-index: -2; background: url('/assets/img/web.svg') center top / cover no-repeat; opacity: .16; mask-image: radial-gradient(ellipse 70% 80% at 50% 0%, #000000 30%, transparent 75%); -webkit-mask-image: radial-gradient(ellipse 70% 80% at 50% 0%, #000000 30%, transparent 75%); }
/* Arco de luz morado, como en las referencias */
.hero__arc { position: absolute; z-index: -1; left: 50%; top: 24%; width: min(1500px, 190vw); aspect-ratio: 1; transform: translateX(-50%); border-radius: 50%; background: radial-gradient(circle at 50% 50%, var(--bg) 58%, transparent 59.5%); box-shadow: 0 -2px 0 1px rgba(207, 207, 207, .55), 0 -18px 60px 6px var(--glow), 0 -60px 160px 40px rgba(70, 70, 70, .35); }
.hero__arc::after { content: ''; position: absolute; inset: 0; border-radius: 50%; background: radial-gradient(circle at 50% 0%, rgba(70, 70, 70, .25), transparent 40%); }
.hero__inner { position: relative; display: flex; flex-direction: column; align-items: center; }
.pill { display: inline-flex; align-items: center; gap: .4rem; font: 500 .78rem var(--mono); color: var(--lavender); background: rgba(70, 70, 70, .12); border: 1px solid rgba(175, 175, 175, .28); border-radius: 999px; padding: .3rem .85rem; margin-bottom: 1.4rem; }
.pill--sm { margin-bottom: .75rem; font-size: .72rem; padding: .2rem .7rem; }
.hero h1 { font-size: clamp(2rem, 6.4vw, 4rem); max-width: 18ch; text-wrap: balance; letter-spacing: -0.03em; }
.hero__lead { color: var(--text-dim); font-size: clamp(1rem, 2vw, 1.12rem); max-width: 54ch; margin: 1rem auto 2rem; }
.hero__ctas { display: flex; flex-wrap: wrap; justify-content: center; gap: .75rem; }
@media (max-width: 480px) { .hero__ctas { flex-direction: column; align-self: stretch; } }

/* ---------- Secciones landing ---------- */
.section { padding-block: clamp(3.5rem, 8vw, 6rem); }
.section__title { font-size: clamp(1.6rem, 3.6vw, 2.4rem); font-weight: 800; text-align: center; margin: 0 0 .6rem; }
.section__lead { text-align: center; color: var(--text-dim); margin: 0 auto 2.5rem; max-width: 52ch; }

.features { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 720px) { .features { grid-template-columns: repeat(3, 1fr); } }
.feature { position: relative; background: linear-gradient(180deg, var(--surface-2), var(--surface)); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.6rem; transition: border-color .25s, transform .25s var(--ease); }
.feature:hover { border-color: var(--border-strong); transform: translateY(-2px); }
.feature p { color: var(--text-dim); margin: 0; font-size: .93rem; }
.feature__icon { width: 34px; height: 34px; margin-bottom: 1.4rem; fill: none; stroke: var(--lavender); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.feature--hl { background: linear-gradient(160deg, var(--purple-hover), var(--purple) 45%, var(--purple-deep)); border-color: transparent; box-shadow: 0 20px 60px var(--glow-soft); }
.feature--hl p { color: rgba(255, 255, 255, .82); }
.feature--hl .feature__icon { stroke: #ffffff; }

.band { background: linear-gradient(180deg, var(--purple-deep), #1c1c1c 60%, #101010); padding-block: clamp(3.5rem, 8vw, 5.5rem); border-block: 1px solid rgba(175, 175, 175, .2); }
.band .section__lead { color: rgba(255, 255, 255, .75); }
.band__steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 560px) { .band__steps { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 960px) { .band__steps { grid-template-columns: repeat(4, 1fr); } }
.band__steps li { border: 1px solid rgba(255, 255, 255, .22); border-radius: var(--radius); padding: 1.4rem; background: rgba(0, 0, 0, .12); }
.band__steps .mono { display: block; font-family: var(--display); font-weight: 800; font-size: 2rem; letter-spacing: -0.02em; color: #ffffff; margin-bottom: .8rem; }
.band__steps p { color: rgba(255, 255, 255, .75); margin: 0; font-size: .93rem; }

.login-card { max-width: 760px; margin-inline: auto; }
.steps { list-style: none; padding: 0; margin: 2rem 0 1rem; display: grid; gap: 1rem; }
.steps > li { display: grid; grid-template-columns: auto 1fr; gap: 1rem; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.35rem; }
.steps > li > div { min-width: 0; }
.steps h3 { margin-top: 0; }
.steps p { color: var(--text-dim); overflow-wrap: anywhere; }
.steps__n { color: var(--lavender); font-size: .85rem; padding-top: .15rem; }
@media (max-width: 480px) { .steps > li { grid-template-columns: 1fr; gap: .4rem; } }
.login-form { display: grid; gap: .6rem; grid-template-columns: 1fr; }
@media (min-width: 640px) { .login-form { grid-template-columns: 1fr auto auto; } }
input, select { font: inherit; color: var(--text); background: var(--bg); border: 1px solid var(--border-strong); border-radius: 10px; padding: .7rem .85rem; min-width: 0; min-height: 46px; transition: border-color .2s, box-shadow .2s; }
input:focus, select:focus { border-color: var(--purple-hover); box-shadow: 0 0 0 3px var(--glow-soft); outline: none; }
.form-error { color: var(--loss); margin: .75rem 0 0; min-height: 1.2em; }
.note { font-size: .85rem; color: var(--text-faint); text-align: center; }

/* ---------- App ---------- */
.app { position: relative; isolation: isolate; overflow-x: clip; padding: 2rem 0 calc(4rem + var(--bottom-nav-h)); }
.app__glow { position: absolute; z-index: -1; inset: -340px 0 auto; height: 520px; background: radial-gradient(ellipse 60% 50% at 50% 50%, rgba(70, 70, 70, .32), transparent 100%); pointer-events: none; }
.panel__head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1.25rem; margin-bottom: 1.75rem; }
.panel__head p:last-child { margin: 0; }
.countdown { color: var(--lavender); }

.wallet { display: flex; flex-wrap: wrap; gap: .6rem; margin: 0; }
.wallet div { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: .55rem .9rem; min-width: 92px; }
.wallet dt { color: var(--text-faint); font: 500 .68rem var(--mono); text-transform: uppercase; letter-spacing: .08em; }
.wallet dd { margin: 0; font-family: var(--display); font-weight: 800; font-size: 1.15rem; }
.wallet div:first-child { border-color: rgba(175, 175, 175, .35); }
@media (max-width: 480px) { .wallet { width: 100%; } .wallet div { flex: 1; min-width: 0; } }

.banner { display: flex; align-items: center; gap: .6rem; background: linear-gradient(90deg, rgba(70, 70, 70, .28), rgba(70, 70, 70, .08)); border: 1px solid rgba(175, 175, 175, .4); border-radius: var(--radius); padding: .9rem 1.1rem; margin-bottom: 1.25rem; }

.grid { display: grid; gap: 1rem; }
.grid--store { grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); }
.grid--small { grid-template-columns: repeat(auto-fill, minmax(min(100%, 170px), 1fr)); gap: .75rem; }
@media (max-width: 480px) { .grid--small { grid-template-columns: 1fr 1fr; } }
.skin { position: relative; display: flex; flex-direction: column; background: linear-gradient(180deg, var(--surface-2), var(--surface)); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; transition: border-color .25s, transform .25s var(--ease), box-shadow .25s; }
.skin:hover { border-color: var(--border-strong); transform: translateY(-2px); }
.skin::before { content: ''; position: absolute; inset: 0 0 auto; height: 2px; background: var(--tier, var(--border)); opacity: .9; }
.skin__img { aspect-ratio: 16 / 9; display: grid; place-items: center; padding: 1.1rem; background: radial-gradient(circle at 50% 65%, color-mix(in srgb, var(--tier, var(--purple)) 18%, transparent), transparent 70%); }
.skin__img img { max-height: 100%; object-fit: contain; filter: drop-shadow(0 8px 18px rgba(0, 0, 0, .6)); }
.skin__body { display: flex; align-items: center; justify-content: space-between; gap: .5rem; padding: .8rem 1rem 1rem; border-top: 1px solid rgba(34, 34, 34, .6); }
.skin__name { font-weight: 600; line-height: 1.3; min-width: 0; overflow-wrap: anywhere; }
.skin__meta { font: 500 .85rem var(--mono); color: var(--silver); white-space: nowrap; background: var(--bg); border: 1px solid var(--border); border-radius: 999px; padding: .15rem .6rem; }
.skin__tier { width: 18px; height: 18px; }
.skin--wished { border-color: var(--purple-hover); box-shadow: 0 0 0 1px var(--purple), 0 12px 40px var(--glow-soft); }
.skin__fav { position: absolute; z-index: 1; top: .6rem; right: .6rem; width: 36px; height: 36px; display: grid; place-items: center; border-radius: 10px; border: 1px solid var(--border-strong); background: rgba(0, 0, 0, .65); color: var(--text-dim); cursor: pointer; font-size: 1rem; transition: color .2s, border-color .2s, background .2s; }
.skin__fav:hover { color: var(--text); }
.skin__fav[aria-pressed="true"] { color: #ffffff; background: var(--purple); border-color: var(--purple); }
.grid--small .skin__body { padding: .6rem .75rem .75rem; font-size: .88rem; }
.grid--small .skin__img { padding: .8rem; }

.search-wrap { position: relative; margin-bottom: 1rem; }
.search-wrap svg { position: absolute; left: .9rem; top: 50%; width: 18px; height: 18px; transform: translateY(-50%); fill: none; stroke: var(--text-faint); stroke-width: 2; stroke-linecap: round; pointer-events: none; }
.search { width: 100%; padding-left: 2.6rem; }
.alerts { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1rem; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1rem 1.1rem; margin-bottom: 1.5rem; }
.alerts p { margin: 0; flex: 1 1 260px; color: var(--text-dim); font-size: .9rem; }

/* Estadísticas */
.stats-top { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 860px) { .stats-top { grid-template-columns: 320px 1fr; } }
.card { background: linear-gradient(180deg, var(--surface-2), var(--surface)); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.35rem; }
.rank { display: flex; align-items: center; gap: 1.1rem; background: linear-gradient(150deg, rgba(70, 70, 70, .35), var(--surface) 60%); border-color: rgba(175, 175, 175, .3); }
.rank img { width: 76px; height: 76px; filter: drop-shadow(0 6px 20px var(--glow)); }
.rank__name { font-family: var(--display); font-weight: 800; font-size: 1.45rem; letter-spacing: -0.01em; }
.rank__sub { color: var(--text-dim); font-family: var(--mono); font-size: .82rem; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(100px, 1fr)); gap: 1rem; align-content: center; }
@media (max-width: 480px) { .kpis { grid-template-columns: repeat(3, 1fr); gap: .9rem .5rem; } }
.kpi__label { color: var(--text-faint); font: 500 .68rem var(--mono); text-transform: uppercase; letter-spacing: .08em; }
.kpi__value { font-family: var(--display); font-weight: 800; font-size: clamp(1.3rem, 3vw, 1.75rem); }
.stats-cols { display: grid; gap: 0 1.5rem; grid-template-columns: 1fr; }
@media (min-width: 860px) { .stats-cols { grid-template-columns: 1fr 1fr; } }
.rows { display: grid; gap: .5rem; }
.row { display: grid; grid-template-columns: 38px 1fr auto auto; align-items: center; gap: .75rem; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: .5rem .8rem .5rem .5rem; }
.row img { width: 38px; height: 38px; border-radius: 8px; object-fit: cover; background: var(--surface-2); }
.row__num { font: 500 .82rem var(--mono); color: var(--text-dim); white-space: nowrap; }
@media (max-width: 480px) { .row { grid-template-columns: 38px 1fr auto; } .row__num:nth-of-type(2) { display: none; } }
.matches { display: grid; gap: .5rem; }
.match { display: grid; grid-template-columns: 3px 42px 1fr auto; align-items: center; gap: .8rem; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: .55rem .9rem .55rem 0; overflow: hidden; }
.match__bar { align-self: stretch; margin-block: -.55rem; background: var(--text-faint); }
.match--win .match__bar { background: var(--win); box-shadow: 0 0 12px var(--win); }
.match--loss .match__bar { background: var(--loss); box-shadow: 0 0 12px var(--loss); }
.match img { width: 42px; height: 42px; border-radius: 8px; background: var(--surface-2); }
.match > div { min-width: 0; }
.match__title { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.match__sub { font: 500 .78rem var(--mono); color: var(--text-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.match__kda { text-align: right; font: 500 .92rem var(--mono); }
.match__kda small { display: block; color: var(--text-dim); font-size: .72rem; }

.empty { color: var(--text-dim); padding: 1.5rem; border: 1px dashed var(--border-strong); border-radius: var(--radius); text-align: center; margin: 0; }
.status { color: var(--text-dim); text-align: center; min-height: 1.5em; margin: 0; padding-bottom: var(--bottom-nav-h); }
.status:empty { display: none; }
.status--error { color: var(--loss); }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--border); padding-block: 2.5rem calc(2rem + var(--bottom-nav-h)); font-size: .82rem; color: var(--text-faint); background: var(--bg-2); }
.footer__inner { display: grid; gap: 1.5rem; grid-template-columns: 1fr; }
@media (min-width: 768px) { .footer__inner { grid-template-columns: 1fr auto; } }
.footer__brand p { margin: .6rem 0 0; color: var(--text-dim); }
.footer__links { display: flex; flex-wrap: wrap; gap: .6rem 1.4rem; align-content: flex-start; }
.footer__links a { color: var(--text-dim); text-decoration: none; }
.footer__links a:hover { color: var(--lavender); }
.footer__legal { grid-column: 1 / -1; margin: 0; padding-top: 1.25rem; border-top: 1px solid var(--border); font-size: .75rem; line-height: 1.55; }

/* ---------- Páginas de texto ---------- */
.prose { max-width: 68ch; padding-block: 3rem 4rem; }
.prose h2 { margin-top: 2.25rem; }
.prose li { margin-bottom: .45rem; color: var(--text-dim); }
.prose li strong { color: var(--text); }
.notfound { text-align: center; padding-block: 7rem; }

/* ---------- Movimiento (respeta reduced-motion) ---------- */
@media (prefers-reduced-motion: no-preference) {
  .hero__inner > * { animation: rise .7s var(--ease) both; }
  .hero__inner > :nth-child(2) { animation-delay: .08s; }
  .hero__inner > :nth-child(3) { animation-delay: .16s; }
  .hero__inner > :nth-child(4) { animation-delay: .24s; }
  .hero__arc { animation: arc 1.4s var(--ease) both; }
  .skin { animation: rise .5s var(--ease) both; animation-delay: calc(var(--i, 0) * 70ms); }
  .reveal { opacity: 0; transform: translateY(20px); transition: opacity .6s var(--ease), transform .6s var(--ease); }
  .reveal.is-in { opacity: 1; transform: none; }
  @keyframes rise { from { opacity: 0; transform: translateY(14px); } }
  @keyframes arc { from { opacity: 0; transform: translateX(-50%) translateY(60px); } }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
.topbar__inner--split { justify-content: space-between; }

/* ---------- Iconos SVG (sin emojis) ---------- */
.ico { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; vertical-align: -3px; }
.ico--filled { fill: currentColor; }
.banner .ico { width: 20px; height: 20px; color: var(--lavender); fill: var(--glow-soft); }
.wallet dd { display: flex; align-items: center; gap: .4rem; }
.wallet dd img { width: 18px; height: 18px; }

/* ---------- Precio y datos de skin ---------- */
.skin__info { display: flex; flex-direction: column; gap: .15rem; min-width: 0; }
.skin__rarity { display: inline-flex; align-items: center; gap: .3rem; font: 500 .7rem var(--mono); color: var(--text-faint); text-transform: uppercase; letter-spacing: .06em; }
.skin__rarity .skin__tier { width: 14px; height: 14px; }
.price { display: inline-flex; align-items: center; gap: .35rem; font: 500 .85rem var(--mono); color: var(--silver); white-space: nowrap; background: var(--bg); border: 1px solid var(--border); border-radius: 999px; padding: .2rem .65rem; }
.price__icon { width: 14px; height: 14px; }
.price__old { color: var(--text-faint); font-size: .75rem; }
.skin__discount { position: absolute; top: .6rem; left: .6rem; background: var(--purple); color: #ffffff; font-size: .78rem; padding: .2rem .5rem; border-radius: 8px; box-shadow: 0 4px 16px var(--glow); }
.skin__noimg { font: 500 .75rem var(--mono); color: var(--text-faint); }
.skin__img { position: relative; }
.skin__fav .ico { width: 18px; height: 18px; }

/* ---------- Mercado nocturno y bundles ---------- */
.store-section { margin-top: 3rem; }
.store-section__head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: .5rem 1rem; margin-bottom: 1.1rem; }
.store-section__head h2 { margin: 0; font-size: clamp(1.3rem, 3vw, 1.7rem); font-weight: 800; }
.store-section__head p.dim { margin: 0; }
.pill--night { color: #ffffff; background: linear-gradient(90deg, var(--purple), var(--purple-deep)); border-color: transparent; }
#night-market { position: relative; padding: clamp(1rem, 3vw, 1.75rem); border-radius: calc(var(--radius) + 6px); border: 1px solid rgba(175, 175, 175, .25); background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(70, 70, 70, .28), transparent 70%), var(--bg-2); }
.grid--night { grid-template-columns: repeat(auto-fill, minmax(min(100%, 200px), 1fr)); }
@media (max-width: 480px) { .grid--night { grid-template-columns: 1fr 1fr; gap: .6rem; } .grid--night .skin__body { flex-direction: column; align-items: flex-start; padding: .6rem .7rem .75rem; } .grid--night .skin__name { font-size: .85rem; } }

.bundles { display: grid; gap: 1.5rem; }
.bundle { background: var(--surface); border: 1px solid var(--border); border-radius: calc(var(--radius) + 4px); overflow: hidden; }
.bundle__hero { position: relative; height: clamp(220px, 32vw, 340px); background: linear-gradient(135deg, var(--purple-deep), var(--bg)); }
.bundle__hero > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.bundle__overlay { position: absolute; inset: 0; display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding: clamp(1rem, 3vw, 1.6rem); background: linear-gradient(0deg, rgba(0, 0, 0, .92), rgba(0, 0, 0, .35) 55%, transparent); }
.bundle__name { font-size: clamp(1.4rem, 4vw, 2.2rem); font-weight: 800; margin: 0 0 .2rem; }
.bundle__ends { margin: 0; color: var(--text-dim); font-size: .9rem; }
.bundle__price .price { font-size: 1rem; padding: .4rem .9rem; background: rgba(0, 0, 0, .7); border-color: rgba(175, 175, 175, .4); }
.bundle__price .price__icon { width: 18px; height: 18px; }
.grid--bundle { grid-template-columns: repeat(auto-fill, minmax(min(100%, 200px), 1fr)); padding: 1rem; gap: .75rem; }
@media (max-width: 480px) { .grid--bundle { grid-template-columns: 1fr 1fr; padding: .75rem; gap: .6rem; } .grid--bundle .skin__body { flex-direction: column; align-items: flex-start; padding: .6rem .7rem .75rem; } .grid--bundle .skin__name { font-size: .85rem; } }
.bundle__extras { margin: 0; padding: 0 1rem 1rem; font-size: .85rem; }

/* ---------- Inventario ---------- */
.vp { display: inline-flex; align-items: center; gap: .4rem; font-family: var(--mono); white-space: nowrap; }
.vp img { width: 18px; height: 18px; }
.vp--xl { font-family: var(--display); font-weight: 800; font-size: clamp(2.2rem, 7vw, 3.4rem); letter-spacing: -0.02em; gap: .7rem; }
.vp--xl img { width: clamp(28px, 5vw, 40px); height: auto; }
.inv-value { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 860px) { .inv-value { grid-template-columns: 1fr 1.2fr; } }
.inv-total { display: flex; flex-direction: column; justify-content: center; background: radial-gradient(ellipse 90% 80% at 0% 0%, rgba(70, 70, 70, .45), transparent 70%), linear-gradient(180deg, var(--surface-2), var(--surface)); border-color: rgba(175, 175, 175, .35); }
.inv-total .kpi__label { margin: 0 0 .4rem; }
.inv-total__eur { margin: .4rem 0 0; color: var(--text-dim); }
.inv-breakdown { display: grid; gap: .1rem; }
.inv-line { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .55rem 0; border-bottom: 1px solid var(--border); }
.inv-line small { display: block; color: var(--text-faint); font-size: .75rem; }
.inv-counts { display: grid; grid-template-columns: repeat(3, 1fr); gap: .9rem .5rem; padding-top: .9rem; }
@media (min-width: 560px) { .inv-counts { grid-template-columns: repeat(6, 1fr); } }
.inv-counts__n { font-family: var(--display); font-weight: 800; font-size: 1.2rem; }
.inv-note { grid-column: 1 / -1; margin: 0; font-size: .8rem; color: var(--text-faint); }
.inv-hint { margin-top: -.4rem; font-size: .88rem; }

.loadout { display: grid; gap: 1.5rem; }
.loadout__cat { font: 500 .72rem var(--mono); text-transform: uppercase; letter-spacing: .08em; color: var(--text-faint); margin: 0 0 .6rem; }
.loadout__grid { display: grid; gap: .75rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr)); }
@media (max-width: 480px) { .loadout__grid { grid-template-columns: 1fr 1fr; gap: .6rem; } }
.weapon { position: relative; display: flex; flex-direction: column; background: linear-gradient(180deg, var(--surface-2), var(--surface)); border: 1px solid var(--border); border-radius: var(--radius); padding: 0; overflow: hidden; }
.weapon::before { content: ''; position: absolute; inset: 0 0 auto; height: 2px; background: var(--tier, var(--border)); }
.weapon__img { display: grid; place-items: center; aspect-ratio: 16 / 7; padding: .8rem 1rem; background: radial-gradient(circle at 50% 65%, color-mix(in srgb, var(--tier, var(--purple)) 16%, transparent), transparent 70%); }
.weapon__img img { max-height: 100%; object-fit: contain; filter: drop-shadow(0 6px 14px rgba(0, 0, 0, .6)); }
.weapon__body { display: flex; flex-direction: column; gap: .1rem; padding: .6rem .85rem .8rem; border-top: 1px solid rgba(34, 34, 34, .6); min-width: 0; }
.weapon__name { font: 500 .7rem var(--mono); text-transform: uppercase; letter-spacing: .06em; color: var(--lavender); }
.weapon__skin { font-weight: 600; font-size: .92rem; line-height: 1.3; overflow-wrap: anywhere; }
.weapon__count { font-size: .72rem; color: var(--text-faint); }

.weapon__name { display: flex; justify-content: space-between; gap: .5rem; }
.weapon__cat { color: var(--text-faint); text-transform: none; letter-spacing: 0; }
@media (max-width: 480px) { .weapon__cat { display: none; } }
@media (min-width: 1024px) { .loadout__grid { grid-template-columns: repeat(4, 1fr); } }
@media (max-width: 480px) { .grid--small .skin__body { flex-direction: column; align-items: flex-start; } .grid--small .skin__name { font-size: .85rem; } }

/* Ayuda del login */
.steps p strong { color: var(--text); font-weight: 600; }
.howto { margin: 0 0 1rem; background: var(--bg-2); border: 1px solid var(--border); border-radius: 12px; padding: .8rem 1rem; }
.howto summary { cursor: pointer; font-weight: 600; color: var(--lavender); }
.howto ul { margin: .75rem 0 .5rem; padding-left: 1.1rem; display: grid; gap: .5rem; color: var(--text-dim); font-size: .9rem; }
.howto li strong { color: var(--text); font-weight: 600; }
.howto__ok { margin: 0; font-size: .85rem; }
kbd { font: 500 .78rem var(--mono); background: var(--surface-2); border: 1px solid var(--border-strong); border-bottom-width: 2px; border-radius: 5px; padding: .05rem .35rem; color: var(--text); }

/* Vuelta automática desde Riot */
.howto__steps { margin: .75rem 0 .25rem; padding-left: 1.2rem; display: grid; gap: .55rem; color: var(--text-dim); font-size: .9rem; }
.howto__steps li strong { color: var(--text); font-weight: 600; }
.howto__steps .btn--ghost { margin-left: .25rem; padding: .3rem .7rem; }
.howto p { color: var(--text-dim); font-size: .9rem; margin: .7rem 0 .25rem; }
.form-info { color: var(--lavender); margin: .75rem 0 0; }
.form-info:empty, .form-error:empty { display: none; }

/* ---------- Buscador de jugadores ---------- */
.search-form { position: relative; display: flex; gap: .5rem; width: 100%; max-width: 560px; }
.search-form > svg { position: absolute; left: .95rem; top: 50%; width: 18px; height: 18px; transform: translateY(-50%); fill: none; stroke: var(--text-faint); stroke-width: 2; stroke-linecap: round; pointer-events: none; }
.search-form input { flex: 1; padding-left: 2.7rem; min-height: 50px; border-radius: 12px; background: rgba(0, 0, 0, .6); }
.search-form .btn { min-height: 50px; border-radius: 12px; }
.search-form--hero { margin-top: 1.5rem; }
@media (max-width: 480px) { .search-form .btn { padding-inline: .9rem; } }
.icon-btn { display: grid; place-items: center; width: 42px; height: 42px; margin-left: auto; border-radius: 12px; border: 1px solid var(--border); background: var(--surface); color: var(--text-dim); transition: color .2s, border-color .2s; }
.icon-btn:hover { color: var(--text); border-color: var(--border-strong); }
.icon-btn svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
@media (min-width: 1024px) { .icon-btn { margin-left: 0; } }
@media (max-width: 1023px) { .icon-btn + .account { margin-left: .5rem; } }

.player-page { position: relative; isolation: isolate; overflow-x: clip; padding: 2rem 0 4rem; }
.player-search { display: flex; flex-direction: column; align-items: flex-start; margin-bottom: 2rem; }
.player-search > p.dim { margin-bottom: 1.25rem; }
.recent { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; margin-top: .9rem; }
.recent__label { font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: var(--text-faint); margin-right: .25rem; }
.chip { font: 500 .82rem var(--mono); color: var(--text-dim); background: var(--surface); border: 1px solid var(--border); border-radius: 999px; padding: .3rem .75rem; cursor: pointer; }
.chip:hover { color: var(--text); border-color: var(--lavender); }

.player__banner { position: relative; display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1rem; min-height: 180px; padding: 1.4rem; margin-bottom: 1rem; border-radius: calc(var(--radius) + 4px); border: 1px solid rgba(175, 175, 175, .3); overflow: hidden; background: linear-gradient(0deg, rgba(0, 0, 0, .9), rgba(0, 0, 0, .35) 70%), var(--card, none) center / cover, linear-gradient(135deg, var(--purple-deep), var(--bg)); }
.player__id { display: flex; align-items: center; gap: 1rem; min-width: 0; }
.player__card { width: 72px; height: 72px; border-radius: 12px; border: 2px solid rgba(255, 255, 255, .25); object-fit: cover; }
.player__name { margin: 0; font-size: clamp(1.6rem, 5vw, 2.4rem); overflow-wrap: anywhere; }
.player__tag { color: var(--text-dim); font-weight: 700; margin-left: .15rem; }
.player__meta { margin: .3rem 0 0; color: var(--lavender); font-size: .85rem; }
.player-page .status { padding-bottom: 0; margin-top: 1rem; text-align: left; }
@media (max-width: 480px) {
  .topbar__inner { gap: .5rem; }
  .icon-btn { width: 40px; height: 40px; flex-shrink: 0; }
  .account { min-width: 0; }
  .account__btn { max-width: 100%; }
  .account__name { max-width: 28vw; }
  .brand { flex-shrink: 0; }
}
@media (max-width: 340px) { .account__name { display: none; } }

/* ---------- Estados de cada sección: cargando y error ---------- */
.panel.is-loading > :not(.panel__head):not(.panel-state),
.panel.is-error > :not(.panel__head):not(.panel-state) { display: none !important; }
.panel-state:empty { display: none; }
.panel-state { display: grid; gap: .75rem; }
.skeleton { height: 120px; border-radius: var(--radius); background: linear-gradient(90deg, var(--surface) 0%, var(--surface-2) 50%, var(--surface) 100%) 0 0 / 200% 100%; border: 1px solid var(--border); }
.skeleton--short { height: 64px; }
@media (prefers-reduced-motion: no-preference) { .skeleton { animation: shimmer 1.4s linear infinite; } @keyframes shimmer { to { background-position: -200% 0; } } }
.panel-error { display: flex; flex-direction: column; align-items: flex-start; gap: .25rem; padding: clamp(1.25rem, 4vw, 2rem); border-color: rgba(140, 140, 140, .35); background: radial-gradient(ellipse 80% 100% at 0% 0%, rgba(140, 140, 140, .12), transparent 70%), var(--surface); }
.panel-error h2 { margin: 0 0 .25rem; font-size: 1.2rem; }
.panel-error p { color: var(--text-dim); margin: 0 0 1rem; max-width: 52ch; }

/* ---------- Móvil: más aire y textos que no se salen ---------- */
@media (max-width: 480px) {
  .panel__head { margin-bottom: 1.25rem; }
  .panel__head h1 { font-size: 1.8rem; }
  h2 { font-size: 1.05rem; margin-top: 1.75rem; }
  .brand { font-size: 1rem; gap: .45rem; }
  .brand svg { width: 28px; height: 28px; }
  .card { padding: 1.1rem; }
  .rank img { width: 60px; height: 60px; }
  .rank__name { font-size: 1.25rem; }
  .btn--lg { padding: .8rem 1.1rem; }
  .section__title { font-size: 1.55rem; }
}
@media (max-width: 480px) { .search-form--hero input::placeholder { font-size: .85rem; } }

/* ---------- Selector de idioma ---------- */
.langs { display: inline-flex; gap: 2px; padding: 3px; background: var(--surface); border: 1px solid var(--border); border-radius: 10px; }
.langs a { font: 700 .75rem var(--body); letter-spacing: .04em; color: var(--text-dim); text-decoration: none; padding: .32rem .55rem; border-radius: 7px; transition: color .2s, background .2s; }
.langs a:hover { color: var(--text); }
.langs a[aria-current="true"] { color: #ffffff; background: var(--purple); }
.site-nav .langs { order: 0; }
.menu__langs { padding: .45rem .65rem .2rem; }
.menu__langs .langs { width: 100%; justify-content: space-between; }
.menu__langs .langs a { flex: 1; text-align: center; }
.footer__inner > .langs { justify-self: start; }
.topbar__actions { display: flex; align-items: center; gap: .6rem; min-width: 0; }
@media (max-width: 767px) {
  .site-nav .langs { align-self: flex-start; margin-top: 1.25rem; }
  .site-nav .langs a { font-size: .9rem; padding: .5rem .9rem; }
}
@media (max-width: 480px) {
  .topbar__actions .langs { display: none; }
}

/* ---------- Próximamente (candado) ---------- */
.panel.is-soon > :not(.panel__head):not(.panel-state) { display: none !important; }
.soon { position: relative; display: grid; place-items: center; min-height: 340px; border-radius: calc(var(--radius) + 4px); overflow: hidden; border: 1px solid rgba(175, 175, 175, .25); background: var(--bg-2); }
.soon__preview { position: absolute; inset: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: .75rem; padding: 1rem; filter: blur(6px); opacity: .55; pointer-events: none; }
.soon__preview span { border-radius: var(--radius); background: linear-gradient(160deg, rgba(70, 70, 70, .35), var(--surface) 70%); border: 1px solid var(--border); }
.soon__card { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; text-align: center; max-width: 440px; margin: 1.5rem; padding: clamp(1.4rem, 4vw, 2rem); border-radius: calc(var(--radius) + 2px); background: rgba(0, 0, 0, .78); border: 1px solid rgba(175, 175, 175, .35); box-shadow: 0 20px 60px rgba(0, 0, 0, .6), 0 0 40px var(--glow-soft); backdrop-filter: blur(6px); }
.soon__card h2 { margin: .2rem 0 .5rem; font-size: 1.35rem; }
.soon__card p:last-child { color: var(--text-dim); margin: 0; }
.soon__card .pill { margin-bottom: .5rem; }
.soon__lock { width: 44px; height: 44px; margin-bottom: .9rem; padding: 10px; border-radius: 14px; background: var(--purple); fill: none; stroke: #ffffff; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; box-shadow: 0 8px 26px var(--glow); }
.player-search.is-soon .search-form, .player-search.is-soon .recent, .player-search.is-soon > p.dim, .player-search.is-soon .form-error { display: none; }
.soon-wrap { width: 100%; }
.tab--soon::after { content: ''; width: 7px; height: 7px; margin-left: .15rem; border-radius: 50%; background: var(--lavender); box-shadow: 0 0 8px var(--lavender); }
@media (max-width: 1023px) { .tab--soon { position: relative; } .tab--soon::after { position: absolute; top: .45rem; right: calc(50% - 18px); margin: 0; } }

/* ===================== Herramientas: páginas comunes ===================== */
.tool-page { position: relative; isolation: isolate; overflow-x: clip; padding: 2rem 0 4rem; }
.tool-head { margin-bottom: 1.75rem; max-width: 70ch; }
.tool-head p.dim { margin: 0; }
.tool-head--row { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1rem; max-width: none; }
.tool-head--row > div { max-width: 70ch; }
.section--tight { padding-top: 0; }
.feature--link { color: inherit; text-decoration: none; display: block; }
.feature--link:hover { border-color: var(--purple-hover); }
.field { display: flex; flex-direction: column; gap: .35rem; min-width: 0; }
.field > span { font-size: .82rem; font-weight: 600; color: var(--text-dim); }
.field small { font-size: .75rem; }
textarea { font: inherit; color: var(--text); background: var(--bg); border: 1px solid var(--border-strong); border-radius: 10px; padding: .7rem .85rem; resize: vertical; width: 100%; }
textarea:focus { border-color: var(--purple-hover); box-shadow: 0 0 0 3px var(--glow-soft); outline: none; }
.chip[aria-pressed="true"] { color: #ffffff; background: var(--purple); border-color: var(--purple); }
.site-nav a[aria-current="page"] { color: var(--text); }

/* ===================== Sensibilidad ===================== */
.aim-setup { display: grid; gap: 1.25rem; }
.aim-form { display: grid; gap: .9rem; grid-template-columns: 1fr; }
@media (min-width: 720px) { .aim-form { grid-template-columns: 1fr 1fr 1.3fr; } }
.aim-metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: .75rem; }
.aim-metrics > div { background: var(--bg); border: 1px solid var(--border); border-radius: 12px; padding: .8rem 1rem; }
@media (max-width: 480px) { .aim-metrics { gap: .5rem; } .aim-metrics > div { padding: .65rem .7rem; } .aim-metrics .kpi__value { font-size: 1.2rem; } }
.edpi-scale { position: relative; padding-top: 6px; }
.edpi-scale__band { height: 10px; border-radius: 999px; background: linear-gradient(90deg, var(--surface-2) 0%, var(--surface-2) 25%, rgba(70, 70, 70, .65) 25%, rgba(97, 97, 97, .9) 50%, rgba(70, 70, 70, .65) 75%, var(--surface-2) 75%); border: 1px solid var(--border); }
.edpi-scale__marker { position: absolute; top: 0; width: 4px; height: 22px; margin-left: -2px; border-radius: 2px; background: #ffffff; box-shadow: 0 0 10px var(--glow); transition: left .25s var(--ease); }
.edpi-scale__labels { display: flex; justify-content: space-between; margin-top: .35rem; font-size: .72rem; color: var(--text-faint); }
.edpi-note { margin: 0; font-size: .88rem; }
.aim-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem 1rem; }
.aim-actions .form-error { margin: 0; }
.aim-stage { margin-top: 1.5rem; }
.aim-hud { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1rem; margin-bottom: .6rem; font-size: .9rem; }
.aim-hud .pill { margin: 0; }
.aim-canvas-wrap { position: relative; width: 100%; border-radius: calc(var(--radius) + 4px); overflow: hidden; border: 1px solid rgba(175, 175, 175, .3); background: #060606; cursor: crosshair; }
.aim-canvas-wrap canvas { display: block; width: 100%; }
.aim-overlay { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .75rem; padding: 1.5rem; text-align: center; background: rgba(0, 0, 0, .72); backdrop-filter: blur(3px); }
.aim-overlay h2 { margin: 0; font-size: 1.5rem; }
.aim-overlay p { margin: 0; color: var(--text-dim); max-width: 48ch; }
.aim-tip { font-size: .82rem; margin-top: .6rem; }
.aim-result { display: grid; gap: 1rem; grid-template-columns: 1fr; margin-top: 1.5rem; }
@media (min-width: 900px) { .aim-result { grid-template-columns: 1fr 1fr; } }
.aim-result__main { display: grid; gap: 1rem; background: radial-gradient(ellipse 90% 80% at 0% 0%, rgba(70, 70, 70, .45), transparent 70%), linear-gradient(180deg, var(--surface-2), var(--surface)); border-color: rgba(175, 175, 175, .35); }
.aim-result__main .kpi__label { margin: 0; }
.aim-result__sens { font-family: var(--display); font-weight: 800; font-size: clamp(2.6rem, 9vw, 4rem); letter-spacing: -0.03em; line-height: 1; }
.aim-result h2 { margin-top: 0; }
.rounds { display: grid; gap: .9rem; margin-bottom: 1rem; }
.round { display: grid; gap: .3rem; }
.round__n { font-size: .75rem; color: var(--text-faint); text-transform: uppercase; letter-spacing: .06em; }
.round__bar { display: grid; grid-template-columns: 4.5rem 1fr 3rem; align-items: center; gap: .6rem; font-size: .85rem; color: var(--text-dim); }
.round__track { height: 8px; border-radius: 999px; background: var(--bg); overflow: hidden; }
.round__track span { display: block; height: 100%; border-radius: inherit; background: var(--border-strong); }
.round__bar--win { color: var(--text); }
.round__bar--win .round__track span { background: linear-gradient(90deg, var(--purple), var(--purple-hover)); }
.round__score { text-align: right; }
.round__tie { font-size: .75rem; color: var(--text-faint); }

/* ===================== Pros ===================== */
.pros__bar { display: flex; flex-wrap: wrap; gap: .6rem; margin-bottom: 1rem; }
.pros__bar .search-wrap { flex: 1 1 260px; margin: 0; }
.pros__list { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); }
.pros__list > .soon { grid-column: 1 / -1; }
.pro { display: grid; gap: .9rem; }
.pro__head { display: flex; justify-content: space-between; gap: 1rem; }
.pro__name { margin: 0; font-size: 1.25rem; display: flex; align-items: center; gap: .5rem; }
.pro__country { font-size: .7rem; padding: .1rem .4rem; border-radius: 6px; background: var(--bg); border: 1px solid var(--border); color: var(--text-dim); }
.pro__team { margin: .15rem 0 0; font-size: .88rem; }
.pro__xhair { width: 72px; height: 72px; border-radius: 10px; flex-shrink: 0; }
.pro__stats { display: grid; grid-template-columns: repeat(5, 1fr); gap: .5rem; }
.pro__stat { font-family: var(--display); font-weight: 800; font-size: 1.05rem; }
.pro__meta { display: grid; grid-template-columns: auto 1fr; gap: .25rem .75rem; margin: 0; font-size: .85rem; }
.pro__meta dt { color: var(--text-faint); }
.pro__meta dd { margin: 0; overflow-wrap: anywhere; }
.pro__foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem; padding-top: .6rem; border-top: 1px solid var(--border); }
.pro__source { color: var(--lavender); font-size: .82rem; }
@media (max-width: 400px) { .pro__stats { grid-template-columns: repeat(3, 1fr); } }

.xhair { display: grid; gap: 1.25rem; grid-template-columns: 1fr; align-items: center; margin-top: 2.5rem; }
@media (min-width: 720px) { .xhair { grid-template-columns: 1fr 220px; } }
.xhair h2 { margin-top: 0; }
.xhair textarea { margin: .75rem 0; font-size: .85rem; }
.xhair__canvas { width: 100%; max-width: 220px; aspect-ratio: 1; border-radius: 14px; border: 1px solid var(--border); justify-self: center; }

.lb { margin-top: 2.5rem; }
.lb .store-section__head select { min-width: 160px; }
.lb__rows { list-style: none; margin: 0; padding: 0; display: grid; gap: .4rem; }
.lb__row { display: grid; grid-template-columns: 3.2rem 32px 1fr auto auto; align-items: center; gap: .75rem; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: .45rem .8rem .45rem .6rem; }
.lb__row img, .lb__noimg { width: 32px; height: 32px; border-radius: 8px; background: var(--surface-2); object-fit: cover; }
.lb__rank { color: var(--lavender); font-weight: 700; }
.lb__name { color: var(--text); text-decoration: none; font-weight: 600; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lb__name:hover { color: var(--lavender); }
.lb__rr { font-weight: 700; }
.lb__wins { font-size: .82rem; }
@media (max-width: 520px) { .lb__row { grid-template-columns: 2.6rem 32px 1fr auto; } .lb__wins { display: none; } }
.lb__list > .soon { min-height: 260px; }

/* ===================== Lineups ===================== */
.lu-maps { display: flex; gap: .5rem; overflow-x: auto; padding-bottom: .4rem; margin-bottom: 1rem; scrollbar-width: thin; }
.lu-mapbtn { position: relative; flex: 0 0 auto; display: flex; align-items: flex-end; justify-content: space-between; gap: .5rem; width: 150px; height: 64px; padding: .5rem .65rem; border-radius: 12px; border: 1px solid var(--border); color: #ffffff; font: 700 .9rem var(--body); text-align: left; cursor: pointer; background: linear-gradient(0deg, rgba(0, 0, 0,.85), rgba(0, 0, 0,.25)), var(--bg, none) center / cover, var(--surface); }
.lu-mapbtn[aria-selected="true"] { border-color: var(--purple-hover); box-shadow: 0 0 0 1px var(--purple), 0 8px 24px var(--glow-soft); }
.lu-mapbtn__n { font-size: .72rem; background: var(--purple); border-radius: 6px; padding: .05rem .4rem; }
.lu-filters { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem; margin-bottom: 1rem; }
.lu-agents { display: flex; flex-wrap: wrap; gap: .35rem; }
.lu-agent { width: 40px; height: 40px; display: grid; place-items: center; padding: 3px; border-radius: 10px; border: 1px solid var(--border); background: var(--surface); color: var(--text-dim); cursor: pointer; font-size: .62rem; }
.lu-agent img { width: 100%; height: 100%; border-radius: 7px; object-fit: cover; }
.lu-agent--empty img { opacity: .4; filter: grayscale(.6); }
.lu-agent[aria-pressed="true"] { border-color: var(--purple-hover); box-shadow: 0 0 0 2px var(--purple); }
.lu-agent[aria-pressed="true"] img { opacity: 1; filter: none; }
.lu-chips { display: flex; flex-wrap: wrap; gap: .5rem; }
.lu-layout { display: grid; gap: 1rem; grid-template-columns: 1fr; align-items: start; }
@media (min-width: 960px) { .lu-layout { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); } .lu-map { position: sticky; top: calc(var(--header-total) + 16px); } }
.lu-map { padding: .75rem; }
.minimap { position: relative; width: 100%; aspect-ratio: 1; border-radius: 12px; overflow: hidden; background: radial-gradient(circle, var(--surface-2), var(--bg)); }
.minimap > img { width: 100%; height: 100%; object-fit: contain; }
.minimap__layer { position: absolute; inset: 0; width: 100%; height: 100%; }
.minimap--pick { cursor: crosshair; }
.lu-legend { display: flex; align-items: center; gap: .4rem; margin: .6rem 0 0; font-size: .82rem; }
.lu-dot { width: 12px; height: 12px; border-radius: 50%; display: inline-block; }
.lu-dot--from { background: #e1e1e1; margin-left: .5rem; }
.lu-dot--from:first-child { margin-left: 0; }
.lu-dot--to { background: var(--purple-hover); margin-left: .75rem; }
.lu-line { stroke: rgba(255, 255, 255,.75); stroke-width: 4; stroke-dasharray: 10 8; }
.lu-pt--from { fill: #e1e1e1; stroke: #000000; stroke-width: 3; }
.lu-pt--to { fill: rgba(97, 97, 97, .9); stroke: #ffffff; stroke-width: 3; }
.lu-mark { cursor: pointer; }
.lu-mark.is-hover .lu-pt--to { fill: #ffffff; }
.lu-mark.is-hover .lu-line { stroke: #ffffff; stroke-dasharray: none; }
.lu-list { display: grid; gap: .6rem; }
.lu-card { display: flex; gap: .8rem; width: 100%; text-align: left; font: inherit; color: var(--text); background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: .7rem; cursor: pointer; transition: border-color .2s, transform .2s var(--ease); }
.lu-card:hover, .lu-card.is-hover { border-color: var(--purple-hover); transform: translateY(-1px); }
.lu-card__icons { position: relative; flex-shrink: 0; width: 52px; height: 52px; }
.lu-card__agent { width: 52px; height: 52px; border-radius: 10px; background: var(--surface-2); }
.lu-card__ability { position: absolute; right: -6px; bottom: -6px; width: 26px; height: 26px; padding: 3px; border-radius: 8px; background: var(--purple); }
.lu-card__body { display: flex; flex-direction: column; gap: .25rem; min-width: 0; }
.lu-card__title { font-weight: 700; overflow-wrap: anywhere; }
.lu-card__sub { font-size: .82rem; }
.lu-tags { display: flex; flex-wrap: wrap; gap: .3rem; margin-top: .15rem; }
.tag { font-size: .7rem; font-weight: 600; padding: .12rem .5rem; border-radius: 999px; background: var(--bg); border: 1px solid var(--border); color: var(--text-dim); }
.tag--smoke { color: #d7d7d7; border-color: rgba(175, 175, 175,.45); }
.tag--molly { color: #bfbfbf; border-color: rgba(167, 167, 167,.45); }
.tag--recon { color: #e1e1e1; border-color: rgba(225, 225, 225,.4); }
.tag--flash { color: #f1f1f1; border-color: rgba(235, 235, 235,.4); }
.lu-empty { display: flex; flex-direction: column; align-items: center; gap: .75rem; }
.lu-empty p { margin: 0; }
.lu-login { display: flex; flex-direction: column; align-items: flex-start; gap: .75rem; }
.lu-notes { white-space: pre-line; }

.modal { width: min(760px, calc(100vw - 24px)); max-height: min(90vh, 960px); padding: 0; color: var(--text); background: var(--bg-2); border: 1px solid var(--border-strong); border-radius: 18px; box-shadow: 0 30px 90px rgba(0, 0, 0,.8), 0 0 0 1px rgba(70, 70, 70,.15); }
.modal--wide { width: min(980px, calc(100vw - 24px)); }
.modal::backdrop { background: rgba(0, 0, 0,.75); backdrop-filter: blur(4px); }
.modal__head { position: sticky; top: 0; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1rem 1.25rem; background: var(--bg-2); border-bottom: 1px solid var(--border); }
.modal__head h2 { margin: 0; font-size: 1.2rem; }
.modal__close { width: 40px; height: 40px; flex-shrink: 0; display: grid; place-items: center; background: var(--surface); border: 1px solid var(--border); border-radius: 10px; color: var(--text); cursor: pointer; }
.modal__body { padding: 1.25rem; display: grid; gap: .9rem; }
.modal__body > p { margin: 0; }
@media (max-width: 480px) { .modal, .modal--wide { width: 100vw; max-width: 100vw; max-height: 94dvh; margin: auto 0 0; border-radius: 18px 18px 0 0; } }
.video { position: relative; width: 100%; aspect-ratio: 16 / 9; border-radius: 12px; overflow: hidden; background: #000000; }
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

.lu-form { display: grid; gap: .9rem; }
.lu-form__grid { display: grid; gap: .75rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 170px), 1fr)); }
.lu-form__map { display: grid; gap: .6rem; }
.lu-form__map .minimap { max-width: 520px; }
.lu-form__marks { display: flex; flex-wrap: wrap; gap: .4rem; }
.chip--from[aria-pressed="true"] { background: #666666; border-color: #e1e1e1; }

/* ===================== Panel ===================== */
.admin-login { display: grid; gap: .8rem; max-width: 460px; }
.tabs-inline { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: 1rem; }
.admin-list { display: grid; gap: .8rem; margin-top: 1rem; }
.admin-item { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 760px) { .admin-item { grid-template-columns: 320px 1fr; } }
.admin-item h3 { margin: 0 0 .25rem; }
.admin-item p { margin: 0 0 .4rem; }
.admin-item--row { grid-template-columns: 1fr auto !important; align-items: center; }
/* Formulario de lineup: en pantallas anchas el minimapa va a la derecha de los campos. */
@media (min-width: 900px) {
  .lu-form { grid-template-columns: minmax(0, 1fr) minmax(0, 400px); align-items: start; column-gap: 1.25rem; }
  .lu-form > * { grid-column: 1; }
  .lu-form > .lu-form__map { grid-column: 2; grid-row: 1 / span 5; position: sticky; top: 80px; }
  .lu-form__grid { grid-template-columns: repeat(auto-fill, minmax(min(100%, 150px), 1fr)); }
}
.aim-result__main, .aim-result > .card { align-content: start; }
.aim-stage, .aim-result, .aim-setup { scroll-margin-top: calc(var(--header-total) + 12px); }

/* ===================== Rediseño: fondo, botones y paneles ===================== */
body { background: radial-gradient(ellipse 90% 60% at 50% -10%, rgba(80, 80, 80, .28), transparent 60%), radial-gradient(ellipse 60% 40% at 100% 30%, rgba(85, 85, 85, .12), transparent 60%), var(--bg); background-attachment: fixed; }
.topbar::before { background: rgba(7, 7, 7, .78); }
.btn--primary { background: var(--grad); border-color: transparent; box-shadow: 0 6px 22px rgba(85, 85, 85, .35), inset 0 1px 0 rgba(255, 255, 255, .18); }
.btn--primary:hover { background: linear-gradient(135deg, #989898 0%, #676767 55%, #646464 100%); border-color: transparent; box-shadow: 0 8px 30px var(--glow), inset 0 1px 0 rgba(255, 255, 255, .25); }
.btn--primary:active { background: linear-gradient(135deg, #434343, #303030); transform: translateY(0); box-shadow: inset 0 2px 8px rgba(0, 0, 0, .35); }
.btn--outline:hover, .btn:not(.btn--primary):not(.btn--ghost):hover { background: rgba(189, 189, 189, .08); }
.btn[disabled], .btn:disabled { background: #2a2a2a; color: var(--text-faint); box-shadow: none; border-color: transparent; }
.card, .feature, .skin, .weapon, .row, .match, .lu-card, .steps > li { background: linear-gradient(180deg, rgba(25, 25, 25, .9), rgba(17, 17, 17, .9)); }
.card { box-shadow: inset 0 1px 0 rgba(189, 189, 189, .06); }
.tab[aria-selected="true"] { background: var(--grad); }
.pill { background: rgba(85, 85, 85, .16); border-color: rgba(189, 189, 189, .32); }
input, select, textarea { background: rgba(7, 7, 7, .7); }
.round__bar--win .round__track span, .bar__fill { background: var(--grad-bar); }
.edpi-scale__band { background: linear-gradient(90deg, var(--surface-2) 0%, var(--surface-2) 25%, #737373 25%, #6e6e6e 50%, #737373 75%, var(--surface-2) 75%); }
.app-nav { background: rgba(17, 17, 17, .85); }
.skin__fav[aria-pressed="true"], .lu-mapbtn__n, .pill--night { background: var(--grad); }
/* Interruptor ON/OFF tipo panel (Stutter Edit) para estados */
.switch { display: inline-flex; align-items: center; gap: .45rem; padding: .2rem .25rem .2rem .6rem; border-radius: 999px; font: 700 .7rem var(--body); letter-spacing: .06em; background: rgba(7, 7, 7, .8); border: 1px solid var(--border-strong); color: var(--text-faint); }
.switch::after { content: ''; width: 14px; height: 14px; border-radius: 50%; background: var(--text-faint); }
.switch--on { color: #ffffff; background: linear-gradient(90deg, #4f4f4f, #737373); border-color: #929292; }
.switch--on::after { background: #ffffff; box-shadow: 0 0 8px #aaaaaa; }

/* ===================== Anillos ===================== */
.ring { position: relative; width: var(--size); height: var(--size); flex-shrink: 0; }
.ring__svg { width: 100%; height: 100%; display: block; }
.ring__track { fill: none; stroke: rgba(189, 189, 189, .14); }
.ring__bar { fill: none; stroke-linecap: round; filter: drop-shadow(0 0 6px rgba(110, 110, 110, .55)); }
.ring__text { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; line-height: 1.05; }
.ring__label { font-weight: 700; font-size: calc(var(--size) * .26); }
.ring__sub { font-size: calc(var(--size) * .1); color: var(--text-dim); margin-top: .15em; }
.ring--big .ring__label { font-weight: 800; font-size: 3rem; letter-spacing: -0.03em; }
.ring--big .ring__sub { font-size: .9rem; }

/* ===================== Racha ===================== */
.streak-top { display: grid; gap: 1rem; grid-template-columns: 1fr; margin-bottom: 1rem; }
@media (min-width: 860px) { .streak-top { grid-template-columns: 1fr 1fr; } }
.streak-card { display: flex; align-items: center; gap: 1.4rem; background: radial-gradient(ellipse 80% 100% at 0% 0%, rgba(85, 85, 85, .32), transparent 70%), linear-gradient(180deg, rgba(25, 25, 25, .95), rgba(17, 17, 17, .95)); border-color: rgba(189, 189, 189, .3); }
.streak-card--locked { padding: 0; background: none; border: 0; }
.streak-card--locked .soon { width: 100%; min-height: 230px; }
.streak-card__body { min-width: 0; }
.streak-card__body .kpi__label { margin: 0 0 .25rem; }
.streak-card__goal { font-size: 1.15rem; font-weight: 700; margin: 0 0 .25rem; }
.streak-card__hint { margin: 0 0 .9rem; font-size: .88rem; }
.streak-card__stats { display: flex; gap: 1.5rem; margin: 0; }
.streak-card__stats dt { font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: var(--text-faint); }
.streak-card__stats dd { margin: 0; font-weight: 800; font-size: 1.3rem; }
@media (max-width: 480px) { .streak-card { flex-direction: column; align-items: flex-start; } }
.streak-week h2, .streak-cols h2, #year-title { margin-top: 0; }
.week { display: grid; grid-template-columns: repeat(7, 1fr); gap: .4rem; justify-items: center; }
.week__day { display: flex; flex-direction: column; align-items: center; gap: .3rem; }
.week__n { font-size: .72rem; color: var(--text-faint); }
.streak-legend { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; font-size: .8rem; margin: 1rem 0 0; }
.legend-dot { width: 12px; height: 12px; border-radius: 50%; display: inline-block; }
.legend-dot--visit { border: 2px solid var(--lavender); }
.legend-dot--play { background: var(--grad); margin-left: .6rem; }
.day { position: relative; }
.day .ring__label { font-size: calc(var(--size) * .3); font-weight: 600; color: var(--text-dim); }
.day--visit .ring__track { stroke: var(--lavender); stroke-opacity: .85; }
.day--visit .ring__label, .day--played .ring__label { color: var(--text); }
.day--today .ring__svg { filter: drop-shadow(0 0 8px rgba(189, 189, 189, .6)); }
.day--today .ring__label { color: #ffffff; font-weight: 800; }
.day--future { opacity: .35; }
.streak-cols { display: grid; gap: 1rem; grid-template-columns: 1fr; margin: 1rem 0; }
@media (min-width: 860px) { .streak-cols { grid-template-columns: 1.3fr 1fr; } }
.cal-head { display: flex; align-items: center; justify-content: space-between; gap: .5rem; margin-bottom: .9rem; }
.cal-head h2 { margin: 0; text-transform: capitalize; font-size: 1.2rem; }
.cal-head .icon-btn { margin: 0; }
.cal-head .icon-btn:disabled { opacity: .35; cursor: default; }
.cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: .45rem .25rem; justify-items: center; }
.cal__head { font-size: .72rem; font-weight: 700; color: var(--text-faint); text-transform: capitalize; }
.streak-bars { position: relative; }
.streak-bars > p.dim { margin: -.6rem 0 1rem; font-size: .85rem; }
.bars { display: grid; grid-template-columns: repeat(7, 1fr); gap: .5rem; align-items: end; height: 220px; }
.bar { display: flex; flex-direction: column; align-items: center; gap: .35rem; height: 100%; }
.bar__n { font-size: .75rem; color: var(--text-dim); }
.bar__track { position: relative; flex: 1; width: 18px; border-radius: 999px; background: rgba(189, 189, 189, .1); overflow: hidden; }
.bar__fill { position: absolute; left: 0; right: 0; bottom: 0; border-radius: inherit; background: linear-gradient(0deg, #737373, #6e6e6e 60%, #bdbdbd); box-shadow: 0 0 12px rgba(110, 110, 110, .5); }
.bar__label { font-size: .72rem; font-weight: 700; color: var(--text-faint); text-transform: capitalize; padding: .1rem .4rem; border-radius: 6px; }
.bar--today .bar__label { background: rgba(189, 189, 189, .9); color: #171717; }
.streak-bars.is-locked .bars { filter: blur(3px); opacity: .35; pointer-events: none; }
.streak-bars.is-locked::after { content: attr(data-soon); position: absolute; inset: auto 1rem 1rem; text-align: center; }
.year { display: grid; grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: .9rem .5rem; justify-items: center; }
.year__m { display: flex; flex-direction: column; align-items: center; gap: .3rem; }
.year__m .ring__label { font-size: .8rem; font-weight: 700; text-transform: capitalize; }
.year__pct { font-size: .72rem; color: var(--text-faint); }
.streak-note { font-size: .82rem; margin-top: 1rem; }

/* Barra inferior con 5 pestañas en pantallas estrechas */
@media (max-width: 1023px) { .app-nav .tab { min-width: 0; padding-inline: .1rem; } .app-nav .tab span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } }
@media (max-width: 420px) { .app-nav .tab { font-size: .62rem; } .app-nav .tab svg { width: 20px; height: 20px; } }
@media (min-width: 1024px) and (max-width: 1180px) { .app-nav .tab { padding: .5rem .7rem; font-size: .84rem; } }
/* Semana y calendario: los círculos se encogen en pantallas estrechas */
.week .ring { --size: min(46px, 10.5vw) !important; }
.week .ring__label { font-size: min(13px, 3vw); }
.cal .ring { --size: min(36px, 10vw) !important; }
.cal .ring__label { font-size: min(11px, 2.9vw); }
.cal-head h2 { text-transform: none; }
.streak-bars.is-locked::after { content: attr(data-soon); top: 50%; bottom: auto; transform: translateY(-50%); font-weight: 700; color: var(--lavender); }

/* ===================== Ficha de skin ===================== */
.skin--clickable { cursor: pointer; }
.skin--clickable:focus-visible { outline: 2px solid var(--lavender); outline-offset: 2px; }
button.weapon { font: inherit; color: var(--text); text-align: left; padding: 0; cursor: pointer; transition: border-color .2s, transform .2s var(--ease), box-shadow .2s; }
button.weapon:hover { border-color: var(--purple-hover); transform: translateY(-2px); box-shadow: 0 10px 30px var(--glow-soft); }
.skin-detail { gap: 1rem; }
.skin-detail__stage { position: relative; display: grid; place-items: center; width: 100%; height: clamp(170px, 34vw, 360px); border-radius: 14px; overflow: hidden; border: 1px solid var(--border); background: radial-gradient(ellipse at center, color-mix(in srgb, var(--tier, var(--purple)) 28%, transparent), transparent 70%), var(--bg); }
/* Posición absoluta: con max-height en % dentro de la rejilla, las imágenes altas (cuchillos) se salían por abajo. */
.skin-detail__img { position: absolute; inset: 9% 7%; width: 86%; height: 82%; object-fit: contain; filter: drop-shadow(0 14px 26px rgba(0, 0, 0, .7)); }
.skin-detail__video { width: 100%; height: 100%; object-fit: contain; background: #000000; }
.skin-detail__head { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: .75rem; }
.skin-detail__name { margin: 0; font-size: 1.35rem; }
.skin-detail__sub { margin: .2rem 0 0; font-size: .88rem; }
.skin-detail__badges { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.skin-detail__cols { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 760px) { .skin-detail__cols { grid-template-columns: 1fr 1fr; } }
.skin-detail__section { display: grid; gap: .6rem; align-content: start; background: rgba(7, 7, 7, .5); border: 1px solid var(--border); border-radius: 14px; padding: .9rem 1rem; }
.skin-detail__section h4 { margin: 0; font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--text-faint); }
.skin-detail__section .btn--ghost { justify-self: start; display: inline-flex; gap: .4rem; }
.skin-detail__section .btn--ghost .ico { fill: currentColor; stroke: none; width: 14px; height: 14px; }
.swatches { display: flex; flex-wrap: wrap; gap: .5rem; }
.swatch { position: relative; width: 48px; height: 48px; padding: 3px; border-radius: 12px; border: 2px solid var(--border-strong); background: var(--surface); cursor: pointer; color: var(--text); }
.swatch img { width: 100%; height: 100%; border-radius: 8px; object-fit: cover; }
.swatch[aria-pressed="true"] { border-color: var(--lavender); box-shadow: 0 0 0 3px var(--glow-soft); }
.swatch--locked img { filter: grayscale(.7) brightness(.6); }
.swatch__lock { position: absolute; right: -6px; top: -6px; width: 20px; height: 20px; padding: 3px; border-radius: 50%; background: var(--bg); border: 1px solid var(--border-strong); }
.levels { list-style: none; margin: 0; padding: 0; display: grid; gap: .4rem; }
.level { display: grid; grid-template-columns: 1.6rem 1fr auto auto; align-items: center; gap: .6rem; padding: .45rem .6rem; border-radius: 10px; background: var(--surface); border: 1px solid var(--border); }
.level__n { width: 1.6rem; height: 1.6rem; display: grid; place-items: center; border-radius: 50%; background: var(--grad); color: #ffffff; font-size: .75rem; font-weight: 800; }
.level--locked .level__n { background: var(--surface-2); color: var(--text-faint); }
.level--locked .level__name { color: var(--text-dim); }
.level__name { font-weight: 600; font-size: .9rem; }
.level__state { width: 18px; height: 18px; color: var(--text-faint); }
.level__state--ok { color: var(--win); }
.level__play { padding: .3rem .55rem; }
.skin-pick { display: grid; gap: .5rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 140px), 1fr)); max-height: 260px; overflow-y: auto; }
.pick { position: relative; display: flex; flex-direction: column; gap: .3rem; font: inherit; color: var(--text); text-align: left; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: .5rem .5rem .6rem; cursor: pointer; }
.pick::before { content: ''; position: absolute; inset: 0 8px auto; height: 2px; background: var(--tier, transparent); }
.pick[aria-pressed="true"] { border-color: var(--purple-hover); box-shadow: 0 0 0 1px var(--purple); }
.pick__img { display: grid; place-items: center; height: 52px; }
.pick__img img { max-height: 100%; object-fit: contain; }
.pick__name { font-size: .8rem; line-height: 1.3; overflow-wrap: anywhere; }

/* ===================== Botones: tamaño táctil, iconos y estados ===================== */
.btn { min-height: 44px; line-height: 1.2; border-radius: 12px; font-weight: 700; letter-spacing: -.005em; -webkit-tap-highlight-color: transparent; user-select: none; }
.btn .ico { width: 18px; height: 18px; vertical-align: 0; }
.btn--ghost { min-height: 38px; border-color: var(--border); border-radius: 10px; }
.btn--ghost:hover { background: rgba(189, 189, 189, .08); border-color: var(--border-strong); }
.btn--lg { min-height: 52px; padding: .85rem 1.5rem; font-size: 1rem; border-radius: 14px; }
.btn--lg .ico { width: 20px; height: 20px; }
.btn--block { display: flex; width: 100%; }
.btn:active { transform: translateY(0) scale(.98); }
.btn:focus-visible { outline: 2px solid var(--lavender); outline-offset: 3px; border-radius: 12px; }
.btn[disabled], .btn:disabled { cursor: not-allowed; transform: none; }
.btn[aria-busy="true"] { cursor: progress; }
.icon-btn, .modal__close { cursor: pointer; transition: color .2s, border-color .2s, background .2s; }
.icon-btn:hover, .modal__close:hover { background: var(--surface-2); border-color: var(--border-strong); }
.icon-btn:active, .modal__close:active { transform: scale(.95); }
/* En pantallas táctiles no hay «hover» real: sin saltos al tocar. */
@media (hover: none) { .btn:hover, .feature:hover, button.weapon:hover { transform: none; } }
/* Textos largos en móvil: el botón crece en alto en lugar de salirse de la pantalla. */
@media (max-width: 480px) {
  .btn { white-space: normal; text-align: center; text-wrap: balance; }
  .hero__ctas .btn, .aim-actions > .btn--primary, .login-card .btn--primary { width: 100%; }
}
@media (prefers-reduced-motion: reduce) { .btn, .icon-btn, .modal__close { transition: none; } .btn:hover, .btn:active { transform: none; } }

/* ===================== Login ===================== */
.trust { display: flex; gap: 1rem; align-items: flex-start; margin: 1.5rem 0 0; padding: 1.1rem 1.25rem; border-radius: var(--radius); border: 1px solid rgba(169, 169, 169, .35); background: linear-gradient(180deg, rgba(169, 169, 169, .1), rgba(169, 169, 169, .03)); }
.trust__ico { width: 28px; height: 28px; color: var(--win); flex-shrink: 0; margin-top: .1rem; }
.trust h3 { margin: 0 0 .3rem; font-size: 1rem; }
.trust p { margin: 0; color: var(--text-dim); font-size: .9rem; }
@media (max-width: 480px) { .trust { flex-direction: column; gap: .5rem; } }
.keys { display: flex; flex-wrap: wrap; gap: .5rem .9rem; margin: 0; font-size: .88rem; }
.keys__item { display: inline-flex; flex-wrap: wrap; align-items: center; gap: .3rem; padding: .4rem .7rem; border-radius: 10px; background: rgba(7, 7, 7, .55); border: 1px solid var(--border); color: var(--text); }
.login-form { grid-template-columns: 1fr; margin-top: .25rem; }
.login-form__paste { grid-column: 1 / -1; }
@media (min-width: 640px) { .login-form { grid-template-columns: minmax(0, 1fr) auto auto; } }
.steps > li { transition: border-color .3s, box-shadow .3s; }
.steps > li.is-next { border-color: var(--purple-hover); box-shadow: 0 0 0 3px var(--glow-soft), 0 18px 50px rgba(85, 85, 85, .2); }

/* ===================== Cabecera y barra inferior fijas ===================== */
/* La cabecera va fija arriba (no se mueve al hacer scroll) y la página empieza debajo. */
/* Solo scroll vertical: la página no se mueve de lado a lado (las filas con scroll propio, como
   los mapas de lineups, siguen deslizando en horizontal). */
html { touch-action: pan-y; overscroll-behavior: none; }
.lu-maps { touch-action: pan-x pan-y; }
body { overscroll-behavior: none; padding-top: var(--header-total); }
.topbar { position: fixed; top: 0; left: 0; right: 0; height: var(--header-total); padding-top: env(safe-area-inset-top); }
.topbar__inner { padding-left: max(16px, env(safe-area-inset-left)); padding-right: max(16px, env(safe-area-inset-right)); }
@media (min-width: 768px) { .topbar__inner { padding-left: max(32px, env(safe-area-inset-left)); padding-right: max(32px, env(safe-area-inset-right)); } }
@media (max-width: 1023px) { .app-nav { transform: translateZ(0); } }
/* iOS hace zoom al tocar un campo con letra menor de 16 px: así no se mueve la vista. */
input, select, textarea { font-size: max(16px, 1em); }

/* ===================== Monocromo: blanco, negro y gris ===================== */
/* Figura de fondo (Forma AI, sin el texto): un arco de luz plateada y difusa detrás de todo. */
body { background: #000; }
body::before { content: ''; position: fixed; z-index: -1; pointer-events: none; left: 50%; top: 18vh; width: min(1100px, 170vw); aspect-ratio: 1; transform: translateX(-30%); border-radius: 50%;
  background: radial-gradient(circle at 50% 50%, #000 57%, transparent 58.5%), radial-gradient(circle at 38% 40%, rgba(255, 255, 255, .5), rgba(170, 170, 170, .18) 38%, transparent 62%);
  box-shadow: -2px -2px 0 0 rgba(255, 255, 255, .35), -30px -30px 120px 10px rgba(255, 255, 255, .08); filter: blur(1px); opacity: .9; }
body::after { content: ''; position: fixed; z-index: -1; inset: 0; pointer-events: none; opacity: .07;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .6 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }
@media (max-width: 767px) { body::before { top: 26vh; width: 190vw; transform: translateX(-38%); } }
.hero__web { opacity: .07; }
.hero__arc { background: radial-gradient(circle at 50% 50%, #000 58%, transparent 59.5%); box-shadow: 0 -1px 0 1px rgba(255, 255, 255, .45), 0 -16px 60px 4px rgba(255, 255, 255, .12), 0 -60px 160px 30px rgba(255, 255, 255, .05); }
.hero__arc::after { background: radial-gradient(circle at 50% 0%, rgba(255, 255, 255, .08), transparent 40%); }
.topbar::before { background: rgba(0, 0, 0, .72); }
.app__glow { background: radial-gradient(ellipse 60% 50% at 50% 50%, rgba(255, 255, 255, .06), transparent 100%); }

/* Texto: titulares blancos que se apagan a gris, como en las referencias. */
.grad { background: linear-gradient(180deg, #ffffff 25%, #8f8f8f 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.brand b { color: #9a9a9a; }

/* Botón principal: píldora blanca con texto negro. */
.btn--primary, .btn--primary:hover { background: #ffffff; color: var(--ink); border-color: #ffffff; box-shadow: 0 6px 24px rgba(255, 255, 255, .12); }
.btn--primary:hover { background: #e9e9e9; border-color: #e9e9e9; box-shadow: 0 8px 30px rgba(255, 255, 255, .2); }
.btn--primary:active { background: #cfcfcf; border-color: #cfcfcf; box-shadow: none; }
.btn { border-radius: 999px; }
.btn:not(.btn--primary) { background: var(--glass); border-color: var(--glass-border); }
.btn:not(.btn--primary):hover { background: rgba(255, 255, 255, .09); border-color: rgba(255, 255, 255, .3); }
.btn[disabled], .btn:disabled { background: #1c1c1c; color: var(--text-faint); border-color: #1c1c1c; }
.btn:focus-visible { border-radius: 999px; outline-color: #fff; }
:focus-visible { outline-color: #ffffff; }

/* Activos: blanco sobre negro. */
.tab[aria-selected="true"], .langs a[aria-current="true"], .chip[aria-pressed="true"], .skin__fav[aria-pressed="true"], .lu-mapbtn__n, .pill--night, .level__n { background: #ffffff; color: var(--ink); border-color: #ffffff; box-shadow: none; }
.level--locked .level__n { background: var(--surface-2); color: var(--text-faint); }
.skin__fav[aria-pressed="true"] .ico { fill: var(--ink); stroke: var(--ink); }
@media (max-width: 1023px) { .app-nav .tab[aria-selected="true"] { background: rgba(255, 255, 255, .1); color: #ffffff; } }
.avatar { background: #ffffff; color: var(--ink); }
.soon__lock { background: #ffffff; stroke: var(--ink); }
.skin__discount, .lu-card__ability { background: #ffffff; color: var(--ink); }
.dot { background: #ffffff; box-shadow: 0 0 8px rgba(255, 255, 255, .6); }
.tab--soon::after { background: #ffffff; box-shadow: none; }
.switch--on { background: #ffffff; color: var(--ink); border-color: #ffffff; }
.switch--on::after { background: var(--ink); box-shadow: none; }

/* Tarjetas: negro con borde fino y brillo arriba (cristal oscuro). */
.card, .feature, .skin, .weapon, .row, .match, .lu-card, .steps > li { background: linear-gradient(180deg, rgba(255, 255, 255, .045), rgba(255, 255, 255, .015)); border-color: var(--glass-border); }
.card { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06); }
.feature--hl { background: linear-gradient(160deg, #ffffff, #cfcfcf); color: var(--ink); box-shadow: 0 20px 60px rgba(255, 255, 255, .08); }
.feature--hl h3, .feature--hl p { color: var(--ink); }
.feature--hl .feature__icon { stroke: var(--ink); }
.band { background: linear-gradient(180deg, #0f0f0f, #050505); border-block-color: var(--glass-border); }
.band__steps li { background: var(--glass); border-color: var(--glass-border); }
.pill { color: #e6e6e6; background: var(--glass); border-color: var(--glass-border); }
.streak-card { background: radial-gradient(ellipse 80% 100% at 0% 0%, rgba(255, 255, 255, .08), transparent 70%), linear-gradient(180deg, rgba(255, 255, 255, .05), rgba(255, 255, 255, .015)); border-color: var(--glass-border); }
.skin--wished { border-color: rgba(255, 255, 255, .55); box-shadow: 0 0 0 1px rgba(255, 255, 255, .25), 0 12px 40px rgba(255, 255, 255, .06); }
.bundle__hero { background: linear-gradient(135deg, #161616, #000); }
.edpi-scale__band { background: linear-gradient(90deg, var(--surface-2) 0%, var(--surface-2) 25%, #8a8a8a 25%, #ffffff 50%, #8a8a8a 75%, var(--surface-2) 75%); }

/* Anillos y barras en blanco y gris. */
.ring__track { stroke: rgba(255, 255, 255, .1); }
.ring__bar { filter: drop-shadow(0 0 6px rgba(255, 255, 255, .25)); }
.bar__fill { background: linear-gradient(0deg, #4a4a4a, #bdbdbd 60%, #ffffff); box-shadow: 0 0 12px rgba(255, 255, 255, .15); }
.bar--today .bar__label { background: #ffffff; color: var(--ink); }
.day--today .ring__svg { filter: drop-shadow(0 0 8px rgba(255, 255, 255, .45)); }

/* Burdeos solo para lo importante: errores, derrotas y avisos. */
.form-error, .status--error, .menu__item--danger { color: var(--loss); }
.match--loss .match__bar { background: var(--burgundy); box-shadow: 0 0 12px var(--burgundy-soft); }
.match--win .match__bar { background: #ffffff; box-shadow: 0 0 12px rgba(255, 255, 255, .3); }
.panel-error { border-color: rgba(196, 55, 79, .45); background: linear-gradient(180deg, var(--burgundy-soft), rgba(122, 28, 48, .08)); }
.banner { border-color: rgba(196, 55, 79, .45); background: linear-gradient(180deg, rgba(122, 28, 48, .28), rgba(122, 28, 48, .06)); }
.banner .ico { color: #ffffff; fill: rgba(196, 55, 79, .5); }

/* ===================== Login de cristal ===================== */
.login-card { position: relative; padding: clamp(1.25rem, 4vw, 2.5rem); border-radius: 28px; background: linear-gradient(160deg, rgba(255, 255, 255, .09), rgba(255, 255, 255, .02) 45%, rgba(255, 255, 255, .05)); border: 1px solid rgba(255, 255, 255, .16); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .12), 0 30px 80px rgba(0, 0, 0, .6); backdrop-filter: blur(22px) saturate(120%); -webkit-backdrop-filter: blur(22px) saturate(120%); }
.login-card .section__title { text-align: left; font-size: clamp(2rem, 6vw, 3rem); letter-spacing: -0.04em; }
.login-card .steps > li { background: rgba(255, 255, 255, .03); border-color: rgba(255, 255, 255, .1); }
.login-card .steps > li.is-next { border-color: rgba(255, 255, 255, .6); box-shadow: 0 0 0 3px rgba(255, 255, 255, .08); }
.login-card .steps__n { color: #8a8a8a; }
.login-card input, .login-card select { background: rgba(255, 255, 255, .06); border-color: rgba(255, 255, 255, .22); border-radius: 14px; }
.login-card input::placeholder { color: rgba(255, 255, 255, .45); }
.login-card input:focus, .login-card select:focus { border-color: rgba(255, 255, 255, .7); box-shadow: 0 0 0 3px rgba(255, 255, 255, .08); }
.trust { border-color: rgba(255, 255, 255, .16); background: rgba(255, 255, 255, .04); }
.trust__ico { color: #ffffff; }
.keys__item { background: rgba(255, 255, 255, .04); border-color: rgba(255, 255, 255, .12); }
input, select, textarea { background: rgba(255, 255, 255, .04); border-color: var(--border-strong); }
input:focus, select:focus, textarea:focus { border-color: rgba(255, 255, 255, .7); box-shadow: 0 0 0 3px rgba(255, 255, 255, .07); }
.form-info { color: #d6d6d6; }
.level__state--ok { color: #ffffff; }

/* ===================== Imágenes de skins: siempre dentro de su recuadro ===================== */
/* Con aspect-ratio + max-height en %, una skin alta (cuchillo, pistola) estiraba la tarjeta.
   La imagen va en posición absoluta y se ajusta al recuadro sin deformarse. */
.skin__img, .weapon__img { position: relative; overflow: hidden; }
.skin__img > img, .weapon__img > img { position: absolute; inset: 1.1rem; width: calc(100% - 2.2rem); height: calc(100% - 2.2rem); max-height: none; object-fit: contain; z-index: 0; }
.grid--small .skin__img > img { inset: .8rem; width: calc(100% - 1.6rem); height: calc(100% - 1.6rem); }
.weapon__img > img { inset: .8rem 1rem; width: calc(100% - 2rem); height: calc(100% - 1.6rem); }
.skin__fav, .skin__discount { z-index: 1; }

/* ===================== Fondo: humo blanco sobre negro ===================== */
/* Fondo propio generado con tools/make-bg.py (vertical en el móvil, horizontal en pantallas
   anchas), fijo detrás de todo. Un velo negro lo oscurece; dentro de la app el velo es más fuerte. */
:root {
  --bg-veil: linear-gradient(180deg, rgba(0, 0, 0, .15), rgba(0, 0, 0, .4) 55%, rgba(0, 0, 0, .75));
  --bg-img: url('/assets/img/bg-portrait.webp');
}
@media (min-aspect-ratio: 1/1) {
  :root {
    --bg-img: url('/assets/img/bg-landscape.webp');
  }
}
body[data-view="app"] { --bg-veil: linear-gradient(180deg, rgba(0, 0, 0, .55), rgba(0, 0, 0, .75)); }
body::before { inset: 0; left: 0; top: 0; width: 100%; height: 100vh; height: 100lvh; aspect-ratio: auto; transform: none; border-radius: 0; box-shadow: none; filter: none; opacity: 1;
  background: var(--bg-veil), var(--bg-img) center / cover no-repeat; }
@media (max-width: 767px) { body::before { top: 0; width: 100%; transform: none; } }
body::after { display: none; }
.hero__arc, .hero__web { display: none; }
.app__glow { display: none; }
/* Secciones con fondo propio: se dejan ver el humo de detrás. */
.band { background: linear-gradient(180deg, rgba(10, 10, 10, .75), rgba(5, 5, 5, .85)); }
.footer { background: rgba(0, 0, 0, .82); }
/* Tarjetas de cristal oscuro sobre el humo: opacas lo justo para leer bien el texto. */
.card, .feature, .skin, .weapon, .row, .match, .lu-card, .steps > li, .band__steps li { background: linear-gradient(180deg, rgba(22, 22, 22, .82), rgba(8, 8, 8, .86)); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.feature--hl { background: linear-gradient(160deg, #ffffff, #cfcfcf); }
.pill, .kpi, .wallet dd { -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.hero__lead, .section__lead { text-shadow: 0 1px 12px rgba(0, 0, 0, .8); }
.hero__lead { color: #dadada; text-shadow: 0 1px 14px rgba(0, 0, 0, .95), 0 0 30px rgba(0, 0, 0, .7); }

/* ===================== Wishlist: precios ===================== */
.price--est { color: var(--text-dim); border-style: dashed; }
.wl-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: .5rem 1rem; margin: 2.25rem 0 .9rem; }
.wl-head h2 { margin: 0; }
.wl-total { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem .7rem; margin: 0; padding: .45rem .9rem; border-radius: 999px; background: rgba(12, 12, 12, .8); border: 1px solid var(--glass-border); }
.wl-total .kpi__label { margin: 0; }
.wl-total small { flex-basis: 100%; font-size: .72rem; }
.search::-webkit-search-cancel-button { filter: grayscale(1) brightness(1.8); cursor: pointer; }

/* ===================== Estadísticas ampliadas ===================== */
.stats-ext { grid-column: 1 / -1; display: grid; gap: 1.1rem; }
.stats-ext__title { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: .3rem 1rem; margin: 0; font-size: 1.05rem; }
.stats-ext__title .dim { font-size: .8rem; font-weight: 600; }
.stats-ext__shots { display: grid; gap: .45rem; }
.kpis--ext { grid-template-columns: repeat(auto-fit, minmax(96px, 1fr)); }
@media (max-width: 480px) { .kpis--ext { grid-template-columns: repeat(3, 1fr); } }
.stats-ext__legend { margin: 0; font-size: .75rem; }
.kpi__sub { font-size: .72rem; margin-top: .1rem; }
/* Reparto de disparos: blanco (cabeza), gris (cuerpo), gris oscuro (piernas), con huecos de 2 px. */
.shots { display: grid; gap: .5rem; }
.shots__bar { display: flex; gap: 2px; height: 14px; border-radius: 999px; overflow: hidden; background: rgba(255, 255, 255, .06); }
.shots__seg { min-width: 4px; }
.shots__seg--head, .shots__dot--head { background: #ffffff; }
.shots__seg--body, .shots__dot--body { background: #9a9a9a; }
.shots__seg--leg, .shots__dot--leg { background: #4d4d4d; }
.shots__legend { display: flex; flex-wrap: wrap; gap: .3rem 1.1rem; font-size: .82rem; color: var(--text-dim); }
.shots__item { display: inline-flex; align-items: center; gap: .4rem; }
.shots__item b { color: var(--text); }
.shots__dot { width: 10px; height: 10px; border-radius: 3px; display: inline-block; border: 1px solid rgba(255, 255, 255, .25); }
.shots__note { margin: .4rem 0 0; font-size: .8rem; }
/* HS % por partida: barras finas con la media como línea de referencia. */
.hs-chart { display: grid; gap: .5rem; }
.hs-chart__head { display: flex; justify-content: space-between; gap: 1rem; font-size: .8rem; }
.hs-chart__plot { position: relative; display: flex; align-items: flex-end; gap: 4px; height: 96px; padding-top: 4px; border-bottom: 1px solid var(--border-strong); }
.hs-chart__bar { flex: 1; max-width: 44px; border-radius: 4px 4px 0 0; background: linear-gradient(180deg, #ffffff, #8a8a8a); opacity: .9; outline-offset: 2px; }
.hs-chart__bar--loss { background: linear-gradient(180deg, #8a8a8a, #3a3a3a); }
.hs-chart__bar:hover, .hs-chart__bar:focus-visible { opacity: 1; box-shadow: 0 0 0 2px rgba(255, 255, 255, .35); }
.hs-chart__avg { position: absolute; left: 0; right: 0; bottom: var(--avg); border-top: 1px dashed rgba(255, 255, 255, .45); pointer-events: none; }
/* Historial: cada partida es un botón que abre su ficha. */
button.match { width: 100%; font: inherit; color: var(--text); text-align: left; cursor: pointer; transition: border-color .2s, transform .2s var(--ease); }
button.match:hover { border-color: rgba(255, 255, 255, .35); transform: translateY(-1px); }
button.match:disabled { cursor: default; transform: none; }

/* ===================== Ficha de partida ===================== */
.match-detail { gap: 1rem; }
.match-detail__sub { margin: -.25rem 0 0; font-size: .85rem; }
.match-detail__section { display: grid; gap: .6rem; background: rgba(6, 6, 6, .6); border: 1px solid var(--border); border-radius: 14px; padding: .9rem 1rem; }
.match-detail__section h4, .scoreboard h4 { margin: 0; font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--text-faint); }
.insights { list-style: none; margin: 0; padding: 0; display: grid; gap: .45rem; }
.insight { position: relative; padding: .55rem .8rem .55rem 2rem; border-radius: 10px; background: var(--surface); border: 1px solid var(--border); font-size: .9rem; line-height: 1.45; }
.insight::before { content: ''; position: absolute; left: .8rem; top: .95rem; width: 8px; height: 8px; border-radius: 50%; background: var(--text-faint); }
.insight--good::before { background: #ffffff; box-shadow: 0 0 8px rgba(255, 255, 255, .6); }
.insight--bad { border-color: rgba(196, 55, 79, .4); }
.insight--bad::before { background: var(--loss); }
.rounds__hint { margin: 0; font-size: .78rem; }
.rounds { display: flex; flex-wrap: wrap; gap: .35rem; }
.rounds__half { width: 2px; align-self: stretch; margin: 0 .2rem; background: var(--border-strong); border-radius: 2px; }
.rchip { display: grid; justify-items: center; gap: 1px; width: 40px; padding: .3rem 0 .25rem; border-radius: 10px; font: inherit; cursor: pointer; border: 1px solid var(--border-strong); background: var(--surface); color: var(--text); }
.rchip--won { background: #ffffff; color: var(--ink); border-color: #ffffff; }
.rchip--lost { border-color: rgba(196, 55, 79, .55); color: var(--text-dim); }
.rchip[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px rgba(255, 255, 255, .7); }
.rchip__n { font-size: .72rem; font-weight: 800; line-height: 1; }
.rchip__ico { width: 14px; height: 14px; }
.rchip__k { font-size: .6rem; line-height: .7; letter-spacing: -1px; }
.round-detail { display: grid; gap: .6rem; padding: .8rem; border-radius: 12px; background: var(--surface); border: 1px solid var(--border); }
.round-detail__head { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .8rem; }
.round-detail__end { display: inline-flex; align-items: center; gap: .3rem; font-size: .85rem; }
.round-detail__notes { margin: 0; font-size: .85rem; }
.kpis--sm { grid-template-columns: repeat(auto-fit, minmax(90px, 1fr)); gap: .6rem; }
.kpis--sm .kpi__value { font-size: 1.05rem; }
.scoreboard { display: grid; gap: .5rem; }
.table-wrap { overflow-x: auto; touch-action: pan-x pan-y; border: 1px solid var(--border); border-radius: 12px; }
.sb { width: 100%; border-collapse: collapse; font-size: .85rem; white-space: nowrap; }
.sb th { text-align: left; font-size: .7rem; font-weight: 700; color: var(--text-faint); text-transform: uppercase; letter-spacing: .06em; padding: .5rem .6rem; background: rgba(255, 255, 255, .03); }
.sb td { padding: .4rem .6rem; border-top: 1px solid var(--border); }
.sb td img { width: 28px; height: 28px; border-radius: 6px; object-fit: cover; display: block; }
.sb__name { display: inline-flex; align-items: center; gap: .4rem; }
.sb .sb__rank { width: 20px; height: 20px; border-radius: 0; object-fit: contain; }
.sb__me td { background: rgba(255, 255, 255, .07); font-weight: 700; }
.sb td.sb__player { padding-right: 1.1rem; }
.sb td img { max-width: none; flex-shrink: 0; }
.sb td:first-child, .sb th:first-child { width: 44px; padding-right: 0; }
