/* Hallmark · v2.0.0 · theme: custom · idea: "a tournament night in Seville: a camera flies through a dark room of real cards, and each section stops at its own scene" · vibe: "tournament night, gold on wine, cards in flight" · paper: dark, a wine-tinted night · accent: gold for the one action and key figures · faces: Barlow Condensed (the app's own face, found in the project) over Figtree · axes: dark/grotesk-condensed/chromatic-gold · posture: committed dark, declared for 23 · hero: the 3D card wheel to the right, the title on the left · nav: logo and links over the night · footer: the card credit strip · redesign: full (Impeccable brand register, Taste skill dials 8/8/4, Emil Kowalski motion rules) · job: browse the cards, then sign in · signature: the camera flight between eight card scenes · deal: none (custom, chosen by the owner) */
/* Hallmark · pre-emit critique: P4 H5 E4 S5 R4 V5 · weakest: E, a full-screen WebGL scene under long content; kept cheap with half-rate rendering on phones and a cap on pixel ratio */
/* Hallmark · waive 39b · each Besti and each card is a button the size of the printed card it opens · the card itself is the control */
/* Hallmark · waive 37 · two families in running use, Barlow Condensed and Figtree · the condensed display is the face the Bestiberia app already prints its card names in, found in the project */
/* Hallmark · waive 83 · the bands show the 95 Bestis, the cards and the community's own event photos · the page exists to show this body of the user's own work */
/* Hallmark · waive 72 · closed details.regla accordions report negative bottoms from their hidden body · open, each rule body keeps var(--space-5) at the sides and var(--space-6) below the reglamento text */

