#gameContainer {
    position: relative;
    overflow: hidden;
    box-sizing: border-box;
    border-radius: 12px;
    width: 100%;
    max-width: 720px;
    aspect-ratio: 3 / 2;
    height: auto;
    border: 3px solid rgba(35, 18, 8, 0.85);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.45);
}


.start-screen {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 10;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 1;
    pointer-events: auto;
    transition: opacity 180ms ease-in-out;
}


.start-screen.is-closed {
    opacity: 0;
    pointer-events: none;
}


#startButton {
    position: absolute;
    top: 12px;
}


#startGame {
    margin: 0;
}


.game-over-overlay,
.win-overlay {
    position: absolute;
    inset: 0;
    align-items: center;
    flex-direction: column;
    justify-content: space-between;
    padding: 12px 0 12px;
    display: flex;
    opacity: 0;
    pointer-events: none;
    transition: opacity 180ms ease-in-out;
}


.overlay-style,
.modal-overlay {
    opacity: 0;
    transition: opacity 180ms ease-in-out;
    pointer-events: none;
}


.game-over-overlay.is-open,
.win-overlay.is-open,
.overlay-style.is-open,
.modal-overlay.is-open {
    opacity: 1;
    pointer-events: auto;
}


.next-level-query {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}


.next-level-text {
    background-color: rgb(255, 186, 0);
    padding: 10px 14px;
    border-radius: 10px;
    margin-bottom: 12px;
    text-align: center;
    font-weight: 600;
}


.game-over-btn,
.win-btn,
#startButton {
    font-size: 20px;
    padding: 10px 14px;
    border-radius: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
}


.orientation-overlay {
    text-align: center;
    font-size: 20px;
    padding: 20px;
    opacity: 1;
    pointer-events: auto;
}


.orientation-card {
    background: rgba(255, 186, 0, 0.9);
    padding: 20px 30px;
    border-radius: 12px;
    max-width: 80%;
}


canvas {
    background-color: black;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: block;
    image-rendering: auto;
}


:fullscreen,
:-webkit-full-screen {
    background: #000;
}


#gameContainer:fullscreen,
#gameContainer:-webkit-full-screen,
#gameContainer:-webkit-full-screen .start-screen {
    width: 100vw;
    height: 100vh;
    max-width: none;
    max-height: none;
    aspect-ratio: unset;
    border: 0;
    box-shadow: none;
}


#gameContainer:fullscreen #gameOverOverlay,
#gameContainer:-webkit-full-screen #gameOverOverlay,
#gameContainer:fullscreen #winOverlay,
#gameContainer:-webkit-full-screen #winOverlay {
    width: 100vw;
    inset: 0;
}


#pauseBtn {
    position: absolute;
    bottom: 12px;
    right: 206px;
    z-index: 20;
}


#startScreenImg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    image-rendering: auto;
    object-position: 55%;
}


#mobileControls {
    width: 100%;
    flex-wrap: wrap;
    gap: 10px;
    position: absolute;
    bottom: 12px;
    justify-content: space-between;
}


.direction {
    margin: 0 0 0 12px;
    display: flex;
    gap: 12px;
}


.attack {
    margin: 0 82px 0 64px;
    display: flex;
    gap: 12px;
}


.control-btn {
    padding: 6px 12px;
    background-color: rgba(0, 0, 0, 0.2);
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    user-select: none;
    touch-action: none;
}


.control-btn:hover {
    background-color: rgba(0, 0, 0, 0.3);
    box-shadow: 0 6px 8px rgba(0, 0, 0, 0.4);
}


.no-active-press:active {
    transform: none !important;
}


.control-btn.is-pressed {
    transform: translateY(1px);
    background-color: rgba(0, 0, 0, 0.3);
}


.control-btn img {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    pointer-events: none;
}


#controlsInfo {
    margin-top: 20px;
    width: 720px;
    background-color: #fef6e4;
    border: 2px solid #ffb703;
    border-radius: 10px;
}


#controlsInfo h3 {
    margin: 0;
    color: #333;
    padding: 16px
}


#controlsInfo ul {
    padding: 0 16px 16px 36px;
    margin: 0;
}


#controlsInfo li {
    margin-bottom: 8px;
}


.audio-hud {
    position: absolute;
    top: 78px;
    right: 12px;
    z-index: 35;
    flex-direction: column;
    gap: 12px;
}


.audio-hud-btn {
    padding: 8px 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}


.audio-hud-btn img {
    width: 24px;
    height: 24px;
    pointer-events: none;
}


#gameContainer.is-fake-fullscreen {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    max-width: none;
    max-height: none;
    border-radius: 0;
    border: 0;
    box-shadow: none;
    z-index: 9999;
}


body.no-scroll {
    overflow: hidden;
}


.level-indicator {
    position: absolute;
    top: 12px;
    right: 50%;
    z-index: 50;
    padding: 6px 10px;
    border-radius: 10px;
    font-weight: 700;
    font-size: 14px;
    background: rgba(0, 0, 0, 0.55);
    opacity: 0;
    transition: opacity 180ms ease ease-in-out;
}


.level-indicator.is-visible {
    opacity: 1;
}


.burger-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 30;
    padding: 8px 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}


.fullscreen-btn {
    position: absolute;
    bottom: 12px;
    right: 12px;
    padding: 8px 10px;
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: center;
}
