/* Shared game styles for all game modes */

body {
    overflow: hidden;
}

/* Select/Dropdown styling for dark theme */
select {
    background-color: #1a1a2e !important;
    color: white !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
}

select option {
    background-color: #1a1a2e;
    color: white;
    padding: 10px;
}

select option:hover,
select option:focus,
select option:checked {
    background-color: #2a2a4e;
    color: white;
}

#gameContainer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* HUD Container */
#hud {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding: 20px;
    box-sizing: border-box;
    pointer-events: none;
    z-index: 100;
}

/* Player Info Cards */
.player-info {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 15px 20px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 10px;
    backdrop-filter: blur(10px);
    min-width: 180px;
    max-width: 280px;
    box-sizing: border-box;
}

.player-info.self,
.player-info.ai1 {
    position: absolute;
    bottom: 20px;
    left: 20px;
    border: 2px solid #4ade80;
}

.player-info.opponent,
.player-info.ai2 {
    position: absolute;
    top: 20px;
    right: 20px;
    border: 2px solid #ef4444;
}

/* For AI battle, both at top */
.player-info.ai1.top {
    position: absolute;
    top: 20px;
    left: 20px;
    bottom: auto;
}

.player-label {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Lives Display */
.lives {
    display: flex;
    gap: 5px;
}

.life {
    width: 24px;
    height: 24px;
    background: #ef4444;
    border-radius: 50%;
    transition: all 0.3s;
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.5);
}

.life.lost {
    opacity: 0.2;
    box-shadow: none;
}

/* Ammo Display */
.ammo-container {
    margin-top: 5px;
}

.ammo-bar {
    display: flex;
    gap: 3px;
    height: 8px;
}

.ammo-bullet {
    flex: 1;
    background: #fbbf24;
    border-radius: 2px;
    transition: all 0.2s;
}

.ammo-bullet.empty {
    background: rgba(255, 255, 255, 0.2);
}

.reload-text {
    color: #fbbf24;
    font-size: 12px;
    margin-top: 5px;
    animation: pulse 0.5s ease-in-out infinite;
}

/* Weapon Selector */
.weapon-selector {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    pointer-events: none;
    z-index: 100;
}

.weapon-slot {
    position: relative;
    width: 70px;
    height: 70px;
    background: rgba(0, 0, 0, 0.7);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    backdrop-filter: blur(10px);
    flex-shrink: 0;
}

.weapon-slot.active {
    border-color: #fbbf24;
    background: rgba(251, 191, 36, 0.2);
    transform: scale(1.1);
}

.weapon-slot .weapon-key {
    font-size: 10px;
    color: rgba(255, 255, 255, 0.5);
    position: absolute;
    top: 4px;
    left: 6px;
}

.weapon-slot .weapon-icon {
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #a5b4fc;
}
.weapon-slot .weapon-icon svg {
    width: 100%;
    height: 100%;
}
.weapon-slot.active .weapon-icon {
    color: #fbbf24;
}

.weapon-slot .weapon-name {
    font-size: 8px;
    color: rgba(255, 255, 255, 0.7);
    margin-top: 2px;
    text-transform: uppercase;
    white-space: nowrap;
}

/* Current Weapon Display */
.current-weapon {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 5px;
    padding-bottom: 5px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.current-weapon .weapon-icon {
    width: 18px;
    height: 18px;
    color: #fbbf24;
}
.current-weapon .weapon-icon svg {
    width: 100%;
    height: 100%;
}

.current-weapon .weapon-name {
    font-size: 12px;
    color: #fbbf24;
    font-weight: bold;
    text-transform: uppercase;
}

/* Ammo Counter (numeric) */
.ammo-counter {
    font-size: 14px;
    color: #fbbf24;
    font-family: monospace;
    margin-top: 3px;
}

.ammo-counter.low {
    color: #ef4444;
    animation: pulse 0.5s ease-in-out infinite;
}

/* Mode Label */
#modeLabel {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(234, 179, 8, 0.9);
    padding: 10px 30px;
    border-radius: 25px;
    font-size: 16px;
    font-weight: bold;
    color: #000;
    backdrop-filter: blur(10px);
}

#modeLabel.practice {
    background: rgba(59, 130, 246, 0.9);
    color: #fff;
}

#modeLabel.multiplayer {
    background: rgba(139, 92, 246, 0.9);
    color: #fff;
}

/* Timer */
#timer {
    position: absolute;
    top: 70px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.7);
    padding: 8px 20px;
    border-radius: 20px;
    font-size: 24px;
    font-weight: bold;
    color: #fff;
    font-family: monospace;
    backdrop-filter: blur(10px);
}

#timer.warning {
    color: #fbbf24;
    animation: pulse 1s ease-in-out infinite;
}

