/* ═══════════════════════════════════════════════════════════════════════════
   MUJERES QUE INSPIRAN — Estilos
   Tótem vertical (9:16) + pantalla interna de video + mobile (destino QR)
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── Fuente local: Inter Variable (bold → nombres, light → texto descriptivo) ── */
@font-face {
  font-family: "Inter Variable";
  src:
    url("../fonts/inter-variable.woff2") format("woff2"),
    url("../fonts/inter-variable.woff") format("woff");
  font-weight: 100 900; /* variable: usa 700 (bold) y 300 (light) */
  font-style: normal;
  font-display: swap;
}

:root {
  --fondo: #0d0d0f;
  --fondo-suave: #16161a;
  --tinta: #f5f3ef;
  --tinta-suave: rgba(245, 243, 239, 0.72);
  --linea: rgba(245, 243, 239, 0.12);
  --rosa: #c13584;
  --violeta: #833ab4;
  --oro: #e8cfa0;
  --radius: 14px;
  --fuente-titulo:
    "Inter Variable", "Inter", system-ui, -apple-system, sans-serif;
  --fuente-texto:
    "Inter Variable", "Inter", system-ui, -apple-system, sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  height: 100%;
  overflow: hidden; /* tótem: sin scroll */
  background: var(--fondo);
  color: var(--tinta);
  font-family: var(--fuente-texto);
  -webkit-font-smoothing: antialiased;
  touch-action: manipulation;
}

body.totem {
  position: relative;
  height: 100dvh;
  overflow: hidden;
}

img {
  display: block;
  max-width: 100%;
}
a {
  text-decoration: none;
  color: inherit;
}

/* ═══════════════════════════ MOSAICO 2×4 ═══════════════════════════
   Mosaico continuo: 2 columnas × 4 filas, 8 celdas iguales.
   Cada celda = 50% ancho × 25% alto de la pantalla (9:16).
   Gap 0px: sin márgenes internos ni bordes entre celdas.          */

.grid {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr); /* 2 columnas */
  grid-template-rows: repeat(4, 1fr); /* 4 filas     */
  gap: 0; /* mosaico continuo */
}

.tile {
  position: relative;
  display: flex;
  overflow: hidden; /* las fotos llenan la celda */
  background: var(--fondo-suave);
  cursor: pointer;
  min-width: 0;
  min-height: 0;
  -webkit-tap-highlight-color: transparent;
  border: 0; /* reset de <button> */
  padding: 0;
  font: inherit;
  color: inherit;
  text-align: inherit;
}

/* ── Foto ── */
.tile--foto {
  transition: filter 0.3s ease;
}

.tile--foto:hover,
.tile--foto:focus-visible {
  filter: brightness(1.15);
  outline: none;
  z-index: 2;
}

.tile__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.tile--foto:hover .tile__img {
  transform: scale(1.04);
}

/* Overlay: oculto por defecto. Tap en la foto → .is-activo lo muestra.
   Capa negra al 80% con play + nombre + subtítulo en la esquina INFERIOR IZQUIERDA.
   Al quitarse: fade-out 0.4s (visibility espera la transición). */
.tile__overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start; /* esquina inferior izquierda */
  justify-content: flex-end;
  gap: clamp(6px, 1vmin, 12px);
  padding: clamp(10px, 1.6vmin, 20px);
  background: rgba(0, 0, 0, 0.8); /* capa negra 80% de opacidad */
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.4s ease,
    visibility 0s linear 0.4s;
}

.tile--foto.is-activo .tile__overlay {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.4s ease;
}

.tile__play {
  width: clamp(40px, 5.8vmin, 64px);
  height: clamp(40px, 5.8vmin, 64px);
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(245, 243, 239, 0.95);
  color: var(--fondo);
  font-size: clamp(13px, 2vmin, 22px);
  padding-left: 3px; /* centrar el triángulo */
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
  transition:
    transform 0.25s ease,
    background 0.25s ease;
}

