/* Lúcida · página de inicio (v1)
   Base: prototipo A, «Luz como atmósfera». Portada: «Tira de reels».
   La luz de Sideralis solo en la portada, el cierre, el contacto y la tilde (el cabezal que avanza con el vídeo).
   Donde se juzga el trabajo, fondo neutro. */

@font-face {
  font-family: "Gambarino";
  src: url("fonts/Gambarino-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "General Sans";
  src: url("fonts/GeneralSans-Variable.woff2") format("woff2");
  font-weight: 200 700;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light;
  /* fondo, tinta, acción */
  --bg: #F9F8FA;
  --surface: #F1EFF3;
  --surface-2: #E9E6EC;
  --surface-3: #E2DEE6;
  --ink: #241820;
  --muted: #5B5359;
  --accent: #5E2F4A;
  --accent-strong: #4A2239;
  --on-accent: #FFFFFF;
  --loading: #E7E4EA;         /* lo que se ve mientras carga un vídeo */
  --field-line: #8E8590;       /* borde de campo: 3,5:1 sobre blanco (WCAG 1.4.11) */
  --field-line-hover: #6F6670;
  /* la luz de Sideralis */
  --lila: #E6DDF2;
  --rosa: #F0DCE6;
  --menta: #DDEEF0;
  --empolvado: #C499AE;
  --violeta: #B9A7DC;         /* solo dentro de la tilde, como en el logo */
  --agua: #9FD1D0;

  --f-display: "Gambarino", "Iowan Old Style", Georgia, serif;
  --f-text: "General Sans", system-ui, -apple-system, "Segoe UI", sans-serif;

  /* cinco tamaños (el del titular lo ajusta script.js para que «Nosotros, el resto.» llene el ancho) */
  --h1: min(calc((100vw - 2 * var(--m)) / 7.1), 21svh, 200px);
  --s2: clamp(40px, 6.2vw, 96px);
  --s3: clamp(22px, 2.2vw, 32px);
  --s4: 18px;
  --s5: 15px;

  --m: clamp(16px, 3.4vw, 48px);
  --gut: clamp(12px, 1.6vw, 24px);
  --section: clamp(80px, 9vw, 136px);
  --radius: 6px;
  --top-h: 84px;
  --reel-w: 64vw;

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.76, 0, 0.24, 1);
  --ease-soft: cubic-bezier(0.33, 1, 0.68, 1);
  --t-press: 140ms;
  --t-hover: 180ms;
  --t-ui: 240ms;
}
@media (min-width: 760px) {
  :root { --reel-w: clamp(200px, min(19vw, 30svh), 300px); }
}
@media (max-width: 759px) {
  :root { --top-h: 68px; --h1: calc((100vw - 2 * var(--m)) / 7.1); }
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--f-text);
  font-size: var(--s4);
  font-weight: 420;
  line-height: 1.55;
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
img, video, svg { display: block; max-width: 100%; }
img, video { height: auto; }
h1, h2, h3, p, ul, ol, figure, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; }
button, select { font: inherit; color: inherit; }
[id] { scroll-margin-top: 24px; }
::selection { background: var(--lila); color: var(--ink); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }

.skip { position: absolute; left: var(--m); top: -100px; z-index: 50; background: var(--accent); color: var(--on-accent); padding: 10px 16px; text-decoration: none; }
.skip:focus { top: 12px; }

.wrap { padding-inline: var(--m); max-width: 1680px; margin-inline: auto; }

.h2 {
  font-family: var(--f-display);
  font-weight: 400;
  font-size: var(--s2);
  line-height: 0.98;
  letter-spacing: -0.025em;
  text-wrap: balance;
}

/* ---------- botones y enlaces ---------- */
.button {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 54px; padding: 0 26px;
  background: var(--accent); color: var(--on-accent);
  border: 0; border-radius: var(--radius);
  font-family: var(--f-text); font-size: 17px; font-weight: 560; letter-spacing: 0.005em;
  text-decoration: none; cursor: pointer;
  transition: transform var(--t-press) var(--ease-out), background-color var(--t-hover) ease;
}
.button:active { transform: scale(0.97); }
.button--small { min-height: 44px; padding: 0 18px; font-size: var(--s5); }
@media (hover: hover) and (pointer: fine) {
  .button:hover { background: var(--accent-strong); }
}

.link {
  background: none; border: 0; padding: 0; cursor: pointer;
  color: var(--ink); font-weight: 520;
  text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 0.25em;
  text-decoration-color: color-mix(in srgb, var(--accent) 45%, transparent);
  transition: text-decoration-color var(--t-hover) ease, color var(--t-hover) ease;
}
@media (hover: hover) and (pointer: fine) {
  .link:hover { color: var(--accent); text-decoration-color: var(--accent); }
}
.link--arrow::after { content: "\2192"; display: inline-block; margin-left: 0.4em; text-decoration: none; transition: transform var(--t-ui) var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .link--arrow:hover::after { transform: translateX(5px); } }

/* ---------- cabecera ---------- */
.top {
  position: absolute; inset: 0 0 auto; z-index: 20;
  height: var(--top-h);
  display: flex; align-items: center; gap: 12px 34px;
  padding: 0 var(--m);
}
.top__logo { display: block; color: var(--ink); width: 104px; margin-right: auto; }
.top__logo svg { width: 100%; height: auto; }
.top__nav { display: flex; gap: 30px; font-size: 16.5px; font-weight: 500; }
.top__nav a { text-decoration: underline; text-decoration-color: transparent; text-decoration-thickness: 1.5px; text-underline-offset: 0.3em; padding: 10px 2px; transition: text-decoration-color var(--t-hover) ease, color var(--t-hover) ease; }
@media (hover: hover) and (pointer: fine) { .top__nav a:hover { text-decoration-color: currentColor; } }

