:root {
    --bg: #050510;
    --accent: #2ecc71; /* Tactical Green */
    --accent-blue: #00d2ff;
    --accent-gold: #ffcc00;
    --accent-red: #ff4d4d;
    --text: #ffffff;
    --glass: rgba(255, 255, 255, 0.05);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Rajdhani', sans-serif;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

body {
    background-color: var(--bg);
    overflow: hidden;
    width: 100vw;
    height: 100vh;
}

#game-container {
    position: relative;
    width: 100%;
    height: 100%;
}

/* --- Responsive HUD --- */
#hud {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    padding: 30px;
}

.hud-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.team-info {
    font-size: 1rem;
    font-weight: 900;
    letter-spacing: 2px;
}

.team-info.blue { color: var(--accent-blue); text-shadow: 0 0 10px var(--accent-blue); }
.team-info.red { color: var(--accent-red); text-shadow: 0 0 10px var(--accent-red); }

.match-timer {
    text-align: center;
}

#timer {
    font-size: 2rem;
    font-weight: 900;
    font-family: 'Orbitron', sans-serif;
    color: var(--accent-gold);
    background: rgba(0,0,0,0.5);
    padding: 5px 20px;
    border-radius: 40px;
    border: 1px solid var(--accent-gold);
}

.objective { font-size: 0.7rem; font-weight: 700; opacity: 0.7; color: white; margin-top: 5px; letter-spacing: 2px; }

/* --- Tactical Crosshair --- */
#crosshair {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 40px;
    height: 40px;
    transform: translate(-50%, -50%);
    z-index: 10;
}

#crosshair .dot {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 4px;
    height: 4px;
    background: white;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    box-shadow: 0 0 5px white;
}

#crosshair .line { position: absolute; background: white; border-radius: 2px; opacity: 0.8; }
#crosshair .line.top { top: -10px; left: 50%; width: 2px; height: 10px; transform: translateX(-50%); }
#crosshair .line.bottom { bottom: -10px; left: 50%; width: 2px; height: 10px; transform: translateX(-50%); }
#crosshair .line.left { left: -10px; top: 50%; width: 10px; height: 2px; transform: translateY(-50%); }
#crosshair .line.right { right: -10px; top: 50%; width: 10px; height: 2px; transform: translateY(-50%); }

/* --- Mobile Specific UI --- */
#mobile-ui {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

#joystick-container {
    position: absolute;
    bottom: 80px;
    left: 80px;
    pointer-events: auto;
}

#joystick-base {
    width: 120px;
    height: 120px;
    background: rgba(255,255,255,0.1);
    border: 2px solid rgba(255,255,255,0.3);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    backdrop-filter: blur(5px);
}

#joystick-stick {
    width: 60px;
    height: 60px;
    background: var(--accent-blue);
    border-radius: 50%;
    box-shadow: 0 0 15px var(--accent-blue);
}

#mobile-buttons {
    position: absolute;
    bottom: 80px;
    right: 80px;
    pointer-events: auto;
    display: grid;
    grid-template-columns: repeat(2, 70px);
    gap: 20px;
}

.m-btn {
    width: 70px;
    height: 70px;
    background: rgba(0,0,0,0.6);
    border: 2px solid var(--accent-blue);
    border-radius: 50%;
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.5rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.5);
    transition: transform 0.1s;
}

.m-btn:active { transform: scale(0.9); background: var(--accent-blue); color: black; }
.btn-shoot { width: 100px; height: 100px; transform: translate(-15px, -15px); font-size: 2.5rem; background: rgba(255,50,50,0.3); border-color: var(--accent-red); }

/* --- Bottom Stats --- */
.hud-bottom {
    position: absolute;
    bottom: 40px;
    left: 40px;
    right: 40px;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}

.player-left { width: 300px; padding: 20px; background: rgba(0,0,0,0.5); border-left: 5px solid var(--accent); backdrop-filter: blur(10px); transform: skewX(-15deg); }
.hp-label { font-size: 1.2rem; font-weight: 900; color: var(--accent); letter-spacing: 2px; }
.hp-bar-container { width: 100%; height: 25px; background: rgba(255,255,255,0.1); border: 1px solid rgba(255,255,255,0.3); margin: 5px 0; overflow: hidden; }
#hp-bar-fill { width: 100%; height: 100%; background: linear-gradient(90deg, #fff, var(--accent)); transition: width 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275); }
.hp-value { font-size: 1.5rem; font-weight: 900; color: white; text-align: right; }

.player-right { text-align: right; width: 300px; padding: 20px; background: rgba(0,0,0,0.5); border-right: 5px solid white; backdrop-filter: blur(10px); transform: skewX(15deg); }
.weapon-name { font-size: 1.2rem; font-weight: 700; letter-spacing: 2px; }
.ammo-display { font-size: 4rem; font-weight: 900; font-family: 'Orbitron', sans-serif; margin-top: -10px; }
.ammo-slash { font-size: 1.5rem; opacity: 0.3; margin: 0 10px; }
.gadget-info { font-size: 1rem; font-weight: 700; color: var(--accent-gold); letter-spacing: 2px; }

/* --- Overlays --- */
.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, transparent 20%, rgba(0,0,0,0.95) 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.glass-box {
    background: rgba(20,20,30,0.85);
    backdrop-filter: blur(20px);
    padding: 60px;
    border: 2px solid rgba(255,255,255,0.1);
    border-radius: 10px;
    text-align: center;
    max-width: 600px;
}

.logo { font-size: 5rem; font-weight: 900; color: white; letter-spacing: 5px; }
.logo .mobile { color: var(--accent-blue); font-size: 4rem; display: block; margin-top: -15px; }

#start-btn { margin-top: 40px; padding: 20px 60px; background: var(--accent-blue); border: none; font-size: 1.5rem; font-weight: 900; cursor: pointer; clip-path: polygon(10% 0%, 100% 0%, 90% 100%, 0% 100%); transition: all 0.2s; }
#start-btn:hover { background: #0088cc; transform: scale(1.05); box-shadow: 0 0 30px var(--accent-blue); }

.hidden { display: none !important; }

/* --- Visual Effects --- */
#hit-marker { position: absolute; top: 50%; left: 50%; width: 20px; height: 20px; transform: translate(-50%, -50%) rotate(45deg); pointer-events: none; border: 2px solid white; border-top: 0; border-left: 0; }
#damage-vignette { position: absolute; top:0; left:0; width: 100%; height: 100%; pointer-events: none; box-shadow: inset 0 0 100px rgba(255,0,0,0); transition: box-shadow 0.2s; }

.class-card.active {
    border: 2px solid white !important;
    background: rgba(0, 210, 255, 0.2) !important;
    transform: scale(1.05);
    box-shadow: 0 0 20px var(--accent-blue);
}

.mode-toggle input {
    width: 20px;
    height: 20px;
    vertical-align: middle;
    margin-right: 10px;
}