@font-face { font-family: "Barlow Condensed"; src: url(../fonts/barlow-condensed-bold.ttf) format("truetype"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Figtree"; src: url(../fonts/figtree-latin.woff2) format("woff2"); font-weight: 300 900; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Figtree"; src: url(../fonts/figtree-latin-ext.woff2) format("woff2"); font-weight: 300 900; font-display: swap; unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

:root {
  --color-night: oklch(15% 0.03 330);
  --color-night-2: oklch(20% 0.045 340);
  --color-night-3: oklch(25% 0.06 345);
  --color-wine: oklch(36% 0.13 15);
  --color-line: oklch(34% 0.04 340);
  --color-field: oklch(62% 0.04 340);
  --color-text: oklch(95% 0.015 85);
  --color-text-soft: oklch(78% 0.025 60);
  --color-gold: oklch(84% 0.15 85);
  --color-gold-2: oklch(72% 0.14 70);
  --color-on-gold: oklch(18% 0.03 330);
  --color-focus: oklch(86% 0.14 200);
  --color-shadow: oklch(8% 0.02 330 / 0.6);
  --color-veil: oklch(15% 0.03 330 / 0.9);
  --color-veil-soft: oklch(15% 0.03 330 / 0.45);
  --color-clear: oklch(15% 0.03 330 / 0);
  --color-backdrop: oklch(10% 0.02 330 / 0.85);
  --color-glow: oklch(84% 0.15 85 / 0.3);
  --color-alert: oklch(66% 0.19 27);

  --font-display: "Barlow Condensed", "Arial Narrow", sans-serif;
  --font-body: "Figtree", ui-sans-serif, sans-serif;

  --text-hero: clamp(3.25rem, 7vw, 6.5rem);
  --text-section: clamp(2.75rem, 6vw, 5.5rem);
  --text-statement: clamp(1.4rem, 2.6vw, 2.2rem);
  --text-title: clamp(1.5rem, 2.2vw, 1.875rem);
  --text-figure: clamp(2.5rem, 4vw, 3.5rem);
  --text-lead: 1.2rem;
  --text-body: 1.0625rem;
  --text-small: 0.9375rem;

  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 3rem;
  --space-8: 4rem;
  --space-9: 6rem;
  --gutter: clamp(var(--space-4), 5vw, var(--space-9));

  --radius-card: 10px;
  --radius-box: 14px;
  --radius-pill: 999px;
  --control-height: 3.25rem;
  --bar-height: 4.5rem;
  --container: 88rem;
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
  --shadow-card: 0 14px 30px var(--color-shadow);
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { overflow-x: clip; scroll-behavior: smooth; scroll-padding-top: var(--bar-height); scrollbar-color: var(--color-gold-2) var(--color-night); }
body { overflow-x: clip; margin: 0; color: var(--color-text); background: var(--color-night); font: 400 var(--text-body)/1.65 var(--font-body); font-synthesis: none; caret-color: var(--color-gold); -webkit-font-smoothing: antialiased; }
::selection { background: var(--color-gold); color: var(--color-on-gold); }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
p { margin: 0; text-wrap: pretty; }
:focus-visible { outline: 3px solid var(--color-focus); outline-offset: 3px; }
h1, h2, h3, h4 { margin: 0; font-family: var(--font-display); font-weight: 700; text-transform: uppercase; line-height: 1; overflow-wrap: break-word; min-width: 0; text-wrap: balance; }
h2 { font-size: var(--text-section); }
h3 { font-size: var(--text-title); line-height: 1.05; }
.caja { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }

/* La escena 3D, fija detrás de todo. */
#mundo { position: fixed; inset: 0; z-index: 0; display: block; width: 100%; height: 100%; }
main, .pie { position: relative; z-index: 1; }

/* Barra */
.barra { position: fixed; z-index: 10; inset: 0 0 auto 0; height: var(--bar-height); display: flex; align-items: center; justify-content: space-between; gap: var(--space-5); padding-inline: var(--gutter); background: linear-gradient(var(--color-veil), var(--color-clear)); }
.barra__marca img { width: 6.5rem; }
.barra__nav { display: flex; align-items: center; gap: var(--space-6); }
.barra__nav a { display: inline-flex; align-items: center; min-height: var(--control-height); font: 700 1.2rem/1 var(--font-display); text-transform: uppercase; letter-spacing: 0.02em; text-decoration: none; white-space: nowrap; text-underline-offset: 0.35em; text-decoration-thickness: 3px; transition: color 200ms var(--ease-out); }
.barra__nav a.es-actual { color: var(--color-gold); text-decoration-line: underline; }
.barra__nav a:active { color: var(--color-gold-2); }
.barra__menu { display: none; }

/* Portada: titular a la izquierda, la rueda 3D a la derecha. */
.portada { position: relative; display: grid; align-items: center; min-height: 100svh; padding-top: var(--bar-height); }
.portada::before { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(90deg, var(--color-veil) 0%, var(--color-veil-soft) 38%, var(--color-clear) 62%), linear-gradient(0deg, var(--color-night), var(--color-clear) 22%); }
.portada__texto { position: relative; display: grid; justify-items: start; gap: var(--space-5); width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.portada__texto > * { max-width: 40rem; }
.portada__logo { width: min(78vw, 28rem); filter: drop-shadow(0 0 40px var(--color-glow)); animation: entrar 900ms var(--ease-out) both; }
.portada h1 { font-size: var(--text-hero); line-height: 0.95; color: var(--color-gold); animation: entrar 900ms var(--ease-out) 80ms both; }
.portada p { max-width: 30ch; font-size: var(--text-lead); color: var(--color-text-soft); animation: entrar 900ms var(--ease-out) 160ms both; }
.portada .acciones { animation: entrar 900ms var(--ease-out) 240ms both; }
@keyframes entrar { from { opacity: 0; transform: translateY(1.25rem); } }

/* Controles */
.acciones { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-6); }
.boton { display: inline-flex; align-items: center; justify-content: center; min-height: var(--control-height); padding: 0 var(--space-6); border: 0; border-radius: var(--radius-pill); background: linear-gradient(var(--color-gold), var(--color-gold-2)); color: var(--color-on-gold); box-shadow: 0 10px 28px var(--color-glow); font: 700 1.4rem/1 var(--font-display); text-transform: uppercase; letter-spacing: 0.02em; text-decoration: none; white-space: nowrap; cursor: pointer; transition: transform 160ms var(--ease-out), box-shadow 200ms var(--ease-out); }
.boton:active { transform: scale(0.97); }
.boton:disabled { opacity: 0.55; cursor: not-allowed; transform: none; }
.boton--claro { background: none; color: var(--color-text); box-shadow: inset 0 0 0 2px var(--color-gold-2); }
.enlace { display: inline-flex; align-items: center; min-height: var(--control-height); padding: 0; border: 0; background: none; color: var(--color-text); font: 700 var(--text-body)/1 var(--font-body); text-decoration: underline; text-decoration-thickness: 2px; text-decoration-color: var(--color-gold); text-underline-offset: 0.35em; white-space: nowrap; cursor: pointer; transition: color 200ms var(--ease-out), transform 160ms var(--ease-out); }
.enlace:active { color: var(--color-gold-2); transform: scale(0.97); }
.enlace:disabled { opacity: 0.55; cursor: not-allowed; }

/* Secciones: un escenario abierto donde se detiene la cámara y, debajo, el contenido sobre la noche. */
.seccion { position: relative; }
.escenario { height: clamp(18rem, 62svh, 40rem); }
.escenario--bajo { height: clamp(14rem, 40svh, 26rem); }
.contenido { position: relative; padding-block: var(--space-6) var(--space-9); background: linear-gradient(var(--color-clear), var(--color-veil) var(--space-9), var(--color-night) calc(var(--space-9) * 2)); }
.contenido h2 { margin-bottom: var(--space-4); }
.entrada { max-width: 52ch; margin-bottom: var(--space-7); font-size: var(--text-lead); color: var(--color-text-soft); }
.declaracion { max-width: 28ch; margin-bottom: var(--space-8); font: 600 var(--text-statement)/1.25 var(--font-body); }

/* Hispalis: tres hechos en columna tipográfica y la línea del tiempo. */
.hechos { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-7); margin: 0 0 var(--space-8); }
.hechos dt { margin-bottom: var(--space-2); font: 700 var(--text-title)/1.05 var(--font-display); text-transform: uppercase; color: var(--color-gold); }
.hechos dd { margin: 0; max-width: 34ch; color: var(--color-text-soft); }
.hitos { display: block; width: 100%; }
.hitos caption { display: block; margin-bottom: var(--space-4); color: var(--color-text-soft); font-size: var(--text-small); text-align: left; }
.hitos tbody { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-6); border-top: 1px solid var(--color-line); padding-top: var(--space-5); }
.hitos tr { display: grid; gap: var(--space-2); }
.hitos th { font: 700 var(--text-figure)/1 var(--font-display); font-variant-numeric: tabular-nums; color: var(--color-gold); text-align: left; }
.hitos td { color: var(--color-text-soft); }

/* Bandas horizontales: se deslizan con el dedo o la rueda, sin alargar la página. */
.banda { display: grid; grid-auto-flow: column; gap: var(--space-4); overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scroll-padding-inline: var(--gutter); padding: var(--space-3) var(--gutter) var(--space-5); scrollbar-width: thin; scrollbar-color: var(--color-gold-2) var(--color-clear); }
.banda > * { scroll-snap-align: start; }
.banda--cartas { grid-auto-columns: clamp(8.5rem, 13vw, 11.5rem); }
.banda--pastillas { gap: var(--space-2); margin: 0 calc(-1 * var(--gutter)) var(--space-4); padding-block: var(--space-2); }
.pastilla { min-height: 2.75rem; padding: 0 var(--space-4); border: 1px solid var(--color-line); border-radius: var(--radius-pill); background: var(--color-night-2); color: var(--color-text); font: 600 var(--text-small)/1 var(--font-body); white-space: nowrap; cursor: pointer; transition: background-color 200ms var(--ease-out), border-color 200ms var(--ease-out), transform 160ms var(--ease-out); }
.pastilla:active { transform: scale(0.97); }
.pastilla[aria-pressed="true"] { background: var(--color-gold); border-color: var(--color-gold); color: var(--color-on-gold); }

/* Cartas */
.besti, .carta { position: relative; display: grid; align-content: start; gap: var(--space-2); padding: 0; border: 0; background: none; color: var(--color-text); font: inherit; text-align: left; cursor: pointer; transition: transform 250ms var(--ease-out); }
.besti img, .carta img { width: 100%; aspect-ratio: 1200 / 1676; border-radius: var(--radius-card); background: var(--color-night-2); box-shadow: var(--shadow-card); }
.besti:active, .carta:active { transform: scale(0.97); }
.besti__nombre { font: 700 1.2rem/1.05 var(--font-display); text-transform: uppercase; }
.besti__num { color: var(--color-text-soft); font-size: var(--text-small); font-variant-numeric: tabular-nums; }
.besti__hueco { display: grid; place-items: center; aspect-ratio: 1200 / 1676; border-radius: var(--radius-card); background: var(--color-night-2); font: 700 var(--text-figure)/1 var(--font-display); }
.carta.es-ajena img { filter: grayscale(1) brightness(0.45); box-shadow: none; }
.carta__cantidad { position: absolute; top: var(--space-2); right: var(--space-2); display: grid; place-items: center; min-width: 2.25rem; height: 2.25rem; padding: 0 var(--space-2); border-radius: var(--radius-pill); background: var(--color-gold); color: var(--color-on-gold); font: 700 1.25rem/1 var(--font-display); font-variant-numeric: tabular-nums; }

/* Colecciones: los dos sobres grandes y la galería por tandas. */
.series { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-6); margin-bottom: var(--space-8); }
.serie { position: relative; display: grid; justify-items: center; padding: var(--space-5) 0 var(--space-7); border: 0; border-radius: var(--radius-box); background: radial-gradient(60% 70% at 50% 45%, var(--color-night-3), var(--color-clear)); cursor: pointer; transition: transform 250ms var(--ease-out); }
.serie > img:first-child { width: auto; height: clamp(15rem, 28vw, 24rem); filter: drop-shadow(0 18px 40px var(--color-glow)); transition: transform 400ms var(--ease-out); }
.serie:active { transform: scale(0.98); }
.serie__logo { position: absolute; left: 50%; bottom: var(--space-3); translate: -50% 0; width: min(80%, 18rem); height: auto; filter: drop-shadow(0 6px 10px var(--color-shadow)); }
.herramientas { display: grid; grid-template-columns: minmax(0, 2fr) repeat(3, minmax(0, 1fr)); align-items: end; gap: var(--space-4); margin-bottom: var(--space-3); }
.campo { display: grid; gap: var(--space-1); }
.campo span { font-size: var(--text-small); font-weight: 700; color: var(--color-text-soft); }
.campo input, .campo select { width: 100%; height: var(--control-height); padding: 0 var(--space-4); border: 1px solid var(--color-field); border-radius: var(--radius-box); background: var(--color-night-2); color: var(--color-text); font: 500 var(--text-body)/1.2 var(--font-body); transition: border-color 200ms var(--ease-out); }
.campo input:focus-visible, .campo select:focus-visible { outline: 3px solid var(--color-focus); outline-offset: 2px; }
.campo input:disabled, .campo select:disabled { opacity: 0.55; cursor: not-allowed; }
.campo input::placeholder { color: var(--color-text-soft); }
.campo select option { background: var(--color-night); }
.marca { display: inline-flex; align-items: center; gap: var(--space-2); min-height: var(--control-height); font-weight: 700; cursor: pointer; }
.marca input { width: 1.375rem; height: 1.375rem; accent-color: var(--color-gold); }
.cuenta-cartas { min-height: 1lh; margin-bottom: var(--space-5); color: var(--color-text-soft); font-size: var(--text-small); }
.rejilla { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 9.5rem), 1fr)); gap: var(--space-5) var(--space-4); margin-bottom: var(--space-6); }
#mas-cartas { justify-self: start; }

