/* =====================================================================
   AeroCaptura — "E . Sala de Proyección"
   A private cinema room: the footage is the only light source,
   the page is the dark room. Lives on typographic precision and
   vertical rhythm. 8px base grid throughout.
   ===================================================================== */

:root {
  /* ---- Palette ---- */
  --proyeccion:   #0A0A0B; /* projection black — main background */
  --grafito:      #141416; /* graphite panel — elevated surfaces */
  --niebla:       #9A9AA0; /* fog — secondary text (≈5.2:1 on black, AA) */
  --niebla-hair:  #6E6E73; /* fog 60 — non-textual hairlines / dividers */
  --niebla-dim:   #43434780; /* hairline divider, very low */
  --proyector:    #F4F2ED; /* projector white — primary text, title */
  --ambar:        #C8852F; /* latent amber — the single, contained accent */
  --ambar-soft:   #c8852f33;
  --indigo:       #3A4A66; /* projection indigo — cold secondary, the beam */
  --focus-ring:   #8AA0CE; /* lightened indigo for focus (≥3:1 on black, WCAG 1.4.11) */

  /* ---- Type ---- */
  --display: "Unbounded", system-ui, sans-serif;
  --body:    "Inter", system-ui, -apple-system, sans-serif;
  --mono:    "IBM Plex Mono", ui-monospace, "SFMono-Regular", monospace;

  /* ---- Rhythm ---- */
  --gutter: clamp(1.25rem, 5vw, 4rem);
  --maxw: 1200px;
  --measure: 60ch;
  --section-pad: clamp(6rem, 14vh, 11rem);

  /* ---- Motion ---- */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --reveal-shift: 14px;
}

/* ===================== Reset & base ===================== */
*,
*::before,
*::after { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--proyeccion);
  color: var(--proyector);
  font-family: var(--body);
  font-size: clamp(1rem, 0.96rem + 0.2vw, 1.0625rem);
  line-height: 1.7;
  letter-spacing: 0.01em;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img,
svg { display: block; max-width: 100%; }

a { color: inherit; }

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

h1, h2, h3 {
  font-family: var(--display);
  font-weight: 300;
  letter-spacing: -0.015em;
  line-height: 1.02;
  margin: 0;
  color: var(--proyector);
}

p { margin: 0; }

::selection {
  background: var(--ambar);
  color: var(--proyeccion);
}

/* ===================== Shared helpers ===================== */
.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.mono {
  font-family: var(--mono);
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.75rem;
  color: var(--niebla);
}

.lede {
  font-size: clamp(1.0625rem, 1rem + 0.4vw, 1.25rem);
  line-height: 1.7;
  max-width: var(--measure);
  color: var(--proyector);
  font-weight: 400;
}
.lede__cue {
  font-family: var(--display);
  font-weight: 400;
  color: var(--ambar);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 200;
  background: var(--proyector);
  color: var(--proyeccion);
  padding: 0.75rem 1.25rem;
  font-family: var(--mono);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  text-decoration: none;
}
.skip-link:focus { left: 1rem; top: 1rem; }

:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 3px;
  border-radius: 1px;
  /* Dark inner ring so the indicator separates on light surfaces too */
  box-shadow: 0 0 0 1px rgba(10, 10, 11, 0.9);
}

/* ===================== The projection beam ===================== */
.beam {
  position: fixed;
  inset: 0 0 auto 0;
  height: 90vh;
  z-index: 0;
  pointer-events: none;
  opacity: 0.62; /* resting value; the breathe animation oscillates around it */
  background:
    radial-gradient(120% 80% at 50% -20%,
      rgba(58, 74, 102, 0.17) 0%,
      rgba(58, 74, 102, 0.08) 32%,
      transparent 62%);
  animation: beam-breathe 8s ease-in-out infinite;
}

@keyframes beam-breathe {
  0%, 100% { opacity: 0.45; }
  50%      { opacity: 0.8; }
}

/* ===================== Header ===================== */
.site-header {
  position: fixed;
  top: 0;
  inset-inline: 0;
  z-index: 100;
  transition: background-color 0.4s ease, border-color 0.4s ease;
  border-bottom: 1px solid transparent;
}
.site-header[data-scrolled="true"] {
  background: rgba(10, 10, 11, 0.78);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border-bottom-color: var(--niebla-dim);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  text-decoration: none;
  color: var(--proyector);
}
.brand__mark { width: 30px; height: 30px; opacity: 0.95; }
.brand__name {
  font-family: var(--display);
  font-weight: 400;
  font-size: 1.1875rem;
  letter-spacing: -0.01em;
}

