.section-title {
  color: #000;
  padding: 0.79%;
  font-size: 2rem;
}

/* ===== TIPOGRAFÍA UNIFICADA ===== */
.resolution-details-ces dt,

.resolution-ces-card .card-header,
.resolution-ces-card,
.resolution-ces-card *,
.accordion,
.accordion * {
  font-family: "Montserrat", sans-serif;
  font-size: 1rem;     
  line-height: 1.5;
}

.row {
  align-items: stretch;
}

.titulo-azul {
  color: #1e3a8a !important;
}

/* ===== TEXTO HISTORIA ===== */
.history-text {
  color: #333;
  margin: 0.50%;
  padding: 1px;
  text-align: justify;
  line-height: 1.5; 
   font-size: 1.2rem;   
}



/* ===== CARD ===== */
.card {
  border-radius: 15px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
  width: 400px;
   margin: 0 auto;
}

.card-title {
  font-weight: bold;
}

/* ===== ACORDEÓN ===== */
.accordion-item {
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.accordion-button {
  font-weight: normal;
  background-color: #1e3a8a;
  color: white;
}

.accordion-button:not(.collapsed) {
  background-color: #1e3a8a;
  color: white;
}

.accordion-button::after {
  filter: invert(1);
}

.accordion-body {
  padding: 0;
}

/* ===== PDF ===== */
.accordion-body iframe {
  width: 100%;
  height: 500px;
  border-radius: 0 0 15px 15px;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .accordion-body iframe {
    height: 350px;
  }
}

@media (min-width: 1400px) {
  .container {
    max-width: 1400px;
  }

  .accordion-body iframe {
    height: 70vh;
  }
}

@media (max-width: 1399px) {
  .accordion-body iframe {
    height: 60vh;
  }
}

@media (max-width: 992px) {
  .accordion-body iframe {
    height: 55vh;
  }
}

@media (max-width: 768px) {
  .card {
    width: 100%;
  }

  .accordion-body iframe {
    height: 50vh;
  }
}

@media (max-width: 576px) {
  .section-title {
    font-size: 1.4rem;
    text-align: center;
  }

  .accordion-body iframe {
    height: 45vh;
  }
}

/* ===== TARJETA CES ===== */
.resolution-ces-card {
  height: 250px;
  overflow: hidden;
}

.bg-ces-blue {
  background-color: #1e3a8a !important;
}

.resolution-ces-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 25px rgba(23, 75, 123, 0.2);
}

.resolution-ces-card .card-header {
  border-bottom: 4px solid #1e3a8a;
  letter-spacing: 0.8px;
}

/* ===== DETALLES ===== */
.resolution-details-ces dt {
  font-weight: 700;
  margin-bottom: 0.6rem;
  color: #333;
}

.resolution-details-ces dd {
  margin-bottom: 0.6rem;
  word-break: break-word;
  font-size: 0.95rem;
}

.resolution-details-ces .text-primary {
  color: #1e3a8a !important;
  font-weight: 600;
}

/* ===== FOOTER ===== */
.resolution-ces-card .card-footer {
  background-color: #f0f2f5 !important;
  border-top: 1px solid #e9ecef;
  font-size: 0.95rem;
}

/* ===== BOTÓN ===== */
.boton {
  background-color: #1e3a8a;
  color: white;
  padding: 10px 20px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 1rem;
  transition: background-color 0.3s ease;
  margin-top: 15px;
  justify-content: center;
    display: inline-block;
      text-decoration: none;
}
.botones {
  display: flex;
  justify-content: center; /* centra horizontalmente */
  gap: 12px;               /* espacio entre botones */
  margin-top: 15px;
}



#carouselCodigoEtica {
  position: relative;
  width: 100%;
  max-height: 350px;
  overflow: hidden;
  background-color: rgba(255, 255, 255, 0.05); /* Muy transparente */
  backdrop-filter: blur(5px); /* Difumina el fondo para mejorar legibilidad */
  border-radius: 15px;
  margin-bottom: 30px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}


