/* ==========================================================================
   FEST · prototipo de portada
   Concepto: la graduación como lanzamiento.
   ========================================================================== */

:root {
  --night: #060a1a;
  --ink: #0d1430;
  --deep: #121b3d;
  --silver: #dde1ec;
  --mist: #8c95b0;
  --line: rgba(221, 225, 236, .14);
  --gold: #e3b866;
  --gold-hi: #f8e3ab;

  --serif: "Bodoni Moda", "Didot", "Bodoni 72", Georgia, serif;
  --sans: "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "DM Mono", ui-monospace, Menlo, monospace;

  --gutter: clamp(20px, 5vw, 72px);
  --ease: cubic-bezier(.19, .8, .22, 1);
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--night);
  color: var(--silver);
  font: 400 17px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

/* Viñeta fija: profundiza los bordes del cielo */
body::before {
  content: "";
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(120% 80% at 50% 0%, rgba(24, 36, 84, .55), transparent 60%),
    radial-gradient(90% 60% at 50% 120%, rgba(18, 27, 61, .7), transparent 70%);
}

#sky {
  position: fixed; inset: 0; z-index: 0;
  width: 100%; height: 100%;
  pointer-events: none;
}

main, .foot { position: relative; z-index: 1; }

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; margin: 0; padding: 0; }
h1, h2, h3, p, dl, dd, figure { margin: 0; }

.wrap { width: min(1240px, 100%); margin-inline: auto; padding-inline: var(--gutter); }

:focus-visible { outline: 2px solid var(--gold-hi); outline-offset: 3px; border-radius: 4px; }

.skip {
  position: fixed; top: 8px; left: 8px; z-index: 100;
  padding: 10px 16px; border-radius: 8px;
  background: var(--gold); color: var(--night); font-weight: 600;
  transform: translateY(-160%);
}
.skip:focus { transform: none; }

/* ---------- Tipografía ---------- */

.h2 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(38px, 6.4vw, 96px);
  line-height: 1;
  letter-spacing: -.02em;
  text-wrap: balance;
}
.h3 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(28px, 3.4vw, 44px);
  line-height: 1.1;
  letter-spacing: -.01em;
}

/* ---------- Botones ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 13px 26px;
  border-radius: 999px;
  border: 1px solid transparent;
  font: 600 15px/1 var(--sans);
  letter-spacing: .01em;
  cursor: pointer;
  transition: transform .35s var(--ease), background .3s, border-color .3s, color .3s, box-shadow .3s;
  -webkit-tap-highlight-color: transparent;
}
.btn:active { transform: scale(.97); }
.btn--lg { padding: 18px 34px; font-size: 16px; }

.btn--gold {
  background: linear-gradient(135deg, var(--gold-hi), var(--gold));
  color: #1a1204;
  box-shadow: 0 0 0 0 rgba(227, 184, 102, 0);
}
.btn--gold:hover { box-shadow: 0 0 34px 2px rgba(227, 184, 102, .4); transform: translateY(-1px); }

.btn--ghost { border-color: rgba(221, 225, 236, .32); color: var(--silver); background: rgba(6, 10, 26, .25); }
.btn--ghost:hover { border-color: var(--gold); color: var(--gold-hi); }

/* ---------- Navegación ---------- */

.nav {
  position: fixed; top: 14px; left: 50%; z-index: 60;
  transform: translateX(-50%);
  width: min(1240px, calc(100% - 2 * var(--gutter) + 24px));
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 10px 10px 10px 26px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(8, 13, 32, .42);
  -webkit-backdrop-filter: blur(16px) saturate(1.3);
  backdrop-filter: blur(16px) saturate(1.3);
  transition: background .4s, border-color .4s;
}
.nav.is-stuck { background: rgba(6, 10, 26, .82); border-color: rgba(227, 184, 102, .28); }

.brand { display: flex; flex-direction: column; gap: 3px; line-height: 1; }
.brand__name { font: 500 27px/1 var(--serif); letter-spacing: .1em; }
.brand__tag { font-size: 10px; letter-spacing: .06em; color: var(--mist); }

.nav__links { display: flex; gap: clamp(18px, 3vw, 44px); margin-left: auto; margin-right: 8px; }
.nav__links a { font-size: 15px; color: var(--silver); opacity: .82; transition: opacity .25s, color .25s; }
.nav__links a:hover { opacity: 1; color: var(--gold-hi); }

