/*****弹出窗口******/
/* 遮罩层样式：新增隐藏类 */
.msg-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}
/* 无遮罩层时的样式：透明背景+不占满屏幕 */
.msg-overlay.no-overlay {
    background-color: transparent;
    pointer-events: none; /* 无遮罩时，遮罩层不拦截点击 */
}
.msg-overlay.active {
    opacity: 1;
    visibility: visible;
}
.msg-box {
    width: 380px;
    max-width: 90%;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    padding: 24px;
    position: absolute;
    cursor: move;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9) translateY(-20px);
    opacity: 0;
    transition:
            transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275),
            opacity 0.4s ease;
    pointer-events: auto; /* 确保窗口本身可点击 */
}
.msg-overlay.active .msg-box {
    transform: translate(-50%, -50%) scale(1) translateY(0);
    opacity: 1;
}
.msg-box.dragging {
    transition: none !important;
}
.msg-title-wrap {
    cursor: move;
    margin-bottom: 12px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}
.msg-close-btn {
    position: static;
    width: 24px;
    height: 24px;
    border: none;
    background-color: transparent;
    cursor: pointer;
    font-size: 16px;
    color: #999;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    transition: all 0.2s ease;
    flex-shrink: 0;
}
.msg-close-btn:hover {
    background-color: #f5f5f5;
    color: #666;
}
.msg-title {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-right: 8px;
}
.msg-content {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
    margin-bottom: 20px;
    cursor: default;
}
.msg-btn-group {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    cursor: default;
}
.msg-btn {
    padding: 8px 16px;
    border-radius: 4px;
    border: none;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.2s ease;
}
.msg-btn-cancel {
    background-color: #f5f5f5;
    color: #666;
}
.msg-btn-cancel:hover {
    background-color: #e8e8e8;
}
.msg-btn-confirm {
    background-color: #409eff;
    color: #fff;
}
.msg-btn-confirm:hover {
    background-color: #3393f3;
}


/* 分页容器基础样式 - 适配移动端 */
.pagination {
    margin: 20px 0;
    padding: 0 15px; /* 左右留白，避免贴边 */
    list-style: none;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap; /* 小屏幕自动换行，防止横向溢出 */
    gap: 5px; /* 统一间距，适配移动端触控 */
    font-family: "PingFang SC", "Microsoft YaHei", sans-serif;
    box-sizing: border-box;
}

/* 分页项通用样式 */
.pagination li {
    flex-shrink: 0; /* 防止按钮被压缩变形 */
}

/* 按钮/文本基础样式 - 保证移动端点击区域 */
.pagination li a,
.pagination li span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px; /* 最小点击宽度，适配手指触控 */
    height: 34px;
    padding: 0 6px;
    border-radius: 6px; /* 圆角更符合移动端审美 */
    font-size: 14px;
    text-decoration: none;
    transition: all 0.2s ease; /* 顺滑过渡 */
    box-sizing: border-box;
}

/* 可点击页码样式 */
.pagination li a {
    background-color: #fff;
    color: #5B7FFF; /* 主色调，可根据项目调整 */
    border: 1px solid #e5e7eb;
}

/* 移动端点击/悬浮反馈 */
.pagination li a:hover,
.pagination li a:active {
    background-color: #f0f5ff;
    border-color: #5B7FFF;
    transform: translateY(-1px); /* 轻微上浮，增强交互感 */
}

/* 当前激活页样式 */
.pagination li.active span {
    background-color: #5B7FFF;
    color: #fff;
    border: 1px solid #5B7FFF;
    font-weight: 500;
}

/* 禁用状态（上一页/下一页不可点、省略号） */
.pagination li.disabled span {
    background-color: #f9fafb;
    color: #9ca3af;
    border: 1px solid #e5e7eb;
    cursor: not-allowed;
}

/* 响应式适配 - 小屏手机（375px以下） */
@media (max-width: 375px) {
    .pagination li a,
    .pagination li span {
        min-width: 30px;
        height: 30px;
        font-size: 13px;
    }
    .pagination {
        gap: 3px;
        padding: 0 10px;
    }
}

/* 超小屏适配（320px以下，如旧款手机） */
@media (max-width: 320px) {
    .pagination li a,
    .pagination li span {
        min-width: 28px;
        height: 28px;
        font-size: 12px;
    }
    /* 省略号进一步压缩，节省空间 */
    .pagination li.disabled span {
        min-width: 28px;
        padding: 0;
    }
}