/* Estilos generales del carrusel */
.swiper {
    width: 100%;
    /* Color theme for Swiper controls (pagination / navigation) */
    --swiper-theme-color: #6B5EA5;
  /* Mantener la altura del carrusel igual que el banner para evitar saltos
     y que el slide del banner ocupe todo el espacio esperado */
  height: 550px;
    margin: 0 auto;
}

.swiper-slide {
    display: flex;
    align-items: center;
    justify-content: center;
    background-size: cover;
    background-position: center;
}

/* Asegurar que las imágenes se centren dentro del slide */
.swiper-slide img {
  display: block;
  margin: 0 auto;
  max-width: 100%;
}

/* Banner (slide único) */
.swiper-slide.banner-full {
  /* background moved to .banner in main stylesheet to avoid duplication */
  min-height: 550px;
  display: flex;
  align-items: center;
  width: 100% !important;
  justify-content: flex-start; /* allow inner .banner to stretch full width */
}

.swiper-slide.banner-full .banner {
  width: 100%;
}

/* Imágenes verticales (852x1280) */
.swiper-slide.vertical-img img {
    height: 550px;
    width: auto;
    max-width: 100%;
    object-fit: cover;
    object-position: center;
}


/* Imágenes horizontales (1280x852) */
.swiper-slide.horizontal-img img {
    width: 100%;
    height: 550px;
    object-fit: cover;
    object-position: center;
}

/* Estilos para la paginación */
.swiper-pagination-bullet {
    background-color: #ccc;
    opacity: 1;
    width: 12px;
    height: 12px;
    margin: 0 6px;
}

.swiper-pagination-bullet-active {
    background-color: #6B5EA5;
}

/* Estilos para las flechas de navegación */
.swiper-button-next,
.swiper-button-prev {
    color: #6B5EA5;
}

/* Ajustes responsivos */
@media (max-width: 767px) {
    /* En móvil, todas las slides ocupan el 100% */
    .swiper-slide:not(.banner-full) {
        width: 100% !important;
    }
  /* En móvil dejamos que el carrusel se adapte al contenido */
  .swiper {
    height: auto;
  }
  .swiper-slide.vertical-img img,
  .swiper-slide.horizontal-img img {
    height: auto;
    width: 100%;
  }
}

@media (min-width: 768px) and (max-width: 1023px) {
    /* Tablet: 2 slides */
    .swiper-slide:not(.banner-full) {
        width: 50% !important;
    }
}

@media (min-width: 1024px) {
    /* Desktop: 3 verticales o 2 horizontales */
  .swiper-slide.vertical-img {
    width: calc(100% / 3) !important;
  }
    .swiper-slide.horizontal-img {
        width: 50% !important;
    }
}

/* Estilo del texto del banner en móvil */
@media (max-width: 768px) {
    .banner-full .block h1 {
        font-size: 28px;
        line-height: 40px;
    }
}

.terminos {
  padding: 10px 15px;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.terminos li {
  list-style: none; /* Quita el punto */
  margin: 0;
  padding: 0;
}

.terminos a {
  color: #6B5EA5;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.3s ease;
}

.terminos a:hover {
  color: #857ea3;
  cursor: pointer;
}

/* Estilo mejorado para el modal */
.modal {
  display: none;
  position: fixed;
  z-index: 1050; /* Mayor z-index para asegurar visibilidad */
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.75); /* Fondo más oscuro para mejor contraste */
  overflow: auto;
  opacity: 0;
  transition: opacity 0.3s ease; /* Transición suave */
}

.modal.show {
  opacity: 1;
}

/* Contenido del modal mejorado */
.modal-content {
  background-color: #fff;
  margin: 2% auto; /* Menor margen superior */
  padding: 25px;
  width: 90%;
  max-width: 900px; /* Ancho más adecuado para PDF */
  height: 85vh;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  transform: translateY(-20px);
  transition: transform 0.3s ease;
}

.modal.show .modal-content {
  transform: translateY(0);
}

/* Botón de cierre mejorado */
.close {
  color: #8d5fff;
  float: right;
  font-size: 28px;
  font-weight: bold;
  line-height: 1;
  padding: 0 8px;
  border-radius: 50%;
  transition: all 0.2s;
}

.close:hover,
.close:focus {
  color: #523796;
  background-color: #f0f0f0;
  text-decoration: none;
  cursor: pointer;
}

/* Mejora para la visualización del PDF */
.pdf-container {
  width: 100%;
  height: calc(100% - 40px); /* Ajuste para el título */
  border: 1px solid #eee;
  border-radius: 5px;
  overflow: hidden;
}

/* Estilos para el fallback */
.pdf-fallback {
  text-align: center;
  padding: 20px;
  background: #f9f9f9;
  border-radius: 5px;
  margin-top: 15px;
}

.pdf-fallback a {
  color: #0066cc;
  text-decoration: none;
  font-weight: bold;
  border-bottom: 1px solid;
}

.pdf-fallback a:hover {
  color: #004499;
}
