/* ===== Modal general ===== */
.modal {
  display: none; /* Oculto por defecto */
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.5);
  justify-content: center;
  align-items: center;
  backdrop-filter: blur(4px);
  transition: opacity 0.3s ease-in-out;
}

/* ===== Contenido del modal ===== */
.modal-content {
  background: #F2E8DE !important;
  border-radius: 20px;
  padding: 30px 40px;
  max-width: 400px;
  width: 90%;
  text-align: center;
  box-shadow: 0 8px 25px rgba(0,0,0,0.2);
  animation: popIn 0.4s ease;
  position: relative;
}

/* ===== Ícono ===== */
.modal-icon {
  font-size: 3rem;
  margin-bottom: 15px;
  animation: bounce 0.8s ease;
}

/* ===== Texto ===== */
.modal-content h2 {
  font-size: 1.6rem;
  margin-bottom: 10px;
  color: #333;
}

.modal-content p {
  color: #555;
  font-size: 1rem;
  margin-bottom: 20px;
}

/* ===== Botón de cierre ===== */
.close {
  position: absolute;
  top: 15px;
  right: 20px;
  font-size: 1.5rem;
  color: #aaa;
  cursor: pointer;
  transition: color 0.3s;
}

.close:hover {
  color: #333;
}


@keyframes popIn {
  0% { transform: scale(0.7); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

/* ===== Colores por tipo ===== */
.modal.success .modal-icon { color: #27ae60; } /* verde */
.modal.error .modal-icon { color: #e74c3c; }   /* rojo */
.modal.warning .modal-icon { color: #f39c12; } /* amarillo */
.modal.info .modal-icon { color: #3498db; }    /* azul */
