/* Portada «Sala de control». Sin JS o con movimiento reducido los canales se leen uno tras otro;
   la clase .viaje (la pone portada.js) activa el recorrido con zoom. */
:root {
  --bg: #05060F;
  --fg: #F6F3EE;
  --soft: #DEDBE5;
  --disp: 'Syne', system-ui, sans-serif;
  --body: 'Manrope', system-ui, sans-serif;
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box }
html { background: var(--bg) }
body {
  margin: 0;
  background: var(--bg) radial-gradient(120% 90% at 50% 20%, #2A1B6B, var(--bg) 70%) fixed;
  color: var(--fg);
  font-family: var(--body);
  overflow-x: clip;
}
body[data-canal="1"] { background-image: linear-gradient(#10201B, #10201B) }
body[data-canal="2"] { background-image: radial-gradient(120% 90% at 50% 80%, #0C6B42, var(--bg) 70%) }
body[data-canal="3"] { background-image: radial-gradient(120% 90% at 50% 50%, #7A2410, var(--bg) 70%) }

#fondo, #tiza { position: fixed; inset: 0; width: 100%; height: 100%; display: block }
#tiza { pointer-events: none }

.nav {
  position: fixed; z-index: 3; top: 0; left: 0; right: 0;
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 0 14px;
  padding: calc(8px + env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) 14px max(16px, env(safe-area-inset-left, 0px));
  background: linear-gradient(rgba(5, 6, 15, .85) 60%, rgba(5, 6, 15, 0));
  font-weight: 600;
  text-shadow: 0 0 10px rgba(5, 6, 15, .8);
}
.nav strong { font-family: var(--disp) }
.nav div { display: flex; gap: 18px }
.nav a { color: inherit; text-decoration: none; min-height: 44px; display: inline-flex; align-items: center }
.nav a:hover, .nav a[aria-current="location"] { text-decoration: underline; text-underline-offset: 7px; text-decoration-thickness: 2px }

.ch { position: relative }
.stick {
  position: relative; min-height: 100vh; min-height: 100svh;
  display: grid; place-items: center;
  padding: 88px max(16px, env(safe-area-inset-right, 0px)) 40px max(16px, env(safe-area-inset-left, 0px));
}
.viaje .ch { height: 260vh }
.viaje .ch:last-of-type { height: 170vh }
.viaje .stick { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden }

.card { position: relative; display: flex; flex-direction: column; align-items: center; gap: 18px; text-align: center; max-width: 100% }
.viaje .card { will-change: transform, opacity }
/* Velo tras el texto: las escenas tienen zonas muy claras */
.card::before {
  content: ""; position: absolute; inset: -25% -20%; z-index: -1;
  background: radial-gradient(closest-side, rgba(5, 6, 15, .8), rgba(5, 6, 15, 0));
}
.antetitulo, .card p.texto, .bajar { text-shadow: 0 0 12px rgba(5, 6, 15, .8) }
.antetitulo { margin: 0; font-weight: 600; letter-spacing: .04em }
.card h1, .card h2 {
  margin: 0; font: 800 clamp(44px, min(12.5vw, 24vh), 196px)/.94 var(--disp); letter-spacing: -.03em;
  text-wrap: balance; overflow-wrap: anywhere;
}
.card p.texto { margin: 0; font-size: clamp(17px, 2vw, 22px); color: var(--soft); max-width: 40ch; line-height: 1.45 }
.go {
  display: inline-flex; align-items: center; min-height: 50px; padding: 0 28px; border-radius: 999px;
  background: var(--fg); color: var(--bg); font-weight: 600; text-decoration: none;
  transition: transform .15s ease-out;
}
.go:active { transform: scale(.97) }
.bajar { color: var(--soft); font-size: 15px; animation: bajar 2.2s ease-in-out infinite }
@keyframes bajar { 50% { transform: translateY(5px) } }
:focus-visible { outline: 2px solid var(--fg); outline-offset: 3px }

.pie {
  position: relative; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 6px 18px;
  padding: 18px max(16px, env(safe-area-inset-right, 0px)) calc(18px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px));
  background: rgba(5, 6, 15, .78); color: var(--soft); font-size: 15px;
}
.pie a { color: inherit; min-height: 44px; display: inline-flex; align-items: center }

@media (prefers-reduced-motion: reduce) {
  .go { transition: none }
  .bajar { animation: none }
}
