body {
    overflow: hidden;
    font-family: 'Montserrat', sans-serif;
    transition: transform 0.5s ease;
    background-color: #F6F6F6;
    padding: 0;
    margin: 0;
}

p {
    text-align: center;
}

a{
    text-decoration: none;
}

h1 {
    text-align: center;
    padding: 0;
    margin: 0;
}


#counter{
    width: 100%;
    text-align: right;
}

.main_wrapper {
    position: absolute;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100%;
    min-width: 100%;
    flex-direction: row;
    gap: 5vw;
}

.main_wrapper > * {
    min-height: 40vh;
}

.secondary_wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 60vw;
    gap: 2vh;
    flex-direction: column;
    background-color: #F6F6F6;
    border-radius: 2rem;
    border: solid #393939 .2rem;
    padding: 2rem;
    
    /* Animation für die Karte selbst */
    opacity: 0;
    animation: cardPop 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.auswertung_wrapper {
    display: flex;
    align-items: center;
    /* Ändere justify-content zu flex-start, damit der Text oben beginnt */
    justify-content: flex-start;
    min-width: 60vw;
    max-width: 90vw; /* Damit es auf kleinen Screens nicht zu breit wird */
    gap: 2vh;
    flex-direction: column;
    background-color: #F6F6F6;
    padding: 2rem;
    opacity: 0;
    animation: cardPop 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;

    /* Wichtig: Falls der Inhalt zu lang wird */
    overflow-y: auto;
    max-height: 90vh;
    padding-bottom: 4rem;
}


/* --- BUTTON STYLING & INTERACTION --- */
.button {
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #393939;
    border-radius: .5rem;
    color: #F6F6F6;
    min-height: 5vh;
    min-width: 10vw;
    cursor: pointer; /* Zeigt die Hand als Mauszeiger */
    
    /* Wichtig für die Hover-Animation */
    transition: all 0.2s ease-in-out;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

/* Hover Effekt: Button wächst und hebt sich */
.button:hover {
    transform: translateY(-3px) scale(1.05);
    background-color: #505050; /* Etwas heller beim Hover */
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}

/* Klick Effekt: Button drückt sich rein */
.button:active {
    transform: translateY(1px) scale(0.98);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Spezieller Puls-Effekt nur für den Start Button */
/* Wir kombinieren hier zwei Animationen: Erst reinfliegen, dann pulsieren */
#start {
    animation: 
        fadeInUpSmooth 0.6s ease-out 0.9s forwards, /* Reinfliegen */
        pulseGlow 2s infinite 1.6s; /* Pulsieren (startet nachdem er reingeflogen ist) */
    opacity: 0; /* Startet unsichtbar wegen fadeInUpSmooth */
}


/* --- KEYFRAMES DEFINITIONEN --- */

/* Reinfliegen */
@keyframes fadeInUpSmooth {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Karten Pop-Up */
@keyframes cardPop {
    0% {
        opacity: 0;
        transform: scale(0.9);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

/* Pulsieren für Start Button */
@keyframes pulseGlow {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(57, 57, 57, 0.7);
    }
    70% {
        transform: scale(1.05);
        box-shadow: 0 0 10px 10px rgba(57, 57, 57, 0);
    }
    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(57, 57, 57, 0);
    }
}


/* --- SLIDER STYLING (BLAU-DESIGN) --- */

input[type="range"] {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    width: 40vw;
    background-color: transparent;
    cursor: pointer;
}

input[type="range"]:focus {
    outline: none;
}

/* 1. Die Schiene (Track) - Blau-Verlauf */
input[type="range"]::-webkit-slider-runnable-track {
    width: 100%;
    height: 3vh;
    cursor: pointer;
    background: linear-gradient(to right, rgba(48, 76, 137) 0%, rgb(100, 141, 229) 50%, rgba(48, 76, 137) 100%);
    border-radius: .5rem;
}

input[type="range"]::-moz-range-track {
    width: 100%;
    height: 3vh;
    cursor: pointer;
    background: linear-gradient(to right, rgba(48, 76, 137) 0%, rgb(100, 141, 229) 50%, rgba(48, 76, 137) 100%);
    border-radius: .5rem;
}

/* 2. Der Regler-Knopf (Thumb) - Kräftiges Blau */
input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    height: 2.5rem;
    width: 4rem;
    border-radius: .5rem;
    background: #648DE5; /* Das helle Blau */
    border: 2px solid #F6F6F6;
    cursor: grab;
    margin-top: -0.5rem; /* Zentriert den Thumb auf der Schiene */
    box-shadow: 0px 3px 6px rgba(0, 0, 0, 0.3);
    transition: transform 0.1s ease, background-color 0.2s;
}

input[type="range"]::-moz-range-thumb {
    height: 2.5rem;
    width: 4rem;
    border-radius: .5rem;
    background: #648DE5;
    border: 2px solid #F6F6F6;
    cursor: grab;
    box-shadow: 0px 3px 6px rgba(0, 0, 0, 0.3);
}

/* Interaktion beim Klicken */
input[type="range"]::-webkit-slider-thumb:active {
    cursor: grabbing;
    transform: scale(1.1);
    background-color: #4a76c9; /* Etwas dunkler beim Drücken */
}


/* --- ANTWORTEN TEXTE --- */

.antworten {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: row;
    gap: 0;
    padding: 0;
    margin: 0;
}

.antworten p {
    width: 9vw;
    font-size: clamp(.1rem, 1rem, 1rem);
}

/* --- STAGGERED LOAD LOGIC --- */

/* Alle Kinder in der Karte initial verstecken */
.secondary_wrapper > * {
    opacity: 0; 
    animation: fadeInUpSmooth 0.6s ease-out forwards;
}

/* Verzögerungen (Delays) */
.secondary_wrapper h1 { animation-delay: 0.3s; }
.secondary_wrapper p { animation-delay: 0.5s; }
.secondary_wrapper input[type="range"] { animation-delay: 0.5s; }
.secondary_wrapper .antworten { animation-delay: 0.7s; }

/* Button Delay (außer es ist #start, der hat eigene Regel oben) */
.secondary_wrapper .button:not(#start) { 
    animation-delay: 0.9s; 
}

/* Antwort-Texte einzeln animieren */
.antworten p {
    opacity: 0;
    animation: fadeInUpSmooth 0.5s ease-out forwards;
}

.antworten p:nth-child(1) { animation-delay: 0.8s; }
.antworten p:nth-child(2) { animation-delay: 0.9s; }
.antworten p:nth-child(3) { animation-delay: 1.0s; }
.antworten p:nth-child(4) { animation-delay: 1.1s; }
.antworten p:nth-child(5) { animation-delay: 1.2s; }
.antworten p:nth-child(6) { animation-delay: 1.4s; }

/* Entferne die festen Delays für die Kinder, wenn du willst, 
   dass alles gleichzeitig oder sehr schnell hintereinander kommt */
.secondary_wrapper > * {
    opacity: 0;
    animation: fadeInUpSmooth 0.6s ease-out forwards;
    animation-delay: 0.2s; /* Ein kleiner Delay nach dem Card-Pop */
}
/* --- AUSWERTUNG STYLES --- */

/* Container, damit der Text nicht zu breit wird und linksbündig ist */
.charts_container {
    width: 100%;
    max-width: 600px;
    margin-top: 2rem;
    text-align: left; /* Wichtig für Lesbarkeit */
}

/* Ein Block (Titel + Balken + Text) */
.result_section {
    margin-bottom: 2rem;
    /* Kleine Animation, damit die Ergebnisse nacheinander erscheinen */
    animation: fadeInUpSmooth 0.6s ease-out forwards;
}

/* Die Zeile über dem Balken (Name links, Prozent rechts) */
.label_row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
    color: #333;
}