.burger { display: none; }

/* ---------- Portada ---------- */

.hero {
  position: relative;
  min-height: 100svh;
  display: flex; align-items: center;
  padding: 150px var(--gutter) 130px;
  overflow: clip;
}
.hero__inner {
  width: min(1240px, 100%); margin-inline: auto;
  display: grid; grid-template-columns: max-content minmax(260px, 1fr);
  align-items: center; column-gap: clamp(24px, 4vw, 72px);
}

.hero__title {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(46px, 8.4vw, 144px);
  line-height: .93;
  letter-spacing: -.03em;
  color: var(--silver);
}
.ln { display: block; overflow: hidden; padding: 0 .06em .1em 0; margin-bottom: -.04em; }
.ln > span { display: inline-block; }

/* La última línea se enciende cuando pasa la luz del lanzamiento */
.ln--go > span {
  background: linear-gradient(100deg, var(--silver) 0 38%, var(--gold-hi) 58%, var(--gold) 100%);
  background-size: 260% 100%;
  background-position: 0 0;
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
  padding-right: .06em;
}

.hero__lead {
  margin-top: clamp(24px, 3.5vw, 44px);
  max-width: 30ch;
  font-size: clamp(18px, 1.7vw, 23px);
  line-height: 1.5;
  color: var(--silver);
  opacity: .9;
}
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }

.hero__hud {
  position: absolute; left: var(--gutter); right: var(--gutter); bottom: 34px;
  display: flex; justify-content: space-between; gap: 20px;
  font: 400 12px/1.4 var(--mono);
  color: var(--mist);
}

.cap__flare {
  position: absolute; z-index: 0;
  left: 50%; top: 100%; margin-top: 12vh;
  width: 2px; height: 38vh;
  background: linear-gradient(to top, transparent, var(--gold-hi));
  box-shadow: 0 0 26px 3px rgba(227, 184, 102, .5);
  opacity: 0;
  pointer-events: none;
}
.cap__flare::after {
  content: ""; position: absolute; top: -4px; left: 50%;
  width: 9px; height: 9px; margin-left: -4.5px; border-radius: 50%;
  background: #fff; box-shadow: 0 0 18px 6px rgba(248, 227, 171, .9);
}
.hero__inner { position: relative; z-index: 1; }

/* Secuencia de entrada: solo con JS activo */
.js .ln > span { transform: translateY(112%); }
.js .hero__lead, .js .hero__actions { opacity: 0; transform: translateY(14px); }

.is-ready .ln > span { transform: none; transition: transform 1.2s var(--ease); }
.is-ready .ln:nth-child(2) > span { transition-delay: .1s; }
.is-ready .ln:nth-child(3) > span { transition-delay: .2s; }
.is-ready .ln--go > span {
  background-position: 100% 0;
  transition: transform 1.2s var(--ease) .2s, background-position 1.5s ease-in-out 1.55s;
}
.is-ready .hero__lead, .is-ready .hero__actions {
  opacity: 1; transform: none;
  transition: opacity .9s ease, transform .9s var(--ease);
}
.is-ready .hero__lead { transition-delay: .9s; }
.is-ready .hero__actions { transition-delay: 1.05s; }
.is-ready .cap__flare { animation: launch 2.1s cubic-bezier(.45, 0, .25, 1) .95s forwards; }

@keyframes launch {
  0%   { transform: translateY(0); opacity: 0; }
  12%  { opacity: 1; }
  82%  { opacity: 1; }
  100% { transform: translateY(-150vh); opacity: 0; }
}

/* ---------- Colegios ---------- */

.ticker {
  position: relative;
  overflow: hidden;
  border-block: 1px solid var(--line);
  background: linear-gradient(90deg, rgba(10, 16, 40, .88), rgba(18, 27, 61, .88), rgba(10, 16, 40, .88));
  -webkit-mask: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
          mask: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
}
.ticker__track { display: flex; width: max-content; animation: ticker 48s linear infinite; }
.ticker:hover .ticker__track { animation-play-state: paused; }
.ticker__list { display: flex; flex: none; }
.ticker__list li {
  display: flex; align-items: center; gap: 34px;
  padding: 24px 0 24px 34px;
  font: 500 clamp(20px, 2.4vw, 28px)/1 var(--serif);
  letter-spacing: .04em; text-transform: uppercase;
  white-space: nowrap;
}
.ticker__list li::after {
  content: ""; width: 7px; height: 7px; border-radius: 50%;
  background: var(--gold); opacity: .7;
}
@keyframes ticker { to { transform: translateX(-50%); } }

