html,
body {
    padding: 0;
    margin: 0;
    overflow: hidden;
    image-rendering: pixelated;
    background: #3d3e42; /* Missing semicolon fixed */

    background-size: cover;
    background-position: center;
}

canvas {
    width: 100%;
    background: blue;
    border-bottom: 5px solid #fff;
}

@font-face {
    font-family: fontRetroGaming;
    src: url("../fonts/Retro Gaming.ttf");
}

#orientation-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.9); /* Etwas dunkler für mehr Kontrast */
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-size: 1.8rem; /* Etwas größere Schrift für bessere Sichtbarkeit */
    padding: 10%;
    box-sizing: border-box; /* Verhindert, dass Padding die Breite verändert */
    z-index: 2000; /* Stellt sicher, dass es über allem liegt */
    visibility: hidden; /* Unsichtbar beim Start */
    opacity: 0;
}

#orientation-overlay p {
    max-width: 80%;
    background: rgba(
            255,
            255,
            255,
            0.15
    ); /* Leicht transparente Box für besseren Kontrast */
    padding: 20px;
    border-radius: 12px; /* Abgerundete Ecken für moderneren Look */
    box-shadow: 0px 0px 15px rgba(255, 255, 255, 0.2); /* Sanfter Schimmer für bessere Lesbarkeit */
}

#win-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    z-index: 3000;
    visibility: hidden;
    opacity: 0;
}

.win-message {
    background: linear-gradient(135deg, #ffd700, #ff8c00);
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.8);
    max-width: 80%;
    font-size: 24px;
    font-family: "fontRetroGaming", sans-serif;
    color: #fff;
    text-shadow: 2px 2px 10px rgba(0, 0, 0, 0.5);
    animation: pulse 1.5s infinite alternate ease-in-out;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    100% {
        transform: scale(1.05);
    }
}

.win-button {
    display: inline-block;
    margin-top: 20px;
    padding: 15px 30px;
    background: #4caf50;
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-size: 20px;
    font-weight: bold;
    box-shadow: 0px 5px 15px rgba(0, 255, 0, 0.5);
    transition: all 0.3s ease-in-out;
}

.win-button:hover {
    background: #3e8e41;
    transform: scale(1.1);
}

/* Back-Button: immer oben rechts, kreisförmig, mit Hover-Effekt */
#back-button {
    position: fixed;
    top: 10px;
    right: 10px;
    z-index: 2000; /* höher als das Overlay (welches z-index: 1000 hat) */
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 50%;
    background-color: #333;
    color: #fff;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

/* Hover-Effekt: Hintergrundfarbe ändern und leicht skalieren */
#back-button:hover {
    background-color: #555;
    transform: scale(1.1);
    transition: ease-in-out 0.2s;
}