/* ---- Nav ---- */
.nav__menu {
  display: flex;
  align-items: center;
  gap: clamp(1.25rem, 2.5vw, 2.25rem);
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav__link {
  font-family: var(--mono);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--niebla);
  text-decoration: none;
  padding: 0.5rem 0;
  position: relative;
  transition: color 0.3s ease;
}
.nav__link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 1px;
  background: var(--ambar);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--ease-out);
}
.nav__link:hover,
.nav__link:focus-visible { color: var(--proyector); }
.nav__link:hover::after,
.nav__link:focus-visible::after,
.nav__link[aria-current="true"]::after { transform: scaleX(1); }
.nav__link[aria-current="true"] { color: var(--proyector); }

/* Persistent amber "Cotizar" CTA — contracting is always one click away */
.nav__cta {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0.5rem 1.05rem;
  font-family: var(--mono);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  text-decoration: none;
  color: var(--ambar);
  border: 1px solid var(--ambar);
  border-radius: 1px;
  transition: background-color 0.35s var(--ease-out), color 0.35s var(--ease-out);
}
.nav__cta:hover,
.nav__cta:focus-visible {
  background: var(--ambar);
  color: var(--proyeccion);
}

.nav__toggle {
  display: none;
  width: 44px;
  height: 44px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.nav__toggle-bar {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--proyector);
  transition: transform 0.35s var(--ease-out), opacity 0.2s ease;
}
.nav__toggle[aria-expanded="true"] .nav__toggle-bar:nth-child(1) {
  transform: translateY(3.75px) rotate(45deg);
}
.nav__toggle[aria-expanded="true"] .nav__toggle-bar:nth-child(2) {
  transform: translateY(-3.75px) rotate(-45deg);
}

/* ===================== HERO ===================== */
.hero {
  position: relative;
  z-index: 1;
  min-height: 100svh;
  outline: none; /* skip-link lands focus here; no ring on the whole plate */
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 6rem 0 clamp(5rem, 12vh, 8rem);
  overflow: hidden;
}

/* ---- Hero footage (letterbox bars come from .letterbox) ---- */
.hero .hero__media {
  position: absolute;
  inset: 0;
  z-index: 0;
  padding-block: clamp(14px, 3.5%, 40px); /* projection bars (inherited look) */
  background: #000;
  pointer-events: none;
}
.hero__video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* sala apagada: the clip enters dimmed like a cinema screen */
  filter: saturate(1.05) contrast(1.04) brightness(0.82);
}
/* Vertical projection scrim: darkens the top (header) and the bottom ~half
   (plate) so text holds AA over the footage regardless of the clip's own
   brightness. The lower stops are hardened (≥0.62 from 60% down) so the
   amber overline, fog subhead and mono marker/credential clear 4.5:1 even on
   a bright frame — the band no longer dips into the unreadable 0.18–0.30 zone
   where the plate text actually lives. */
.hero__scrim {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(
      to bottom,
      rgba(10, 10, 11, 0.74) 0%,
      rgba(10, 10, 11, 0.34) 24%,
      rgba(10, 10, 11, 0.30) 46%,
      rgba(10, 10, 11, 0.62) 60%,
      rgba(10, 10, 11, 0.82) 78%,
      rgba(10, 10, 11, 0.94) 100%);
}

/* ---- Plate, anchored bottom-left to the container column ---- */
.hero__container {
  position: relative;
  z-index: 2;
  width: 100%;
}

/* Defensive dark halo on the secondary text over the footage: the scrim does
   the heavy lifting, but a single low-spread shadow guarantees legibility on a
   bright frame without reading as a drop shadow (kept subtle, AA insurance). */
.hero__marker,
.hero__overline,
.hero__subhead,
.hero__credential {
  text-shadow: 0 1px 3px rgba(10, 10, 11, 0.7);
}

