/* Minimal Quiz – theme‑adaptive, 100% width on mobile, 85% on desktop */

.minimal-quiz-container {
    width: 100%;           /* pełna szerokość na urządzeniach mobilnych */
    margin: 0 auto;
    padding: clamp(1em, 4vw, 2em);
    box-sizing: border-box;
}

/* Desktop: 85% szerokości */
@media screen and (min-width: 769px) {
    .minimal-quiz-container {
        width: 85%;
    }
}

/* Zgoda */
.quiz-consent {
    text-align: center;
    padding: 2em 1em;
}
.quiz-consent p {
    margin-bottom: 1.5em;
    font-size: inherit;
}
.quiz-consent button {
    margin: 0.5em;
    padding: 0.6em 1.4em;
    border: 1px solid currentColor;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    font-size: 1rem;
    min-width: 8em;
    background: transparent;
    color: inherit;
    transition: filter 0.2s;
}
.quiz-consent button:hover {
    filter: brightness(0.9);
}

/* Postęp i pytanie */
.quiz-progress {
    font-size: 0.9rem;
    margin-bottom: 1.2em;
}
.quiz-question {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 1.5em;
    line-height: 1.4;
}

/* Odpowiedzi */
.quiz-answers {
    list-style: none;
    padding: 0;
    margin: 0 0 1.5em 0;
}
.quiz-answer-item {
    margin-bottom: 0.6em;
}
.quiz-answer-btn {
    display: block;
    width: 100%;
    text-align: left;
    background: transparent;
    border: 1px solid currentColor;
    border-radius: 6px;
    padding: 0.75em 1em;
    font-size: 1rem;
    color: inherit;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
    line-height: 1.4;
    word-break: break-word;
}
.quiz-answer-btn:hover:not(:disabled) {
    background: rgba(128,128,128,0.08);
}

/* Wybrana odpowiedź (przed sprawdzeniem) */
.quiz-answer-btn.selected {
    border-width: 2px;
    font-weight: 600;
}

/* Poprawna odpowiedź */
.quiz-answer-btn.correct {
    border-color: #4caf50 !important;
    background: rgba(76, 175, 80, 0.12);
    font-weight: 700;
}

/* Błędna odpowiedź */
.quiz-answer-btn.wrong {
    border-color: #f44336 !important;
    background: rgba(244, 67, 54, 0.12);
    font-weight: 700;
}

.quiz-answer-btn:disabled {
    opacity: 0.85;
    cursor: default;
}

/* Kontener przycisków nawigacyjnych */
.quiz-navigation {
    display: flex;
    justify-content: flex-end;
    margin-top: 1em;
    gap: 0.5em;
}

/* Przyciski nawigacyjne (Dalej, Zakończ) i reset */
.quiz-next-btn,
.quiz-reset-btn {
    padding: 0.7em 1.8em;
    border: 1px solid currentColor;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    font-size: 1rem;
    min-width: 6em;
    text-align: center;
    background: transparent;
    color: inherit;
    transition: background 0.2s;
    margin: 0;
}
.quiz-next-btn:hover,
.quiz-reset-btn:hover {
    background: rgba(128,128,128,0.1);
}
.quiz-next-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Objaśnienie */
.quiz-explanation {
    margin-top: 1.2em;
    padding: 1em;
    border-left: 4px solid currentColor;
    font-size: 0.95rem;
    background: transparent;
    border-radius: 4px;
    line-height: 1.5;
}

/* Wyniki */
.quiz-results {
    text-align: center;
}
.quiz-score {
    font-size: 1.3rem;
    margin: 1.2em 0;
    font-weight: 600;
}
.quiz-results .quiz-reset-btn {
    display: inline-block;
    margin-top: 0.5em;
}

/* RWD – Mobile */
@media screen and (max-width: 480px) {
    .minimal-quiz-container {
        padding: 1em;
    }
    .quiz-consent button {
        display: block;
        width: 100%;
        margin: 0.5em 0;
    }

    .quiz-navigation {
        flex-direction: column;
    }
    .quiz-navigation .quiz-next-btn {
        width: 100%;
    }

    .quiz-answer-btn {
        padding: 0.7em 0.8em;
    }
}