/* Mobile-first styles for small screens */

body {
    font-family: -apple-system, BlinkMacSystemFont, sans-serif;
    color: white;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 100vh; /* Ensure the body takes full viewport height */
    background-image: url("../img/gradient.png");
    background-repeat: no-repeat;
    background-size: cover;
}

header {
    background-color: #A7A3EFCC;
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    border-radius: 10px;
    margin: 3% auto;
    margin-bottom: 0;
    width: 80%; 
    
}

footer {
    background-color: #36009C;
    color: white;
    text-align: center;
    padding: 1em;
    width: 100%;
    position: relative; /* Footer is not fixed for small screens */
}

main {
    flex: 1;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 2% auto;
    margin-bottom: 80px;
    width: 80%;
}

h2 {
    color: white;
    text-align: center;
}

.header-content {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.soundwave {
    position: absolute;
    right: -1%; /* Verschiebt das Bild nach rechts außerhalb des Headers */
    top: 0; /* Positioniert das Bild am oberen Rand des Headers */ 
    width: 20%;
    z-index: 1; /* Stellt sicher, dass das Bild vor dem Header-Inhalt liegt */
}

.soundwave-down {
    position: absolute;
    bottom: 0;
    left: -1%; /* Abstand von der linken Seite */
    width: 20%;
    z-index: 1;
}

.question-container {
    width: 100%; /* Full width on mobile */
    background-color: #A7A3EFCC;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.answers {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.answers label {
    display: flex;
    align-items: center;
    font-size: 1.2em;
    color: white;
    margin-bottom: 15px;
    cursor: pointer;
}

/* Hide the default radio button */
.answers input[type="radio"] {
    display: none;
}

/* Custom radio button */
.answers label:before {
    content: "";
    display: inline-block;
    width: 25px;
    height: 25px;
    margin-right: 15px;
    border-radius: 50%;
    border: 2px solid white;
    background-color: transparent;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.answers input[type="radio"]:checked + label:before {
    background-color: white;
    border-color: white;
}

button {
    background-color: white;
    border: none;
    color: #273169;
    padding: 10px 32px;
    margin-top: 2%;
    border-radius: 15px;
    cursor: pointer;
    text-align: center;
}

button:hover {
    background-color: #273169;
    color: white;
}

.result-graphic {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.cd-image {
    width: 80px;
    height: auto;
    padding: 15px 0;
}

.chart-container {
    width: 100%; /* Full width on small screens */
    margin: 20px auto;
    text-align: center;
}

.correct {
    background-color: #28a745; /* Grün für richtig */
    color: white;
    padding: 10px;
    border-radius: 5px;
    text-align: center;
    margin-top: 10px;
}

.incorrect {
    background-color: #dc3545; /* Rot für falsch */
    color: white;
    padding: 10px;
    border-radius: 5px;
    text-align: center;
    margin-top: 10px;
}

/* Medium screens (e.g., tablets) */
@media (min-width: 600px) {
    main {
        width: 80%;
    }

    .cd-image {
        width: 100px;
    }

    header {
        width: 80%;
    }
}

/* Large screens (e.g., desktops) */
@media (min-width: 1024px) {
    header {
        width: 60%;
    }

    main {
        width: 60%;
    }

    footer {
        position: fixed; /* Fixed footer for larger screens */
        bottom: 0;
    }

    .chart-container {
        max-width: 600px;
    }
}