.menu { display: none; position: relative; }
.menu summary {
  list-style: none; cursor: pointer;
  min-height: 44px; display: flex; align-items: center; padding: 0 2px 0 6px;
  font-size: 16px; font-weight: 540;
}
.menu summary::-webkit-details-marker { display: none; }
.menu__cerrar, .menu[open] .menu__abrir { display: none; }
.menu[open] .menu__cerrar { display: inline; }
.menu__lista {
  position: absolute; right: calc(var(--m) * -1); top: calc(100% + 12px);
  width: 100vw; max-width: 390px;
  display: grid; padding: 8px var(--m) 24px;
  background: var(--surface);
}
.menu:not([open]) .menu__lista { display: none; }
.menu__lista a { font-family: var(--f-display); font-size: 34px; line-height: 1.3; text-decoration: none; padding: 4px 0; }
@media (prefers-reduced-motion: no-preference) {
  .menu[open] .menu__lista { animation: drop 260ms var(--ease-out); }
}
@keyframes drop { from { opacity: 0; transform: translateY(-8px); } }

@media (max-width: 899px) {
  /* en el móvil la cabecera se queda arriba: «Pide presupuesto» y «Menú» siempre a mano */
  .top { gap: 14px; position: fixed; transition: background-color var(--t-ui) ease; }
  .top.is-stuck, html:not(.js) .top { background: var(--bg); }
  [id] { scroll-margin-top: calc(var(--top-h) + 16px); }
  .top__logo { width: 88px; }
  .top__nav { display: none; }
  .menu { display: block; }
}

/* ---------- la luz (cielo tornasolado de A) ---------- */
.sky { position: absolute; inset: 0; overflow: hidden; background: var(--bg); pointer-events: none; }
/* la luz va en imagen (img/luz-*.webp, 5-10 KB cada una): el mismo cielo, sin degradados pintados */
.sky__wash {
  position: absolute; inset: -30% -120%;
  background: var(--lila) url("img/luz-cielo-a.webp") center / 100% 100% no-repeat;
  transform: translate3d(-8%, 0, 0);
}
.sky__wash--b {
  inset: -60% -80%;
  opacity: 0.55;
  mix-blend-mode: multiply;
  background: #FFFFFF url("img/luz-cielo-b.webp") center / 100% 100% no-repeat;
  transform: translate3d(6%, 0, 0);
}
.sky__sun {
  position: absolute; inset: -10% -10% 30%;
  background: radial-gradient(70% 55% at 38% 34%, rgba(255,255,255,0.92) 0%, rgba(255,255,255,0.55) 38%, rgba(255,255,255,0) 72%); /* taste-skill-ignore: luz de marca */
}
.sky__floor { position: absolute; inset: auto 0 0 0; height: 46%; background: linear-gradient(to bottom, rgba(249,248,250,0), var(--bg) 82%); } /* taste-skill-ignore: luz de marca */
.sky__top { position: absolute; inset: 0 0 auto 0; height: 34%; background: linear-gradient(to top, rgba(249,248,250,0), var(--bg)); } /* taste-skill-ignore: luz de marca */
.sky--hero { z-index: 0; }
.sky--hero .sky__wash { opacity: 0.62; }
@media (prefers-reduced-motion: no-preference) {
  .sky__wash { animation: drift-a 70s var(--ease-in-out) infinite alternate; }
  .sky__wash--b { animation: drift-b 90s var(--ease-in-out) infinite alternate; }
  .sky__sun { animation: breathe 14s ease-in-out infinite alternate; }
}
@keyframes drift-a { from { transform: translate3d(-8%, 0, 0); } to { transform: translate3d(14%, -3%, 0); } }
@keyframes drift-b { from { transform: translate3d(6%, 2%, 0); } to { transform: translate3d(-12%, -2%, 0); } }
@keyframes breathe { from { opacity: 1; } to { opacity: 0.6; } }
/* «Pausar movimiento»: la luz se queda quieta */
.is-quieto .sky__wash, .is-quieto .sky__sun, .is-quieto .foco { animation-play-state: paused; }
.is-quieto .sweep::before { animation: none; }

/* ---------- la tilde de luz: el cabezal que avanza con el vídeo activo ---------- */
.frame { position: relative; overflow: clip; }
/* va arriba, como la tilde sobre la letra del logo */
.cabezal {
  position: absolute; left: 0; right: 0; top: 0; height: 18px; z-index: 2;
  pointer-events: none; overflow: hidden;
  opacity: 0; transition: opacity 400ms ease;
}
.cabezal__luz {
  position: absolute; left: 0; right: 0; top: 0; height: 7px;
  transform: translateX(calc((var(--p, 0) - 1) * 100%));
  background: linear-gradient(90deg, var(--lila), var(--rosa) 40%, var(--empolvado) 66%, var(--violeta) 86%, var(--agua)); /* taste-skill-ignore: la tilde de luz, firma de la marca */
}
/* el halo: la misma luz, desenfocada, que cae un poco sobre la imagen */
.cabezal::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 7px;
  transform: translateX(calc((var(--p, 0) - 1) * 100%));
  background: linear-gradient(90deg, rgba(230,221,242,0), var(--rosa) 50%, var(--agua)); /* taste-skill-ignore: la tilde de luz */
  filter: blur(6px); opacity: 0.9;
}
/* la punta: un trazo con el ángulo de la tilde del logo */
.cabezal__luz::after {
  content: ""; position: absolute; right: 0; top: 0; bottom: -1px; width: 4px;
  background: #FFFFFF; transform: skewX(-28deg);
}
.is-active > .cabezal, .frame.is-active > .cabezal, .reel.is-active .cabezal, .reel.is-playing .cabezal { opacity: 1; }

