/* 全屏加载遮罩层 */
#loading {
    bottom: 0;
    left: 0;
    position: fixed; /* 固定定位，始终覆盖整个屏幕 */
    right: 0;
    top: 0;
    z-index: 9999; /* 高优先级层级，确保在最上层显示 */
    background-color: #f4f5f5; /* 浅灰色背景 */
    pointer-events: none; /* 允许点击穿透遮罩层，不影响页面交互 */
}

/* 加载动画核心元素 */
.loader-inner {
    will-change: transform; /* 浏览器优化提示：该元素将有transform动画 */
    width: 40px;
    height: 40px;
    position: absolute; /* 绝对定位，相对于#loading容器 */
    top: 50%;
    left: 50%;
    margin: -20px 0 0 -20px; /* 负边距实现元素自身居中 */
    background-color: #3742fa; /* 深蓝色圆形 */
    border-radius: 50%; /* 圆形效果 */
    animation: scaleout 0.6s infinite ease-in-out forwards; /* 应用缩放动画 */
    text-indent: -99999px; /* 隐藏可能的文本内容 */
    z-index: 999991; /* 确保在遮罩层之上 */
}

/* 定义缩放动画关键帧 */
@keyframes scaleout {
    0% {
        transform: scale(0); /* 初始状态：缩小到0 */
        opacity: 0; /* 完全透明 */
    }
    40% {
        opacity: 1; /* 中间状态：完全显示 */
    }
    100% {
        transform: scale(1); /* 结束状态：放大到原始大小 */
        opacity: 0; /* 完全透明 */
    }
}