.hero__marker {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  color: var(--proyector);
  margin-bottom: clamp(1.25rem, 4vh, 2.25rem);
}
.hero__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ambar);
  box-shadow: 0 0 0 0 rgba(200, 133, 47, 0.55);
  animation: hero-pulse 2.2s ease-in-out infinite;
}
@keyframes hero-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(200, 133, 47, 0.5); opacity: 1; }
  50%      { box-shadow: 0 0 0 6px rgba(200, 133, 47, 0); opacity: 0.6; }
}

.hero__plate {
  max-width: 52rem;
}

.hero__overline {
  color: var(--ambar);
  margin-bottom: clamp(1rem, 2.5vh, 1.5rem);
}

.hero__title {
  font-family: var(--display);
  font-weight: 300;
  font-size: clamp(2.4rem, 6vw, 4.6rem);
  line-height: 1.04;
  letter-spacing: -0.02em;
  font-optical-sizing: auto;
  color: var(--proyector);
  margin: 0;
  text-wrap: balance;
}

.hero__subhead {
  margin-top: clamp(1.25rem, 3vh, 1.75rem);
  max-width: 46ch;
  font-size: clamp(1.0625rem, 1rem + 0.4vw, 1.1875rem);
  line-height: 1.6;
  color: var(--niebla);
}

.hero__ctas {
  margin-top: clamp(1.75rem, 4vh, 2.5rem);
  display: flex;
  flex-wrap: wrap;
  gap: 0.875rem;
}

.hero__credential {
  margin-top: clamp(1.75rem, 4vh, 2.5rem);
  padding-top: 1.5rem;
  border-top: 1px solid var(--niebla-dim);
  color: var(--niebla);
}

/* ---- Scroll cue, degraded to bottom-right ---- */
.hero__scroll {
  position: absolute;
  z-index: 2;
  bottom: clamp(1.5rem, 4vh, 2.5rem);
  right: var(--gutter);
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  color: var(--niebla);
  font-size: 0.625rem;
  letter-spacing: 0.18em;
  transition: color 0.3s ease;
}
.hero__scroll:hover,
.hero__scroll:focus-visible { color: var(--proyector); }

/* ---- Cinematic intro: footage loops twice → fades to black → the brand
   lockup (logo + AeroCaptura) appears centred at the top and STAYS. The hero
   plate text is visible the whole time: the veil sits BELOW the text. ---- */
.hero__veil {
  position: absolute;
  inset: 0;
  z-index: 1;                     /* over the footage, under the text */
  background: var(--proyeccion);
  opacity: 0;
  pointer-events: none;
  transition: opacity 1s ease;
}
.hero[data-intro="fade"] .hero__veil,
.hero[data-intro="brand"] .hero__veil { opacity: 1; }

/* Logo + wordmark lockup, centred in the clear band above the plate */
.hero__brand {
  position: absolute;
  top: clamp(84px, 12vh, 120px);
  left: 0;
  right: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(0.5rem, 1.3vw, 0.95rem);
  pointer-events: none;
}
.hero__brand-mark {
  width: clamp(44px, 5.5vw, 68px);
  height: auto;
  opacity: 0;
  transform: scale(0.6);
  filter: drop-shadow(0 0 0 rgba(200, 133, 47, 0));
  transition: opacity 0.9s var(--ease-out),
              transform 1.1s var(--ease-out),
              filter 1.1s ease;
}
.hero__brand-name {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(1.3rem, 1rem + 1.4vw, 2.1rem);
  letter-spacing: -0.01em;
  line-height: 1;
  color: var(--proyector);
  opacity: 0;
  transform: translateX(-10px);
  transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out);
  transition-delay: 0.15s;
}
.hero[data-intro="brand"] .hero__brand-mark {
  opacity: 1;
  transform: scale(1);
  filter: drop-shadow(0 0 26px rgba(200, 133, 47, 0.32));
}
.hero[data-intro="brand"] .hero__brand-name {
  opacity: 1;
  transform: none;
}

/* Once the brand has landed, nudge the scroll cue so the way down reads clearly */
.hero[data-intro="brand"] .hero__scroll span {
  display: inline-block;
  animation: scroll-nudge 1.9s ease-in-out infinite;
}
@keyframes scroll-nudge {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(3px); }
}

