:root {
    --color-bg: #1a1a1a;
    --color-panel: rgba(26, 38, 26, 0.92);
    --color-primary: #2a3b2a;
    --color-accent: #ff6b00;
    --color-accent-hover: #ff8533;
    --color-text: #f0f0f0;
    --color-text-dim: #a0a0a0;
    --color-player: #4a9eff;
    --color-enemy: #e63946;
    --color-neutral: #888888;
    --color-health: #4caf50;
    --color-health-low: #e63946;
    --pixel-border: 3px solid #4a5a4a;
    --shadow-pixel: 4px 4px 0 rgba(0, 0, 0, 0.5);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
    -webkit-user-select: none;
    touch-action: none;
}

html, body {
    width: 100%;
    height: 100%;
    height: 100dvh;
    overflow: hidden;
    background: #000;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Microsoft YaHei", sans-serif;
    color: var(--color-text);
}

#game-container {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    /* Use safe-area insets so iOS notch/toolbar don't overlap */
    padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
    overflow: hidden;
    background: #000;
}

#game-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    image-rendering: auto;
    z-index: 1;
}

.screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: none;
    z-index: 10;
    overflow: hidden;
}

.screen.active {
    display: flex;
}

.screen-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #1a2a1a 0%, #0f1a0f 50%, #1a1a1a 100%);
    z-index: -1;
}

.pixel-grid {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 8px 8px;
    pointer-events: none;
}

.vignette {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at center, transparent 40%, rgba(0,0,0,0.6) 100%);
    pointer-events: none;
}

/* 启动页 */
.start-content {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px;
    gap: 24px;
}

.game-title {
    font-size: 48px;
    font-weight: 900;
    letter-spacing: 4px;
    color: var(--color-text);
    text-shadow:
        4px 4px 0 #000,
        -2px -2px 0 var(--color-accent);
    text-align: center;
}

.game-subtitle {
    font-size: 14px;
    color: var(--color-text-dim);
    letter-spacing: 2px;
    margin-top: -16px;
}

.section-label {
    font-size: 12px;
    color: var(--color-text-dim);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 8px;
    display: block;
    text-align: center;
}

.difficulty-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 16px 0;
}

.difficulty-selector {
    display: flex;
    border: var(--pixel-border);
    background: var(--color-primary);
    box-shadow: var(--shadow-pixel);
}

.difficulty-btn {
    padding: 12px 24px;
    background: transparent;
    border: none;
    color: var(--color-text-dim);
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.1s;
    border-right: 2px solid #3a4a3a;
}

.difficulty-btn:last-child {
    border-right: none;
}

.difficulty-btn.active {
    background: var(--color-accent);
    color: #fff;
}

.pixel-btn {
    padding: 16px 48px;
    background: var(--color-primary);
    border: var(--pixel-border);
    color: var(--color-text);
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: var(--shadow-pixel);
    transition: transform 0.1s, box-shadow 0.1s;
    text-align: center;
    min-width: 180px;
}

.pixel-btn:active {
    transform: translate(2px, 2px);
    box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.5);
}

.pixel-btn.primary {
    background: var(--color-accent);
    color: #fff;
}

.pixel-btn.primary:active {
    background: var(--color-accent-hover);
}

.pixel-btn.small {
    padding: 8px 16px;
    font-size: 14px;
    min-width: auto;
}

.pixel-btn.large {
    padding: 18px 56px;
    font-size: 20px;
}

.help-panel {
    width: 100%;
    max-width: 320px;
    margin-top: 8px;
}

.help-toggle {
    width: 100%;
    padding: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid #3a4a3a;
    color: var(--color-text-dim);
    font-size: 14px;
    cursor: pointer;
}

.help-content {
    display: none;
    padding: 16px;
    background: rgba(0, 0, 0, 0.6);
    border: 2px solid #3a4a3a;
    border-top: none;
}

.help-content.open {
    display: block;
}

.help-content ul {
    list-style: none;
    font-size: 13px;
    color: var(--color-text-dim);
    line-height: 1.8;
}

.help-content li::before {
    content: "▸ ";
    color: var(--color-accent);
}

