/* ============================================
   TOASTS - AEM77
   Système de notifications
   Convention: snake_case
   Version: 1.0
   ============================================ */

/* Conteneur fixe en haut à droite (sous le header de 100px) */
.toast_container {
    position: fixed;
    top: 120px;
    right: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 400px;
    pointer-events: none;
}

/* Toast individuel */
.toast {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    pointer-events: auto;
    animation: toast_slide_in 0.3s ease-out;
    min-width: 280px;
    max-width: 100%;
}

/* Animation d'entrée */
@keyframes toast_slide_in {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Animation de sortie */
.toast.toast_closing {
    animation: toast_slide_out 0.3s ease-in forwards;
}

@keyframes toast_slide_out {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* Message du toast */
.toast_message {
    flex: 1;
    font-size: 15px;
    line-height: 1.4;
    padding-right: 12px;
}

/* Bouton de fermeture */
.toast_close {
    background: none;
    border: none;
    font-size: 20px;
    font-weight: bold;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.2s ease;
    padding: 0;
    line-height: 1;
    color: inherit;
}

.toast_close:hover {
    opacity: 1;
}

/* === TYPES DE TOAST === */

/* Succès (vert) */
.toast_success {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

/* Avertissement (orange) */
.toast_warning {
    background-color: #fff3cd;
    border: 1px solid #ffc107;
    color: #856404;
}

/* Erreur (rouge) */
.toast_error {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

/* === RESPONSIVE === */
@media (max-width: 480px) {
    .toast_container {
        top: 90px;
        right: 10px;
        left: 10px;
        max-width: none;
    }

    .toast {
        min-width: auto;
    }
}
