/* Hexathlon — páginas sueltas (404, privacidad, cookies, aviso legal). Se carga después de site.css y reutiliza sus variables,
   fuentes, cabecera y pie. Texto largo y sencillo, sin animaciones. Los 8 idiomas conviven en la misma página: con JavaScript
   (clase .js, la pone js/lang.js) se muestra solo el del idioma activo (html[lang]); sin él, salen los 8. */

body.pagina { background: var(--ink) var(--hexgrid); min-height: 100vh; display: flex; flex-direction: column; }
.pagina .pg-main { flex: 1 0 auto; width: 100%; max-width: 880px; margin: 0 auto; padding: clamp(96px, 14vh, 130px) clamp(16px, 5vw, 32px) clamp(48px, 9vh, 90px); }
.pagina .pg-main:focus { outline: none; }
.pagina .footer { flex: none; }

/* un idioma cada vez */
.js .pg-l, .js .pg-lang { display: none; }
html[lang="es"] [data-l="es"], html[lang="en"] [data-l="en"], html[lang="fr"] [data-l="fr"], html[lang="pt-BR"] [data-l="pt-BR"],
html[lang="de"] [data-l="de"], html[lang="zh-CN"] [data-l="zh-CN"], html[lang="ja"] [data-l="ja"], html[lang="ko"] [data-l="ko"] { display: revert; }
html:not(.js) .pg-lang { padding-bottom: 28px; margin-bottom: 28px; border-bottom: 1px solid rgba(255, 255, 255, .12); }
html:not(.js) .pg-l { margin-right: .5em; }

.pg-home { margin-left: auto; font-family: var(--hud); text-transform: uppercase; letter-spacing: .14em; font-size: .8rem; text-decoration: none; color: var(--muted); padding: 6px 0; }
.pg-home:hover { color: var(--gold); }

/* fila de idiomas */
.pg-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 28px; }
.pg-chips a { padding: .35em .9em; border-radius: 999px; border: 1px solid rgba(255, 248, 238, .22); font-family: var(--hud); font-size: .82rem; letter-spacing: .08em;
  text-decoration: none; color: var(--muted); transition: color .2s, border-color .2s, background .2s; }
.pg-chips a:hover { color: var(--white); border-color: var(--gold); }
.pg-chips a[aria-current="true"] { color: var(--ink); background: var(--gold); border-color: var(--gold); }

.pg-title { margin: 0 0 12px; font-family: var(--display); font-weight: 400; font-size: clamp(1.6rem, .9rem + 3.6vw, 3.2rem); line-height: 1.12; text-wrap: balance; overflow-wrap: anywhere; min-width: 0; max-width: 100%; }
.pg-meta { margin: 0 0 26px; color: var(--muted); font-size: .95rem; }

/* texto legal */
.pg-texto h2 { margin: 34px 0 10px; font-family: var(--display); font-weight: 400; font-size: clamp(1.25rem, 2.5vw, 1.6rem); line-height: 1.15; color: var(--gold); text-wrap: balance; }
.pg-texto p, .pg-texto li { color: rgba(255, 248, 238, .88); line-height: 1.75; text-wrap: pretty; overflow-wrap: break-word; }
.pg-texto p { margin: 0 0 14px; }
.pg-texto ul { margin: 0 0 14px; padding-left: 1.3em; }
.pg-texto li { margin: 0 0 8px; }
.pg-texto li::marker { color: var(--gold); }
.pg-texto .pg-lang a, .pg-texto .pg-l a { color: var(--reflex); text-decoration-color: rgba(46, 230, 240, .4); text-underline-offset: 3px; overflow-wrap: anywhere; }
.pg-texto .pg-lang a:hover, .pg-texto .pg-l a:hover { color: var(--gold); text-decoration-color: currentColor; }
.pg-texto strong { color: var(--white); font-weight: 800; }
.pg-top { color: var(--reflex); display: inline-block; margin-top: 10px; font-family: var(--hud); text-transform: uppercase; letter-spacing: .14em; font-size: .8rem; }

/* marcadores de datos que faltan: muy visibles a propósito */
mark.hueco { padding: .05em .45em; border-radius: 6px; background: var(--gold); color: var(--ink); font-family: var(--hud); font-size: .9em; white-space: nowrap; }

/* datos de identificación (aviso legal) */
.pg-id { display: grid; grid-template-columns: minmax(0, max-content) minmax(0, 1fr); gap: 8px 22px; margin: 0 0 14px; padding: 18px 22px; border-radius: 16px;
  background: rgba(20, 16, 41, .82); border: 1px solid rgba(255, 255, 255, .09); }
.pg-id dt { font-family: var(--hud); text-transform: uppercase; letter-spacing: .12em; font-size: .8rem; color: var(--gold); padding-top: .25em; }
.pg-id dd { margin: 0; color: rgba(255, 248, 238, .92); overflow-wrap: anywhere; }
@media (max-width: 559px) { .pg-id { grid-template-columns: 1fr; gap: 0; } .pg-id dd { margin-bottom: 10px; } }

/* 404 */
.pg-404 .pg-main { display: grid; grid-template-columns: minmax(0, 1fr); justify-items: center; align-content: center; gap: 8px; text-align: center; max-width: 720px; }
.pg-404__hexi { position: relative; width: min(300px, 70vw); margin-top: 8px; }
.pg-404__hexi img { display: block; width: 100%; height: auto; }
.pg-404__bubble { position: absolute; top: -6px; right: -34px; margin: 0; padding: .55em 1em; border-radius: 18px; background: var(--white); color: var(--ink); font-family: var(--display);
  font-size: clamp(.9rem, 2.4vw, 1.1rem); line-height: 1.2; max-width: 11em; transform: rotate(4deg); }
.pg-404__bubble::after { content: ""; position: absolute; left: 22px; bottom: -9px; border: 10px solid transparent; border-top-color: var(--white); border-bottom: 0; }
.pg-404__box { margin-top: 10px; min-width: 0; max-width: 100%; }
.pg-404__txt { margin: 0 0 22px; color: var(--muted); font-size: 1.1rem; line-height: 1.6; text-wrap: balance; overflow-wrap: anywhere; }
@media (max-width: 520px) { .pg-404__bubble { right: -10px; } }

@media print {
  body.pagina { background: #fff; }
  .topbar, .skip, .footer, .pg-chips { display: none; }
  .pagina .pg-main { max-width: none; padding: 0; }
  .pagina .pg-main *, .pg-title { color: #000 !important; background: none !important; }
  .pg-texto .pg-lang a, .pg-texto .pg-l a { text-decoration: underline; }
}