/* 装备选择页 */
#equipment-screen {
    flex-direction: column;
    background: var(--color-bg);
}

.screen-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
    border-bottom: 2px solid #3a4a3a;
    background: var(--color-panel);
}

.screen-title {
    font-size: 20px;
    font-weight: 700;
    letter-spacing: 2px;
}

.placeholder {
    width: 60px;
}

.equipment-content {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.equipment-section {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.section-title {
    font-size: 16px;
    color: var(--color-accent);
    letter-spacing: 2px;
}

.weapon-grid, .gadget-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.equipment-card {
    padding: 16px;
    background: var(--color-panel);
    border: 2px solid #3a4a3a;
    cursor: pointer;
    transition: all 0.15s;
    position: relative;
}

.equipment-card.selected {
    border-color: var(--color-accent);
    background: rgba(255, 107, 0, 0.1);
}

.equipment-card.selected::after {
    content: "✓";
    position: absolute;
    top: 8px;
    right: 8px;
    color: var(--color-accent);
    font-weight: 700;
}

.equipment-card h4 {
    font-size: 15px;
    margin-bottom: 8px;
    color: var(--color-text);
}

.equipment-card p {
    font-size: 12px;
    color: var(--color-text-dim);
    line-height: 1.5;
}

.stat-bars {
    margin-top: 10px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.stat-bar {
    height: 6px;
    background: #2a3a2a;
    border-radius: 0;
    overflow: hidden;
}

.stat-bar-fill {
    height: 100%;
    background: var(--color-accent);
    transition: width 0.3s;
}

.equipment-footer {
    padding: 16px;
    border-top: 2px solid #3a4a3a;
    display: flex;
    justify-content: center;
    background: var(--color-panel);
}

/* HUD */
#hud {
    pointer-events: none;
    background: transparent;
}

#hud > * {
    pointer-events: auto;
}

.hud-top {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    padding: 12px 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.tickets-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(0, 0, 0, 0.6);
    border: 2px solid #3a4a3a;
    padding: 8px 12px;
}

.ticket-team {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.ticket-team.alpha .ticket-value {
    color: #4a9eff;
}

.ticket-team.bravo .ticket-value {
    color: #e63946;
}

.ticket-team.charlie .ticket-value {
    color: #4ade80;
}

.ticket-team.delta .ticket-value {
    color: #ffcc00;
}

.ticket-label {
    font-size: 10px;
    color: var(--color-text-dim);
    letter-spacing: 1px;
}

.ticket-value {
    font-size: 20px;
    font-weight: 900;
    font-family: "Courier New", monospace;
}

.match-timer {
    font-size: 18px;
    font-weight: 700;
    color: var(--color-text);
    font-family: "Courier New", monospace;
}



.score-display {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: var(--color-text-dim);
    padding: 0 8px;
}

.hud-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
}

.damage-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9;
    opacity: 0;
    transition: opacity 0.15s ease-out;
    box-shadow: inset 0 0 0 0 rgba(255, 0, 0, 0);
}

.damage-overlay.active {
    opacity: 1;
    box-shadow: inset 0 0 80px 30px rgba(255, 0, 0, 0.55);
}

.hit-direction {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    pointer-events: none;
    z-index: 9;
    opacity: 0;
    transition: opacity 0.15s ease-out;
}

.hit-direction.active {
    opacity: 1;
}

.hit-direction::before {
    content: "";
    position: absolute;
    top: -12px;
    left: -12px;
    width: 0;
    height: 0;
    border-left: 12px solid transparent;
    border-right: 12px solid transparent;
    border-bottom: 20px solid rgba(255, 0, 0, 0.85);
    transform-origin: 50% 80px;
    transform: translate(-50%, -50%) rotate(0deg);
}

.scope-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 8;
    opacity: 0;
    transition: opacity 0.15s ease-out;
    display: flex;
    align-items: center;
    justify-content: center;
}

.scope-overlay.active {
    opacity: 1;
}

.scope-vignette {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, transparent 18%, rgba(0, 0, 0, 0.85) 36%, #000 55%);
}

.scope-reticle {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 280px;
    height: 280px;
    transform: translate(-50%, -50%);
    border: 2px solid rgba(0, 255, 100, 0.7);
    border-radius: 50%;
}