/* Duelo: la ronda como secuencia, sin cajas. */
.ronda { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-7); margin: 0 0 var(--space-8); padding: var(--space-5) 0 0; border-top: 1px solid var(--color-line); list-style: none; }
.ronda li { display: grid; align-content: start; gap: var(--space-2); }
.ronda b { display: grid; gap: var(--space-2); font: 700 var(--text-title)/1.05 var(--font-display); text-transform: uppercase; }
.ronda__n { font-size: var(--text-figure); line-height: 1; color: var(--color-gold); }
.ronda li > span { color: var(--color-text-soft); }
.juegos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-7); margin-bottom: var(--space-8); }
.juego { display: grid; grid-template-columns: minmax(0, 7rem) minmax(0, 1fr); align-items: center; gap: var(--space-5); }
.juego > img { width: 100%; max-height: 10rem; object-fit: contain; filter: drop-shadow(0 12px 24px var(--color-shadow)); }
.juego > img[src*="lugares"] { aspect-ratio: 3 / 4; object-fit: cover; border-radius: var(--radius-card); }
.juego p { margin-block: var(--space-2); color: var(--color-text-soft); }
.tiendas { display: flex; flex-wrap: wrap; gap: var(--space-3); margin-top: var(--space-3); }
.boton--chico { min-height: 2.75rem; padding: 0 var(--space-5); font-size: 1.15rem; }
.reglas { display: grid; gap: var(--space-3); }
.regla { border-radius: var(--radius-box); background: var(--color-night-2); }
.regla summary { display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); min-height: 3.5rem; padding: var(--space-3) var(--space-5); font: 700 var(--text-title)/1.05 var(--font-display); text-transform: uppercase; cursor: pointer; list-style: none; transition: color 200ms var(--ease-out); }
.regla summary::-webkit-details-marker { display: none; }
.regla summary::after { content: "+"; color: var(--color-gold); font: 700 2rem/1 var(--font-display); transition: transform 250ms var(--ease-out); }
.regla[open] summary::after { transform: rotate(45deg); }
.regla summary:active { color: var(--color-gold-2); }
.regla summary:focus-visible { outline-offset: -4px; }
.regla__texto { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--space-3); max-width: 72ch; padding: 0 var(--space-5) var(--space-6); color: var(--color-text-soft); }
.regla__texto h4 { margin: var(--space-4) 0 0; font-size: 1.375rem; color: var(--color-text); }
.regla__texto b { color: var(--color-text); }
.regla__texto ul { display: grid; gap: var(--space-2); margin: 0; padding-left: var(--space-5); }

