body, html {
    margin: 0;
    padding: 0;
    height: 100vh;
    width: 100vw;
    overflow: hidden;
    background-color: #000000;
    display: flex;
    justify-content: center;
    align-items: center;
    font-family: 'Press Start 2P', cursive;
    border: 1px solid #444444;
    box-sizing: border-box;
}

#mainContainer {
    display: flex;
    gap: 0;
    height: 100vh;
    max-height: 100vh;
    box-sizing: border-box;
}

#gameContainer {
    border: 3px solid gray;
    background-color: #0a0a0a;
    position: relative;
    overflow: hidden;
    aspect-ratio: 4 / 5;
    height: 100%;
    box-sizing: border-box;
}

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

#gameOverScreen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    background-color: transparent;
}

#gameOverScreen.game-over-hidden {
    display: none;
}

#initialScreen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    background-color: transparent;
}

#initialScreen.initial-screen-hidden {
    display: none;
}

.game-over-content {
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 30px;
    align-items: center;
}

.game-over-content h1 {
    font-size: 48px;
    color: #ff0000;
    margin: 0;
    text-shadow: 0 0 10px rgba(255, 0, 0, 0.8);
    font-family: 'Press Start 2P', cursive;
}

.initial-screen-content {
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 30px;
    align-items: center;
}

.initial-screen-content h1 {
    font-size: 48px;
    color: #00ff00;
    margin: 0;
    text-shadow: 0 0 10px rgba(0, 255, 0, 0.8);
    font-family: 'Press Start 2P', cursive;
}

.game-over-level {
    font-size: 24px;
    color: #00ff00;
    font-family: 'Press Start 2P', cursive;
}

.game-over-response {
    font-size: 16px;
    color: #00ff00;
    font-family: 'Press Start 2P', cursive;
    font-style: italic;
    min-height: 20px;
}

.game-over-footer {
    font-size: 14px;
    color: #00ff00;
    font-family: 'Press Start 2P', cursive;
    margin-top: 20px;
}

.github-link {
    color: #10a817;
    text-decoration: underline;
    cursor: pointer;
    transition: all 0.2s;
}

.github-link:hover {
    color: #15d31f;
    text-shadow: 0 0 10px rgba(36, 202, 30, 0.8);
}

.restart-button {
    padding: 15px 40px;
    font-size: 20px;
    font-family: 'Press Start 2P', cursive;
    background-color: transparent;
    color: #00ff00;
    border: 3px solid #00ff00;
    cursor: pointer;
    transition: all 0.2s;
}

.restart-button:hover {
    background-color: #00ff00;
    color: #000000;
    box-shadow: 0 0 20px rgba(0, 255, 0, 0.8);
}

.restart-button:active {
    transform: scale(0.95);
}

.start-button {
    padding: 15px 40px;
    font-size: 20px;
    font-family: 'Press Start 2P', cursive;
    background-color: transparent;
    color: #00ff00;
    border: 3px solid #00ff00;
    cursor: pointer;
    transition: all 0.2s;
}

.start-button:hover {
    background-color: #00ff00;
    color: #000000;
    box-shadow: 0 0 20px rgba(0, 255, 0, 0.8);
}

.start-button:active {
    transform: scale(0.95);
}

.controls-list {
    font-size: 16px;
    color: #00ff00;
    font-family: 'Press Start 2P', cursive;
    line-height: 1.8;
}

.controls-list p {
    margin: 0;
}

.weapon-unlock-info {
    font-size: 14px;
    color: #ffaa00;
    font-family: 'Press Start 2P', cursive;
    line-height: 1.6;
    border-top: 2px solid #ffaa00;
    border-bottom: 2px solid #ffaa00;
    padding: 15px 20px;
}

.weapon-unlock-info p {
    margin: 0;
}

.initial-screen-footer {
    font-size: 14px;
    color: #00ff00;
    font-family: 'Press Start 2P', cursive;
    margin-top: 20px;
}

#sidePanel {
    border: 3px solid gray;
    border-left: none;
    background-color: #0a0a0a;
    width: 200px;
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 0;
    box-sizing: border-box;
}

