/* Programas 29N
   Sans (Schibsted Grotesk) = lo nuestro: interfaz, titulares, cifras.
   Serif (Newsreader) = lo que dicen los partidos, literal.
   La web no tiene color propio: el color es de los partidos. El amarillo solo marca lo que se busca. */

/* Fuentes servidas desde la propia web (SIL Open Font License, en fonts/) */
@font-face { font-family: "Schibsted Grotesk"; font-style: normal; font-weight: 400 800; font-display: swap; src: url("fonts/schibsted-grotesk-latin-ext.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Schibsted Grotesk"; font-style: normal; font-weight: 400 800; font-display: swap; src: url("fonts/schibsted-grotesk-latin.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Newsreader"; font-style: normal; font-weight: 400 600; font-display: swap; src: url("fonts/newsreader-latin-ext.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Newsreader"; font-style: normal; font-weight: 400 600; font-display: swap; src: url("fonts/newsreader-latin.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Newsreader"; font-style: italic; font-weight: 400; font-display: swap; src: url("fonts/newsreader-italic-latin-ext.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Newsreader"; font-style: italic; font-weight: 400; font-display: swap; src: url("fonts/newsreader-italic-latin.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
  --bg: #f4f5f7;
  --surface: #ffffff;
  --surface-2: #f3f4f6;
  --surface-3: #e8eaee;
  --line: #e3e5e9;
  --line-2: #c9ced6;
  --ink: #15181d;
  --ink-2: #454d59;
  --ink-3: #5c6573;
  --mark: #ffe066;
  --mark-ink: #15181d;
  --sans: "Schibsted Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
  --serif: "Newsreader", "Source Serif 4", Georgia, serif;
  --r-s: 8px;
  --r-m: 12px;
  --r-l: 16px;
  --w: 1320px;
  --gut: clamp(16px, 3vw, 32px);
  --top: 64px;
  --abajo: 0px;
  --c-fa: #c2d935;
  --c-pp: #21599e;
  --c-psoe: #de0612;
  --c-vox: #5ac035;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--top) + 12px); scrollbar-color: var(--line-2) transparent; }
body {
  margin: 0; padding-bottom: var(--abajo); background: var(--bg); color: var(--ink);
  font: 400 1rem/1.55 var(--sans); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
::selection { background: var(--mark); color: var(--mark-ink); }
a { color: var(--ink); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .18em; text-decoration-color: color-mix(in srgb, currentColor 35%, transparent); }
a:hover { text-decoration-color: currentColor; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; border-radius: 4px; }
h1, h2, h3, h4 { margin: 0; text-wrap: balance; }
p { margin: 0; }
button, input { font: inherit; color: inherit; }
a[href], button, summary, label[for], [role="tab"] { cursor: pointer; }
:disabled, [aria-disabled="true"] { cursor: not-allowed; }
mark { background: var(--mark); color: var(--mark-ink); padding: 0 .1em; border-radius: 2px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 8px; top: -60px; background: var(--ink); color: var(--surface); padding: 8px 12px; z-index: 40; border-radius: var(--r-s); }
.skip:focus { top: 8px; }
.i { width: 16px; height: 16px; flex: none; vertical-align: -3px; }
.nota { font-size: .875rem; color: var(--ink-3); }
.vacio { font-size: .875rem; color: var(--ink-3); padding: 10px 0; }
.cargando, .fallo { padding: 64px 0; max-width: 60ch; color: var(--ink-2); }
.fallo h1 { font-size: 1.5rem; margin-bottom: 8px; color: var(--ink); }

/* ---- Cabecera ---- */
.top { position: sticky; top: 0; z-index: 20; background: var(--surface); border-bottom: 1px solid var(--line); }
.top-in { max-width: var(--w); margin: 0 auto; padding: 0 var(--gut); height: var(--top); display: flex; align-items: center; gap: 32px; }
.marca { display: flex; flex-direction: column; line-height: 1.15; color: var(--ink); text-decoration: none; flex: none; }
.marca-n { font-weight: 800; font-size: 1.125rem; letter-spacing: -.02em; }
.marca-s { font-size: .75rem; font-weight: 500; color: var(--ink-3); }
.nav { display: flex; align-self: stretch; gap: 4px; }
.nav a { position: relative; display: flex; align-items: center; padding: 0 12px; color: var(--ink-2); font-weight: 500; text-decoration: none; white-space: nowrap; }
.nav a::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: -1px; height: 3px; border-radius: 3px 3px 0 0; background: transparent; }
.nav a:hover { color: var(--ink); }
.nav a:hover::after { background: var(--line-2); }
.nav a[aria-current="page"] { color: var(--ink); font-weight: 700; }
.nav a[aria-current="page"]::after { background: var(--ink); }
.nav-i { display: none; width: 22px; height: 22px; }
.nav-buscar { display: none !important; }
.busca { position: relative; margin-left: auto; flex: 0 1 360px; min-width: 0; }
.busca input {
  width: 100%; height: 40px; padding: 0 40px 0 38px; background: var(--surface-2);
  border: 1px solid transparent; border-radius: var(--r-m); transition: border-color .15s ease-out, background-color .15s ease-out;
}
.busca input::placeholder { color: var(--ink-3); }
.busca input:hover { border-color: var(--line-2); }
.busca input:focus { outline: none; background: var(--surface); border-color: var(--ink); }
.busca-i { position: absolute; left: 12px; top: 50%; width: 18px; height: 18px; transform: translateY(-50%); color: var(--ink-3); pointer-events: none; }
.busca-k {
  position: absolute; right: 10px; top: 50%; transform: translateY(-50%); pointer-events: none;
  font: 600 .75rem/1 var(--sans); color: var(--ink-3); background: var(--surface); border: 1px solid var(--line-2); border-radius: 4px; padding: 3px 6px;
}
.busca input:focus ~ .busca-k, .busca input:not(:placeholder-shown) ~ .busca-k { display: none; }
body[data-ruta="buscar"] .top .busca { visibility: hidden; }

/* ---- Estructura ---- */
main { display: block; max-width: var(--w); margin: 0 auto; padding: 0 var(--gut) 72px; overflow-x: clip; }
main:focus, main:focus-visible { outline: none; }
.cab { padding: 40px 0 20px; }
.cab h1 { font-size: clamp(1.875rem, 1.4rem + 1.6vw, 2.625rem); line-height: 1.08; letter-spacing: -.03em; font-weight: 800; max-width: 26ch; }
.cab .lead { margin-top: 12px; font-size: 1.125rem; line-height: 1.55; color: var(--ink-2); max-width: 62ch; }
.cab-d { margin-top: 8px; color: var(--ink-3); }
.barra { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 24px; margin-top: 22px; }

/* ---- Controles ---- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 40px; padding: 0 18px;
  border: 1px solid var(--line-2); border-radius: var(--r-m); background: var(--surface); color: var(--ink);
  font-size: .9375rem; font-weight: 600; text-decoration: none;
}
.btn:hover { background: var(--surface-2); border-color: var(--ink-3); }
.btn--fuerte { background: var(--ink); border-color: var(--ink); color: #fff; }
.btn--fuerte:hover { background: #2c323b; border-color: #2c323b; }

/* Filtro de partidos: punto lleno y borde continuo = se muestra; punto hueco y borde discontinuo = oculto */
.filtro { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.filtro-t { margin-right: 4px; font-size: .875rem; font-weight: 600; color: var(--ink-3); }
.chip {
  display: inline-flex; align-items: center; gap: 0; height: 36px; padding: 0 14px 0 12px;
  border: 1.5px solid var(--line-2); border-radius: 999px; background: var(--surface);
  color: var(--ink); font-size: .875rem; font-weight: 600;
  transition: background-color .15s ease-out, color .15s ease-out, border-color .15s ease-out;
}
.chip:hover { border-color: var(--ink-3); }
.chip[aria-pressed="false"] { background: transparent; border-style: dashed; color: var(--ink-3); font-weight: 500; }
.chip[aria-pressed="false"] .pc { background: transparent; box-shadow: inset 0 0 0 1.5px var(--pc); }
.chip .c { margin-left: 6px; font-weight: 500; color: var(--ink-3); }
.chip .corto { display: none; text-decoration: none; }

.seg { display: inline-flex; padding: 3px; gap: 2px; background: var(--surface-3); border-radius: var(--r-m); }
.seg button { height: 32px; padding: 0 14px; border: 0; background: transparent; border-radius: 9px; color: var(--ink-2); font-size: .875rem; font-weight: 500; white-space: nowrap; transition: background-color .15s ease-out, color .15s ease-out; }
.seg button:hover { color: var(--ink); }
.seg button[aria-pressed="true"] { background: var(--surface); color: var(--ink); font-weight: 700; box-shadow: 0 0 0 1px var(--line-2); }
.btn:active, .chip:active, .seg button:active, .ord:active, .ejemplos a:active { background: var(--surface-3); }
.btn--fuerte:active { background: #000; }

/* Sigla de partido: punto de color + sigla */
.pt {
  display: inline-flex; align-items: center; justify-content: center; gap: 5px; min-width: 30px; height: 26px; padding: 0 8px;
  border-radius: 6px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line-2); color: var(--ink);
  font-size: .8125rem; font-weight: 700; line-height: 1; text-decoration: none; white-space: nowrap;
}
.pt[data-p]::before { content: ""; flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--pc, var(--ink-3)); }
a.pt:hover { box-shadow: inset 0 0 0 1.5px var(--ink); }
.pt .x { font-weight: 500; margin-left: -1px; color: var(--ink-3); }

/* ---- Color de cada partido: siempre junto a su nombre, nunca solo ---- */
[data-p="fa"] { --pc: var(--c-fa); }
[data-p="pp"] { --pc: var(--c-pp); }
[data-p="psoe"] { --pc: var(--c-psoe); }
[data-p="vox"] { --pc: var(--c-vox); }
.pc { display: inline-block; flex: none; width: 10px; height: 10px; margin-right: 8px; border-radius: 50%; background: var(--pc, var(--ink-3)); vertical-align: .05em; }

/* ---- Portada ---- */
.hero { padding: 56px 0 12px; }
.hero h1 { font-size: clamp(2.25rem, 1.5rem + 2.6vw, 3.5rem); line-height: 1.02; letter-spacing: -.035em; font-weight: 800; max-width: 16ch; }
.hero .lead { margin-top: 18px; font-size: 1.1875rem; line-height: 1.55; color: var(--ink-2); max-width: 58ch; }
.hero .lead strong { font-weight: 600; color: var(--ink); }
.hero-p { display: flex; flex-wrap: wrap; gap: 10px 26px; margin: 22px 0 0; padding: 0; list-style: none; }
.hero-p li { display: flex; align-items: baseline; gap: 6px; }
.hero-p a { display: inline-flex; align-items: center; font-weight: 700; }
.hero-p .c { font-size: .8125rem; color: var(--ink-3); }

.bloque { margin-top: 28px; padding: 28px 32px; background: var(--surface); border-radius: var(--r-l); box-shadow: 0 0 0 1px var(--line); }
.bloque-h { margin-bottom: 18px; }
.bloque-h h2 { font-size: 1.625rem; font-weight: 800; letter-spacing: -.025em; line-height: 1.15; }
.bloque-d { margin-top: 6px; color: var(--ink-2); max-width: 70ch; }
.mas-p { margin-top: 20px; }

.indice-nota { max-width: 76ch; margin-bottom: 10px; }
.indice { width: 100%; border-collapse: collapse; }
.indice th, .indice td { text-align: left; vertical-align: middle; padding: 13px 0 13px 24px; border-bottom: 1px solid var(--line); }
.indice th[scope="row"], .indice thead th:first-child { padding-left: 0; }
.indice thead th { padding-top: 12px; padding-bottom: 10px; font-size: .8125rem; font-weight: 600; color: var(--ink-3); border-bottom: 2px solid var(--ink); }
.indice .num { width: 16%; text-align: right; }
.indice .corto { display: none; text-decoration: none; }
.ord { display: inline-flex; align-items: center; gap: 4px; padding: 4px 6px; margin: -4px -6px; border: 0; border-radius: var(--r-s); background: none; color: var(--ink); font-size: .9375rem; font-weight: 700; }
.ord:hover { background: var(--surface-2); }
.ord .i { width: 13px; height: 13px; opacity: .35; transition: opacity .15s ease-out; }
.ord:hover .i, .ord[aria-pressed="true"] .i { opacity: 1; }
.ord[aria-pressed="true"] { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: .3em; }
.ord .pc { width: 9px; height: 9px; margin-right: 6px; }
.indice tbody tr { cursor: pointer; }
.indice tbody tr:hover > * { background: var(--surface-2); }
.indice tbody th a { color: var(--ink); font-size: 1.0625rem; font-weight: 700; letter-spacing: -.01em; text-decoration: none; }
.indice tbody tr:hover th a { text-decoration: underline; }
.n-sub { display: block; margin-top: 1px; font-size: .8125rem; font-weight: 400; color: var(--ink-3); }
.indice td .v { display: block; font-weight: 700; font-size: 1rem; }
.indice td.cero .v { font-weight: 400; color: var(--ink-3); }
/* Barra de ancho fijo, igual con 4 que con 12 partidos; el porcentaje va debajo */
.cuota { display: block; margin-top: 5px; }
.indice .bar { flex: none; width: var(--bar-w, 88px); margin-left: auto; }
.bar { display: block; flex: 1; min-width: 24px; height: 6px; background: var(--surface-3); border-radius: 3px; overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--pc, var(--ink)); border-radius: 3px; }
.indice .q { display: block; margin-top: 3px; flex: none; min-width: 0; font-size: .75rem; font-weight: 500; color: var(--ink-3); text-align: right; white-space: nowrap; }
.indice tfoot th, .indice tfoot td { border-bottom: 0; padding-top: 12px; padding-bottom: 0; font-size: .8125rem; font-weight: 500; color: var(--ink-3); }
.indice tfoot a { color: var(--ink-2); font-weight: 600; }
.indice tfoot .q { margin-left: 4px; }

/* Portada: preguntas destacadas de «Dónde chocan», en lista a dos columnas */
.qcs { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 40px; }
.qc { padding: 18px 0 20px; border-top: 1px solid var(--line); }
.qc-t { font-size: .8125rem; font-weight: 600; color: var(--ink-3); }
.qc-q { margin-top: 2px; font-size: 1.125rem; font-weight: 700; line-height: 1.3; letter-spacing: -.01em; }
.qc-q a { text-decoration: none; }
.qc-q a:hover { text-decoration: underline; }

/* Posturas de una pregunta: una fila por postura. Las siglas van pegadas al nombre y alineadas
   en columna (subgrid), en vez de irse al otro extremo de la fila. */
.pf { list-style: none; margin: 12px 0 0; padding: 0; display: grid; grid-template-columns: minmax(0, max-content) auto; column-gap: 18px; row-gap: 6px; width: fit-content; max-width: 100%; }
.pf li { grid-column: 1 / -1; display: grid; grid-template-columns: subgrid; align-items: center; min-height: 40px; padding: 6px 10px 6px 12px; background: var(--surface-2); border-radius: var(--r-s); }
.pf-n { font-size: .9375rem; line-height: 1.3; }
.pf-p { display: flex; flex-wrap: wrap; gap: 4px; }
.pf--nadie .pf-n { color: var(--ink-3); }
.nadie { font-size: .8125rem; color: var(--ink-3); }

/* ---- Páginas con lateral ---- */
.con-lado { display: grid; grid-template-columns: 216px minmax(0, 1fr); gap: 32px; align-items: start; }
.lado {
  position: sticky; top: var(--top); max-height: calc(100vh - var(--top)); overflow: auto;
  padding: 40px 4px 24px 0; scrollbar-width: thin;
}
.lado-t { margin: 0 0 8px 12px; font-size: .8125rem; font-weight: 600; color: var(--ink-3); }
.lado-l { list-style: none; margin: 0; padding: 0; }
.lado-l a {
  display: flex; justify-content: space-between; gap: 10px; padding: 7px 12px; border-radius: var(--r-s);
  color: var(--ink-2); font-size: .875rem; line-height: 1.35; text-decoration: none;
}
.lado-l a:hover { background: var(--surface-3); color: var(--ink); }
.lado-l a[aria-current] { background: var(--surface); color: var(--ink); font-weight: 700; box-shadow: 0 0 0 1px var(--line-2); }
.lado-l .c { color: var(--ink-3); font-size: .8125rem; font-weight: 400; }
.lado-o, .lado .toc { margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--line-2); font-size: .875rem; }
.lado .toc { margin-top: 0; padding-top: 0; border-top: 0; }
.lado summary, .tambien summary, .toc-m summary { display: flex; align-items: center; gap: 6px; list-style: none; color: var(--ink-2); font-weight: 600; }
.lado summary { padding: 4px 12px; font-size: .8125rem; color: var(--ink-3); }
.lado summary::-webkit-details-marker, .tambien summary::-webkit-details-marker, .toc-m summary::-webkit-details-marker { display: none; }
.lado summary .i-chev, .tambien summary .i-chev, .toc-m summary .i-chev { transform: rotate(-90deg); transition: transform .15s ease-out; }
.lado details[open] > summary .i-chev, .tambien[open] > summary .i-chev, .toc-m[open] > summary .i-chev { transform: none; }
.lado-o ol { list-style: none; margin: 6px 0 0; padding: 0; }
.lado-o a { display: block; padding: 5px 12px; border-radius: var(--r-s); color: var(--ink-2); text-decoration: none; }
.lado-o a:hover { background: var(--surface-3); }
.lado-o a[aria-current] { color: var(--ink); font-weight: 700; }
.subindice, .toc-m { display: none; }

/* ---- Subtema ---- */
.sub { margin-top: 16px; padding: 26px 30px 0; background: var(--surface); border-radius: var(--r-l); box-shadow: 0 0 0 1px var(--line); scroll-margin-top: calc(var(--top) + 16px); }
.sub-h { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; margin-bottom: 16px; }
.sub-h h2 { font-size: 1.5rem; font-weight: 800; letter-spacing: -.025em; line-height: 1.15; }
.sub-h .c { font-size: .875rem; color: var(--ink-3); }
.sub-d { max-width: 70ch; margin: -6px 0 4px; font-size: .9375rem; color: var(--ink-2); }
.sub--choques { padding-bottom: 26px; }

/* Migas: dónde estoy */
.migas { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-bottom: 10px; font-size: .875rem; color: var(--ink-3); }
.migas a { color: var(--ink-2); font-weight: 600; }
.migas [aria-current] { color: var(--ink-3); }

/* ---- Ficha de pregunta: la misma en el tema y en «Dónde chocan» ---- */
.eje { margin-top: 14px; overflow: hidden; background: var(--surface); border-radius: var(--r-l); box-shadow: 0 0 0 1px var(--line); scroll-margin-top: calc(var(--top) + 16px); }
.eje-q { padding: 20px 22px 0; font-size: 1.25rem; font-weight: 800; letter-spacing: -.015em; line-height: 1.25; }
.eje .pf { margin: 14px 22px 0; max-width: calc(100% - 44px); }
.eje-sin { margin: 8px 22px 0; font-size: .8125rem; color: var(--ink-3); }
.eje-acc { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 4px 16px; margin-top: 16px; padding: 6px 22px 6px 14px; border-top: 1px solid var(--line); }
.eje-ver { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 8px; border: 0; border-radius: var(--r-s); background: none; color: var(--ink); font-size: .9375rem; font-weight: 700; }
.eje-ver:hover { background: var(--surface-2); }
.eje-ver:active { background: var(--surface-3); }
.eje-ver .i-chev { transition: transform .15s ease-out; }
.eje-ver[aria-expanded="true"] .i-chev { transform: rotate(180deg); }
.eje-ver[aria-expanded="true"] .si-cerrada, .eje-ver[aria-expanded="false"] .si-abierta { display: none; }
.eje-a { display: inline-block; font-size: .875rem; font-weight: 600; color: var(--ink-2); text-wrap: pretty; }
.eje-a .i { width: 14px; height: 14px; margin-left: 4px; vertical-align: -2px; }
.eje-a:hover { color: var(--ink); }

/* Columnas de partido: cada una lleva arriba la franja de su color */
.fila { display: grid; grid-template-columns: repeat(var(--n), minmax(0, 1fr)); column-gap: 1px; margin: 0 -30px; padding: 0 30px; background: linear-gradient(var(--line), var(--line)) no-repeat 0 0 / 100% 1px; }
.col { min-width: 0; padding: 0 16px 20px; border-top: 3px solid var(--pc, var(--line-2)); }
.col:first-child { padding-left: 0; }
.col:last-child { padding-right: 0; }
.col + .col { box-shadow: -1px 0 0 var(--line); }
.col-h { position: sticky; top: var(--top); z-index: 2; display: flex; align-items: baseline; gap: 0; padding: 12px 0 8px; background: var(--surface); font-size: 1rem; font-weight: 800; }
.col-h .c { margin-left: 8px; font-size: .8125rem; font-weight: 500; color: var(--ink-3); }
.col-h .pc { align-self: center; }
.pestanas { display: none; }
.col-l { display: flex; flex-direction: column; }

/* ---- Extracto ---- */
.ex { border-bottom: 1px solid var(--line); scroll-margin-top: calc(var(--top) + 56px); border-radius: 2px; }
.col-l > .ex:last-child, .lista > .ex:last-child { border-bottom: 0; }
.ex-hh { margin: 0; font: inherit; text-wrap: pretty; }
.ex-h { display: flex; align-items: flex-start; gap: 10px; width: 100%; padding: 12px 0; border: 0; background: none; color: var(--ink); text-align: left; }
.ex-h .pt { margin-top: -2px; }
.ex-tit { flex: 1; font-size: .9375rem; font-weight: 600; line-height: 1.38; letter-spacing: -.005em; }
.ex-h:hover .ex-tit { text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: .2em; }
.ex-h .i-chev { margin-top: 2px; color: var(--ink-3); transition: transform .15s ease-out; }
.ex.abierto .ex-h .i-chev { transform: rotate(180deg); }
.ex:not(.abierto) .ex-body { display: none; }
.ex-body { padding: 0 0 16px; }
.ex-txt {
  max-width: 70ch; font-family: var(--serif); font-size: 1.0625rem; line-height: 1.55; color: var(--ink);
  font-optical-sizing: auto; hyphens: auto; overflow-wrap: break-word;
}
.ex-txt p + p, .ex-txt p + ul, .ex-txt ul + p { margin-top: .6em; }
.ex-txt ul { margin: .4em 0 0; padding-left: 1.15em; }
.ex-txt ul ul { margin-top: .35em; }
.ex-txt li + li { margin-top: .35em; }
.ex-txt li::marker { color: var(--ink-3); }
.ex-txt strong { font-weight: 600; }
.ex-src { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 8px; margin-top: 10px; font-size: .8125rem; color: var(--ink-3); }
.ex-src a { display: inline-flex; align-items: center; gap: 3px; color: var(--ink-2); font-weight: 600; }
.ex-src .i { width: 13px; height: 13px; }
.ex-src .sep { color: var(--line-2); }
.ex-ruta { margin-top: 2px; font-size: .8125rem; color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ex--fijo .ex-tit { display: block; margin: 18px 0 6px; font-size: .8125rem; font-weight: 600; color: var(--ink-3); }
/* Al llegar desde un enlace, el extracto destella en amarillo para encontrarlo */
.ex.destello { animation: destello 2.4s ease-out; }
@keyframes destello { 0%, 35% { background: color-mix(in srgb, var(--mark) 45%, transparent); box-shadow: 0 0 0 8px color-mix(in srgb, var(--mark) 45%, transparent); } 100% { background: transparent; box-shadow: 0 0 0 8px transparent; } }

/* Resumen: titular + dos líneas del texto literal */
.ex:not(.abierto):not(.ex--fijo) .ex-body { display: block; padding-bottom: 12px; margin-top: -4px; }
.ex:not(.abierto):not(.ex--fijo) .ex-src, .ex:not(.abierto):not(.ex--fijo) .ex-ruta { display: none; }
.ex:not(.abierto):not(.ex--fijo) .ex-txt {
  max-height: 3em; overflow: hidden; font-size: .9375rem; line-height: 1.5; color: var(--ink-2); cursor: pointer;
  -webkit-mask-image: linear-gradient(#000 45%, transparent); mask-image: linear-gradient(#000 45%, transparent);
}
.ex:not(.abierto):not(.ex--fijo) .ex-txt ul { padding-left: 0; list-style: none; }
.vista { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; }
.vista .nota { font-size: .8125rem; }

.tambien { margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line); font-size: .875rem; }
.tambien summary .c { margin-left: auto; font-weight: 500; color: var(--ink-3); }
.tambien > .col-l { margin-top: 4px; }

.paso { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 24px; }
.paso-a { display: flex; flex-direction: column; gap: 4px; padding: 16px 20px; background: var(--surface); border-radius: var(--r-l); box-shadow: 0 0 0 1px var(--line); color: var(--ink); text-decoration: none; transition: box-shadow .15s ease-out; }
.paso-a:hover { box-shadow: 0 0 0 1.5px var(--ink-3); }
.paso-a.der { grid-column: 2; align-items: flex-end; text-align: right; }
.paso-k { display: inline-flex; align-items: center; gap: 6px; font-size: .8125rem; color: var(--ink-3); }
.paso-n { font-weight: 800; font-size: 1.125rem; letter-spacing: -.015em; }

/* ---- Dónde chocan ---- */
.grupo-ejes { margin-top: 32px; scroll-margin-top: calc(var(--top) + 16px); }
.grupo-h { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 16px; margin-bottom: 4px; }
.grupo-h h2 { font-size: 1.5rem; font-weight: 800; letter-spacing: -.025em; }
.eje-par { display: grid; grid-template-columns: repeat(var(--k), minmax(0, 1fr)); gap: 1px; background: var(--line); border-top: 1px solid var(--line); }
.eje-par[hidden] { display: none; }
/* Altura máxima por partido, con scroll propio: la cita más larga no estira toda la fila */
.cp { display: flex; flex-direction: column; }
.cp-cuerpo { max-height: 20rem; overflow-y: auto; scrollbar-width: thin; scrollbar-color: var(--line-2) transparent; padding-right: 6px; margin-right: -6px; }
.cp { min-width: 0; padding: 14px 20px 20px; background: var(--surface); border-top: 3px solid var(--pc, var(--line-2)); }
.cp-n { display: flex; align-items: center; margin-bottom: 10px; font-size: 1rem; font-weight: 800; }
.cp-pos + .cp-pos { margin-top: 16px; padding-top: 14px; border-top: 1px dashed var(--line-2); }
.postura { margin-bottom: 10px; font-size: .875rem; font-weight: 700; line-height: 1.35; color: var(--ink-2); }
.cp ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.cita { margin: 0; padding-left: 14px; border-left: 2px solid var(--line-2); font-family: var(--serif); font-size: 1.0625rem; line-height: 1.45; color: var(--ink); }
.cp .cita { font-size: 1rem; }
.cita::before { content: "«"; }
.cita::after { content: "»"; }
.cita-tit { padding-left: 14px; font-weight: 600; }
.ir { display: inline-flex; align-items: center; gap: 4px; margin: 6px 0 0 16px; font-size: .8125rem; font-weight: 600; color: var(--ink-2); }
.ir:hover { color: var(--ink); }
.ir .i { width: 13px; height: 13px; }
.cp--sin { background: var(--surface-2); }
.cp--sin .nadie { font-size: .875rem; }
.nota--pie { margin-top: 32px; }

/* ---- Programas ---- */
.programas { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.programas li { position: relative; display: flex; }
.pg { flex: 1; display: flex; flex-direction: column; gap: 6px; padding: 22px 24px 20px; background: var(--surface); border-radius: var(--r-l); box-shadow: 0 0 0 1px var(--line); border-top: 4px solid var(--pc); color: var(--ink); text-decoration: none; transition: box-shadow .15s ease-out; }
.pg:hover { box-shadow: 0 0 0 1.5px var(--ink-3); }
.pg-n { display: flex; align-items: center; padding-right: 120px; font-size: 1.5rem; font-weight: 800; letter-spacing: -.025em; line-height: 1.15; }
.pg-t { font-family: var(--serif); font-size: 1.3rem; line-height: 1.3; }
.pg-d { font-size: .875rem; color: var(--ink-3); }
.pg-s { display: flex; flex-wrap: wrap; gap: 4px 18px; margin-top: 10px; font-size: .875rem; color: var(--ink-2); }
.pg-s b { color: var(--ink); font-weight: 700; }
.pg-a { display: inline-flex; align-items: center; gap: 6px; margin-top: auto; padding-top: 14px; font-weight: 700; }
.pg:hover .pg-a { text-decoration: underline; }
.pg-pdf { position: absolute; top: 26px; right: 24px; display: inline-flex; align-items: center; gap: 4px; font-size: .8125rem; font-weight: 600; }
.descargas { display: flex; flex-wrap: wrap; gap: 10px; margin: 20px 0 0; }
.descargas .btn { height: auto; min-height: 40px; padding: 8px 16px; flex-wrap: wrap; gap: 2px 8px; white-space: nowrap; }
.descargas .btn span { font-weight: 400; color: var(--ink-3); }

.prog-titulo { font-family: var(--serif); font-weight: 500; letter-spacing: -.01em; }
.ficha { display: grid; gap: 6px; margin-top: 16px; font-size: .875rem; color: var(--ink-2); max-width: 70ch; }
.ficha div { display: grid; grid-template-columns: 104px minmax(0, 1fr); gap: 12px; }
.ficha dt { color: var(--ink-3); }
.ficha dd { margin: 0; }
.ficha a { display: inline-flex; align-items: center; gap: 3px; }
.prog-txt { max-width: 760px; padding: 8px 44px 40px; background: var(--surface); border-radius: var(--r-l); box-shadow: 0 0 0 1px var(--line); }
.prog-txt .cap { font-family: var(--serif); font-weight: 600; line-height: 1.22; letter-spacing: -.01em; scroll-margin-top: calc(var(--top) + 16px); }
.prog-txt h2.cap { margin-top: 44px; padding-top: 24px; border-top: 1px solid var(--line); font-size: 1.75rem; }
.prog-txt > h2.cap:first-child { margin-top: 20px; padding-top: 0; border-top: 0; }
.prog-txt h3.cap { margin-top: 32px; font-size: 1.375rem; }
.prog-txt h4.cap { margin-top: 24px; font-size: 1.125rem; }
.prog-txt .ex { border-bottom: 0; }
.prog-txt .ex-body { padding-bottom: 4px; }

/* Llegada desde «Ver en su programa»: el extracto en su sitio, con la cita subrayada en amarillo */
.ex--aqui { margin: 20px -20px 8px; padding: 4px 20px 14px; background: #fffbe8; border-radius: var(--r-m); box-shadow: inset 0 0 0 1px #f0dc8a; scroll-margin-top: calc(var(--top) + 24px); }
.aqui { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; padding-top: 10px; }
.aqui-t { font-size: .875rem; font-weight: 700; color: var(--ink); }
.aqui-v { height: 34px; padding: 0 12px 0 10px; font-size: .875rem; }
mark.subr { background: var(--mark); color: var(--mark-ink); padding: .05em 0; -webkit-box-decoration-break: clone; box-decoration-break: clone; }

/* ---- Búsqueda ---- */
.busca-v { position: relative; display: flex; gap: 8px; max-width: 680px; margin-top: 18px; }
.busca-v .busca-i { left: 16px; width: 20px; height: 20px; }
.busca-v input {
  flex: 1; min-width: 0; height: 52px; padding: 0 16px 0 46px; background: var(--surface);
  border: 1.5px solid var(--line-2); border-radius: var(--r-m); font-size: 1.0625rem;
}
.busca-v input::placeholder { color: var(--ink-3); }
.busca-v input:hover { border-color: var(--ink-3); }
.busca-v input:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 1px var(--ink); }
.busca-v .btn { height: 52px; padding: 0 22px; font-size: 1rem; }
.cab--buscar .nota { margin-top: 10px; }
.res-n { margin-top: 14px; font-size: 1.0625rem; color: var(--ink-2); }
.ejemplos { margin-top: 26px; }
.ejemplos-t { margin-bottom: 10px; font-size: .875rem; font-weight: 600; color: var(--ink-3); }
.ejemplos ul { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
.ejemplos a {
  display: inline-flex; align-items: center; height: 40px; padding: 0 16px; background: var(--surface);
  border-radius: 999px; box-shadow: inset 0 0 0 1px var(--line-2); font-weight: 600; text-decoration: none;
}
.ejemplos a:hover { box-shadow: inset 0 0 0 1.5px var(--ink); }
.ejemplos .c { margin-left: 8px; font-size: .8125rem; font-weight: 500; color: var(--ink-3); }
.res-p { max-width: 54rem; margin-top: 20px; padding: 20px 28px 8px; background: var(--surface); border-radius: var(--r-l); box-shadow: 0 0 0 1px var(--line); border-top: 4px solid var(--pc); scroll-margin-top: calc(var(--top) + 16px); }
.res-p > h2 { display: flex; align-items: center; padding-bottom: 8px; font-size: 1.25rem; font-weight: 800; letter-spacing: -.015em; border-bottom: 1px solid var(--line); }
.res-p > h2 .c { margin-left: 10px; font-size: .875rem; font-weight: 500; color: var(--ink-3); }
.lista { display: flex; flex-direction: column; }
.cuerpo > .lista { padding: 4px 28px; background: var(--surface); border-radius: var(--r-l); box-shadow: 0 0 0 1px var(--line); }
.mas { padding: 12px 0 14px; }

/* ---- Pie ---- */
.pie { border-top: 1px solid var(--line); background: var(--surface); }
.pie-in { max-width: var(--w); margin: 0 auto; padding: 32px var(--gut) 48px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: 32px 64px; align-items: start; font-size: .875rem; color: var(--ink-2); }
.pie h2 { margin-bottom: 12px; font-size: .9375rem; font-weight: 700; color: var(--ink); }
.pie a { color: var(--ink-2); }
.pie-fuentes summary { display: inline-flex; align-items: center; gap: 6px; list-style: none; font-weight: 600; color: var(--ink); }
.pie-fuentes summary::-webkit-details-marker { display: none; }
.pie-fuentes summary .i-chev { transform: rotate(-90deg); transition: transform .15s ease-out; }
.pie-fuentes[open] summary .i-chev { transform: none; }
.pie-fuentes ul { list-style: none; margin: 12px 0 0; padding: 0 0 0 22px; }
.pie-fuentes li + li { margin-top: 6px; }
.pie-fuentes p { margin-top: 12px; padding-left: 22px; color: var(--ink-3); }
.opina-campos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.opina-msg { grid-column: 1 / -1; }
.campo-t { font-size: .8125rem; font-weight: 600; color: var(--ink-2); }
.campo-t .opc { font-weight: 400; color: var(--ink-3); }
.opina input, .opina textarea {
  width: 100%; padding: 10px 12px; border: 1px solid var(--line-2); border-radius: var(--r-m);
  background: var(--surface); color: var(--ink); font: inherit; font-size: 1rem;
}
.opina input { height: 44px; }
.opina textarea { min-height: 7rem; resize: vertical; line-height: 1.45; }
.opina input:hover, .opina textarea:hover { border-color: var(--ink-3); }
.opina input:focus, .opina textarea:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 1px var(--ink); }
.opina-pie { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; margin-top: 12px; }
.opina-estado { color: var(--ink-2); }
@media (max-width: 760px) {
  .pie-in { grid-template-columns: minmax(0, 1fr); }
  .opina-campos { grid-template-columns: minmax(0, 1fr); }
}

/* ---- Añadir partidos: botón de la cabecera y panel con las candidaturas ---- */
.btn--peq { height: 36px; padding: 0 14px; font-size: .875rem; }
.btn:disabled { opacity: .6; cursor: default; }
.enlace { padding: 0; border: 0; background: none; color: var(--ink); font: inherit; font-weight: 600; text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: .2em; cursor: pointer; }
.enlace:hover { text-decoration-color: currentColor; }
.top-partidos { flex: none; height: 40px; padding: 0 12px 0 14px; }
.top-partidos .c { display: inline-flex; align-items: center; justify-content: center; min-width: 22px; height: 22px; margin-left: 4px; padding: 0 6px; border-radius: 999px; background: var(--surface-3); font-size: .8125rem; font-weight: 700; color: var(--ink-2); }

/* ---- Selector de idioma: un circulito con la bandera; al pulsarlo bajan los demás ---- */
.idiomas { position: relative; flex: none; display: flex; align-items: center; margin-left: -12px; }
.idi-b, .idi-a { display: block; width: 22px; height: 22px; padding: 0; border: 0; border-radius: 50%; background: none; cursor: pointer; }
/* el área de pulsación es mayor que el círculo (36px) sin que el círculo crezca */
.idi-b, .idi-a { position: relative; }
.idi-b::after, .idi-a::after { content: ""; position: absolute; inset: -7px; border-radius: 50%; }
.idi-f { display: block; width: 100%; height: 100%; border-radius: 50%; box-shadow: 0 0 0 1px rgba(21, 24, 29, .14); opacity: .9; transition: opacity .15s ease, box-shadow .15s ease; }
.idi-b:hover .idi-f, .idi-a:hover .idi-f { opacity: 1; box-shadow: 0 0 0 1px rgba(21, 24, 29, .35); }
.idi-b:focus-visible, .idi-a:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
.idiomas.abierta .idi-b .idi-f { opacity: 1; box-shadow: 0 0 0 1.5px var(--ink); }
.idi-l { position: absolute; top: calc(100% + 10px); right: 0; z-index: 30; display: flex; flex-direction: column; align-items: flex-end; gap: 12px; margin: 0; padding: 0; list-style: none; }
.idi-l[hidden] { display: none; }
.idi-l li { position: relative; animation: idi-sale .16s ease both; animation-delay: calc(var(--k) * 30ms); }
.idi-a .idi-f { opacity: 1; box-shadow: 0 0 0 1px rgba(21, 24, 29, .14), 0 1px 4px rgba(21, 24, 29, .16); }
.idi-n { position: absolute; right: calc(100% + 8px); top: 50%; transform: translateY(-50%); padding: 2px 8px; border-radius: 999px; background: var(--ink); color: #fff; font-size: .75rem; font-weight: 600; white-space: nowrap; opacity: 0; pointer-events: none; transition: opacity .12s ease; }
.idi-a:hover .idi-n, .idi-a:focus-visible .idi-n { opacity: 1; }
@keyframes idi-sale { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .idi-l li { animation: none; } }
@media (max-width: 760px) {
  .idiomas { margin-left: -14px; }
}

/* Con más de cuatro partidos, la tabla de temas se desplaza en horizontal y el nombre del tema queda fijo */
/* position: relative para que los textos .sr (absolutos) de las columnas no escapen del desplazamiento y ensanchen la página */
.indice-scroll { position: relative; overflow-x: auto; }
/* Columnas de partido iguales, sea cual sea la longitud del nombre, para que las barras se comparen a la misma escala */
.indice-w--ancha .indice { table-layout: fixed; width: max(100%, calc(14rem + var(--np) * 7rem)); }
.indice-w--ancha .indice thead th:first-child { width: 14rem; }
.indice-w--ancha .indice .num { width: auto; }
.indice-w--ancha .ord { text-align: right; }
.indice-w--ancha .indice th[scope="row"], .indice-w--ancha .indice thead th:first-child { position: sticky; left: 0; z-index: 1; min-width: 12rem; padding-right: 12px; background: var(--surface); }
.indice-w--ancha .indice tbody tr:hover th[scope="row"] { background: var(--surface-2); }
.fila { row-gap: 20px; }
.pc--vacio { background: transparent; box-shadow: inset 0 0 0 1.5px var(--line-2); }

.dlg { width: min(760px, calc(100vw - 32px)); max-width: none; height: min(860px, calc(100dvh - 48px)); max-height: none; padding: 0; border: 0; border-radius: var(--r-l); background: var(--surface); color: var(--ink); box-shadow: 0 0 0 1px var(--line-2); }
.dlg::backdrop { background: rgb(21 24 29 / .5); }
html:has(.dlg[open]) { overflow: hidden; }
.dlg-in { display: flex; flex-direction: column; height: 100%; }
.dlg-h { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 24px; border-bottom: 1px solid var(--line); }
.dlg-h h2 { font-size: 1.375rem; font-weight: 800; letter-spacing: -.02em; line-height: 1.2; }
.dlg-x { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; margin: -6px -10px 0 0; border: 0; border-radius: var(--r-m); background: none; color: var(--ink-2); }
.dlg-x:hover { background: var(--surface-2); color: var(--ink); }
.dlg-x .i { width: 18px; height: 18px; }
.dlg-cuerpo { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; }
.dlg-sel { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 16px 24px 0; }
.dlg-st { font-size: .875rem; font-weight: 600; color: var(--ink-3); }
.dlg-st .c { margin-left: 2px; color: var(--ink); }
.dlg-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; list-style: none; }
.chip--quitar { gap: 6px; height: 32px; padding: 0 8px 0 10px; }
.chip--quitar .pc { margin-right: 0; }
.chip--quitar .i { width: 13px; height: 13px; color: var(--ink-3); }
.chip--quitar:hover .i { color: var(--ink); }
.chip--quitar:disabled { padding-right: 12px; cursor: default; }
.dlg-base { font-size: .875rem; }
.dlg-f { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; padding: 16px 24px 18px; }
.campo { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.campo--q { grid-column: 1 / -1; }
.campo input[type="search"] {
  width: 100%; height: 44px; padding: 0 12px; border: 1px solid var(--line-2); border-radius: var(--r-m);
  background: var(--surface); color: var(--ink); font: inherit; font-size: 1rem;
}
.campo input:hover { border-color: var(--ink-3); }
.campo input:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 1px var(--ink); }
.dlg-acc { position: sticky; top: 0; z-index: 1; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; padding: 12px 24px; background: var(--surface-2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.dlg-n { font-size: .875rem; font-weight: 600; color: var(--ink-2); }
.dlg-bs { display: flex; flex-wrap: wrap; gap: 8px; }
.dlg-ok { display: inline-flex; align-items: center; height: 36px; font-size: .875rem; color: var(--ink-3); outline: none; }
.cands { margin: 0; padding: 0 24px; list-style: none; }
.cand { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.cand > p { grid-column: 1; }
.cand-n { display: flex; align-items: baseline; flex-wrap: wrap; gap: 0 8px; font-weight: 700; line-height: 1.3; }
.cand-n .pc { margin-right: 0; align-self: center; }
.cand-s { font-size: .8125rem; font-weight: 500; color: var(--ink-3); }
.cand-d { margin-top: 3px; font-size: .875rem; color: var(--ink-2); }
.cand-d .sep { margin: 0 6px; color: var(--line-2); }
.cand-mas { color: var(--ink-3); }
.cand-e { margin-top: 3px; font-size: .8125rem; line-height: 1.45; color: var(--ink-3); }
.cand-e a { display: inline-flex; align-items: center; gap: 3px; color: var(--ink-2); font-weight: 600; }
.cand-e .i { width: 13px; height: 13px; }
.cand--sin .cand-n { font-weight: 600; color: var(--ink-3); }
.cand--sin .cand-d, .cand--sin .cand-s { color: var(--ink-3); }
.cand-b { grid-column: 2; grid-row: 1 / span 3; align-self: center; min-width: 7.5rem; }
.cand-b .si-si, .cand-b[aria-pressed="true"] .si-no { display: none; }
.cand-b .si-no, .cand-b[aria-pressed="true"] .si-si { display: inline-flex; align-items: center; gap: 6px; }
.cand-b[aria-pressed="true"] { background: var(--surface-2); border-color: var(--line); color: var(--ink-2); }
.cand-b[aria-pressed="true"]:hover { border-color: var(--ink-3); }
.cand-b:disabled { opacity: .6; cursor: default; }
.dlg-vacio { padding: 20px 24px; }
.dlg-pie { display: flex; justify-content: flex-end; padding: 12px 24px; border-top: 1px solid var(--line); }
/* Panel en dos columnas: a la izquierda la lista alfabética (con su propio scroll), a la derecha el mapa y lo elegido */
.dlg { width: min(1180px, calc(100vw - 32px)); }
.dlg-cuerpo { display: grid; grid-template-columns: minmax(0, 1fr) minmax(360px, 44%); overflow: hidden; }
.dlg-izq { min-height: 0; overflow-y: auto; overscroll-behavior: contain; border-right: 1px solid var(--line); }
.dlg-der { min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding-bottom: 20px; }
.dlg-izq .dlg-f { grid-template-columns: minmax(0, 1fr); }
.mapa { padding: 16px 24px 0; }
.mapa-t { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 2px 12px; min-height: 2.75rem; outline: none; }
.mapa-t > span:first-child { font-size: 1.0625rem; font-weight: 700; letter-spacing: -.01em; }
.mapa-t .enlace { font-size: .875rem; }
.mapa-svg { display: block; width: 100%; height: auto; margin-top: 6px; overflow: visible; }
.mapa-marco { fill: none; stroke: var(--line-2); stroke-width: 1; }
.mapa-z { cursor: pointer; outline: none; }
.mapa-z path, .mapa-z circle { fill: var(--line-2); stroke: var(--surface); stroke-width: .6; stroke-linejoin: round; transition: fill .12s; }
.mapa-lineas { fill: none; stroke: var(--surface); stroke-width: 2; stroke-linejoin: round; pointer-events: none; }
.mapa-z circle { fill-opacity: 0; stroke: var(--ink-3); stroke-width: 1; }
.mapa-z:hover path, .mapa-z:focus-visible path { fill: var(--ink-3); }
.mapa-z:focus-visible path { stroke: var(--ink); stroke-width: 2; }
.mapa-z--vacia path { fill: var(--surface-3); }
.mapa-z[aria-pressed="true"] path { fill: var(--ink); }
.mapa-z:hover circle, .mapa-z:focus-visible circle { stroke: var(--ink); stroke-width: 2; }
.mapa-z[aria-pressed="true"] circle { fill: var(--ink); fill-opacity: .9; stroke: var(--ink); }
.mapa-h { min-height: 1.4em; margin-top: 4px; font-size: .875rem; color: var(--ink-2); text-align: center; }
.mapa-ir { display: none; }
.dlg-der .dlg-sel { margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--line); }
@media (max-width: 860px) {
  .dlg-cuerpo { display: flex; flex-direction: column; overflow-y: auto; }
  .dlg-izq, .dlg-der { flex: none; min-height: auto; overflow: visible; border-right: 0; }
  .dlg-der { order: -1; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
  .mapa-svg { max-width: 400px; margin-left: auto; margin-right: auto; }
  .mapa-h { display: none; }
  .mapa-ir { display: flex; width: 100%; margin-top: 8px; }
}
.top-partidos .tp-corto { display: none; }
@media (max-width: 760px) {
  .top-partidos { margin-left: auto; }
}
@media (max-width: 420px) {
  .top-in { gap: 20px; }
  .idiomas { margin-left: -8px; }
  /* el subtítulo de la marca cede antes que los botones (en euskera o gallego es más largo) */
  .marca { flex: 0 1 auto; min-width: 0; }
  .marca-s { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
  .top-partidos { padding: 0 10px 0 12px; }
  .top-partidos .tp-largo { display: none; }
  .top-partidos .tp-corto { display: inline; }
}
@media (max-width: 359px) {
  .top-partidos .i { display: none; }
}
@media (max-width: 640px) {
  .dlg { width: 100vw; height: 100dvh; margin: 0; border-radius: 0; }
  .dlg-h, .dlg-sel, .dlg-f, .dlg-acc, .dlg-pie, .dlg-vacio, .mapa { padding-left: var(--gut); padding-right: var(--gut); }
  .cands { padding: 0 var(--gut); }
  .cand { grid-template-columns: minmax(0, 1fr); }
  .cand-b { grid-column: 1; grid-row: auto; justify-self: start; margin-top: 10px; }
  .dlg-pie .btn { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; }
  .ex.destello { animation: none; outline: 3px solid var(--mark); outline-offset: 6px; }
}

/* ---- Texto completo en escritorio: un partido por fila, a medida de lectura ---- */
@media (min-width: 821px) {
  [data-lectura="texto"] .fila { display: block; padding: 0; background: none; }
  [data-lectura="texto"] .fila > .col {
    display: grid; grid-template-columns: 148px minmax(0, 1fr); column-gap: 24px;
    padding: 0 30px 16px; box-shadow: none;
  }
  [data-lectura="texto"] .col > .col-h { grid-column: 1; grid-row: 1 / span 3; align-self: start; padding-top: 12px; }
  [data-lectura="texto"] .col > :not(.col-h) { grid-column: 2; }
  [data-lectura="texto"] .col > .vacio { padding-top: 12px; }
  /* Altura máxima por partido, como en «Dónde chocan». En móvil no hace falta: se ve un partido cada vez */
  .fila > .col > .col-l, .tambien > .col-l { max-height: 30rem; overflow-y: auto; scrollbar-width: thin; scrollbar-color: var(--line-2) transparent; padding-right: 6px; margin-right: -6px; }
}

/* ---- Responsive ---- */
@media (max-width: 1080px) {
  .con-lado { grid-template-columns: 200px minmax(0, 1fr); gap: 28px; }
  .eje-par { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cp:last-child:nth-child(odd) { grid-column: 1 / -1; }
}
@media (max-width: 960px) {
  .con-lado { display: block; }
  .lado { display: none; }
  .eje-par { grid-template-columns: repeat(var(--k), minmax(0, 1fr)); }
  .cp:last-child:nth-child(odd) { grid-column: auto; }
  .subindice { display: flex; gap: 4px 18px; margin: 18px calc(-1 * var(--gut)) 0; padding: 0 var(--gut) 4px; overflow-x: auto; scrollbar-width: none; list-style: none; }
  .subindice::-webkit-scrollbar { display: none; }
  .subindice a { flex: none; padding: 4px 0; color: var(--ink-2); font-size: .875rem; font-weight: 500; white-space: nowrap; text-decoration-color: var(--line-2); }
  .subindice .c { margin-left: 5px; color: var(--ink-3); font-weight: 400; }
  .toc-m { display: block; margin-top: 18px; padding: 12px 14px; background: var(--surface); border-radius: var(--r-m); box-shadow: 0 0 0 1px var(--line); font-size: .875rem; }
  .toc-m ol { margin: 10px 0 0; padding: 0 0 0 4px; list-style: none; max-height: 50vh; overflow: auto; }
  .toc-m li { padding: 4px 0; }
  .toc-m a { color: var(--ink-2); text-decoration: none; }
  .qcs { grid-template-columns: 1fr; }
}
@media (max-width: 820px) {
  .fila { display: block; padding: 0; background: none; }
  .fila > .col { display: none; padding: 4px 30px 16px; border-top: 0; box-shadow: none; }
  .fila > .col.on { display: block; }
  .col-h { display: none; }
  .pestanas {
    position: sticky; top: var(--top); z-index: 3; display: flex; gap: 4px; margin: 0 -30px; padding: 0 20px;
    overflow-x: auto; scrollbar-width: none; background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  }
  .pestanas::-webkit-scrollbar { display: none; }
  .pestanas button {
    flex: none; display: inline-flex; align-items: center; gap: 0; height: 48px; padding: 0 10px;
    border: 0; border-bottom: 3px solid transparent; margin-bottom: -1px; background: none;
    color: var(--ink-3); font-size: .9375rem; font-weight: 600;
  }
  .pestanas button[aria-selected="true"] { color: var(--ink); font-weight: 800; border-bottom-color: var(--pc, var(--ink)); }
  .pestanas .c { margin-left: 6px; font-size: .8125rem; font-weight: 500; color: var(--ink-3); }
  .pestanas .pc { align-self: center; }
  .pestanas .corto { display: none; text-decoration: none; }
  .ex { scroll-margin-top: calc(var(--top) + 60px); }
  .eje-par { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cp:last-child:nth-child(odd) { grid-column: 1 / -1; }
}

/* Móvil: cabecera de una línea y navegación abajo, al alcance del pulgar */
@media (max-width: 760px) {
  :root { --top: 0px; --abajo: calc(64px + env(safe-area-inset-bottom)); }
  .top { position: static; }
  .top-in { height: 56px; }
  .busca { display: none; }
  .nav {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: grid; grid-template-columns: repeat(4, 1fr); gap: 0;
    height: var(--abajo); padding-bottom: env(safe-area-inset-bottom); background: var(--surface); border-top: 1px solid var(--line-2);
  }
  .nav a { flex-direction: column; justify-content: center; gap: 3px; padding: 0 2px; font-size: .75rem; font-weight: 600; color: var(--ink-3); }
  .nav a::after { top: -1px; bottom: auto; left: 28%; right: 28%; border-radius: 0 0 3px 3px; }
  .nav a:hover::after { background: transparent; }
  .nav a[aria-current="page"] { color: var(--ink); font-weight: 800; }
  .nav a:active { background: var(--surface-2); }
  .nav-i { display: block; }
  .nav-buscar { display: flex !important; }
  .hero { padding-top: 32px; }
  .indice th, .indice td { padding-left: 8px; }
  .indice .num { width: 17%; }
  .indice .largo { display: none; }
  .indice .corto { display: inline; }
  .ord { font-size: .8125rem; }
  .ord .i, .ord .pc { display: none; }
  .n-sub { display: none; }
  .indice tbody th a { font-size: .9375rem; }
  .indice td .v { font-size: .875rem; }
  .indice { --bar-w: 52px; }
  .indice .q { display: block; min-width: 0; margin-top: 3px; }
  .indice tfoot .q { display: none; }
  .programas { grid-template-columns: 1fr; }
  .paso { grid-template-columns: 1fr; }
  .paso-a.der { grid-column: auto; }
}
@media (max-width: 640px) {
  .bloque, .sub, .res-p, .prog-txt, .cuerpo > .lista, .grupo-ejes > .eje {
    margin-left: calc(-1 * var(--gut)); margin-right: calc(-1 * var(--gut)); border-radius: 0;
  }
  .bloque { padding: 22px var(--gut); }
  .sub { padding: 22px var(--gut) 0; }
  .fila, .pestanas { margin-left: calc(-1 * var(--gut)); margin-right: calc(-1 * var(--gut)); }
  .pestanas { padding: 0 calc(var(--gut) - 10px); }
  .pestanas .largo { display: none; }
  .pestanas .corto { display: inline; }
  .fila > .col { padding: 4px var(--gut) 16px; }
  .res-p { padding: 16px var(--gut) 4px; }
  .prog-txt { padding: 4px var(--gut) 28px; }
  .cuerpo > .lista { padding: 4px var(--gut); }
  .eje-par { grid-template-columns: 1fr; }
  .eje-q { padding: 18px var(--gut) 0; font-size: 1.125rem; }
  .eje .pf { margin: 12px var(--gut) 0; max-width: none; }
  .eje-sin { margin: 8px var(--gut) 0; }
  .eje-acc { padding: 4px var(--gut) 10px calc(var(--gut) - 8px); }
  .eje-acc .eje-a { margin-left: 8px; }
  .sub--choques .eje { margin-left: -6px; margin-right: -6px; }
  .cp { padding: 14px var(--gut) 18px; }
  .pf { width: auto; grid-template-columns: minmax(0, 1fr); }
  .pf li { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; }
  .ex--aqui { margin-left: calc(-1 * var(--gut) + 4px); margin-right: calc(-1 * var(--gut) + 4px); padding-left: calc(var(--gut) - 4px); padding-right: calc(var(--gut) - 4px); }
  .pg { padding: 18px 18px 16px; }
  .pg-pdf { top: 22px; right: 18px; }
  .cab { padding-top: 28px; }
  .cab .lead, .hero .lead { font-size: 1.0625rem; }
  .chip .largo { display: none; }
  .chip .corto { display: inline; }
  .chip { padding: 0 11px 0 10px; }
  .chip .pc { margin-right: 6px; }
  .chip .c { margin-left: 5px; }
  .filtro { gap: 6px; }
  .filtro-t { flex-basis: 100%; }
  .barra { margin-top: 16px; }
  .busca-v .btn { padding: 0 16px; }
}

/* ---- Pantallas táctiles: toda zona pulsable mide al menos 44 px ---- */
@media (pointer: coarse) {
  .chip, .btn, .seg button { min-height: 44px; }
  .chip { height: auto; }
  .ord { min-height: 44px; margin: -12px -6px; }
  .subindice a, .ir, .hero-p a, .ex-src a, .qc-q a, .ejemplos a, .migas a { display: inline-flex; align-items: center; min-height: 44px; }
  .eje-a { padding: 12px 0; }
  .eje-ver { min-height: 44px; }
  .lado summary, .tambien summary, .toc-m summary, .pie-fuentes summary { min-height: 44px; }
}
