/* Quiz spezifische Styles */

.quiz-header-section {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0 var(--page-padding);
    gap: 3rem;
    box-sizing: border-box; /* Hinzugefügt für Konsistenz */
}

/* Anpassung des Quiz-Headers an das Regelwerk-Design */
.quiz-header-content { /* Umbenannt von .quiz-header-content in .rules-header-content-quiz, um Konflikte zu vermeiden */
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-bottom: 2rem;
}

/* Neuer Stil für den Header-Icon im Quiz, ähnlich dem Regelwerk */
.quiz-header-content .header-icon {
    padding: 1.5rem;
    background: rgba(59, 130, 246, 0.1);
    border-radius: 1rem;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(59, 130, 246, 0.2);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

.quiz-header-content .header-icon i {
    font-size: 3rem;
    color: var(--accent-color);
    animation: pulse 2s ease-in-out infinite;
}

/* Neuer Stil für den Header-Text im Quiz, ähnlich dem Regelwerk */
.quiz-header-content .header-text {
    /* Flex-Container für Titel und Untertitel, wenn nötig */
}

.quiz-header-content .header-text .info-title {
    font-size: 3.5rem; /* Konsistent mit Regelwerk */
    font-weight: 700;
    font-style: italic;
    margin-bottom: 0.5rem;
    color: white; /* Sicherstellen, dass es weiß ist */
}

.quiz-header-content .header-subtitle {
    font-size: 1.5rem;
    color: var(--second-text-color);
    font-weight: 300;
}

/* Beschreibung für den Quiz-Header, ähnlich dem Regelwerk */
.quiz-header-description {
    max-width: 800px;
}

.quiz-header-description .description-text {
    font-size: 1.2rem;
    color: var(--second-text-color);
    line-height: 1.8;
    margin-bottom: 2rem;
}

/* Info-Box-Stil (existierte bereits, aber für den Kontext hier) */
.info-box {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1rem;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 1rem;
    backdrop-filter: blur(10px);
    margin-top: 2rem; /* <-- HIER WURDE DER ABSTAND HINZUGEFÜGT */
}

.info-box i {
    color: var(--accent-color);
    font-size: 1.5rem;
    margin-top: 0.2rem;
}

.info-content strong {
    color: #93c5fd;
    display: block;
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.info-content p {
    color: var(--second-text-color);
    margin: 0;
    line-height: 1.6;
    font-size: 1rem;
}

/* --- MODIFIZIERT --- */
.quiz-content-section {
    height: 100vh;
    padding: 4rem var(--page-padding);
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.quiz-screen {
    display: none;
    animation: fadeIn 0.5s ease-in-out;
    width: 100%;
}

.quiz-screen.active {
    display: block;
}

/* Start Screen */
.start-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 1rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 3rem;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.start-header {
    margin-bottom: 2rem;
}

.start-header i {
    font-size: 4rem;
    color: var(--accent-color);
    margin-bottom: 1rem;
    animation: bounce 2s ease-in-out infinite;
}

.start-header h2 {
    font-size: 2.8rem;
    color: white;
    font-weight: 700;
    font-style: italic;
}

.start-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.25rem;
    margin-bottom: 2.5rem;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.5rem;
}

.info-item i {
    color: var(--accent-color);
    font-size: 1.25rem;
}

.info-item span {
    color: var(--second-text-color);
    font-size: 1rem;
    text-transform: uppercase;
}

.difficulty-selection {
    margin-bottom: 2.5rem;
}

.difficulty-selection h3 {
    color: white;
    margin-bottom: 1.25rem;
    font-size: 1.35rem;
    font-style: italic;
}

.difficulty-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.difficulty-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 1.25rem;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.75rem;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--second-text-color);
    min-width: 120px;
    text-transform: uppercase;
}

.difficulty-btn:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(59, 130, 246, 0.5);
}

.difficulty-btn.active {
    background: rgba(59, 130, 246, 0.2);
    border-color: var(--accent-color);
    color: white;
}

.difficulty-btn i {
    font-size: 1.6rem;
}

.difficulty-btn span {
    font-weight: 600;
    font-size: 0.95rem;
}

.difficulty-btn small {
    font-size: 0.85rem;
    opacity: 0.8;
}

.btn-large {
    padding: 1.1rem 2.2rem;
    font-size: 1.05rem;
}

/* Quiz Progress */
.quiz-progress {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 0.75rem;
    padding: 1.25rem;
    margin-bottom: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.progress-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    color: white;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 1rem;
}

.progress-bar {
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--accent-color), var(--accent-color-darker));
    border-radius: 4px;
    transition: width 0.5s ease;
    width: 0%;
}

/* Question Card */
.question-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 1rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 2.5rem;
    max-width: 800px;
    margin: 0 auto;
}

.question-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    gap: 1rem;
}

.question-category {
    background: rgba(59, 130, 246, 0.2);
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: var(--accent-color);
    padding: 0.4rem 0.8rem;
    border-radius: 0.375rem;
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
}

