.index {
  width: 100%;
  /* min-height (no height fija): si el contenido pasa de 100dvh, el .index CRECE
     con él y el fondo (background-size 100% 100%) lo cubre entero. Con height
     fija, el contenido desbordaba y asomaba el blanco del html debajo (gap del
     fondo en el index, Manu jul 2026). */
  min-height: 100dvh;
  padding: 0 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  /* Fondo negro de base para evitar destellos mientras carga la imagen */
  background-color: var(--fondo-negro);
  /* Fondo del index POR-CLIENTE (token): cada app pone su imagen/gradiente en
     styles.css (--fondo-index-img). Fallback = fondo.webp (apps oscuras de la
     flota). Evita hardcodear una imagen por-cliente en este CSS compartido. */
  background-image: var(--fondo-index-img, url(/images/fondo.webp));
  background-repeat: no-repeat;
  /* 100% 100% ESTIRA para llenar SIEMPRE ancho y alto del index (100dvh), igual
     que el fondo de las páginas interiores (.logo__fondo). `cover` recortaba el
     fondo en el index (Manu, jul 2026). */
  background-size: 100% 100%;
  background-position: center;
}

/* HEADER */
.index__header {
  width: 100%;
  max-width: 50rem;
  padding: 0.5rem;
  gap: 0.5rem;
  z-index: 3;
  display: flex;
  justify-content: space-between;
  align-items: center;
  /* Animaciones */
  animation: rotation 2s;
}

/* Botón RESERVAR del header — color/background/animación en styles1.css */
.index__boton-reservar {
  padding: 0.3em 0.5rem;
  text-align: center;
  font-size: 1.3rem;
  font-weight: 800;
  border-radius: var(--border-radius);
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
}

.index__header-banderas {
  width: 100%;
  display: flex;
  justify-content: end;
  align-items: center;
  gap: 0.7rem;
}
.index_header-banderas-flag {
  width: 2.2rem;
  border-radius: 50%;
  box-shadow: var(--sombra);
  cursor: pointer;
}
/* HERO */
/* La imagen de cabecera (.hero-img) es un componente COMPARTIDO: su aspecto vive
   en estructura-base.css y su comportamiento logo/foto en app.js (pintarHero),
   para que se vea IGUAL en todas las páginas. Aquí solo su posición en el index. */
/* Posición del hero: la pone estructura-base (hero único de flota) */

/* BOTONES */
.index__buttons {
  width: 100%;
  max-width: 50rem;
  padding-left: 1rem; /* aire a la izquierda (convención de flota) */
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  z-index: 1;
}
.index__buttons > :nth-child(1) {
  width: 95%;
  /* Animaciones */
  animation: rotation 2s;
}
.index__buttons > :nth-child(2) {
  width: 85%;
  animation: rotation 2s;
}
.index__buttons > :nth-child(3) {
  width: 75%;
  animation: rotation 2s;
}
.index__buttons > :nth-child(4) {
  width: 65%;
  animation: rotation 2s;
}
.index__buttons > :nth-child(5) {
  width: 55%;
  animation: rotation 2s;
}
.index__buttons > :nth-child(6) {
  width: 45%;
  animation: rotation 2s;
}
.index__buttons-btn {
  width: 100%;
  padding: 0.6rem 0.4rem;
  border-radius: var(--border-radius);
  box-shadow: var(--sombra);
  cursor: pointer;
  /* Icono + texto alineados a la IZQUIERDA en una fila: gap controla la distancia
     entre ambos, align-items la altura (misma línea). */
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.75rem;
  padding-left: 1.2rem;
  /* El cristal (Liquid Glass) lo aporta liquid-glass.css */
  /* Degradado de marca por token (convención): en apps CLARAS pinta el
     gradiente bajo el cristal; en OSCURAS el token es 'none' → cristal puro. */
  background-image: var(--color-degradado2);
}
/* Mismos estilos que los nombres de familia (.platos__familia-h2):
   texto blanco, peso 600 y halo oscuro sobre el cristal. */
.index__buttons-texto {
  font-size: 1.5rem;
  /* El texto de los botones del index va DEL MISMO color que sus iconos
     (--color-icono-nav): texto e icono alineados (convención de consistencia,
     Manu jul 2026). Antes iba con el color de texto del tema y no casaba. */
  color: var(--color-icono-nav);
}
/* Botón @easybooking flotante del index: oculto (en el index la reserva se hace
   desde el botón RESERVAR del header). Los iconos del index heredan su color de
   --color-icono-nav (.icono base), igual que el resto de páginas. */