.carousel-item .card {
  height: 100%;            /* hace que la card llene la altura del item */
  overflow: hidden;        /* corta lo que sobre */
}

/* Contenido centrado */
.carousel-content {
  text-align: center;
  padding: 40px 20px;
}

.carousel-content h2 {
  font-family: "Montserrat", sans-serif;
  font-size: 1.8rem;
  font-weight: bold;
  color: #f0f2f5;
  margin-bottom: 15px;
}

.carousel-content p {
  font-family: "Montserrat", sans-serif;
  font-size: 1.1rem;
  color: #f0f2f5;
  line-height: 1.5;
  margin-bottom: 20px;
}

.boton-carousel {
  background-color: #1e3a8a;
  color: white;
  padding: 10px 25px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: 500;
  transition: background-color 0.2s ease;
}

.boton-carousel:hover {
  background-color: #16306b;
}

/* Ajuste responsive */
@media (max-width: 768px) {
  .carousel-content h2 {
    font-size: 1.4rem;
  }
  .carousel-content p {
    font-size: 1rem;
  }
}

.carousel-content {
  position: relative;
  height: 250px; /* altura de tu slide */
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  overflow: hidden;
}

.carousel-content h2,
.carousel-content p {
  opacity: 0;  /* inicia invisible */
  position: relative;
  transition: all 1s ease; /* transición suave */
}

.carousel-item.active .carousel-content h2 {
  transform: translateX(0);  /* posición final centrada */
  opacity: 1;
}

.carousel-item.active .carousel-content p {
  transform: translateX(0);  /* posición final centrada */
  opacity: 1;
}

/* posiciones iniciales fuera de pantalla */
.carousel-content h2 {
  transform: translateX(-100%); /* desde la izquierda */
}

.carousel-content p {
  transform: translateX(100%);  /* desde la derecha */
}

/* Botón centrado con fade-in */
.carousel-content .boton-carousel {
  margin-top: 20px;
  opacity: 0;
  transition: all 1s ease;
}

.carousel-item.active .carousel-content .boton-carousel {
  opacity: 1;
  transform: translateY(0);
}
.carousel-content h2 {
  opacity: 0;
  transform: translateX(-100%);
  animation: slideInLeft 1s forwards;
}

.carousel-content p {
  opacity: 0;
  transform: translateX(100%);
  animation: slideInRight 1s forwards;
  animation-delay: 0.3s; /* se retrasa un poco */
}

@keyframes slideInLeft {
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes slideInRight {
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

/* botón con fade-in */
.carousel-content .boton-carousel {
  opacity: 0;
  animation: fadeIn 1s forwards;
  animation-delay: 0.6s;
}

@keyframes fadeIn {
  to {
    opacity: 1;
  }
}

/* ==========================================
   AGREGADO DE RESPONSIVIDAD ADICIONAL
   ========================================== */

@media (max-width: 576px) {
  .history-text {
    font-size: 1.1rem; /* Fuente más legible en celulares */
    text-align: left; /* El justificado a veces crea huecos feos en pantallas muy angostas */
  }

  .resolution-ces-card {
    height: auto; /* Permite que la tarjeta crezca si el texto es largo */
    min-height: 250px;
  }

  .botones {
    flex-direction: column; /* Apila los botones verticalmente en móviles */
    align-items: center;
    gap: 10px;
  }

  .boton {
    width: 90%; /* Botones más anchos para fácil clic táctil */
    text-align: center;
  }

  #carouselCodigoEtica {
    max-height: none; /* Permite que el carrusel se adapte al contenido en móviles */
  }

  .carousel-content {
    height: auto;
    padding: 30px 15px;
  }
}

@media (max-width: 400px) {
  .resolution-details-ces dd {
    font-size: 0.85rem; /* Ajuste fino para pantallas muy pequeñas */
  }
}