.example-quiz {
    /* --example-quiz-background: #f8fbff;
    --example-quiz-border-color: #d6e4f0;
    --example-quiz-title-background: #eef6ff;
    --example-quiz-title-color: #1f2937; */

    --example-quiz-background: #fafafa;
    --example-quiz-border-color: #d6e4f0;
    --example-quiz-title-background: #fafafa;
    --example-quiz-title-color: #1f2937;

    background: var(--example-quiz-background);
    border: 1px solid var(--example-quiz-border-color);
    border-radius: 6px;
    margin: 24px 0;
    overflow: hidden;
}

.example-quiz-title {
    margin: 0;
}

.example-quiz-toggle-control {
    opacity: 0;
    position: absolute;
}

.example-quiz-toggle-control:focus + .example-quiz-title .example-quiz-toggle {
    /* outline: 2px solid #80bdff; */
    outline: none;
    outline-offset: -2px;
}

.example-quiz-toggle {
    align-items: center;
    background: var(--example-quiz-title-background);
    border: 0;
    color: var(--example-quiz-title-color);
    cursor: pointer;
    display: flex;
    font: inherit;
    justify-content: space-between;
    padding: 14px 16px;
    text-align: left;
    width: 100%;
}

.example-quiz-toggle-icon {
    flex: 0 0 auto;
    font-weight: 700;
    margin-left: 12px;
}

.example-quiz-toggle-icon::before {
    content: "▼";
}

.example-quiz-toggle-control:checked + .example-quiz-title .example-quiz-toggle-icon::before {
    content: "▲";
}

.example-quiz-panel {
    display: none;
    /* padding: 16px; */
    padding: 16px 16px 16px 0;
}

.example-quiz-toggle-control:checked ~ .example-quiz-panel {
    display: block;
}

.example-quiz-list {
    display: grid;
    gap: 12px;
    list-style: none;
    margin: 0;
    padding-left: 0;
}

.example-quiz-item {
    display: grid;
    gap: 8px;
    grid-template-columns: max-content 20px minmax(0, 1fr);
    line-height: 1.7;
    align-items: baseline;
}

.example-quiz-number {
    font-weight: 700;
    min-width: 2.4em;
    text-align: right;
}

.example-quiz-reveal-answer {
    cursor: pointer;
    height: 16px;
    justify-self: center;
    margin-top: 8px;
    width: 16px;
}

.example-quiz-reveal-answer:disabled {
    cursor: not-allowed;
    opacity: 0.55;
}

.example-quiz-sentence {
    overflow-wrap: anywhere;
}

.example-quiz-input {
    border: 1px solid #ced4da;
    border-radius: 4px;
    display: inline-block;
    margin: 0 4px;
    min-height: 34px;
    padding: 4px 9px;
    vertical-align: baseline;
    width: clamp(120px, var(--example-quiz-answer-ch, 12ch), 280px);
}

.example-quiz-input:focus {
    border-color: #80bdff;
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.15);
    outline: 0;
}

.example-quiz-item.is-correct .example-quiz-input {
    border-color: #28a745;
}

.example-quiz-item.is-wrong .example-quiz-input {
    border-color: #dc3545;
}

.example-quiz-input.is-answer-revealed {
    color: #dc3545;
    font-weight: 700;
}

.example-quiz-status {
    display: inline-block;
    font-weight: 700;
    min-width: 20px;
    text-align: center;
}

.example-quiz-item.is-correct .example-quiz-status {
    color: #28a745;
}

.example-quiz-item.is-wrong .example-quiz-status {
    color: #dc3545;
}

.example-quiz-results {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 24px 0;
}

.example-quiz-result-summary {
    font-weight: 700;
}

.example-quiz-result-correct {
    color: #28a745;
}

.example-quiz-result-wrong {
    color: #dc3545;
}

.example-quiz-result-unanswered {
    color: #6c757d;
}

.example-quiz-result-total {
    color: #007bff;
}

.example-quiz-result-separator {
    color: #6c757d;
}

@media (max-width: 640px) {
    .example-quiz-input {
        max-width: calc(100vw - 96px);
    }
}
