/* Lumina · one-page. Mismo esqueleto que la de Médula y la v6 de Optimizo (siempre claro, retícula de cuatro columnas,
   texto que se escribe), con la identidad de Lumina: el ámbar de la luz, tinta de Optimizo y SF. */

:root {
  --blanco: #FFFFFF; --nube: #F5F5F7; --tinta: #0B131B; --texto-2: #5E6A71; --texto-3: #A1A9AD; --apagado: #C9CFD2; --linea: rgba(11, 19, 27, .08);
  --lumina: #EC6D27; --lumina-claro: #F5A06A; --lumina-hondo: #CF560B; --lumina-texto: #B34A07; --lumina-crema: #FDEEE4; --lumina-noche: #0F0B06;
  --critica: #E5484D; --revision: #D97A00; --atendida: #1F9D5A;
  --letra: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Inter", system-ui, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --llegada: cubic-bezier(.16, 1, .3, 1);
  --ancho: 1240px;
  --margen: calc((100vw - min(var(--ancho), 100vw - 40px)) / 2);
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; overflow-x: clip; }
body { background: var(--blanco); color: var(--tinta); font-family: var(--letra); font-size: 17px; line-height: 1.5; letter-spacing: -.012em; -webkit-font-smoothing: antialiased; overflow-x: clip; }
img, svg, video, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; text-align: inherit; }
:focus-visible { outline: 2px solid var(--lumina-hondo); outline-offset: 3px; border-radius: 6px; }
::selection { background: var(--lumina-claro); color: var(--tinta); }
.envoltura { width: min(var(--ancho), 100% - 40px); margin-inline: auto; }
main, .pie { position: relative; z-index: 1; }
section[id] { scroll-margin-top: 72px; }
.gris { color: var(--texto-3); }
.bajada { color: var(--texto-2); font-size: 18px; max-width: 48ch; }
.nota { margin-top: 14px; font-size: 13px; color: var(--texto-3); text-align: center; }
.nota--izq { text-align: left; }

/* ── Tipografía ── */
.eti { display: inline-flex; align-items: center; gap: 10px; font-size: 12.5px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--texto-2); }
.eti::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--lumina); box-shadow: 0 0 0 3px rgba(236, 109, 39, .18); }
.t { font-size: clamp(2.2rem, 1.2rem + 2.6vw, 3.9rem); line-height: 1.02; letter-spacing: -.05em; font-weight: 600; text-wrap: balance; }
.arma .pal { display: inline-block; vertical-align: top; padding-bottom: .1em; margin-bottom: -.1em; }
.arma .pal > span { display: inline-block; transform: translateY(.35em); opacity: 0; filter: blur(12px); transition: transform 1.1s var(--llegada), opacity .9s var(--llegada), filter .9s var(--llegada); transition-delay: calc(var(--i) * 45ms); }
.arma.visto .pal > span { transform: none; opacity: 1; filter: none; }
[data-r] { opacity: 0; transform: translateY(26px); filter: blur(8px); transition: opacity 1s var(--llegada), transform 1.2s var(--llegada), filter 1s var(--llegada); transition-delay: var(--d, 0s); }
[data-r].visto { opacity: 1; transform: none; filter: none; }

.cursor { display: inline-block; width: .07em; min-width: 2px; height: .9em; margin-left: .06em; vertical-align: -.08em; border-radius: 2px; background: var(--lumina-hondo); animation: parpadeo 1.05s steps(1) infinite; }
.escribiendo + .cursor { animation: none; }
@keyframes parpadeo { 50% { opacity: 0; } }

