/* ==========================================================================
   Estilos Personalizados - Antonio Klett
   ========================================================================== */

/* Transiciones suaves para la página */
html {
  scroll-behavior: smooth;
}

/* Efectos para las imágenes de la galería */
.gallery-item {
  transition: transform 0.5s ease;
}

/* La escala ocurre en el contenedor al hacer hover */
.group:hover .gallery-item {
  transform: scale(1.05);
}

/* Animaciones de Marquee (Carrusel Infinito) */
.marquee-container {
  display: flex;
  width: 100%;
  overflow: hidden;
}

.marquee-content {
  display: flex;
  min-width: 200%;
  animation: scrollLeft 40s linear infinite;
}

.marquee-content.reverse {
  animation: scrollRight 45s linear infinite;
}

/* Pausar la animación al pasar el ratón */
.marquee-container:hover .marquee-content {
  animation-play-state: paused;
}

@keyframes scrollLeft {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

@keyframes scrollRight {
  0% { transform: translateX(-50%); }
  100% { transform: translateX(0); }
}

/* ==========================================================================
   LightBox Modal para la Galería
   ========================================================================== */
.modal {
  display: none; 
  position: fixed; 
  z-index: 1000; 
  left: 0;
  top: 0;
  width: 100%; 
  height: 100%; 
  overflow: auto; 
  background-color: rgba(0,0,0,0.9);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.modal.show {
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 1;
}

.modal-content {
  margin: auto;
  display: block;
  max-width: 90%;
  max-height: 90vh;
  box-shadow: 0 0 20px rgba(0,0,0,0.5);
}

/* Botón de cerrar modal */
.close-modal {
  position: absolute;
  top: 20px;
  right: 35px;
  color: #f1f1f1;
  font-size: 40px;
  font-weight: bold;
  transition: 0.3s;
  cursor: pointer;
  z-index: 1010;
}

.close-modal:hover,
.close-modal:focus {
  color: #135bec;
  text-decoration: none;
  cursor: pointer;
}

/* ==========================================================================
   Hero Slideshow Animations
   ========================================================================== */
.hero-slideshow {
  width: 100%;
  height: 100%;
  position: relative;
}

.slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  opacity: 0;
  animation-duration: 24s; /* 4 images * 6s */
  animation-iteration-count: infinite;
  animation-timing-function: linear;
}

/* Sequential timing */
.slide:nth-child(1) { animation-delay: 0s; }
.slide:nth-child(2) { animation-delay: 6s; }
.slide:nth-child(3) { animation-delay: 12s; }
.slide:nth-child(4) { animation-delay: 18s; }

/* The fading animation combined with zoom */
.slide.zoom-in {
  animation-name: fadeZoomIn;
}

.slide.zoom-out {
  animation-name: fadeZoomOut;
}

@keyframes fadeZoomIn {
  0% { opacity: 0; transform: scale(1); }
  5% { opacity: 1; }
  25% { opacity: 1; }
  30% { opacity: 0; transform: scale(1.15); }
  100% { opacity: 0; transform: scale(1.15); }
}

@keyframes fadeZoomOut {
  0% { opacity: 0; transform: scale(1.15); }
  5% { opacity: 1; }
  25% { opacity: 1; }
  30% { opacity: 0; transform: scale(1); }
  100% { opacity: 0; transform: scale(1); }
}

/* ==========================================================================
   Scroll Reveal Animations
   ========================================================================== */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s ease-out;
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* ==========================================================================
   Prevención de Copia de Imágenes
   ========================================================================== */
img {
  -webkit-user-drag: none;
  -khtml-user-drag: none;
  -moz-user-drag: none;
  -o-user-drag: none;
  user-drag: none;
  -webkit-touch-callout: none;
  user-select: none;
  -moz-user-select: none;
  -webkit-user-select: none;
  -ms-user-select: none;
}