#timer.critical {
    color: #ef4444;
    animation: pulse 0.5s ease-in-out infinite;
}

/* Crosshair */
#crosshair {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    z-index: 100;
}

#crosshair .dot {
    width: 4px;
    height: 4px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

#crosshair .line {
    position: absolute;
    background: rgba(255, 255, 255, 0.7);
}

#crosshair .line.top {
    width: 2px;
    height: 10px;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
}

#crosshair .line.bottom {
    width: 2px;
    height: 10px;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
}

#crosshair .line.left {
    width: 10px;
    height: 2px;
    left: -15px;
    top: 50%;
    transform: translateY(-50%);
}

#crosshair .line.right {
    width: 10px;
    height: 2px;
    right: -15px;
    top: 50%;
    transform: translateY(-50%);
}

/* Instructions */
#instructions {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.7);
    padding: 15px 20px;
    border-radius: 10px;
    font-size: 13px;
    pointer-events: none;
    backdrop-filter: blur(10px);
}

#instructions p {
    margin: 5px 0;
    color: rgba(255, 255, 255, 0.8);
}

#instructions span {
    color: #4ade80;
    font-weight: bold;
}

/* Kill Feed */
#killFeed {
    position: fixed;
    top: 120px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 5px;
    pointer-events: auto;
    z-index: 100;
    max-height: 180px;
    overflow-y: auto;
    overflow-x: hidden;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,0.3) transparent;
}

#killFeed::-webkit-scrollbar {
    width: 4px;
}

#killFeed::-webkit-scrollbar-track {
    background: transparent;
}

#killFeed::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.3);
    border-radius: 2px;
}

#killFeed.center {
    right: auto;
    left: 50%;
    transform: translateX(-50%);
    align-items: center;
}

.kill-entry {
    background: rgba(0, 0, 0, 0.7);
    padding: 8px 15px;
    border-radius: 5px;
    font-size: 14px;
    animation: slideIn 0.3s ease-out;
    backdrop-filter: blur(5px);
    flex-shrink: 0;
}

.kill-entry .killer {
    color: #4ade80;
}

.kill-entry .victim {
    color: #ef4444;
}

/* Damage Flash */
#damageFlash {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 50;
    background: radial-gradient(ellipse at center, transparent 0%, rgba(239, 68, 68, 0.3) 100%);
    opacity: 0;
    transition: opacity 0.1s;
}

/* Overlays */
.game-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 1);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 200;
}

.overlay-content {
    text-align: center;
    padding: 40px;
}

/* Reconnection Overlay */
.reconnect-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(255, 255, 255, 0.2);
    border-top-color: #4ade80;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.reconnect-countdown {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.6);
    margin-top: 15px;
}

.opponent-disconnected {
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid rgba(239, 68, 68, 0.5);
    padding: 10px 20px;
    border-radius: 8px;
    margin-top: 20px;
}

/* Stats Panel (for AI battle) */
#stats {
    position: absolute;
    bottom: 20px;
    left: 20px;
    background: rgba(0, 0, 0, 0.7);
    padding: 15px 20px;
    border-radius: 10px;
    backdrop-filter: blur(10px);
}

#stats div {
    margin: 5px 0;
}

/* Camera Controls (for spectator/AI battle) */
#cameraControls {
    position: absolute;
    bottom: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.7);
    padding: 15px 20px;
    border-radius: 10px;
    pointer-events: auto;
    backdrop-filter: blur(10px);
}

#cameraControls button {
    padding: 8px 15px;
    margin: 0 5px;
    background: #4a4a6a;
    border: none;
    border-radius: 5px;
    color: white;
    cursor: pointer;
    transition: all 0.2s;
}

#cameraControls button:hover {
    background: #5a5a7a;
}

#cameraControls button.active {
    background: #eab308;
    color: #000;
}

#cameraHelp {
    position: absolute;
    bottom: 80px;
    right: 20px;
    background: rgba(0, 0, 0, 0.7);
    padding: 10px 15px;
    border-radius: 10px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.7);
    pointer-events: none;
    backdrop-filter: blur(10px);
}

#cameraHelp kbd {
    background: rgba(255, 255, 255, 0.2);
    padding: 2px 6px;
    border-radius: 3px;
    font-family: monospace;
}

/* Loading Spinner */
.loading-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(234, 179, 8, 0.3);
    border-top-color: #eab308;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    vertical-align: middle;
    margin-right: 8px;
}

