/*=========notify=====*/
/* 通知容器 - 固定在右上角 */
.notification-container {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 400px;
    width: calc(100% - 48px);
    pointer-events: none; /* 让容器不阻挡点击，但内部的alert可以点击 */
}

.notification-container .alert {
    pointer-events: auto; /* 恢复alert的点击事件 */
}

/* 基础通知样式 */
.alert {
    position: relative;
    padding: 16px 20px;
    border-radius: 12px;
    background: white;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15), 0 2px 8px rgba(0, 0, 0, 0.06);
    display: flex;
    align-items: flex-start;
    gap: 12px;
    backdrop-filter: blur(4px);
    border-left: 4px solid transparent;
    transition: all 0.3s ease;
    animation: slideIn 0.3s ease forwards;
}

.alert:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
}

/* 图标样式 */
.alert .glyphicon {
    font-size: 20px;
    flex-shrink: 0;
    margin-top: 2px;
}

/* 消息文本 */
.alert span:not(.glyphicon) {
    flex: 1;
    font-size: 14px;
    line-height: 1.6;
    color: #1e293b;
    word-break: break-word;
}

/* 关闭按钮 */
.alert .close {
    background: none;
    border: none;
    padding: 4px;
    cursor: pointer;
    font-size: 20px;
    line-height: 1;
    color: #94a3b8;
    transition: all 0.2s ease;
    flex-shrink: 0;
    opacity: 0.7;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
}

.alert .close:hover {
    color: #475569;
    opacity: 1;
    background-color: rgba(0, 0, 0, 0.05);
    transform: scale(1.1);
}

/* 不同类型通知的样式 */

/* 成功通知 - 绿色 */
.alert-success {
    background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
    border-left-color: #22c55e;
}

.alert-success .glyphicon {
    color: #22c55e;
}

/* 信息通知 - 蓝色 */
.alert-info {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    border-left-color: #3b82f6;
}

.alert-info .glyphicon {
    color: #3b82f6;
}

/* 警告通知 - 黄色/橙色 */
.alert-warning {
    background: linear-gradient(135deg, #fefce8 0%, #fef9c3 100%);
    border-left-color: #eab308;
}

.alert-warning .glyphicon {
    color: #eab308;
}

/* 错误通知 - 红色 */
.alert-danger {
    background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%);
    /*background: rgba(221, 66, 66, 0.92);*/
    border-left-color: #ef4444;
}

.alert-danger .glyphicon {
    color: #ef4444;
}

/* 淡入淡出动画 */
.fade-enter-active,
.fade-leave-active {
    transition: all 0.3s ease;
}

.fade-enter-from {
    opacity: 0;
    transform: translateX(30px);
}

.fade-leave-to {
    opacity: 0;
    transform: translateX(30px);
}

.fade-move {
    transition: transform 0.3s ease;
}

/* 入场动画 */
@keyframes slideIn {
    0% {
        opacity: 0;
        transform: translateX(30px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

/* 响应式设计 - 移动端 */
@media screen and (max-width: 640px) {
    .notification-container {
        top: 16px;
        right: 16px;
        left: 16px;
        max-width: none;
        width: auto;
    }

    .alert {
        padding: 14px 16px;
    }

    .alert .glyphicon {
        font-size: 18px;
    }

    .alert span:not(.glyphicon) {
        font-size: 13px;
    }
}

/* 可选：添加进度条效果 */
.alert.progress {
    position: relative;
    overflow: hidden;
}

.alert.progress::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: rgba(0, 0, 0, 0.1);
    animation: progress 3s linear forwards;
}

@keyframes progress {
    0% {
        width: 100%;
    }
    100% {
        width: 0%;
    }
}

/* 可选：深色主题支持 */
/*@media (prefers-color-scheme: dark) {
    .alert {
        background: #1e293b;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    }

    .alert span:not(.glyphicon) {
        color: #e2e8f0;
    }

    .alert-success {
        background: linear-gradient(135deg, #14532d 0%, #166534 100%);
    }

    .alert-info {
        background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%);
    }

    .alert-warning {
        background: linear-gradient(135deg, #854d0e 0%, #92400e 100%);
    }

    .alert-danger {
        background: linear-gradient(135deg, #7f1d1d 0%, #991b1b 100%);
    }
}*/

/* 可选：堆叠效果 */
.notification-container .alert + .alert {
    margin-top: -8px;
}

.notification-container:hover .alert {
    opacity: 1 !important;
    transform: scale(1) !important;
}

/* 可选：为不同位置的通知容器 */
.notification-container.top-left {
    top: 24px;
    right: auto;
    left: 24px;
}

.notification-container.top-center {
    top: 24px;
    right: 50%;
    transform: translateX(50%);
}

.notification-container.bottom-right {
    top: auto;
    bottom: 24px;
    right: 24px;
}

.notification-container.bottom-left {
    top: auto;
    bottom: 24px;
    right: auto;
    left: 24px;
}

.notification-container.bottom-center {
    top: auto;
    bottom: 24px;
    right: 50%;
    transform: translateX(50%);
}