/* =====================================================================
   PERFILES · Revista Página — Hoja de estilos
   ---------------------------------------------------------------------
   Índice
     0. Variables (colores, tipografías)   ← cambie aquí la identidad
     0b. Sistema de cajas de texto (cómo mover y ajustar cada texto)
     1. Base
     2. Entrada (pantalla de escritura)
     3. Cabecera, índice y barra de progreso
     4. Portada del home (mosaico)
     5. Presentación y lenguajes
     6. Tarjetas de los perfiles
     7. Perfil: piezas comunes (etiquetas, bloques)
     8. Perfil: apertura
     9. Perfil: texto
    10. Perfil: video
    11. Perfil: serie fotográfica
    12. Perfil: cita
    13. Perfil: pieza sonora
    14. Perfil: producto gráfico
    15. Perfil: herramienta digital
    16. Separador entre perfiles
    17. Créditos
    18. Visor de fotos (ampliar)
   ===================================================================== */


/* ---------- 0. Variables ---------- */
:root {
  --acento: #E8542F;          /* naranja de la marca */
  --fondo: #0a0a0a;           /* fondo general */
  --fondo-caja: #121110;      /* fondo de recuadros */
  --fondo-foto: #161514;      /* fondo mientras carga una foto */
  --tinta: #ece9e4;           /* texto principal */
  --tinta-2: #cfcbc5;         /* texto secundario */
  --tinta-3: #bdb9b3;         /* pies de foto, firmas */
  --tinta-4: #9a9690;         /* etiquetas */
  --tinta-5: #6f6b66;         /* créditos menores */
  --linea: #2a2826;           /* líneas divisorias */
  --linea-2: #2e2c2a;
  --linea-3: #4a4744;

  --f-titulo: 'Archivo', sans-serif;      /* títulos condensados */
  --f-texto: 'Source Serif 4', serif;     /* lectura */
  --f-dato: 'JetBrains Mono', monospace;  /* etiquetas y datos */
  --f-mano: 'Caveat', cursive;            /* entrada manuscrita */

  --margen: clamp(16px, 4vw, 56px);       /* margen lateral de los bloques */
}


/* ---------- 0b. SISTEMA DE CAJAS DE TEXTO ----------
   Toda caja de texto (títulos, párrafos, etiquetas, citas, pies de foto) se ajusta
   en su propia regla con las mismas propiedades:
     font-family (tipografía) · font-size (tamaño) · font-weight (grosor)
     line-height (interlineado) · letter-spacing (espaciado) · color
   Para MOVER una caja sin empujar a las demás usa top / left en su regla
   (negativo = sube / izquierda). margin, en cambio, sí empuja a las vecinas.
   Tipografías y colores base: sección 0 (variables). "inherit" = hereda de la caja que la contiene.
   Los párrafos del texto de cada perfil se cambian todos juntos en .texto__cuerpo. */
.intro__sobre,
.intro__frase,
.intro__pluma,
.intro__resto,
.marca__nombre,
.cabecera__actual,
.indice__num,
.indice__nombre,
.indice__frase,
.portada__sobre,
.portada__titulo,
.portada__lema,
.portada__desliza,
.editorial__sobre,
.editorial__titulo,
.editorial__entrada,
.editorial__firma,
.lenguaje__num,
.lenguaje__nombre,
.lenguaje__dato,
.tarjetas-seccion__titulo,
.tarjeta__num,
.tarjeta__titulo,
.tarjeta__frase,
.apertura__num,
.apertura__titulo,
.apertura__frase,
.apertura__firma,
.texto__pct,
.video__play,
.video__titulo,
.serie__actual,
.foto__num,
.cita,
.audio__tiempo-actual,
.audio__titulo,
.herramienta__titulo,
.herramienta__desc,
.herramienta__credito,
.etiqueta,
.creditos__titulo,
.creditos__edicion,
.creditos__rol,
.creditos__aviso {
  position: relative; top: 0; left: 0;
}


/* ---------- 1. Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--fondo);
  color: var(--tinta);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
a:hover { color: #fff; }
img { max-width: none; }
button { font: inherit; }
::selection { background: var(--acento); color: var(--fondo); }
body.sin-scroll { overflow: hidden; }

/* Animación de aparición al bajar (la activa funciones.js) */
.aparece { transition: opacity .9s ease, transform .9s cubic-bezier(.2,.7,.2,1); }
.aparece.oculto { opacity: 0; transform: translateY(28px); }