/* Animations */
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInCenter {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Button States */
.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ===== GAME MODE SPECIFIC UI ===== */

/* Team Score Display */
.team-score-display {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 10px 25px;
    background: rgba(0, 0, 0, 0.8);
    border-radius: 10px;
    font-size: 24px;
    font-weight: bold;
    z-index: 100;
}

.team-score {
    display: flex;
    align-items: center;
    gap: 10px;
}

.team-score.red-team {
    color: #ef4444;
}

.team-score.blue-team {
    color: #3b82f6;
}

.team-label {
    font-size: 14px;
    text-transform: uppercase;
    opacity: 0.8;
}

.team-score-value {
    font-size: 32px;
    min-width: 40px;
    text-align: center;
}

.score-divider {
    color: #888;
    font-size: 28px;
}

/* Control Point UI (King of the Hill) */
.control-point-ui {
    position: fixed;
    top: 80px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    z-index: 100;
}

.capture-bar-container {
    width: 300px;
    height: 20px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 10px;
    overflow: hidden;
    display: flex;
    position: relative;
}

.capture-bar {
    height: 100%;
    transition: width 0.2s ease;
}

.capture-bar.red {
    background: linear-gradient(90deg, #ef4444, #dc2626);
    position: absolute;
    left: 0;
}

.capture-bar.blue {
    background: linear-gradient(90deg, #2563eb, #3b82f6);
    position: absolute;
    right: 0;
}

.control-status {
    font-size: 14px;
    font-weight: bold;
    text-transform: uppercase;
    color: #888;
    padding: 5px 15px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 5px;
}

.control-status.red {
    color: #ef4444;
}

.control-status.blue {
    color: #3b82f6;
}

.control-status.contested {
    color: #fbbf24;
    animation: pulse 0.5s ease-in-out infinite;
}

/* Zombie Survival UI */
.zombie-ui {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 30px;
    padding: 10px 25px;
    background: rgba(0, 0, 0, 0.8);
    border-radius: 10px;
    z-index: 100;
}

.wave-info, .enemies-info, .zombie-score {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.wave-label, .enemies-label, .score-label {
    font-size: 12px;
    color: #888;
    text-transform: uppercase;
}

.wave-number {
    font-size: 32px;
    font-weight: bold;
    color: #fbbf24;
}

.enemies-count {
    font-size: 28px;
    font-weight: bold;
    color: #ef4444;
}

.score-value {
    font-size: 28px;
    font-weight: bold;
    color: #4ade80;
}

.zombie-lives {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.lives-label {
    font-size: 12px;
    color: #888;
    text-transform: uppercase;
}

.lives-value {
    font-size: 28px;
    font-weight: bold;
    color: #ef4444;
}

.lives-value.critical {
    color: #ff0000;
    animation: pulse 0.5s ease-in-out infinite;
}

/* Power-up effects display */
.powerup-effects {
    display: flex;
    gap: 8px;
    margin-left: 20px;
    padding-left: 20px;
    border-left: 1px solid rgba(255, 255, 255, 0.2);
}

.powerup-effect {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 4px 8px;
    border-radius: 4px;
    background: rgba(0, 0, 0, 0.5);
    min-width: 50px;
}

.powerup-effect.speed {
    border: 2px solid #3B82F6;
    box-shadow: 0 0 10px rgba(59, 130, 246, 0.5);
}

.powerup-effect.damage {
    border: 2px solid #EF4444;
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.5);
}

.powerup-effect-icon {
    font-size: 18px;
}

.powerup-effect-timer {
    font-size: 12px;
    font-weight: bold;
    color: #fff;
}

.powerup-shield {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 4px 8px;
    border-radius: 4px;
    background: rgba(168, 85, 247, 0.3);
    border: 2px solid #A855F7;
}

.powerup-shield-icon {
    font-size: 18px;
}

.powerup-shield-value {
    font-size: 14px;
    font-weight: bold;
    color: #A855F7;
}

/* Ability text states */
.ability-text.active {
    color: #fbbf24;
    font-weight: bold;
    animation: pulse 0.5s ease-in-out infinite;
}

/* Upgrade Selection Overlay */
.upgrade-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 200;
    pointer-events: auto;
}

.upgrade-content {
    text-align: center;
    max-width: 800px;
}

.upgrade-content h2 {
    font-size: 36px;
    margin-bottom: 10px;
    color: #fbbf24;
}

.upgrade-timer {
    font-size: 48px;
    font-weight: bold;
    color: #ef4444;
    margin-bottom: 30px;
}

.upgrade-options {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

.upgrade-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 20px 30px;
    background: rgba(74, 222, 128, 0.2);
    border: 2px solid #4ade80;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s;
    min-width: 180px;
}

.upgrade-btn:hover {
    background: rgba(74, 222, 128, 0.4);
    transform: scale(1.05);
}

.upgrade-name {
    font-size: 18px;
    font-weight: bold;
    color: #4ade80;
}

.upgrade-desc {
    font-size: 14px;
    color: #ccc;
}

/* Respawn Timer */
.respawn-timer {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    padding: 40px 60px;
    background: rgba(0, 0, 0, 0.9);
    border-radius: 15px;
    z-index: 150;
    border: 2px solid rgba(239, 68, 68, 0.5);
    box-shadow: 0 0 30px rgba(239, 68, 68, 0.3);
}

.respawn-death-message {
    font-size: 32px;
    font-weight: bold;
    color: #ef4444;
    text-shadow: 0 0 10px rgba(239, 68, 68, 0.5);
    animation: deathPulse 1s ease-in-out infinite;
}

@keyframes deathPulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.8; transform: scale(1.02); }
}

.respawn-countdown-container {
    display: flex;
    align-items: center;
    gap: 8px;
}

.respawn-text {
    font-size: 18px;
    color: #888;
}

.respawn-countdown {
    font-size: 48px;
    font-weight: bold;
    color: #fbbf24;
    text-shadow: 0 0 10px rgba(251, 191, 36, 0.5);
    min-width: 50px;
    text-align: center;
}

/* Team Indicator on Player Names */
.player-label.team-red {
    color: #ef4444;
}

.player-label.team-blue {
    color: #3b82f6;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* ===== MOBILE CONTROLS ===== */

#mobileControls {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 150;
    display: none;
}

/* Show on mobile */
@media (pointer: coarse), (max-width: 1024px) {
    #mobileControls {
        display: block;
    }
}