.question-difficulty {
    padding: 0.4rem 0.8rem;
    border-radius: 0.375rem;
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
}

.difficulty-easy {
    background: rgba(16, 185, 129, 0.2);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: #10b981;
}

.difficulty-medium {
    background: rgba(245, 158, 11, 0.2);
    border: 1px solid rgba(245, 158, 11, 0.3);
    color: #f59e0b;
}

.difficulty-hard {
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #ef4444;
}

.question-text {
    font-size: 1.35rem;
    color: white;
    font-weight: 600;
    margin-bottom: 2rem;
    line-height: 1.6;
    font-style: italic;
}

.question-options {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 2rem;
}

.option-btn {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.1rem 1.35rem;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.75rem;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--second-text-color);
    text-align: left;
    width: 100%;
    font-size: 1.05rem;
    text-transform: uppercase;
}

.option-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(59, 130, 246, 0.5);
    transform: translateX(4px);
}

.option-btn.selected {
    background: rgba(59, 130, 246, 0.2);
    border-color: var(--accent-color);
    color: white;
}

.option-btn.correct {
    background: rgba(16, 185, 129, 0.2);
    border-color: #10b981;
    color: #10b981;
}

.option-btn.incorrect {
    background: rgba(239, 68, 68, 0.2);
    border-color: #ef4444;
    color: #ef4444;
}

.option-btn.disabled {
    cursor: not-allowed;
    opacity: 0.7;
}

.option-letter {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    font-weight: 700;
    font-size: 0.95rem;
    flex-shrink: 0;
}

.option-btn.selected .option-letter {
    background: var(--accent-color);
    color: white;
}

.option-btn.correct .option-letter {
    background: #10b981;
    color: white;
}

.option-btn.incorrect .option-letter {
    background: #ef4444;
    color: white;
}

.question-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.answer-feedback {
    margin-top: 1.5rem;
    padding: 1.25rem;
    border-radius: 0.75rem;
    border-left: 4px solid;
}

.feedback-correct {
    background: rgba(16, 185, 129, 0.1);
    border-color: #10b981;
    color: #10b981;
}

.feedback-incorrect {
    background: rgba(239, 68, 68, 0.1);
    border-color: #ef4444;
    color: #ef4444;
}

.feedback-title {
    font-weight: 700;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-transform: uppercase;
    font-size: 1.05rem;
}

.feedback-explanation {
    font-size: 1rem;
    line-height: 1.6;
}

/* Results Screen */
.results-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 1rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 3rem;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.results-header {
    margin-bottom: 2.5rem;
}

.results-icon {
    font-size: 4.5rem;
    margin-bottom: 1rem;
    animation: bounce 2s ease-in-out infinite;
}

.results-icon.excellent {
    color: #10b981;
}

.results-icon.good {
    color: var(--accent-color);
}

.results-icon.average {
    color: #f59e0b;
}

.results-icon.poor {
    color: #ef4444;
}

.results-header h2 {
    font-size: 2.8rem;
    color: white;
    font-weight: 700;
    margin-bottom: 1rem;
    font-style: italic;
}

.results-score {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    font-size: 1.6rem;
    font-weight: 700;
    text-transform: uppercase;
}

.score-percentage {
    color: var(--accent-color);
}

.result-stats {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.15rem;
    text-transform: uppercase;
}

.stat-item.correct {
    color: #10b981;
}

.stat-item.incorrect {
    color: #ef4444;
}

.results-message {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-bottom: 2rem;
    color: var(--second-text-color);
    font-size: 1.1rem;
    line-height: 1.6;
}

.results-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Responsive Design */
@media (max-width: 768px) {
    .quiz-header-content {
        flex-direction: column;
        text-align: center;
    }

    /* Anpassung des Titels für kleinere Bildschirme im Quiz */
    .quiz-header-content .header-text .info-title {
        font-size: 2.5rem; /* Konsistent mit Regelwerk Media Query */
    }

    .difficulty-buttons {
        flex-direction: column;
        align-items: center;
    }

    .difficulty-btn {
        width: 100%;
        max-width: 300px;
    }

    .result-stats {
        flex-direction: column;
        gap: 1rem;
    }

    .results-actions {
        flex-direction: column;
        align-items: center;
    }

    .results-actions .blue-button,
    .results-actions .gray-button {
        width: 100%;
        max-width: 300px;
    }
}

@media (max-width: 480px) {
    .quiz-content-section {
        padding: 2rem 1rem;
    }

    /* Anpassung des Titels für sehr kleine Bildschirme im Quiz */
    .quiz-header-content .header-text .info-title {
        font-size: 2rem; /* Konsistent mit Regelwerk Media Query */
    }

    .start-card,
    .question-card,
    .results-card {
        padding: 1.8rem;
    }

    .question-actions {
        flex-direction: column;
    }

    .question-actions .blue-button,
    .question-actions .gray-button {
        width: 100%;
    }
}