* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    touch-action: none;
}
html, body {
    background: #000;
    width: 100%;
    height: 100%;
    overflow: hidden;
    font-family: 'Courier New', monospace;
}
#gameContainer {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}
canvas {
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}
/* HUD rendered as vector graphics on canvas */
#touchControls {
    position: absolute;
    bottom: 42px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-between;
    padding: 0 15px;
    z-index: 10;
}
.touchBtn {
    width: 60px;
    height: 60px;
    border: 2px solid rgba(0, 255, 255, 0.8);
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.4);
    color: #0ff;
    font-size: 22px;
    display: flex;
    justify-content: center;
    align-items: center;
    user-select: none;
    -webkit-user-select: none;
    text-shadow: 0 0 10px #0ff;
    box-shadow: 0 0 15px rgba(0, 255, 255, 0.3);
}
.touchBtn:active {
    background: rgba(0, 255, 255, 0.3);
}
#fireBtn {
    border-color: rgba(255, 0, 0, 0.8);
    color: #f00;
    background: rgba(0, 0, 0, 0.4);
    box-shadow: 0 0 15px rgba(255, 0, 0, 0.3);
    text-shadow: 0 0 10px #f00;
}
#fireBtn:active {
    background: rgba(255, 0, 0, 0.3);
}
.dirBtns {
    display: flex;
    gap: 8px;
}
.rightBtns {
    display: flex;
    gap: 8px;
}
#zapBtn {
    border-color: rgba(255, 255, 0, 0.8);
    color: #ff0;
    background: rgba(0, 0, 0, 0.4);
    box-shadow: 0 0 15px rgba(255, 255, 0, 0.3);
    text-shadow: 0 0 10px #ff0;
}
#zapBtn:active {
    background: rgba(255, 255, 0, 0.3);
}
#zapBtn.used {
    opacity: 0.3;
}

@media (min-width: 800px) {
    #touchControls {
        display: none;
    }
    /* Show touch controls on large touch devices */
    #touchControls.force-show {
        display: flex;
    }
}

/* Settings button */
#settingsBtn {
    position: absolute;
    top: 10px;
    right: 10px;
    cursor: pointer;
    user-select: none;
    z-index: 15;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 50%;
    padding: 0;
    width: 44px;
    height: 44px;
    display: none; /* Hidden by default, shown via JS */
}
#settingsBtn canvas {
    display: block;
}

/* Settings now rendered on canvas */

/* Aspect ratio container */
#aspectContainer {
    position: relative;
    background: #000;
}