/* Joystick Area (left side) */
.mobile-joystick-area {
    position: absolute;
    left: 0;
    bottom: 0;
    width: 40%;
    height: 50%;
    pointer-events: auto;
}

.joystick-base {
    position: absolute;
    width: 120px;
    height: 120px;
    background: rgba(255, 255, 255, 0.15);
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    left: 30px;
    bottom: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.7;
    transition: opacity 0.2s;
}

.joystick-knob {
    width: 50px;
    height: 50px;
    background: rgba(74, 222, 128, 0.8);
    border-radius: 50%;
    transition: transform 0.05s;
    box-shadow: 0 0 15px rgba(74, 222, 128, 0.5);
}

/* Look Area (right side, invisible) */
.mobile-look-area {
    position: absolute;
    right: 0;
    top: 0;
    width: 60%;
    height: 60%;
    pointer-events: auto;
}

/* Action Buttons (right side) */
.mobile-action-buttons {
    position: absolute;
    right: 20px;
    bottom: 20px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    pointer-events: auto;
}

.mobile-btn {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.6);
    border: 3px solid rgba(255, 255, 255, 0.3);
    color: white;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.1s;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}

.mobile-btn .btn-icon {
    font-size: 24px;
    line-height: 1;
}

.mobile-btn .btn-label {
    font-size: 10px;
    margin-top: 2px;
    opacity: 0.7;
}

.mobile-btn:active,
.mobile-btn.active {
    background: rgba(74, 222, 128, 0.4);
    border-color: #4ade80;
    transform: scale(0.95);
}

/* Shoot button special styling */
.shoot-btn {
    width: 90px;
    height: 90px;
    background: rgba(239, 68, 68, 0.4);
    border-color: #ef4444;
}

.shoot-btn:active,
.shoot-btn.active {
    background: rgba(239, 68, 68, 0.7);
}

.shoot-btn .ammo-indicator {
    position: absolute;
    bottom: -25px;
    font-size: 14px;
    font-weight: bold;
    color: white;
}

.shoot-btn .ammo-indicator.low {
    color: #ef4444;
}

/* Ability Buttons (left of action buttons) */
.mobile-ability-buttons {
    position: absolute;
    right: 110px;
    bottom: 100px;
    display: flex;
    gap: 10px;
    pointer-events: auto;
}

.ability-btn {
    width: 60px;
    height: 60px;
}

.dodge-btn {
    background: rgba(59, 130, 246, 0.4);
    border-color: #3b82f6;
}

.grenade-btn {
    background: rgba(251, 191, 36, 0.4);
    border-color: #fbbf24;
}

.ultimate-btn {
    background: rgba(168, 85, 247, 0.4);
    border-color: #a855f7;
}

/* Weapon Switch Buttons */
.mobile-weapon-buttons {
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: auto;
}

.weapon-btn {
    width: 50px;
    height: 50px;
    font-size: 18px;
    font-weight: bold;
}

.weapon-btn.active {
    background: rgba(74, 222, 128, 0.4);
    border-color: #4ade80;
}

/* Cooldown overlay */
.mobile-btn.on-cooldown::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--cooldown, 0%);
    background: rgba(0, 0, 0, 0.6);
    border-radius: 50%;
    pointer-events: none;
}

/* Reload button special */
.reload-btn {
    width: 60px;
    height: 60px;
}