/* ---------- 2. Entrada ---------- */
.intro {
  position: fixed; inset: 0; z-index: 100;
  background: #050505;
  display: flex; align-items: center; justify-content: center;
  padding: clamp(24px, 6vw, 96px);
  cursor: crosshair; touch-action: none;
  transition: opacity 1.4s ease;
}
.intro.saliendo { opacity: 0; }
.intro[hidden] { display: none; }
.intro__caja { width: 100%; max-width: 1100px; display: flex; flex-direction: column; gap: 28px; }
.intro__sobre {
  font-family: var(--f-dato); font-size: 12px; letter-spacing: .16em;
  text-transform: uppercase; color: var(--tinta-5);
  font-weight: 400; line-height: 1.4;
}
.intro__frase {
  margin: 0; font-family: var(--f-mano); font-weight: 500;
  font-size: clamp(48px, 7.5vw, 112px); line-height: 1.02; color: var(--tinta);
  text-wrap: pretty;
  letter-spacing: 0;
}
.intro__pluma-caja { position: relative; display: inline-block; width: 0; height: .8em; }
.intro__pluma {
  position: absolute; left: -.08em; bottom: -.02em; display: block;
  font-family: serif; font-size: .85em; line-height: 1; color: var(--acento);
  transform-origin: 0% 100%;
  font-weight: 400; letter-spacing: 0;
}
.intro__resto { color: #1a1918;
  font-family: inherit; font-size: inherit; font-weight: 400; line-height: 1.4; letter-spacing: 0;
}
.intro__barra { height: 1px; background: var(--linea); position: relative; }
.intro__progreso { position: absolute; left: 0; top: -1px; height: 3px; width: 0; background: var(--acento); }
.intro__pie {
  display: flex; justify-content: space-between; gap: 16px;
  font-family: var(--f-dato); font-size: 11px; letter-spacing: .14em;
  text-transform: uppercase; color: #8a8680;
}