/* el barrido de luz con el ángulo de la tilde: al cargar y al cambiar de Episodio a Reel */
.sweep { position: absolute; inset: 0; z-index: 3; overflow: hidden; pointer-events: none; }
.sweep::before {
  content: ""; position: absolute; top: -20%; bottom: -20%; left: 0; width: 22%;
  background: linear-gradient(90deg, rgba(255,255,255,0) 0%, rgba(240,220,230,0.4) 34%, rgba(255,255,255,0.8) 50%, rgba(221,238,240,0.4) 66%, rgba(255,255,255,0) 100%); /* taste-skill-ignore: barrido de luz de marca */
  mix-blend-mode: screen;
  transform: translateX(-130%) skewX(-28deg);
  opacity: 0;
}
@media (prefers-reduced-motion: no-preference) {
  .sweep--load::before { animation: sweep 1600ms var(--ease-in-out) 700ms 1 both; }
  .frame.is-active > .sweep.is-run::before { animation: sweep 1200ms var(--ease-in-out) 1 both; }
}
@keyframes sweep {
  0% { transform: translateX(-130%) skewX(-28deg); opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { transform: translateX(560%) skewX(-28deg); opacity: 0; }
}

/* ---------- portada ---------- */
.hero { position: relative; padding-top: var(--top-h); overflow: clip; }
.hero__text { position: relative; z-index: 1; padding: clamp(10px, 1.6vw, 28px) var(--m) 0; }
.hero__title {
  font-family: var(--f-display); font-weight: 400;
  font-size: var(--h1); line-height: 0.88; letter-spacing: -0.025em;
  font-kerning: normal;
  color: var(--ink);
}
.hero__line { display: block; width: max-content; white-space: nowrap; }
.w { display: inline-block; }
.hero__aside { margin-top: 26px; max-width: 36rem; }
.hero__aside p { text-wrap: pretty; }
.hero__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 24px; margin-top: 24px; }
@media (min-width: 1240px) {
  /* el texto ocupa el hueco a la derecha de «Tú grabas.» y se apoya en su línea de base */
  .hero__aside {
    position: absolute; right: var(--m); top: clamp(10px, 1.6vw, 28px);
    height: calc(var(--h1) * 0.88);
    width: min(35%, 31rem);
    margin: 0;
    display: flex; flex-direction: column; justify-content: flex-end;
    padding-bottom: calc(var(--h1) * 0.06);
  }
  .hero__actions { margin-top: 20px; }
}
@media (min-width: 760px) and (max-width: 1239px) {
  .hero__aside { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 24px 40px; max-width: none; align-items: end; }
  .hero__actions { margin-top: 0; }
}

/* la tira */
.strip {
  position: relative; z-index: 1;
  margin-top: calc(clamp(28px, 3.2vw, 48px) - 8px);
  overflow-x: auto; overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory; scroll-padding-left: var(--m);
  scrollbar-width: none;
  padding-bottom: 4px;
}
.strip::-webkit-scrollbar { display: none; }
.strip:focus-visible { outline-offset: -3px; }
.strip__list { display: flex; gap: clamp(10px, 1vw, 14px); padding: 8px var(--m); width: max-content; }
.reel { flex: 0 0 var(--reel-w); width: var(--reel-w); scroll-snap-align: start; }
.reel__media {
  position: relative; display: block; overflow: hidden;
  aspect-ratio: 9 / 16; border-radius: var(--radius);
  background: var(--loading); cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.reel__media video { width: 100%; height: 100%; object-fit: cover; transition: transform 700ms var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .reel__media:hover video { transform: scale(1.025); } }
.reel__media:active video { transform: scale(0.99); transition-duration: var(--t-press); }
.reel__sound {
  position: absolute; left: 12px; bottom: 16px; z-index: 3;
  width: 36px; height: 36px; border-radius: 50%;
  background: rgba(20, 12, 18, 0.52) no-repeat center / 18px 18px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M11 5 6 9H3v6h3l5 4V5z' fill='white'/%3E%3Cpath d='m16 9 5 6M21 9l-5 6'/%3E%3C/svg%3E");
  transition: background-color var(--t-hover) ease, transform var(--t-press) var(--ease-out);
}
.reel.is-playing .reel__sound {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M11 5 6 9H3v6h3l5 4V5z' fill='white'/%3E%3Cpath d='M15.5 8.5a5 5 0 0 1 0 7M18.5 5.5a9 9 0 0 1 0 13'/%3E%3C/svg%3E");
}
@media (hover: hover) and (pointer: fine) { .reel__media:hover .reel__sound { background-color: rgba(20, 12, 18, 0.74); transform: scale(1.06); } }
.reel[data-mudo] .reel__sound { display: none; }
.reel__foot { margin-top: 12px; font-size: var(--s5); line-height: 1.4; padding-right: 8px; }
.reel__client { display: block; font-weight: 560; }
.reel__title { display: block; color: var(--muted); }
.strip.is-dragging { cursor: grabbing; scroll-snap-type: none; }
/* «Pausar movimiento» (solo con script, que es quien lo hace funcionar) */
.hero__foot { position: relative; z-index: 1; display: flex; justify-content: flex-end; padding: 6px var(--m) 0; }
.quieto {
  min-height: 44px; padding: 0 2px; border: 0; background: none; cursor: pointer;
  display: inline-flex; align-items: center; gap: 10px;
  font-size: var(--s5); font-weight: 520; color: var(--muted);
  text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 0.3em; text-decoration-color: color-mix(in srgb, var(--muted) 40%, transparent);
  transition: color var(--t-hover) ease;
}
.quieto::before { content: ""; width: 10px; height: 12px; border-inline: 3px solid currentColor; box-sizing: border-box; }
.quieto[aria-pressed="true"]::before { width: 0; height: 0; border-block: 6px solid transparent; border-inline: 10px solid currentColor; border-right-width: 0; }
@media (hover: hover) and (pointer: fine) { .quieto:hover { color: var(--ink); } }
html:not(.js) .quieto { display: none; }
.strip.is-dragging .reel__media { cursor: grabbing; }

/* entradas de la portada (con script y con movimiento; asentadas antes de 1,2 s) */
@media (prefers-reduced-motion: no-preference) {
  .js .hero__title .w { opacity: 0; transform: translateY(0.28em); animation: rise 820ms var(--ease-expo) forwards; animation-delay: calc(60ms + var(--i) * 70ms); }
  .js .hero .fade { opacity: 0; transform: translateY(14px); animation: rise 620ms var(--ease-out) forwards; animation-delay: var(--d); }
  .js .strip__list .reel { opacity: 0; transform: translateY(28px); animation: rise 900ms var(--ease-expo) forwards; }
  .js .strip__list .reel:nth-child(1) { animation-delay: 360ms; }
  .js .strip__list .reel:nth-child(2) { animation-delay: 420ms; }
  .js .strip__list .reel:nth-child(3) { animation-delay: 480ms; }
  .js .strip__list .reel:nth-child(4) { animation-delay: 540ms; }
  .js .strip__list .reel:nth-child(n+5) { animation-delay: 600ms; }
}

/* entradas por sección: ligadas al scroll; lo que aún no ha llegado no está oculto sin soporte */
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    [data-r] {
      animation: enter linear forwards;
      animation-timeline: view();
      animation-range: entry calc(var(--i, 0) * 36px) entry calc(220px + var(--i, 0) * 36px);
    }
  }
}
@keyframes enter {
  from { opacity: 0; transform: translateY(28px); animation-timing-function: var(--ease-out); }
  to { opacity: 1; transform: none; }
}
@keyframes rise { to { opacity: 1; transform: none; } }

