/* Long-form article, hub and printable pages. Class vocabulary is fixed by docs/CONTENT_PLAN.md section 3.2. */
/* The card spans the full container (same box as .site-nav); only running text keeps a readable measure. */
.article-body { max-width: none; line-height: 1.85; }
.article-body > :where(p, ul, ol, h2, h3, blockquote, dl, .callout, figure, details),
.article-body > div > :where(p, ul, ol, h2, h3, blockquote, dl, .callout, figure, details) { max-width: 72ch; }
.article-body > h2, .article-body > div > h2 { padding-top: 1.1em; border-top: 1px solid var(--color-border-subtle); }
.article-body > h2:first-of-type { border-top: 0; }
.article-body h1 + .lede { margin-top: 0; }
.article-body h2 { margin: 2.2em 0 .6em; }
.article-body h3 { margin: 1.6em 0 .5em; }
.article-body p + p { margin-top: .9em; }
.article-body a:not(.play-link):not(.card-link):not(.qc-btn) { color: var(--link-ink); text-underline-offset: 3px; }
.article-body a:not(.play-link):not(.card-link):focus-visible { outline: 3px solid var(--accent-blue); outline-offset: 2px; border-radius: 3px; }
.article-byline { margin: 14px 0 0; padding-bottom: 18px; border-bottom: 1px solid var(--color-border-subtle); color: var(--text-muted); font-size: .82rem; line-height: 1.7; max-width: none !important; }
.article-byline a { color: inherit; }

.callout { margin: 1.6em 0; padding: 16px 20px; line-height: 1.8; border-left: 4px solid var(--accent-blue); border-radius: var(--radius-sm); background: color-mix(in srgb, var(--accent-blue) 8%, transparent); }
.callout > :first-child { margin-top: 0; }
.callout > :last-child { margin-bottom: 0; }
.callout-note { border-left-color: var(--accent-emerald); background: color-mix(in srgb, var(--accent-emerald) 8%, transparent); }
.callout-caution { border-left-color: var(--accent-amber); background: color-mix(in srgb, var(--accent-amber) 10%, transparent); }

figure.rule-diagram { margin: 1.8em auto; max-width: 420px; text-align: center; }
figure.rule-diagram svg { display: block; width: 100%; height: auto; color: var(--text-primary); }
figure.rule-diagram figcaption { margin-top: 8px; color: var(--text-secondary); font-size: .85rem; line-height: 1.6; }

.table-scroll { margin: 1.6em 0; overflow-x: auto; -webkit-overflow-scrolling: touch; max-width: 100%; scrollbar-color: var(--color-border) transparent; }
.table-scroll:focus-visible { outline: 3px solid var(--accent-blue); outline-offset: 2px; }
table.data-table, table.schedule-table { width: 100%; border-collapse: collapse; font-size: .92rem; }
table.data-table th, table.data-table td,
table.schedule-table th, table.schedule-table td { padding: 9px 12px; border: 1px solid var(--color-border); text-align: left; vertical-align: top; line-height: 1.6; }
table.data-table th, table.schedule-table th { background: var(--color-surface-hover); color: var(--text-primary); white-space: nowrap; }
table.data-table tbody tr:nth-child(even) td, table.schedule-table tbody tr:nth-child(even) td { background: color-mix(in srgb, var(--text-primary) 3%, transparent); }
table.data-table td, table.schedule-table td { font-variant-numeric: tabular-nums; }
table.data-table td:first-child, table.schedule-table td:first-child { white-space: nowrap; }
table.data-table caption, table.schedule-table caption { margin-bottom: 8px; text-align: left; font-weight: 700; }
table.schedule-table td[data-min] { white-space: nowrap; font-variant-numeric: tabular-nums; }

dl.lesson-meta { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 8px 18px; margin: 1.6em 0; padding: 16px 20px; border: 1px solid var(--color-border); border-radius: var(--radius-md); }
dl.lesson-meta dt { color: var(--text-primary); font-weight: 800; }
dl.lesson-meta dd { margin: 0; color: var(--text-secondary); }

blockquote.teacher-script { margin: 1.4em 0; padding: 12px 18px; border-left: 4px solid var(--accent-purple); background: color-mix(in srgb, var(--accent-purple) 8%, transparent); color: var(--text-secondary); font-style: normal; }
blockquote.teacher-script p { margin: 0; }

section.worksheet { margin-top: 2em; padding: 20px 22px; border: 1px dashed var(--color-border); border-radius: var(--radius-md); }
section.print-sheet { margin-top: 2em; }

a.play-link { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; margin: 8px 8px 8px 0; padding: 10px 20px; border-radius: 999px; background: var(--color-primary-gradient); color: white; font-weight: 800; text-decoration: none; }
a.play-link:hover { box-shadow: var(--shadow-glow); transform: translateY(-1px); }
a.play-link:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent-blue) 45%, transparent); outline-offset: 3px; }

ol.source-list { padding-left: 22px; display: grid; gap: 6px; font-size: .88rem; word-break: break-all; }

.card-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin: 1.6em 0; }
.card-grid a.card-link { display: block; padding: 18px 20px; border: 1px solid var(--color-border); border-radius: var(--radius-md); background: var(--color-surface); color: inherit; text-decoration: none; }
.card-grid a.card-link { transition: border-color var(--transition-fast), box-shadow var(--transition-fast); }
.card-grid a.card-link:hover { border-color: var(--accent-blue); box-shadow: var(--shadow-glow); }
.card-grid a.card-link:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent-blue) 45%, transparent); outline-offset: 3px; }
.card-grid a.card-link h3 { margin: 0 0 6px; font-size: 1.05rem; color: var(--text-primary); }
.card-grid a.card-link p { margin: 0; font-size: .9rem; color: var(--text-secondary); }

/* Reserved for approved manual ad units; unused this round. */
.ad-slot { margin: 2em 0; min-height: 0; }

@media (max-width: 640px) {
    .card-grid { grid-template-columns: 1fr; }
    dl.lesson-meta { grid-template-columns: 1fr; gap: 2px; }
    dl.lesson-meta dd { margin-bottom: 8px; }
}

@media print {
    .app-background, .site-nav, .playbook-index, .site-static-footer, .seo-breadcrumb, .related-pages, .seo-information, .page-guide, .no-print, .ad-slot { display: none !important; }
    @page { size: A4; margin: 12mm; }
    body { background: #fff !important; color: #000 !important; }
    .content-page { width: 100%; margin: 0; padding: 0; }
    .article-body :where(p, ul, ol, h2, h3, blockquote, dl, figure, details) { max-width: none; }
    .article-body > h2 { border-top: 0; padding-top: 0; }
    .article-body, .content-page article { max-width: none; padding: 0; border: 0; box-shadow: none; background: #fff; color: #000; }
    .article-body *, .content-page article * { color: #000 !important; }
    body[data-content-kind="printable"] article > :not(.print-sheet) { display: none; }
    .worksheet { break-before: page; border-color: #000; }
    figure.rule-diagram svg, figure.rule-diagram svg * { stroke: currentColor; }
    figure.rule-diagram svg [fill]:not([fill="none"]) { fill: currentColor; }
    .callout, blockquote.teacher-script { background: none; border-left-color: #000; }
    table.data-table th, table.schedule-table th { background: #eee; }
}