.scope-cross-v,
.scope-cross-h {
    position: absolute;
    background: rgba(0, 255, 100, 0.85);
}

.scope-cross-v {
    width: 2px;
    height: 100%;
    left: 50%;
    top: 0;
    transform: translateX(-50%);
}

.scope-cross-h {
    width: 100%;
    height: 2px;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
}

.scope-mil {
    position: absolute;
    width: 10px;
    height: 2px;
    background: rgba(0, 255, 100, 0.7);
}

.scope-mil.mil-1 { top: 25%; left: 50%; transform: translateX(-50%); }
.scope-mil.mil-2 { top: 75%; left: 50%; transform: translateX(-50%); }
.scope-mil.mil-3 { top: 50%; left: 25%; transform: translateY(-50%) rotate(90deg); }
.scope-mil.mil-4 { top: 50%; left: 75%; transform: translateY(-50%) rotate(90deg); }

.scope-range {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 10px;
    color: rgba(0, 255, 100, 0.7);
    font-family: "Courier New", monospace;
    letter-spacing: 1px;
}

body.aiming .crosshair .ch-line {
    opacity: 0.25;
}

body.aiming.sniper-aim .crosshair {
    opacity: 0;
}

.crosshair {
    width: 48px;
    height: 48px;
    position: relative;
    --ch-gap: 8px;
}

/* Center dot */
.ch-dot {
    position: absolute;
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.7);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.9), 0 0 4px rgba(255, 160, 30, 0.6);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
}

/* Four thin lines radiating from center based on --ch-gap */
.ch-line {
    position: absolute;
    background: rgba(255, 255, 255, 0.85);
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.5);
    z-index: 1;
}
.ch-top {
    width: 1px; height: 8px;
    left: 50%; bottom: calc(50% + var(--ch-gap));
    transform: translateX(-50%);
}
.ch-bottom {
    width: 1px; height: 8px;
    left: 50%; top: calc(50% + var(--ch-gap));
    transform: translateX(-50%);
}
.ch-left {
    width: 8px; height: 1px;
    top: 50%; right: calc(50% + var(--ch-gap));
    transform: translateY(-50%);
}
.ch-right {
    width: 8px; height: 1px;
    top: 50%; left: calc(50% + var(--ch-gap));
    transform: translateY(-50%);
}

.hit-marker {
    position: absolute;
    width: 32px;
    height: 32px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    opacity: 0;
    pointer-events: none;
}

.hit-marker.active {
    animation: hitMarker 0.2s ease-out;
}

.hit-marker::before,
.hit-marker::after {
    content: "";
    position: absolute;
    width: 12px;
    height: 2px;
    background: var(--color-accent);
    top: 50%;
    left: 50%;
}

.hit-marker::before {
    transform: translate(-50%, -50%) rotate(45deg);
}

.hit-marker::after {
    transform: translate(-50%, -50%) rotate(-45deg);
}

@keyframes hitMarker {
    0% { opacity: 1; transform: translate(-50%, -50%) scale(0.5); }
    50% { opacity: 1; transform: translate(-50%, -50%) scale(1.2); }
    100% { opacity: 0; transform: translate(-50%, -50%) scale(1); }
}

.capture-notice {
    position: absolute;
    top: -60px;
    left: 50%;
    transform: translateX(-50%);
    white-space: nowrap;
    font-size: 14px;
    font-weight: 700;
    color: var(--color-accent);
    text-shadow: 2px 2px 0 #000;
    opacity: 0;
    transition: opacity 0.3s;
}

.capture-notice.active {
    opacity: 1;
}

.hud-bottom {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 16px;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    pointer-events: none;
}

.health-ammo {
    position: absolute;
    bottom: 8px;
    left: 180px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    pointer-events: auto;
    z-index: 5;
}

@media (max-width: 640px) {
    .health-ammo {
        left: 50%;
        bottom: 8px;
        transform: translateX(-50%) scale(0.85);
        transform-origin: center bottom;
    }
}

.health-bar {
    width: 180px;
    height: 28px;
    background: rgba(0, 0, 0, 0.6);
    border: 2px solid #3a4a3a;
    position: relative;
    overflow: hidden;
}

