﻿/* =============================================================
   TMIS TOASTS — FINAL NORMALIZATION
   Responsibility:
   - Global notifications
   - Success / Error / Info / Warning
   - Dark-mode safe
   - No layout responsibility
   ============================================================= */

/* =============================================================
   TOAST CONTAINER
   ============================================================= */

#toast-container {
    position: fixed;
    top: 80px;
    right: 24px;
    z-index: 5000;
    display: flex;
    flex-direction: column;
    gap: 12px;
    pointer-events: none;
}

/* =============================================================
   BASE TOAST
   ============================================================= */

.tmis-toast {
    min-width: 280px;
    max-width: 360px;
    padding: 0.75rem 1rem;
    background: var(--tmis-surface);
    color: var(--tmis-text);
    border: 1px solid var(--tmis-border);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.18);
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    pointer-events: auto;
}

/* =============================================================
   ICON
   ============================================================= */

.tmis-toast-icon {
    font-size: 1.1rem;
    line-height: 1;
}

/* =============================================================
   MESSAGE
   ============================================================= */

.tmis-toast-message {
    flex: 1;
    line-height: 1.35;
}

/* =============================================================
   CLOSE BUTTON
   ============================================================= */

.tmis-toast-close {
    background: transparent;
    border: none;
    color: var(--tmis-text-muted);
    cursor: pointer;
    font-size: 1.1rem;
    line-height: 1;
    padding: 0;
}

    .tmis-toast-close:hover {
        color: var(--tmis-text-strong);
    }

/* =============================================================
   VARIANTS
   ============================================================= */

.tmis-toast-success {
    border-left: 4px solid #2e7d32;
}

    .tmis-toast-success .tmis-toast-icon {
        color: #2e7d32;
    }

.tmis-toast-error {
    border-left: 4px solid #c62828;
}

    .tmis-toast-error .tmis-toast-icon {
        color: #c62828;
    }

.tmis-toast-warning {
    border-left: 4px solid #ed6c02;
}

    .tmis-toast-warning .tmis-toast-icon {
        color: #ed6c02;
    }

.tmis-toast-info {
    border-left: 4px solid var(--tmis-primary);
}

    .tmis-toast-info .tmis-toast-icon {
        color: var(--tmis-primary);
    }

/* =============================================================
   DARK MODE SAFETY
   ============================================================= */

html.dark-mode .tmis-toast {
    background: var(--tmis-surface);
    color: var(--tmis-text);
    border-color: rgba(255, 255, 255, 0.08);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.65);
}

html.dark-mode .tmis-toast-close {
    color: rgba(255, 255, 255, 0.6);
}

    html.dark-mode .tmis-toast-close:hover {
        color: #ffffff;
    }
