/* ============================================================
   base.css —— 全局重置 / gameContainer / 加载遮罩
   ============================================================ */

/* ---- 全局重置 + 防选中 + 触摸支持 ---- */
* {
    margin: 0; padding: 0; box-sizing: border-box;
    user-select: none;
    -webkit-user-select: none;
    -webkit-touch-callout: none;
    -webkit-tap-highlight-color: transparent;
}
html, body {
    touch-action: none;
    overscroll-behavior: none;
}
body {
    background: #0d0d0d;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    font-family: "Microsoft YaHei", sans-serif;
    overflow: hidden;
}

#gameContainer {
    position: relative;
    width: 1280px;
    height: 720px;
    background: #1a1a1a;
    border: 2px solid #333;
    box-shadow: 0 0 60px rgba(0, 0, 0, 0.9);
    overflow: hidden;
}
#gameContainer::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(255,255,255,0.015) 2px, rgba(255,255,255,0.015) 4px),
        radial-gradient(ellipse at center, #1f1f1f 0%, #0a0a0a 100%);
    pointer-events: none;
    z-index: 0;
}

/* ---- 加载遮罩 ---- */
#loadingOverlay {
    position: absolute;
    inset: 0;
    top: 0; left: 0; right: 0; bottom: 0;
    background: #0a0a0a;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.5s;
    pointer-events: all;
}
#loadingOverlay.hidden {
    opacity: 0;
    pointer-events: none;
}
.loadingText {
    color: #fff;
    font-size: 24px;
    letter-spacing: 8px;
    margin-bottom: 30px;
    text-shadow: 0 0 12px rgba(233, 69, 96, 0.6);
    animation: loadingPulse 1.4s ease-in-out infinite;
}
@keyframes loadingPulse {
    0%, 100% { opacity: 0.5; }
    50%      { opacity: 1; }
}
.loadingBar {
    width: 320px;
    height: 6px;
    background: #1a1a1a;
    border: 1px solid #333;
    border-radius: 3px;
    overflow: hidden;
}
.loadingBarFill {
    height: 100%;
    width: 30%;
    background: linear-gradient(90deg, #e94560, #ff758f, #e94560);
    background-size: 200% 100%;
    animation: loadingBarRun 1.6s ease-in-out infinite;
}
@keyframes loadingBarRun {
    0%   { transform: translateX(-100%); }
    100% { transform: translateX(350%); }
}