/* Centre portal — top-center toast notifications */
#centre-toast-stack {
    position: fixed;
    top: 16px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10050;
    width: min(520px, calc(100vw - 24px));
    pointer-events: none;
}

body.centre-portal #centre-toast-stack {
    top: 70px;
}

.centre-toast {
    pointer-events: auto;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 10px;
    padding: 14px 16px;
    border-radius: 8px;
    color: #fff;
    background: #333;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.22);
    border-left: 5px solid rgba(255, 255, 255, 0.85);
    animation: centreToastIn 0.28s ease;
    font-family: Arial, Helvetica, sans-serif;
}

.centre-toast--success {
    background: linear-gradient(135deg, #2d8a4e 0%, #239954 100%);
    border-left-color: #b8f0cb;
}

.centre-toast--error {
    background: linear-gradient(135deg, #a93226 0%, #c0392b 100%);
    border-left-color: #ffb3aa;
}

.centre-toast--info {
    background: linear-gradient(135deg, #1f6fa8 0%, var(--site-primary, #1f7ab5) 100%);
    border-left-color: #b3ddff;
}

.centre-toast__icon {
    flex: 0 0 22px;
    font-size: 18px;
    line-height: 1.2;
    margin-top: 1px;
}

.centre-toast__body {
    flex: 1;
    min-width: 0;
}

.centre-toast__title {
    display: block;
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 3px;
}

.centre-toast__message {
    display: block;
    font-size: 13px;
    line-height: 1.45;
    opacity: 0.96;
    word-break: break-word;
}

.centre-toast__close {
    flex: 0 0 auto;
    border: 0;
    background: transparent;
    color: #fff;
    font-size: 20px;
    line-height: 1;
    opacity: 0.85;
    cursor: pointer;
    padding: 0;
    margin-left: 4px;
}

.centre-toast__close:hover {
    opacity: 1;
}

.centre-toast.is-leaving {
    animation: centreToastOut 0.22s ease forwards;
}

@keyframes centreToastIn {
    from {
        opacity: 0;
        transform: translateY(-16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes centreToastOut {
    from {
        opacity: 1;
        transform: translateY(0);
    }
    to {
        opacity: 0;
        transform: translateY(-12px);
    }
}

@media (max-width: 767px) {
    body.centre-portal #centre-toast-stack {
        top: 62px;
    }

    .centre-toast {
        padding: 12px 14px;
    }
}
