.nexa-admin-toast-stack {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 99999;
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: min(420px, calc(100vw - 48px));
    pointer-events: none;
}

.nexa-admin-toast-stack .message {
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    width: 100%;
    margin: 0;
    padding: 16px 44px 16px 58px;
    border: 0;
    border-left: 5px solid #1f7a4d;
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.18);
    color: #111827;
    font-size: 14px;
    line-height: 1.45;
    pointer-events: auto;
    transform: translateX(18px);
    opacity: 0;
    animation: nexaToastIn 180ms ease-out forwards;
}

.nexa-admin-toast-stack .message::before {
    position: absolute;
    left: 18px;
    top: 15px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 999px;
    background: #dcfce7;
    color: #15803d;
    font-size: 15px;
    font-weight: 700;
    content: "\2713";
}

.nexa-admin-toast-stack .message-success,
.nexa-admin-toast-stack .success {
    border-left-color: #16a34a;
}

.nexa-admin-toast-stack .message-error,
.nexa-admin-toast-stack .error {
    border-left-color: #dc2626;
}

.nexa-admin-toast-stack .message-error::before,
.nexa-admin-toast-stack .error::before {
    background: #fee2e2;
    color: #b91c1c;
    content: "!";
}

.nexa-admin-toast-stack .message-warning,
.nexa-admin-toast-stack .warning,
.nexa-admin-toast-stack .message-notice,
.nexa-admin-toast-stack .notice {
    border-left-color: #d97706;
}

.nexa-admin-toast-stack .message-warning::before,
.nexa-admin-toast-stack .warning::before,
.nexa-admin-toast-stack .message-notice::before,
.nexa-admin-toast-stack .notice::before {
    background: #fef3c7;
    color: #b45309;
    content: "!";
}

.nexa-admin-toast-stack .message-info,
.nexa-admin-toast-stack .info {
    border-left-color: #2563eb;
}

.nexa-admin-toast-stack .message-info::before,
.nexa-admin-toast-stack .info::before {
    background: #dbeafe;
    color: #1d4ed8;
    content: "i";
}

.nexa-admin-toast-stack .message > div {
    flex: 1 1 auto;
    min-width: 0;
    margin: 0;
    padding: 1px 0 0;
}

.nexa-admin-toast-stack .message > div::before,
.nexa-admin-toast-stack .message > div::after {
    display: none !important;
    content: none !important;
}

.nexa-admin-toast-close {
    position: absolute;
    top: 10px;
    right: 12px;
    width: 26px;
    height: 26px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: #6b7280;
    cursor: pointer;
    font-size: 20px;
    line-height: 24px;
    padding: 0;
}

.nexa-admin-toast-close:hover {
    background: #f3f4f6;
    color: #111827;
}

.nexa-admin-toast-stack .message.nexa-toast-leaving {
    animation: nexaToastOut 160ms ease-in forwards;
}

@keyframes nexaToastIn {
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes nexaToastOut {
    to {
        transform: translateX(18px);
        opacity: 0;
    }
}

@media (max-width: 640px) {
    .nexa-admin-toast-stack {
        top: 16px;
        right: 16px;
        left: 16px;
        width: auto;
    }
}
