        #mute-btn {
            position: absolute;
            top: 10px;
            right: 60px;
            width: 40px;
            height: 40px;
            font-size: 20px;
            background-color: rgba(0, 0, 0, 0.5);
            color: white;
            border: none;
            border-radius: 5px;
            cursor: pointer;
            z-index: 10;
            transition: background 0.2s;
        }

        #mute-btn:hover {
            background-color: rgba(0, 0, 0, 0.8);
        }

        /* Mobile Controls (hidden by default, shown only on touch devices) */
        #mobile-controls {
            position: fixed;
            bottom: 10px;
            left: 0;
            right: 0;
            width: 100%;
            display: none; /* default hidden */
            justify-content: space-between;
            pointer-events: none;
            z-index: 9999;
            padding-bottom: constant(safe-area-inset-bottom);
            padding-bottom: env(safe-area-inset-bottom);
        }

        /* When a touch-capable device is detected, body will get .touch-device */
        .touch-device #mobile-controls {
            display: flex;
        }

        .mobile-left,
        .mobile-right {
            display: flex;
            gap: 10px;
            pointer-events: auto;
        }

        .mobile-left {
            margin-left: 10px;
        }

        .mobile-right {
            margin-right: 10px;
        }

        .mobile-btn {
            width: 60px;
            height: 60px;
            font-size: 32px;
            border-radius: 50%;
            border: none;
            background: #ffcb19;
            color: white;
            box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
            cursor: pointer;
            opacity: 0.85;
            transition: background 0.2s;
            user-select: none;
            -webkit-user-select: none;
            -webkit-touch-callout: none;
        }

        button {
            user-select: none;
            -webkit-user-select: none;
            -webkit-touch-callout: none;
        }

        .mobile-btn:active {
            background: #ebb916;
        }

        /* Removed width-based hiding; visibility controlled by touch detection JS */

        @font-face {
            font-family: 'zebars';
            src: url('fonts/Zabars.ttf') format('truetype');
        }


        body {
            margin: 0;
            padding: 0;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            font-family: 'zebars', sans-serif;
            height: 100vh;
            background-color: #f0f0f0;
            background-image: url('img/backround-dessert.png');
            background-size: cover;
            background-position: center;
        }

        h1 {
            text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.5);
            margin-bottom: 20px;
            font-size: 62px;
        }

        #game-container {
            position: relative;
            width: 720px;
            height: 480px;
            padding-bottom: 100px; /* reserve space for fixed buttons */
        }

        /* When compact mode is active (landscape / playing) remove extra bottom padding */
        .compact-runtime #game-container {
            padding-bottom: 0;
        }

        .normalfont {
            font-family: Arial, Helvetica, sans-serif;
            font-size: 16px;
            text-align: center;
        }

        canvas {
            background-color: black;
            display: block;
        }

        #start-btn {
            position: absolute;
            top: 10%;
            left: 50%;
            transform: translate(-50%, -50%);
            padding: 20px 60px;
            font-size: 24px;
            font-weight: bold;
            background-color: #ffcb19;
            color: white;
            border: none;
            border-radius: 10px;
            cursor: pointer;
            z-index: 10;
        }

        #start-btn:hover {
            background-color: #ebb916;
        }

        #fullscreen-btn {
            position: absolute;
            top: 10px;
            right: 10px;
            width: 40px;
            height: 40px;
            font-size: 20px;
            background-color: rgba(0, 0, 0, 0.5);
            color: white;
            border: none;
            border-radius: 5px;
            cursor: pointer;
            z-index: 10;
        }

        #fullscreen-btn:hover {
            background-color: rgba(0, 0, 0, 0.8);
        }

        #game-container:fullscreen {
            width: 100vw;
            height: 100vh;
            display: flex;
            justify-content: center;
            align-items: center;
            background-color: black;
        }

        #game-container:fullscreen canvas {
            width: 100vw;
            height: 100vh;
            object-fit: contain;
        }

        @media only screen and (max-width: 760px) {
            #game-container {
                width: 100%;
                height: auto;
            }

            canvas {
                width: 100%;
                height: auto;
            }
        }

        @media only screen and (max-height: 480px) {
            body {
                justify-content: flex-start;
            }

            h1 {
                display: none;
            }

            .normalfont {
                display: none;
            }

            #game-container {
                width: 100%;
                height: 100vh;
            }

            canvas {
                width: 100%;
                height: 100vh;
            }

            #start-btn {
                top: 15%;
            }
        }

        @media only screen and (max-width: 760px) and (max-height: 480px) {
            h1 {
                display: none;
            }

            .normalfont {
                display: none;
            }

            #game-container {
                width: 100vw;
                height: 100vh;
            }

            canvas {
                width: 100vw;
                height: 100vh;
            }
        }

    /* Orientation notice: hidden by default, shown briefly when .visible is added */
    #orientation-notice {
        display: none;
        position: fixed;
        top: 18px;
        left: 50%;
        transform: translateX(-50%) translateY(-10px);
        background: rgba(0,0,0,0.75);
        color: #fff;
        padding: 8px 14px;
        border-radius: 10px;
        font-family: Arial, Helvetica, sans-serif;
        font-size: 14px;
        z-index: 10000;
        pointer-events: none;
        opacity: 0;
        transition: opacity 0.25s ease, transform 0.25s ease;
    }

    #orientation-notice.visible {
        display: block;
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }

/* Impressum link/button fixed bottom-center */
.impressum-link-btn {
    position: static;
    display: block;
    width: fit-content;
    /* push to bottom of viewport when possible (body is column flex) */
    margin-left: auto;
    margin-right: auto;
    margin-top: auto;
    margin-bottom: 20px;
    padding: 12px 20px;
    background: linear-gradient(180deg,#ff6b00,#ff8a2b);
    color: #fff;
    text-decoration: none;
    border-radius: 28px;
    box-shadow: 0 6px 18px rgba(0,0,0,0.12);
    transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
    font-weight: 600;
    font-size: 16px;
    font-family: Arial, Helvetica, sans-serif;
    text-align: center;
}
.impressum-link-btn:hover,
.impressum-link-btn:focus {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 12px 26px rgba(0,0,0,0.22);
    background: linear-gradient(180deg,#ff7b1a,#ff9b49);
    outline: none;
}

@media (max-width: 600px) {
    .impressum-link-btn { margin: 18px auto 32px; padding: 10px 16px; font-size: 15px; }
}
@media (max-width: 320px) {
    .impressum-link-btn { margin: 14px auto 28px; padding: 8px 14px; font-size: 14px; }
}