/* Jump button */
.jump-btn {
    width: 60px;
    height: 60px;
    background: rgba(74, 222, 128, 0.3);
    border-color: #4ade80;
}

/* Mobile HUD adjustments */
@media (pointer: coarse), (max-width: 1024px) {
    .player-info.self {
        bottom: auto;
        top: 80px;
        left: 10px;
        transform: scale(0.85);
        transform-origin: top left;
    }

    .player-info.opponent {
        top: 80px;
        right: 10px;
        transform: scale(0.85);
        transform-origin: top right;
    }

    #timer {
        top: 10px;
    }

    #killFeed {
        font-size: 12px;
        max-width: 200px;
    }
}

/* Landscape mobile optimization */
@media (max-height: 500px) and (pointer: coarse) {
    .mobile-btn {
        width: 55px;
        height: 55px;
    }

    .shoot-btn {
        width: 70px;
        height: 70px;
    }

    .ability-btn {
        width: 50px;
        height: 50px;
    }

    .joystick-base {
        width: 100px;
        height: 100px;
    }

    .joystick-knob {
        width: 40px;
        height: 40px;
    }
}

/* =====================================================
   LOBBY UI STYLES
   ===================================================== */

.lobby-container {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 30px;
    min-width: 500px;
    max-width: 700px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.lobby-header {
    text-align: center;
    margin-bottom: 20px;
}

.lobby-header h2 {
    margin: 0 0 15px 0;
    font-size: 24px;
}

.room-code-display {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.1);
    padding: 10px 20px;
    border-radius: 10px;
    font-size: 18px;
}

.room-code-display strong {
    font-family: monospace;
    font-size: 24px;
    letter-spacing: 2px;
    color: #fbbf24;
}

.copy-code-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 18px;
    padding: 5px;
    border-radius: 5px;
    transition: background 0.2s;
}

.copy-code-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.lobby-mode-info {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 25px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
}

.lobby-mode-info span {
    background: rgba(255, 255, 255, 0.1);
    padding: 5px 15px;
    border-radius: 15px;
}

#lobbyGameMode {
    color: #8b5cf6;
    font-weight: bold;
}

/* Team-based lobby view */
.lobby-teams {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 25px;
    min-height: 150px;
}

.teams-container {
    display: flex;
    gap: 15px;
    align-items: stretch;
}

.teams-vs {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: bold;
    color: rgba(255, 255, 255, 0.6);
    padding: 0 10px;
}

.lobby-team {
    flex: 1;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 15px;
    padding: 20px;
    min-height: 120px;
}

.lobby-team h3 {
    margin: 0 0 15px 0;
    font-size: 16px;
    text-align: center;
}

.lobby-team.team-red {
    border: 2px solid rgba(239, 68, 68, 0.5);
}

.lobby-team.team-blue {
    border: 2px solid rgba(59, 130, 246, 0.5);
}

.team-player-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-height: 60px;
}

.team-player-list:empty::after {
    content: 'No players';
    color: rgba(255, 255, 255, 0.4);
    font-size: 13px;
    text-align: center;
    padding: 15px;
}

.team-player-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
}

.team-player-item.is-self {
    border: 2px solid #4ade80;
    background: rgba(74, 222, 128, 0.15);
}

.team-player-item .player-name {
    flex: 1;
    font-weight: 500;
}

.team-player-item .ready-status {
    font-size: 12px;
    padding: 3px 10px;
    border-radius: 10px;
    font-weight: 500;
}

.team-player-item .ready-status.ready {
    background: #22c55e;
    color: white;
}

.team-player-item .ready-status.not-ready {
    background: rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.6);
}

.team-join-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 10px;
}

.btn-join-team {
    padding: 12px 30px;
    font-size: 15px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-join-red {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    border: 2px solid #ef4444;
    color: white;
}

.btn-join-red:hover {
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
    transform: scale(1.02);
}

.btn-join-red.active {
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.5);
}

.btn-join-blue {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    border: 2px solid #3b82f6;
    color: white;
}

.btn-join-blue:hover {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    transform: scale(1.02);
}

.btn-join-blue.active {
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.5);
}

.join-team-btn {
    width: 100%;
    padding: 8px;
    font-size: 13px;
}

/* Coop/Zombie lobby view */
.lobby-coop {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 25px;
    border: 2px solid rgba(74, 222, 128, 0.5);
    min-height: 100px;
}

.lobby-coop h3 {
    margin: 0 0 15px 0;
    text-align: center;
    color: #4ade80;
}

.coop-player-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.coop-player-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
}

.coop-player-item.is-self {
    border: 2px solid #4ade80;
    background: rgba(74, 222, 128, 0.15);
}

.coop-player-item .player-avatar {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, #4ade80, #22c55e);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.coop-player-item .player-info-text {
    flex: 1;
}

