/* ======================================================= */
/* 1. Estilos BASE e Modernização (Comum a Todos) */
/* ======================================================= */
.toast {
    background-color: #333;
    color: white;
    border-radius: 0.75rem;
    border: none;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
    padding: 0;
    overflow: hidden;
    width: fit-content;
    max-width: 350px;
    position: relative;
}

.toast-body {
    background-color: transparent !important;
    border: none !important;
    padding: 1rem 1.5rem !important;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    z-index: 1;
}

.toast-icon {
    font-size: 1.5rem;
    line-height: 1;
    /* CRUCIAL PARA OS BOOTSTRAP ICONS */
    font-family: "bootstrap-icons" !important;
    font-weight: normal !important;
}

.toast-message {
    font-size: 1rem;
    font-weight: 400;
}

/* ======================================================= */
/* 2. Barra de Progresso Animada */
/* ======================================================= */
.toast-progress-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    width: 100%;
    z-index: 2;
    opacity: 0;
    transform-origin: left;
    border-top-left-radius: 0;
    border-top-right-radius: 0;
    border-bottom-left-radius: 0.75rem;
    border-bottom-right-radius: 0.75rem;
}

.toast.showing .toast-progress-bar,
.toast.show .toast-progress-bar {
    opacity: 1;
    animation-name: progress-animation;
    animation-timing-function: linear;
    animation-fill-mode: forwards;
}

/* Definição da animação: Reduz a largura de 100% para 0% */
@keyframes progress-animation {
    from {
        width: 100%;
    }

    to {
        width: 0%;
    }
}

/* ======================================================= */
.toast-success {
    background-color: #2eb82e !important;
    color: var(--bs-white) !important;
}
    .toast-success .toast-progress-bar {
        background-color: #1f7a1f;
    }
    .toast-success .toast-icon::before {
        content: "\F270"; /* bi-check-lg */
    }

.toast-danger {
    background-color: var(--bs-danger) !important;
    color: var(--bs-white) !important;
}
    .toast-danger .toast-progress-bar {
        background-color: #b02a37;
    }
    .toast-danger .toast-icon::before {
        content: "\F532"; /* bi-shield-fill-exclamation */
    }

.toast-warning {
    background-color: #ff9933 !important;
    color: var(--bs-dark) !important;
}
    .toast-warning .toast-progress-bar {
        background-color: #cc6600;
    }
    .toast-warning .toast-icon::before {
        content: "\F33B"; /* bi-exclamation-triangle */
    }

.toast-info {
    background-color: var(--bs-info) !important;
    color: var(--bs-white) !important;
}
    .toast-info .toast-progress-bar {
        background-color: #0aa5c2;
    }
    .toast-info .toast-icon::before {
        content: "\F332"; /* bi-exclamation-circle-fill */
    }
