.article { max-width: 720px; padding-top: 2.5rem; color: #233b30; font-size: 1.125rem; line-height: 1.75; }
.article a, .blog-index a { color: #0d683e; text-underline-offset: 4px; }
.article nav, .eyebrow, .byline, figcaption, .sample-note, .editor-note, .excerpt-end { font-family: Arial, sans-serif; font-size: .85rem; }
.article nav span { margin: 0 .65rem; color: #83968a; }
.article header { margin: 3.5rem 0 1.5rem; }
.eyebrow { text-transform: uppercase; letter-spacing: .1em; color: #526c5a; }
.article h1 { font-size: clamp(2.1rem, 6vw, 3.25rem); line-height: 1.12; letter-spacing: -.025em; margin: .8rem 0; }
.subtitle { font-size: 1.35rem; margin: 1rem 0; }
.byline { color: #526c5a; }
.sample-note { padding: 1rem 1.2rem; background: #f3f6f0; border-left: 3px solid #65816c; }
.contents { display: flex; flex-direction: column; margin: 2rem 0 3rem; gap: .3rem; }
.article h2 { font-size: 1.8rem; line-height: 1.25; margin: 2.8rem 0 1.25rem; }
.article section { scroll-margin-top: 2rem; }
.article p { margin: 1.25rem 0; }
.article figure { margin: 2rem 0; }
.article figure img { display: block; width: 100%; height: auto; }
.article .small-figure { max-width: 530px; }
.article figcaption { margin-top: .75rem; color: #587060; }
.article code { font-size: .85em; background: #f0f4ed; padding: .1em .25em; border-radius: 3px; }
.equation { text-align: center; font-size: clamp(.95rem, 3vw, 1.35rem); padding: 1.4rem .4rem; background: #f6f8f3; }
.editor-note { margin: 1.5rem 0; color: #526353; }
.editor-note summary { cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.article blockquote { margin: 2rem 0; padding: .4rem 0 .4rem 1.25rem; border-left: 3px solid #66816a; font-size: 1.5rem; line-height: 1.45; }
.steps li { padding-left: .3rem; }
.tradeoffs { display: grid; grid-template-columns: 1fr 1fr; gap: 0 2rem; margin: 2rem 0; }
.tradeoffs div { padding: 1rem 0; border-top: 1px solid #d8e2d7; }
.tradeoffs dt { font-weight: bold; font-size: 1.2rem; }
.tradeoffs dd { margin: .3rem 0 0; }
.excerpt-end { border-top: 1px solid #d8e2d7; margin-top: 3rem; padding-top: 1rem; }
.blog-index { line-height: 1.6; }
.blog-index h1 { font-size: 2.5rem; }
.blog-entry { border-top: 1px solid #d8e2d7; padding-top: 1rem; margin-top: 2rem; }
.blog-entry h2 { font-size: 1.6rem; line-height: 1.3; }
@media (max-width: 480px) { .article { padding: 1.75rem 1.25rem; } .article header { margin-top: 2.5rem; } .tradeoffs { grid-template-columns: 1fr; } }

/* Long-form article: equations, tables, and original drawings. */
.article h3 { font-size: 1.35rem; line-height: 1.4; margin: 2rem 0 .75rem; }
.article figure a { display: block; }
.article figure a:focus-visible { outline: 3px solid #0d683e; outline-offset: 5px; }
.table-wrap { overflow-x: auto; margin: 2rem 0; }
.article table { width: 100%; border-collapse: collapse; font-size: 1rem; text-align: left; }
.article caption { text-align: left; font-size: .85rem; color: #526c5a; margin-bottom: .7rem; font-family: Arial, sans-serif; }
.article th, .article td { padding: .7rem .8rem; border-bottom: 1px solid #d8e2d7; vertical-align: top; }
.article thead { background: #f3f6f0; }
.article pre { overflow-x: auto; padding: 1rem; background: #f3f6f0; font-size: .85rem; line-height: 1.65; }
.article pre code { padding: 0; background: none; font-size: inherit; }
.article .equation { overflow-wrap: anywhere; }
.memory-equation { font-size: 1.05rem; }
.article :target { scroll-margin-top: 1.5rem; }
@media (max-width: 480px) { .article th, .article td { padding: .55rem; } }

/* Optional text equivalents keep handwritten figures first. */
.article .diagram-text { margin: -1rem 0 2rem; font-size: 1rem; }
.diagram-text summary { cursor: pointer; color: #526353; font: .85rem/1.6 Arial, sans-serif; text-decoration: underline; text-underline-offset: 3px; }
.diagram-text summary:focus-visible { outline: 2px solid #0d683e; outline-offset: 4px; }
.article .diagram-text[open] { padding-bottom: .75rem; border-bottom: 1px solid #d8e2d7; }

/* A short chapter at a time, with a full-article fallback. */
[hidden] { display: none !important; }
.chapter-links { display: grid; gap: .5rem; margin: 2rem 0; }
.chapter-links a { display: flex; gap: .6rem; }
.reader-controls { position: sticky; top: 0; z-index: 5; padding: .85rem 0; margin-top: 1.5rem; background: #fff; border-bottom: 1px solid #d8e2d7; }
.reader-toolbar { display: flex; align-items: center; gap: .65rem; font: .85rem/1.4 Arial, sans-serif; }
.reader-toolbar select { flex: 1; min-width: 0; max-width: 100%; padding: .65rem .4rem; border: 1px solid #b7c8b8; border-radius: 6px; color: #233b30; background: #fff; font: inherit; }
.reader-toolbar button, .chapter-pager button { font: .85rem/1.4 Arial, sans-serif; padding: .7rem .9rem; border: 1px solid #b7c8b8; border-radius: 6px; background: #f3f6f0; color: #233b30; cursor: pointer; }
.reader-status { display: flex; justify-content: space-between; align-items: center; gap: 1rem; margin-top: .6rem; color: #526353; font: .75rem/1.5 Arial, sans-serif; }
.reader-status progress { width: 100px; height: 5px; accent-color: #0d683e; }
.article .reader-chapter > h2 { margin-top: 1.8rem; scroll-margin-top: 8rem; }
.chapter-takeaway { border-left: 3px solid #65816c; background: #f3f6f0; padding: .85rem 1rem; margin-bottom: 1.5rem; }
.chapter-takeaway strong { font: 600 .75rem/1.5 Arial, sans-serif; text-transform: uppercase; letter-spacing: .06em; }
.article .chapter-takeaway p { margin: .3rem 0 0; font-size: 1.05rem; line-height: 1.55; }
.chapter-topic { border-top: 1px solid #d8e2d7; scroll-margin-top: 8rem; }
.chapter-topic > summary { cursor: pointer; font-size: 1.15rem; font-weight: 600; padding: 1rem .2rem; }
.topic-body { padding: 0 .2rem 1rem; }
.chapter-pager { display: flex; justify-content: space-between; gap: 1rem; border-top: 1px solid #d8e2d7; margin-top: 2rem; padding-top: 1rem; }
.chapter-pager button { max-width: 72%; }
.chapter-pager button:disabled { opacity: .45; cursor: default; }
.article button:focus-visible, .article select:focus-visible, .chapter-topic > summary:focus-visible { outline: 2px solid #0d683e; outline-offset: 3px; }
.article header { margin-top: 2rem; }
@media (max-width: 480px) { .reader-toolbar { flex-wrap: wrap; } .reader-toolbar label { display: none; } .reader-toolbar select { width: 60%; } .chapter-pager { gap: .5rem; } }
@media print { .reader-controls, .chapter-pager, .chapter-links { display: none !important; } .reader-chapter[hidden] { display: block !important; } .chapter-topic > .topic-body { display: block !important; } }

/* Notebook-inspired editorial reading experience. */
.reading-page { background: #f8f7f3; color: #283a32; }
.reading-page .article { max-width: 820px; padding: 2.5rem 2rem 5rem; font-family: Georgia, 'Times New Roman', serif; font-size: 1.08rem; line-height: 1.8; }
.reading-page .article > nav:first-child { font-size: .78rem; letter-spacing: .02em; }
.reading-page .article > nav:first-child a { text-decoration: none; }
.reading-page .article header { margin: 4rem 0 1.4rem; }
.reading-page .eyebrow { font-size: .68rem; letter-spacing: .16em; color: #778176; }
.reading-page .article h1 { font-weight: 400; font-size: clamp(3.2rem, 8vw, 5.5rem); letter-spacing: -.055em; line-height: 1.04; margin: 1.2rem 0; }
.title-subline { display: block; margin-top: .6rem; font-size: .43em; letter-spacing: -.025em; font-style: italic; color: #687765; }
.reading-page .subtitle { font-size: 1.05rem; color: #6c746b; margin: 1.4rem 0; }
.reading-page .byline { display: flex; align-items: center; flex-wrap: wrap; gap: .6rem; font-size: .72rem; }
.author-mark { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: #e5eadd; color: #3b5642; font: 11px Georgia, serif; }
.byline-divider { color: #a8afa2; }
.about-notes { color: #778176; font: .75rem/1.7 Arial, sans-serif; margin-bottom: 2.6rem; }
.about-notes summary { cursor: pointer; }
.about-notes p { max-width: 600px; }
.reading-page .chapter-links { display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); gap: 0; border-top: 1px solid #d8ddd1; border-bottom: 1px solid #d8ddd1; margin: 0; }
.reading-page .chapter-links a { display: flex; flex-direction: column; gap: .4rem; padding: 1rem .6rem; text-decoration: none; color: #778176; border-bottom: 2px solid transparent; font: .73rem/1.4 Arial, sans-serif; transition: background .15s; }
.reading-page .chapter-links a:hover { background: #eeeee6; }
.reading-page .chapter-links a[aria-current] { color: #244a35; border-bottom-color: #42634b; background: #edf0e7; }
.article .chapter-links .chapter-number { margin: 0; color: inherit; font-size: .65rem; letter-spacing: .1em; }
.article .chapter-links .chapter-label { margin: 0; color: inherit; }
.reading-page .reader-controls { position: static; margin: 0 0 2rem; padding: .6rem 0; border: 0; background: transparent; display: flex; align-items: center; justify-content: space-between; flex-direction: row-reverse; }
.reading-page .reader-toolbar label, .reading-page #chapter-select { display: none; }
.reading-page .reader-toolbar button { background: transparent; border: 0; padding: .3rem 0; border-radius: 0; color: #66705f; text-decoration: underline; text-underline-offset: 4px; font-size: .72rem; }
.reading-page .reader-status { margin: 0; gap: .8rem; font-size: .68rem; }
.reading-page .reader-status progress { width: 65px; height: 3px; }
.reading-page .reader-chapter { background: #fffefa; border: 1px solid #e4e5db; border-radius: 12px; padding: 2.2rem 2.7rem; box-shadow: 0 8px 32px #273d2710; }
.reading-page .reader-chapter + .reader-chapter { margin-top: 1.5rem; }
.reading-page .reader-chapter > h2 { margin: 0 0 1.8rem; font-weight: 400; font-size: clamp(1.8rem,4vw,2.45rem); line-height: 1.2; letter-spacing: -.025em; scroll-margin-top: 2rem; }
.section-kicker { display: block; font: 10px/1.5 Arial,sans-serif; letter-spacing: .15em; color: #7a856f; margin-bottom: .8rem; }
.reading-page .chapter-takeaway { border: 0; border-radius: 8px; padding: 1rem 1.2rem; background: #eef1e7; margin-bottom: 2rem; }
.reading-page .chapter-takeaway strong { font-size: .6rem; letter-spacing: .12em; color: #627655; }
.reading-page .chapter-takeaway p { font-size: 1rem; line-height: 1.65; }
.reading-page .article h3 { font-size: 1.2rem; font-weight: 400; }
.reading-page .article blockquote { font-size: 1.25rem; border-color: #b5c0a5; font-style: italic; }
.reading-page .chapter-topic > summary { font-family: Arial,sans-serif; font-size: .86rem; font-weight: 400; padding: 1.1rem .1rem; color: #3f5946; }
.reading-page .chapter-topic { border-color: #e3e7dc; }
.reading-page .article figure { background: #fff; padding: .75rem; border: 1px solid #eeeeE7; border-radius: 8px; margin: 1.5rem 0; }
.reading-page .article figcaption { font-size: .7rem; line-height: 1.6; }
.reading-page .article .diagram-text { margin: -.7rem 0 1.6rem; padding-left: .25rem; }
.reading-page .diagram-text summary { font-size: .7rem; color: #7a816f; }
.reading-page .article .equation, .reading-page .article pre { border-radius: 6px; background: #f3f4ed; }
.reading-page .chapter-pager { border: 0; margin-top: 1.2rem; padding-top: 0; align-items: center; }
.reading-page .chapter-pager button { border-radius: 8px; padding: .8rem 1rem; font-size: .75rem; background: transparent; border-color: #d8ddd1; }
.reading-page #next-chapter:not(:disabled) { background: #34583f; color: #fff; border-color: #34583f; }
.reading-page .excerpt-end { text-align: center; border: 0; margin-top: 2.5rem; font-size: .72rem; color: #7a816f; }
@media (max-width: 600px) {
 .reading-page .article { padding: 1.4rem 1rem 3rem; font-size: 1rem; }
 .reading-page .article header { margin-top: 2.6rem; }
 .reading-page .byline { font-size: .66rem; }
 .reading-page .chapter-links a { padding: .8rem .3rem; font-size: .61rem; }
 .reading-page .reader-chapter { padding: 1.4rem 1.1rem; border-radius: 9px; }
 .reading-page .chapter-pager button { padding: .7rem; font-size: .68rem; }
 .reading-page .article figure { padding: .35rem; }
}
@media (prefers-reduced-motion: reduce) { .reading-page * { transition: none !important; } }
@media print { .reading-page { background: #fff; } .reading-page .reader-chapter { border: 0; box-shadow: none; padding: 0; } }

.reading-page .notebook-downloads { display: flex; flex-wrap: wrap; align-items: center; gap: .55rem 1rem; margin: -1rem 0 2rem; font: .72rem/1.7 Arial, sans-serif; }
.notebook-downloads > span { flex-basis: 100%; color: #778176; }
.notebook-downloads a { text-underline-offset: 4px; }