/* ---------- trabajos para (pruebas) ---------- */
.proof { position: relative; padding-top: clamp(56px, 6vw, 96px); }
.proof__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gut); row-gap: 18px; align-items: end; }
.proof__title { grid-column: 1 / -1; margin-bottom: 18px; font-family: var(--f-display); font-weight: 400; font-size: var(--s3); line-height: 1.1; color: var(--muted); }
.proof__lead { grid-column: 1 / 5; display: grid; font-family: var(--f-display); }
.proof__name { position: relative; z-index: 1; font-size: var(--s3); line-height: 1.1; letter-spacing: -0.01em; }
.proof__fig { font-size: var(--s2); line-height: 1; letter-spacing: -0.03em; margin-top: 10px; font-variant-numeric: tabular-nums; }
.proof__note { font-family: var(--f-text); font-size: var(--s5); color: var(--muted); margin-top: 10px; }
.proof__names { grid-column: 5 / 13; display: flex; flex-wrap: wrap; align-items: baseline; font-family: var(--f-display); font-size: var(--s3); line-height: 1.3; letter-spacing: -0.01em; padding-bottom: 28px; }
.proof__names > li { white-space: nowrap; }
.proof__names > li::after { content: ",\00a0"; white-space: pre; color: var(--muted); }
.proof__names > li:nth-last-child(2)::after { content: "\00a0y\00a0"; }
.proof__names > li:last-child::after { content: "."; }
@media (max-width: 899px) {
  .proof__lead, .proof__names { grid-column: 1 / -1; }
  .proof__names { padding-bottom: 0; }
  .proof__names > li { white-space: normal; }
}

/* ---------- qué hacemos: tres puertas ---------- */
.doors { padding-top: var(--section); }
.doors__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gut); row-gap: clamp(28px, 3vw, 44px); align-items: start; }
.doors__title { grid-column: 1 / -1; }
.doors__list { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px var(--gut); }
.door { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; }
.door__media { position: relative; width: 100%; background: var(--loading); }
/* el cartel es una <img loading="lazy"> debajo del vídeo: llega cuando hace falta y se ve también sin script */
.door__media img, .piece__media img, .frame > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.door__media img { object-position: 50% 40%; }
.door__media video { position: relative; width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; object-position: 50% 40%; }
.door__media figcaption { margin-top: 10px; font-size: var(--s5); color: var(--muted); }
.door__name { margin-top: 6px; font-family: var(--f-display); font-weight: 400; font-size: var(--s3); line-height: 1.08; letter-spacing: -0.01em; }
.door p { font-size: 17px; line-height: 1.55; }
.door .link { margin-top: auto; padding-top: 4px; }
/* en el móvil: una fila que se desliza, con el borde de la siguiente puerta a la vista */
@media (max-width: 759px) {
  .doors__list {
    display: flex; gap: var(--gut); overflow-x: auto; overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory; scroll-padding-left: var(--m); scrollbar-width: none;
    margin-inline: calc(var(--m) * -1); padding: 4px var(--m) 8px;
  }
  .doors__list::-webkit-scrollbar { display: none; }
  .door { flex: 0 0 82%; scroll-snap-align: start; }
}

