/* Contenedor de las cartas */
.card-container {
  display: flex;
  flex-wrap: wrap; /* Para que se ajusten en pantallas pequeñas */
  gap: 20px;       /* Espacio entre cartas */
  padding: 10px;
  justify-content: center;
}

/* Estilo de cada carta */
.card {
  width: 300px;
  border-radius: 10px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  overflow: hidden; /* Para que la imagen no se salga */
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 15px rgba(0, 0, 0, 0.15);
}

.card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
}

.card-content {
  padding: 15px;
}

.card-content h3 {
  margin-top: 0;
}

/* Estilos del Modal */
.modal-overlay {
  display: none; /* Oculto por defecto */
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.6);
  z-index: 1000;
  
  /* Usamos flex para centrar el contenido */
  justify-content: center;
  align-items: center;
}

.modal-content {

  border-top: 6px solid #400312;
  border-radius: 12px;
  background-color: #fff;
  padding: 40px;
  box-shadow: 0 8px 20px rgba(64, 3, 18, 0.25);

  border-radius: 12px;
  max-width: 700px; /* antes 500px */
  width: 95%; /* un poco más ancho */
  position: relative;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.close-btn {

  color: #400312;
  font-size: 28px;
  cursor: pointer;
  transition: color 0.2s ease;

  position: absolute;
  top: 10px;
  right: 15px;
  font-weight: bold;
}

.close-btn:hover {
  color: #70041c;
}

#dcard-modal-image {
  width: 100%;
  height: auto;
  max-height: 500px; /* 🔼 Aumenta la altura visible */
  object-fit: cover;
  border-radius: 10px;
  margin-bottom: 20px;
  transition: max-height 0.3s ease;
}


.modal-overlay.show {
  display: flex;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modal-content h5,
.modal-content strong {
  color: #400312;
}

/*-Title cards-*/

section {
    padding: 60px 0;
    overflow: hidden;
  }
  
  .section-bg {
    background-color: #f0f4f8;
  }
  
  .section-title-cards {
    padding-bottom: 40px;
  }
  
  .section-title-cards h2 {
    font-size: 14px;
    font-weight: 500;
    padding: 0;
    line-height: 1px;
    margin: 0 0 5px 0;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: rgba(95, 19, 19, 0.979);
    font-family: "Poppins", sans-serif;
  }
  
  .section-title-cards h2::after {
    content: "";
    width: 120px;
    height: 1px;
    display: inline-block;
    background: rgba(95, 19, 19, 0.979);
    margin: 4px 10px;
  }
  
  .section-title-cards p {
    margin: 0;
    margin: 0;
    font-size: 36px;
    font-weight: 700;
    text-transform: uppercase;
    font-family: "Poppins", sans-serif;
    color: #263d4d;
  }