/* Comunidad */
.quedadas { margin-bottom: var(--space-8); }
.quedadas h3 { display: none; }
.galeria { grid-auto-columns: clamp(16rem, 30vw, 26rem); }
.galeria figure { display: grid; gap: var(--space-2); margin: 0; }
.galeria a { display: block; border-radius: var(--radius-box); transition: transform 250ms var(--ease-out); }
.galeria a:active { transform: scale(0.98); }
.galeria img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radius-box); box-shadow: var(--shadow-card); }
.galeria figcaption { color: var(--color-text-soft); font-size: var(--text-small); }
.ranking { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--space-4); max-width: 60rem; margin-bottom: var(--space-8); }
.ranking h3, .comunidad h3 { font-size: clamp(2rem, 3.6vw, 3rem); }
.ranking tr.extra { display: none; }
.ranking.es-completo tr.extra { display: table-row; }
.clasificacion { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.clasificacion caption { padding-bottom: var(--space-3); color: var(--color-text-soft); font-size: var(--text-small); text-align: left; }
.clasificacion th, .clasificacion td { padding: var(--space-2) var(--space-3); text-align: left; }
.clasificacion thead th { color: var(--color-text-soft); font-size: var(--text-small); font-weight: 700; }
.clasificacion tbody tr + tr { border-top: 1px solid var(--color-line); }
.clasificacion tbody th { font-weight: 700; }
.clasificacion td:last-child { font: 700 1.375rem/1 var(--font-display); color: var(--color-gold); }
.clasificacion tbody tr:nth-child(-n+3) th { color: var(--color-gold); }
.originales { display: flex; flex-wrap: wrap; gap: 0 var(--space-6); margin: var(--space-2) 0 0; padding: 0; list-style: none; }
.originales__titulo { margin-top: var(--space-4); font-size: var(--text-small); }
.comunidad { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-8); }
.comunidad > div { display: grid; align-content: start; gap: var(--space-3); }
.comunidad p { color: var(--color-text-soft); }
.tienda { width: 100%; margin-top: var(--space-4); border-collapse: collapse; }
.tienda caption { padding-bottom: var(--space-2); color: var(--color-text-soft); font-size: var(--text-small); text-align: left; }
.tienda th, .tienda td { padding-block: var(--space-2); text-align: left; vertical-align: baseline; }
.tienda tr + tr { border-top: 1px solid var(--color-line); }
.tienda th { width: 1%; padding-right: var(--space-5); white-space: nowrap; font: 700 var(--text-body)/1.3 var(--font-body); color: var(--color-gold); }
.tienda a { color: var(--color-gold); }