/* ---------- Manifiesto ---------- */

.manifesto { padding-block: clamp(110px, 18vw, 260px); }
.manifesto__text {
  max-width: 15em;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(28px, 4.4vw, 66px);
  line-height: 1.14;
  letter-spacing: -.015em;
  text-wrap: pretty;
}
.manifesto__text em { font-style: italic; }
.manifesto__text .w { transition: opacity .15s linear; }
.manifesto__text em .w { color: var(--gold-hi); }

/* ---------- Secuencia ---------- */

.seq { padding-block: clamp(40px, 8vw, 120px) clamp(90px, 14vw, 200px); }
.seq__head { max-width: 720px; }
.seq__intro { margin-top: 24px; max-width: 34ch; font-size: 19px; color: var(--mist); }

.seq__track { --p: 0; position: relative; margin-top: clamp(56px, 9vw, 120px); }
.seq__line, .seq__fill { position: absolute; left: 50%; top: 0; }
.seq__line { bottom: 0; width: 1px; background: var(--line); transform: translateX(-.5px); }
.seq__fill {
  width: 2px; height: calc(var(--p) * 100%);
  transform: translateX(-1px);
  background: linear-gradient(to bottom, rgba(227, 184, 102, .1), var(--gold-hi));
  box-shadow: 0 0 20px 1px rgba(227, 184, 102, .55);
}
.seq__star {
  position: absolute; left: 50%; top: calc(var(--p) * 100%);
  width: 26px; height: 26px;
  transform: translate(-50%, -50%);
  color: #fff;
  filter: drop-shadow(0 0 8px var(--gold-hi)) drop-shadow(0 0 20px var(--gold));
}

.steps { position: relative; }
.step {
  position: relative; --gap: clamp(36px, 6vw, 84px);
  display: grid; grid-template-columns: 1fr 1fr; align-items: center;
  min-height: clamp(230px, 28vw, 340px);
  opacity: .32;
  transition: opacity .7s ease;
}
.step.is-on { opacity: 1; }

.step__t { display: flex; flex-direction: column; gap: 4px; }
.step__num {
  font: 500 clamp(54px, 9vw, 140px)/.9 var(--serif);
  letter-spacing: -.03em;
  color: var(--silver);
}
.step.is-on .step__num { color: var(--gold-hi); transition: color .7s ease; }
.step__unit { font: 400 13px/1 var(--mono); color: var(--mist); }

.step__body h3 {
  font: 500 clamp(26px, 3vw, 40px)/1.1 var(--serif);
  margin-bottom: 12px;
}
.step__body p { max-width: 32ch; color: var(--mist); font-size: 18px; }

/* impares: texto a la izquierda, tiempo a la derecha; pares: al revés */
.step:nth-child(odd)  .step__body { grid-column: 1; text-align: right; padding-right: clamp(36px, 6vw, 84px); justify-self: end; }
.step:nth-child(odd)  .step__body p { margin-left: auto; }
.step:nth-child(odd)  .step__t    { grid-column: 2; grid-row: 1; padding-left: clamp(36px, 6vw, 84px); }
.step:nth-child(even) .step__t    { grid-column: 1; grid-row: 1; text-align: right; padding-right: clamp(36px, 6vw, 84px); align-items: flex-end; }
.step:nth-child(even) .step__body { grid-column: 2; grid-row: 1; padding-left: clamp(36px, 6vw, 84px); }

/* ---------- Cotizador ---------- */

.quote { padding-block: clamp(60px, 9vw, 140px); }
.quote__intro { margin-top: 22px; max-width: 34ch; font-size: 19px; color: var(--mist); }
.quote__grid {
  display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
  gap: clamp(36px, 6vw, 96px);
  margin-top: clamp(40px, 6vw, 80px);
  align-items: start;
}

