/* ============================================================
   Wordle Asturianu 2.0 — «brutalismo suave» (herencia Caxellu)
   Paleta PlayPresta: miel #FFD23F, magenta #F35BD3 (celebración),
   morado nocturno #1C0F21. Archivo Black (títulos) + Space
   Grotesk (resto). Fondo crema-cera en claro, sombras duras
   pequeñas en botones y teclas.
   Semántica Wordle: verde = correcta, miel = presente, gris =
   ausente. Modo daltónico: naranja / azul.
   ============================================================ */

/* Tipografíes sirvíes dende'l propiu hosting (copiar los .woff2
   de Caxellu a assets/fonts/). Si nun tán, úsase la del sistema. */
@font-face {
  font-family: 'Archivo Black';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/archivo-black-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-20C0, U+2113,
    U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Archivo Black';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/archivo-black-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: 'Space Grotesk';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('fonts/space-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-20C0, U+2113,
    U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Space Grotesk';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('fonts/space-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;
}

:root {
  --miel: #FFD23F;
  --miel-fuerte: #E8B70D;
  --magenta: #F35BD3;
  --tinta: #241329;
  --focu: #6B3E00;
  --miel-testu: #8A5A00;

  /* Modo claro: papel de cera cálido */
  --fondu: #FBF4E1;
  --superficie: #FFFCF2;
  --testu: #2A1B30;
  --testu-nidiu: #6E5F4C;
  --borde: #9A8766;
  --celda: #F3E7C6;
  --sombra: #2A1B30;

  /* Semántica del xuegu */
  --correcta: #357A38;
  --presente: #FFD23F;
  --ausente: #6F6475;
  --testu-correcta: #FFFFFF;
  --testu-presente: #241329;
  --testu-ausente: #FFFFFF;
}

html[data-theme="dark"] {
  --fondu: #1C0F21;
  --superficie: #241329;
  --testu: #FBF3FA;
  --testu-nidiu: #B6A4BA;
  --borde: #826E88;
  --celda: #2E1B34;
  --sombra: #FFD23F;
  --focu: #FFD23F;
  --miel-testu: #FFD23F;

  --correcta: #357A38;
  --presente: #D9AE18;
  --ausente: #43324A;
  --testu-presente: #1C0F21;
  --testu-ausente: #CBBBD1;
}

/* Modo daltónico: naranja = correcta, azul = presente */
html.colorblind, html[data-theme="dark"].colorblind {
  --correcta: #F5793A;
  --presente: #85C0F9;
  --testu-correcta: #241329;
  --testu-presente: #10222E;
}

* { box-sizing: border-box; }

html { height: 100%; }

body {
  margin: 0;
  height: 100%;
  min-height: 100%;
  background: var(--fondu);
  color: var(--testu);
  font-family: 'Space Grotesk', system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.45;
  transition: background-color .25s, color .25s;
  overscroll-behavior: none;
  overflow-x: hidden;
}

.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  margin: -1px; padding: 0; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

:focus-visible {
  outline: 3px solid var(--focu);
  outline-offset: 2px;
  border-radius: 4px;
}

/* ---------- Estructura a pantalla completa ---------- */

.aplicacion {
  height: 100%;
  height: 100dvh;
  min-height: 520px;
  max-width: 540px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  padding: 0 8px env(safe-area-inset-bottom);
}

/* ---------- Cabecera ---------- */

.cabecera {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 8px 6px;
  flex: 0 0 auto;
}

.marca-playpresta {
  flex: 1 1 0;
  display: flex;
  justify-content: flex-start;
  min-width: 0;
}

.pp-mini {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: 'Archivo Black', 'Space Grotesk', system-ui, sans-serif;
  font-size: 18px;
  line-height: 1;
  color: var(--tinta);
  background: var(--miel);
  border: 2px solid var(--testu);
  border-radius: 10px;
  padding: 6px 8px;
  box-shadow: 2px 2px 0 var(--sombra);
  transition: transform .08s, box-shadow .08s;
}
.marca-playpresta:hover .pp-mini { transform: translateY(-1px); }
.marca-playpresta:active .pp-mini { transform: translate(2px, 2px); box-shadow: 0 0 0 transparent; }

.marca-wordle {
  flex: 0 0 auto;
  color: var(--testu);
  line-height: 1;
  text-decoration: none;
}