.tile--foto.is-activo .tile__play:hover,
.tile--foto.is-activo .tile__play:focus-visible {
  transform: scale(1.12);
  background: var(--oro);
}

.tile__meta {
  text-align: left;
}

.tile__nombre {
  display: block;
  font-family: var(--fuente-titulo);
  font-size: clamp(16px, 2.8vmin, 30px);
  font-weight: 700; /* bold para nombres */
  line-height: 1.15;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.65);
}

.tile__subtitulo {
  display: block;
  font-size: clamp(10px, 1.5vmin, 17px);
  font-weight: 300; /* light para texto descriptivo */
  color: rgba(245, 243, 239, 0.82);
  letter-spacing: 0.02em;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.65);
}

/* ── Bloque de marca → imagen (Ellas / Inspira) ── */
.tile--imagen {
  cursor: default; /* decorativo, sin interacción */
}

.tile--imagen .tile__img {
  position: absolute;
}

/* ── Bloque de color ── */
.tile--bloque {
  background:
    radial-gradient(
      120% 90% at 85% 10%,
      rgba(255, 255, 255, 0.16) 0%,
      transparent 55%
    ),
    var(--tile-color, var(--rosa));
}

.tile__contenido {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: clamp(3px, 0.7vmin, 10px);
  padding: clamp(10px, 1.7vmin, 24px);
  width: 100%;
}

.tile__titulo {
  font-family: var(--fuente-titulo);
  font-size: clamp(17px, 3vmin, 36px);
  font-weight: 700;
  font-style: italic;
  line-height: 1.05;
}

.tile__texto {
  font-size: clamp(9px, 1.3vmin, 15px);
  color: rgba(255, 255, 255, 0.92);
  line-height: 1.45;
  max-width: 30ch;
}

/* ═══════════════════════════ OVERLAYS (flotan sobre el mosaico) ═══════════════════════════ */

.totem-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: clamp(6px, 1vmin, 12px);
  padding: clamp(6px, 1.1vmin, 14px) clamp(10px, 1.6vmin, 20px);
  background: linear-gradient(
    to bottom,
    rgba(10, 10, 12, 0.65) 0%,
    transparent 100%
  );
  pointer-events: none; /* no bloquea el tótem */
}

.totem-logo__icon {
  font-size: clamp(16px, 2.2vmin, 26px);
  color: var(--oro);
}

.totem-logo__nombre {
  font-family: var(--fuente-titulo);
  font-size: clamp(14px, 2vmin, 24px);
  font-weight: 600;
  letter-spacing: 0.02em;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7);
}

.totem-header__hint {
  margin-left: auto;
  font-size: clamp(8px, 1.1vmin, 13px);
  color: rgba(245, 243, 239, 0.9);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7);
}

.totem-footer {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: clamp(5px, 1vmin, 12px);
  background: linear-gradient(
    to top,
    rgba(10, 10, 12, 0.6) 0%,
    transparent 100%
  );
  pointer-events: none;
}

.totem-footer__texto {
  font-size: clamp(8px, 1vmin, 12px);
  color: rgba(245, 243, 239, 0.85);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7);
}

.totem-footer__qr {
  color: var(--oro);
  font-size: clamp(12px, 1.6vmin, 18px);
  letter-spacing: 2px;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7);
}

/* ═══════════════════════════ PANTALLA INTERNA ═══════════════════════════ */

body.interna {
  display: flex;
  flex-direction: column;
  height: 100dvh;
  background: #000;
}

.interna__volver {
  position: fixed;
  top: clamp(12px, 2vmin, 24px);
  left: clamp(12px, 2vmin, 24px);
  z-index: 10;
  padding: 8px 16px;
  border-radius: 999px;
  background: rgba(13, 13, 15, 0.7);
  border: 1px solid var(--linea);
  backdrop-filter: blur(8px);
  font-size: clamp(11px, 1.4vmin, 14px);
  letter-spacing: 0.04em;
  transition: background 0.25s ease;
}

.interna__volver:hover {
  background: rgba(13, 13, 15, 0.95);
}

.player {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 100%;
  padding: 0;
}