.health-fill {
    height: 100%;
    width: 100%;
    background: var(--color-health);
    transition: width 0.2s, background 0.2s;
}

.health-fill.low {
    background: var(--color-health-low);
    animation: pulse 0.5s infinite alternate;
}

@keyframes pulse {
    from { opacity: 1; }
    to { opacity: 0.6; }
}

.health-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    text-shadow: 1px 1px 0 #000;
    font-family: "Courier New", monospace;
}

.weapon-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.weapon-name {
    font-size: 15px;
    color: var(--color-text);
    font-weight: 700;
}

.ammo-text {
    font-size: 20px;
    color: var(--color-text);
    font-family: "Courier New", monospace;
    font-weight: 700;
}

.ammo-text.reloading {
    color: var(--color-accent);
}

.minimap {
    position: absolute;
    top: 80px;
    right: 16px;
    width: 100px;
    height: 100px;
    background: rgba(0, 0, 0, 0.25);
    border: 2px solid rgba(58, 74, 58, 0.6);
    border-radius: 50%;
    overflow: hidden;
    pointer-events: auto;
}

#minimap-canvas {
    width: 100%;
    height: 100%;
}

/* 虚拟摇杆 */
.joystick-area {
    position: absolute;
    bottom: 24px;
    left: 24px;
    width: 140px;
    height: 140px;
    pointer-events: auto;
}

.joystick-base {
    position: absolute;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.3);
    bottom: 0;
    left: 0;
}

.joystick-thumb {
    position: absolute;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.4);
    border: 2px solid rgba(255, 255, 255, 0.6);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    transition: transform 0.05s;
}

/* 操作按钮 - PUBG/CoD Mobile 风格布局 */
.action-buttons {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 300px;
    height: 300px;
    pointer-events: none;
}

.action-buttons > * {
    pointer-events: auto;
}

.right-pad {
    position: absolute;
    top: 12px;
    right: 12px;
    display: flex;
    flex-direction: row;
    gap: 10px;
}

.action-btn {
    width: 72px;
    height: 60px;
    background: rgba(0, 0, 0, 0.35);
    border: 2px solid rgba(255, 255, 255, 0.35);
    color: var(--color-text);
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    border-radius: 14px;
    transition: all 0.1s;
    backdrop-filter: blur(2px);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    line-height: 1.1;
    padding: 2px;
}

@media (max-width: 640px) {
    .action-btn {
        width: 62px;
        height: 54px;
        font-size: 12px;
    }
}

.action-btn:active,
.action-btn.active {
    background: rgba(255, 107, 0, 0.5);
    transform: scale(0.95);
}

.action-btn.jump {
    position: absolute;
    right: 28px;
    bottom: 156px;
    background: rgba(0, 0, 0, 0.35);
    border-color: rgba(255, 255, 255, 0.35);
}

.fire-btn {
    position: absolute;
    right: 16px;
    bottom: 16px;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 107, 0, 0.7) 0%, rgba(204, 85, 0, 0.85) 100%);
    border: 4px solid rgba(255, 255, 255, 0.35);
    cursor: pointer;
    box-shadow: 0 5px 0 rgba(120, 50, 0, 0.6);
    transition: transform 0.05s;
}