.nombre-wordle {
  font-family: 'Archivo Black', 'Space Grotesk', system-ui, sans-serif;
  font-size: clamp(24px, 6vw, 32px);
  letter-spacing: -.045em;
  margin: 0;
}
.nombre-wordle .ast { color: var(--miel-testu); }

.acciones { flex: 1 1 0; display: flex; gap: 6px; justify-content: flex-end; }

/* ---------- Botones ---------- */

button {
  font-family: inherit;
  font-size: 16px;
  font-weight: 500;
  color: var(--testu);
  background: var(--superficie);
  border: 2px solid var(--testu);
  border-radius: 10px;
  padding: 9px 18px;
  cursor: pointer;
  box-shadow: 2px 2px 0 var(--sombra);
  transition: transform .08s, box-shadow .08s, background-color .15s;
}
button:hover { background: var(--celda); }
button:active { transform: translate(2px, 2px); box-shadow: 0 0 0 var(--sombra); }

button.principal {
  background: var(--miel);
  color: var(--tinta);
  border-color: var(--tinta);
  font-weight: 700;
}
button.principal:hover { background: var(--miel-fuerte); }
html[data-theme="dark"] button.principal { box-shadow: 2px 2px 0 var(--magenta); }
html[data-theme="dark"] button.principal:active { box-shadow: 0 0 0 transparent; }

button.icono {
  padding: 8px 10px;
  display: inline-flex;
  align-items: center;
}

/* ---------- Zona de xuegu ---------- */

.xuegu {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  position: relative;
}

.tableru-zona {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 4px 0;
}

.tableru {
  display: grid;
  grid-template-rows: repeat(6, 1fr);
  gap: 6px;
  width: min(88vw, 340px, 62vh);
}

.fila {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
}

.caxella {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Archivo Black', 'Space Grotesk', sans-serif;
  font-size: clamp(22px, 7vw, 32px);
  text-transform: lowercase;
  color: var(--testu);
  background: var(--superficie);
  border: 2px solid var(--borde);
  border-radius: 10px;
  user-select: none;
  transition: transform .1s, background-color .15s, border-color .15s;
}

.caxella[data-fill] {
  border-color: var(--testu);
  animation: pum .1s ease-in-out;
}
@keyframes pum { 50% { transform: scale(1.08); } }

.caxella.volteando { animation: voltiar .5s ease forwards; }
@keyframes voltiar {
  0% { transform: rotateX(0); }
  50% { transform: rotateX(90deg); }
  100% { transform: rotateX(0); }
}

.caxella[data-state="correct"] {
  background: var(--correcta);
  border-color: var(--correcta);
  color: var(--testu-correcta);
}
.caxella[data-state="present"] {
  background: var(--presente);
  border-color: var(--presente);
  color: var(--testu-presente);
}
.caxella[data-state="absent"] {
  background: var(--ausente);
  border-color: var(--ausente);
  color: var(--testu-ausente);
}

.fila.tremar { animation: tremar .5s; }
@keyframes tremar {
  10%, 90% { transform: translateX(-1px); }
  20%, 80% { transform: translateX(2px); }
  30%, 50%, 70% { transform: translateX(-4px); }
  40%, 60% { transform: translateX(4px); }
}

.fila.brincar .caxella { animation: brincar .8s ease; }
.fila.brincar .caxella:nth-child(2) { animation-delay: .1s; }
.fila.brincar .caxella:nth-child(3) { animation-delay: .2s; }
.fila.brincar .caxella:nth-child(4) { animation-delay: .3s; }
.fila.brincar .caxella:nth-child(5) { animation-delay: .4s; }
@keyframes brincar {
  0%, 100% { transform: translateY(0); }
  30% { transform: translateY(-14px); }
  55% { transform: translateY(3px); }
  70% { transform: translateY(-6px); }
}

/* ---------- Toasts ---------- */

.toaster {
  position: absolute;
  top: 6px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 40;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  pointer-events: none;
  width: max-content;
  max-width: 92%;
}

.toast {
  background: var(--tinta);
  color: #FBF3FA;
  border: 2px solid var(--tinta);
  border-radius: 10px;
  box-shadow: 3px 3px 0 var(--sombra);
  padding: 8px 16px;
  font-weight: 700;
  font-size: 15px;
  text-align: center;
  opacity: 1;
  transition: opacity .3s;
}
html[data-theme="dark"] .toast {
  background: var(--miel);
  color: var(--tinta);
  border-color: var(--tinta);
  box-shadow: 3px 3px 0 var(--magenta);
}
.toast.celebrar {
  background: var(--magenta);
  color: var(--tinta);
  box-shadow: 3px 3px 0 var(--sombra);
}
.toast.sumir { opacity: 0; }

