/* Chakra UI–inspired toasts (dark, POSEIDON theme) */
#chakra-toast-root {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    pointer-events: none;
    max-width: min(420px, calc(100vw - 2rem));
}

.chakra-toast {
    pointer-events: auto;
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    background: #1a202c;
    color: #edf2f7;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow:
        0 6px 16px rgba(0, 0, 0, 0.35),
        0 0 0 1px rgba(0, 0, 0, 0.2);
    transform: translateX(110%);
    opacity: 0;
    transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.28s ease;
}

.chakra-toast.is-visible {
    transform: translateX(0);
    opacity: 1;
}

.chakra-toast.is-leaving {
    transform: translateX(110%);
    opacity: 0;
}

.chakra-toast__icon {
    flex-shrink: 0;
    width: 1.35rem;
    height: 1.35rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    font-size: 0.72rem;
    margin-top: 0.1rem;
}

.chakra-toast--success .chakra-toast__icon {
    background: rgba(72, 187, 120, 0.18);
    color: #48bb78;
}

.chakra-toast--error .chakra-toast__icon {
    background: rgba(245, 101, 101, 0.18);
    color: #f56565;
}

.chakra-toast--warning .chakra-toast__icon {
    background: rgba(237, 137, 54, 0.18);
    color: #ed8936;
}

.chakra-toast--info .chakra-toast__icon {
    background: rgba(0, 229, 255, 0.14);
    color: #00e5ff;
}

.chakra-toast--loading .chakra-toast__icon {
    background: rgba(0, 229, 255, 0.14);
    color: #00e5ff;
}

.chakra-toast__body {
    flex: 1;
    min-width: 0;
}

.chakra-toast__title {
    font-size: 0.88rem;
    font-weight: 700;
    line-height: 1.35;
    margin: 0 0 0.15rem;
}

.chakra-toast__title:only-child,
.chakra-toast__title:last-child {
    margin-bottom: 0;
}

.chakra-toast__desc {
    font-size: 0.82rem;
    line-height: 1.45;
    color: #a0aec0;
    margin: 0;
}

.chakra-toast__close {
    flex-shrink: 0;
    border: none;
    background: transparent;
    color: #718096;
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    line-height: 1;
    padding: 0;
    margin: -0.15rem -0.25rem 0 0;
    transition: color 0.15s ease, background 0.15s ease;
}

.chakra-toast__close:hover {
    color: #edf2f7;
    background: rgba(255, 255, 255, 0.06);
}

.chakra-toast__spinner {
    width: 0.85rem;
    height: 0.85rem;
    border: 2px solid rgba(0, 229, 255, 0.25);
    border-top-color: #00e5ff;
    border-radius: 50%;
    animation: chakra-toast-spin 0.65s linear infinite;
}

@keyframes chakra-toast-spin {
    to { transform: rotate(360deg); }
}

@media (max-width: 576px) {
    #chakra-toast-root {
        left: 1rem;
        right: 1rem;
        max-width: none;
    }

    .chakra-toast {
        transform: translateY(-110%);
    }

    .chakra-toast.is-visible {
        transform: translateY(0);
    }

    .chakra-toast.is-leaving {
        transform: translateY(-110%);
    }
}
