/* Toast容器样式 */
.toast-container {
    position: fixed;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: none;
}

/* 位置样式 */
.toast-container.top-left {
    top: 20px;
    left: 20px;
}

.toast-container.top-center {
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
}

.toast-container.top-right {
    top: 20px;
    right: 20px;
}

.toast-container.bottom-left {
    bottom: 20px;
    left: 20px;
}

.toast-container.bottom-center {
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
}

.toast-container.bottom-right {
    bottom: 20px;
    right: 20px;
}

/* Toast项目样式 */
.toast {
    min-width: 300px !important;
    max-width: 500px !important;
    min-height: 50px !important;
    padding: 12px 20px;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    display: flex !important;
    align-items: center;
    pointer-events: auto;
    position: relative;
    overflow: hidden;
    animation: toastSlideIn 0.3s ease-out forwards;
    transition: transform 0.3s ease, opacity 0.3s ease;
    background-color: white;
}

.toast.hiding {
    animation: toastSlideOut 0.3s ease-in forwards;
}

/* Toast类型样式 */
.toast.success {
    background-color: #f6ffed;
    border: 1px solid #b7eb8f;
    color: #52c41a;
}

.toast.error {
    background-color: #fff2f0;
    border: 1px solid #ffccc7;
    color: #ff4d4f;
}

.toast.warning {
    background-color: #fffbe6;
    border: 1px solid #ffe58f;
    color: #faad14;
}

.toast.info {
    background-color: #e6f7ff;
    border: 1px solid #91d5ff;
    color: #1890ff;
}

/* 图标样式 */
.toast-icon {
    margin-right: 10px;
    font-size: 18px;
    display: flex;
    align-items: center;
}

/* 内容样式 */
.toast-content {
    flex: 1;
    font-size: 14px;
    line-height: 1.5;
}

/* 关闭按钮 */
.toast-close {
    margin-left: 10px;
    background: none;
    border: none;
    font-size: 16px;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.2s;
    color: inherit;
}

.toast-close:hover {
    opacity: 1;
}

/* 进度条 */
.toast-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    background-color: currentColor;
    opacity: 0.3;
    width: 100%;
    transform: scaleX(1);
    transform-origin: left;
    transition: transform linear;
}

/* 动画 */
@keyframes toastSlideIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes toastSlideOut {
    from {
        opacity: 1;
        transform: translateY(0);
    }

    to {
        opacity: 0;
        transform: translateY(-20px);
    }
}