/* ===================== Buttons (CTA system) ===================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.75rem 1.5rem;
  font-family: var(--mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  text-decoration: none;
  border-radius: 1px;
  transition: background-color 0.35s var(--ease-out),
              color 0.35s var(--ease-out),
              border-color 0.35s var(--ease-out);
}
/* Primary: projector white at rest → amber on hover/focus */
.btn--primary {
  background: var(--proyector);
  color: var(--proyeccion);
  border: 1px solid var(--proyector);
}
.btn--primary:hover,
.btn--primary:focus-visible {
  background: var(--ambar);
  border-color: var(--ambar);
  color: var(--proyeccion);
}
/* Ghost: fog border → projector border on hover */
.btn--ghost {
  background: transparent;
  color: var(--proyector);
  border: 1px solid var(--niebla-hair);
}
.btn--ghost:hover,
.btn--ghost:focus-visible {
  border-color: var(--proyector);
  color: var(--proyector);
}
/* The hero "Ver el showreel" CTA reuses the .facade hook to open the lightbox
   (it is an <a href="#showreel"> so it still navigates with JS disabled), but
   must NOT inherit the facade's block/16:9 media-frame geometry — restore the
   .btn box so it sits inline beside the ghost CTA. */
.btn.facade {
  display: inline-flex;
  position: static;
  width: auto;
  aspect-ratio: auto;
  overflow: visible;
  background: var(--proyector);
}
.btn--primary.facade:hover,
.btn--primary.facade:focus-visible { background: var(--ambar); }

/* ===================== Sections (projection fade-in) ===================== */
.section {
  position: relative;
  z-index: 1;
  padding-block: var(--section-pad);
}
.section + .section { padding-top: 0; }

[data-reveal] {
  opacity: 0;
  transform: translateY(var(--reveal-shift));
  transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out);
}
/* Promote to a compositor layer only while the reveal is animating, then
   drop it (cleared on transitionend in main.js) to avoid lingering layers. */
[data-reveal].is-revealing,
.tile.is-revealing { will-change: opacity, transform; }
[data-reveal].is-visible {
  opacity: 1;
  transform: none;
}

/* ---- Section heads ---- */
.section-head { margin-bottom: clamp(2.5rem, 6vh, 4rem); }
.kicker {
  color: var(--ambar);
  margin-bottom: 1.25rem;
  display: inline-block;
}
.section-title {
  font-size: clamp(2.5rem, 1.5rem + 4vw, 5rem);
  font-weight: 300;
  letter-spacing: -0.02em;
  line-height: 1;
  font-optical-sizing: auto;
}
.section-deck {
  margin-top: 1rem;
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(1.125rem, 1rem + 0.7vw, 1.5rem);
  color: var(--niebla);
}

/* ===================== Letterbox system (the signature) ===================== */
.frame { margin: 0; }

.letterbox {
  position: relative;
  background: #000;
  /* Real projection bars top & bottom */
  padding-block: clamp(14px, 3.5%, 40px);
}
.letterbox::before,
.letterbox::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--niebla-dim);
  pointer-events: none;
}
.letterbox::before { top: 0; }
.letterbox::after  { bottom: 0; }

/* ===================== Showreel ===================== */
.showreel__layout {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: stretch;
}

/* Feature frame: fill the full row height, no letterbox bars */
.frame--feature {
  display: flex;
}
.frame--feature .letterbox {
  width: 100%;
  height: 100%;
  padding-block: 0;
  display: flex;
  flex-direction: column;
}
.frame--feature .letterbox::before,
.frame--feature .letterbox::after { display: none; }
.frame--feature .facade {
  aspect-ratio: unset;
  flex: 1;
  height: 100%;
}
/* Play button pinned to bottom-right corner */
.frame--feature .facade__play {
  top: auto;
  left: auto;
  bottom: 1.25rem;
  right: 1.25rem;
  transform: none;
  width: 60px;
  height: 60px;
}
.frame--feature .facade:hover .facade__play,
.frame--feature .facade:focus-visible .facade__play {
  transform: scale(1.06);
}

