/* A shared reading layout for the psychologist's articles and exercises. */
.article-page .page-head { padding-top: 28px; padding-bottom: 36px; }
.article-page .page-head h1 { max-width: 800px; font-size: clamp(2rem, 3.4vw, 2.875rem); line-height: 1.16; letter-spacing: -.025em; color: var(--text-on-mint); margin-bottom: 0; text-wrap: pretty; }
.article-page .crumbs { line-height: 1.7; max-width: 800px; margin-bottom: 24px; }
.article-page .crumbs a { text-decoration: underline; text-decoration-color: var(--border); }
.article-layout { max-width: 1160px; margin: 0 auto; padding: 0 24px 80px; display: grid; grid-template-columns: minmax(0, 1fr) 248px; gap: clamp(40px, 6vw, 88px); align-items: start; }
.article-body { min-width: 0; max-width: 70ch; font-size: 1.0625rem; line-height: 1.8; overflow-wrap: break-word; }
.article-body p { margin: 0 0 1.15em; }
.article-body .article-lead { font-size: 1.25rem; line-height: 1.65; color: var(--text-on-mint); }
.article-intro { margin-bottom: 40px; }
.article-section { padding-top: 32px; margin-top: 36px; border-top: 1px solid var(--border); }
.article-section:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.article-section > :last-child { margin-bottom: 0; }
.article-body h2, .article-body h3 { font-family: Nunito, sans-serif; font-weight: 800; text-wrap: pretty; }
.article-body h2 { font-size: 1.75rem; line-height: 1.3; letter-spacing: -.015em; color: var(--text-on-mint); margin-bottom: 18px; }
.article-body h3 { font-size: 1.25rem; line-height: 1.4; margin: 32px 0 12px; }
.article-body h2:focus { outline: none; }
.article-body h2:focus-visible { outline: 2px solid var(--focus); outline-offset: 6px; border-radius: 4px; }
.article-body ul, .article-body ol { padding-left: 1.4em; margin: 12px 0 24px; }
.article-body li { padding-left: .25em; margin-bottom: 8px; }
.article-body li::marker { color: var(--leaf, #35634E); font-weight: 800; font-variant-numeric: tabular-nums; }
.article-body .article-label { margin: 24px 0 8px; }
.article-body .article-signature, .article-body .age-label { color: var(--text-soft); font-size: 1rem; }
.article-body .age-label { margin-top: -6px; font-weight: 700; }
.article-note { margin: 24px 0; padding: 20px 24px; border-radius: 12px; background: #E6F1E4; color: var(--text-on-mint); }
.article-note p { margin-bottom: 10px; }
.article-note > :last-child { margin-bottom: 0; }
.article-note > p:first-child:not(:last-child) { font-weight: 800; }
.article-body blockquote { margin: 0 0 20px; padding: 12px 0; color: var(--text-soft); font-style: italic; font-size: 1.1875rem; }
.article-body blockquote p { margin: 0; }
.article-body .article-image { margin: 24px 0; border-radius: 12px; }
.article-definitions { margin: 20px 0 28px; }
.article-definitions > div { padding: 14px 0; border-bottom: 1px solid var(--border); }
.article-definitions dt { font-weight: 800; color: var(--text-on-mint); }
.article-definitions dd { margin: 4px 0 0; }
.article-subsection { margin: 36px 0; }
.article-body .spaced-list li { padding-bottom: 12px; margin-bottom: 16px; border-bottom: 1px solid var(--border); }
.exercise-number { display: inline-block; min-width: 1.2em; margin-right: 8px; color: var(--red-deep); font-size: .85em; font-variant-numeric: tabular-nums; }
.matching-table { width: 100%; table-layout: fixed; border-collapse: collapse; margin: 24px 0; background: var(--surface); }
.matching-table th, .matching-table td { padding: 14px 18px; text-align: left; vertical-align: top; border: 1px solid var(--border); }
.matching-table th { background: #E6F1E4; color: var(--text-on-mint); font-weight: 800; }
.article-body .word-bank, .article-body .word-matrix { padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 10px; margin: 24px 0; }
.article-body .word-bank li { margin: 0; padding: 8px 14px; background: var(--surface); border: 1px solid var(--border); border-radius: 8px; }
.article-body .word-matrix { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; background: var(--surface); padding: 16px; border-radius: 12px; }
.article-body .word-matrix li { padding: 8px; margin: 0; }
.reading-sample { background: var(--surface); padding: 24px; border-radius: 12px; margin: 24px 0; font-size: 1.125rem; }
.reading-sample .verse { margin: 0; line-height: 1.95; }
.article-body .word-focus { margin: 24px 0; font-weight: 800; font-size: 1.75rem; color: var(--text-on-mint); letter-spacing: .08em; }
.syllable-grid { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 6px; margin: 24px 0; }
.syllable-grid > div { text-align: center; padding: 8px 2px; background: var(--surface); border-bottom: 2px solid var(--mint); }
.syllable-grid span, .syllable-grid strong { display: block; }
.syllable-grid span { font-size: .8125rem; color: var(--text-soft); }
.syllable-grid strong { font-size: 1.125rem; font-weight: 800; }
.acrostic p { margin: 0; line-height: 1.9; }
.acrostic strong { color: var(--red-deep); font-weight: 800; }
.exercise-answer { border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); margin: 20px 0; }
.exercise-answer summary, .article-toc-mobile summary { padding: 12px 0; min-height: 48px; color: var(--text-on-mint); font-weight: 800; cursor: pointer; touch-action: manipulation; }
.exercise-answer summary::marker, .article-toc-mobile summary::marker { color: var(--leaf, #35634E); }
.answer-content { padding: 4px 0 8px; }
.answer-content > :last-child { margin-bottom: 8px; }
.article-sidebar { position: sticky; top: calc(var(--header-height, 100px) + 24px); min-width: 0; }
.article-toc { border-top: 2px solid var(--mint); padding-top: 18px; }
.toc-title { font-size: 1rem; font-weight: 800; color: var(--text-on-mint); margin: 0 0 12px; }
.toc-list { margin: 0; padding: 0; list-style: none; }
.article-toc .toc-list { max-height: calc(100dvh - var(--header-height, 100px) - 110px); overflow-y: auto; scrollbar-width: thin; scrollbar-color: var(--mint) transparent; }
.toc-list a { display: flex; align-items: center; min-height: 44px; padding: 8px 10px 8px 0; font-size: .9375rem; line-height: 1.45; text-decoration: none; color: var(--text-soft); border-bottom: 1px solid var(--border); }
.toc-list a:hover, .toc-list a:focus-visible { color: var(--red-deep); text-decoration: underline; }
.article-toc-mobile { display: none; }
.article-end { border-top: 1px solid var(--border); margin-top: 48px; padding-top: 24px; }
.article-end a, .article-contact { display: inline-flex; align-items: center; min-height: 44px; color: var(--red-deep); font-weight: 800; }
@media (max-width: 1000px) {
  .article-page .page-head, .article-layout { max-width: 760px; }
  .article-layout { display: block; }
  .article-sidebar { display: none; }
  .article-toc-mobile { display: block; border-block: 1px solid var(--border); margin-bottom: 32px; }
  .article-toc-mobile nav { padding: 0 0 20px; }
  .article-toc-mobile .toc-list { columns: 2; column-gap: 24px; }
  .article-toc-mobile li { break-inside: avoid; }
}
@media (max-width: 560px) {
  .article-page .page-head { padding: 24px 20px 24px; }
  .article-page .crumbs { margin-bottom: 18px; font-size: .8125rem; }
  .article-layout { padding: 0 20px 56px; }
  .article-body { font-size: 1rem; line-height: 1.75; }
  .article-body .article-lead { font-size: 1.125rem; }
  .article-body h2 { font-size: 1.5rem; }
  .article-body h3 { font-size: 1.125rem; }
  .article-section { padding-top: 28px; margin-top: 32px; }
  .article-note, .reading-sample { padding: 18px; }
  .matching-table th, .matching-table td { padding: 12px; }
  .article-body .word-bank { gap: 8px; }
  .article-body .word-bank li { padding: 6px 10px; }
  .article-body .word-matrix { padding: 8px; }
  .article-body .word-matrix li { padding: 8px 4px; font-size: .9375rem; }
  .syllable-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .article-toc-mobile .toc-list { columns: 1; }
}
@media print {
  .article-sidebar, .article-toc-mobile, .article-end { display: none; }
  .article-layout { display: block; padding: 0; }
  .article-body { max-width: none; font-size: 11pt; }
  .article-section h2, .article-body h3 { break-after: avoid; }
  .matching-table, .reading-sample, .syllable-grid { break-inside: avoid; }
}