/* ---------- una grabación, siete piezas ---------- */
.seven { padding-top: var(--section); }
.seven__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gut); row-gap: clamp(28px, 3vw, 44px); }
.seven__title { grid-column: 1 / 7; align-self: end; }
.seven__intro { grid-column: 7 / 13; align-self: end; display: grid; gap: 24px; }
.seven__text { max-width: 52ch; }
.piece img, .piece video { width: 100%; height: auto; background: var(--surface); }
.piece__media { position: relative; display: block; background: var(--surface); }
.piece__media img { background: none; }
.piece__media video { position: relative; aspect-ratio: 9 / 16; object-fit: cover; background: none; }
.piece figcaption, .piece__cap {
  margin-top: 10px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 2px 12px;
  font-size: var(--s5); line-height: 1.35; color: var(--muted);
}
.piece__to { color: var(--ink); font-weight: 560; }
/* el episodio arriba a la izquierda y, debajo, el audio; a la derecha, los dos reels de esa misma grabación */
.piece--episode { grid-column: 1 / 8; grid-row: 2; }
.seven__side { grid-column: 1 / 8; grid-row: 3; }
.wave { width: 100%; height: clamp(72px, 7.4vw, 112px); fill: var(--ink); }
.seven__list { font-family: var(--f-display); font-size: var(--s3); line-height: 1.2; letter-spacing: -0.01em; display: grid; gap: 6px; }
.seven__reels { grid-column: 8 / 13; grid-row: 2 / span 2; align-self: start; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--gut); }
@media (max-width: 899px) {
  .seven__title, .seven__intro, .piece--episode, .seven__side, .seven__reels { grid-column: 1 / -1; grid-row: auto; }
}

/* ---------- del episodio al reel ---------- */
.swap { margin-top: var(--section); padding-block: clamp(64px, 7vw, 112px); background: var(--surface); }
.swap__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gut); row-gap: 32px; align-items: start; }
.swap__title { grid-column: 1 / -1; }
.swap__copy { grid-column: 1 / 5; display: grid; gap: 24px; align-content: start; padding-top: 8px; }
.swap__copy > p { max-width: 34ch; }
.swap__controls { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.toggle { display: inline-flex; background: var(--surface-3); border-radius: calc(var(--radius) + 4px); padding: 4px; }
.toggle__btn {
  min-height: 48px; padding: 0 22px; border: 0; border-radius: var(--radius); background: transparent;
  font-size: 17px; font-weight: 560; cursor: pointer;
  transition: background-color var(--t-hover) ease, color var(--t-hover) ease, transform var(--t-press) var(--ease-out);
}
.toggle__btn[aria-pressed="true"] { background: var(--accent); color: var(--on-accent); }
.toggle__btn:active { transform: scale(0.96); }
@media (hover: hover) and (pointer: fine) { .toggle__btn[aria-pressed="false"]:hover { background: var(--bg); } }
.sound {
  display: inline-flex; align-items: center; gap: 10px; min-height: 48px; padding: 0 18px;
  border: 0; border-radius: var(--radius); background: var(--bg); cursor: pointer; font-size: 17px; font-weight: 520;
  transition: background-color var(--t-hover) ease, transform var(--t-press) var(--ease-out);
}
.sound:active { transform: scale(0.96); }
@media (hover: hover) and (pointer: fine) { .sound:hover { background: var(--lila); } }
.sound__icon { width: 12px; height: 12px; border-radius: 50%; background: var(--muted); transition: background-color var(--t-ui) ease, transform var(--t-ui) var(--ease-out); }
.sound[aria-pressed="true"] .sound__icon { background: var(--accent); transform: scale(1.3); }

.swap__stage { grid-column: 5 / 13; position: relative; aspect-ratio: 16 / 9; --slice: 34.2%; }
.swap__cap { grid-column: 5 / 13; margin-top: -12px; font-size: var(--s5); color: var(--muted); }
.swap__ep, .swap__reel { position: absolute; }
.swap__ep { inset: 0; transition: clip-path 900ms var(--ease-in-out), opacity 500ms ease 500ms; clip-path: inset(0 0 0 0); }
.swap__ep, .swap__reel { background: var(--loading); }
.swap__ep video, .swap__reel video { position: relative; width: 100%; height: 100%; object-fit: cover; }
.swap__reel { top: 0; bottom: 0; left: 50%; aspect-ratio: 9 / 16; height: 100%; transform: translateX(-50%) scale(1.04); opacity: 0; transition: opacity 500ms ease 420ms, transform 900ms var(--ease-expo) 420ms; }
.swap__stage[data-mode="reel"] .swap__ep { clip-path: inset(0 var(--slice) 0 var(--slice)); opacity: 0; }
.swap__stage[data-mode="reel"] .swap__reel { opacity: 1; transform: translateX(-50%); }
/* en el móvil el escenario mide lo que el vídeo activo: 16:9 en Episodio, más alto en Reel; nada de franjas vacías */
@media (max-width: 899px) {
  .swap__copy, .swap__stage, .swap__cap { grid-column: 1 / -1; }
  .swap__stage { aspect-ratio: 16 / 9; transition: aspect-ratio 700ms var(--ease-in-out); }
  .swap__stage[data-mode="reel"] { aspect-ratio: 16 / 10; --slice: 32.4%; }
  .swap__ep { inset: auto 0; top: 50%; aspect-ratio: 16 / 9; translate: 0 -50%; }
  .swap__stage[data-mode="reel"] .swap__ep { clip-path: inset(0 var(--slice)); }
}
@media (max-width: 599px) {
  .swap__stage[data-mode="reel"] { aspect-ratio: 4 / 5; --slice: 14.8%; }
}

/* ---------- trabajos ---------- */
.work { padding-top: var(--section); }
.work__head { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gut); row-gap: 16px; align-items: end; margin-bottom: clamp(32px, 4vw, 56px); }
.work__head .h2 { grid-column: 1 / 7; }
.work__head p { grid-column: 7 / 13; max-width: 40ch; }
.work__grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: clamp(28px, 3vw, 44px) var(--gut); grid-auto-flow: row dense; align-items: start; }
.work__item--wide { grid-column: span 3; }
.work__link { display: block; text-decoration: none; color: inherit; cursor: pointer; }
.work__media { display: block; position: relative; overflow: clip; aspect-ratio: 9 / 16; background: var(--surface-2); }
.work__item--wide .work__media { aspect-ratio: 16 / 9; }
.work__media img, .work__media video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 700ms var(--ease-soft), opacity 300ms ease; }
.work__media video { opacity: 0; }
.work__media.is-playing video { opacity: 1; }
.work__media::after {
  content: "Ver con sonido"; position: absolute; left: 12px; bottom: 12px;
  background: var(--bg); color: var(--ink); font-size: var(--s5); font-weight: 560; padding: 7px 12px; border-radius: var(--radius);
  opacity: 0; transform: translateY(8px); transition: opacity var(--t-ui) ease, transform var(--t-ui) var(--ease-out);
}
.work__title { display: block; margin-top: 12px; font-size: 17px; font-weight: 560; line-height: 1.3; }
.work__client { display: block; margin-top: 2px; font-size: var(--s5); color: var(--muted); min-height: 1.4em; }
@media (hover: hover) and (pointer: fine) {
  .work__link:hover .work__media img, .work__link:hover .work__media video { transform: scale(1.035); }
  .work__link:hover .work__media::after, .work__link:focus-visible .work__media::after { opacity: 1; transform: none; }
}
.work__link:active .work__media { transform: scale(0.985); transition: transform var(--t-press) var(--ease-out); }
@media (max-width: 1099px) { .work__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } .work__item--wide { grid-column: span 3; } }
@media (max-width: 759px) {
  .work__head .h2, .work__head p { grid-column: 1 / -1; }
  .work__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
  .work__item--wide { grid-column: span 2; }
}