/* ---------- 3. Cabecera, índice y progreso ---------- */
.cabecera {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  background: linear-gradient(#0a0a0a 0%, rgba(10,10,10,.85) 70%, rgba(10,10,10,0));
  padding: 14px clamp(16px, 3vw, 40px) 18px;
  display: flex; flex-direction: column; gap: 10px;
  pointer-events: none;
}
.cabecera__fila { display: flex; align-items: center; justify-content: space-between; gap: 16px; pointer-events: auto; }
.marca { display: flex; align-items: baseline; gap: 12px; }
.marca__nombre {
  font-family: var(--f-titulo); font-stretch: 70%; font-weight: 900;
  font-size: 24px; letter-spacing: .02em; text-transform: uppercase;
  line-height: 1.4; color: inherit;
}
.marca__edicion, .cabecera__actual {
  font-family: var(--f-dato); font-size: 11px; letter-spacing: .12em;
  text-transform: uppercase; color: var(--tinta-4);
}
.cabecera__actual { color: var(--tinta-2); letter-spacing: .1em;
  font-family: inherit; font-size: inherit; font-weight: 400; line-height: 1.4;
}
.cabecera__acciones { display: flex; align-items: center; gap: 16px; }

/* Botón "Intro" junto al Índice: vuelve a mostrar la animación de entrada */
.volver-intro {
  font-family: var(--f-dato); font-size: 11px; letter-spacing: .14em; text-transform: uppercase;
  background: transparent; color: var(--tinta); border: 0; padding: 10px 4px; min-height: 40px; cursor: pointer;
}
.volver-intro:hover { color: var(--acento, #E8542F); }

.indice { position: relative; }
.indice__boton {
  font-family: var(--f-dato); font-size: 11px; letter-spacing: .14em; text-transform: uppercase;
  background: transparent; color: var(--tinta);
  border: 1px solid var(--linea-3); padding: 10px 14px; min-height: 40px;
  cursor: pointer; display: flex; align-items: center; gap: 10px;
}
.indice__boton:hover { border-color: var(--tinta); }
.indice__flecha { display: inline-block; transition: transform .3s ease; }
.indice.abierto .indice__boton { background: var(--tinta); color: var(--fondo); }
.indice.abierto .indice__flecha { transform: rotate(180deg); }
.indice__panel {
  position: absolute; top: calc(100% + 10px); right: 0;
  width: min(460px, calc(100vw - 32px)); max-height: min(72vh, 660px); overflow: auto;
  background: rgba(14,13,12,.96);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--linea-2); box-shadow: 0 28px 70px rgba(0,0,0,.65);
  display: flex; flex-direction: column;
}
.indice__panel[hidden] { display: none; }
.indice__titulo {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 18px; border-bottom: 1px solid var(--linea);
  font-family: var(--f-dato); font-size: 11px; letter-spacing: .12em;
  text-transform: uppercase; color: var(--tinta-4);
}
.indice__cerrar { background: transparent; border: 0; color: var(--tinta-2); font-size: 16px; cursor: pointer; width: 32px; height: 32px; }
.indice__item {
  display: grid; grid-template-columns: 56px 36px minmax(0,1fr); gap: 14px; align-items: center;
  padding: 10px 18px; border-bottom: 1px solid #1f1d1c;
}
.indice__item:hover { background: #1c1a19; }
.indice__item.actual { background: #1a1817; }
.indice__foto { width: 56px; height: 56px; object-fit: cover; display: block; }
.indice__num { font-family: var(--f-dato); font-size: 13px; color: var(--acento);
  font-weight: 400; line-height: 1.4; letter-spacing: 0;
}
.indice__textos { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.indice__nombre {
  font-family: var(--f-titulo); font-stretch: 70%; font-weight: 800;
  font-size: 24px; line-height: 1; text-transform: uppercase;
  letter-spacing: 0; color: inherit;
}
.indice__frase {
  font-family: var(--f-texto); font-style: italic; font-size: 14px; color: var(--tinta-4);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  font-weight: 400; line-height: 1.4; letter-spacing: 0;
}

.progreso { display: grid; grid-template-columns: repeat(9, minmax(0,1fr)); gap: 4px; pointer-events: auto; }
.progreso__tramo { display: block; height: 12px; padding: 4px 0; cursor: pointer; }
.progreso__barra { display: block; height: 3px; background: var(--linea-2); position: relative; overflow: hidden; }
.progreso__relleno { position: absolute; left: 0; top: 0; bottom: 0; width: 0; background: var(--acento); }


/* ---------- 4. Portada del home ---------- */
.portada { position: relative; height: 170vh; }
.portada__fijo { position: sticky; top: 0; height: 100vh; overflow: hidden; }
.portada__mosaico {
  position: absolute; inset: 0;
  display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); grid-template-rows: repeat(2, minmax(0,1fr)); /* 8 fotos: 4 × 2 (con 9 fotos pasa solo a 3 × 3, ver .portada--9) */
  gap: 3px; will-change: transform;
}
.portada__mosaico img { width: 100%; height: 100%; object-fit: cover; display: block; }
.portada__sombra {
  position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(10,10,10,.4) 0%, rgba(10,10,10,0) 14%, rgba(10,10,10,0) 70%, rgba(10,10,10,.6) 100%);
}
/* Los textos de la portada se apoyan sobre la línea que divide las filas del mosaico,
   para no tapar las fotos de abajo. 4×2 → mitad (50%); 3×3 → línea inferior (33.333%). */
.portada__textos {
  position: absolute; left: 0; right: 0; bottom: 50%;
  display: flex; flex-direction: column; justify-content: flex-end; gap: 20px;
  padding: 0 clamp(24px, 5vw, 72px) clamp(14px, 2vh, 24px);
}
/* 7 fotos: 4 × 2 con la primera ocupando dos filas */
.portada--7 .portada__mosaico img:not([hidden]):first-child { grid-row: span 2; }
.portada--9 .portada__mosaico { grid-template-columns: repeat(3, minmax(0,1fr)); grid-template-rows: repeat(3, minmax(0,1fr)); }

.portada__sobre {
  font-family: var(--f-dato); font-size: 12px; letter-spacing: .16em;
  text-transform: uppercase; color: var(--acento);
  font-weight: 400; line-height: 1.4;
}
.portada__titulo {
  margin: 0; font-family: var(--f-titulo); font-stretch: 62%; font-weight: 900;
  font-size: clamp(96px, 22vw, 340px); line-height: .82; letter-spacing: -.01em;
  text-transform: uppercase; text-shadow: 0 4px 40px rgba(0,0,0,.55);
  color: inherit;
}
.portada__pie { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 24px; }
.portada__lema {
  margin: 0; max-width: 524px; font-family: var(--f-dato);
  font-size: clamp(19px, 2vw, 24px); line-height: 1.25; color: #FFFEFD;
  font-weight: 400; letter-spacing: 0;
}
.portada__desliza {
  font-family: var(--f-dato); font-size: 11px; letter-spacing: .16em;
  text-transform: uppercase; color: var(--tinta-4);
  font-weight: 400; line-height: 1.4;
}


/* ---------- 4b. AJUSTE de los textos de la portada ----------
   Los tres textos van apilados (uno debajo del otro), así "7 miradas…" nunca se monta
   sobre "PERFILES" aunque el título crezca o se achique con el ancho de la pantalla.
   padding-top de .portada__textos → altura donde empieza el bloque (más = baja)
   padding-left → distancia desde la izquierda
   margin-top de .portada__lema → espacio entre "PERFILES" y "7 miradas…"           */
.portada__textos  { top: 0; bottom: 0; height: auto; display: flex; flex-direction: column; justify-content: flex-start; align-items: flex-start; gap: 0;
                    padding: clamp(72px, 40vh, 380px) 24px 0 clamp(24px, 4.5vw, 65px); pointer-events: none; }
.portada__pie     { display: contents; }
.portada__sobre   { position: static; pointer-events: auto; }  /* Revista Página · Taller… */
.portada__titulo  { position: static; margin-top: 6px; margin-left: -.04em; pointer-events: auto; text-shadow: 0 4px 40px rgba(0,0,0,.55); }  /* PERFILES */
.portada__lema    { position: static; margin-top: clamp(16px, 2.4vw, 36px); width: min(524px, 80vw); pointer-events: auto; }    /* 7 miradas al mundo… */
.portada__desliza { position: absolute; bottom: 22px; right: clamp(24px,5vw,72px); pointer-events: auto; }                          /* Desliza ↓ */


/* ---------- 5. Presentación y lenguajes ---------- */
.presentacion {
  padding: clamp(80px, 14vh, 160px) clamp(20px, 5vw, 72px);
  display: flex; flex-direction: column; align-items: center; gap: 72px;
}
.presentacion__texto {
  margin: 0; max-width: 900px; font-family: var(--f-texto);
  font-size: clamp(26px, 3.4vw, 44px); line-height: 1.3; text-align: center; text-wrap: balance;
}
.editorial { width: 100%; max-width: 780px; display: flex; flex-direction: column; gap: 26px; }
.editorial p { margin: 0; font-family: var(--f-texto); font-size: 20px; line-height: 1.68; text-wrap: pretty; }
.editorial__sobre { font-family: var(--f-dato); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--acento); text-align: center;
  font-weight: 400; line-height: 1.4;
}
.editorial__titulo { margin: 0; font-family: var(--f-titulo); font-stretch: 70%; font-weight: 800; font-size: clamp(40px, 6vw, 72px); line-height: .95; letter-spacing: .01em; text-transform: uppercase; text-align: center; text-wrap: balance;
  color: inherit;
}
.editorial .editorial__entrada { margin-bottom: 14px; font-size: clamp(24px, 2.8vw, 34px); line-height: 1.3; font-style: italic; text-align: center; text-wrap: balance; }
.editorial__firma { margin-top: 8px; font-family: var(--f-dato); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: #9a9690;
  font-weight: 400; line-height: 1.4;
}
.lenguajes { width: 100%; max-width: 1000px; display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.lenguaje {
  flex: 0 1 150px; min-width: 130px;
  background: transparent; border: 1px solid var(--linea);
  padding: 14px 14px 16px; display: flex; flex-direction: column; gap: 6px;
}
.lenguaje__num { font-family: var(--f-dato); font-size: 11px; color: var(--acento);
  font-weight: 400; line-height: 1.4; letter-spacing: 0;
}
.lenguaje__nombre { font-family: var(--f-titulo); font-stretch: 75%; font-weight: 800; font-size: 18px; line-height: 1.05; text-transform: uppercase;
  letter-spacing: 0; color: inherit;
}
.lenguaje__dato { font-family: var(--f-dato); font-size: 10px; letter-spacing: .08em; color: var(--tinta-4); text-transform: uppercase;
  font-weight: 400; line-height: 1.4;
}


/* ---------- 6. Tarjetas de los perfiles ---------- */
.tarjetas-seccion { padding: 0 clamp(20px, 5vw, 72px) clamp(100px, 16vh, 180px); }
.tarjetas-seccion__caja { max-width: 1400px; margin: 0 auto; display: flex; flex-direction: column; gap: 28px; }
.tarjetas-seccion__titulo {
  font-family: var(--f-dato); font-size: 12px; letter-spacing: .14em;
  text-transform: uppercase; color: var(--tinta-4);
  font-weight: 400; line-height: 1.4;
}
.tarjetas { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 4px; }
.tarjeta { position: relative; display: block; aspect-ratio: 4/5; overflow: hidden; background: var(--fondo-foto); }
.tarjeta:hover { outline: 2px solid var(--acento); outline-offset: -2px; }
.tarjeta__foto {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  transition: transform .8s cubic-bezier(.2,.7,.2,1);
}
.tarjeta:hover .tarjeta__foto { transform: scale(1.05); }
.tarjeta__info {
  position: absolute; inset: 0; padding: 22px;
  background: linear-gradient(180deg, rgba(10,10,10,0) 40%, rgba(10,10,10,.92));
  display: flex; flex-direction: column; justify-content: flex-end; gap: 6px;
}
.tarjeta__num { font-family: var(--f-dato); font-size: 12px; color: var(--acento);
  font-weight: 400; line-height: 1.4; letter-spacing: 0;
}
.tarjeta__titulo { font-family: var(--f-titulo); font-stretch: 70%; font-weight: 800; font-size: 38px; line-height: .95; text-transform: uppercase;
  letter-spacing: 0; color: inherit;
}
.tarjeta__frase { font-family: var(--f-texto); font-style: italic; font-size: 16px; color: var(--tinta-2);
  font-weight: 400; line-height: 1.4; letter-spacing: 0;
}


/* ---------- 7. Perfil: piezas comunes ---------- */
.perfil { position: relative; }

/* Fila de etiqueta: "■ Audiovisual ........ 4:00" */
.etiqueta {
  width: 100%; max-width: 1280px;
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px;
  font-family: var(--f-dato); font-size: 11px; letter-spacing: .12em;
  text-transform: uppercase; color: var(--tinta-4);
  font-weight: 400; line-height: 1.4;
}
.etiqueta__nombre { display: flex; gap: 8px; flex-wrap: wrap; }
.etiqueta__nombre::before { content: "■"; color: var(--acento); }

/* Contenedor estándar de video, gráfico y herramienta */
.bloque {
  padding: 60px var(--margen) 40px;
  display: flex; flex-direction: column; align-items: center; gap: 16px;
}


/* ---------- 8. Perfil: apertura ---------- */
.apertura { position: relative; height: 200vh; }
.apertura__fijo { position: sticky; top: 0; height: 100vh; overflow: hidden; background: var(--fondo); }
.apertura__foto {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  transform: scale(1.18); will-change: transform;
}
.apertura__sombra {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(10,10,10,.2) 0%, rgba(10,10,10,.1) 40%, rgba(10,10,10,.95) 100%);
}
.apertura__textos {
  position: absolute; inset: 0; padding: clamp(24px, 5vw, 72px);
  display: flex; flex-direction: column; justify-content: flex-end; gap: 18px;
}
.apertura__num {
  font-family: var(--f-titulo); font-stretch: 62%; font-weight: 900;
  font-size: clamp(80px, 14vw, 200px); line-height: .8; color: var(--acento);
  letter-spacing: 0;
}
.apertura__titulo {
  margin: 0; font-family: var(--f-titulo); font-stretch: 65%; font-weight: 900;
  font-size: clamp(56px, 10vw, 160px); line-height: .85; text-transform: uppercase;
  letter-spacing: 0; color: inherit;
}
.apertura__pie { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 20px; }
.apertura__frase {
  margin: 0; max-width: 620px; font-family: var(--f-texto); font-style: italic;
  font-size: clamp(20px, 2.2vw, 28px); line-height: 1.35; color: #e4e0da;
  font-weight: 400; letter-spacing: 0;
}
.apertura__firma {
  font-family: var(--f-dato); font-size: 11px; letter-spacing: .12em;
  text-transform: uppercase; color: var(--tinta-3);
  font-weight: 400; line-height: 1.4;
}


/* ---------- 9. Perfil: texto ---------- */
.texto { padding: clamp(72px, 12vh, 140px) var(--margen) 80px; display: flex; justify-content: center; }
.texto__columnas {
  width: 100%; max-width: 1180px;
  display: flex; flex-wrap: wrap; gap: clamp(24px, 4vw, 64px); align-items: flex-start;
}
.texto__lateral {
  flex: 1 1 180px; max-width: 240px;
  position: sticky; top: 88px; z-index: 5; background: var(--fondo); padding: 10px 0;
  display: flex; flex-direction: column; gap: 10px;
  font-family: var(--f-dato); font-size: 11px; letter-spacing: .12em;
  text-transform: uppercase; color: var(--tinta-4);
}
.texto__barra { display: block; height: 3px; background: var(--linea-2); position: relative; overflow: hidden; }
.texto__relleno { position: absolute; left: 0; top: 0; bottom: 0; width: 0; background: var(--acento); }
.texto__pct { color: var(--tinta);
  font-family: inherit; font-size: inherit; font-weight: 400; line-height: 1.4; letter-spacing: 0;
}
.texto__cuerpo {
  flex: 999 1 560px; max-width: 780px; min-width: 0;
  font-family: var(--f-texto); font-size: 20px; line-height: 1.68; font-weight: 500;
  color: var(--tinta); text-wrap: pretty;
  display: flex; flex-direction: column; gap: 1.1em;
}
.texto__cuerpo p { margin: 0; }
/* Letra capital del primer párrafo */
.texto__cuerpo > p:first-child::first-letter {
  float: left; font-family: var(--f-titulo); font-stretch: 62%; font-weight: 900;
  font-size: 108px; line-height: .78; margin: 8px 12px 0 0; color: var(--acento);
}
/* Intertítulos */
.texto__cuerpo h3 {
  margin: 1.4em 0 0; font-family: var(--f-titulo); font-stretch: 70%; font-weight: 800;
  font-size: 32px; line-height: 1; letter-spacing: .01em; text-transform: uppercase;
}
/* Recuadro dentro del texto */
.recuadro {
  margin: 1.4em 0 0; border: 1px solid var(--linea-2); background: var(--fondo-caja);
  padding: clamp(24px, 4vw, 40px); display: flex; flex-direction: column; gap: 1em;
}
.recuadro h3 { margin: 0; line-height: 1.05; }


/* ---------- 10. Perfil: video ---------- */
.video { padding: 60px var(--margen); }
.video__marco { position: relative; width: 100%; max-width: 1280px; aspect-ratio: 16/9; background: #000; }
.video__marco video,
.video__marco iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; object-fit: cover; background: #000; }
.video__cubierta { position: absolute; inset: 0; border: 0; padding: 0; cursor: pointer; background: #000; display: block; }
.video__cubierta img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .7; }
.video__play {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  width: 104px; height: 104px; border-radius: 50%; background: var(--acento);
  display: flex; align-items: center; justify-content: center;
  color: var(--fondo); font-size: 34px; padding-left: 6px;
  font-family: inherit; font-weight: 400; line-height: 1.4; letter-spacing: 0;
}
.video__titulo {
  position: absolute; left: 24px; bottom: 22px; text-align: left; color: #fff;
  font-family: var(--f-titulo); font-stretch: 75%; font-weight: 800;
  font-size: clamp(20px, 2.4vw, 32px); text-transform: uppercase;
  line-height: 1.4; letter-spacing: 0;
}


/* ---------- 11. Perfil: serie fotográfica ---------- */
.serie { position: relative; height: 540vh; } /* funciones.js ajusta el alto según el número de fotos */
.serie__fijo {
  position: sticky; top: 0; height: 100vh; overflow: hidden;
  display: flex; flex-direction: column; justify-content: center; gap: 20px;
}
.serie__cabeza {
  display: flex; justify-content: space-between; padding: 0 var(--margen);
  font-family: var(--f-dato); font-size: 11px; letter-spacing: .12em;
  text-transform: uppercase; color: var(--tinta-4);
}
.serie__contador { display: flex; gap: 6px; }
.serie__actual { color: var(--tinta);
  font-family: inherit; font-size: inherit; font-weight: 400; line-height: 1.4; letter-spacing: 0;
}
.serie__pista { display: flex; gap: 16px; padding: 0 var(--margen); width: max-content; will-change: transform; }
.foto { margin: 0; display: flex; flex-direction: column; gap: 12px; flex: none; }
.foto img {
  height: min(68vh, 720px); width: auto; aspect-ratio: 3/2;
  object-fit: cover; display: block; cursor: zoom-in; background: var(--fondo-foto);
}
/* Formatos de foto */
.foto--horizontal img { aspect-ratio: 3/2; }
.foto--vertical img   { aspect-ratio: 2/3; }
.foto--retrato img    { aspect-ratio: 4/5; }
.foto--cuadrada img   { aspect-ratio: 1/1; }
.foto figcaption {
  max-width: 420px; display: flex; gap: 10px;
  font-family: var(--f-dato); font-size: 12px; line-height: 1.5; color: var(--tinta-3);
}
.foto__num { color: var(--acento); flex: none;
  font-family: inherit; font-size: inherit; font-weight: 400; line-height: 1.4; letter-spacing: 0;
}
/* Barra para recorrer la serie con clic o arrastrando */
.serie__control { margin: 4px var(--margen) 0; height: 32px; display: flex; align-items: center; cursor: pointer; touch-action: none; }
.serie__riel { position: relative; display: block; width: 100%; height: 4px; background: rgba(236,233,228,.18); border-radius: 2px; }
.serie__punto {
  position: absolute; top: 50%; left: 0; width: 18px; height: 18px; margin: -9px 0 0 -9px;
  border-radius: 50%; background: var(--acento); box-shadow: 0 0 0 4px rgba(10,10,10,.5); cursor: grab;
}


/* ---------- 12. Perfil: cita ---------- */
.cita-bloque { padding: 80px 20px 40px; display: flex; justify-content: center; }
.cita {
  margin: 0; max-width: 1000px; text-align: center; text-wrap: balance;
  font-family: var(--f-titulo); font-stretch: 70%; font-weight: 800;
  font-size: clamp(40px, 6vw, 88px); line-height: .98; text-transform: uppercase;
  letter-spacing: 0; color: inherit;
}
.cita::before { content: "“"; color: var(--acento); }
.cita::after  { content: "”"; color: var(--acento); }


/* ---------- 13. Perfil: pieza sonora ---------- */
.audio { padding: 60px var(--margen); display: flex; justify-content: center; }
.audio__caja {
  width: 100%; max-width: 1100px; border: 1px solid var(--linea-2); background: var(--fondo-caja);
  padding: clamp(24px, 4vw, 48px);
  display: grid; grid-template-columns: auto minmax(0,1fr); gap: clamp(20px, 3vw, 40px); align-items: center;
}
.audio__boton {
  width: clamp(80px, 9vw, 112px); height: clamp(80px, 9vw, 112px); border-radius: 50%; border: 0;
  background: var(--acento); color: var(--fondo); font-size: 30px; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}
.audio__info { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.audio__tiempo-actual { color: var(--tinta);
  font-family: inherit; font-size: inherit; font-weight: 400; line-height: 1.4; letter-spacing: 0;
}
.audio__titulo {
  font-family: var(--f-titulo); font-stretch: 75%; font-weight: 800;
  font-size: clamp(24px, 3vw, 40px); line-height: 1; text-transform: uppercase;
  letter-spacing: 0; color: inherit;
}
.audio__onda { height: 72px; display: flex; align-items: center; gap: 3px; cursor: pointer; }
.audio__onda span { flex: 1; min-width: 1px; background: var(--linea-3); border-radius: 1px; }
.audio__onda span.sonado { background: var(--acento); }


/* ---------- 14. Perfil: producto gráfico ---------- */
.grafico img { width: 100%; max-width: 1280px; display: block; cursor: zoom-in; background: var(--fondo-foto); }


/* ---------- 15. Perfil: herramienta digital ---------- */
.herramienta__cabeza { width: 100%; max-width: 1280px; display: flex; flex-direction: column; gap: 6px; }
.herramienta__titulo {
  font-family: var(--f-titulo); font-stretch: 75%; font-weight: 800;
  font-size: clamp(24px, 3vw, 40px); line-height: 1; text-transform: uppercase;
  letter-spacing: 0; color: inherit;
}
.herramienta__desc { font-family: var(--f-texto); font-style: italic; font-size: 17px; line-height: 1.45; color: var(--tinta-3);
  font-weight: 400; letter-spacing: 0;
}
.herramienta__marco {
  position: relative; width: 100%; max-width: 1280px; aspect-ratio: 16/10; min-height: 460px;
  background: var(--fondo-caja); border: 1px solid var(--linea-2); overflow: hidden;
}
.herramienta__marco iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; pointer-events: none; }
.herramienta__marco.activa iframe { pointer-events: auto; }
.herramienta__activar {
  position: absolute; inset: 0; width: 100%; height: 100%; border: 0; cursor: pointer; padding: 22px;
  background: linear-gradient(180deg, rgba(10,10,10,0) 55%, rgba(10,10,10,.85));
  display: flex; align-items: flex-end; justify-content: flex-start;
}
.herramienta__activar span {
  display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 14px 18px;
  background: var(--acento); color: var(--fondo);
  font-family: var(--f-dato); font-size: 12px; letter-spacing: .12em; text-transform: uppercase;
}
.herramienta__credito { width: 100%; max-width: 1280px; font-family: var(--f-dato); font-size: 11px; line-height: 1.5; color: var(--tinta-5);
  font-weight: 400; letter-spacing: 0;
}


/* ---------- 16. Separador entre perfiles ---------- */
.separador { padding: clamp(56px, 10vh, 110px) clamp(20px, 5vw, 72px); }
.separador span { display: block; max-width: 1400px; margin: 0 auto; height: 1px; background: var(--linea); position: relative; }
.separador span::before { content: ""; position: absolute; left: 0; top: -1px; height: 3px; width: 22%; background: var(--acento); }


/* ---------- 17. Créditos ---------- */
.creditos { border-top: 1px solid var(--linea); padding: clamp(72px, 12vh, 140px) clamp(20px, 5vw, 72px); }
.creditos__columnas { max-width: 1400px; margin: 0 auto; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 48px; }
.creditos__marca { display: flex; flex-direction: column; gap: 12px; }
.creditos__titulo { font-family: var(--f-titulo); font-stretch: 62%; font-weight: 900; font-size: 72px; line-height: .85; text-transform: uppercase;
  letter-spacing: 0; color: inherit;
}
.creditos__edicion { font-family: var(--f-dato); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--tinta-4);
  font-weight: 400; line-height: 1.4;
}
.creditos__repetir {
  align-self: flex-start; margin-top: 12px; min-height: 40px; padding: 10px 14px; cursor: pointer;
  font-family: var(--f-dato); font-size: 11px; letter-spacing: .14em; text-transform: uppercase;
  background: transparent; color: var(--tinta); border: 1px solid var(--linea-3);
}
.creditos__repetir:hover { border-color: var(--tinta); }
.creditos__grupo { display: flex; flex-direction: column; gap: 8px; font-family: var(--f-texto); font-size: 17px; line-height: 1.5; color: var(--tinta-2); }
.creditos__rol { font-family: var(--f-dato); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--acento);
  font-weight: 400; line-height: 1.4;
}
.creditos__institucional {
  max-width: 1400px; margin: 72px auto 0; padding-top: 48px; border-top: 1px solid var(--linea);
  display: flex; flex-wrap: wrap; align-items: center; gap: clamp(28px, 5vw, 72px);
}
.creditos__logos { width: min(100%, 560px); height: auto; display: block; }
.creditos__aviso { flex: 1 1 360px; max-width: 720px; margin: 0; font-family: var(--f-texto); font-size: 16px; line-height: 1.6; color: var(--tinta-3); text-wrap: pretty;
  font-weight: 400; letter-spacing: 0;
}


/* ---------- 18. Visor de fotos ---------- */
.visor {
  position: fixed; inset: 0; z-index: 90; background: rgba(5,5,5,.97);
  display: flex; align-items: center; justify-content: center;
  padding: clamp(16px, 4vw, 56px); cursor: zoom-out;
}
.visor[hidden] { display: none; }
.visor img { max-width: 100%; max-height: 86vh; object-fit: contain; display: block; }


/* Elementos guardados (ej. perfil 08): siguen en el código pero no se muestran.
   Para activarlos, borra "hidden" en index.html. */
[data-guardado][hidden] { display: none !important; }

/* Video de YouTube y audio de SoundCloud (incrustados) */
.video__youtube { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; background: #000; }
.audio__caja--soundcloud { display: flex; flex-direction: column; gap: 18px; }
.audio__soundcloud { width: 100%; height: 166px; border: 0; display: block; }
.video__enlace { display: block; text-decoration: none; }
.video__ver { position: absolute; right: 24px; bottom: 22px; font-family: var(--f-dato); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: #fff; }
/* Pieza interactiva del perfil 05 (línea de tiempo): alto fijo según su código de inserción */
.herramienta__marco--flourish { aspect-ratio: auto; min-height: 0; height: 650px; }
/* Pieza interactiva del perfil 03 (Flourish): alto fijo según su código de inserción */
.herramienta__marco--600 { aspect-ratio: auto; min-height: 0; height: 600px; }
/* Atmósfera sonora (perfil 02): caja pequeña antes de un párrafo, con reproductor mini de SoundCloud */
.atmosfera { position: relative; top: 0; left: 0; margin: 8px 0 0; padding: 16px 18px; border: 1px solid #2e2c2a; border-top: 2px solid var(--acento, #E8542F); background: #121110; display: flex; flex-direction: column; gap: 10px; max-width: 520px; }
.atmosfera__etiqueta { display: flex; justify-content: space-between; gap: 12px; font-family: 'JetBrains Mono', monospace; font-size: 11px; font-weight: 400; font-style: normal; line-height: 1.3; letter-spacing: .12em; text-transform: uppercase; color: #9a9690; }
.atmosfera__etiqueta b { color: var(--acento, #E8542F); font-weight: 400; margin-right: 6px; }
.atmosfera__instruccion { font-family: 'Source Serif 4', serif; font-size: 15px; font-weight: 400; font-style: italic; line-height: 1.45; color: #bdb9b3; }
.atmosfera__audio { width: 100%; height: 20px; border: 0; display: block; }
/* Pieza interactiva del perfil 04 (StoryMapJS): alto fijo según su código de inserción */
.herramienta__marco--800 { aspect-ratio: auto; min-height: 0; height: 800px; }
/* Pieza interactiva del perfil 06 (hoja de cálculo de Google): alto fijo y fondo blanco */
.herramienta__marco--hoja { aspect-ratio: auto; min-height: 0; height: 650px; background: #fff; }