/* ---------- Teclau ---------- */

.teclau {
  flex: 0 0 auto;
  padding: 6px 0 10px;
  user-select: none;
}

.teclau-fila {
  display: flex;
  justify-content: center;
  gap: 5px;
  margin-bottom: 6px;
  touch-action: manipulation;
}

.tecla {
  flex: 1 1 0;
  max-width: 44px;
  min-width: 0;
  height: 52px;
  padding: 0;
  font-family: 'Space Grotesk', system-ui, sans-serif;
  font-size: 15px;
  font-weight: 700;
  text-transform: lowercase;
  color: var(--testu);
  background: var(--celda);
  border: 2px solid var(--testu);
  border-radius: 8px;
  box-shadow: 2px 2px 0 var(--sombra);
  display: flex;
  align-items: center;
  justify-content: center;
}
.tecla:hover { background: var(--superficie); }
.tecla:active { transform: translate(2px, 2px); box-shadow: 0 0 0 var(--sombra); }

.tecla.ancha {
  flex: 1.6 1 0;
  max-width: 72px;
  font-size: 12px;
  letter-spacing: .3px;
  text-transform: uppercase;
}

.tecla[data-state="correct"] { background: var(--correcta); border-color: var(--correcta); color: var(--testu-correcta); }
.tecla[data-state="present"] { background: var(--presente); border-color: var(--presente); color: var(--testu-presente); }
.tecla[data-state="absent"] { background: var(--ausente); border-color: var(--ausente); color: var(--testu-ausente); box-shadow: none; }

.espaciador { flex: .5 1 0; }

/* ---------- Modales ---------- */

.modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  background: rgba(20, 8, 25, .55);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 16px 12px;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}
.modal[hidden] { display: none; }

.modal-caxa {
  position: relative;
  background: var(--superficie);
  color: var(--testu);
  border: 2px solid var(--testu);
  border-radius: 16px;
  box-shadow: 6px 6px 0 var(--sombra);
  max-width: 520px;
  max-height: calc(100vh - 32px);
  max-height: calc(100dvh - 32px);
  width: 100%;
  padding: 22px 24px;
  text-align: left;
  overflow-y: auto;
  overscroll-behavior: contain;
  touch-action: pan-y;
  -webkit-overflow-scrolling: touch;
}

.modal-caxa h2 {
  font-family: 'Archivo Black', sans-serif;
  font-weight: 400;
  font-size: 20px;
  margin: 14px 0 8px;
}
.modal-caxa h2:first-of-type { margin-top: 4px; }
.modal-caxa h3 {
  font-size: 15px;
  font-weight: 700;
  margin: 16px 0 8px;
}

.modal-conteniu { padding-left: 20px; margin: 0; }
.modal-conteniu li { margin-bottom: 6px; }
.creitos { padding-left: 0; font-size: 15px; }
.creitos p { margin: 4px 0; }

.modal-zarrar {
  position: absolute;
  top: 10px; right: 10px;
  padding: 2px 11px;
  font-size: 20px;
}

.modal-pie { text-align: center; margin-top: 18px; }

/* ---------- Avisu d'instalación PWA ---------- */

.install-prompt {
  position: fixed;
  left: 50%;
  bottom: max(14px, env(safe-area-inset-bottom));
  z-index: 45;
  display: flex;
  align-items: flex-start;
  gap: 14px;
  width: min(480px, calc(100vw - 24px));
  padding: 16px 42px 16px 16px;
  color: var(--testu);
  background: var(--superficie);
  border: 2px solid var(--testu);
  border-radius: 16px;
  box-shadow: 6px 6px 0 var(--magenta);
}
.install-prompt[hidden] { display: none; }
.install-iconu {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  color: var(--tinta);
  background: var(--miel);
  border: 2px solid var(--tinta);
  border-radius: 11px;
  box-shadow: 3px 3px 0 var(--magenta);
  font-family: 'Archivo Black', sans-serif;
  font-size: 28px;
  line-height: 1;
}
.install-conteniu { flex: 1 1 auto; min-width: 0; }
.install-titulu { margin: 0; font-weight: 700; line-height: 1.25; }
.install-testu { margin: 3px 0 12px; color: var(--testu-nidiu); font-size: 15px; }
.install-acciones { display: flex; gap: 10px; }
.install-acciones button { min-height: 46px; padding: 8px 14px; }
.install-zarrar {
  position: absolute;
  top: 8px;
  right: 8px;
  min-width: 34px;
  min-height: 34px;
  padding: 0;
  font-size: 20px;
  line-height: 1;
  box-shadow: none;
}