/* ---------- cómo trabajamos ---------- */
.how { padding-top: var(--section); }
.how .h2 { margin-bottom: clamp(20px, 2.4vw, 36px); }
.how__step {
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gut); align-items: center;
  padding-block: clamp(14px, 1.6vw, 22px);
}
.how__step { align-items: baseline; }
.how__step + .how__step { border-top: 4px solid var(--surface); }
.how__verb { grid-column: 1 / 5; font-family: var(--f-display); font-weight: 400; font-size: clamp(36px, 4.4vw, 64px); line-height: 1; letter-spacing: -0.025em; }
.how__step p { grid-column: 5 / 11; max-width: 40ch; font-size: var(--s3); line-height: 1.3; letter-spacing: -0.01em; }
@media (max-width: 899px) {
  .how__step { grid-template-columns: 1fr; row-gap: 8px; }
  .how__verb, .how__step p { grid-column: 1; }
  .how__step p { font-size: var(--s4); }
}
@media (min-width: 600px) and (max-width: 899px) {
  .how__step { grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); column-gap: var(--gut); }
  .how__verb { grid-column: 1; }
  .how__step p { grid-column: 2; }
}

/* ---------- cómo podemos trabajar: el mismo componente en las tres páginas, sin precios ----------
   Inicio: el lanzamiento a todo el ancho (.forma--grande) y tres pequeñas. /podcast/ y /redes/: dos iguales (.formas__list--dos). */
.formas { margin-top: var(--section); padding-block: clamp(64px, 7vw, 112px); background: var(--surface); }
.formas__head { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gut); row-gap: 20px; align-items: end; margin-bottom: clamp(32px, 4vw, 56px); }
.formas__head .h2 { grid-column: 1 / 8; }
.formas__note { grid-column: 9 / 13; max-width: 46ch; }
.formas__list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gut); }
.formas__list--dos { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.forma {
  background: var(--bg); border-radius: var(--radius);
  display: flex; flex-direction: column; align-items: flex-start; gap: 18px;
  padding: clamp(24px, 3vw, 44px);
}
.forma__name { font-family: var(--f-display); font-weight: 400; font-size: var(--s3); line-height: 1.1; letter-spacing: -0.01em; text-wrap: balance; }
.forma--grande .forma__name, .formas__list--dos .forma__name { font-size: clamp(36px, 4.4vw, 64px); line-height: 1; letter-spacing: -0.025em; }
.forma__text { font-size: var(--s4); line-height: 1.55; max-width: 44ch; }
.forma__note { color: var(--muted); max-width: 44ch; }
.forma__list { align-self: stretch; }
.forma__list li { font-family: var(--f-display); font-size: var(--s3); line-height: 1.15; letter-spacing: -0.01em; padding-block: 14px; }
.forma__list li:first-child { padding-top: 0; }
.forma__list li + li { border-top: 2px solid var(--surface); }
.forma .button { margin-top: auto; }
/* el lanzamiento: a la izquierda el nombre y la frase; a la derecha lo que incluye y el botón debajo */
.forma--grande { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); column-gap: clamp(32px, 6vw, 112px); row-gap: 28px; align-items: start; }
.forma__head { display: grid; gap: 18px; }
.forma__side { display: grid; gap: 28px; justify-items: start; }
.forma--grande .button { margin-top: 0; }
@media (max-width: 899px) {
  .formas__head .h2, .formas__note { grid-column: 1 / -1; }
  .formas__list, .forma--grande { grid-template-columns: 1fr; }
  .formas__list { row-gap: 32px; }
}
@media (min-width: 600px) and (max-width: 899px) {
  .formas__list--dos { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 599px) {
  .forma .button { align-self: stretch; justify-self: stretch; width: 100%; }
}

/* ---------- quién está detrás (sin foto): título, texto en cuerpo y los datos en la columna de la derecha ---------- */
.who { padding-top: var(--section); }
.who__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gut); row-gap: 28px; align-items: start; }
.who__title { grid-column: 1 / 5; }
.who__text { grid-column: 5 / 10; font-size: 21px; line-height: 1.5; max-width: 52ch; text-wrap: pretty; }
.who__facts { grid-column: 10 / 13; display: grid; gap: 14px; padding-top: 18px; border-top: 2px solid var(--surface-3); font-family: var(--f-display); font-size: var(--s3); line-height: 1.15; letter-spacing: -0.01em; }
@media (max-width: 1099px) {
  .who__title, .who__text, .who__facts { grid-column: 1 / -1; }
}
@media (max-width: 759px) {
  .who__text { font-size: var(--s4); line-height: 1.55; }
}

