/* ============================================================
   TOASTS, MODAIS E NOTIFICAÇÕES (COMPONENTS/MODALS.CSS)
============================================================ */

/* Notificações Flutuantes (Toast) */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toast-alert {
    color: #FFFFFF;
    padding: 0.9rem 1.4rem;
    border-radius: var(--radius-sm, 10px);
    box-shadow: var(--shadow-lg);
    font-weight: 600;
    font-size: 0.88rem;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    animation: slideIn 0.3s ease-out;
    max-width: 350px;
}

.toast-alert.success { background-color: #047857; }
.toast-alert.error   { background-color: #D92D20; }
.toast-alert.warning { background-color: #DC6803; }
.toast-alert.info    { background-color: var(--azul-vibrante); }

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

/* Fundo Escuro para Janelas Modais */
.modal-backdrop {
    position: fixed;
    inset: 0;
    background-color: rgba(12, 15, 26, 0.55);
    backdrop-filter: blur(3px);
    z-index: 2147483646;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-backdrop.active {
    opacity: 1;
    visibility: visible;
}

.modal-backdrop-notificacoes {
    z-index: 1040;
    display: none;
}

/* Mensagens de Alerta Globais */
.message-alert {
    max-width: 600px;
    margin: 0 auto 1.25rem auto;
}

/* Diálogo de Confirmação */
.dialog-confirm-modal {
    top: 50%;
    left: 50%;
    right: auto;
    transform: translate(-50%, -50%);
    width: 90%;
    max-width: 420px;
    position: fixed;
    max-height: none;
}

.dialog-confirm-message {
    font-size: 0.94rem;
    color: var(--texto-escuro, #1e293b);
    margin: 0.75rem 0 1.25rem 0;
}

.dialog-confirm-actions {
    margin: 0;
    justify-content: flex-end;
    gap: 0.75rem;
}

/* Modal de IA */
#ai-response-content {
    font-size: 0.92rem;
    line-height: 1.6;
    color: var(--texto-escuro);
    max-height: 320px;
    overflow-y: auto;
}

/* Gaveta Lateral de Notificações */
.offcanvas-notificacoes {
    position: fixed;
    top: 0;
    right: 0;
    width: min(380px, 92vw);
    height: 100vh;
    background: #FFFFFF;
    box-shadow: -6px 0 25px rgba(0, 0, 0, 0.15);
    z-index: 2000;
    display: flex;
    flex-direction: column;
}

.offcanvas-header {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--borda-cinza);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.offcanvas-body {
    flex: 1;
    overflow-y: auto;
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.notificacao-card {
    background: var(--fundo-cinza);
    border-radius: 12px;
    padding: 1rem;
    border-left: 4px solid var(--azul-vibrante);
    display: flex;
    gap: 0.85rem;
}

.notificacao-card.card-sucesso { border-left-color: var(--sucesso); }
.notificacao-card.card-alerta  { border-left-color: var(--aviso); }

.notificacao-icon .lucide {
    width: 22px;
    height: 22px;
    color: var(--azul-vibrante);
}

.card-sucesso .notificacao-icon .lucide { color: var(--sucesso); }
.card-alerta .notificacao-icon .lucide  { color: var(--aviso); }

.notificacao-content h4 {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--texto-escuro);
    margin-bottom: 0.35rem;
}

.notificacao-content p {
    font-size: 0.84rem;
    color: var(--texto-cinza);
    line-height: 1.5;
    margin-bottom: 0.5rem;
}

.notificacao-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
}

.btn-link-guia {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--azul-vibrante);
    text-decoration: underline;
}

.btn-voice {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--texto-cinza-suave);
    padding: 4px;
}