body.pong-background {
    background: url('/media/images/games/pong/Pilz-Wald_01__Background.png') no-repeat center center fixed;
    background-size: cover;
    color: #fff;
    margin: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 100vh; /* Ensures the body takes the full height of the viewport */
}

header {
    width: 100%;
    text-align: center;
    position: fixed; /* Changed from absolute to fixed to keep it at the top */
    top: 0;
    left: 0;
    z-index: 10;
    background-color: #000;
    padding: 20px 0;
}

header h1 {
    font-size: 4em; /* Larger title */
    margin: 0;
}

nav ul {
    list-style-type: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
    font-size: 1.5em; /* Increased font size */
}

nav ul li {
    margin: 0 15px;
}

nav ul li a {
    color: #fff;
    text-decoration: none;
    padding: 10px 20px;
    border-radius: 5px;
    transition: background-color 0.3s;
}

nav ul li a:hover {
    background-color: #444;
}

.game-button a {
    color: gold;
}

section {
    width: 80%;
    max-width: 1200px;
    margin: 20px 0;
}

h2 {
    font-size: 2.5em;
    margin: 10px 0;
}

footer {
    width: 100%;
    text-align: center;
    position: fixed; /* Changed from absolute to fixed to keep it at the bottom */
    bottom: 0;
    left: 0;
    z-index: 10;
    background-color: #000;
    padding: 20px 0;
}

/* Styles specific to the game */
#game-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex-grow: 1;
    position: relative;
    width: 100%;
    max-width: 1120px;
    margin: auto; /* Center the game container */
    padding-top: 100px; /* Adjust padding to avoid overlap with header */
}

.scoreboard {
    width: 100%;
    max-width: 1120px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #000;
    border: 1px solid #fff;
    padding: 10px 0;
    margin-bottom: 20px;
}

.scoreboard .cpu-score,
.scoreboard .player-score {
    color: #0095DD; /* Blue color for CPU and Player labels */
    font-size: 2.5em;
    font-weight: bold;
    padding-left: 30px; /* Padding to give space from the edge */
    padding-right: 30px; /* Padding to give space from the edge */
}

.scoreboard .cpu-score span,
.scoreboard .player-score span,
.scoreboard .game-time {
    color: #fff; /* White color for scores and game time */
}

.scoreboard .game-time {
    text-align: center;
    flex: 1;
    font-size: 2.5em; /* Match size with the scores */
}

canvas {
    background: #000;
    border: 1px solid #fff; /* Add border to canvas */
    width: 100%; /* Ensure the canvas is responsive */
    height: auto; /* Maintain aspect ratio */
}

.game-over {
    display: none;
    font-size: 2.25rem; /* Fixed font size in rem */
    text-align: center;
    color: #ff0000;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.highscore-entry {
    display: none;
    text-align: center;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.highscore-entry input {
    font-size: 1rem; /* Fixed font size in rem */
    text-align: center;
    width: 3em;
}

.start-button {
    position: relative;
    top: 10px;
    width: 60%;
    padding: 10px 0;
    font-size: 1.5rem; /* Fixed font size in rem */
    cursor: pointer;
    background-color: #0095DD;
    border: none;
    border-radius: 0;
    color: white;
    text-align: center;
    margin-top: 10px;
}

@media (max-width: 768px) {
    header h1 {
        font-size: 1.75rem; /* Anpassung für kleinere Bildschirme */
    }

    nav ul {
        font-size: 1.5rem; /* Anpassung für kleinere Bildschirme */
    }

    .scoreboard {
        flex-direction: column;
        align-items: center;
    }

    .scoreboard .cpu-score,
    .scoreboard .player-score {
        padding-left: 0;
        padding-right: 0;
        text-align: center;
    }

    .scoreboard .game-time {
        margin: 1em 0;
    }

    .start-button {
        width: 80%; /* Increase width for smaller screens */
        font-size: 1.25rem; /* Anpassung für kleinere Bildschirme */
    }
}