.aim-btn {
    position: absolute;
    right: 152px;
    bottom: 36px;
    width: 82px;
    height: 82px;
    border-radius: 50%;
    background: rgba(0, 180, 255, 0.2);
    border: 3px solid rgba(100, 210, 255, 0.5);
    color: var(--color-text);
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.1s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.aim-btn:active,
.aim-btn.active,
body.aiming .aim-btn {
    background: rgba(0, 180, 255, 0.5);
    box-shadow: 0 0 12px rgba(0, 180, 255, 0.5);
    transform: scale(0.95);
}

@media (max-width: 640px) {
    .action-buttons {
        width: 260px;
        height: 260px;
    }

    .fire-btn {
        width: 100px;
        height: 100px;
    }

    .aim-btn {
        right: 130px;
        bottom: 30px;
        width: 72px;
        height: 72px;
        font-size: 14px;
    }

    .action-btn.jump {
        right: 22px;
        bottom: 132px;
    }

    .right-pad {
        top: 8px;
        right: 8px;
        gap: 6px;
    }

    .action-btn {
        width: 60px;
    }
}

.fire-btn:active {
    transform: scale(0.92);
    box-shadow: 0 3px 0 rgba(120, 50, 0, 0.6);
}

/* Sprint / ADS indicator for desktop HUD */
.health-ammo::after {
    content: "冲刺中";
    position: absolute;
    top: -22px;
    left: 0;
    font-size: 12px;
    font-weight: 700;
    color: #4a9eff;
    text-shadow: 1px 1px 0 #000;
    opacity: 0;
    transition: opacity 0.15s;
    pointer-events: none;
}

body.sprinting .health-ammo::after {
    opacity: 1;
}

body.aiming .health-ammo::after {
    content: "瞄准中";
    color: #4adfff;
    opacity: 1;
}

/* 复活界面 */
#respawn-screen {
    align-items: center;
    justify-content: center;
}

.respawn-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
}

.respawn-content {
    position: relative;
    z-index: 1;
    text-align: center;
    padding: 24px;
    width: 100%;
    max-width: 360px;
}

.respawn-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 16px;
    letter-spacing: 2px;
}

.respawn-timer {
    font-size: 64px;
    font-weight: 900;
    color: var(--color-accent);
    font-family: "Courier New", monospace;
    margin-bottom: 8px;
}

.respawn-tip {
    font-size: 14px;
    color: var(--color-text-dim);
    margin-bottom: 24px;
}

.respawn-points {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.respawn-point-btn {
    padding: 16px;
    background: var(--color-panel);
    border: 2px solid #3a4a3a;
    color: var(--color-text);
    font-size: 14px;
    cursor: pointer;
    text-align: left;
    transition: all 0.15s;
}

.respawn-point-btn:hover,
.respawn-point-btn:active {
    border-color: var(--color-accent);
    background: rgba(255, 107, 0, 0.1);
}

/* 结算页 */
#gameover-screen {
    align-items: center;
    justify-content: center;
}

.gameover-content {
    position: relative;
    z-index: 1;
    text-align: center;
    padding: 32px;
    width: 100%;
    max-width: 320px;
    background: var(--color-panel);
    border: var(--pixel-border);
    box-shadow: var(--shadow-pixel);
}

.gameover-title {
    font-size: 32px;
    font-weight: 900;
    margin-bottom: 24px;
    letter-spacing: 2px;
}

.gameover-title.win {
    color: var(--color-player);
}

.gameover-title.lose {
    color: var(--color-enemy);
}

.gameover-title.draw {
    color: var(--color-text-dim);
}

.gameover-stats {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 24px;
}

.stat-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #3a4a3a;
}

.stat-label {
    font-size: 14px;
    color: var(--color-text-dim);
}

.stat-value {
    font-size: 16px;
    font-weight: 700;
    color: var(--color-text);
    font-family: "Courier New", monospace;
}

/* 横屏提示 */
#orientation-warning {
    background: #000;
    align-items: center;
    justify-content: center;
    z-index: 100;
}

.orientation-content {
    text-align: center;
    color: var(--color-text);
}

.orientation-content p {
    font-size: 18px;
    margin: 8px 0;
}

/* 通用 */
.hidden {
    display: none !important;
}

/* 桌面模式：隐藏移动端控件 */
.desktop-mode .joystick-area,
.desktop-mode .action-buttons {
    display: none !important;
}

.desktop-mode .health-ammo {
    left: 24px;
    bottom: 24px;
}

.pointer-lock-hint {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.7);
    color: var(--color-text);
    padding: 12px 20px;
    border: 2px solid var(--color-accent);
    border-radius: 8px;
    font-size: 14px;
    font-weight: 700;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s;
    z-index: 20;
    text-align: center;
    white-space: nowrap;
}

/* 响应式：竖屏时提示旋转 */
@media (orientation: portrait) {
    #game-container {
        display: none;
    }

    #orientation-warning {
        display: flex !important;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
    }
}

@media (min-width: 400px) {
    .game-title {
        font-size: 56px;
    }

    .weapon-grid, .gadget-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
