/* =========================================================
   Capa cinemática: portada con video, escena de «Tu visita»
   fijada al scroll. Se activa con body.cine
   (lo pone js/cine.js) y respeta «reducir movimiento».
   ========================================================= */

/* ---------- Encabezado sobre el video ---------- */
/* El encabezado sigue «pegado» arriba; la portada sube debajo de él para que el video llene la pantalla */
body.cine .hero { margin-top: calc(-1 * var(--header-h)); }
body.cine.sobre-video .header:not(.scrolled) { background: transparent; backdrop-filter: none; -webkit-backdrop-filter: none; }
body.cine.sobre-video .header:not(.scrolled) .nav > a:not(.btn),
body.cine.sobre-video .header:not(.scrolled) .nav-social a { color: #fff; }
body.cine.sobre-video .header:not(.scrolled) .brand { background: #fff; border-radius: 14px; padding: 4px 10px; }
body.cine.sobre-video .header:not(.scrolled) .burger { background: rgba(255,255,255,.18); }
body.cine.sobre-video .header:not(.scrolled) .burger span { background: #fff; }

/* ---------- Portada ---------- */
.hero-video, .hero-cine-shade, .hero-grano, .bandas { display: none; }
body.cine .hero {
  min-height: 100svh; display: flex; align-items: center; color: #fff;
  padding: calc(var(--header-h) + 40px) 0 120px; background: #071f24; isolation: isolate;
}
body.cine .hero .blob, body.cine .hero .helix, body.cine .hero .molecules { display: none; }
body.cine .hero-video {
  display: block; position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -3;
  transform-origin: 50% 40%;
}
body.cine .hero-cine-shade {
  display: block; position: absolute; inset: 0; z-index: -2; pointer-events: none;
  background:
    radial-gradient(120% 90% at 30% 50%, rgba(7,31,36,.35) 0%, rgba(7,31,36,.82) 70%),
    linear-gradient(180deg, rgba(7,31,36,.55) 0%, rgba(7,31,36,0) 30%, rgba(7,31,36,.85) 100%);
}
/* Grano de película muy suave */
body.cine .hero-grano {
  display: block; position: absolute; inset: -50%; z-index: -1; pointer-events: none; opacity: .09;
  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: grano 1s steps(4) infinite;
}
@keyframes grano { 25% { transform: translate(-3%, 2%); } 50% { transform: translate(2%, -3%); } 75% { transform: translate(-2%, -1%); } }

/* Bandas negras de cine que se abren al cargar */
body.cine .bandas { display: block; position: absolute; inset: 0; z-index: 3; pointer-events: none; }
body.cine .bandas::before, body.cine .bandas::after {
  content: ""; position: absolute; left: 0; right: 0; height: 50.5%; background: #050f12;
  transition: transform 1.6s cubic-bezier(.77,0,.18,1) .2s;
}
body.cine .bandas::before { top: 0; } body.cine .bandas::after { bottom: 0; }
body.cine.loaded .bandas::before { transform: translateY(-100%); }
body.cine.loaded .bandas::after { transform: translateY(100%); }

body.cine .hero-grid { grid-template-columns: 1fr; }
body.cine .hero-copy { max-width: 880px; }
body.cine .hero .eyebrow { color: #ffb3c2; letter-spacing: .18em; }
body.cine .hero-title { color: #fff; font-size: clamp(2.6rem, 7vw, 5.6rem); line-height: 1.02; text-shadow: 0 6px 40px rgba(0,0,0,.35); }
body.cine .hero-title .hl { color: #7fe0ea; }
body.cine .hero-title .hl.rose { color: #ff8fa6; }
body.cine .hero-sub { color: rgba(255,255,255,.86); font-size: clamp(1.05rem, 1.7vw, 1.3rem); max-width: 620px; }
body.cine .hero-local, body.cine .hero-trust { color: #e6f7f9; }
body.cine .hero-trust .i { background: #ff5c7c; }
body.cine .hero .btn-ghost { background: rgba(255,255,255,.12); color: #fff; border-color: rgba(255,255,255,.45); }
body.cine .hero .btn-ghost:hover { background: rgba(255,255,255,.22); }

/* Las tarjetas flotantes pasan a una fila de «créditos» abajo a la derecha */
body.cine .hero-visual { position: absolute; right: clamp(16px, 4vw, 56px); bottom: 34px; display: flex; gap: 12px; z-index: 2; }
body.cine .hero-photo { display: none; }
body.cine .float-card {
  position: static; animation: none; background: rgba(7,31,36,.55); color: #fff;
  border: 1px solid rgba(255,255,255,.18); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
}
body.cine .float-card strong { color: #fff; }
body.cine .float-card small { color: rgba(255,255,255,.75); }
body.cine .scroll-cue { left: clamp(16px, 4vw, 56px); right: auto; transform: none; filter: invert(1) brightness(2); }

/* Botón para pausar el video (accesibilidad: contenido en movimiento) */
.video-pausa { display: none; }
body.cine .video-pausa {
  display: grid; place-items: center; position: absolute; left: clamp(16px, 4vw, 56px); bottom: 90px; z-index: 2;
  width: 40px; height: 40px; border-radius: 50%; border: 1px solid rgba(255,255,255,.4);
  background: rgba(7,31,36,.45); color: #fff; cursor: pointer; font-size: 14px;
}
body.cine .video-pausa:focus-visible { outline: 3px solid #7fe0ea; outline-offset: 3px; }

@media (max-width: 860px) {
  body.cine .hero { align-items: flex-end; padding-bottom: 150px; }
  body.cine .hero-visual { left: 16px; right: 16px; bottom: 20px; overflow-x: auto; scrollbar-width: none; }
  body.cine .float-card { flex: 0 0 auto; font-size: .82rem; }
  body.cine .scroll-cue { display: none; }
  body.cine .video-pausa { left: auto; right: 16px; bottom: auto; top: calc(var(--header-h) + 14px); }
}

/* ---------- Escena «Tu visita» fijada al scroll ---------- */
.escena { display: none; }
body.cine #visita.con-escena .container { display: none; }
body.cine #visita.con-escena { padding: 0; background: #071f24; }
body.cine .escena { display: block; position: relative; height: 100svh; overflow: hidden; color: #fff; }
.escena .fotos, .escena .foto { position: absolute; inset: 0; }
.escena .foto { background-size: cover; background-position: center; opacity: 0; transform: scale(1.12); }
.escena .foto:first-child { opacity: 1; transform: scale(1); }
.escena .velo { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(7,31,36,.92) 0%, rgba(7,31,36,.65) 45%, rgba(7,31,36,.15) 100%); }
.escena .titulo-escena { position: absolute; top: calc(var(--header-h) + 24px); left: clamp(16px, 6vw, 96px); right: 16px;
  font-size: .85rem; font-weight: 800; letter-spacing: .2em; text-transform: uppercase; color: #ffb3c2; }
.escena .pasos { position: absolute; left: clamp(16px, 6vw, 96px); right: 16px; top: 22%; bottom: 18%; max-width: 640px; list-style: none; margin: 0; padding: 0; }
.escena .paso { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: center; opacity: 0; }
.escena .paso:first-child { opacity: 1; }
.escena .num { display: block; font-size: clamp(5rem, 16vw, 11rem); font-weight: 800; line-height: .85; letter-spacing: -.06em;
  color: transparent; -webkit-text-stroke: 2px rgba(255,255,255,.6); }
.escena .paso h3 { color: #fff; font-size: clamp(2rem, 4.6vw, 3.6rem); letter-spacing: -.03em; margin: 14px 0 12px; }
.escena .paso p { color: rgba(255,255,255,.85); font-size: clamp(1rem, 1.5vw, 1.2rem); line-height: 1.55; margin: 0; }
.escena .barra { position: absolute; left: clamp(16px, 6vw, 96px); right: clamp(16px, 6vw, 96px); bottom: 40px; height: 3px; background: rgba(255,255,255,.18); border-radius: 3px; }
.escena .barra i { position: absolute; inset: 0; transform-origin: left; transform: scaleX(0); background: linear-gradient(90deg, #7fe0ea, #ff5c7c); border-radius: inherit; }
.escena .contador { position: absolute; right: clamp(16px, 6vw, 96px); bottom: 56px; font-weight: 700; color: rgba(255,255,255,.7); font-variant-numeric: tabular-nums; }
@media (max-width: 860px) {
  .escena .velo { background: linear-gradient(180deg, rgba(7,31,36,.25) 0%, rgba(7,31,36,.9) 55%, #071f24 100%); }
  .escena .pasos { top: 36%; bottom: 140px; }
  .escena .barra { bottom: 96px; }
  .escena .contador { bottom: 108px; }
  .escena .paso { justify-content: flex-end; }
  .escena .num { font-size: 4.5rem; }
}

/* ---------- Fotos con profundidad ---------- */
body.cine .about-card { overflow: hidden; }
body.cine .about-card img { will-change: transform; }

/* Sin animaciones si la persona lo pidió en su dispositivo */
@media (prefers-reduced-motion: reduce) {
  body.cine .hero-grano { animation: none; }
  body.cine .bandas { display: none; }
}

/* Lenis maneja el desplazamiento suave: se desactiva el «smooth» nativo para que no compitan */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }

/* ---------- Escena «Del tubo a tu resultado» ----------
   Sin animación (o sin JS) se ve todo junto: los textos, el tubo lleno y el informe. */
.muestra { background: #071f24; color: #fff; padding: clamp(60px, 9vw, 110px) 0; overflow: hidden; }
.muestra-escenario { position: relative; max-width: 1180px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 40px);
  display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 5vw, 70px); align-items: center; }
.muestra .eyebrow { color: #ffb3c2; letter-spacing: .18em; }
.muestra-textos .mt { font-size: clamp(1.05rem, 1.6vw, 1.25rem); line-height: 1.5; color: rgba(255,255,255,.82); margin: 0 0 18px; }
.muestra-textos .mt strong { display: block; color: #fff; font-size: clamp(1.6rem, 3.4vw, 2.7rem); letter-spacing: -.03em; line-height: 1.1; margin-bottom: 8px; }
.muestra-visual { position: relative; min-height: 520px; display: flex; align-items: center; justify-content: center; gap: 28px; }
.tubo-wrap { position: relative; width: 130px; flex: 0 0 auto; }
.tubo { width: 100%; height: auto; display: block; overflow: visible; filter: drop-shadow(0 20px 40px rgba(0,0,0,.45)); }
.muestra:not(.animada) .liquido, .muestra:not(.animada) .menisco { transform: translateY(-370px); }   /* lleno si no hay animación */
.gota { display: none; }
.muestra-barra { display: none; }

/* Con animación: escenario a pantalla completa y todo aparece paso a paso */
body.cine .muestra.animada { padding: 0; }
body.cine .muestra.animada .muestra-escenario { height: 100svh; }
body.cine .muestra.animada .muestra-textos { position: relative; height: 60%; }
body.cine .muestra.animada .mt { position: absolute; left: 0; right: 0; top: 50%; opacity: 0; }
body.cine .muestra.animada .muestra-visual { min-height: 0; height: 100%; }
body.cine .muestra.animada .tubo-wrap { position: absolute; left: 50%; top: 50%; width: 150px; margin: -280px 0 0 -75px; }
body.cine .muestra.animada .gota { display: block; position: absolute; left: 50%; top: -40px; width: 18px; height: 24px; margin-left: -9px;
  background: #c42b4c; border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%; opacity: 0; }
body.cine .muestra.animada .muestra-barra { display: block; position: absolute; left: clamp(16px, 4vw, 40px); right: clamp(16px, 4vw, 40px); bottom: 34px; height: 3px; background: rgba(255,255,255,.15); border-radius: 3px; }
body.cine .muestra.animada .muestra-barra i { position: absolute; inset: 0; transform: scaleX(0); transform-origin: left; background: linear-gradient(90deg, #c42b4c, #7fe0ea); border-radius: inherit; }

@media (max-width: 860px) {
  .muestra-escenario { grid-template-columns: 1fr; }
  .muestra-visual { flex-direction: column; min-height: 0; }
  body.cine .muestra.animada .muestra-escenario { grid-template-rows: 30% 70%; gap: 0; padding-top: calc(var(--header-h) + 10px); padding-bottom: 120px; }
  body.cine .muestra.animada .anillo { font-size: .54rem; overflow-wrap: normal; }
  body.cine .muestra.animada .muestra-textos { height: 100%; }
  body.cine .muestra.animada .mt { top: 40%; }
  body.cine .muestra.animada .tubo-wrap { width: 92px; margin: -230px 0 0 -46px; }
  body.cine .muestra.animada .telefono { width: 178px; border-radius: 30px; padding: 7px; }
  body.cine .muestra.animada .tel-pantalla { border-radius: 24px; padding: 38px 11px 11px; gap: 8px; }
  body.cine .muestra.animada .tel-titulo { font-size: 1rem; }
  body.cine .muestra.animada .tl-fila { padding: 7px 9px; font-size: .66rem; }
  body.cine .muestra.animada .tel-boton { font-size: .68rem; padding: 8px; }
  body.cine .muestra.animada .aviso-jont { top: 34px; padding: 7px 9px; }
    body.cine .muestra.animada .muestra-barra { bottom: 96px; }
}

/* Celular con los resultados (pantalla estilo app) */
.telefono { width: 250px; flex: 0 0 auto; aspect-ratio: 9 / 19; border-radius: 40px; padding: 10px;
  background: linear-gradient(145deg, #2b3a3e, #0d1719); box-shadow: 0 40px 90px -20px rgba(0,0,0,.7), inset 0 0 0 1.5px rgba(255,255,255,.12); }
.tel-pantalla { position: relative; height: 100%; border-radius: 31px; overflow: hidden; padding: 46px 16px 16px;
  background: radial-gradient(120% 70% at 50% 0%, #11444c 0%, #0a2a30 55%, #071c20 100%); color: #fff; display: flex; flex-direction: column; gap: 12px; }
.tel-isla { position: absolute; top: 10px; left: 50%; width: 78px; height: 22px; margin-left: -39px; border-radius: 12px; background: #000; }
.tel-cab { display: flex; align-items: center; justify-content: space-between; }
.tel-cab img { height: 26px; width: auto; background: #fff; border-radius: 8px; padding: 3px 6px; }
.tel-cab span { font-size: .62rem; letter-spacing: .1em; text-transform: uppercase; color: rgba(255,255,255,.55); font-weight: 700; }
.tel-titulo { margin: 4px 0 0; font-size: 1.25rem; font-weight: 800; letter-spacing: -.02em; }
.anillos { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.anillo { min-width: 0; text-align: center; font-size: .62rem; font-weight: 700; color: rgba(255,255,255,.8); overflow-wrap: anywhere; }
.anillo svg { width: 100%; height: auto; transform: rotate(-90deg); display: block; margin-bottom: 4px; }
.anillo circle { fill: none; stroke-width: 5; }
.anillo .pista { stroke: rgba(255,255,255,.1); }
.anillo .arco { stroke: #7fe0ea; stroke-linecap: round; stroke-dasharray: 113.1; stroke-dashoffset: 28; }
.anillo:nth-child(2) .arco { stroke: #ff8fa6; } .anillo:nth-child(3) .arco { stroke: #b9f0c9; }
.tel-lista { display: grid; gap: 6px; }
.tl-fila { display: flex; justify-content: space-between; align-items: center; background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.08);
  border-radius: 12px; padding: 9px 11px; font-size: .74rem; font-weight: 700; }
.tl-fila em { font-style: normal; font-size: .64rem; color: #0a353c; background: #7fe0ea; border-radius: 999px; padding: 3px 8px; }
.tel-boton { margin-top: auto; text-align: center; background: #25d366; color: #05301a; font-weight: 800; font-size: .78rem; border-radius: 999px; padding: 10px; }
.aviso-jont { position: absolute; left: 8px; right: 8px; top: 40px; z-index: 2; display: flex; gap: 8px; align-items: center;
  background: rgba(255,255,255,.92); color: #0c2328; border-radius: 16px; padding: 9px 11px; box-shadow: 0 12px 30px rgba(0,0,0,.35); }
.aviso-ic { width: 28px; height: 28px; border-radius: 8px; background: #25d366; display: grid; place-items: center; font-size: .85rem; flex: 0 0 auto; }
.aviso-jont strong { display: block; font-size: .68rem; }
.aviso-jont span { font-size: .66rem; color: #34515a; }

/* Animado: el celular espera en el centro; la gota viaja del tubo a la pantalla */
body.cine .muestra.animada .telefono { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); opacity: 0; }
body.cine .muestra.animada .aviso-jont { opacity: 0; }
body.cine .muestra.animada .gota { z-index: 5; }
@media (max-width: 860px) {
  .telefono { width: 230px; }
}
.gota-viaje { position: absolute; left: 0; top: 0; width: 22px; height: 28px; margin: -14px 0 0 -11px; z-index: 6; pointer-events: none; opacity: 0;
  background: radial-gradient(circle at 35% 35%, #ff7d97 0%, #c42b4c 45%, #6e0f22 100%); border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%;
  box-shadow: 0 0 24px 6px rgba(196,43,76,.55); }