.coop-player-item .ready-badge {
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 10px;
    font-weight: 500;
    background: rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.6);
}

.coop-player-item .ready-badge.ready {
    background: #22c55e;
    color: white;
}

/* King of the Hill - Free For All lobby view */
.lobby-ffa {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 25px;
    border: 2px solid rgba(251, 191, 36, 0.5);
    min-height: 100px;
}

.lobby-ffa h3 {
    margin: 0 0 15px 0;
    text-align: center;
    color: #fbbf24;
}

.ffa-player-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.ffa-player-list:empty::after {
    content: 'No players yet';
    color: rgba(255, 255, 255, 0.4);
    font-size: 13px;
    text-align: center;
    padding: 20px;
    grid-column: 1 / -1;
}

.ffa-player-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
}

.ffa-player-item.is-self {
    border: 2px solid #fbbf24;
    background: rgba(251, 191, 36, 0.15);
}

.ffa-player-item .player-name {
    flex: 1;
    font-weight: 500;
}

.ffa-player-item .ready-badge {
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 10px;
    font-weight: 500;
    background: rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.6);
}

.ffa-player-item .ready-badge.ready {
    background: #22c55e;
    color: white;
}

.coop-player-item .player-name {
    font-weight: bold;
    font-size: 14px;
}

.coop-player-item .player-status {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
}

.coop-player-item .ready-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
}

.coop-player-item .ready-indicator.ready {
    background: #22c55e;
    box-shadow: 0 0 10px #22c55e;
}

/* Deathmatch 1v1 view */
.lobby-deathmatch {
    margin-bottom: 25px;
    min-height: 120px;
}

.deathmatch-players {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 30px;
    min-height: 100px;
}

.player-slot {
    flex: 1;
    max-width: 200px;
    text-align: center;
}

.slot-label {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.slot-content {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 25px 20px;
    min-height: 80px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.slot-content.empty {
    color: rgba(255, 255, 255, 0.4);
    font-style: italic;
}

.slot-content.filled {
    border: 2px solid #4ade80;
}

.slot-content .player-name {
    font-size: 18px;
    font-weight: bold;
}

.slot-content .ready-badge {
    font-size: 12px;
    padding: 4px 12px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.2);
}

.slot-content .ready-badge.ready {
    background: #22c55e;
}

.vs-divider {
    font-size: 32px;
    font-weight: bold;
    color: #ef4444;
    text-shadow: 0 0 20px rgba(239, 68, 68, 0.5);
}

/* Spectator section - Fixed in corner */
.lobby-spectator-section {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: rgba(20, 20, 30, 0.95);
    border: 1px solid rgba(150, 150, 150, 0.3);
    border-radius: 8px;
    padding: 12px 16px;
    width: 200px;
    z-index: 100;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.spectator-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
}

.spectator-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    min-height: 30px;
    margin-bottom: 10px;
}

.spectator-item {
    background: rgba(100, 100, 100, 0.3);
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.8);
}

.spectator-item.is-self {
    background: rgba(59, 130, 246, 0.3);
    border: 1px solid rgba(59, 130, 246, 0.5);
}

.btn-spectator {
    background: rgba(100, 100, 100, 0.4);
    color: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(150, 150, 150, 0.4);
    padding: 6px 12px;
    font-size: 13px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
}

.btn-spectator:hover {
    background: rgba(100, 100, 100, 0.6);
    border-color: rgba(150, 150, 150, 0.6);
}

.btn-spectator.is-spectating {
    background: rgba(59, 130, 246, 0.3);
    border-color: rgba(59, 130, 246, 0.5);
    color: #60a5fa;
}

.btn-spectator:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Lobby actions */
.lobby-actions {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
}

.ready-checkbox {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    padding: 12px 25px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    transition: all 0.2s;
    user-select: none;
}

.ready-checkbox:hover {
    background: rgba(255, 255, 255, 0.15);
}

.ready-checkbox input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.ready-checkbox input[type="checkbox"]:checked + span {
    color: #4ade80;
}

.btn-ready {
    padding: 15px 40px;
    font-size: 18px;
    background: rgba(255, 255, 255, 0.15);
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: #fff;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    min-width: 160px;
}

.btn-ready:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.5);
}

.btn-ready.is-ready {
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    border-color: #22c55e;
    color: #fff;
}

