.elsp-module-toast-wrap {
    position: fixed;
    z-index: 99999;
    width: min(340px, calc(100vw - 32px));
    pointer-events: none;
}

.elsp-module-toast-wrap.elsp-module-toast-wrap--top-right {
    top: clamp(16px, 3vw, 24px);
    right: clamp(16px, 3vw, 24px);
}

.elsp-module-toast-wrap.elsp-module-toast-wrap--top-left {
    top: clamp(16px, 3vw, 24px);
    left: clamp(16px, 3vw, 24px);
}

.elsp-module-toast-wrap.elsp-module-toast-wrap--bottom-right {
    bottom: clamp(16px, 3vw, 24px);
    right: clamp(16px, 3vw, 24px);
}

.elsp-module-toast-wrap.elsp-module-toast-wrap--bottom-left {
    bottom: clamp(16px, 3vw, 24px);
    left: clamp(16px, 3vw, 24px);
}

.elsp-module-toast {
    --elsp-toast-accent: #38ad8a;
    --elsp-toast-error: #ef4444;
    display: flex;
    align-items: center;
    gap: clamp(10px, 2.5vw, 14px);
    width: 100%;
    min-height: clamp(60px, 14vw, 72px);
    padding: clamp(12px, 3vw, 16px) clamp(36px, 8vw, 44px) clamp(12px, 3vw, 16px) clamp(14px, 3vw, 18px);
    border-radius: clamp(12px, 3vw, 16px);
    background: #ffffff;
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.1);
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 0.28s ease, transform 0.28s ease;
    pointer-events: all;
    position: relative;
}

.elsp-module-toast-wrap.is-visible .elsp-module-toast {
    opacity: 1;
    transform: translateY(0);
}

.elsp-module-toast__icon {
    flex: 0 0 auto;
    width: clamp(24px, 5.5vw, 28px);
    height: clamp(24px, 5.5vw, 28px);
    color: var(--elsp-toast-accent);
}

.elsp-module-toast--error .elsp-module-toast__icon {
    color: var(--elsp-toast-error);
}

.elsp-module-toast__icon svg {
    display: block;
    width: 100%;
    height: 100%;
}

.elsp-module-toast__content {
    flex: 1 1 auto;
    min-width: 0;
}

.elsp-module-toast__title {
    color: var(--elsp-toast-accent);
    font-size: clamp(13px, 2.8vw, 14px);
    font-weight: 700;
    line-height: 1.35;
}

.elsp-module-toast--error .elsp-module-toast__title {
    color: var(--elsp-toast-error);
}

.elsp-module-toast__message {
    margin-top: clamp(2px, 1vw, 4px);
    font-size: clamp(12px, 2.5vw, 13px);
    line-height: 1.4;
}

.elsp-module-toast__message a {
    color: var(--elsp-toast-accent);
    text-decoration: underline;
    text-underline-offset: 2px;
    font-weight: 500;
}

.elsp-module-toast__message a:hover,
.elsp-module-toast__message a:focus {
    opacity: 0.85;
}

.elsp-module-toast__close {
    position: absolute;
    top: clamp(10px, 2.5vw, 14px);
    right: clamp(10px, 2.5vw, 14px);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: clamp(18px, 4vw, 20px);
    height: clamp(18px, 4vw, 20px);
    padding: 0;
    margin: 0;
    border: 0;
    background: transparent;
    color: var(--elsp-toast-accent);
    cursor: pointer;
    line-height: 1;
    transition: opacity 0.2s ease;
    -webkit-appearance: none;
    appearance: none;
}

.elsp-module-toast--error .elsp-module-toast__close {
    color: var(--elsp-toast-error);
}

.elsp-module-toast__close:hover,
.elsp-module-toast__close:focus {
    opacity: 0.7;
    outline: none;
}

.elsp-module-toast__close svg {
    display: block;
    width: clamp(10px, 2.2vw, 12px);
    height: clamp(10px, 2.2vw, 12px);
}

@media (max-width: 767px) {
    .elsp-module-toast-wrap.elsp-module-toast-wrap--top-right,
    .elsp-module-toast-wrap.elsp-module-toast-wrap--top-left,
    .elsp-module-toast-wrap.elsp-module-toast-wrap--bottom-right,
    .elsp-module-toast-wrap.elsp-module-toast-wrap--bottom-left {
        left: 16px;
        right: 16px;
        width: auto;
    }
}
