/* Additive styles: the supplied page layouts and colour palette remain intact. */
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body { overflow-wrap: break-word; }
button, input, summary { font-family: inherit; }
button:disabled { opacity: .6; cursor: default; }
a:focus-visible, button:focus-visible, input:focus-visible, summary:focus-visible { outline: 3px solid #123c69; outline-offset: 3px; }
.skip-link { position: absolute; left: 18px; top: -100px; z-index: 50; padding: 10px 16px; background: #17233c; color: white; border-radius: 8px; }
.skip-link:focus { top: 10px; }
.learning-layout { grid-template-columns: 270px minmax(0, 1fr); }
.content, .card, .quiz-card { min-width: 0; }
.logo { white-space: nowrap; }
.chapter { line-height: 1.45; }
.chapter-source-link { margin: -17px 0 27px; font-size: 14px; }
.chapter-source-link a, .source-panel a, .question-sources a, .references-group a, .reference-nav a { color: #117268; text-underline-offset: 3px; }
.intro p + p, .lesson-text p + p, #goodToKnow p + p { margin-top: 12px; }
.lesson-text ul, .lesson-text ol, #goodToKnow ul, #goodToKnow ol { padding-left: 24px; margin: 12px 0; }
.lesson-text li, #goodToKnow li { margin-bottom: 8px; }
.lesson-text h3 { font-size: 19px; color: #17233c; margin: 22px 0 10px; }
#goodToKnow p { margin: 10px 0; }
#goodToKnow p:first-child { margin-top: 0; }
#goodToKnow li:last-child { margin-bottom: 0; }
.faq-item summary { list-style: none; gap: 16px; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: '+'; flex: 0 0 16px; }
.faq-item[open] summary::after { content: '\2212'; }
.faq-item[open] .faq-answer { display: block; }
.faq-answer p + p { margin-top: 10px; }
.source-panel { background: white; border: 1px solid #e3e7eb; border-radius: 12px; margin-top: 24px; padding: 0 22px; }
.source-panel > summary { cursor: pointer; color: #117268; font-size: 15px; font-weight: 700; padding: 18px 0; }
.source-list { list-style: none; padding: 0; margin: 0; }
.source-list li { margin-bottom: 16px; }
.source-list .source-description { display: block; margin-top: 4px; color: #667085; font-size: 14px; font-weight: normal; }
.source-note { font-size: 13px; color: #667085; font-weight: normal; margin: 14px 0; }
.question-sources { font-size: 13px; font-weight: normal; margin-top: 14px; }
.question-sources a { display: inline-block; margin: 4px 12px 0 0; }
.answer-option { display: flex; align-items: baseline; gap: 10px; }
.answer-option input { flex: 0 0 auto; margin: 0; accent-color: #16857b; }
.answer-option.selected { background: #e9f5f3; border-color: #16857b; }
.answer-option:has(input:disabled) { cursor: default; }
#feedback p { margin-top: 8px; }
.content-note { border-left: 3px solid #16857b; background: #f0f7f6; border-radius: 6px; padding: 12px 16px; color: #475467; font-size: 14px; margin: 12px 0 20px; }
.timer-warning, .timeout-note { background: #fff8ea; border: 1px solid #ecd3a0; color: #73510d; padding: 13px 16px; margin: 15px 0 22px; border-radius: 9px; }
.timer-warning.urgent { background: #fff0e6; color: #9a3412; }
.app-error { color: #9a3412; border: 1px solid #e1b69c; background: #fff8f2; padding: 16px; margin-bottom: 24px; border-radius: 10px; }
.site-footer { background: white; border-top: 1px solid #e7e9ed; padding: 25px 20px; color: #667085; font-size: 13px; text-align: center; }
.site-footer p + p { margin-top: 6px; }
.site-footer a { color: #117268; text-underline-offset: 3px; }
.references-group { background: white; border: 1px solid #e3e7eb; border-radius: 16px; padding: 28px; margin-top: 24px; scroll-margin-top: 20px; }
.references-group h2 { font-size: 23px; margin-bottom: 22px; line-height: 1.35; }
.reference-nav { display: flex; flex-direction: column; gap: 8px; margin-top: 22px; }
.reference-nav a { margin-left: 0; font-size: 15px; }
.topic-row { gap: 18px; align-items: baseline; }
.topic-row strong { white-space: nowrap; }
.weak-areas li + li { margin-top: 10px; }
.weak-areas a { color: #117268; }
.result-heading h1 { outline-offset: 8px; }
dialog { width: min(520px, calc(100vw - 32px)); margin: auto; border: 1px solid #dfe5e8; border-radius: 16px; padding: 28px; color: #17233c; }
dialog h2 { margin-bottom: 14px; }
dialog::backdrop { background: rgba(23,35,60,.4); }
.dialog-buttons { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
@media (max-width: 850px) {
 .learning-layout { grid-template-columns: minmax(0, 1fr); }
 header .navbar { flex-wrap: wrap; gap: 12px; }
 header nav { display: flex; flex-wrap: wrap; gap: 10px 18px; }
 header nav a { margin-left: 0; }
 .content { max-width: none; }
 .sidebar { padding: 20px; }
 .chapter { margin-bottom: 4px; }
 .reference-nav { display: flex; }
}
@media (max-width: 480px) {
 h1 { overflow-wrap: anywhere; }
 .test-header { align-items: flex-start; gap: 10px; }
 .timer { flex-shrink: 0; }
 .question-jump { min-width: 39px; }
 .topic-result { gap: 12px; }
 .quiz-card, .card { padding: 22px; }
 .source-panel { padding: 0 17px; }
 .references-group { padding: 24px; }
}
@media (prefers-reduced-motion: reduce) {
 html { scroll-behavior: auto; }
 *, *::before, *::after { transition: none !important; animation: none !important; }
}
/* Programmatic heading focus announces navigation without outlining entire cards. */
[tabindex="-1"]:focus { outline: none; }
.disclaimer a { color: #73510d; text-underline-offset: 3px; }