.form { display: grid; gap: 30px; }
.field { display: grid; gap: 10px; border: 0; padding: 0; margin: 0; min-width: 0; }
.field label, .field legend { display: flex; justify-content: space-between; align-items: baseline; font-size: 14px; font-weight: 500; color: var(--mist); padding: 0; }
.field output { font: 500 15px/1 var(--mono); color: var(--gold-hi); }

.field input[type="text"], .field input[type="date"], .field select {
  width: 100%;
  padding: 10px 0 14px;
  border: 0; border-bottom: 1px solid rgba(221, 225, 236, .28);
  border-radius: 0;
  background: transparent;
  color: var(--silver);
  font: 500 clamp(20px, 2.2vw, 26px)/1.2 var(--serif);
  transition: border-color .3s;
  color-scheme: dark;
}
.field input::placeholder { color: rgba(140, 149, 176, .6); }
.field input:focus, .field select:focus { outline: none; border-bottom-color: var(--gold); }
.field select {
  -webkit-appearance: none; appearance: none; cursor: pointer;
  padding-right: 30px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9'%3E%3Cpath d='M1 1l6 6 6-6' fill='none' stroke='%23e3b866' stroke-width='1.8'/%3E%3C/svg%3E") no-repeat right 4px center;
}
.field select option { background: var(--ink); color: var(--silver); font: 500 16px var(--sans); }

input[type="range"] { -webkit-appearance: none; appearance: none; width: 100%; height: 30px; background: transparent; cursor: pointer; margin: 0; }
input[type="range"]::-webkit-slider-runnable-track {
  height: 2px;
  background: linear-gradient(90deg, var(--gold) var(--fill, 30%), rgba(221, 225, 236, .22) var(--fill, 30%));
}
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none; width: 22px; height: 22px; margin-top: -10px; border-radius: 50%;
  background: var(--gold-hi);
  box-shadow: 0 0 0 7px rgba(227, 184, 102, .16), 0 0 20px rgba(227, 184, 102, .6);
}
input[type="range"]::-moz-range-track { height: 2px; background: rgba(221, 225, 236, .22); }
input[type="range"]::-moz-range-progress { height: 2px; background: var(--gold); }
input[type="range"]::-moz-range-thumb {
  width: 22px; height: 22px; border: 0; border-radius: 50%;
  background: var(--gold-hi);
  box-shadow: 0 0 0 7px rgba(227, 184, 102, .16), 0 0 20px rgba(227, 184, 102, .6);
}

.chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 4px; }
.chip {
  padding: 11px 18px;
  border: 1px solid var(--line); border-radius: 999px;
  background: transparent; color: var(--silver);
  font: 500 14px/1 var(--sans);
  cursor: pointer;
  transition: background .25s, border-color .25s, color .25s, transform .3s var(--ease);
}
.chip:hover { border-color: rgba(227, 184, 102, .6); }
.chip:active { transform: scale(.96); }
.chip[aria-pressed="true"] { background: rgba(227, 184, 102, .15); border-color: var(--gold); color: var(--gold-hi); }

.form__send { display: grid; gap: 14px; justify-items: start; }
.form__note { max-width: 42ch; font-size: 14px; color: var(--mist); }

