* { margin: 0; padding: 0; box-sizing: border-box; }
html, body { height: 100%; overflow: hidden; background: #071014; font-family: "Microsoft YaHei", "PingFang SC", sans-serif; }
.battle-root { position: fixed; inset: 0; color: #dcebe4; }
.scene-host { position: absolute; inset: 0; }
.scene-host canvas { display: block; }
.vignette { position: absolute; inset: 0; z-index: 5; pointer-events: none; background: radial-gradient(ellipse at center, transparent 55%, rgba(2, 6, 8, .55) 100%); }
.wall-big { position: absolute; top: 96px; z-index: 10; text-align: center; background: rgba(7, 18, 22, .75); border-radius: 9px; padding: 6px 14px; pointer-events: none; }
.wall-big small { display: block; font-size: 10px; letter-spacing: 2px; }
.wall-big b { font-size: 20px; font-weight: 900; }
.wall-big.left { left: 18px; }
.wall-big.left small, .wall-big.left b { color: #ff425f; }
.wall-big.right { right: 18px; }
.wall-big.right small, .wall-big.right b { color: #21d477; }
.utc-clock { position: absolute; top: 148px; left: 18px; z-index: 10; font-size: 11px; color: rgba(255, 255, 255, .6); font-family: monospace; pointer-events: none; }
.round-card #pressureLine { display: block; font-size: 10px; margin-top: 3px; }

.battle-top { position: absolute; top: 0; left: 0; right: 0; z-index: 10; display: flex; align-items: center; gap: 14px; padding: 10px 16px; background: linear-gradient(180deg, rgba(4, 12, 15, .88), rgba(4, 12, 15, 0)); pointer-events: none; }
.battle-top > * { pointer-events: auto; }
.battle-brand { display: flex; align-items: center; gap: 10px; }
.battle-brand .crest { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 9px; background: linear-gradient(135deg, #ffd05b, #b9832b); color: #071014; font-weight: 900; }
.battle-brand b { display: block; font-size: 15px; }
.battle-brand small { color: #9db8ad; font-size: 11px; }
.symbol-switch, .step-switch { display: flex; gap: 6px; }
.symbol-switch button, .step-switch button, .top-actions a, .top-actions button { border: 1px solid rgba(255, 208, 91, .25); background: rgba(10, 22, 26, .78); color: #c8dbd2; border-radius: 7px; padding: 6px 12px; font-size: 12px; cursor: pointer; text-decoration: none; transition: all .15s; }
.symbol-switch button.active, .step-switch button.active { background: #ffd05b; color: #071014; border-color: #ffd05b; font-weight: 700; }
.top-actions { margin-left: auto; display: flex; gap: 6px; }
.top-actions button:hover, .top-actions a:hover { border-color: #ffd05b; color: #ffd05b; }

.battle-score { position: absolute; top: 62px; left: 50%; transform: translateX(-50%); z-index: 10; display: flex; gap: 12px; align-items: stretch; pointer-events: none; }
.army-card, .round-card { background: rgba(7, 18, 22, .82); border: 1px solid rgba(255, 255, 255, .08); border-radius: 10px; padding: 8px 16px; text-align: center; min-width: 130px; backdrop-filter: blur(4px); }
.army-card span, .round-card small { font-size: 11px; color: #9db8ad; }
.army-card b { display: block; font-size: 17px; }
.army-card small { display: block; font-size: 10px; color: #7e968b; margin-top: 2px; }
.army-card.long b { color: #21d477; }
.army-card.short b { color: #ff425f; }
.round-card b { display: block; font-size: 15px; color: #ffc85a; margin: 2px 0; }
.round-card span { font-size: 10px; color: #7e968b; }
.defense-progress { height: 4px; border-radius: 2px; background: rgba(255, 255, 255, .1); margin: 5px 0 3px; overflow: hidden; }
.defense-progress i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #ffd05b, #ff9640); transition: width .6s; }

.price-rail { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); z-index: 10; display: flex; flex-direction: column; gap: 10px; pointer-events: none; }
.price-rail > div { background: rgba(7, 18, 22, .82); border: 1px solid rgba(255, 255, 255, .08); border-radius: 9px; padding: 7px 12px; min-width: 128px; }
.price-rail small { display: block; font-size: 10px; color: #7e968b; }
.price-rail b { font-size: 15px; color: #ffd05b; }
.price-rail .current { border-color: rgba(255, 208, 91, .45); }
.price-rail .current b { font-size: 18px; color: #fff; }
.price-rail .current span { display: block; font-size: 11px; }

.depth-panel { position: absolute; left: 14px; bottom: 44px; z-index: 10; width: 330px; background: rgba(7, 18, 22, .85); border: 1px solid rgba(255, 255, 255, .08); border-radius: 10px; padding: 10px 12px; backdrop-filter: blur(4px); }
.panel-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.panel-head b { font-size: 12px; color: #c8dbd2; }
.panel-head span { font-size: 11px; color: #7e968b; }
#depthChart { width: 100%; height: 120px; display: block; }
.depth-walls { display: flex; justify-content: space-between; font-size: 11px; margin-top: 6px; }
.depth-walls .long { color: #21d477; }
.depth-walls .short { color: #ff425f; }

.battle-log { position: absolute; right: 14px; top: 96px; bottom: 84px; z-index: 10; width: 300px; background: rgba(7, 18, 22, .82); border: 1px solid rgba(255, 255, 255, .08); border-radius: 10px; padding: 10px 12px; display: flex; flex-direction: column; backdrop-filter: blur(4px); }
.log-list { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 6px; scrollbar-width: thin; }
.log-item { display: flex; gap: 8px; font-size: 11px; line-height: 1.45; padding: 5px 7px; border-radius: 6px; background: rgba(255, 255, 255, .03); border-left: 2px solid #555; }
.log-item time { color: #63776d; flex-shrink: 0; }
.log-item.long { border-left-color: #21d477; }
.log-item.short { border-left-color: #ff425f; }
.log-item.long p { color: #b8e8cd; }
.log-item.short p { color: #f3c2cb; }

.battle-history { position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%); z-index: 10; display: flex; align-items: center; gap: 14px; background: rgba(7, 18, 22, .82); border: 1px solid rgba(255, 255, 255, .08); border-radius: 10px; padding: 7px 14px; pointer-events: none; }
.battle-history b { font-size: 11px; margin-right: 8px; }
.battle-history span { font-size: 11px; color: #9db8ad; }
.history-dots { display: flex; gap: 4px; }
.history-dot { display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; font-size: 10px; font-weight: 700; }
.history-dot.long { background: rgba(33, 212, 119, .2); color: #21d477; border: 1px solid #21d477; }
.history-dot.short { background: rgba(255, 66, 95, .2); color: #ff425f; border: 1px solid #ff425f; }

.camera-hint { position: absolute; right: 16px; bottom: 44px; z-index: 10; font-size: 11px; color: rgba(255, 255, 255, .5); background: rgba(7, 18, 22, .6); padding: 5px 10px; border-radius: 6px; pointer-events: none; }

.event-banner { position: absolute; left: 50%; top: 34%; transform: translate(-50%, -50%) scale(.9); z-index: 20; font-size: 26px; font-weight: 900; color: #ffd05b; text-shadow: 0 2px 14px rgba(0, 0, 0, .8); opacity: 0; transition: all .25s; pointer-events: none; white-space: nowrap; }
.event-banner.show { opacity: 1; transform: translate(-50%, -50%) scale(1); }
.event-banner.long { color: #21d477; }
.event-banner.short { color: #ff425f; }

.round-banner { position: absolute; left: 50%; top: 42%; transform: translate(-50%, -50%); z-index: 21; text-align: center; opacity: 0; transition: opacity .4s; pointer-events: none; }
.round-banner.show { opacity: 1; }
.round-banner b { display: block; font-size: 46px; font-weight: 900; letter-spacing: 6px; color: #fff; text-shadow: 0 4px 30px rgba(255, 208, 91, .55), 0 2px 8px rgba(0, 0, 0, .9); }
.round-banner span { font-size: 15px; color: #ffd05b; text-shadow: 0 2px 8px rgba(0, 0, 0, .9); }

.loading-mask { position: absolute; inset: 0; z-index: 50; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; background: radial-gradient(ellipse at center, #0c1c22 0%, #050c0f 70%); transition: opacity .6s; }
.loading-mask.hide { opacity: 0; pointer-events: none; }
.loading-mask b { font-size: 20px; color: #ffd05b; }
.loading-mask span { font-size: 12px; color: #7e968b; }
.loading-mask a { color: #21d477; }
.radar { width: 72px; height: 72px; border-radius: 50%; border: 2px solid rgba(255, 208, 91, .25); position: relative; overflow: hidden; }
.radar::before { content: ""; position: absolute; inset: 0; background: conic-gradient(from 0deg, rgba(255, 208, 91, .7), transparent 90deg); animation: radar-spin 1.4s linear infinite; }
@keyframes radar-spin { to { transform: rotate(360deg); } }

@media (max-width: 900px) {
    .battle-log { display: none; }
    .depth-panel { width: 250px; }
    .step-switch button { padding: 5px 7px; font-size: 10px; }
    .camera-hint { display: none; }
}
