/* Sustituye a los plugins del CMS (camera.js, fancybox, highslide) en la réplica estática. */

/* ---- slider de cabecera ---- */
.slider { overflow: hidden; }
.diy-slideshow {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.diy-slideshow figure {
  position: absolute;
  inset: 0;
  margin: 0;
  opacity: 0;
  transition: opacity 1s ease-in-out;
  pointer-events: none;
}
.diy-slideshow figure.show { opacity: 1; }
.diy-slideshow figure img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.diy-slideshow .overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, .25);
  z-index: 1;
}
.diy-slideshow figure figcaption { z-index: 2; transform: translate(-50%, -50%); }

/* ---- galería ---- */
/* la maquetación a tres columnas la pone gallery.css; aquí sólo se
   uniforman los recortes y se apila en móvil */
.highslide-gallery .highslideContainer a.highslide img {
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

@media (max-width: 767px) {
  .highslide-gallery .highslideContainer { width: 50% !important; }
}

/* ---- lightbox ---- */
.lb-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .9);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}
.lb-overlay.open { display: flex; }
.lb-overlay img {
  max-width: 92vw;
  max-height: 88vh;
  object-fit: contain;
}
.lb-overlay button {
  position: absolute;
  background: none;
  border: 0;
  color: #fff;
  font-size: 3rem;
  cursor: pointer;
  padding: 1rem 1.5rem;
  line-height: 1;
}
.lb-close { top: 1rem; right: 1rem; }
.lb-prev { left: .5rem; top: 50%; transform: translateY(-50%); }
.lb-next { right: .5rem; top: 50%; transform: translateY(-50%); }

/* bg-banner-cta.png no venía en el backup; sin él la regla sólo pedía un 404 */
.cta-banner span::before { background-image: none !important; }

/* ---- formulario ---- */
form.contactForm .form-msg {
  margin-top: 1rem;
  padding: 1rem;
  background: #eef4fb;
  color: #04559b;
  border-radius: 4px;
  font-size: 1.5rem;
}
form.contactForm .text-input.invalid { border-color: #c0392b !important; }
form.contactForm .form-msg.error { background: #fbeceb; color: #c0392b; }

/* trampa para bots: fuera de la vista pero sin display:none, que algunos omiten */
.hp-field {
  position: absolute !important;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