/* Pase de abordar */
.ticket {
  --stub: 124px;
  --r: 13px;
  position: sticky; top: 108px;
  padding: 30px 30px calc(var(--stub) + 26px);
  border: 1px solid rgba(248, 227, 171, .2);
  border-radius: 24px;
  background:
    radial-gradient(120% 80% at 100% 0%, rgba(227, 184, 102, .13), transparent 55%),
    linear-gradient(165deg, #1a2552 0%, #0e1636 62%, #0a1029 100%);
  -webkit-mask:
    radial-gradient(circle var(--r) at 0 calc(100% - var(--stub)), #0000 calc(var(--r) - 1px), #000 var(--r)) left / 51% 100% no-repeat,
    radial-gradient(circle var(--r) at 100% calc(100% - var(--stub)), #0000 calc(var(--r) - 1px), #000 var(--r)) right / 51% 100% no-repeat;
          mask:
    radial-gradient(circle var(--r) at 0 calc(100% - var(--stub)), #0000 calc(var(--r) - 1px), #000 var(--r)) left / 51% 100% no-repeat,
    radial-gradient(circle var(--r) at 100% calc(100% - var(--stub)), #0000 calc(var(--r) - 1px), #000 var(--r)) right / 51% 100% no-repeat;
}
.ticket__top { display: flex; justify-content: space-between; align-items: baseline; padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.ticket__brand { font: 500 30px/1 var(--serif); letter-spacing: .1em; }
.ticket__kind { font-size: 14px; color: var(--gold); font-weight: 500; }

.ticket__rows { display: grid; grid-template-columns: 1fr 1fr; gap: 22px 18px; padding-top: 24px; }
.row { display: grid; gap: 4px; min-width: 0; }
.row--wide { grid-column: 1 / -1; }
.row dt { font-size: 13px; color: var(--mist); }
.row dd { font: 500 clamp(22px, 2.4vw, 30px)/1.15 var(--serif); overflow-wrap: anywhere; transition: color .3s; }
.row dd.is-empty { color: rgba(221, 225, 236, .38); }
.row dd.is-bump { animation: bump .5s var(--ease); }
@keyframes bump { 0% { transform: translateY(6px); opacity: .3; } 100% { transform: none; opacity: 1; } }

.ticket__stub {
  position: absolute; left: 0; right: 0; bottom: 0; height: var(--stub);
  display: grid; align-content: center; gap: 12px;
  padding: 0 30px;
  border-top: 2px dashed rgba(221, 225, 236, .22);
}
.barcode {
  height: 42px;
  background: repeating-linear-gradient(90deg,
    var(--silver) 0 2px, transparent 2px 5px,
    var(--silver) 5px 6px, transparent 6px 10px,
    var(--silver) 10px 13px, transparent 13px 15px,
    var(--silver) 15px 16px, transparent 16px 20px);
  opacity: .78;
}
.ticket__code { font: 400 12px/1 var(--mono); color: var(--mist); }

/* ---------- Galería ---------- */

.gallery { padding-block: clamp(60px, 9vw, 140px) clamp(40px, 6vw, 80px); }
.gallery__intro { margin-top: 22px; font-size: 19px; color: var(--mist); }

.reel {
  display: flex; align-items: flex-start; gap: clamp(14px, 2vw, 26px);
  margin-top: clamp(40px, 6vw, 80px);
  padding: 10px var(--gutter) 34px;
  overflow-x: auto;
  scroll-snap-type: x proximity;
  scrollbar-width: none;
  cursor: grab;
}
.reel::-webkit-scrollbar { display: none; }
.reel.is-drag { cursor: grabbing; scroll-snap-type: none; }

.tile { flex: 0 0 clamp(230px, 26vw, 340px); scroll-snap-align: center; user-select: none; }
.tile__art {
  position: relative;
  aspect-ratio: 3 / 4.4;
  border-radius: 999px 999px 26px 26px;
  border: 1px solid rgba(221, 225, 236, .18);
  overflow: hidden;
  transition: transform .6s var(--ease), border-color .4s;
}
.tile:hover .tile__art { transform: translateY(-8px); border-color: rgba(227, 184, 102, .6); }
.tile:nth-child(even) { margin-top: clamp(30px, 5vw, 70px); }
.tile:nth-child(3n) .tile__art { aspect-ratio: 3 / 5; }

/* Mientras carga la foto se ve el azul noche */
.tile__art { background: linear-gradient(180deg, #0a1029, #121b3d); }
.tile__art img {
  width: 100%; height: 100%;
  object-fit: cover;
  -webkit-user-drag: none; user-select: none;
  transition: transform 1.2s var(--ease);
}
.tile:hover .tile__art img { transform: scale(1.05); }

.tile figcaption { margin-top: 14px; font-size: 14px; color: var(--mist); padding-inline: 6px; }

.gallery__foot { margin-top: 10px; }

/* ---------- Políticas ---------- */

.policy { padding-block: clamp(40px, 6vw, 90px); }
.policy__card {
  display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 8px 40px;
  padding: clamp(28px, 4vw, 52px);
  border: 1px solid var(--line);
  border-radius: 28px;
  background: linear-gradient(120deg, rgba(18, 27, 61, .75), rgba(10, 16, 40, .55));
}
.policy__card .h3 { grid-column: 1; }
.policy__card p { grid-column: 1; color: var(--mist); }
.policy__card .btn { grid-column: 2; grid-row: 1 / span 2; }

/* ---------- Cierre ---------- */

.finale { padding-block: clamp(100px, 16vw, 240px) clamp(80px, 12vw, 160px); text-align: center; }
.finale__title {
  font: 500 clamp(56px, 13vw, 220px)/.92 var(--serif);
  letter-spacing: -.035em;
  background: linear-gradient(180deg, var(--silver) 30%, rgba(221, 225, 236, .25));
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
}
.finale__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; margin-top: clamp(36px, 5vw, 64px); }

/* ---------- Pie ---------- */

.foot { border-top: 1px solid var(--line); background: rgba(6, 10, 26, .75); padding-top: clamp(44px, 6vw, 80px); }
.foot__grid { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 36px; }
.foot__brand { font: 500 32px/1 var(--serif); letter-spacing: .12em; margin-bottom: 14px; }
.foot__text { max-width: 30ch; color: var(--mist); }
.foot__social { display: flex; flex-wrap: wrap; gap: 14px 28px; align-items: flex-start; }
.foot__social a { display: inline-flex; align-items: center; gap: 10px; font-weight: 500; opacity: .85; transition: opacity .25s, color .25s; }
.foot__social a:hover { opacity: 1; color: var(--gold-hi); }
.foot__social svg { width: 22px; height: 22px; }
.foot__legal { padding-block: 44px 34px; color: var(--mist); }
.foot__legal small { font-size: 13px; }

.wa-float {
  position: fixed; right: 18px; bottom: 18px; z-index: 55;
  display: grid; place-items: center;
  width: 56px; height: 56px; border-radius: 50%;
  background: rgba(8, 13, 32, .85);
  border: 1px solid rgba(227, 184, 102, .55);
  color: var(--gold-hi);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  transition: transform .35s var(--ease), box-shadow .3s;
}
.wa-float:hover { transform: scale(1.07); box-shadow: 0 0 28px rgba(227, 184, 102, .45); }
.wa-float svg { width: 28px; height: 28px; }

/* ==========================================================================
   Responsive
   ========================================================================== */

/* ---------- Constelaciones ---------- */

.cst { display: block; width: 100%; height: auto; overflow: visible; }

.cline {
  fill: none; stroke: rgba(248, 227, 171, .66); stroke-width: 1.4; stroke-linecap: round;
  stroke-dasharray: 1; stroke-dashoffset: 1;
}
.cstar .halo { fill: url(#halo); pointer-events: none; }
.cstar .core { fill: #fff6dc; }
.cstar .hit { fill: transparent; }

.clabel {
  font: italic 500 19px var(--serif);
  fill: var(--gold-hi);
  paint-order: stroke; stroke: var(--night); stroke-width: 5px; stroke-linejoin: round;
  opacity: 0; transition: opacity .25s ease;
  pointer-events: none;
}
.cstar:hover .clabel { opacity: 1; }

.const { position: relative; }
.const .cstar { opacity: .2; }
.const__name { display: block; margin-top: 10px; font: italic 400 19px/1 var(--serif); color: var(--mist); }

.manifesto .wrap { position: relative; }
.const--orion { position: absolute; right: var(--gutter); top: 50%; width: clamp(170px, 19vw, 280px); transform: translateY(-50%); }
.const--orion .const__name, .const--cassio .const__name { text-align: center; }

.gallery__head { position: relative; }
.gallery__head .h2 { max-width: 9em; }
.const--dipper { position: absolute; right: 0; bottom: 0; width: clamp(220px, 28vw, 380px); }

.const--cassio { width: clamp(180px, 22vw, 280px); margin: 0 auto 30px; }

/* Birrete de colegios (portada) */
.cap { position: relative; margin: 0; justify-self: center; width: min(100%, 440px); }
.cap .cst { filter: drop-shadow(0 0 24px rgba(227, 184, 102, .14)); }
.cap figcaption {
  margin-top: 18px; text-align: center;
  font: italic 400 clamp(17px, 1.5vw, 20px)/1.3 var(--serif); color: var(--mist);
}
.js .cap figcaption { opacity: 0; }
.is-ready .cap figcaption { opacity: 1; transition: opacity 1s ease 3.6s; }

.js .cap .cline { transition: stroke-dashoffset 1.1s var(--ease) calc(2.1s + var(--i) * .15s); }
.js .cap .cstar { opacity: 0; }
.is-ready .cap .cline { stroke-dashoffset: 0; }
.is-ready .cap .cstar { opacity: 1; transition: opacity .8s ease calc(1.8s + var(--s) * .11s); }

.cap .cstar .core, .cap .cstar .halo { transform-box: fill-box; transform-origin: center; transition: transform .35s var(--ease); }
.cap .cstar .core { transform: scale(calc(1 + var(--g, 0) * 1.3)); }
.cap .cstar .halo { transform: scale(calc(1 + var(--g, 0) * .8)); animation: twinkle calc(3.4s + var(--i) * .43s) ease-in-out 4.2s infinite alternate; }
@keyframes twinkle { from { opacity: .5; } to { opacity: 1; } }

/* Mini constelaciones en la secuencia */
.mini {
  position: absolute; left: 50%; top: 50%;
  width: calc(var(--gap) * 2 - 16px); max-width: 190px;
  transform: translate(-50%, -50%);
  pointer-events: none;
}
.mini .cline { stroke-width: 1.5; transition: stroke-dashoffset 1s var(--ease) .15s; }
.mini .cstar { opacity: .35; transition: opacity .6s ease; }
.mini .cstar:first-child .core { fill: var(--silver); transition: fill .6s; }
.step.is-on .mini .cline { stroke-dashoffset: 0; }
.step.is-on .mini .cstar { opacity: 1; }
.step.is-on .mini .cstar:first-child .core { fill: #fff6dc; }

/* Tu constelación (cotizador) */
.tsky { margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--line); }
.tsky__label { display: flex; justify-content: space-between; align-items: baseline; font-size: 13px; color: var(--mist); }
.tsky__label output { font: 500 13px/1 var(--mono); color: var(--gold-hi); }
.tsky svg { display: block; width: 100%; height: auto; margin-top: 8px; overflow: visible; }
.sstar { cursor: pointer; }
.sstar .core { fill: rgba(221, 225, 236, .42); transition: fill .3s; }
.sstar .halo { fill: url(#halo); opacity: 0; transition: opacity .4s; pointer-events: none; }
.sstar .hit { fill: transparent; }
.sstar:hover .core { fill: rgba(248, 227, 171, .85); }
.sstar.is-lit .core { fill: #fff6dc; }
.sstar.is-lit .halo { opacity: 1; }
.sline {
  fill: none; stroke: var(--gold-hi); stroke-width: 1.5; stroke-linecap: round;
  stroke-dasharray: 1; stroke-dashoffset: 1; opacity: .9;
  animation: drawline .7s var(--ease) forwards;
}
.sline.is-out { opacity: 0; transition: opacity .25s ease; }
@keyframes drawline { to { stroke-dashoffset: 0; } }

#t-extras { font-size: clamp(18px, 1.7vw, 22px); line-height: 1.25; }

@media (max-height: 820px) and (min-width: 961px) {
  .ticket { position: relative; top: 0; }
}

@media (max-width: 1000px) {
  .hero__inner { grid-template-columns: minmax(0, 1fr); row-gap: 10px; }
  .cap { order: -1; width: min(60vw, 400px); justify-self: start; }
}

@media (max-width: 960px) {
  .quote__grid { grid-template-columns: 1fr; }
  .ticket { position: relative; top: 0; }
  .policy__card { grid-template-columns: 1fr; }
  .policy__card .btn { grid-column: 1; grid-row: auto; justify-self: start; margin-top: 14px; }
}

@media (max-width: 760px) {
  body { font-size: 16px; }

  .nav { padding: 8px 8px 8px 20px; gap: 12px; }
  .nav__links {
    position: absolute; top: calc(100% + 10px); left: 0; right: 0;
    flex-direction: column; gap: 4px; margin: 0;
    padding: 14px;
    border-radius: 24px; border: 1px solid var(--line);
    background: rgba(6, 10, 26, .98);
    -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
    opacity: 0; visibility: hidden; transform: translateY(-8px);
    transition: opacity .3s, transform .4s var(--ease), visibility .3s;
  }
  .nav__links a { padding: 14px 16px; font-size: 18px; border-radius: 14px; opacity: 1; }
  .nav__links a:hover { background: rgba(221, 225, 236, .06); }
  .nav.is-open .nav__links { opacity: 1; visibility: visible; transform: none; }
  .nav__cta { margin-left: auto; padding: 11px 20px; }

  .burger {
    display: grid; place-content: center; gap: 6px;
    width: 44px; height: 44px; padding: 0;
    border: 1px solid var(--line); border-radius: 50%;
    background: transparent; cursor: pointer;
  }
  .burger span { display: block; width: 18px; height: 1.5px; background: var(--silver); transition: transform .35s var(--ease); }
  .nav.is-open .burger span:first-child { transform: translateY(3.75px) rotate(45deg); }
  .nav.is-open .burger span:last-child  { transform: translateY(-3.75px) rotate(-45deg); }

  .hero { padding-top: 130px; padding-bottom: 110px; align-items: flex-end; }
  .hero__hud { bottom: 26px; font-size: 11px; }
  .hero__hud span:first-child { display: none; }
  .cap { width: min(66vw, 270px); justify-self: start; margin-left: 2vw; }
  .cap figcaption { font-size: 16px; }
  .mini { display: none; }
  .const--orion { position: relative; right: auto; top: auto; transform: none; width: 150px; margin: 0 0 34px auto; }
  .manifesto__text { max-width: none; }
  .gallery__head .h2 { max-width: none; }
  .const--dipper { position: relative; width: min(78vw, 300px); margin-top: 26px; }

  /* Secuencia en una sola columna con la línea a la izquierda */
  .seq__line, .seq__fill { left: 10px; }
  .seq__star { left: 10px; width: 22px; height: 22px; }
  .step { grid-template-columns: 1fr; min-height: 0; padding: 0 0 54px 44px; gap: 10px; align-items: start; }
  .step:nth-child(n) .step__t,
  .step:nth-child(n) .step__body { grid-column: 1; grid-row: auto; text-align: left; padding: 0; justify-self: start; align-items: flex-start; }
  .step:nth-child(n) .step__t { flex-direction: row; align-items: baseline; gap: 12px; }
  .step:nth-child(n) .step__body p { margin-left: 0; }
  .step__num { font-size: 56px; }

  .ticket { padding-inline: 22px; }
  .ticket__stub { padding-inline: 22px; }

  .tile { flex-basis: 62vw; }
  .wa-float { width: 52px; height: 52px; right: 14px; bottom: 14px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .ticker__track { animation: none; }
  .js .ln > span, .js .hero__lead, .js .hero__actions { transform: none; opacity: 1; }
  .ln--go > span { background-position: 100% 0; }
  .cap__flare { display: none; }
  .cline { stroke-dashoffset: 0 !important; }
  .cstar { opacity: 1 !important; }
  .cap figcaption { opacity: 1 !important; }
  .cap .cstar .halo { animation: none; }
  .step { opacity: 1; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

/* ---------- Fotografía de ambiente (portada y cierre) ---------- */

.hero__photo, .finale__photo {
  position: absolute; inset: 0; z-index: 0;
  overflow: hidden; pointer-events: none;
}
.hero__photo img, .finale__photo img { width: 100%; height: 100%; object-fit: cover; }

.hero__photo img { object-position: 50% 45%; opacity: .62; }
.hero__photo::after {
  content: "";
  position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(6, 10, 26, .92) 0%, rgba(6, 10, 26, .6) 36%, rgba(6, 10, 26, .12) 72%, rgba(6, 10, 26, .3) 100%),
    linear-gradient(180deg, rgba(6, 10, 26, .6) 0%, transparent 24%, transparent 58%, var(--night) 100%);
}

.finale { position: relative; overflow: clip; }
.finale > .wrap { position: relative; z-index: 1; }
.finale__photo img { opacity: .4; object-position: 50% 50%; }
.finale__photo::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, var(--night) 0%, rgba(6, 10, 26, .15) 32%, rgba(6, 10, 26, .25) 62%, rgba(6, 10, 26, .92) 100%);
}

@media (max-width: 960px) {
  .hero__photo img { object-position: 60% 50%; opacity: .6; }
  .hero__photo::after {
    background:
      linear-gradient(180deg, rgba(6, 10, 26, .72) 0%, rgba(6, 10, 26, .3) 30%, rgba(6, 10, 26, .8) 58%, rgba(6, 10, 26, .88) 80%, var(--night) 100%);
  }
}