/* ---------- preguntas ---------- */
.faq { padding-top: var(--section); }
.faq__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gut); row-gap: 28px; align-items: start; }
.faq__title { grid-column: 1 / 5; }
.faq__list { grid-column: 5 / 13; }
.q { background: none; }
.q + .q { border-top: 4px solid var(--surface); }
.q summary {
  list-style: none; cursor: pointer;
  display: grid; grid-template-columns: minmax(0, 1fr) 22px; gap: 20px; align-items: center;
  padding: clamp(18px, 2vw, 28px) 0;
}
.q summary::-webkit-details-marker { display: none; }
.q__text { font-family: var(--f-display); font-size: var(--s3); line-height: 1.15; letter-spacing: -0.01em; transition: color var(--t-hover) ease; }
.q__mark { position: relative; width: 22px; height: 22px; }
.q__mark::before, .q__mark::after { content: ""; position: absolute; left: 0; top: 10px; width: 22px; height: 2px; background: var(--ink); transition: transform var(--t-ui) var(--ease-out); }
.q__mark::after { transform: rotate(90deg); }
.q[open] .q__mark::after { transform: rotate(0deg); }
@media (hover: hover) and (pointer: fine) { .q summary:hover .q__text { color: var(--accent); } }
.q p { padding: 0 0 clamp(22px, 2.4vw, 32px); max-width: 62ch; font-size: var(--s4); }
@media (prefers-reduced-motion: no-preference) {
  .q[open] p { animation: rise-in 420ms var(--ease-out); }
}
@keyframes rise-in { from { opacity: 0; transform: translateY(8px); } }
@media (max-width: 1099px) {
  .faq__title, .faq__list { grid-column: 1 / -1; }
}


/* ---------- contacto: focos de luz suaves ---------- */
.contact { position: relative; overflow: clip; margin-top: var(--section); padding: clamp(80px, 9vw, 140px) 0 clamp(64px, 7vw, 112px); background: var(--bg); }
.focos {
  position: absolute; inset: 0; pointer-events: none; opacity: 0.45;
  -webkit-mask-image: linear-gradient(to bottom, transparent, #000 18%, #000 80%, transparent); /* taste-skill-ignore: funde los focos con el fondo, sin bordes */
  mask-image: linear-gradient(to bottom, transparent, #000 18%, #000 80%, transparent); /* taste-skill-ignore: funde los focos con el fondo, sin bordes */
}
.foco { position: absolute; background: center / 100% 100% no-repeat; }
.foco--a { width: 70vw; height: 70vw; left: -22vw; top: -30vw; background-image: url("img/luz-foco-lila.webp"); }
.foco--b { width: 60vw; height: 60vw; right: -18vw; top: -10vw; background-image: url("img/luz-foco-menta.webp"); }
.foco--c { width: 56vw; height: 56vw; left: 26vw; bottom: -18vw; background-image: url("img/luz-foco-rosa.webp"); }
@media (prefers-reduced-motion: no-preference) {
  .foco--a { animation: foco-a 34s ease-in-out infinite alternate; }
  .foco--b { animation: foco-b 42s ease-in-out infinite alternate; }
  .foco--c { animation: foco-c 38s ease-in-out infinite alternate; }
}
@keyframes foco-a { to { transform: translate3d(14vw, 8vw, 0) scale(1.08); } }
@keyframes foco-b { to { transform: translate3d(-12vw, 10vw, 0) scale(0.94); } }
@keyframes foco-c { to { transform: translate3d(-10vw, -8vw, 0) scale(1.1); } }

/* el cierre, igual en las tres páginas: título a la izquierda, alineado abajo; a la derecha la frase, el botón y el correo */
.cierre__grid { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gut); row-gap: 32px; align-items: end; }
.cierre__title { grid-column: 1 / 8; }
.cierre__copy { grid-column: 8 / 13; display: grid; gap: 22px; justify-items: start; }
.contact__lead { font-size: var(--s3); line-height: 1.3; max-width: 24ch; letter-spacing: -0.01em; }
.cierre__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 24px; }
.cierre__mail { font-size: var(--s4); }
@media (max-width: 599px) {
  .cierre__title, .cierre__copy { grid-column: 1 / -1; }
  .cierre__actions, .cierre__actions .button { width: 100%; }
}
/* con formulario (en el inicio, cuando script.js tiene la clave de Web3Forms): título y frase a la izquierda, formulario a la derecha */
.contact--con-form .cierre__grid { align-items: start; }
.contact--con-form .cierre__title, .contact--con-form .cierre__copy { grid-column: 1 / 6; }
.contact--con-form .form { grid-column: 7 / 13; grid-row: 1 / span 2; }
.form { background: var(--bg); padding: clamp(24px, 3vw, 40px); display: grid; gap: 20px; }
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field { display: grid; gap: 8px; font-size: var(--s5); font-weight: 560; }
.field input, .field textarea, .field select {
  width: 100%; font: inherit; font-size: var(--s4); font-weight: 420; color: var(--ink);
  background: #FFFFFF; border: 1.5px solid var(--field-line); border-radius: var(--radius); padding: 13px 14px;
  transition: border-color var(--t-hover) ease;
}
.field select {
  appearance: none; -webkit-appearance: none; padding-right: 44px; cursor: pointer;
  background: #FFFFFF url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23241820' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 14px center / 18px 18px;
}
.field textarea { resize: vertical; min-height: 120px; }
.field input:hover, .field textarea:hover, .field select:hover { border-color: var(--field-line-hover); }
.field :is(input, textarea, select):focus { outline: none; border-color: var(--accent); }
.field :is(input, textarea, select):focus-visible { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 35%, transparent); }
.form__send:disabled { opacity: 0.7; cursor: progress; }
.field select.is-picked { border-color: var(--accent); }
.check { display: flex; align-items: flex-start; gap: 12px; font-size: var(--s5); line-height: 1.45; cursor: pointer; }
.check input { flex: none; width: 20px; height: 20px; margin: 1px 0 0; accent-color: var(--accent); cursor: pointer; }
.form__send { justify-self: start; min-width: 160px; }
.form__legal { font-size: var(--s5); line-height: 1.5; color: var(--muted); }
.form__legal .link { font-weight: 500; color: var(--muted); }
@media (max-width: 899px) {
  .contact--con-form .cierre__title, .contact--con-form .cierre__copy, .contact--con-form .form { grid-column: 1 / -1; grid-row: auto; }
  .form { margin-inline: calc(var(--m) * -0.5); }
  .form__row { grid-template-columns: 1fr; }
  .form__send { width: 100%; }
}