.facade {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #000;
  padding: 0;
  margin: 0;
}
.facade__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* sala apagada: footage sits a touch dimmed until engaged */
  filter: brightness(0.82) saturate(1.02);
  transition: filter 0.4s var(--ease-out), transform 0.6s var(--ease-out);
}
.facade__play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 72px;
  height: 72px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--proyector);
  background: rgba(10, 10, 11, 0.35);
  border: 1px solid rgba(244, 242, 237, 0.6);
  -webkit-backdrop-filter: blur(2px);
  backdrop-filter: blur(2px);
  transition: background-color 0.4s ease, border-color 0.4s ease, transform 0.4s var(--ease-out);
}
.facade__play svg { margin-left: 3px; }
.facade:hover .facade__img,
.facade:focus-visible .facade__img { filter: brightness(1) saturate(1.05); transform: scale(1.015); }
.facade:hover .facade__play,
.facade:focus-visible .facade__play {
  background: rgba(200, 133, 47, 0.92);
  border-color: var(--ambar);
  color: var(--proyeccion);
  transform: translate(-50%, -50%) scale(1.06);
}

.showreel__notes { padding-block: 0.5rem; }
.filmstrip {
  margin-top: 2rem;
  border-top: 1px solid var(--niebla-dim);
}
.filmstrip__row {
  display: flex;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 0.875rem 0;
  border-bottom: 1px solid var(--niebla-dim);
}
.filmstrip__row dt { color: var(--niebla); }
.filmstrip__row dd { margin: 0; color: var(--proyector); text-align: right; }

/* ===================== Proceso — comparator ===================== */
.proceso__layout {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}

/* Remove letterbox bars so the 1:1 frame is a clean square */
.compare > .letterbox {
  padding-block: 0;
}
.compare > .letterbox::before,
.compare > .letterbox::after { display: none; }

.compare { user-select: none; }
.compare__stage {
  position: relative;
  width: 100%;
  /* The RAW/GRADED pair is exported square (1080×1080); match it so the
     color section is never cropped (~43% lost under 16/9 cover). */
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: #000;
  touch-action: pan-y;
  --compare: 50%; /* JS-driven wipe position; no-JS shows a centered split */
}
.compare__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  -webkit-user-drag: none;
  user-select: none;
}
/* The GRADED layer sits on top and is revealed from the left via clip-path,
   driven by --compare from JS. RAW is the base layer (no clip).
   This keeps both halves at the exact same scale/encuadre while wiping. */
.compare__img--graded {
  clip-path: inset(0 calc(100% - var(--compare, 50%)) 0 0);
}

.compare__tag {
  position: absolute;
  bottom: 14px;
  font-size: 0.625rem;
  letter-spacing: 0.14em;
  padding: 0.45rem 0.7rem;
  background: rgba(10, 10, 11, 0.6);
  color: var(--proyector);
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
  pointer-events: none;
}
.compare__tag--graded { left: 14px; }
.compare__tag--raw { right: 14px; }

.compare__handle {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 0;
  transform: translateX(-50%);
  pointer-events: none;
}
.compare__handle-line {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 2px;
  transform: translateX(-50%);
  background: var(--proyector);
  mix-blend-mode: difference;
}
.compare__handle-grip {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--proyeccion);
  background: var(--proyector);
  box-shadow: 0 2px 16px rgba(0,0,0,0.45);
}

.compare__range {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: ew-resize;
  -webkit-appearance: none;
  appearance: none;
  background: transparent;
}
.compare__range::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 46px;
  height: 100%;
  cursor: ew-resize;
}
.compare__range::-moz-range-thumb {
  width: 46px;
  height: 100%;
  border: none;
  background: transparent;
  cursor: ew-resize;
}
/* When the (visually hidden) range receives keyboard focus, surface a
   high-contrast ring on the handle grip so the control reads as focused. */
.compare:focus-within .compare__handle-grip {
  outline: 3px solid var(--focus-ring);
  outline-offset: 3px;
  box-shadow: 0 2px 16px rgba(0,0,0,0.45), 0 0 0 1px rgba(10, 10, 11, 0.9);
}

.proceso__notes { padding-block: 0.5rem; }

/* ---- Spec lists (mono, dotted ficha-técnica) ---- */
.spec-list {
  list-style: none;
  margin: 2rem 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 0;
  align-items: center;
}
.spec-list li {
  display: inline-flex;
  align-items: center;
  color: var(--niebla);
  font-size: 0.6875rem;
}
.spec-list li:not(:last-child)::after {
  content: "·";
  margin: 0 0.6rem;
  color: var(--ambar);
}

/* ===================== Portafolio grid ===================== */
.grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(2.5rem, 5vw, 5rem) clamp(2rem, 4vw, 4rem);
}

.tile {
  opacity: 0;
  transform: translateY(var(--reveal-shift));
  transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
}
.tile.is-visible { opacity: 1; transform: none; }