/* Video vertical: encaja en pantalla sin deformarse */
.player__video {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6);
  outline: none;
  background: #000;
}

.player__sinvideo {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  color: var(--tinta-suave);
}

.player__poster {
  max-width: min(56vmin, 420px);
  border-radius: 12px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6);
}

/* Aviso de audio (patrón tótem): solo aparece si el navegador bloqueó el
   sonido del autoplay; el primer toque en la pantalla lo activa y lo oculta.
   pointer-events: none → el toque atraviesa el aviso y llega al video. */
.player__audio-hint {
  position: fixed;
  left: 50%;
  bottom: max(12vh, 92px);
  transform: translateX(-50%);
  z-index: 50;
  background: rgba(13, 13, 15, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: var(--tinta);
  font-family: var(--fuente-texto);
  font-size: clamp(13px, 1.8vmin, 17px);
  letter-spacing: 0.04em;
  padding: 10px 20px;
  border-radius: 999px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
  animation: audio-hint-in 0.4s ease both;
  pointer-events: none;
}

@keyframes audio-hint-in {
  from {
    opacity: 0;
    transform: translate(-50%, 10px);
  }
  to {
    opacity: 1;
    transform: translate(-50%, 0);
  }
}

/* Hint de navegación swipe ← → (pantalla interna). Pill superior centrado,
   se desvanece solo tras 5s. pointer-events: none → no roba toques. */
.player__swipe-hint {
  position: fixed;
  left: 50%;
  top: max(10vh, 56px);
  transform: translateX(-50%);
  z-index: 50;
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(13, 13, 15, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.22);
  color: var(--tinta);
  font-family: var(--fuente-texto);
  font-size: clamp(13px, 1.8vmin, 17px);
  letter-spacing: 0.04em;
  padding: 10px 20px;
  border-radius: 999px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
  opacity: 1;
  transition: opacity 0.6s ease;
  pointer-events: none;
}

.player__swipe-hint span {
  font-weight: 700;
}

.player__swipe-hint.is-hidden {
  opacity: 0;
}

/* Transición de salida al navegar entre testimonios (fade 0.18s) */
.interna {
  transition: opacity 0.18s ease;
}

.interna--nav {
  opacity: 0;
}

.interna__info {
  text-align: center;
  padding: clamp(10px, 1.6vmin, 20px) 20px;
  flex-shrink: 0;
}

.interna__titulo {
  font-family: var(--fuente-titulo);
  font-size: clamp(24px, 3.8vmin, 42px);
  font-weight: 700;
}

.interna__subtitulo {
  font-size: clamp(13px, 1.8vmin, 19px);
  color: var(--tinta-suave);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-top: 4px;
}

.interna__footer {
  text-align: center;
  padding: clamp(8px, 1.2vmin, 14px);
  border-top: 1px solid var(--linea);
  flex-shrink: 0;
}

.interna__marca {
  font-size: clamp(10px, 1.3vmin, 13px);
  color: var(--tinta-suave);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* ═══════════════════════════ MOBILE (destino QR) ═══════════════════════════ */

@media (max-width: 768px), (orientation: portrait) and (max-height: 480px) {
  body.totem {
    padding: 0;
    gap: 0;
  }

  .totem-header {
    flex-wrap: wrap;
    justify-content: center;
    text-align: center;
  }
  .totem-header__hint {
    width: 100%;
    text-align: center;
    margin-left: 0;
  }

  .grid {
    gap: 0;
  }

  .tile__play {
    width: 44px;
    height: 44px;
    font-size: 15px;
  }

  .totem-footer {
    flex-wrap: wrap;
    text-align: center;
  }
  .totem-footer__texto {
    width: 100%;
  }

  .interna__volver {
    top: 10px;
    left: 10px;
    padding: 7px 13px;
    font-size: 11px;
  }
}

/* ═══════════════════════════ MODO TÓTEM FULLSCREEN (kiosk) ═══════════════════════════ */

@media (display-mode: fullscreen) {
  body.totem {
    border-radius: 0;
  }
}
