* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: #000;
    color: #fff;
    font-family: 'Courier New', monospace;
    overflow: hidden;
}

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

#gameCanvas {
    width: 100%;
    height: 100%;
    display: block;
}

#hud {
    position: relative;
    bottom: 0;
    left: 0;
    right: 0;
    height: 80px;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    padding: 10px 20px;
}

#health-bar, #ammo-bar {
    display: flex;
    flex-direction: column;
    align-items: center;
}

#health-bar span, #ammo-bar span {
    font-size: 12px;
    color: #888;
    margin-bottom: 5px;
}

#health-value {
    font-size: 24px;
    color: #0f0;
    text-shadow: 0 0 10px #0f0;
    transition: color 0.3s, text-shadow 0.3s;
}

#health-value.low {
    color: #f00;
    text-shadow: 0 0 10px #f00;
    animation: pulse 0.5s infinite;
}

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

#health-bar-container {
    display: flex;
    flex-direction: column;
    align-items: center;
}

#health-bar-bg {
    width: 150px;
    height: 15px;
    background: #333;
    border: 2px solid #555;
    margin-top: 5px;
    position: relative;
}

#health-bar-fill {
    height: 100%;
    background: linear-gradient(to right, #0f0, #0a0);
    transition: width 0.3s, background 0.3s;
    width: 100%;
}

#health-bar-fill.low {
    background: linear-gradient(to right, #f00, #800);
    animation: pulse-bar 0.5s infinite;
}

@keyframes pulse-bar {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

#ammo-value {
    font-size: 24px;
    color: #ff0;
    text-shadow: 0 0 10px #ff0;
}

#level-display {
    position: absolute;
    left: 20px;
    top: 10px;
    font-size: 20px;
    color: #0ff;
    text-shadow: 0 0 10px #0ff;
    text-transform: uppercase;
    letter-spacing: 2px;
}

#weapon-display {
    position: absolute;
    right: 20px;
    bottom: 10px;
}

#weapon-icon {
    width: 100px;
    height: 60px;
    image-rendering: pixelated;
}

#menu, #game-over, #victory {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: rgba(0,0,0,0.9);
    z-index: 100;
}

#menu h1, #game-over h1, #victory h1 {
    font-size: 64px;
    color: #f00;
    text-shadow: 0 0 20px #f00, 0 0 40px #800;
    margin-bottom: 40px;
    letter-spacing: 8px;
}

#victory h1 {
    color: #0f0;
    text-shadow: 0 0 20px #0f0, 0 0 40px #080;
}

button {
    font-family: 'Courier New', monospace;
    font-size: 24px;
    padding: 15px 40px;
    margin: 10px;
    background: #300;
    color: #f00;
    border: 2px solid #f00;
    cursor: pointer;
    transition: all 0.3s;
    text-transform: uppercase;
    letter-spacing: 4px;
}

button:hover {
    background: #f00;
    color: #000;
    box-shadow: 0 0 20px #f00;
}

.hidden {
    display: none !important;
}

#controls-info {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0,0,0,0.95);
    padding: 40px;
    border: 2px solid #f00;
    z-index: 200;
    text-align: center;
}

#controls-info h2 {
    color: #f00;
    margin-bottom: 20px;
}

#controls-info p {
    margin: 10px 0;
    color: #ccc;
}