/* Diario */
.diario { display: grid; }
.noticia { display: grid; grid-template-columns: minmax(0, 12rem) minmax(0, 1fr) minmax(0, 1.4fr); align-items: baseline; gap: var(--space-6); padding-block: var(--space-5); }
.noticia + .noticia { border-top: 1px solid var(--color-line); }
.noticia time { color: var(--color-gold); font: 700 1.125rem/1.3 var(--font-display); text-transform: uppercase; font-variant-numeric: tabular-nums; white-space: nowrap; }
.noticia p { color: var(--color-text-soft); max-width: 60ch; }
.archivo { margin-top: var(--space-6); }
.archivo .diario { padding: 0 var(--space-5) var(--space-4); }

/* Cuenta */
.cuenta { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: start; gap: var(--space-7); }
.acceso { display: grid; gap: var(--space-4); max-width: 28rem; }
.aviso { padding: var(--space-3) var(--space-4); border: 1px solid var(--color-alert); border-radius: var(--radius-box); background: var(--color-night-3); color: var(--color-text); font-weight: 700; }
.saludo { margin-bottom: var(--space-3); font: 700 var(--text-section)/1 var(--font-display); text-transform: uppercase; color: var(--color-gold); }
.marcadores { margin-bottom: var(--space-6); font-size: var(--text-lead); color: var(--color-text-soft); }
.progresos { display: grid; gap: var(--space-4); margin-bottom: var(--space-6); }
.progreso__cabecera { display: flex; justify-content: space-between; gap: var(--space-4); margin-bottom: var(--space-1); font-weight: 700; font-variant-numeric: tabular-nums; }
.progreso__barra { height: 0.5rem; border-radius: var(--radius-pill); overflow: hidden; background: var(--color-night-3); }
.progreso__barra i { display: block; height: 100%; background: var(--color-gold); transform: scaleX(var(--tengo, 0)); transform-origin: left; transition: transform 900ms var(--ease-out); }
.proximamente { margin-top: var(--space-6); color: var(--color-text-soft); }