/* ── Botones ── */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; height: 52px; padding: 0 24px; border-radius: 999px; background: var(--tinta); color: #fff; font-weight: 600; font-size: 15.5px; letter-spacing: -.01em; white-space: nowrap; transition: background .3s, transform .5s var(--llegada), box-shadow .5s var(--llegada); }
.btn svg { width: 16px; height: 16px; transition: transform .5s var(--llegada); }
.btn img { width: 18px; height: 18px; filter: brightness(0) invert(1); }
.btn:hover { background: #1B2530; box-shadow: 0 14px 30px -14px rgba(11, 19, 27, .5); }
.btn:hover svg { transform: translateX(3px); }
.btn:active { transform: scale(.97); }
.btn--claro { background: rgba(255, 255, 255, .7); color: var(--tinta); box-shadow: inset 0 0 0 1px rgba(11, 19, 27, .14); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }
.btn--claro:hover { background: #fff; box-shadow: inset 0 0 0 1px rgba(11, 19, 27, .22), 0 14px 30px -18px rgba(11, 19, 27, .35); }
.btn--chico { height: 38px; padding: 0 16px; font-size: 14px; }
.btn--grande { height: 58px; padding: 0 30px; font-size: 16.5px; }

/* ── Navegación: vidrio blanco ── */
.nav { position: fixed; inset: 0 0 auto; z-index: 60; background: rgba(255, 255, 255, .72); -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px); transition: box-shadow .4s; }
.nav.bajo { box-shadow: 0 1px 0 var(--linea); }
.nav__in { display: flex; align-items: center; gap: 28px; height: 64px; }
.logo { display: inline-flex; align-items: center; gap: 9px; color: var(--tinta); }
.logo { gap: 10px; }
.logo__iso { width: 26px; height: 26px; }
.logo__palabra { height: 15px; width: auto; }
.logo small { font-size: 13px; font-weight: 500; color: var(--texto-3); letter-spacing: -.01em; margin-left: 4px; padding-left: 12px; border-left: 1px solid var(--linea); line-height: 18px; }
.nav__links { display: flex; gap: 26px; margin-left: auto; font-size: 14.5px; font-weight: 500; color: var(--texto-2); }
.nav__links a { transition: color .25s; }
.nav__links a:hover { color: var(--tinta); }
.nav__menu { display: none; width: 40px; height: 40px; margin-left: auto; position: relative; }
.nav__menu i { position: absolute; left: 11px; right: 11px; height: 1.6px; border-radius: 2px; background: var(--tinta); transition: transform .4s var(--llegada); }
.nav__menu i:first-child { top: 16px; } .nav__menu i:last-child { top: 23px; }
.nav.abierto .nav__menu i:first-child { transform: translateY(3.5px) rotate(45deg); }
.nav.abierto .nav__menu i:last-child { transform: translateY(-3.5px) rotate(-45deg); }
.menu { display: none; }
.progreso { position: absolute; left: 0; right: 0; bottom: 0; height: 2px; }
.progreso i { position: absolute; inset: 0; background: linear-gradient(90deg, var(--lumina-claro), var(--lumina-hondo)); transform-origin: left; transform: scaleX(var(--p, 0)); }

/* ── La luz: una malla de puntos que solo se ve donde pasa la luz ── */
.luz { position: absolute; inset: 0; width: 100%; height: 100%; }

/* ── Banner: el video de fondo a pantalla completa; el título y el CTA directo encima ── */
.heroe { position: relative; height: 100svh; min-height: 620px; max-height: 1000px; overflow: hidden; background: #1A1F23; }
.vivo, .vivo video, .vivo__capa { position: absolute; inset: 0; width: 100%; height: 100%; }
.vivo video { object-fit: cover; opacity: 0; transform: scale(1.04); transition: opacity 1s var(--llegada), transform 6s linear; }
.vivo video.on { opacity: 1; transform: scale(1); }
.vivo__velo { position: absolute; inset: 0; background: linear-gradient(to top, rgba(7, 9, 11, .86), rgba(7, 9, 11, .55) 48%, rgba(7, 9, 11, .38)); pointer-events: none; }
.heroe { display: flex; align-items: flex-end; padding: 120px 0 72px; }
.heroe__in { position: relative; z-index: 3; color: #fff; }
.heroe .eti { color: rgba(255, 255, 255, .78); }
.heroe .eti::before { background: var(--lumina); box-shadow: 0 0 0 3px rgba(236, 109, 39, .3); }
.heroe__t { margin-top: 26px; font-size: clamp(3rem, 1rem + 4.7vw, 6.4rem); line-height: .95; letter-spacing: -.058em; font-weight: 600; color: #fff; text-shadow: 0 2px 30px rgba(0, 0, 0, .3); }
.heroe__t .arma, .heroe__linea { display: block; }
.heroe__linea { min-height: 1em; }
.heroe__linea .tipeo { color: rgba(255, 255, 255, .55); }
.heroe__pie { margin-top: 52px; padding-top: 28px; border-top: 1px solid rgba(255, 255, 255, .28); display: flex; align-items: flex-end; justify-content: space-between; gap: 40px; }
.heroe__pie .bajada { color: rgba(255, 255, 255, .82); max-width: 46ch; }
.heroe .btn { background: #fff; color: var(--tinta); flex: none; }
.heroe .btn:hover { background: #F2F2F0; box-shadow: 0 14px 30px -14px rgba(0, 0, 0, .5); }

/* ── La frase: centrada, se escribe por partes ── */
.frase { min-height: 100vh; display: flex; align-items: center; padding: 240px 0 200px; }
.frase__in { display: grid; justify-items: center; gap: 34px; text-align: center; }
.frase__l { position: relative; max-width: 22ch; text-wrap: balance; font-size: clamp(1.8rem, 1rem + 2.4vw, 3.2rem); line-height: 1.08; letter-spacing: -.045em; font-weight: 600; color: var(--texto-3); }
.frase__l--b { max-width: 15ch; color: var(--tinta); font-size: clamp(2.4rem, 1.1rem + 3.6vw, 4.8rem); letter-spacing: -.055em; }
.frase__l .fant { visibility: hidden; }
.frase__l .vivo-t { position: absolute; inset: 0; }
.frase__l .cursor { opacity: 0; }
.frase__l.on .cursor { opacity: 1; }

/* ── Encabezado en dos columnas ── */
.cab2 { display: grid; grid-template-columns: 1fr 1fr; gap: 22px 64px; align-items: end; margin-bottom: 56px; }
.cab2 > div:first-child { display: grid; gap: 22px; justify-items: start; }
.cab2 .t { max-width: 15ch; }
.cab2 > .bajada { padding-left: 22px; }

/* ── El recorrido: la maqueta en 3D y sus seis estaciones ── */
.como { padding: 130px 0 60px; }
.recorrido { position: relative; z-index: 1; height: 520vh; margin: 0 calc(50% - 50vw); }
.recorrido__fijo { position: sticky; top: 64px; height: calc(100vh - 64px); display: flex; flex-direction: column; background: #fff; overflow: hidden; }
.recorrido__fijo > .estaciones, .recorrido__fijo > .estaciones__txt { width: min(var(--ancho), 100% - 40px); margin-inline: auto; }
.recorrido__fijo > .estaciones { margin-bottom: 22px; }
.maqueta { position: relative; flex: 1; min-height: 0; overflow: hidden; }
.maqueta__lienzo { position: absolute; inset: 0; width: 100%; height: 100%; cursor: grab; }
.maqueta__lienzo:active { cursor: grabbing; }
.maqueta__capa { position: absolute; inset: 0; pointer-events: none; }
.maqueta__cargando { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); font-size: 14px; color: var(--texto-3); transition: opacity .5s; }
.maqueta.lista .maqueta__cargando { opacity: 0; }

/* etiquetas: punto ámbar numerado, línea fina y el texto que se despliega cuando llega la luz */
.eti3d { position: absolute; left: 0; top: 0; transform: translate(var(--x), var(--y)); will-change: transform; }
.eti3d__linea { position: absolute; left: 0; bottom: 0; width: 1px; height: var(--alto, 46px); background: linear-gradient(to top, rgba(11, 19, 27, .35), rgba(11, 19, 27, .12)); transform-origin: bottom; transition: height .7s var(--llegada); }
.eti3d__caja { position: absolute; left: -11px; bottom: var(--alto, 46px); display: flex; align-items: flex-start; gap: 10px; width: max-content; max-width: 290px; padding: 0; transition: bottom .7s var(--llegada); }
.eti3d__n { flex: none; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: #fff; box-shadow: inset 0 0 0 1px rgba(11, 19, 27, .18); font-size: 10.5px; font-weight: 700; color: var(--texto-2); font-variant-numeric: tabular-nums; transition: background .5s, color .5s, box-shadow .5s; }
.eti3d__txt { display: grid; gap: 2px; padding-top: 2px; }
.eti3d__txt b { font-size: 14px; font-weight: 600; letter-spacing: -.02em; line-height: 1.2; color: var(--texto-2); white-space: nowrap; transition: color .5s, font-size .5s; }
.eti3d__txt em { font-style: normal; font-size: 13.5px; line-height: 1.35; color: var(--texto-2); max-width: 30ch; max-height: 0; overflow: hidden; opacity: 0; transition: max-height .7s var(--llegada), opacity .5s; }
.eti3d:not(.activo) .eti3d__txt { opacity: 0; transform: translateX(-6px); }
.eti3d__txt { transition: opacity .5s, transform .6s var(--llegada); }
.eti3d { --alto: 30px; }
.eti3d.activo { --alto: 74px; z-index: 2; }
.eti3d.activo .eti3d__n { background: var(--lumina); color: #FFFFFF; box-shadow: 0 0 0 5px rgba(236, 109, 39, .22), 0 0 22px 4px rgba(236, 109, 39, .45); }
.eti3d.activo .eti3d__txt b { font-size: 17px; color: var(--tinta); }
.eti3d.activo .eti3d__txt em { max-height: 5em; opacity: 1; }
.eti3d.activo .eti3d__linea { background: linear-gradient(to top, var(--lumina-hondo), rgba(236, 109, 39, .25)); }
/* etiquetas vivas de detección y alerta */
.tag3d { position: absolute; left: 0; top: 0; transform: translate(var(--x), var(--y)) translate(-50%, -100%); display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 10px 0 8px; border-radius: 999px; background: rgba(15, 11, 6, .84); color: #fff; font-size: 12px; font-weight: 600; white-space: nowrap; opacity: 0; transition: opacity .35s; }
.tag3d::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--c, var(--lumina-claro)); }
.tag3d.on { opacity: 1; }
.tag3d--alerta { height: 30px; padding: 0 13px 0 10px; font-size: 13px; background: #fff; color: var(--tinta); box-shadow: 0 14px 30px -14px rgba(11, 19, 27, .5); --c: var(--critica); }

.estaciones { display: grid; grid-template-columns: repeat(6, 1fr); border-top: 1px solid var(--linea); }
.estacion { position: relative; display: grid; align-content: start; gap: 4px; padding: 16px 16px 4px 0; text-align: left; }
.estacion + .estacion { padding-left: 16px; box-shadow: -1px 0 0 var(--linea); }
.estacion__barra { position: absolute; left: 0; right: 0; top: -1px; height: 2px; background: linear-gradient(90deg, var(--lumina-claro), var(--lumina-hondo)); transform-origin: left; transform: scaleX(0); }
.estacion.activo .estacion__barra { transform: scaleX(var(--prog, 0)); }
.estacion span { font-size: 12px; font-weight: 700; color: var(--texto-3); font-variant-numeric: tabular-nums; transition: color .4s; }
.estacion b { font-size: 15px; font-weight: 600; letter-spacing: -.02em; line-height: 1.2; color: var(--texto-2); transition: color .4s; }
.estacion em { display: none; }
.estaciones__txt { display: none; margin-top: 14px; font-size: 15.5px; line-height: 1.4; color: var(--texto-2); min-height: 4.2em; }
.estaciones__txt b { color: var(--tinta); font-weight: 600; }
.estacion.activo span { color: var(--lumina-texto); }
.estacion.activo b, .estacion:hover b { color: var(--tinta); }

/* ── Metodología: cuatro tarjetas que entran y se apilan, como los superpoderes de Optimizo ── */
.metodo { padding: 140px 0 40px; }
.pila { display: grid; padding-bottom: 6vh; }
.carta { position: sticky; top: calc(96px + var(--i) * 14px); height: min(560px, calc(100vh - 150px)); margin-bottom: 12vh; display: grid; grid-template-columns: 5fr 7fr; border-radius: 32px; background: #fff; box-shadow: inset 0 0 0 1px var(--linea), 0 -20px 60px -40px rgba(11, 19, 27, .25); overflow: hidden; transform-origin: 50% 0; transform: scale(var(--esc, 1)); will-change: transform; }
.carta:last-child { margin-bottom: 0; }
.carta > * { opacity: var(--luz, 1); transition: opacity .2s; }
.carta__txt { display: flex; flex-direction: column; align-items: flex-start; padding: 40px 44px; }
.carta__n { font-size: 13px; font-weight: 600; color: var(--lumina-texto); font-variant-numeric: tabular-nums; }
.carta h3 { margin-top: auto; font-size: clamp(2.4rem, 1.4rem + 2.6vw, 4.2rem); font-weight: 600; letter-spacing: -.055em; line-height: 1; }
.carta p { margin-top: 14px; font-size: 16.5px; color: var(--texto-2); max-width: 40ch; }
.carta__esc { position: relative; margin: 14px; border-radius: 22px; background: var(--nube); overflow: hidden; isolation: isolate; }
.carta__esc::before { content: ""; position: absolute; z-index: -1; width: 70%; height: 70%; right: -14%; top: -18%; border-radius: 50%; background: var(--lumina); opacity: .16; filter: blur(60px); }
.carta__esc canvas { position: absolute; inset: 0; width: 100%; height: 100%; }

/* ── Preguntas ── */
.fq { padding: 140px 0 100px; }
.fq__in { display: grid; grid-template-columns: 5fr 7fr; gap: 0 64px; }
.fq__izq { position: sticky; top: 120px; align-self: start; display: grid; gap: 22px; justify-items: start; padding-right: 12px; }
.fq__lista details { border-top: 1px solid var(--linea); }
.fq__lista details:last-child { border-bottom: 1px solid var(--linea); }
.fq__lista summary { list-style: none; display: flex; align-items: center; gap: 18px; padding: 26px 0; cursor: pointer; font-size: clamp(1.05rem, 1rem + .3vw, 1.25rem); font-weight: 600; letter-spacing: -.02em; }
.fq__lista summary::-webkit-details-marker { display: none; }
.fq__lista summary span { width: 28px; flex: none; font-size: 13px; font-weight: 600; color: var(--texto-3); font-variant-numeric: tabular-nums; }
.fq__lista summary i { position: relative; width: 14px; height: 14px; margin-left: auto; flex: none; }
.fq__lista summary i::before, .fq__lista summary i::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 1.6px; margin-top: -.8px; border-radius: 2px; background: var(--tinta); transition: transform .5s var(--llegada); }
.fq__lista summary i::after { transform: rotate(90deg); }
.fq__lista details[open] summary i::after { transform: rotate(0); }
.fq__lista details p { padding: 0 40px 28px 46px; color: var(--texto-2); max-width: 64ch; }
.fq__lista details[open] p { animation: abre .6s var(--llegada); }
@keyframes abre { from { opacity: 0; transform: translateY(-6px); } }

/* ── Cierre ── */
.fin { position: relative; overflow: hidden; padding: 200px 0 220px; text-align: center; }
.fin__in { position: relative; z-index: 2; display: grid; justify-items: center; gap: 26px; }
.fin__t { font-size: clamp(3rem, 1rem + 6vw, 7.2rem); line-height: .95; letter-spacing: -.058em; font-weight: 600; max-width: 11ch; text-wrap: balance; }
.fin .bajada { text-align: center; max-width: 50ch; }

/* ── Footer ── */
.pie { border-top: 1px solid var(--linea); padding: 64px 0 32px; background: #fff; }
.pie__arriba { display: flex; justify-content: space-between; gap: 48px; }
.pie__marca p { margin-top: 14px; color: var(--texto-2); font-size: 15px; }
.pie__cols { display: grid; grid-template-columns: repeat(3, auto); gap: 72px; }
.pie__cols h4 { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--texto-3); margin-bottom: 14px; }
.pie__cols a { display: block; font-size: 15px; margin-bottom: 9px; transition: color .25s; }
.pie__cols a:hover { color: var(--lumina-texto); }
.pie__abajo { margin-top: 64px; padding-top: 22px; border-top: 1px solid var(--linea); display: flex; justify-content: space-between; gap: 24px; font-size: 13px; color: var(--texto-3); }
.pie__abajo span:last-child { max-width: 62ch; text-align: right; }


/* ── Celular y tableta ── */
@media (max-width: 1020px) {
  .nav__links, .nav__in > .btn { display: none; }
  .nav__menu { display: block; }
  .menu { display: grid; max-height: 0; overflow: hidden; padding: 0 20px; transition: max-height .6s var(--llegada), padding .6s var(--llegada); }
  .nav.abierto .menu { max-height: 620px; padding: 8px 20px 24px; }
  .nav.abierto { background: rgba(255, 255, 255, .96); }
  .menu a:not(.btn) { padding: 13px 0; font-size: 19px; font-weight: 600; letter-spacing: -.02em; border-bottom: 1px solid var(--linea); }
  .menu .btn { margin-top: 18px; }
  .heroe { height: 92svh; min-height: 560px; }
  .heroe { padding: 110px 0 48px; }
  .heroe__pie { flex-direction: column; align-items: stretch; gap: 24px; margin-top: 32px; }
  .frase { min-height: 80vh; padding: 160px 0 140px; }
  .recorrido { height: 440svh; }
  .recorrido__fijo { top: 64px; height: calc(100svh - 64px); }
  .carta { top: calc(76px + var(--i) * 8px); height: calc(100svh - 110px); grid-template-columns: 1fr; grid-template-rows: 1fr auto; border-radius: 26px; margin-bottom: 10vh; }
  .carta__esc { order: -1; margin: 10px; border-radius: 18px; }
  .carta__txt { padding: 16px 22px 24px; }
  .carta h3 { margin-top: 6px; font-size: 2.3rem; }
  .carta p { font-size: 15px; }
  .cab2 { grid-template-columns: 1fr; }
  .cab2 > .bajada { padding-left: 0; }
  .como, .metodo, .fq { padding-top: 96px; }
  .cab2 { margin-bottom: 36px; }
  .frase { min-height: 74vh; }
  .eti3d:not(.activo) .eti3d__txt { display: none; }
  .eti3d__txt em { display: none; }
  .estaciones { grid-template-columns: repeat(6, 1fr); }
  .estacion b { display: none; }
  .estacion, .estacion + .estacion { padding: 14px 0 0; justify-items: center; box-shadow: none; }
  .estaciones__txt { display: block; }
  .fq__in { grid-template-columns: 1fr; }
  .fq__izq { position: static; margin-bottom: 30px; padding: 0; }
  .fin { padding: 150px 0 170px; }
  .pie__arriba { flex-direction: column; }
  .pie__cols { grid-template-columns: 1fr 1fr; gap: 32px; }
  .pie__abajo { flex-direction: column; }
  .pie__abajo span:last-child { text-align: left; }
}
@media (max-width: 560px) {
  .bajada { font-size: 16.5px; }
  .logo small { display: none; }
  .heroe .btn { width: 100%; }
  .fq__lista details p { padding-left: 0; padding-right: 0; }
  .fin .btn { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .cursor { animation: none; }
  .arma .pal > span, [data-r] { filter: none; }
}
