* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: #000;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    font-family: 'Courier New', monospace;
    overflow: hidden;
    touch-action: none;
}

#gameCanvas {
    border: 2px solid #0ff;
    box-shadow: 0 0 20px #0ff;
    max-width: 100vw;
    max-height: 100vh;
}

#ui {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    color: #0ff;
    text-align: center;
    font-size: 24px;
    text-shadow: 0 0 10px #0ff;
    pointer-events: none;
    z-index: 10;
}

#bossHealth {
    position: absolute;
    top: 90px;
    left: 50%;
    transform: translateX(-50%);
    width: 200px;
    height: 20px;
    background: #333;
    border: 2px solid #f00;
    box-shadow: 0 0 10px #f00;
    z-index: 10;
    display: none;
}

#bossHealthBar {
    height: 100%;
    background: #f00;
    width: 100%;
    transition: width 0.1s;
}

#bossLabel {
    position: absolute;
    top: 115px;
    left: 50%;
    transform: translateX(-50%);
    color: #f00;
    font-size: 14px;
    text-shadow: 0 0 10px #f00;
    z-index: 10;
    display: none;
}

#gameOver {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #f0f;
    text-align: center;
    font-size: 32px;
    text-shadow: 0 0 20px #f0f;
    display: none;
    z-index: 10;
}

#gameOver button {
    margin-top: 20px;
    padding: 10px 30px;
    font-size: 20px;
    background: #0ff;
    border: none;
    color: #000;
    cursor: pointer;
    font-family: 'Courier New', monospace;
    font-weight: bold;
}

#gameOver button:hover {
    background: #fff;
}

.instruction {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    color: #0ff;
    font-size: 16px;
    text-shadow: 0 0 10px #0ff;
    z-index: 10;
}

#levelUpNotification {
    position: absolute;
    top: 100px;
    left: 50%;
    transform: translateX(-50%);
    color: #0f0;
    text-align: center;
    font-size: 48px;
    font-weight: bold;
    text-shadow: 0 0 20px #0f0;
    pointer-events: none;
    z-index: 15;
    display: none;
}

#bossNotification {
    position: absolute;
    top: 100px;
    left: 50%;
    transform: translateX(-50%);
    color: #f00;
    text-align: center;
    font-size: 48px;
    font-weight: bold;
    text-shadow: 0 0 20px #f00;
    pointer-events: none;
    z-index: 15;
    display: none;
}

#bossDefeatedNotification {
    position: absolute;
    top: 100px;
    left: 50%;
    transform: translateX(-50%);
    color: #0f0;
    text-align: center;
    font-size: 48px;
    font-weight: bold;
    text-shadow: 0 0 20px #0f0;
    pointer-events: none;
    z-index: 15;
    display: none;
}

#groupNotification {
    position: absolute;
    top: 100px;
    left: 50%;
    transform: translateX(-50%);
    color: #ff0;
    text-align: center;
    font-size: 48px;
    font-weight: bold;
    text-shadow: 0 0 20px #ff0;
    pointer-events: none;
    z-index: 15;
    display: none;
}

@keyframes levelUpPulse {
    0% { transform: translateX(-50%) scale(0.5); opacity: 0; }
    10% { transform: translateX(-50%) scale(1.2); opacity: 1; }
    90% { transform: translateX(-50%) scale(1); opacity: 1; }
    100% { transform: translateX(-50%) scale(1); opacity: 0; }
}

.notification-animate {
    animation: levelUpPulse 2s ease-out;
}

#highScoreEntry {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.95);
    padding: 40px;
    border: 3px solid #0ff;
    box-shadow: 0 0 30px #0ff;
    z-index: 20;
}

#leaderboard {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.95);
    padding: 40px;
    border: 3px solid #0ff;
    box-shadow: 0 0 30px #0ff;
    z-index: 20;
    max-height: 80vh;
    overflow-y: auto;
}

#mainMenu {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    z-index: 25;
}

.menu-title {
    color: #0ff;
    font-size: 64px;
    font-weight: bold;
    text-shadow: 0 0 30px #0ff;
    margin-bottom: 50px;
}

.menu-buttons {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.menu-btn {
    width: 250px;
    padding: 15px 40px;
    font-size: 24px;
    background: transparent;
    border: 3px solid #0ff;
    color: #0ff;
    cursor: pointer;
    font-family: 'Courier New', monospace;
    font-weight: bold;
    text-shadow: 0 0 10px #0ff;
    box-shadow: 0 0 15px #0ff;
    transition: all 0.2s;
}

.menu-btn:hover {
    background: #0ff;
    color: #000;
    text-shadow: none;
}

.mode-desc {
    color: #088;
    font-size: 14px;
    margin-bottom: 20px;
}
