
/* Base styling for all alerts */
.alert {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  min-width: 300px;
  max-width: 500px;
  padding: 15px 20px;
  border: none;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  z-index: 9999;
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: space-between;
  animation: slide-up 0.3s ease-out;
}

/* Success alert styling */
.alert-success {
  background-color: #e7f7ed;
  color: #2d6a4f;
  border-left: 4px solid #2d6a4f;
}

/* Info alert styling */
.alert-info {
  background-color: #e3f2fd;
  color: #0d47a1;
  border-left: 4px solid #0d47a1;
}

/* Warning alert styling */
.alert-warning {
  background-color: #fff8e1;
  color: #bf6900;
  border-left: 4px solid #bf6900;
}

/* Danger alert styling */
.alert-danger {
  background-color: #fee2e2;
  color: #b91c1c;
  border-left: 4px solid #b91c1c;
}

/* Custom close button */
.alert .btn-close {
  background: none;
  border: none;
  font-size: 20px;
  font-weight: bold;
  cursor: pointer;
  padding: 0 5px;
  opacity: 0.7;
  transition: opacity 0.2s;
}

.alert .btn-close:hover {
  opacity: 1;
}

/* Custom close button icons instead of bootstrap's default */
.alert .btn-close::before {
  content: "×";
}

/* Animation for the alerts */
@keyframes slide-up {
  0% {
    opacity: 0;
    transform: translate(-50%, 20px);
  }
  100% {
    opacity: 1;
    transform: translate(-50%, 0);
  }
}

/* Optional: Auto-hide animation */
.alert.fade-out {
  animation: fade-out 0.5s forwards;
}

@keyframes fade-out {
  0% {
    opacity: 1;
    transform: translate(-50%, 0);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, 20px);
  }
}

/* Make sure the alerts stack nicely if there are multiple */
.alert + .alert {
  margin-bottom: 10px;
}
