/* WorldJump · hero «el scroll es la cámara» (scrub.js escribe --sp de 0 a 1). */
.scrub { --sp: 0; position: relative; height: 320svh; background: #05070b; }
.scrub__stage { position: sticky; top: 0; height: 100svh; overflow: hidden; isolation: isolate; }
.scrub__cv, .scrub__poster { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.scrub__cv { z-index: -3; }
.scrub__poster { z-index: -4; transition: opacity .6s ease; }
.scrub.is-ready .scrub__poster { opacity: 0; }
/* la cámara «empuja»: un leve zoom continuo y el velo se aclara al entrar en el parque */
.scrub__cv { transform: scale(calc(1.02 + var(--sp) * .06)); transform-origin: 50% 55%; }
.scrub__veil { position: absolute; inset: 0; z-index: -2; pointer-events: none;
  background: radial-gradient(120% 80% at 50% 110%, rgba(5, 7, 11, .85), transparent 60%), linear-gradient(180deg, rgba(5, 7, 11, .55) 0%, rgba(5, 7, 11, .1) 30%, rgba(5, 7, 11, .15) 60%, rgba(5, 7, 11, .8) 100%);
  opacity: calc(1 - var(--sp) * .25); }
.scrub__grain { position: absolute; inset: -50%; z-index: -1; pointer-events: none; opacity: .09; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); animation: grain 1.2s steps(6) infinite; }
@keyframes grain { 0% { transform: translate(0, 0); } 33% { transform: translate(-3%, 2%); } 66% { transform: translate(2%, -3%); } 100% { transform: translate(0, 0); } }
.scrub__layer { position: absolute; left: 0; right: 0; display: grid; justify-items: center; gap: var(--space-4); padding: 0 var(--gutter); text-align: center; pointer-events: none; will-change: transform, opacity; }
.scrub__layer a, .scrub__layer button { pointer-events: auto; }
/* 1 · «VIVE EL SALTO»: crece y se deshace mientras el dron se acerca (vuelas a través del título) */
.scrub__l1 { top: 50%; transform: translateY(-50%) scale(calc(1 + var(--sp) * 2.4)); opacity: clamp(0, calc(1 - (var(--sp) - .04) / .2), 1); }
.scrub__title { display: flex; flex-wrap: wrap; justify-content: center; column-gap: .22em; font: 700 clamp(64px, 13vw, 210px)/.86 var(--font-display); letter-spacing: -.035em; text-shadow: 0 10px 60px rgba(5, 7, 11, .55); }
.scrub__title span { display: inline-block; animation: scrub-in 1s cubic-bezier(.2, .8, .2, 1) both; animation-delay: calc(var(--i) * 120ms + 150ms); }
@keyframes scrub-in { from { opacity: 0; transform: translateY(40px) rotate(-3deg); filter: blur(8px); } }
.scrub__lead { max-width: 34ch; color: #e6e9f2; font-size: clamp(16px, 1.4vw, 19px); text-shadow: 0 2px 20px rgba(5, 7, 11, .9); animation: scrub-in 1s .55s both; }
/* 2 · ya dentro: la cifra */
.scrub__l2 { top: 50%; transform: translateY(calc(-50% + (1 - min(1, max(0, (var(--sp) - .3) / .1))) * 40px)); opacity: min(clamp(0, calc((var(--sp) - .3) / .08), 1), clamp(0, calc((.64 - var(--sp)) / .07), 1)); }
.scrub__big { font: 700 clamp(40px, 7vw, 112px)/.95 var(--font-display); letter-spacing: -.03em; text-shadow: 0 10px 50px rgba(5, 7, 11, .7); }
.scrub__big b { background: linear-gradient(90deg, var(--cyan), #a996ff); -webkit-background-clip: text; background-clip: text; color: transparent; }
.scrub__small { color: #e6e9f2; font: 600 clamp(15px, 1.4vw, 20px) var(--font-display); letter-spacing: .04em; text-shadow: 0 2px 20px rgba(5, 7, 11, .9); }
/* 3 · llamada final */
.scrub__l3 { bottom: clamp(72px, 12svh, 140px); transform: translateY(calc((1 - min(1, max(0, (var(--sp) - .7) / .12))) * 36px)); opacity: clamp(0, calc((var(--sp) - .7) / .1), 1); }
.scrub__q { font: 700 clamp(34px, 5.4vw, 84px)/.98 var(--font-display); letter-spacing: -.025em; text-shadow: 0 10px 50px rgba(5, 7, 11, .7); }
.scrub__l3 .hero__actions { justify-content: center; }
/* barra de avance + «Desliza para entrar» */
.scrub__hint { position: absolute; left: 50%; bottom: calc(18px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); display: grid; justify-items: center; gap: 8px; padding: 6px 12px; border: 0; background: none; color: #dfe3f0; font: 600 12.5px var(--font-display); letter-spacing: .1em; text-transform: uppercase; cursor: pointer; opacity: clamp(0, calc(1 - (var(--sp) - .6) / .15), 1); }
.scrub__bar { position: relative; width: 120px; height: 3px; overflow: hidden; border-radius: 3px; background: rgba(255, 255, 255, .22); }
.scrub__bar b { position: absolute; inset: 0; background: var(--cyan); transform-origin: left; transform: scaleX(var(--sp)); }
.scrub__hint span::after { content: " ↓"; display: inline-block; animation: nudge-down 1.4s ease-in-out infinite; }
@keyframes nudge-down { 50% { transform: translateY(4px); } }
@media (max-width: 760px) {
  .scrub { height: 280svh; }
  .scrub__title { font-size: clamp(56px, 19vw, 96px); }
  .scrub__l3 .hero__actions { display: grid; grid-template-columns: 1fr 1fr; width: 100%; max-width: 420px; gap: var(--space-2); }
  .scrub__l3 .wjs-btn { padding-inline: 12px; font-size: 16px; }
  .scrub__l3 { bottom: calc(86px + env(safe-area-inset-bottom, 0px)); }
}
/* ---- mapa real (realmap.js, Leaflet + CARTO oscuro) ---- */
.map__board--real { position: relative; }
.map__real { position: relative; height: clamp(420px, 62vh, 640px); overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius-lg); background: #0b0d14; isolation: isolate; }
.map__loading { position: absolute; inset: 0; display: grid; place-items: center; color: var(--muted); font: 600 14px var(--font-display); }
.map__real .leaflet-container, .map__real.leaflet-container { background: #0b0d14; font-family: var(--font-body); }
.map__real .leaflet-tile-pane { filter: invert(1) hue-rotate(195deg) brightness(.82) contrast(.92) saturate(.55); }
.map__real .leaflet-control-zoom a, .rm-all { width: 40px; height: 40px; line-height: 40px; border: 1px solid var(--line) !important; background: rgba(17, 19, 28, .92) !important; color: var(--ink) !important; font-size: 20px; }
.rm-all { width: auto; padding: 0 14px; border-radius: 999px; font: 600 13px var(--font-display); cursor: pointer; }
.rm-all:hover { border-color: var(--cyan) !important; }
.map__real .leaflet-control-attribution { background: rgba(7, 9, 13, .7); color: #8a90a6; font-size: 10.5px; }
.map__real .leaflet-control-attribution a { color: #b9c0d6; }
.rm-pin { position: relative; }
.rm-pin__dot { position: absolute; inset: 0; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 0 5px rgba(42, 196, 244, .22), 0 0 22px 6px rgba(42, 196, 244, .55); transition: transform .3s ease; }
.rm-pin__dot::after { content: ""; position: absolute; inset: -10px; border-radius: 50%; border: 2px solid rgba(42, 196, 244, .6); animation: rm-ping 2.2s ease-out infinite; }
@keyframes rm-ping { from { transform: scale(.5); opacity: 1; } to { transform: scale(1.8); opacity: 0; } }
.rm-pin__label { position: absolute; left: 24px; top: 50%; transform: translateY(-50%); padding: 3px 9px; border-radius: 999px; background: rgba(7, 9, 13, .82); color: #fff; font: 600 12.5px var(--font-display); white-space: nowrap; pointer-events: none; }
.rm-pin.is-active .rm-pin__dot { background: var(--spark); box-shadow: 0 0 0 6px rgba(255, 210, 63, .25), 0 0 26px 8px rgba(255, 210, 63, .6); transform: scale(1.25); }
.rm-popup .leaflet-popup-content-wrapper { border: 1px solid var(--line); border-radius: 16px; background: #11131c; color: var(--ink); box-shadow: 0 18px 48px rgba(0, 0, 0, .55); }
.rm-popup .leaflet-popup-tip { background: #11131c; }
.rm-popup .leaflet-popup-content { margin: 14px 16px; }
.rm-popup a.leaflet-popup-close-button { color: var(--muted); }
.rm-pop { display: grid; gap: 6px; min-width: 200px; }
.rm-pop strong { font: 700 17px var(--font-display); }
.rm-pop small { color: var(--muted); font-size: 13px; line-height: 1.4; }
.rm-pop__acts { display: flex; align-items: center; gap: 12px; margin-top: 6px; }
.rm-pop__btn { display: inline-flex; align-items: center; min-height: 36px; padding: 0 14px; border-radius: 999px; background: var(--violet); color: #fff !important; font: 600 13px var(--font-display); text-decoration: none; }
.rm-pop__link { color: var(--cyan) !important; font: 600 13px var(--font-display); }
@media (max-width: 760px) { .map__real { height: 62svh; } .rm-pin__label { font-size: 11.5px; } }

/* ---- hero 3D (hero3d.js): mientras carga Three.js o si no hay WebGL, un fondo dibujado con CSS ---- */
.h3 { height: 300svh; }
.h3__art { position: absolute; inset: 0; z-index: -4; overflow: hidden; background: radial-gradient(60% 45% at 50% 0%, rgba(123, 92, 255, .45), transparent 70%), radial-gradient(50% 40% at 50% 100%, rgba(255, 61, 154, .28), transparent 70%), #05060b; }
.h3__art::before { content: ""; position: absolute; left: -40%; right: -40%; bottom: -10%; height: 75%; transform: perspective(520px) rotateX(62deg); transform-origin: bottom;
  background: repeating-linear-gradient(90deg, rgba(42, 196, 244, .5) 0 2px, transparent 2px 90px), repeating-linear-gradient(0deg, rgba(255, 61, 154, .45) 0 2px, transparent 2px 90px);
  -webkit-mask-image: linear-gradient(0deg, #000 20%, transparent 90%); mask-image: linear-gradient(0deg, #000 20%, transparent 90%); }
.h3 .scrub__cv { opacity: 0; transition: opacity .8s ease; transform: none; }
.h3.is-ready .scrub__cv { opacity: 1; }
.h3 .scrub__veil { background: radial-gradient(120% 70% at 50% 110%, rgba(5, 6, 11, .8), transparent 60%), linear-gradient(180deg, rgba(5, 6, 11, .5) 0%, transparent 28%, transparent 62%, rgba(5, 6, 11, .75) 100%); opacity: 1; }
@media (max-width: 760px) { .h3 { height: 260svh; } }
.h3--static { height: auto; }
.h3--static .scrub__stage { position: relative; height: 100svh; }
.h3--static .scrub__l1 { top: 30%; transform: none; opacity: 1; }
.h3--static .scrub__l2, .h3--static .scrub__hint { display: none; }
.h3--static .scrub__l3 { transform: none; opacity: 1; }

/* sin animación: una imagen y todo el texto, como un hero normal */
.scrub--static { height: auto; }
.scrub--static .scrub__stage { position: relative; height: 100svh; }
.scrub--static .scrub__poster { opacity: 1; }
.scrub--static .scrub__l1 { top: 30%; transform: none; opacity: 1; }
.scrub--static .scrub__l2, .scrub--static .scrub__hint, .scrub--static .scrub__grain { display: none; }
.scrub--static .scrub__l3 { transform: none; opacity: 1; }
@media (prefers-reduced-motion: reduce) { .scrub__title span, .scrub__lead { animation: none; } }

.map__go[hidden] { display: none !important; }
/* marcadores muy cercanos: etiqueta al otro lado y grupo «2» */
.rm-pin--left .rm-pin__label { left: auto; right: 24px; }
.rm-pin--group .rm-pin__dot { display: grid; place-items: center; color: #07090d; font: 800 13px var(--font-display); }
.rm-pin--group .rm-pin__label { left: 34px; line-height: 1.35; border-radius: 12px; padding: 5px 10px; }
.rm-pin--group { cursor: zoom-in; }

/* ===== hero «todo WorldJump» (hero3d.js): las partículas cambian de forma con el scroll; cada capítulo, su texto ===== */
.h4 { height: 720svh; }
.h4__ch { --o: 0; position: absolute; z-index: 2; display: grid; gap: var(--space-3); pointer-events: none;
  opacity: var(--o); transform: translateY(calc((1 - var(--o)) * 26px)); will-change: opacity, transform; }
.h4__ch.is-on { pointer-events: auto; }
.h4__ch--intro { --o: 1; inset: 0; align-content: center; justify-items: center; padding: 0 var(--gutter); text-align: center; }
.h4__ch:not(.h4__ch--intro):not(.h4__ch--cta) { left: max(var(--gutter), (100vw - var(--maxw)) / 2); bottom: clamp(90px, 16svh, 170px); max-width: 520px; }
.h4__k { display: inline-flex; align-items: center; gap: 10px; color: var(--cyan); font: 700 13px var(--font-display); letter-spacing: .16em; text-transform: uppercase; }
.h4__k::before { content: ""; width: 28px; height: 2px; border-radius: 2px; background: currentColor; box-shadow: 0 0 12px currentColor; }
.h4__t { font: 700 clamp(36px, 5vw, 76px)/.98 var(--font-display); letter-spacing: -.03em; text-wrap: balance; text-shadow: 0 10px 50px rgba(5, 7, 11, .8); }
.h4__p { color: #dfe3f0; font-size: clamp(16px, 1.3vw, 19px); max-width: 38ch; text-shadow: 0 2px 18px rgba(5, 7, 11, .95); }
.h4__go { justify-self: start; display: inline-flex; align-items: center; gap: 10px; min-height: 48px; padding: 0 22px; border: 1px solid rgba(255, 255, 255, .28); border-radius: 999px;
  background: rgba(10, 12, 20, .45); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); color: #fff; font: 600 15px var(--font-display); text-decoration: none; transition: border-color .2s, background .2s, transform .15s; }
.h4__go:hover { border-color: var(--cyan); background: rgba(42, 196, 244, .14); }
.h4__go:active { transform: scale(.97); }
.h4__go span { transition: transform .2s; }
.h4__go:hover span { transform: translateX(4px); }
.h4__ch--cta { left: 0; right: 0; bottom: clamp(80px, 13svh, 150px); justify-items: center; padding: 0 var(--gutter); text-align: center; }
.h4__ch--cta .hero__actions { justify-content: center; }
/* puntos: en qué capítulo estás (y saltar a otro) */
.h4__dots { position: absolute; z-index: 3; right: clamp(10px, 2.2vw, 34px); top: 50%; transform: translateY(-50%); display: grid; gap: 2px; }
.h4__dots button { position: relative; display: grid; place-items: center; width: 32px; height: 32px; border: 0; background: none; cursor: pointer; }
.h4__dots button::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: rgba(255, 255, 255, .35); transition: transform .3s, background .3s, box-shadow .3s; }
.h4__dots button[aria-current="true"]::before { background: var(--cyan); transform: scale(1.5); box-shadow: 0 0 12px var(--cyan); }
.h4__dots span { position: absolute; right: 36px; padding: 3px 10px; border-radius: 999px; background: rgba(7, 9, 13, .8); color: #fff; font: 600 12px var(--font-display); white-space: nowrap; opacity: 0; transform: translateX(6px); transition: opacity .2s, transform .2s; pointer-events: none; }
.h4__dots button:hover span, .h4__dots button:focus-visible span { opacity: 1; transform: none; }
.h4 .scrub__hint { opacity: clamp(0, calc(1 - var(--sp) * 8), 1); }
@media (max-width: 760px) {
  .h4 { height: 620svh; }
  .h4__ch:not(.h4__ch--intro):not(.h4__ch--cta) { left: var(--gutter); right: 48px; bottom: calc(96px + env(safe-area-inset-bottom, 0px)); }
  .h4__t { font-size: clamp(32px, 9.5vw, 44px); }
  .h4__p { font-size: 15.5px; }
  .h4__ch--cta { bottom: calc(92px + env(safe-area-inset-bottom, 0px)); }
  .h4__ch--cta .hero__actions { display: grid; grid-template-columns: 1fr 1fr; width: 100%; max-width: 420px; gap: var(--space-2); }
  .h4__ch--cta .wjs-btn { padding-inline: 12px; font-size: 16px; }
  .h4__dots { right: 4px; }
  .h4__dots button { width: 28px; height: 28px; }
}
/* sin WebGL / reducir movimiento: todos los capítulos, uno debajo de otro */
.h4.h3--static { height: auto; }
.h4.h3--static .scrub__stage { position: relative; height: auto; min-height: 100svh; display: grid; gap: 48px; padding: 120px var(--gutter) 80px; }
.h4.h3--static .h4__ch { position: static; --o: 1; opacity: 1; transform: none; pointer-events: auto; max-width: 640px; }
.h4.h3--static .h4__ch--intro { min-height: 60svh; }
.h4.h3--static .h4__dots, .h4.h3--static .scrub__hint { display: none; }
/* fotos reales pequeñas en cada capítulo (tocar = verla grande) */
.h4__pics { display: flex; gap: 0; margin-bottom: 4px; }
.h4__ch--intro .h4__pics { justify-content: center; margin: 14px 0 0; }
.h4__pic { position: relative; width: 112px; aspect-ratio: 4 / 3; padding: 0; border: 3px solid rgba(255, 255, 255, .92); border-radius: 10px; overflow: hidden; background: #111; cursor: zoom-in;
  transform: rotate(var(--r)) translateY(calc((1 - var(--o, 1)) * 18px)); box-shadow: 0 12px 30px rgba(0, 0, 0, .55); transition: transform .35s cubic-bezier(.2, .8, .2, 1), box-shadow .3s; }
.h4__pic + .h4__pic { margin-left: -18px; }
.h4__pic img { width: 100%; height: 100%; object-fit: cover; display: block; }
.h4__pic::after { content: ""; position: absolute; right: 5px; bottom: 5px; width: 20px; height: 20px; border-radius: 50%; background: rgba(7, 9, 13, .7) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2.5' stroke-linecap='round'%3E%3Cpath d='M15 3h6v6M9 21H3v-6M21 3l-7 7M3 21l7-7'/%3E%3C/svg%3E") center / 11px no-repeat; }
.h4__pic:hover, .h4__pic:focus-visible { transform: rotate(0deg) scale(1.08) translateY(-4px); z-index: 2; box-shadow: 0 18px 40px rgba(0, 0, 0, .6), 0 0 0 2px var(--cyan); }
.h4__pic:active { transform: scale(.96); }
@media (max-width: 760px) { .h4__pic { width: 84px; border-width: 2px; border-radius: 8px; } .h4__pic + .h4__pic { margin-left: -14px; } }
/* visor de fotos */
.lbx { width: min(1100px, 94vw); max-height: 92svh; padding: 0; border: 0; border-radius: 16px; background: #07090d; color: #fff; overflow: hidden; box-shadow: 0 30px 90px rgba(0, 0, 0, .7); }
.lbx::backdrop { background: rgba(3, 4, 8, .82); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.lbx[open] { animation: lbx-in .35s cubic-bezier(.2, .8, .2, 1); }
@keyframes lbx-in { from { opacity: 0; transform: scale(.92) translateY(14px); } }
.lbx img { display: block; width: 100%; max-height: calc(92svh - 56px); object-fit: contain; background: #000; }
.lbx__bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 56px; padding: 0 8px 0 18px; font: 600 15px var(--font-display); }
.lbx__x { width: 44px; height: 44px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .08); color: #fff; font-size: 22px; cursor: pointer; }
.lbx__x:hover { background: rgba(255, 255, 255, .16); }
/* ===== mapa de puntos (realmap.js) ===== */
.map__real { background: radial-gradient(70% 60% at 50% 45%, rgba(123, 92, 255, .12), transparent 70%), #07080f; }
.dm__cv { position: absolute; inset: 0; }
.dm__labels, .dm__pins { position: absolute; inset: 0; pointer-events: none; }
.dm__prov { position: absolute; left: 0; top: 0; color: rgba(255, 255, 255, .55); font: 700 11px var(--font-display); letter-spacing: .32em; text-transform: uppercase; white-space: nowrap; text-shadow: 0 2px 12px #07080f; transition: opacity .3s; }
.dm__pin { position: absolute; left: 0; top: 0; width: 0; height: 0; padding: 0; border: 0; background: none; color: #fff; cursor: pointer; pointer-events: auto; }
.dm__pin i { position: absolute; left: -8px; top: -8px; width: 16px; height: 16px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 0 4px rgba(42, 196, 244, .25), 0 0 18px 4px rgba(42, 196, 244, .6); font-style: normal; transition: transform .25s, background .25s; }
.dm__pin i::after { content: ""; position: absolute; inset: -9px; border-radius: 50%; border: 2px solid rgba(42, 196, 244, .7); animation: rm-ping 2.4s ease-out infinite; }
.dm__pin span { position: absolute; left: 16px; top: 0; transform: translateY(-50%); padding: 4px 10px; border: 1px solid rgba(255, 255, 255, .14); border-radius: 999px; background: rgba(9, 11, 18, .78); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); font: 600 12.5px/1.3 var(--font-display); white-space: nowrap; transition: border-color .2s, background .2s; }
.dm__pin--left span { left: auto; right: 16px; }
.dm__pin:hover i, .dm__pin:focus-visible i { transform: scale(1.25); }
.dm__pin:hover span, .dm__pin:focus-visible span { border-color: var(--cyan); }
.dm__pin.is-active i { background: var(--spark); box-shadow: 0 0 0 5px rgba(255, 210, 63, .25), 0 0 22px 6px rgba(255, 210, 63, .6); transform: scale(1.3); }
.dm__pin.is-active i::after { border-color: rgba(255, 210, 63, .7); }
.dm__pin--group i { left: -13px; top: -13px; width: 26px; height: 26px; display: grid; place-items: center; color: #07090d; font: 800 13px var(--font-display); }
.dm__pin--group span { left: 22px; border-radius: 12px; padding: 5px 10px; }
.dm__pin--group { cursor: zoom-in; }
.dm__card { position: absolute; left: 16px; bottom: 16px; z-index: 3; width: min(330px, calc(100% - 32px)); display: grid; gap: 4px; padding: 16px 18px; border: 1px solid rgba(255, 255, 255, .14); border-radius: 18px; background: rgba(10, 12, 20, .82); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); box-shadow: 0 20px 50px rgba(0, 0, 0, .5); }
.dm__card.is-in { animation: dm-in .4s cubic-bezier(.2, .8, .2, 1); }
@keyframes dm-in { from { opacity: 0; transform: translateY(14px) scale(.97); } }
.dm__k { color: var(--cyan); font: 700 11.5px var(--font-display); letter-spacing: .14em; text-transform: uppercase; }
.dm__card strong { font: 700 22px var(--font-display); }
.dm__card small { color: #c3c8d8; font-size: 14px; }
.dm__acts { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-top: 10px; }
.dm__btn { display: inline-flex; align-items: center; min-height: 44px; padding: 0 18px; border-radius: 999px; background: var(--violet, #6d4eec); color: #fff; font: 600 14.5px var(--font-display); text-decoration: none; }
.dm__btn:active { transform: scale(.97); }
.dm__link { color: #fff; font: 600 14.5px var(--font-display); text-underline-offset: 4px; }
.dm__x { position: absolute; right: 8px; top: 8px; width: 36px; height: 36px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .08); color: #fff; font-size: 20px; cursor: pointer; }
.dm__all { position: absolute; right: 14px; top: 14px; z-index: 3; min-height: 40px; padding: 0 16px; border: 1px solid rgba(255, 255, 255, .2); border-radius: 999px; background: rgba(10, 12, 20, .8); color: #fff; font: 600 13px var(--font-display); cursor: pointer; }
.dm__all:hover { border-color: var(--cyan); }
@media (max-width: 760px) { .map__real { height: 64svh; } .dm__prov { font-size: 9.5px; letter-spacing: .24em; } .dm__pin span { font-size: 11.5px; padding: 3px 8px; } }
.dm__card[hidden], .dm__all[hidden] { display: none; }
.dm__pin--group.dm__pin--left span { left: auto; right: 22px; text-align: right; }

/* iPhone (Safari): el escenario fijo ocupa la pantalla GRANDE (también debajo de la barra de Safari cuando se encoge
   o flota), así no queda una franja abajo sin cubrir. --vbar = alto de la barra; los textos de abajo suben eso para
   que nunca queden tapados. */
.scrub { --vbar: 0px; }
.scrub__stage { height: 100vh; }
@supports (height: 100lvh) {
  .scrub { --vbar: calc(100lvh - 100svh); }
  .scrub__stage { height: 100lvh; }
}
.scrub__hint { bottom: calc(18px + var(--vbar) + env(safe-area-inset-bottom, 0px)); }
.scrub__l3 { bottom: calc(clamp(72px, 12svh, 140px) + var(--vbar)); }
.h4__ch--intro { padding-bottom: var(--vbar); }
.h4__ch:not(.h4__ch--intro):not(.h4__ch--cta) { bottom: calc(clamp(90px, 16svh, 170px) + var(--vbar)); }
.h4__ch--cta { bottom: calc(clamp(80px, 13svh, 150px) + var(--vbar)); }
.h4__dots { top: calc(50% - var(--vbar) / 2); }
@media (max-width: 760px) {
  .scrub__l3 { bottom: calc(86px + var(--vbar) + env(safe-area-inset-bottom, 0px)); }
  .h4__ch:not(.h4__ch--intro):not(.h4__ch--cta) { bottom: calc(96px + var(--vbar) + env(safe-area-inset-bottom, 0px)); }
  .h4__ch--cta { bottom: calc(92px + var(--vbar) + env(safe-area-inset-bottom, 0px)); }
}
.h3--static .scrub__stage, .scrub--static .scrub__stage { height: 100svh; }
.h4.h3--static .scrub__stage { height: auto; }
.h4.h3--static .h4__ch { padding-bottom: 0; }

/* iPhone (Safari 26) tiñe la barra de abajo con el color de cualquier barra fija pegada al borde inferior, aunque esté
   escondida con transform. La barra de reservar escondida pasa a invisible (sin fondo) → Safari deja ver el escenario. */
.bookbar { transition: transform .35s var(--ease-out), visibility 0s linear .35s; }
.bookbar:not(.is-visible) { visibility: hidden; }
.bookbar.is-visible { visibility: visible; transition: transform .35s var(--ease-out), visibility 0s; }
/* sobre el hero, la cabecera es transparente: las partículas llegan hasta arriba del todo (y Safari no pinta franja) */
html.on-hero .site-header.is-scrolled:not(.is-open) { background: transparent; border-bottom-color: transparent; -webkit-backdrop-filter: none; backdrop-filter: none; }
html.on-hero .site-header.is-scrolled:not(.is-open)::before { opacity: 1; }

/* ===== fluidez del hero (2026-11-16) =====
   · más corto: la escena cambia por disparo (hero3d.js), no hace falta tanto recorrido
   · nada de desenfoques ni mezclas encima del lienzo animado (en iPhone se recalculan en cada fotograma) */
.h4 { height: 560svh; }
@media (max-width: 760px) { .h4 { height: 450svh; } }
.h4 .scrub__grain { display: none; }
.h4 .h4__go { -webkit-backdrop-filter: none; backdrop-filter: none; background: rgba(10, 12, 20, .72); }
.h4 .wjs-badge { -webkit-backdrop-filter: none; backdrop-filter: none; }
/* saltarse la intro: directo a los parques */
.h4__skip { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; margin-top: 6px; padding: 0 18px; border: 1px solid rgba(255, 255, 255, .22); border-radius: 999px;
  background: rgba(10, 12, 20, .6); color: #e6e9f2; font: 600 14px var(--font-display); text-decoration: none; animation: scrub-in 1s .8s both; transition: border-color .2s, background .2s, transform .15s; }
.h4__skip:hover { border-color: var(--cyan); background: rgba(42, 196, 244, .14); }
.h4__skip:active { transform: scale(.97); }
.h4__skip span { display: inline-block; transition: transform .2s; }
.h4__skip:hover span { transform: translateY(3px); }
.h4.h3--static .h4__skip { display: none; }
@media (prefers-reduced-motion: reduce) { .h4__skip { animation: none; } }
/* títulos largos («Más de 30.000 familias…»): un poco más anchos y algo más pequeños en escritorio, que quepan en 3 líneas */
@media (min-width: 761px) {
  .h4__ch:not(.h4__ch--intro):not(.h4__ch--cta) { max-width: 620px; }
  .h4__t { font-size: clamp(34px, 4.3vw, 64px); }
}

/* imán nativo del hero (hero3d.js crea los .h4__snap): una escena por gesto, como mucho */
html.snap-hero { scroll-snap-type: y mandatory; }
.h4__snap { position: absolute; left: 0; width: 1px; height: 1px; pointer-events: none; scroll-snap-align: start; scroll-snap-stop: always; }
.h4.h3--static .h4__snap { display: none; }

/* ===== escritorio como antes (2026-11-16): las optimizaciones del móvil no se aplican aquí ===== */
@media (min-width: 761px) and (pointer: fine) {
  .h4 { height: 680svh; }
  .h4 .scrub__grain { display: block; }
  .h4 .h4__go { background: rgba(10, 12, 20, .45); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
}

/* ---------- hero con las 6 escenas 3D (iframes, hero-scenes.js) ---------- */
.h5__stage { position: absolute; inset: 0; z-index: -3; overflow: hidden; pointer-events: none; }
.h5__s { position: absolute; inset: 0; opacity: 0; visibility: hidden; transform-origin: 50% 55%; will-change: opacity, transform; }
.h5__s.is-first { opacity: 1; visibility: visible; }
.h5__p, .h5__p img { position: absolute; inset: 0; width: 100%; height: 100%; display: block; object-fit: cover; }
.h5__f { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; pointer-events: none; background: transparent; opacity: 0; transition: opacity .6s ease; }
.h5__f.is-ready { opacity: 1; }
/* sin el fondo morado de la versión anterior: mientras carga se ve la imagen de espera */
.h4 .h3__art { background: #05060b; }
.h4 .h3__art::before, .h4 .h3__art::after { display: none; }
.h4.h3--static .h5__stage { display: none; }
/* portada (capítulo 0): oscurecer el centro para que el título y el texto se lean sobre la escena; desaparece al bajar */
.h5__stage::after { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: max(0, calc(1 - var(--sp, 0) * 8));
  background: radial-gradient(60% 55% at 50% 52%, rgba(5, 6, 11, .62), rgba(5, 6, 11, .25) 60%, transparent 85%); }
/* visor de fotos como álbum (flechas, deslizar, contador) */
.lbx__ph { position: relative; touch-action: pan-y; background: #000; }
.lbx img { transition: opacity .22s ease, transform .3s cubic-bezier(.2, .8, .2, 1); opacity: 0; transform: translateX(var(--dx, 0)); user-select: none; -webkit-user-drag: none; }
.lbx img.is-in { opacity: 1; transform: none; }
.lbx__nav { position: absolute; top: 50%; width: 48px; height: 48px; margin-top: -24px; border: 1px solid rgba(255, 255, 255, .18); border-radius: 50%; background: rgba(10, 12, 20, .55);
  color: #fff; font: 400 30px/1 system-ui, sans-serif; cursor: pointer; display: none; place-items: center; -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); transition: background .2s, transform .15s; }
.lbx.is-multi .lbx__nav { display: grid; }
.lbx__nav--p { left: 12px; } .lbx__nav--n { right: 12px; }
.lbx__nav:hover { background: rgba(10, 12, 20, .8); } .lbx__nav:active { transform: scale(.94); }
.lbx__cap { flex: 1; min-width: 0; }
.lbx__num { color: var(--muted, #9aa3b5); font-size: 14px; font-variant-numeric: tabular-nums; }
@media (max-width: 760px) { .lbx__nav { width: 40px; height: 40px; margin-top: -20px; font-size: 26px; } }
@media (prefers-reduced-motion: reduce) { .lbx img { transition: none; } }
/* hero en modo «ligero» (móviles flojos): solo las imágenes, con un acercamiento lento para que no parezca parado */
.h5__stage.is-lite .h5__p img { animation: h5-kb 16s ease-in-out infinite alternate; transform-origin: 60% 45%; }
@keyframes h5-kb { from { transform: scale(1.02) translate3d(0, 0, 0); } to { transform: scale(1.09) translate3d(-1.5%, -1%, 0); } }
@media (prefers-reduced-motion: reduce) { .h5__stage.is-lite .h5__p img { animation: none; } }
/* ===== versión vídeo: cumpleaños con la escena 3D en su sección ===== */
.bday { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(24px, 4vw, 56px); align-items: center; padding-block: clamp(56px, 9vw, 120px); }
.bday__t { margin: 8px 0 12px; font: 800 clamp(30px, 4vw, 48px)/1.08 var(--font-display); letter-spacing: -.01em; text-wrap: balance; }
.bday__p { margin: 0 0 24px; max-width: 34ch; color: var(--muted); font-size: 18px; line-height: 1.55; }
.bday__acts { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.bday__pic { width: 96px; aspect-ratio: 4 / 3; padding: 0; border: 2px solid rgba(255, 255, 255, .85); border-radius: 10px; overflow: hidden; background: none; cursor: zoom-in; transform: rotate(-4deg); box-shadow: 0 10px 24px rgba(0, 0, 0, .4); transition: transform .2s ease; }
.bday__pic:hover { transform: rotate(0) scale(1.04); }
.bday__pic img { display: block; width: 100%; height: 100%; object-fit: cover; }
.bday3d { position: relative; aspect-ratio: 4 / 3; overflow: hidden; isolation: isolate; border: 1px solid rgba(255, 255, 255, .08); border-radius: 24px; background: #0b0c1d; box-shadow: 0 30px 80px rgba(0, 0, 0, .45); cursor: pointer; touch-action: manipulation; }
.bday3d.is-still { cursor: default; }
.bday3d__poster, .bday3d__f { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; }
.bday3d__poster { object-fit: cover; object-position: 50% 30%; }
.bday3d__f { opacity: 0; pointer-events: none; transition: opacity .6s ease; }
.bday3d__f.is-ready { opacity: 1; }
.bday3d__hint { position: absolute; left: 50%; bottom: 16px; margin: 0; padding: 8px 14px; transform: translateX(-50%); border: 1px solid rgba(255, 255, 255, .14); border-radius: 999px; background: rgba(10, 12, 20, .7); color: #fff; font: 600 14px var(--font-display); white-space: nowrap; pointer-events: none; opacity: 0; transition: opacity .4s ease; -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.bday3d.is-live .bday3d__hint { opacity: 1; }
.bday3d.is-touched .bday3d__hint { opacity: 0; }
@media (max-width: 760px) { .bday { grid-template-columns: 1fr; } .bday3d { border-radius: 18px; } .bday__p { font-size: 16px; } }
