* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Courier New', Courier, monospace;
}

body {
    background-color: #050510;
    overflow: hidden;
    color: #fff;
}

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

canvas {
    display: block;
}

#ui-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

#leaderboard {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.5);
    padding: 10px;
    border: 1px solid #0ff;
    border-radius: 5px;
    box-shadow: 0 0 10px #0ff;
}

#leaderboard h3 {
    text-align: center;
    color: #0ff;
    margin-bottom: 5px;
    text-shadow: 0 0 5px #0ff;
}

#score-list {
    list-style: none;
}

#health-bar-container {
    position: absolute;
    bottom: 20px;
    left: 20px;
    width: 200px;
    height: 20px;
    border: 2px solid #fff;
    border-radius: 10px;
    overflow: hidden;
}

#health-bar {
    width: 100%;
    height: 100%;
    background: #0f0;
    box-shadow: 0 0 10px #0f0;
    transition: width 0.2s, background 0.2s;
}

.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10;
    pointer-events: auto;
}

.hidden {
    display: none;
}

.box {
    text-align: center;
    background: rgba(10, 10, 30, 0.9);
    padding: 40px;
    border: 2px solid #f0f;
    border-radius: 10px;
    box-shadow: 0 0 20px #f0f;
}

h1 {
    font-size: 3em;
    margin-bottom: 20px;
    color: #f0f;
    text-shadow: 0 0 10px #f0f;
}

input {
    padding: 10px;
    font-size: 1.2em;
    background: #000;
    border: 1px solid #0ff;
    color: #0ff;
    margin-bottom: 20px;
    outline: none;
    text-align: center;
}

button {
    padding: 10px 30px;
    font-size: 1.2em;
    background: #0ff;
    color: #000;
    border: none;
    cursor: pointer;
    font-weight: bold;
    box-shadow: 0 0 10px #0ff;
    transition: transform 0.1s;
}

button:hover {
    transform: scale(1.1);
}

.blink {
    animation: blink 1s infinite;
    color: #f00;
    text-shadow: 0 0 20px #f00;
}

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