* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Courier New', monospace;
    background: #000;
    color: #00a0ff;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    overflow: hidden;
}

.game-container {
    width: 100%;
    max-width: 900px;
    background: #111;
    border: 3px solid #00a0ff;
    box-shadow: 0 0 20px rgba(0, 160, 255, 0.5);
}

.header {
    background: #000;
    padding: 15px 20px;
    border-bottom: 2px solid #00a0ff;
}

.header h1 {
    font-size: 24px;
    text-align: center;
    margin-bottom: 10px;
    text-shadow: 0 0 10px #00a0ff;
}

.stats {
    display: flex;
    justify-content: space-around;
    font-size: 16px;
}

.stat {
    display: flex;
    gap: 8px;
}

.label {
    color: #0080cc;
}

.value {
    color: #00a0ff;
    font-weight: bold;
}

#gameCanvas {
    display: block;
    width: 100%;
    background: #000;
    cursor: crosshair;
    image-rendering: pixelated;
    image-rendering: -moz-crisp-edges;
    image-rendering: crisp-edges;
}

.controls {
    background: #000;
    padding: 15px 20px;
    border-top: 2px solid #00a0ff;
}

.ammo-display {
    display: flex;
    justify-content: space-around;
}

.battery {
    display: flex;
    gap: 8px;
    font-size: 14px;
}

.ammo-count {
    color: #00a0ff;
    font-weight: bold;
    min-width: 25px;
}

.game-over, .start-screen, .high-score-entry {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.95);
    border: 3px solid #00a0ff;
    padding: 40px;
    text-align: center;
    min-width: 400px;
    box-shadow: 0 0 30px rgba(0, 160, 255, 0.8);
    max-height: 90vh;
    overflow-y: auto;
}

.game-over h2, .start-screen h2 {
    font-size: 36px;
    margin-bottom: 20px;
    text-shadow: 0 0 15px #00a0ff;
}

.game-over p {
    font-size: 20px;
    margin-bottom: 30px;
}

.start-screen p {
    font-size: 18px;
    margin-bottom: 20px;
    color: #0080cc;
}

.instructions {
    text-align: left;
    list-style: none;
    margin-bottom: 30px;
    font-size: 14px;
    color: #0080cc;
}

.instructions li {
    margin-bottom: 10px;
    padding-left: 20px;
    position: relative;
}

.instructions li:before {
    content: "►";
    position: absolute;
    left: 0;
    color: #00a0ff;
}

button {
    background: #000;
    color: #00a0ff;
    border: 2px solid #00a0ff;
    padding: 15px 40px;
    font-size: 18px;
    font-family: 'Courier New', monospace;
    cursor: pointer;
    transition: all 0.3s;
    text-shadow: 0 0 5px #00a0ff;
}

button:hover {
    background: #00a0ff;
    color: #000;
    box-shadow: 0 0 15px #00a0ff;
}

button:active {
    transform: scale(0.95);
}

button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    box-shadow: none;
}

button:disabled:hover {
    background: #000;
    color: #00a0ff;
    box-shadow: none;
}

.hidden {
    display: none !important;
}

#final-score, #high-score-value {
    color: #00a0ff;
    font-size: 28px;
    font-weight: bold;
}

/* High Score Entry */
.enter-initials {
    font-size: 18px;
    margin: 20px 0 10px;
    color: #0080cc;
}

.initials-selector {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin: 30px 0;
}

.letter-selector {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.letter-display {
    font-size: 48px;
    font-weight: bold;
    color: #00a0ff;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #00a0ff;
    background: #000;
    text-shadow: 0 0 10px #00a0ff;
}

.letter-selector.active .letter-display {
    background: #00a0ff;
    color: #000;
    box-shadow: 0 0 20px #00a0ff;
}

.arrow-up, .arrow-down {
    background: #000;
    color: #00a0ff;
    border: 2px solid #00a0ff;
    padding: 8px 20px;
    font-size: 20px;
    font-family: 'Courier New', monospace;
    cursor: pointer;
    transition: all 0.2s;
    min-width: 60px;
}

.arrow-up:hover, .arrow-down:hover {
    background: #00a0ff;
    color: #000;
    box-shadow: 0 0 10px #00a0ff;
}

.arrow-up:active, .arrow-down:active {
    transform: scale(0.9);
}

.hint {
    font-size: 12px;
    color: #0080cc;
    margin: 10px 0 20px;
}

/* High Scores Display */
.high-scores-display {
    margin: 30px 0;
    padding: 20px;
    background: rgba(0, 80, 160, 0.2);
    border: 2px solid #0080cc;
}

.high-scores-display h3 {
    font-size: 20px;
    margin-bottom: 15px;
    color: #00a0ff;
    text-shadow: 0 0 10px #00a0ff;
}

#high-scores-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.high-score-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 20px;
    background: #000;
    border: 1px solid #0080cc;
    font-size: 16px;
}

.high-score-rank {
    color: #0080cc;
    font-weight: bold;
    min-width: 40px;
}

.high-score-initials {
    color: #00a0ff;
    font-weight: bold;
    letter-spacing: 5px;
    min-width: 80px;
}

.high-score-score {
    color: #00a0ff;
    font-weight: bold;
    min-width: 100px;
    text-align: right;
}