.google { display: grid; gap: var(--space-3); max-width: 28rem; margin-top: var(--space-4); }
.google__o { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: var(--space-3); color: var(--color-text-soft); font-size: var(--text-small); }
.google__o::before, .google__o::after { content: ""; height: 1px; background: var(--color-line); }
#google-boton { min-height: 44px; }

/* Pie */
.pie { padding-block: var(--space-8) var(--space-6); background: var(--color-night); }
.pie .caja { display: grid; justify-items: center; gap: var(--space-5); text-align: center; }
.pie img { width: min(100%, 18rem); filter: drop-shadow(0 0 30px var(--color-glow)); }
.apoyos { display: grid; justify-items: center; gap: var(--space-2); color: var(--color-text-soft); }
.apoyos ul { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-2) var(--space-6); margin: 0; padding: 0; list-style: none; }
.apoyos a, .pie nav a { display: inline-flex; align-items: center; min-height: var(--control-height); color: var(--color-text); font-weight: 700; text-underline-offset: 0.3em; transition: color 200ms var(--ease-out); }
.pie nav { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-2) var(--space-6); }
.apoyos a:active, .pie nav a:active { color: var(--color-gold-2); }
.pie__cinta { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-2) var(--space-7); color: var(--color-text-soft); font-size: var(--text-small); }

/* Ficha de carta */
.ficha { width: min(94%, 56rem); max-height: 92svh; padding: var(--space-6); border: 1px solid var(--color-line); border-radius: var(--radius-box); background: var(--color-night-2); color: var(--color-text); box-shadow: 0 30px 80px var(--color-shadow); }
.ficha[open] { display: grid; grid-template-columns: minmax(0, 20rem) minmax(0, 1fr); align-items: center; gap: var(--space-7); animation: abrir 250ms var(--ease-out); }
.ficha::backdrop { background: var(--color-backdrop); animation: velo 250ms var(--ease-out); }
@keyframes abrir { from { opacity: 0; transform: scale(0.96); } }
@keyframes velo { from { opacity: 0; } }
.ficha__cerrar { position: absolute; top: var(--space-2); right: var(--space-2); width: var(--control-height); height: var(--control-height); border: 0; border-radius: var(--radius-pill); background: none; color: var(--color-text); font: 400 2rem/1 var(--font-body); cursor: pointer; transition: background-color 200ms var(--ease-out), transform 160ms var(--ease-out); }
.ficha__cerrar:active { transform: scale(0.94); }
.ficha__imagen img { width: 100%; border-radius: var(--radius-card); box-shadow: var(--shadow-card); }
.ficha__imagen:empty { display: none; }
.ficha h3 { font-size: var(--text-section); color: var(--color-gold); }
.ficha__origen { margin-bottom: var(--space-4); color: var(--color-text-soft); font-size: var(--text-small); }
.ficha dl { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: var(--space-2) var(--space-5); margin: var(--space-5) 0 0; }
.ficha dt { color: var(--color-text-soft); font-size: var(--text-small); }
.ficha dd { margin: 0; font-weight: 700; }