.btn-ready.is-ready:hover {
    background: linear-gradient(135deg, #16a34a 0%, #15803d 100%);
}

.btn-start-game {
    padding: 15px 40px;
    font-size: 18px;
    background: rgba(100, 100, 100, 0.5);
    border: 2px solid rgba(150, 150, 150, 0.3);
    color: rgba(255, 255, 255, 0.4);
    border-radius: 8px;
    cursor: not-allowed;
    transition: all 0.3s;
    min-width: 160px;
}

.btn-start-game:disabled {
    background: rgba(100, 100, 100, 0.5);
    border-color: rgba(150, 150, 150, 0.3);
    color: rgba(255, 255, 255, 0.4);
    cursor: not-allowed;
}

.btn-start-game.not-host {
    background: rgba(80, 80, 100, 0.5);
    border-color: rgba(100, 100, 150, 0.3);
    color: rgba(255, 255, 255, 0.5);
    cursor: not-allowed;
    font-style: italic;
}

.btn-start-game.all-ready {
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    border-color: #22c55e;
    color: #fff;
    cursor: pointer;
    animation: pulse-green 2s ease-in-out infinite;
}

.btn-start-game.all-ready:hover {
    background: linear-gradient(135deg, #16a34a 0%, #15803d 100%);
    transform: scale(1.02);
}

.btn-start {
    padding: 15px 40px;
    font-size: 18px;
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    animation: pulse-green 2s ease-in-out infinite;
}

@keyframes pulse-green {
    0%, 100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.4); }
    50% { box-shadow: 0 0 0 15px rgba(34, 197, 94, 0); }
}

.btn-small {
    padding: 8px 16px;
    font-size: 13px;
}

.lobby-footer {
    text-align: center;
    padding-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Lobby Map Preview */
.lobby-map-preview {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 10px 15px;
    margin: 15px 0;
}

.map-preview-icon {
    font-size: 28px;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
}

.map-preview-info {
    flex: 1;
}

.map-preview-label {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.map-preview-name {
    font-size: 16px;
    font-weight: bold;
    color: #4ade80;
}

/* Map card in selection modal */
.lobby-map-card {
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 12px 8px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
}

.lobby-map-card:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
    transform: scale(1.02);
}

.lobby-map-card.selected {
    background: rgba(74, 222, 128, 0.2);
    border-color: #4ade80;
}

/* ===== PAUSE MENU ===== */

.pause-menu .overlay-content {
    background: rgba(26, 26, 46, 0.95);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    padding: 40px 60px;
}

.pause-content h2 {
    font-size: 36px;
    margin-bottom: 30px;
    color: #fbbf24;
}

.pause-buttons {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.pause-buttons .btn {
    padding: 15px 40px;
    font-size: 16px;
    min-width: 200px;
}

.pause-buttons .btn.primary {
    background: linear-gradient(135deg, #4ade80 0%, #22c55e 100%);
}

.pause-buttons .btn.danger {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
}

/* Settings panel in pause menu */
.settings-content {
    background: rgba(26, 26, 46, 0.95);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    padding: 30px 40px;
    min-width: 350px;
}

.settings-content h2 {
    font-size: 28px;
    margin-bottom: 25px;
    color: #fbbf24;
}

.settings-group {
    margin-bottom: 20px;
    text-align: left;
}

.settings-group label {
    display: block;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 10px;
}

.slider-container {
    display: flex;
    align-items: center;
    gap: 15px;
}

.slider-container input[type="range"] {
    flex: 1;
    height: 8px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.2);
    outline: none;
    -webkit-appearance: none;
}

.slider-container input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #4ade80;
    cursor: pointer;
}

.slider-container input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #4ade80;
    cursor: pointer;
    border: none;
}

.slider-container span {
    min-width: 40px;
    text-align: right;
    font-family: monospace;
    color: #4ade80;
}

/* Toggle button group for settings */
.toggle-group {
    display: flex;
    gap: 10px;
}

.toggle-btn {
    flex: 1;
    padding: 10px 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    background: rgba(0, 0, 0, 0.3);
    color: rgba(255, 255, 255, 0.7);
    font-family: 'Orbitron', sans-serif;
    font-size: 14px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.toggle-btn:hover {
    border-color: rgba(74, 222, 128, 0.5);
    background: rgba(74, 222, 128, 0.1);
}

.toggle-btn.active {
    border-color: #4ade80;
    background: rgba(74, 222, 128, 0.3);
    color: #4ade80;
    font-weight: bold;
}

/* Kill feed wave-info style */
.kill-entry .wave-info {
    color: #fbbf24;
    font-weight: bold;
}

/* ===== SCORE SCREENS ===== */

.game-score-screen,
.zombie-score-screen {
    min-width: 400px;
}

.score-table-container {
    background: rgba(0, 0, 0, 0.5);
    border-radius: 10px;
    padding: 20px;
    margin: 15px 0;
}

.score-table-container h3 {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.8);
    margin: 0 0 15px 0;
}

.score-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 16px;
}

.score-table thead {
    background: rgba(255, 255, 255, 0.1);
}

.score-table th,
.score-table td {
    padding: 12px 20px;
    text-align: center;
}