/* ---------- cierre: vuelve el cielo, con «lúcida» enorme ---------- */
.foot { position: relative; overflow: clip; padding-top: clamp(48px, 6vw, 96px); }
.foot > .sky { z-index: 0; }
.foot__row, .foot__word { position: relative; z-index: 1; }
.foot__row { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 0 24px; font-size: var(--s5); }
.foot__legal { display: flex; gap: 20px; }
.foot__legal .link { font-weight: 500; display: inline-block; padding-block: 10px; }
.foot__word { display: block; color: var(--ink); padding: clamp(16px, 2.4vw, 36px) var(--m) 0; margin-bottom: -5.4vw; }
.foot__word svg { width: 100%; height: auto; }

/* ---------- reproductor grande ---------- */
.player {
  width: min(100vw - 24px, 1280px); max-width: none; max-height: calc(100svh - 24px);
  padding: 0; border: 0; background: var(--bg); color: var(--ink);
  box-shadow: 0 30px 80px rgba(36, 24, 32, 0.28); /* taste-skill-ignore: el reproductor flota */
  overscroll-behavior: contain;
}
.player::backdrop { background: rgba(36, 24, 32, 0.72); }
.player[open] { display: block; }
@media (prefers-reduced-motion: no-preference) {
  .player[open] { animation: pop 420ms var(--ease-expo); }
  .player[open]::backdrop { animation: fade 300ms ease; }
}
@keyframes pop { from { opacity: 0; transform: translateY(18px) scale(0.98); } }
@keyframes fade { from { opacity: 0; } }
.player__inner { display: grid; grid-template-columns: minmax(0, 1fr) 300px; }
.player__frame { background: #120C10; display: grid; place-items: center; min-height: 0; }
.player__frame video { max-height: calc(100svh - 24px); width: 100%; height: auto; }
.player.is-v .player__frame video { width: auto; height: calc(100svh - 24px); max-width: 100%; }
.player__frame .cabezal { opacity: 1; }
.player__meta { padding: 28px; display: flex; flex-direction: column; gap: 10px; }
.player__title { font-family: var(--f-display); font-weight: 400; font-size: var(--s3); line-height: 1.1; }
.player__client { color: var(--muted); }
.player__nav { margin-top: auto; display: flex; flex-wrap: wrap; gap: 8px; }
.player__btn {
  min-height: 44px; padding: 0 16px; border: 0; border-radius: var(--radius); background: var(--surface-2); cursor: pointer; font-size: var(--s5); font-weight: 560;
  transition: background-color var(--t-hover) ease, transform var(--t-press) var(--ease-out);
}
.player__btn:active { transform: scale(0.96); }
.player__close { background: var(--accent); color: var(--on-accent); }
@media (hover: hover) and (pointer: fine) { .player__btn:hover { background: var(--lila); } .player__close:hover { background: var(--accent-strong); } }
@media (max-width: 899px) {
  .player { width: 100vw; height: 100svh; max-height: 100svh; }
  .player__inner { grid-template-columns: 1fr; grid-template-rows: minmax(0, 1fr) auto; height: 100%; }
  .player__frame video, .player.is-v .player__frame video { max-height: calc(100svh - 190px); height: auto; width: auto; max-width: 100%; }
  .player__meta { padding: 16px; }
}

/* ---------- movimiento reducido ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; }
}