/* Exemplos de la ayuda */
.exemplu p { margin: 6px 0 14px; font-size: 15px; }
.exemplu-fila { display: flex; gap: 5px; }
.exemplu-caxella {
  width: 40px; height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: 'Archivo Black', sans-serif;
  font-size: 20px;
  border: 2px solid var(--borde);
  border-radius: 8px;
  background: var(--superficie);
}
.exemplu-caxella.correcta { background: var(--correcta); border-color: var(--correcta); color: var(--testu-correcta); }
.exemplu-caxella.presente { background: var(--presente); border-color: var(--presente); color: var(--testu-presente); }
.exemplu-caxella.ausente { background: var(--ausente); border-color: var(--ausente); color: var(--testu-ausente); }

.nota-diaria {
  text-align: center;
  background: var(--celda);
  border-radius: 12px;
  padding: 10px 14px;
  font-weight: 700;
}

/* ---------- Estadístiques ---------- */

.numberu { color: var(--testu-nidiu); font-family: 'Space Grotesk', sans-serif; font-size: 15px; }

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  text-align: center;
  margin: 12px 0 4px;
}
.stats-conteniu { min-width: 0; }
.stats-resume { min-width: 0; }
.stat-num {
  font-family: 'Archivo Black', sans-serif;
  font-size: 28px;
  margin: 0;
}
.stat-label { font-size: 12px; color: var(--testu-nidiu); margin: 2px 0 0; }

.stats-sub { margin-top: 18px; }