.tile__index {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  margin-bottom: 0.875rem;
}
.tile__num {
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  color: var(--ambar);
  font-variant-numeric: tabular-nums;
}
.tile__rule {
  flex: 1;
  height: 1px;
  background: var(--niebla-dim);
}

.tile .facade {
  /* frame floats in black: no border, no shadow */
  aspect-ratio: 16 / 9;
}
.tile .facade::after {
  /* the amber hairline that appears on hover */
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 2px;
  background: var(--ambar);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s var(--ease-out);
  z-index: 2;
}
.tile .facade:hover::after,
.tile .facade:focus-visible::after { transform: scaleX(1); }
.tile .facade__play {
  width: 56px;
  height: 56px;
}

.tile__meta {
  margin-top: 1.125rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}
.tile__title {
  font-family: var(--display);
  font-weight: 400;
  font-size: 1.125rem;
  letter-spacing: -0.01em;
  line-height: 1.25;
  color: var(--proyector);
}
.tile__place {
  font-family: var(--mono);
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--niebla);
}

.noscript-note { margin-top: 2rem; color: var(--niebla); }

/* ===================== Nosotros — Nota de director ===================== */
/* Title-card treatment: the director's name is the protagonist, projected on
   the dark room like an opening credit. The credit overline, role, note and
   principles are the supporting cast. */
.director { max-width: 100%; }

.director__credit {
  color: var(--ambar);
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
  margin-bottom: clamp(1.25rem, 3vh, 2rem);
}
.director__credit::before {
  content: "";
  width: clamp(1.75rem, 5vw, 3.25rem);
  height: 1px;
  background: currentColor;
}

.director__name {
  font-family: var(--display);
  font-optical-sizing: auto;
  font-weight: 400;
  letter-spacing: -0.035em;
  line-height: 0.9;
  margin: 0;
  display: grid;
}
.director__given,
.director__family {
  font-size: clamp(2.25rem, 1rem + 8vw, 7.5rem);
}
.director__given { color: var(--proyector); }
/* Surname projected as an outline — it fills with light when the name is read. */
.director__family {
  color: transparent;
  -webkit-text-stroke: 1.5px var(--proyector);
  transition: color 0.6s var(--ease-out);
}
.director:hover .director__family { color: var(--proyector); }

.director__role {
  color: var(--niebla);
  margin-top: clamp(1.25rem, 2.5vh, 1.75rem);
}

.director__grid {
  margin-top: clamp(2.5rem, 6vh, 4.5rem);
  padding-top: clamp(2.25rem, 5vh, 3.5rem);
  border-top: 1px solid var(--niebla-dim);
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: start;
}

.director__lead {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(1.375rem, 1.1rem + 1.2vw, 1.875rem);
  line-height: 1.35;
  letter-spacing: -0.015em;
  color: var(--proyector);
  max-width: 24ch;
}
.director__prose {
  margin-top: 1.5rem;
  font-size: clamp(1.0625rem, 1rem + 0.4vw, 1.1875rem);
  line-height: 1.7;
  color: var(--niebla);
  max-width: var(--measure);
}

.principles {
  list-style: none;
  margin: 0;
  padding: 0;
}
.principles li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1.25rem;
  align-items: baseline;
  padding: 1.125rem 0;
  border-bottom: 1px solid var(--niebla-dim);
}
.principles li:first-child { padding-top: 0; }
.principles__num {
  color: var(--ambar);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  font-variant-numeric: tabular-nums;
}
.principles__text {
  font-family: var(--body);
  text-transform: none;
  letter-spacing: 0.01em;
  font-size: 0.9375rem;
  color: var(--proyector);
  line-height: 1.55;
}

/* ===================== Equipo ===================== */
/* ---- Intro: drone render + wordmark + pitch ---- */
.equipo__intro {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
}
.equipo__image { margin: 0; }
.equipo__image img {
  width: 100%;
  height: auto;
  object-fit: contain;
  filter: brightness(0.96);
}
.equipo__lead { max-width: 46ch; }
.equipo__wordmark {
  width: clamp(180px, 55%, 260px);
  height: auto;
  margin-bottom: 1.75rem;
}
.equipo__pitch {
  font-size: clamp(1.0625rem, 1rem + 0.45vw, 1.3125rem);
  line-height: 1.6;
  color: var(--proyector);
}
.equipo__pitch em {
  font-family: var(--display);
  color: var(--ambar);
}

