/* 引入 Nasalization 字体 (请确保你的项目中带有这个字体文件，路径需根据实际情况修改) */
/* 引入 Nasalization 字体 (OTF 格式) */
        @font-face {
            font-family: 'Nasalization';
            src: url('./fonts/nasalization.otf') format('opentype'); /* 请确保路径与你的实际文件位置一致 */
            font-weight: normal;
            font-style: normal;
        }

        :root {
            --bg-deep: #020617;
            --text-main: #f8fafc;
            --text-muted: #94a3b8;
            --text-alert: #ef4444;
            --accent-cyan: #06b6d4;
            --accent-purple: #8b5cf6;
            --hud-border: rgba(6, 182, 212, 0.3);
            --hud-bg: rgba(2, 6, 23, 0.75);
            --hud-glow: 0 0 10px rgba(6, 182, 212, 0.2); 
        }

        /* 基础重置与排版 */
        body { 
            margin: 0; 
            background: var(--bg-deep); 
            background-image: radial-gradient(circle at 50% 0%, #1e1b4b 0%, #020617 70%);
            overflow: hidden; 
            /* 修改为 Nasalization 字体，并添加 sans-serif 作为后备 */
            font-family: 'Nasalization', sans-serif; 
            touch-action: none; 
            color: var(--text-main);
            user-select: none;
        }

        /* CRT 扫描线特效 */
        .scanlines {
            position: fixed; top: 0; left: 0; width: 100%; height: 100%;
            background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%);
            background-size: 100% 4px; z-index: 9999; pointer-events: none; opacity: 0.5;
        }
        
        /* 加载页面 */
        #loading-screen { 
            position: fixed; top: 0; left: 0; width: 100%; height: 100%; 
            background: #020617; overflow: hidden; display: flex; flex-direction: column; 
            align-items: center; justify-content: center; z-index: 1000; 
            transition: transform 1.2s cubic-bezier(0.85, 0, 0.15, 1); 
        }
        .loader-box {
            width: 350px; padding: 2.5rem; border: 1px solid var(--accent-cyan);
            background: rgba(6, 182, 212, 0.05); text-align: center; position: relative;
        }
        .loader-box::before, .loader-box::after { content: ''; position: absolute; width: 20px; height: 20px; }
        .loader-box::before { top: -5px; left: -5px; border-top: 2px solid var(--accent-cyan); border-left: 2px solid var(--accent-cyan); }
        .loader-box::after { bottom: -5px; right: -5px; border-bottom: 2px solid var(--accent-cyan); border-right: 2px solid var(--accent-cyan); }
        .loader-logo { font-size: 1.8rem; font-weight: 900; letter-spacing: 6px; margin-bottom: 30px; color: var(--text-main); text-shadow: var(--hud-glow); }
        
        .loader-bar-container { width: 100%; height: 2px; background: #1e293b; position: relative; overflow: hidden; }
        #loader-progress { width: 0%; height: 100%; background: var(--accent-cyan); box-shadow: var(--hud-glow); transition: width 0.3s ease; }
        #loader-text-dynamic { margin-top: 15px; font-size: 0.85rem; letter-spacing: 2px; color: var(--accent-cyan); }

        /* 顶部状态栏 */
        #status { 
            position: absolute; top: 40px; width: 100%; text-align: center; 
            color: var(--accent-cyan); font-weight: bold; font-size: 1.2rem; letter-spacing: 4px;
            pointer-events: none; z-index: 100; opacity: 0; transition: opacity 1s 1s; 
            text-shadow: var(--hud-glow); text-transform: uppercase;
        }
        .status-active { animation: hudBlink 1s step-end infinite; color: var(--text-alert) !important; text-shadow: 0 0 15px rgba(239, 68, 68, 0.8) !important; }
        @keyframes hudBlink { 50% { opacity: 0; } }
        
        /* 左上角面板 */
        #counter-panel { 
            position: absolute; top: 20px; left: 20px; 
            background: var(--hud-bg); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
            padding: 20px; border-left: 3px solid var(--accent-cyan); border-top: 1px solid var(--hud-border); border-bottom: 1px solid var(--hud-border);
            color: var(--text-muted); z-index: 100; font-size: 0.85rem; 
            transform: translateX(-150%); transition: transform 0.8s 1.2s; 
            box-shadow: 10px 10px 0 rgba(0,0,0,0.3); min-width: 200px;
        }
        .sys-label { color: var(--accent-cyan); font-size: 0.75rem; margin-bottom: 1rem; letter-spacing: 2px; }
        .data-list { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--hud-border); }
        .data-list li { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid var(--hud-border); letter-spacing: 1px; }
        .data-list span:first-child { color: var(--text-main); }
        .data-highlight { font-weight: bold; color: var(--accent-cyan); text-shadow: var(--hud-glow); }
        
        /* 底部控制区 */
        #control-panel { 
            position: absolute; bottom: -30%; left: 0; width: 100%; height: 25%; 
            background: linear-gradient(0deg, var(--hud-bg) 0%, rgba(2,6,23,0) 100%); 
            display: flex; align-items: center; justify-content: center; gap: 80px; 
            z-index: 101; transition: bottom 1s 1s; border-top: 1px solid var(--hud-border);
        }
        
        /* 补货按钮 */
        #spawn-btn { 
            position: fixed; top: 20px; right: 20px; padding: 10px 20px; 
            background: rgba(6, 182, 212, 0.05); backdrop-filter: blur(10px); 
            border: 1px solid var(--accent-cyan); color: var(--accent-cyan); 
            cursor: pointer; z-index: 100; font-weight: bold; 
            /* 修改字体为 Nasalization */
            font-family: 'Nasalization', sans-serif;
            letter-spacing: 2px; opacity: 0; transition: all 0.3s; text-transform: uppercase;
            box-shadow: inset 0 0 10px rgba(6, 182, 212, 0.1);
        }
        #spawn-btn:hover { background: var(--accent-cyan); color: #000; box-shadow: var(--hud-glow); }
        #spawn-btn:disabled { border-color: #334155; color: #334155; cursor: not-allowed; box-shadow: none; background: transparent; }
        
        /* 摇杆 */
        #joystick-container { 
            width: 160px; height: 160px; background: rgba(6, 182, 212, 0.05); 
            border: 1px dashed var(--accent-cyan); border-radius: 50%; 
            display: flex; align-items: center; justify-content: center; position: relative; 
        }
        #joystick-container::after { content: '+'; position: absolute; color: var(--accent-cyan); opacity: 0.5; font-size: 1.5rem; }
        #joystick-knob { 
            width: 60px; height: 60px; background: rgba(2, 6, 23, 0.9); 
            border: 2px solid var(--accent-cyan); border-radius: 50%; 
            box-shadow: var(--hud-glow); cursor: grab; position: relative; z-index: 1; transition: background 0.2s; 
        }
        #joystick-knob:active { background: var(--accent-cyan); cursor: grabbing; }
        
        /* 抓取按钮 */
        #catch-btn { 
            width: 130px; height: 130px; background: transparent; 
            color: var(--accent-cyan); border-radius: 0; border: 1px solid var(--accent-cyan); 
            font-size: 1.2rem; font-weight: bold; cursor: pointer; transition: all 0.3s; 
            display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; 
            /* 修改字体为 Nasalization */
            font-family: 'Nasalization', sans-serif; 
            letter-spacing: 2px; position: relative; overflow: hidden;
        }
        #catch-btn::before { content: ''; position: absolute; top: 0; left: -100%; width: 100%; height: 100%; background: var(--accent-cyan); transition: left 0.3s cubic-bezier(0.25, 1, 0.5, 1); z-index: -1; }
        #catch-btn:hover:not(:disabled) { color: #000; box-shadow: var(--hud-glow); }
        #catch-btn:hover:not(:disabled)::before { left: 0; }
        #catch-btn:active:not(:disabled) { transform: scale(0.95); }
        #catch-btn:disabled { border-color: #334155; color: #334155; cursor: not-allowed; box-shadow: none; }
        .btn-subtext { font-size: 0.7rem; opacity: 0.8; font-weight: normal; }