/* ============================
   🏅 Toast Succès (GLOBAL)
=============================== */

.success-toast {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  backdrop-filter: blur(1px);
  opacity: 0;
  pointer-events: none;
  transform: scale(0.98);
  transition: opacity 0.25s ease-out, transform 0.25s ease-out;
  z-index: 999999;
  padding: 20px;
  box-sizing: border-box;
}

.success-toast.visible {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
}

.success-toast.hidden {
  opacity: 0;
  transform: scale(0.98);
}

.success-card-popup {
  background: rgba(23, 55, 83, 0.4); /* #173753 à 40% */
  color: #ffffff;
  padding: 18px 24px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 1.1rem;
  font-weight: 600;
  border: 2px solid #2DB53D; /* contour vert vif */
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.25);
  min-width: min(360px, 90vw);
  justify-content: center;
}

.toast-content {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.toast-label {
  font-size: 0.72em;
  font-weight: 500;
  opacity: 0.7;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.toast-title {
  font-size: 1em;
  font-weight: 700;
}


/* ============================
   🎉 Confettis (GLOBAL)
=============================== */

.confetti-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  overflow: hidden;
  z-index: 999998;
}

/* --- Flou derrière les confettis + toast --- */
.confetti-container.active::before {
  content: "";
  position: fixed;
  inset: 0;
  backdrop-filter: blur(1px);
  background: rgba(0, 0, 0, 0.20); /* léger fondu pour renforcer l'effet */
  z-index: -1; /* reste derrière les confettis */
}

.confetti-piece {
  width: 10px;
  height: 14px;
  position: absolute;
  top: -10px;
  animation: confettiFall 3s linear forwards;
  opacity: 0.9;
  border-radius: 2px;
}

@keyframes confettiFall {
  0% {
    transform: translateY(0) rotate(0deg);
  }
  100% {
    transform: translateY(120vh) rotate(720deg);
  }
}