/* ---- Stat bar: the four headline numbers ---- */
.statbar {
  list-style: none;
  margin: clamp(3rem, 7vh, 5rem) 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-block: 1px solid var(--niebla-dim);
}
.statbar__item {
  padding: clamp(1.5rem, 3vw, 2.25rem) clamp(1rem, 2.2vw, 1.75rem);
  border-left: 1px solid var(--niebla-dim);
}
.statbar__item:first-child { border-left: none; }
.statbar__label {
  color: var(--ambar);
  margin: 0 0 0.85rem;
}
.statbar__value {
  font-family: var(--display);
  font-weight: 300;
  font-optical-sizing: auto;
  font-size: clamp(2.75rem, 1.6rem + 4.4vw, 4.5rem);
  line-height: 0.9;
  letter-spacing: -0.02em;
  color: var(--proyector);
  font-variant-numeric: tabular-nums;
  display: flex;
  align-items: baseline;
  gap: 0.18em;
}
.statbar__suffix {
  font-size: 0.34em;
  font-family: var(--mono);
  letter-spacing: 0.08em;
  color: var(--niebla);
  transform: translateY(-0.15em);
}
.statbar__unit {
  margin: 0.9rem 0 0;
  text-transform: none;
  letter-spacing: 0.04em;
  font-size: 0.7rem;
  color: var(--niebla-hair);
}

/* ---- Spec grid: four grouped panels ---- */
.specgrid {
  margin-top: clamp(2.5rem, 6vh, 4rem);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(1rem, 2vw, 1.5rem);
}
.specgroup {
  background: var(--grafito);
  border-top: 1px solid var(--ambar);
  padding: clamp(1.5rem, 3vw, 2.25rem);
}
.specgroup__title {
  font-family: var(--display);
  font-weight: 300;
  font-size: clamp(1.375rem, 1.1rem + 1vw, 1.75rem);
  letter-spacing: -0.015em;
  margin-bottom: 1.25rem;
}
.specgroup__list { margin: 0; }
.specgroup__row {
  display: grid;
  grid-template-columns: minmax(0, auto) minmax(0, 1fr);
  gap: 1.25rem;
  align-items: baseline;
  padding: 0.85rem 0;
  border-top: 1px solid var(--niebla-dim);
}
.specgroup__row:first-child { border-top: none; padding-top: 0; }
.specgroup__row dt {
  color: var(--niebla);
  white-space: nowrap;
}
.specgroup__row dd {
  margin: 0;
  color: var(--proyector);
  text-align: right;
  letter-spacing: 0.04em;
  line-height: 1.5;
  text-transform: none;
}

/* ===================== Contacto ===================== */
.contacto { text-align: center; }
.contacto__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.contacto .kicker { margin-bottom: 1.75rem; }
.contacto__title {
  font-family: var(--display);
  font-weight: 300;
  font-size: clamp(4rem, 2rem + 9vw, 9rem);
  line-height: 0.95;
  letter-spacing: -0.03em;
  color: var(--proyector);
  font-optical-sizing: auto;
}
.contacto__email {
  margin-top: clamp(1.75rem, 4vh, 2.75rem);
  font-size: clamp(1.125rem, 1rem + 0.8vw, 1.5rem);
  color: var(--ambar);
  text-decoration: none;
  background-image: linear-gradient(var(--ambar), var(--ambar));
  background-repeat: no-repeat;
  background-position: 0 100%;
  background-size: 100% 1px;
  padding-bottom: 3px;
  transition: background-size 0.4s var(--ease-out), color 0.3s ease;
}
.contacto__email:hover,
.contacto__email:focus-visible {
  background-size: 100% 2px;
  color: var(--proyector);
}
.contacto__email:hover { background-image: linear-gradient(var(--proyector), var(--proyector)); }

.contacto__social {
  list-style: none;
  margin: clamp(2.5rem, 6vh, 4rem) 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2rem;
}
.contacto__social a {
  font-family: var(--mono);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--niebla);
  text-decoration: none;
  transition: color 0.3s ease;
}
.contacto__social a:hover,
.contacto__social a:focus-visible { color: var(--proyector); }

