@import url("/fuentes/fuentes.css");

/* Es Fácil Tech · dirección «la frase es la composición» (taste-skill, semilla 62177954).
   Proporciones de la paleta dealt (gris frío + un acento); el acento y el campo oscuro salen de los propios vídeos. */
:root {
  --bg: #eef0f3;
  --surface: #e2e5ea;
  --ink: #0b0c0e;
  --muted: #545b66;
  --campo: #111317;
  --campo-ink: #eef0f3;
  --campo-muted: #a7adb6;
  --hondo: #08090b;
  --acento: #f2b33d;
  --acento-ink: #0b0c0e;

  --display: "Gambarino", Georgia, serif;
  --texto: "General Sans", "Helvetica Neue", Arial, sans-serif;

  --step-small: clamp(0.8125rem, 0.79rem + 0.1vw, 0.875rem);
  --step-body: clamp(1.0625rem, 1rem + 0.25vw, 1.1875rem);
  --step-lead: clamp(1.25rem, 1.1rem + 0.7vw, 1.625rem);
  --step-head: clamp(2.5rem, 1.3rem + 4.2vw, 5rem);
  --step-poster: clamp(4rem, 11vw, 10.5rem);

  --margen: clamp(16px, 2.2vw, 32px);
  --radio: 0;
  --hueco: clamp(120px, 14vw, 200px);
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 var(--step-body) / 1.5 var(--texto);
  -webkit-font-smoothing: antialiased;
}
img, video { display: block; max-width: 100%; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--acento); outline-offset: 3px; }
::selection { background: var(--acento); color: var(--acento-ink); }
.oculto { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ── Cabecera: toma el color del capítulo que tiene debajo ── */
.cabecera {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 68px;
  padding: 0 var(--margen);
  background: var(--bg);
  color: var(--ink);
  transition: background-color 300ms ease, color 300ms ease;
}
.cabecera[data-tono="oscuro"] { background: var(--campo); color: var(--campo-ink); }
.cabecera[data-tono="hondo"] { background: var(--hondo); color: var(--campo-ink); }
.cabecera[data-tono="acento"] { background: var(--acento); color: var(--acento-ink); }
.marca { font-weight: 600; font-size: 1rem; text-decoration: none; letter-spacing: -0.01em; }
.enlaces-nav { display: flex; align-items: center; gap: 28px; }
.enlaces-nav a:not(.boton) { text-decoration: none; font-size: 1rem; }
.enlaces-nav a:not(.boton):hover { text-decoration: underline; text-underline-offset: 5px; }
.menu { display: none; }
.menu summary { list-style: none; cursor: pointer; font-size: 1rem; }
.menu summary::-webkit-details-marker { display: none; }

.boton {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border: 0;
  border-radius: var(--radio);
  background: var(--acento);
  color: var(--acento-ink);
  font: 500 1rem / 1 var(--texto);
  text-decoration: none;
  cursor: pointer;
  transition: transform 160ms var(--ease), background-color 160ms ease;
}
.boton:hover { background: #ffc65c; }
.boton:active { transform: scale(0.97); }
.boton.tinta { background: var(--ink); color: var(--bg); }
.boton.tinta:hover { background: #262a31; }
.boton.claro { background: var(--campo-ink); color: var(--ink); }
.boton.claro:hover { background: #ffffff; }

/* ── Portada: dos campos y la frase cruzando la costura ── */
.heroe {
  position: relative;
  height: max(640px, 100svh);
  --costura: 50%;
  background: var(--bg);
  overflow: hidden;
}
.heroe::before { content: ""; position: absolute; inset: var(--costura) 0 0 0; background: var(--campo); }
.titular-heroe {
  position: absolute;
  left: 50%;
  top: 50%;
  width: max-content;
  max-width: calc(100% - 2 * var(--margen));
  margin: 0;
  font: 400 var(--step-poster) / 0.92 var(--display);
  letter-spacing: -0.02em;
  text-align: center;
  transform: translate(-50%, -1.22em);
}
.titular-heroe .capa { display: block; }
.titular-heroe .capa + .capa { position: absolute; inset: 0; }
.capa.arriba { color: var(--ink); clip-path: inset(0 0 calc(100% - 1.22em) 0); }
.capa.abajo { color: var(--campo-ink); clip-path: inset(1.22em 0 0 0); }
.linea { display: block; white-space: nowrap; }
.ranura {
  display: inline-block;
  width: 2.1em;
  height: 0.74em;
  margin-left: 0.12em;
  vertical-align: -0.02em;
  overflow: hidden;
  background: var(--campo);
}
.ranura video, .ranura img { width: 100%; height: 100%; object-fit: cover; }
.pie-heroe {
  position: absolute;
  left: 50%;
  bottom: 56px;
  display: grid;
  justify-items: center;
  gap: 24px;
  width: min(40ch, calc(100% - 2 * var(--margen)));
  transform: translateX(-50%);
}
.entradilla-heroe {
  margin: 0;
  color: var(--campo-ink);
  font-size: var(--step-lead);
  line-height: 1.4;
  text-align: center;
}
.heroe-cola { height: 30svh; background: var(--campo); }

/* ── Secciones ── */
.capitulo { position: relative; }
.capitulo.oscuro { background: var(--campo); color: var(--campo-ink); }
.capitulo.hondo { background: var(--hondo); color: var(--campo-ink); }
.titulo { font: 400 var(--step-head) / 0.95 var(--display); letter-spacing: -0.02em; margin: 0; }
.rejilla { display: grid; grid-template-columns: repeat(12, 1fr); gap: 0 var(--margen); padding: 0 var(--margen); }

/* Una foto, tres distancias */
.distancias { height: 300vh; }
.escenario {
  position: sticky;
  top: 0;
  height: 100svh;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  grid-template-rows: 1fr auto 1fr;
  align-items: center;
  padding: 68px var(--margen) 0;
}
.distancias .medio1, .distancias .medio2 {
  grid-column: 1 / -1;
  margin: 0;
  font: 400 var(--step-head) / 0.95 var(--display);
  letter-spacing: -0.02em;
  text-align: center;
}
.distancias .medio1 { grid-row: 1; align-self: end; padding-bottom: 0.25em; }
.distancias .medio2 { grid-row: 3; align-self: start; margin-top: -0.3em; position: relative; z-index: 2; opacity: 0; transform: translateY(24px); transition: opacity 600ms var(--ease), transform 600ms var(--ease); }
.marco {
  grid-column: 2;
  grid-row: 2;
  width: min(30vw, 46svh);
  aspect-ratio: 4 / 5;
  overflow: hidden;
  background: var(--campo);
}
.marco img { width: 100%; height: 100%; object-fit: cover; transition: transform 700ms var(--ease); transform-origin: 50% 50%; }
.distancias[data-etapa="2"] .marco img { transform: scale(1.8); transform-origin: 22% 30%; }
.distancias[data-etapa="3"] .marco img { transform: scale(3.2); transform-origin: 90% 52%; }
.distancias[data-etapa="2"] .medio2, .distancias[data-etapa="3"] .medio2 { opacity: 1; transform: none; }
.pie-marco {
  grid-column: 3;
  grid-row: 2;
  align-self: start;
  max-width: 28ch;
  margin: 0 0 0 clamp(20px, 3vw, 48px);
  font-size: var(--step-body);
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 600ms var(--ease), transform 600ms var(--ease);
}
.pie-marco small { display: block; margin-top: 10px; color: var(--muted); font-size: var(--step-small); }
.distancias[data-etapa="3"] .pie-marco { opacity: 1; transform: none; }
.marcas { position: absolute; inset: 0; pointer-events: none; }
.marcas span { position: absolute; left: 0; height: 1px; width: 1px; } /* taste-skill-ignore: marcadores invisibles de scroll */
.marcas span:nth-child(1) { top: 0; }
.marcas span:nth-child(2) { top: 100vh; }
.marcas span:nth-child(3) { top: 190vh; }

/* ¿Estafa o no? */
.juego { padding: var(--hueco) 0; }
.juego .rejilla { align-items: start; }
.juego-texto { grid-column: 1 / span 5; position: sticky; top: 120px; }
.juego-texto p { max-width: 34ch; margin: 28px 0 0; color: var(--campo-ink); font-size: var(--step-lead); line-height: 1.35; }
.marcador { margin-top: 28px; color: var(--acento); font-size: var(--step-lead); font-weight: 500; }
.mensajes { grid-column: 7 / span 6; display: grid; gap: 56px; }
.mensaje { max-width: 520px; }
.mensaje .de { margin: 0 0 10px; color: var(--campo-muted); font-size: var(--step-small); }
.burbuja {
  margin: 0;
  padding: 18px 20px;
  border-radius: 20px 20px 20px 6px;
  background: #1d2128;
  color: var(--campo-ink);
  font-size: var(--step-body);
  line-height: 1.45;
}
.burbuja .url { color: #8ec5ff; text-decoration: underline; text-underline-offset: 3px; }
.elige { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.elige .boton { min-height: 44px; }
.elige .boton.otro { background: #262b33; color: var(--campo-ink); }
.elige .boton.otro:hover { background: #313741; }
.respuesta { margin-top: 16px; }
.respuesta summary { cursor: pointer; color: var(--campo-muted); }
.veredicto { margin: 0 0 6px; font-weight: 600; font-size: var(--step-lead); }
.veredicto.bien { color: var(--acento); }
.veredicto.mal { color: #ff7a59; }
.explica { margin: 0; color: var(--campo-ink); max-width: 46ch; }
.con-js .respuesta summary { display: none; }
.con-js .respuesta:not([open]) { display: none; }
.sin-js .elige { display: none; }

/* Los vídeos: un párrafo de nombres */
.videos { padding: var(--hueco) var(--margen); }
.videos .titulo { margin-bottom: 40px; }
.nombres {
  max-width: 1400px;
  margin: 0;
  font: 400 var(--step-lead) / 1.35 var(--texto);
  letter-spacing: -0.015em;
  color: var(--muted);
}
.nombres a { text-decoration: none; color: var(--ink); transition: color 160ms ease; }
.nombres a:hover { color: var(--ink); text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 6px; }
.nombres .proximo { color: var(--muted); }
.miniatura {
  display: inline-block;
  width: 1.5em;
  height: 0.95em;
  margin: 0 0.25em 0 0.2em;
  vertical-align: -0.12em;
  overflow: hidden;
  background: var(--campo);
  transition: transform 200ms var(--ease);
  transform-origin: left center;
}
.miniatura img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; }
.nombres a:hover .miniatura { transform: scale(1.6); }
.videos .nota { margin: 32px 0 0; color: var(--muted); font-size: var(--step-body); }

/* Cómo se hace: un verbo por pantalla */
.paso {
  position: relative;
  height: 100svh;
  min-height: 560px;
  display: grid;
  grid-template-columns: 1fr minmax(0, 40vw);
  align-items: center;
  gap: var(--margen);
  padding: 68px var(--margen) 0;
  overflow: clip;
}
.paso:nth-child(even) { background: var(--hondo); }
.paso-texto { grid-column: 1; grid-row: 1; }
.verbo { margin: 0 0 28px; font: 400 var(--step-poster) / 0.9 var(--display); letter-spacing: -0.03em; color: var(--campo-ink); }
.paso figure { grid-column: 2; grid-row: 1; margin: 0; height: 78svh; aspect-ratio: 4 / 5; max-width: 100%; justify-self: end; overflow: hidden; background: var(--campo); }
.paso figure img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.08); transition: transform 1600ms var(--ease); }
.paso.visto figure img { transform: scale(1); }
.paso .frase { max-width: 34ch; margin: 0; color: var(--campo-ink); font-size: var(--step-lead); line-height: 1.35; }
@media (max-width: 1000px) {
  .paso { height: auto; min-height: 0; grid-template-columns: 1fr; padding: calc(var(--hueco) * 0.6) var(--margen); }
  .paso figure { grid-column: 1; grid-row: 1; justify-self: stretch; height: auto; max-height: 72svh; }
  .paso-texto { grid-column: 1; grid-row: 2; margin-top: 28px; }
  .verbo { margin-bottom: 16px; }
}

/* Llamada: la pregunta en los dos bordes */
.pregunta {
  position: relative;
  height: max(620px, 100svh);
  display: grid;
  grid-template-rows: auto 1fr auto;
  justify-items: center;
  padding: 100px var(--margen) 24px;
  background: var(--hondo);
  color: var(--campo-ink);
  text-align: center;
}
.pregunta .titulo { font-size: var(--step-poster); line-height: 1; }
.pregunta .arriba { align-self: start; }
.pregunta .abajo { align-self: end; }
.eleccion { align-self: center; display: grid; justify-items: center; gap: 16px; }
.eleccion .fila { display: flex; align-items: center; gap: 28px; }
.eleccion .fila .boton { min-width: 200px; min-height: 56px; }
.eleccion .o { color: var(--campo-muted); }
.eleccion p { margin: 0; color: var(--campo-muted); }

/* Pie: el contacto es el titular */
.pie {
  min-height: 90svh;
  display: grid;
  grid-template-rows: auto 1fr auto auto;
  padding: 40px var(--margen) 28px;
  background: var(--acento);
  color: var(--acento-ink);
}
.pie-notas { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px 40px; font-size: var(--step-small); }
.pie-notas div { display: flex; flex-wrap: wrap; gap: 8px 40px; }
.pie-notas p { margin: 0; max-width: 30ch; }
.contacto {
  align-self: end;
  display: block;
  margin: 0 0 32px;
  font: 400 var(--step-poster) / 0.95 var(--display);
  letter-spacing: -0.02em;
  text-decoration: none;
}
.contacto span { display: block; }
.contacto:hover { text-decoration: underline; text-decoration-thickness: 0.05em; text-underline-offset: 0.12em; }
.pie-meta { display: grid; grid-template-columns: 1fr auto 1fr; gap: 12px 24px; font-size: var(--step-small); }
.pie-meta nav { display: flex; flex-wrap: wrap; gap: 20px; }
.pie-meta a { text-decoration: none; }
.pie-meta a:hover { text-decoration: underline; text-underline-offset: 4px; }
.pie-meta .derecha { text-align: right; }
.pie.corto { min-height: 60svh; }

/* ── Páginas interiores ── */
.interior { padding: calc(68px + var(--hueco) * 0.6) var(--margen) var(--hueco); }
.interior .titulo { font-size: clamp(3.5rem, 9vw, 8rem); }
.interior .lead { max-width: 40ch; margin: 28px 0 0; font-size: var(--step-lead); line-height: 1.4; }
.documento { display: grid; grid-template-columns: repeat(12, 1fr); gap: 0 var(--margen); margin-top: clamp(64px, 8vw, 120px); }
.documento section { grid-column: 1 / -1; display: grid; grid-template-columns: subgrid; padding: 0 0 56px; }
.documento h2 { grid-column: 1 / span 4; margin: 0 0 12px; font-size: var(--step-lead); font-weight: 500; line-height: 1.3; }
.documento .cuerpo { grid-column: 5 / span 7; }
.documento p { margin: 0 0 14px; max-width: 64ch; }
.documento a { text-underline-offset: 3px; }
.vacio { display: grid; grid-template-columns: repeat(12, 1fr); gap: 0 var(--margen); margin-top: clamp(64px, 8vw, 120px); align-items: end; }
.vacio .texto { grid-column: 1 / span 6; }
.vacio .texto p { margin: 0 0 24px; font-size: var(--step-lead); line-height: 1.4; max-width: 34ch; }
.vacio figure { grid-column: 8 / span 5; margin: 0; aspect-ratio: 4 / 5; overflow: hidden; background: var(--campo); }
.vacio figure img { width: 100%; height: 100%; object-fit: cover; }
.aviso-afiliado { grid-column: 1 / span 6; margin-top: 32px; color: var(--muted); font-size: var(--step-body); max-width: 52ch; }

/* ── Entradas ── */
.con-js .entra { opacity: 0; transform: translateY(24px); transition: opacity 700ms var(--ease), transform 700ms var(--ease); }
.con-js .visto .entra, .con-js .entra.visto { opacity: 1; transform: none; }
.con-js .visto .entra:nth-child(2) { transition-delay: 80ms; }
.con-js .visto .entra:nth-child(3) { transition-delay: 160ms; }
.con-js .visto .entra:nth-child(4) { transition-delay: 240ms; }
.heroe .titular-heroe, .heroe .pie-heroe > * { animation: sube 900ms var(--ease) both; }
.heroe .entradilla-heroe { animation-delay: 160ms; }
.heroe .pie-heroe .boton { animation-delay: 240ms; }
@keyframes sube { from { opacity: 0; translate: 0 24px; } }

/* ── Teléfono ── */
@media (max-width: 760px) {
  .enlaces-nav a:not(.boton) { display: none; }
  .menu { display: block; position: relative; }
  .menu nav { position: absolute; right: 0; top: 40px; display: grid; gap: 14px; min-width: 180px; padding: 18px 20px; background: var(--ink); color: var(--bg); }
  .menu nav a { text-decoration: none; }
  .heroe { --costura: 46%; }
  .titular-heroe { top: 46%; font-size: 14.5vw; }
  .pie-heroe { bottom: 40px; width: min(30ch, calc(100% - 2 * var(--margen))); }
  .entradilla-heroe { font-size: 1.0625rem; }
  .escenario { grid-template-columns: 1fr; grid-template-rows: 1fr auto auto 1fr; justify-items: center; }
  .distancias .medio1 { grid-row: 1; }
  .marco { grid-column: 1; grid-row: 2; width: 70vw; }
  .distancias .medio2 { grid-row: 3; }
  .pie-marco { grid-column: 1; grid-row: 4; margin: 16px 0 0; text-align: center; font-size: 1rem; }
  .juego-texto { grid-column: 1 / -1; position: static; }
  .mensajes { grid-column: 1 / -1; margin-top: 56px; gap: 48px; }
  .nombres { line-height: 1.45; }
  .nombres a { padding: 3px 0; }
  .nombres .proximo .miniatura, .nombres li:nth-child(n+4) .miniatura { display: none; }
  .verbo { font-size: 14.5vw; }
  .paso .frase { font-size: 1.0625rem; }
  .pregunta .titulo { font-size: 14.5vw; }
  .eleccion .fila { flex-direction: column; gap: 12px; width: 72vw; }
  .eleccion .fila .boton { width: 100%; min-width: 0; }
  .contacto { font-size: 14.5vw; }
  .pie-meta { grid-template-columns: 1fr; }
  .pie-meta .derecha { text-align: left; }
  .documento h2, .documento .cuerpo { grid-column: 1 / -1; }
  .vacio .texto, .vacio figure, .aviso-afiliado { grid-column: 1 / -1; }
  .vacio figure { margin-top: 32px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
  .con-js .entra { opacity: 1; transform: none; }
  .distancias .medio2, .pie-marco { opacity: 1; transform: none; }
}