.easy-index {
  display: none;
}

/* ************************************************** */
/* MODAL GOOGLE MAPS */
/* ************************************************** */

/* Bloquear scroll cuando el modal está abierto */
body.menu-open {
  overflow: hidden;
}

/* Overlay del modal */
.maps-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  backdrop-filter: blur(0.3125rem);
  z-index: 15;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 2rem;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition:
    opacity 0.3s ease-out,
    visibility 0.3s ease-out;
}

.maps-modal.active {
  opacity: 1;
  visibility: visible;
  pointer-events: all;
}

/* Contenido del modal */
.maps-modal-content {
  position: relative;
  width: 100%;
  max-width: 56.25rem;
  height: 80vh;
  max-height: 37.5rem;
  background: #fff;
  border-radius: 0.9375rem;
  overflow: hidden;
  box-shadow: 0 0.625rem 2.5rem rgba(0, 0, 0, 0.5);
  transform: scale(0.9);
  opacity: 0;
  transition:
    transform 0.3s ease-out,
    opacity 0.3s ease-out;
}

.maps-modal.active .maps-modal-content {
  transform: scale(1);
  opacity: 1;
}

/* Botón cerrar (X) */
.maps-modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 2.5rem;
  height: 2.5rem;
  background: linear-gradient(-55deg, #333 0%, #000 55%);
  border: none;
  border-radius: 50%;
  color: #fff;
  font-size: 1.5rem;
  cursor: pointer;
  z-index: 16;
  display: flex;
  justify-content: center;
  align-items: center;
  box-shadow: 0 0.125rem 0.625rem rgba(0, 0, 0, 0.3);
  transition:
    transform 0.3s ease,
    background 0.3s ease;
}

.maps-modal-close:hover {
  transform: rotate(90deg) scale(1.1);
}

/* Iframe del mapa */
.maps-container {
  width: 100%;
  height: 100%;
}

.maps-container iframe {
  width: 100%;
  height: 100%;
  border: none;
}

/* Botón "Cómo llegar" */
.maps-directions-btn {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.8rem 1.5rem;
  background: linear-gradient(-55deg, #333 0%, #000 55%);
  color: #fff;
  text-decoration: none;
  border-radius: 3.125rem;
  font-weight: 400;
  font-size: 1rem;
  box-shadow: 0 0.25rem 0.9375rem rgba(0, 0, 0, 0.3);
  transition:
    transform 0.3s ease,
    background 0.3s ease;
  z-index: 16;
}

.maps-directions-btn:hover {
  transform: translateX(-50%) scale(1.05);
  color: #fff;
}

/* ----------------------------------------
   Animación rotate-scale-up-diag-2
   Aplicada al logo ".movimiento" en el index.
   ---------------------------------------- */
@-webkit-keyframes rotate-scale-up-diag-2 {
  0% {
    -webkit-transform: scale(1) rotate3d(-1, 1, 0, 0deg);
    transform: scale(1) rotate3d(-1, 1, 0, 0deg);
  }
  50% {
    -webkit-transform: scale(2) rotate3d(-1, 1, 0, 180deg);
    transform: scale(2) rotate3d(-1, 1, 0, 180deg);
  }
  100% {
    -webkit-transform: scale(1) rotate3d(-1, 1, 0, 360deg);
    transform: scale(1) rotate3d(-1, 1, 0, 360deg);
  }
}
@keyframes rotate-scale-up-diag-2 {
  0% {
    -webkit-transform: scale(1) rotate3d(-1, 1, 0, 0deg);
    transform: scale(1) rotate3d(-1, 1, 0, 0deg);
  }
  50% {
    -webkit-transform: scale(2) rotate3d(-1, 1, 0, 180deg);
    transform: scale(2) rotate3d(-1, 1, 0, 180deg);
  }
  100% {
    -webkit-transform: scale(1) rotate3d(-1, 1, 0, 360deg);
    transform: scale(1) rotate3d(-1, 1, 0, 360deg);
  }
}

/* ********************************************** */
/* MOVIMIENTO — animación del logo del index */
.movimiento {
  animation: rotate-scale-up-diag-2 2s linear both;
  width: 70dvw;
  max-width: 30rem;
  position: fixed;
  bottom: 8dvh;
  left: 30%;
  margin: auto;
  /* Decorativo: por detrás del contenido (-2, nunca -1 = nivel de .wrapper) y
     sin interceptar clics. Escala de capas de la flota (regla 25 jul). */
  z-index: -2;
  pointer-events: none;
  @media (width > 60rem) {
    right: 0;
  }
}