/* ===================== Footer ===================== */
.footer {
  position: relative;
  z-index: 1;
  background: var(--grafito);
  border-top: 1px solid var(--niebla-dim);
  padding-block: 3rem;
}
.footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}
.footer__brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
}
.footer__brand .mono { color: var(--ambar); }
.footer__mark { width: 24px; height: 24px; opacity: 0.85; }
.footer__slogan {
  font-family: var(--display);
  font-weight: 400;
  font-size: 1rem;
  color: var(--niebla);
}
.footer__legal { color: var(--niebla); font-size: 0.6875rem; }

/* ===================== Lightbox ===================== */
.lightbox {
  border: none;
  padding: 0;
  margin: auto;
  width: min(92vw, 1280px);
  max-width: 92vw;
  background: transparent;
  color: var(--proyector);
  overflow: visible;
}
.lightbox::backdrop {
  background: rgba(6, 6, 7, 0.92);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}
.lightbox__inner { position: relative; }
.lightbox__close {
  position: absolute;
  top: -52px;
  right: 0;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  color: var(--proyector);
  border: 1px solid var(--niebla-dim);
  border-radius: 50%;
  transition: background-color 0.3s ease, border-color 0.3s ease;
}
.lightbox__close:hover,
.lightbox__close:focus-visible {
  background: var(--ambar);
  color: var(--proyeccion);
  border-color: var(--ambar);
}
.letterbox--player { width: 100%; }
.lightbox__slot {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}
.lightbox__slot iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* Fade the dialog open */
.lightbox[open] { animation: lb-in 0.35s var(--ease-out); }
@keyframes lb-in {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}

/* ===================== Responsive ===================== */
@media (max-width: 920px) {
  .showreel__layout,
  .proceso__layout,
  .director__grid,
  .equipo__intro {
    grid-template-columns: 1fr;
    gap: clamp(2rem, 6vw, 3rem);
  }
  .equipo__image { order: -1; max-width: 480px; margin-inline: auto; }
  .specgrid { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  .nav__toggle { display: flex; }
  .nav__menu {
    position: fixed;
    inset: 72px 0 auto 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    background: rgba(10, 10, 11, 0.97);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--niebla-dim);
    padding: 0.5rem var(--gutter) 1.5rem;
    transform: translateY(-8px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s var(--ease-out), visibility 0.3s;
  }
  .nav__menu[data-open="true"] {
    transform: none;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }
  .nav__menu li { width: 100%; border-bottom: 1px solid var(--niebla-dim); }
  .nav__link {
    display: block;
    width: 100%;
    padding: 1rem 0;
    font-size: 0.8rem;
  }
  .nav__link::after { bottom: 0.6rem; }

  /* CTA gets its own breathing room in the stacked panel */
  .nav__menu li:last-child { border-bottom: none; padding-top: 1rem; }
  .nav__cta {
    width: 100%;
    justify-content: center;
    min-height: 44px;
    font-size: 0.8rem;
  }

  .grid { grid-template-columns: 1fr; gap: 2.75rem; }

  .filmstrip__row {
    flex-direction: column;
    gap: 0.25rem;
  }
  .filmstrip__row dd { text-align: left; }

  /* Spec rows stack so long values get full width */
  .specgroup__row {
    grid-template-columns: 1fr;
    gap: 0.25rem;
  }
  .specgroup__row dt { white-space: normal; }
  .specgroup__row dd { text-align: left; }
}

/* Stat bar reflows to a 2×2 block on narrow screens */
@media (max-width: 640px) {
  .statbar { grid-template-columns: repeat(2, 1fr); }
  .statbar__item:nth-child(odd) { border-left: none; }
  .statbar__item:nth-child(n + 3) { border-top: 1px solid var(--niebla-dim); }
}

@media (max-width: 400px) {
  :root { --gutter: 1.125rem; }
  .hero__ctas .btn { width: 100%; }
}

/* Short viewports (landscape phones): keep the plate readable and let the
   hero grow so the bottom-anchored plate doesn't crowd the footage. */
@media (max-height: 560px) {
  .hero {
    min-height: auto;
    padding-top: 6rem;
    padding-bottom: 2.5rem;
  }
}

/* ===================== Reduced motion ===================== */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  .beam { animation: none; }
  .hero__dot { animation: none; }

  [data-reveal],
  .tile {
    opacity: 1 !important;
    transform: none !important;
  }
}