/* Efectos de pasar el ratón, solo donde hay ratón. */
@media (hover: hover) and (pointer: fine) {
  .barra__nav a:hover, .enlace:hover, .apoyos a:hover, .pie nav a:hover, .regla summary:hover { color: var(--color-gold); }
  .boton:hover { box-shadow: 0 14px 34px var(--color-glow); }
  .pastilla:hover { border-color: var(--color-gold); }
  .besti:hover, .carta:hover { transform: translateY(-6px) rotate(-1deg); }
  .serie:hover > img:first-child { transform: translateY(-8px) rotate(-2deg) scale(1.03); }
  .galeria a:hover { transform: translateY(-4px); }
  .campo input:hover, .campo select:hover { border-color: var(--color-gold-2); }
  .ficha__cerrar:hover { background: var(--color-night-3); }
}

/* Entrada en 3D de los bloques de texto al llegar a la pantalla (CSS puro, corre en el compositor). */
@supports (animation-timeline: view()) {
  .hechos > div, .hitos tr, .ronda li, .juego, .noticia, .serie {
    animation: aparecer linear both;
    animation-timeline: view();
    animation-range: entry 0% entry 60%;
  }
  @keyframes aparecer { from { opacity: 0; transform: perspective(900px) rotateX(24deg) translateY(2rem); } }
}

@media (max-width: 60rem) {
  .barra__menu { display: inline-flex; align-items: center; min-height: var(--control-height); padding: 0 var(--space-5); border: 1px solid var(--color-text); border-radius: var(--radius-pill); background: none; color: var(--color-text); font: 700 var(--text-body)/1 var(--font-body); cursor: pointer; transition: transform 160ms var(--ease-out); }
  .barra__menu:active { transform: scale(0.97); }
  .barra__nav { display: none; position: fixed; inset: var(--bar-height) 0 0 0; flex-direction: column; align-items: flex-start; gap: var(--space-2); padding: var(--space-6) var(--gutter); background: var(--color-night); }
  .barra__nav.es-abierto { display: flex; }
  .barra__nav a { font-size: var(--text-section); }
  .portada { align-items: end; padding-bottom: var(--space-7); }
  .portada::before { background: linear-gradient(0deg, var(--color-night) 18%, var(--color-veil) 42%, var(--color-clear) 70%); }
  .escenario { height: clamp(14rem, 44svh, 22rem); }
  .escenario--bajo { height: clamp(10rem, 26svh, 14rem); }
  .hechos, .ronda, .juegos, .comunidad, .cuenta { grid-template-columns: minmax(0, 1fr); gap: var(--space-6); }
  .hitos tbody { grid-template-columns: minmax(0, 1fr); gap: var(--space-4); }
  .series { gap: var(--space-3); }
  .serie > img:first-child { height: clamp(11rem, 44vw, 15rem); }
  .herramientas { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .campo--ancho { grid-column: 1 / -1; }
  .rejilla { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-4) var(--space-3); }
  .besti__nombre { font-size: 1.0625rem; }
  .banda--cartas { grid-auto-columns: 42vw; }
  .galeria { grid-auto-columns: 78vw; }
  .juego { grid-template-columns: minmax(0, 5rem) minmax(0, 1fr); }
  .noticia { grid-template-columns: minmax(0, 1fr); gap: var(--space-1); }
  .ficha { padding: var(--space-5); }
  .ficha[open] { grid-template-columns: minmax(0, 1fr); gap: var(--space-5); overflow-y: auto; }
  .ficha__imagen { max-width: 13rem; margin-inline: auto; }
}

@media (max-width: 40rem) {
  .clasificacion th, .clasificacion td { padding-inline: var(--space-2); }
  .clasificacion td:nth-child(3), .clasificacion th:nth-child(3), .clasificacion td:nth-child(4), .clasificacion th:nth-child(4) { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition-duration: 1ms !important; }
}
