/* ════════════════════════════════════════════════════
   eam.css — ecoarte&medios
════════════════════════════════════════════════════ */

/* ── Fuente ── */
@font-face { font-family: 'Bellota'; src: url('../fonts/Bellota-Regular.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: 'Bellota'; src: url('../fonts/Bellota-Italic.woff2') format('woff2'); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: 'Bellota'; src: url('../fonts/Bellota-Medium.woff2') format('woff2'); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: 'Bellota'; src: url('../fonts/Bellota-MediumItalic.woff2') format('woff2'); font-weight: 500; font-style: italic; font-display: swap; }
@font-face { font-family: 'Bellota'; src: url('../fonts/Bellota-Bold.woff2') format('woff2'); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: 'Bellota'; src: url('../fonts/Bellota-BoldItalic.woff2') format('woff2'); font-weight: 700; font-style: italic; font-display: swap; }

/* ── Variables ── */
:root {
  --fondo: #0b0c0a;
  --tinta: #f3efe6;
  --tinta-suave: rgba(243, 239, 230, .74);


  --mezcla: overlay;
  --titulo-opacidad: .6;
  --margen: clamp(16px, 4vw, 48px);
  --cabecera: clamp(56px, 9vh, 84px);
  --alto: 100vh;
  --apacheta-alto: clamp(84px, 16vh, 132px);
  --apacheta-ancho: calc(var(--apacheta-alto) * .78);
  --suave: cubic-bezier(.22, .61, .36, 1);
}
@supports (height: 100svh) {
  :root { --alto: 100svh; }
}

/* ── Base ── */
*, *::before, *::after { box-sizing: border-box; }
html {
  scroll-snap-type: y mandatory;
  background: var(--fondo);
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  background: var(--fondo);
  color: var(--tinta);
  font-family: 'Bellota', system-ui, sans-serif;
  font-size: clamp(1rem, .94rem + .3vw, 1.2rem);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
img, svg, video, canvas { display: block; }
a { color: inherit; }
button { font: inherit; color: inherit; }
h1, h2, h3 { font-weight: 700; line-height: 1.05; margin: 0; }
:focus-visible { outline: 2px solid var(--c4); outline-offset: 3px; }

.aviso-dev {
  position: fixed; inset: 0 0 auto; z-index: 999; margin: 0;
  padding: .5rem 1rem; background: #a33; color: #fff; font-size: .9rem;
}

/* ── Cabecera ── */
.cabecera {
  position: fixed; inset: 0 0 auto; z-index: 50;
  height: var(--cabecera);
  padding: 0 var(--margen);
  padding-top: env(safe-area-inset-top);
  display: flex; align-items: center; justify-content: space-between;
  pointer-events: none;
}
.cabecera > * { pointer-events: auto; }
.cabecera-logo {
  width: clamp(120px, 13vw, 172px);
  color: var(--tinta);
  transition: opacity .5s var(--suave), transform .5s var(--suave);
}
.cabecera-logo .logo { width: 100%; height: auto; }
body[data-seccion="inicio"] .cabecera-logo { opacity: 0; transform: translateY(-8px); pointer-events: none; }

.cabecera-botones { display: flex; align-items: center; gap: 2px; margin-right: -10px; }
.sonido, .contemplar {
  width: 44px; height: 44px;
  display: grid; place-items: center;
  background: none; border: 0; padding: 0; cursor: pointer;
  opacity: .7; transition: opacity .3s;
}
.sonido svg, .contemplar svg {
  width: 24px; height: 24px;
  fill: none; stroke: var(--tinta); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round;
}
.sonido .sonido-parlante { fill: var(--tinta); stroke: none; }
.sonido.cargando svg { animation: latido 1s ease-in-out infinite alternate; }
@keyframes latido { to { opacity: .35; } }
.sonido[aria-pressed="false"] .sonido-on,
.sonido[aria-pressed="true"] .sonido-off { display: none; }

/* ── Contemplar ── */
.contemplando .cabecera-logo, .contemplando .apacheta, .contemplando .bajar, .contemplando .pista { opacity: 0 !important; pointer-events: none; }
.cabecera-botones { transition: opacity .9s var(--suave); }
.contemplando.quieto { cursor: none; }
.contemplando.quieto .cabecera-botones { opacity: 0; }
.contemplar[aria-pressed="true"] svg { fill: rgba(243, 239, 230, .25); }

/* ── Apacheta ── */
.apacheta {
  position: fixed; z-index: 40;
  right: var(--margen); bottom: 0;
  height: var(--apacheta-alto);
  aspect-ratio: 41.04 / 52.57;
  color: var(--tinta);
}
.no-js .apacheta { display: none; }
.apacheta-piedras { width: 100%; height: 100%; overflow: visible; }
.piedra {
  opacity: .16;
  transform: translateY(-3px);
  transition: opacity .6s var(--suave), transform .6s var(--suave);
}
.piedra.puesta { opacity: .62; transform: none; }
.piedra.actual { opacity: 1; }
.piedra.resaltada { opacity: .9; }
.apacheta ol { list-style: none; margin: 0; padding: 0; }
.apacheta a {
  position: absolute; left: -12px; right: -12px;
  display: flex; align-items: center; justify-content: flex-end;
  text-decoration: none;
}
.apacheta a span {
  position: absolute; right: calc(100% + 6px);
  font-size: .85rem; letter-spacing: .04em; white-space: nowrap;
  text-shadow: 0 0 8px rgba(0, 0, 0, .8);
  opacity: 0; translate: 6px 0;
  transition: opacity .3s, translate .3s var(--suave);
  pointer-events: none;
}
.apacheta a:focus-visible { outline-offset: 0; }

/* ── Secciones ── */
.seccion {
  position: relative;
  min-height: var(--alto);
  scroll-snap-align: start;
  display: grid;
  place-items: center;
  overflow: hidden;
  overflow: clip;
}
.seccion-contenido {
  position: relative; z-index: 2;
  width: min(100% - 2 * var(--margen), 64rem);
  padding-block: calc(var(--cabecera) + 1.5rem) 4rem;
}
.velo {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at 50% 45%, rgba(0, 0, 0, .12), rgba(0, 0, 0, .58) 75%);
}

/* ── Precarga ── */
.precarga { display: none; }
.js .precarga {
  position: fixed; inset: 0; z-index: 1000;
  display: grid; place-items: center;
  background: var(--fondo); color: var(--tinta);
  transition: opacity .6s var(--suave), visibility .6s;
}
.precarga.ida { opacity: 0; visibility: hidden; }
.precarga-piedras { width: 52px; height: auto; overflow: visible; }
.precarga .piedra { opacity: 1; transform: none; transition: none; }

/* ── Tipo B: espejo ── */
.tipo-b, .espejado { touch-action: pan-y; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
.espejo {
  grid-area: 1 / 1; align-self: start; justify-self: stretch;
  position: sticky; top: 0;
  height: var(--alto);
  background: var(--color, #15140f);
  pointer-events: none;
}
.tipo-b > .seccion-contenido { grid-area: 1 / 1; z-index: auto; }
.espejado > .seccion-contenido { grid-area: 1 / 1; }
.espejado .velo { background: radial-gradient(ellipse at 50% 45%, rgba(0, 0, 0, .4), rgba(0, 0, 0, .72) 75%); }
.espejo-lienzo {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  opacity: 0;
  transition: opacity .8s var(--suave);
}
.espejo.vivo .espejo-lienzo { opacity: 1; }
.espejo-mitad {
  position: absolute; top: 0; bottom: 0; left: 0;
  width: 50%;
  overflow: hidden;
}
.espejo-reflejo { left: 50%; transform: scaleX(-1); }
.espejo :is(img, video) {
  position: absolute; top: 0; left: 0;
  width: 200%; height: 100%;
  object-fit: cover;
}
.pieza-central { display: grid; place-items: center; text-align: center; gap: 1.2rem; pointer-events: none; }
.pieza-central :is(a, button) { pointer-events: auto; }
.hero-logo { width: min(78vw, 640px); }
.hero-logo .logo { width: 100%; height: auto; }
.provisional {
  font-size: clamp(2rem, 8vw, 5rem); font-weight: 500;
  opacity: .5; letter-spacing: .02em;
}
.pista { position: absolute; inset: 0; z-index: 3; pointer-events: none; opacity: 0; transition: opacity .6s var(--suave); }
.pista.activa { opacity: 1; }
.pista-dedo {
  position: absolute; left: 0; top: 0;
  width: 26px; height: 26px; margin: -13px 0 0 -13px;
  border-radius: 50%;
  border: 1.5px solid rgba(243, 239, 230, .9);
  background: rgba(243, 239, 230, .16);
  box-shadow: 0 0 18px rgba(255, 255, 255, .3);
  transition: opacity .5s;
}
.pista.suelta .pista-dedo, .pista.quieta .pista-dedo { opacity: 0; }
.pista-texto {
  position: absolute; left: 50%; top: 70%;
  translate: -50% 0;
  font-size: .95rem; letter-spacing: .24em;
  color: var(--tinta);
  text-shadow: 0 0 10px rgba(0, 0, 0, .85);
}
.bajar {
  position: absolute; z-index: 2; left: 50%; bottom: max(1.5rem, env(safe-area-inset-bottom));
  translate: -50% 0;
  width: 44px; height: 56px;
  display: grid; place-items: center;
}
.bajar svg { width: 14px; height: 20px; fill: var(--tinta); opacity: .75; animation: gota 2.6s var(--suave) infinite; }
@keyframes gota {
  0%   { transform: translateY(-10px) scale(.6); opacity: 0; }
  30%  { opacity: .8; }
  70%  { transform: translateY(10px) scale(1); opacity: .8; }
  100% { transform: translateY(16px) scale(1.1, .5); opacity: 0; }
}

/* ── Tipo A y D: fondo fijo y título mezclado ── */
.con-fondo-fijo { clip-path: inset(0); }
.fondo-fijo {
  position: fixed; inset: 0; z-index: 0;
  background:
    radial-gradient(ellipse at 30% 20%, rgba(135, 127, 41, .28), transparent 60%),
    radial-gradient(ellipse at 75% 80%, rgba(106, 123, 37, .22), transparent 55%),
    var(--color, #12130f);
}
.fondo-fijo :is(img, video) { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.titulo-fondo {
  position: absolute; z-index: 1; top: 0; left: 0; right: 0;
  height: var(--alto);
  display: grid; place-items: center;
  margin: 0; padding: 0 2vw;
  font-size: min(calc(96vw / (var(--letras) * .52)), 42vh);
  line-height: .85;
  color: #fff;
  opacity: var(--titulo-opacidad);
  mix-blend-mode: var(--mezcla);
  pointer-events: none;
  user-select: none;
  white-space: nowrap;
}

/* ── Manifiesto ── */
.linea { display: block; }
.manifiesto .linea { white-space: nowrap; }
.manifiesto {
  max-width: 46rem;
  font-size: min(clamp(1.1rem, 1rem + .7vw, 1.55rem), calc((100vw - 2 * var(--margen) - 1rem) / (var(--largo, 40) * .52))); line-height: 1.6;
  text-shadow: 0 0 14px rgba(0, 0, 0, .7);
}
.manifiesto { padding-block: 50vh 100vh; }
.js .manifiesto .linea { opacity: 0; transform: translateY(1.6em) scale(.97); filter: blur(4px); }
.js .manifiesto .linea.arriba { transform: translateY(-1.6em) scale(.97); }
.js .manifiesto .linea { transition: opacity 1.1s var(--suave), transform 1.1s var(--suave), filter 1.1s var(--suave); }
.js .manifiesto .linea.vista { opacity: 1; transform: none; filter: none; }
.manifiesto p { margin: 0 0 1.5em; }
.manifiesto p:last-child { margin-bottom: 0; }
.tipo-b:has(.manifiesto) .velo { background: radial-gradient(ellipse at 50% 50%, rgba(0, 0, 0, .45), rgba(0, 0, 0, .72) 80%); }
@media (max-width: 759px) {
  .seccion-contenido:has(.manifiesto) { width: calc(100% - 1.2rem); }
  .manifiesto { font-size: min(clamp(1.1rem, 1rem + .7vw, 1.55rem), calc((100vw - 1.2rem) / (var(--largo, 40) * .5))); }
  .manifiesto .linea { line-height: max(1.6em, calc(100svh / 11)); }
  .manifiesto p { margin-bottom: .6em; }
}

/* ── Tipo A ── */
.tipo-a .seccion-contenido { max-width: 40rem; }
.tipo-a p { margin: 0 0 1.2em; font-size: clamp(1.1rem, 1rem + .7vw, 1.5rem); line-height: 1.6; }

/* ── Tipo D: eventos ── */
@property --tono-tarjeta { syntax: '<color>'; inherits: true; initial-value: transparent; }
.tipo-d .seccion-contenido { width: min(100% - 2 * var(--margen) - 2 * var(--apacheta-ancho), 100rem); padding-block: 0; }
.eventos {
  list-style: none; margin: 0; padding: 0;
  display: grid; gap: 0;
  grid-template-columns: 1fr;
}
@media (min-width: 640px) { .eventos { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .eventos { grid-template-columns: repeat(4, 1fr); } }
.evento {
  --tono-tarjeta: var(--tono);
  display: flex; flex-direction: column;
  cursor: pointer;
  transition: --tono-tarjeta .45s var(--suave);
  min-height: var(--alto);
  scroll-snap-align: start;

  background: rgba(11, 12, 10, .62);
  backdrop-filter: blur(8px);
}
.evento-marco { flex: 1 1 0; min-height: 9rem; display: flex; }
.evento-foto {
  position: relative;
  flex: 1;
  overflow: hidden;
  background: rgba(11, 12, 10, .4);
}
.evento-foto img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.evento-diapo { position: absolute; inset: 0; opacity: 0; transition: opacity 1.6s var(--suave); }
.evento-diapo.activa { opacity: 1; }
.evento-foto::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(to top, var(--tono-tarjeta), transparent 65%);
}
.evento h3 {
  padding: .8rem 1.4rem;
  background: var(--tono-tarjeta); color: #000;
  text-transform: uppercase; letter-spacing: .04em;
  font-size: clamp(1.05rem, .95rem + .5vw, 1.4rem);
}
.evento-texto { padding: 1.3rem 1.4rem 1.4rem; }
.evento p { margin: 0; color: var(--tinta-suave); font-size: clamp(1.02rem, .98rem + .25vw, 1.15rem); line-height: 1.55; }
.evento .proxima { margin-top: 1rem; color: var(--tinta); }
.evento .proxima + .proxima { margin-top: .6rem; }
.proxima-rotulo { display: block; font-weight: 700; }
.evento .boton { align-self: stretch; background: var(--tono-tarjeta); color: #000; }

.tipo-b .pieza-central:has(.frase) { width: 100%; }
.titulo-svg {
  width: min(78vw, 760px); color: #fff;
  mix-blend-mode: var(--mezcla-titulo, overlay);
  opacity: .9;
  pointer-events: auto; cursor: grab; touch-action: none;
}
.titulo-svg.arrastrando { cursor: grabbing; }

/* ── Palíndromos: SVG a la escala del título, con su mezcla; cada uno se arrastra en vertical ── */
.palindromos { position: absolute; inset: 0; pointer-events: none; }
.palindromo {
  position: absolute; left: 50%; top: var(--y, 50%);
  width: calc(min(78vw, 760px) * var(--proporcion, .25)); margin: 0;
  translate: -50% -50%;
  color: #fff; mix-blend-mode: var(--mezcla-titulo, overlay); opacity: .9;
  pointer-events: auto; cursor: grab; touch-action: none;
}
.palindromo-dibujo { display: block; width: 100%; height: auto; }
.palindromo.arrastrando { cursor: grabbing; }
.js .palindromos:not(.listo) .palindromo { visibility: hidden; }
.no-js .palindromos { display: none; }
.titulo-svg-dibujo { width: 100%; height: auto; }

/* ── Botones ── */
.boton {
  padding: .8em 1.5em;
  border: 0;
  background: var(--tono-osc, var(--c4-osc)); color: var(--tinta);
  font-weight: 700; letter-spacing: .02em;
  cursor: pointer;
  transition: background .3s, color .3s;
}

/* ── Tipo C: mosaico ── */
.tipo-c { height: var(--alto); background: #000; }
.mosaico {
  position: absolute; inset: 0;
  display: grid;
  grid-template-columns: repeat(var(--cols, 4), 1fr);
  grid-template-rows: repeat(var(--filas, 3), 1fr);
  background: #000;
  overflow: hidden;
}
.no-js .mosaico { grid-template-rows: none; grid-auto-rows: 1fr; }
.celda { position: relative; margin: 0; min-width: 0; min-height: 0; overflow: hidden; background: #000; }
.celda img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  clip-path: circle(0% at var(--x, 50%) var(--y, 50%));
  transition: clip-path 1.6s var(--suave);
}
.celda.cargada img, .no-js .celda img { clip-path: circle(150% at var(--x, 50%) var(--y, 50%)); }

/* ── Contacto y enlaces ── */
.tipo-pie {
  background:
    radial-gradient(ellipse at 50% 110%, rgba(106, 123, 37, .32), transparent 60%),
    var(--fondo);
}
.pie { display: grid; gap: clamp(2.5rem, 6vh, 4.5rem); width: min(100% - 2 * var(--margen), 70rem); }
.pie h2 { font-size: clamp(2.4rem, 2rem + 3vw, 4.5rem); text-align: center; }
.pie-invitacion {
  display: flex; flex-wrap: wrap; align-items: baseline; justify-content: center; gap: .1em .32em;
  text-align: center;
}
.pie-invitacion p { margin: 0; }
.pie-invitacion .boton { padding: .04em .32em .1em; font-size: 1em; font-weight: inherit; line-height: inherit; color: #000; }
.pie-enlaces {
  --objeto: clamp(10rem, 24vh, 14.5rem);
  align-items: start;
  display: grid; gap: clamp(2.5rem, 6vw, 6rem); width: 100%;
  grid-template-columns: 1fr;
}
@media (min-width: 760px) { .pie-enlaces { grid-template-columns: 1fr 1fr; } }
.pie-columna { display: grid; align-content: start; gap: clamp(1.2rem, 3vh, 2rem); justify-items: start; }
.pie-invitacion, .pie-subtitulo { font-size: clamp(.95rem, .5rem + 2vw, 2.4rem); line-height: 1.2; }
.pie-subtitulo { margin: 0 0 calc(-1 * clamp(.4rem, 1.5vh, 1rem)); font-weight: inherit; color: var(--tinta); }
.pie-texto { margin: 0; max-width: 40ch; color: var(--tinta-suave); font-size: clamp(1.05rem, .92rem + .45vw, 1.3rem); line-height: 1.55; }
@media (max-width: 759px) {
  .tipo-pie > .pie { padding-block: calc(var(--cabecera) + .2rem) 1rem; gap: 1rem; }
  .pie-enlaces { --objeto: clamp(4.8rem, 13vh, 7.5rem); gap: 1.1rem; }
  .pie-columna { gap: .4rem; }
  .pie-invitacion, .pie-subtitulo { font-size: 1.05rem; }
  .pie-subtitulo { margin-bottom: 0; }
  .pie-texto { font-size: .8rem; line-height: 1.38; }
  .pie-columna > :last-child { margin-top: .2rem; }
}

/* ── El documento, como cuaderno ── */
.enlace-documento {
  position: relative; display: block;
  height: var(--objeto); max-width: calc(100% - 8px);
  aspect-ratio: var(--proporcion, .75);
  perspective: 900px;
  text-decoration: none;
}
.enlace-documento[aria-disabled="true"] { opacity: .45; }
.cuaderno-hojas {
  position: absolute; inset: 3% 0 3% 4%;
  background: repeating-linear-gradient(90deg, #ece6d8 0 3px, #d9d2c2 3px 4px);
  box-shadow: 4px 4px 0 #c9c2b2, 8px 8px 0 #b3ac9c;
}
.cuaderno-tapa {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; justify-content: space-between;
  padding: 1.3rem 1.1rem 1.1rem 1.6rem;
  background: linear-gradient(150deg, var(--c3-osc), var(--c5-osc));
  text-align: start;
  transform-origin: left center;
  transition: transform .8s var(--suave), box-shadow .8s var(--suave);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .45);
}
.cuaderno-portada { position: absolute; inset: 0; z-index: -1; overflow: hidden; }
.cuaderno-portada img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.cuaderno-tapa { isolation: isolate; overflow: hidden; }
.cuaderno-tapa .enlace-titulo { font-size: 1.35rem; text-shadow: 0 1px 8px rgba(0, 0, 0, .6); }
.cuaderno-tapa small { font-size: .85rem; color: rgba(243, 239, 230, .85); }

/* ── Autorretrato colectivo: un visor sobrio; al pasar, las esquinas del logo se abren ── */
.enlace-autorretrato {
  position: relative;
  display: grid; place-items: center;
  height: var(--objeto); width: min(100%, calc(var(--objeto) * 1.9));
  text-decoration: none; color: var(--tinta);
  background: rgba(11, 12, 10, .62);
  box-shadow: inset 0 0 0 1px rgba(243, 239, 230, .16), 0 10px 30px rgba(0, 0, 0, .35);
  backdrop-filter: blur(6px);
  transition: box-shadow .5s var(--suave), background .5s var(--suave);
}
.autorretrato-logo svg { display: block; height: calc(var(--objeto) * .5); width: auto; overflow: visible; }
.autorretrato-logo polyline { transition: transform .55s var(--suave); }

/* ── Foto en grande ── */
.celda { cursor: zoom-in; }
.visor {
  width: 100vw; height: 100dvh; max-width: none; max-height: none;
  margin: 0; padding: 0; border: 0;
  background: rgba(0, 0, 0, .94);
}
.visor::backdrop { background: #000; }
.visor[open] { display: grid; place-items: center; animation: aparecer .35s var(--suave); }
.visor img { max-width: 100%; max-height: 100%; object-fit: contain; user-select: none; -webkit-user-drag: none; }
.visor-paso, .visor-cerrar {
  position: absolute; width: 56px; height: 56px;
  display: grid; place-items: center;
  border: 0; background: none; cursor: pointer; opacity: .7;
}
.visor-paso { top: 50%; translate: 0 -50%; }
.visor-paso::before { content: ''; width: 14px; height: 14px; border-left: 2px solid var(--tinta); border-bottom: 2px solid var(--tinta); }
.visor-ant { left: 8px; }
.visor-ant::before { transform: rotate(45deg); margin-left: 6px; }
.visor-sig { right: 8px; }
.visor-sig::before { transform: rotate(-135deg); margin-right: 6px; }
.visor.una .visor-paso { display: none; }
.visor-cerrar { top: 8px; right: 8px; }
.visor-cerrar svg { width: 22px; height: 22px; fill: none; stroke: var(--tinta); stroke-width: 1.6; stroke-linecap: round; }

/* ── Contacto (modal) ── */
.contacto {
  width: min(100% - 2 * var(--margen), 34rem);
  max-height: calc(100dvh - 2rem);
  padding: 0; border: 0;
  border-top: 3px solid var(--tono, var(--c4));
  background: #12130f; color: var(--tinta);
  overflow: auto;
}
.contacto[open] { animation: aparecer .45s var(--suave); }
.contacto::backdrop { background: rgba(5, 5, 4, .72); backdrop-filter: blur(4px); }
@keyframes aparecer { from { opacity: 0; transform: translateY(14px); } }
.contacto-form { position: relative; padding: clamp(1.4rem, 4vw, 2.2rem); }
.contacto h2 { font-size: clamp(1.6rem, 1.3rem + 1.4vw, 2.2rem); margin-bottom: .6rem; }
.contacto-cerrar {
  position: absolute; top: .4rem; right: .4rem;
  width: 44px; height: 44px; display: grid; place-items: center;
  background: none; border: 0; cursor: pointer; opacity: .7;
}
.contacto-cerrar svg { width: 20px; height: 20px; fill: none; stroke: var(--tinta); stroke-width: 1.6; stroke-linecap: round; }
.campo { position: relative; margin-top: 1.5rem; }
.campo :is(input, textarea, select) {
  display: block; width: 100%;
  padding: .95em .8em .55em;
  border: 0; border-bottom: 1px solid rgba(243, 239, 230, .35); border-radius: 0;
  background: rgba(243, 239, 230, .05);
  color: var(--tinta); font: inherit;
  appearance: none;
  transition: border-color .25s, background .25s;
}
.campo textarea { resize: vertical; min-height: 7.5em; }
.campo select option { background: #12130f; color: var(--tinta); }
.campo :is(input, textarea, select):focus { outline: none; border-bottom-color: var(--tono, var(--c4)); background: rgba(243, 239, 230, .08); }
.campo label {
  position: absolute; left: .8em; top: .95em;
  color: var(--tinta-suave);
  pointer-events: none;
  transform-origin: left top;
  transition: transform .25s var(--suave), color .25s;
}
.campo :is(input, textarea):is(:focus, :not(:placeholder-shown)) + label,
.campo select:focus + label,
.campo.lleno label { transform: translateY(-1.7em) scale(.78); color: var(--tinta); }
.campo-lista::after {
  content: '';
  position: absolute; right: 1em; top: 50%;
  width: .5em; height: .5em; margin-top: -.35em;
  border-right: 1.5px solid var(--tinta-suave); border-bottom: 1.5px solid var(--tinta-suave);
  transform: rotate(45deg);
  pointer-events: none;
}
.campo-tipo { display: block; min-height: 1.3em; margin-top: .3em; font-size: .85rem; color: var(--tinta-suave); }
.campo-contacto.es-correo .campo-tipo::before { content: '✉ '; }
.campo-contacto.es-whatsapp .campo-tipo::before { content: '✆ '; }
.campo-contacto.invalido .campo-tipo { color: var(--c12); }
.campo [aria-invalid="true"] { border-bottom-color: var(--c12); }
.casilla { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem 1rem; margin-top: .6rem; font-size: .92rem; color: var(--tinta-suave); }
.casilla[hidden] { display: none; }
.casilla label { display: flex; align-items: center; gap: .5rem; cursor: pointer; }
.casilla input { width: 1.1rem; height: 1.1rem; accent-color: var(--tono, var(--c4)); }
.casilla a { font-size: .85rem; }
.contacto-pie { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; margin-top: 1.2rem; }
.campo-suma { margin-top: 1.5rem; width: 7.5rem; }
.contacto-pie .boton { margin-left: auto; }
.contacto-estado { min-height: 1.4em; margin: 1rem 0 0; font-size: .95rem; text-align: right; }
.contacto-estado.error { color: #e48a9e; }
.contacto-estado.ok { color: var(--c5); }

/* ── Hover ── */
.evento:has(.boton:focus-visible) { --tono-tarjeta: var(--tinta); }

@media (any-hover: hover) {
  .sonido:hover, .contemplar:hover, .contacto-cerrar:hover { opacity: 1; }
  .boton:hover { background: var(--tinta); color: #15140f; }
  .evento:hover { --tono-tarjeta: var(--tinta); }
  .enlace-documento:not([aria-disabled]):hover .cuaderno-tapa { transform: rotateY(-32deg); box-shadow: 14px 10px 30px rgba(0, 0, 0, .5); }
  .enlace-autorretrato:hover { background: rgba(11, 12, 10, .78); box-shadow: inset 0 0 0 1px rgba(243, 239, 230, .45), 0 10px 30px rgba(0, 0, 0, .35); }
  .enlace-autorretrato:hover polyline:nth-of-type(1) { transform: translate(2.5px, -2.5px); }
  .enlace-autorretrato:hover polyline:nth-of-type(2) { transform: translate(-2.5px, -2.5px); }
  .enlace-autorretrato:hover polyline:nth-of-type(3) { transform: translate(2.5px, 2.5px); }
  .enlace-autorretrato:hover polyline:nth-of-type(4) { transform: translate(-2.5px, 2.5px); }
  .visor-paso:hover, .visor-cerrar:hover { opacity: 1; }
}

/* ── Pantallas táctiles ── */
@media not (any-pointer: fine) {
  .apacheta { --apacheta-alto: clamp(52px, 8vh, 72px); }
  .apacheta a { left: -18px; right: -18px; }
}

/* ── Pantallas angostas ── */
@media (max-width: 700px) {
  .frase { flex-direction: column; gap: calc(7 * var(--u)); font-size: min(calc((100vw - 2 * var(--margen)) * 9 / 236), 30px); }
}
@media (max-width: 700px), not (any-pointer: fine) {
  .tipo-d .seccion-contenido { width: min(100% - 2 * var(--margen), 100rem); }
}

/* ── Movimiento reducido ── */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .bajar svg { animation: none; opacity: .75; }
  .piedra, .cabecera-logo, .frase, .frase *, .celda img { transition: none !important; }
  .autorretrato-logo polyline { transition: none; }
  .js .manifiesto .linea { opacity: 1; transform: none; }
}