#weaponPanel {
    border: 3px solid gray;
    border-right: none;
    background-color: #0a0a0a;
    width: 200px;
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 0;
    box-sizing: border-box;
}

.weapon-box {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 20px;
    box-sizing: border-box;
    border-bottom: 3px solid gray;
    cursor: pointer;
    transition: background-color 0.2s;
}

.weapon-box:last-child {
    border-bottom: none;
}

.weapon-box:hover {
    background-color: #1a1a1a;
}

.weapon-box.active {
    background-color: #1a3a1a;
    border-left: 5px solid #00ff00;
}

.weapon-box.locked {
    opacity: 0.3;
    cursor: not-allowed;
}

.weapon-box.locked:hover {
    background-color: #0a0a0a;
}

.weapon-box.locked .weapon-label {
    color: #555555;
    text-shadow: none;
}

.weapon-box.locked .weapon-icon {
    filter: grayscale(100%) brightness(0.4);
}

.weapon-box.unlock-flash {
    animation: goldenFlash 1s ease-out;
}

@keyframes goldenFlash {
    0% {
        background-color: #ffdd00;
        box-shadow: 0 0 30px rgba(255, 221, 0, 1);
    }
    25% {
        background-color: #0a0a0a;
        box-shadow: none;
    }
    50% {
        background-color: #ffdd00;
        box-shadow: 0 0 30px rgba(255, 221, 0, 1);
    }
    75% {
        background-color: #0a0a0a;
        box-shadow: none;
    }
    100% {
        background-color: #0a0a0a;
        box-shadow: none;
    }
}

.weapon-label {
    font-size: 12px;
    color: #00ff00;
    margin-bottom: 15px;
    letter-spacing: 2px;
    text-shadow: 0 0 8px rgba(0, 255, 0, 0.6);
}

.weapon-icon {
    width: 80px;
    height: 80px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    image-rendering: pixelated;
}

.projectile-icon {
    width: 12px;
    height: 30px;
    background: linear-gradient(180deg, #00aaff 0%, #0066aa 100%);
    border-radius: 2px;
    box-shadow: 0 0 10px rgba(0, 170, 255, 0.5);
}

.lazer-icon {
    width: 60px;
    height: 14px;
    background: linear-gradient(90deg, #ff0000 0%, #ff6600 50%, #ffff00 100%);
    box-shadow: 0 0 15px rgba(255, 0, 0, 0.8);
}

.bomb-icon {
    width: 35px;
    height: 35px;
    background-color: #333333;
    box-shadow: 
        inset 0 0 0 3px #666666,
        inset 0 0 0 6px #888888,
        inset 0 0 0 9px #aaaaaa,
        0 0 10px rgba(100, 100, 100, 0.4);
    image-rendering: pixelated;
}


.panel-box {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 20px;
    box-sizing: border-box;
}

#scorePanel {
    border-bottom: 3px solid gray;
    position: relative;
    overflow: hidden;
}

#bonusContainer {
    position: relative;
    height: 0;
    overflow: hidden;
}

.panel-value {
    font-size: 48px;
    color: #00ff00;
    text-align: center;
    line-height: 1.2;
    word-wrap: break-word;
    max-width: 100%;
    text-shadow: 0 0 8px rgba(0, 255, 0, 0.3);
}

#scorePanel .panel-value {
    font-size: 64px;
}

.level-label {
    font-size: 12px;
    color: #00ff00;
    margin-bottom: 20px;
    letter-spacing: 2px;
}

#levelPanel .panel-value {
    font-size: 56px;
}

.bonus-notification {
    color: #ffdd00;
    font-size: 10px;
    font-family: 'Press Start 2P', cursive;
    white-space: nowrap;
    pointer-events: none;
    text-shadow: 0 0 8px rgba(255, 221, 0, 0.8);
    animation: bonusScroll 3.5s ease-in forwards;
}

@keyframes bonusScroll {
    0% {
        opacity: 1;
        transform: translateX(0);
    }
    5% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        opacity: 0;
        transform: translateX(-80px);
    }
}