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

body {
    background: #000;
    color: #fff;
    font-family: 'Courier New', monospace;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    overflow: hidden;
}

.game-container {
    position: relative;
    background: #000;
    border: 4px solid #333;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 
        0 0 20px rgba(255, 107, 107, 0.3),
        inset 0 0 20px rgba(0, 0, 0, 0.5);
}

.crt-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        repeating-linear-gradient(
            0deg,
            transparent,
            transparent 2px,
            rgba(0, 255, 0, 0.03) 2px,
            rgba(0, 255, 0, 0.03) 4px
        );
    pointer-events: none;
    z-index: 10;
    border-radius: 8px;
}

#gameCanvas {
    display: block;
    background: #000;
    border: 2px solid #444;
    image-rendering: pixelated;
    image-rendering: -moz-crisp-edges;
    image-rendering: crisp-edges;
}

#ui-overlay {
    position: absolute;
    top: 20px;
    left: 20px;
    right: 20px;
    pointer-events: none;
    z-index: 5;
}

.hud {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(0, 0, 0, 0.8);
    padding: 8px 16px;
    border: 2px solid #555;
    border-radius: 8px;
    font-size: 16px;
    font-weight: bold;
    text-shadow: 2px 2px 4px #000;
}

.hud-left, .hud-center, .hud-right {
    color: #fff;
}

.hud-center {
    color: #FFD700;
}

.powerups-display {
    display: flex;
    gap: 16px;
    margin-top: 8px;
    background: rgba(0, 0, 0, 0.8);
    padding: 8px 16px;
    border: 2px solid #555;
    border-radius: 8px;
    font-size: 14px;
    font-weight: bold;
}

.powerups-display span {
    color: #fff;
    text-shadow: 1px 1px 2px #000;
}

.menu-screen {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 15;
    border-radius: 8px;
}

.menu-screen.active {
    display: flex;
}

.menu-content {
    text-align: center;
    max-width: 400px;
    padding: 40px;
    background: rgba(20, 20, 20, 0.9);
    border: 3px solid #ff6b6b;
    border-radius: 12px;
    box-shadow: 0 0 30px rgba(255, 107, 107, 0.5);
}

.game-title {
    font-size: 48px;
    font-weight: bold;
    color: #ff6b6b;
    text-shadow: 
        3px 3px 0px #333,
        6px 6px 10px rgba(0, 0, 0, 0.8);
    margin-bottom: 10px;
    letter-spacing: 4px;
}

.subtitle {
    font-size: 16px;
    color: #aaa;
    margin-bottom: 30px;
    font-style: italic;
}

.menu-button {
    background: linear-gradient(45deg, #ff6b6b, #ff8787);
    border: 3px solid #fff;
    color: #fff;
    padding: 12px 30px;
    font-size: 18px;
    font-weight: bold;
    border-radius: 8px;
    cursor: pointer;
    margin: 10px;
    transition: all 0.3s ease;
    font-family: 'Courier New', monospace;
    text-transform: uppercase;
    letter-spacing: 2px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.menu-button:hover {
    background: linear-gradient(45deg, #ff8787, #ffb3b3);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.4);
}

.menu-button:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.controls-info {
    margin-top: 30px;
    font-size: 14px;
    color: #ccc;
    line-height: 1.6;
}

.controls-info p {
    margin: 5px 0;
}

.controls-info strong {
    color: #fff;
}

h2 {
    font-size: 36px;
    color: #ff6b6b;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px #000;
}

#level-score, #time-bonus, #final-score {
    font-size: 18px;
    color: #FFD700;
    margin: 10px 0;
    font-weight: bold;
}

/* Responsive design */
@media (max-width: 900px) {
    .game-container {
        padding: 10px;
        margin: 10px;
    }
    
    #gameCanvas {
        max-width: 100%;
        height: auto;
    }
    
    .game-title {
        font-size: 36px;
    }
    
    .menu-content {
        padding: 20px;
        margin: 20px;
    }
}

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

.menu-button {
    animation: pulse 2s infinite ease-in-out;
}

.menu-button:hover {
    animation: none;
}

/* Retro glow effects */
.hud {
    box-shadow: 
        0 0 10px rgba(255, 107, 107, 0.3),
        inset 0 0 10px rgba(0, 0, 0, 0.5);
}

.powerups-display {
    box-shadow: 
        0 0 10px rgba(255, 107, 107, 0.3),
        inset 0 0 10px rgba(0, 0, 0, 0.5);
}