/* Der graue Hintergrund des Balkens */
.bar_bg {
    width: 100%;
    height: 14px;
    background-color: #e0e0e0;
    border-radius: 7px;
    overflow: hidden;
    margin-bottom: 1rem;
    box-shadow: inset 0 1px 2px rgba(0,0,0,0.1);
}

/* Die farbige Füllung */
.bar_fill {
    height: 100%;
    /* Farbverlauf passend zu deinem blauen Design */
    background: linear-gradient(90deg, #304c89, #648de5);
    border-radius: 7px;
    transition: width 1s ease-in-out;
}

/* Der Text unter dem Balken */
.auswertung_text {
    font-size: 0.95rem;
    line-height: 1.6;
    color: #444;
    text-align: justify; /* Blocksatz sieht bei längeren Texten oft ruhiger aus */
}

/* Die Trennlinie */
.divider {
    border: 0;
    height: 1px;
    background: #ccc;
    margin-top: 1.5rem;
    opacity: 0.5;
}

/* Damit die Result-Sections etwas verzögert reinkommen (optional) */
.result_section:nth-child(1) { animation-delay: 0.1s; }
.result_section:nth-child(2) { animation-delay: 0.2s; }
.result_section:nth-child(3) { animation-delay: 0.3s; }
.result_section:nth-child(4) { animation-delay: 0.4s; }
.result_section:nth-child(5) { animation-delay: 0.5s; }
.quiz-header {
    position: absolute; /* Damit es über dem Content schwebt */
    top: 0;
    left: 0;
    width: 100%;
    padding: 1rem 2rem;
    box-sizing: border-box;
    z-index: 1000;
}

.logo-container {
    display: flex;
    justify-content: space-between; /* Verteilt die Logos nach links und rechts */
    align-items: center;
}

.logo-main {
    height: 50px; /* Höhe deines Logos anpassen */
    width: auto;
}

.logo-htl {
    height: 40px; /* Höhe des HTL Logos anpassen */
    width: auto;
}

/* Verhindert, dass der Content unter den Header rutscht */
.main_wrapper {
}