.distribucion { display: flex; flex-direction: column; gap: 5px; }
.dist-fila { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.dist-guess { width: 14px; font-weight: 700; text-align: right; }
.dist-barra-zona { flex: 1; }
.dist-barra {
  min-width: 22px;
  background: var(--ausente);
  color: var(--testu-ausente);
  border-radius: 6px;
  padding: 2px 8px;
  font-weight: 700;
  text-align: right;
  width: 0%;
}
.dist-barra.destacada { background: var(--correcta); color: var(--testu-correcta); }

.pallabra-card {
  margin-top: 20px;
  padding: 16px 18px;
  background: var(--celda);
  border: 2px solid var(--testu);
  border-radius: 14px;
  box-shadow: 4px 4px 0 var(--miel);
}
.pallabra-card[hidden] { display: none; }
.pallabra-etiqueta {
  margin: 0 0 3px;
  color: var(--testu-nidiu);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.pallabra-cabecera {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.modal-caxa .pallabra-nome {
  margin: 0;
  font-family: 'Archivo Black', sans-serif;
  font-size: clamp(24px, 8vw, 34px);
  font-weight: 400;
  letter-spacing: .03em;
  line-height: 1.15;
  text-transform: uppercase;
}
.pallabra-tipu {
  padding: 3px 8px;
  color: var(--tinta);
  background: var(--miel);
  border: 1px solid var(--tinta);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}
.pallabra-definicio { margin: 10px 0 0; overflow-wrap: anywhere; }
.pallabra-mas { margin-top: 10px; }
.pallabra-mas summary {
  width: fit-content;
  cursor: pointer;
  color: var(--miel-testu);
  font-weight: 700;
}
.pallabra-acepciones {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--borde);
  overflow-wrap: anywhere;
}
.pallabra-acepcion { margin: 0 0 12px; }
.pallabra-acepcion:last-child { margin-bottom: 0; }
.pallabra-acepcion-tipu {
  display: block;
  margin-bottom: 2px;
  color: var(--testu-nidiu);
  font-size: 12px;
}
.pallabra-avisu {
  margin: 12px 0 0;
  padding: 8px 10px;
  background: var(--superficie);
  border-left: 4px solid var(--miel);
  border-radius: 6px;
  font-size: 13px;
}
.pallabra-fonte {
  margin: 12px 0 0;
  color: var(--testu-nidiu);
  font-size: 12px;
}

.stats-pie {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 18px;
  padding-top: 14px;
  border-top: 2px solid var(--borde);
  flex-wrap: wrap;
}
.cuenta-titulu { margin: 0; font-size: 13px; color: var(--testu-nidiu); }
.cuenta-tiempu {
  margin: 0;
  font-family: 'Archivo Black', sans-serif;
  font-size: 26px;
  letter-spacing: 1px;
}
.stats-acciones { display: flex; gap: 10px; }

/* ---------- Opciones ---------- */

.opcion {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 13px 0;
  border-bottom: 2px solid var(--borde);
}
.opcion-titulu { margin: 0; font-weight: 700; }
.opcion-descripcion { margin: 2px 0 0; font-size: 13px; color: var(--testu-nidiu); }
.opcion-enllaces { margin: 0; }
.opcion-enllaces a { color: var(--testu); font-weight: 700; }

.interruptor {
  flex: 0 0 auto;
  width: 50px;
  height: 28px;
  padding: 2px;
  border-radius: 999px;
  background: var(--celda);
  display: inline-flex;
  align-items: center;
}
.interruptor .bola {
  width: 20px; height: 20px;
  border-radius: 50%;
  background: var(--testu-nidiu);
  transition: transform .15s, background-color .15s;
}
.interruptor[aria-checked="true"] { background: var(--miel); }
.interruptor[aria-checked="true"] .bola {
  transform: translateX(20px);
  background: var(--tinta);
}

.logos {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(10px, 4vw, 24px);
  padding: 18px 0 4px;
}
.logos a {
  flex: 0 1 130px;
  min-width: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.logos img { width: 100%; max-width: 130px; height: auto; }
html[data-theme="dark"] .logos a {
  min-height: 58px;
  padding: 8px 10px;
  background: #FFFCF2;
  border: 2px solid var(--miel);
  border-radius: 12px;
  box-shadow: 2px 2px 0 var(--magenta);
}

/* Enllaces xenerales */
a { color: inherit; }

/* ---------- Responsive y preferencies ---------- */

@media (max-height: 620px) {
  .tecla { height: 44px; }
  .cabecera { padding-top: 6px; }
}

@media (max-height: 519px) {
  body { overflow-y: auto; overscroll-behavior: auto; }
  .aplicacion { height: auto; }
}

@media (max-width: 380px) {
  .tecla { font-size: 14px; }
  .tecla.ancha { font-size: 11px; }
  .acciones { gap: 4px; }
  button.icono { padding: 7px 8px; }
  .install-prompt { gap: 10px; padding: 14px 40px 14px 12px; }
  .install-iconu { width: 42px; height: 42px; font-size: 24px; }
  .install-acciones { display: grid; grid-template-columns: 1fr; }
  .install-acciones button { width: 100%; }
}

@media (max-width: 599px) {
  .modal { padding: 12px; }
  .modal-caxa {
    max-height: calc(100vh - 24px);
    max-height: calc(100dvh - 24px);
    padding: 18px;
  }
}

@media (max-width: 599px) {
  .stats-pie { align-items: stretch; }
  .cuenta-atras { width: 100%; }
  .stats-acciones {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
    gap: 12px;
  }
  .stats-acciones button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 50px;
    padding-inline: 12px;
    line-height: 1.2;
  }
}

@media (max-width: 380px) {
  .stats-acciones { grid-template-columns: 1fr; }
}

@media (min-width: 600px) {
  .stats-grid { gap: 12px; }
}

@media (min-width: 700px) {
  #ayuda .modal-caxa,
  #estadistiques .modal-caxa {
    max-width: 860px;
  }

  .ayuda-columnas {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr);
    gap: 30px;
    align-items: start;
  }
  .ayuda-creitos {
    padding-left: 26px;
    border-left: 2px solid var(--borde);
  }
  .ayuda-creitos h2 { margin-top: 0; }

  .stats-conteniu.con-pallabra {
    display: grid;
    grid-template-columns: minmax(0, .82fr) minmax(0, 1.18fr);
    gap: 24px;
    align-items: start;
  }
  .stats-conteniu.con-pallabra .pallabra-card { margin-top: 0; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}

@media (forced-colors: active) {
  :focus-visible { outline: 3px solid Highlight; }
  .caxella[data-state="correct"] { border-style: double; }
  .caxella[data-state="present"] { border-style: dashed; }
  .caxella[data-state="absent"] { border-style: dotted; }
}