.score-table th {
    font-weight: 600;
    color: #fbbf24;
    text-transform: uppercase;
    font-size: 13px;
    letter-spacing: 1px;
}

.score-table tbody tr {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.score-table tbody tr:last-child {
    border-bottom: none;
}

.score-table tbody tr.self-row {
    background: rgba(74, 222, 128, 0.15);
}

.score-table tbody tr.self-row td:first-child {
    color: #4ade80;
    font-weight: bold;
}

.score-table td {
    color: rgba(255, 255, 255, 0.9);
}

.total-stats {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    text-align: center;
    font-size: 16px;
    color: rgba(255, 255, 255, 0.7);
}

.total-stats strong {
    color: #fbbf24;
    font-size: 20px;
}

/* Responsive lobby */
@media (max-width: 600px) {
    .lobby-container {
        min-width: auto;
        width: 95%;
        padding: 20px;
    }

    .lobby-teams {
        flex-direction: column;
    }

    .coop-player-list {
        grid-template-columns: 1fr;
    }

    .deathmatch-players {
        flex-direction: column;
        gap: 15px;
    }

    .vs-divider {
        font-size: 24px;
    }
}

/* ===== HIT MARKER SYSTEM ===== */
.hit-marker {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    z-index: 1000;
    opacity: 0;
}

.hit-marker svg {
    width: 40px;
    height: 40px;
}

.hit-marker.active {
    animation: hitMarkerPop 0.15s ease-out forwards;
}

.hit-marker.kill {
    animation: hitMarkerKill 0.3s ease-out forwards;
}

.hit-marker.critical {
    animation: hitMarkerCritical 0.2s ease-out forwards;
}

.hit-marker.headshot {
    animation: hitMarkerHeadshot 0.25s ease-out forwards;
}

@keyframes hitMarkerPop {
    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);
    }
}

@keyframes hitMarkerKill {
    0% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(0.5);
        filter: drop-shadow(0 0 10px #ffd700);
    }
    30% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1.5);
        filter: drop-shadow(0 0 20px #ffd700);
    }
    100% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(1.2);
        filter: drop-shadow(0 0 5px #ffd700);
    }
}

@keyframes hitMarkerCritical {
    0% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(0.6);
        filter: drop-shadow(0 0 8px #ff4444);
    }
    50% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1.3);
        filter: drop-shadow(0 0 15px #ff4444);
    }
    100% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(1);
        filter: drop-shadow(0 0 5px #ff4444);
    }
}

@keyframes hitMarkerHeadshot {
    0% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(0.5) rotate(0deg);
        filter: drop-shadow(0 0 10px #ff00ff);
    }
    50% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1.4) rotate(180deg);
        filter: drop-shadow(0 0 20px #ff00ff);
    }
    100% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(1.1) rotate(360deg);
        filter: drop-shadow(0 0 5px #ff00ff);
    }
}

/* ===== DAMAGE FLASH / VIGNETTE ===== */
.damage-vignette {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 999;
    opacity: 0;
    background: radial-gradient(ellipse at center, transparent 0%, transparent 40%, rgba(255, 0, 0, 0.6) 100%);
    transition: opacity 0.1s ease-out;
}

.damage-vignette.active {
    animation: damageFlash 0.3s ease-out forwards;
}

.damage-vignette.direction-left {
    background: linear-gradient(90deg, rgba(255, 0, 0, 0.5) 0%, transparent 50%);
}

.damage-vignette.direction-right {
    background: linear-gradient(-90deg, rgba(255, 0, 0, 0.5) 0%, transparent 50%);
}

.damage-vignette.direction-front {
    background: linear-gradient(180deg, rgba(255, 0, 0, 0.5) 0%, transparent 50%);
}

.damage-vignette.direction-back {
    background: linear-gradient(0deg, rgba(255, 0, 0, 0.5) 0%, transparent 50%);
}

@keyframes damageFlash {
    0% {
        opacity: var(--damage-intensity, 0.5);
    }
    100% {
        opacity: 0;
    }
}

/* ===== CROSSHAIR HIT INDICATOR ===== */
.crosshair.hit-confirm {
    animation: crosshairHit 0.15s ease-out;
}

.crosshair.kill-confirm {
    animation: crosshairKill 0.3s ease-out;
}

@keyframes crosshairHit {
    0% {
        filter: brightness(1);
    }
    50% {
        filter: brightness(2) drop-shadow(0 0 5px #fff);
    }
    100% {
        filter: brightness(1);
    }
}

@keyframes crosshairKill {
    0% {
        filter: brightness(1);
    }
    30% {
        filter: brightness(3) drop-shadow(0 0 10px #ffd700);
    }
    100% {
        filter: brightness(1);
    }
}
