/* Notebook index and post pages. Loads after site.css and before theme.css,
   so it only uses theme variables and any theme can restyle it. */
.pagehead, .post-hero, .notebook-hero { background: var(--poster, var(--ink)); color: var(--poster-ink, var(--bg)); }
.pagehead a:hover, .post-hero a:hover { color: var(--c3); }
.nav .nav-active { border-bottom: 2px solid var(--c3); }
.container { max-width: 1376px; margin-inline: auto; padding-inline: 32px; }

.post-hero, .notebook-hero { padding-block: 40px 56px; border-bottom: 6px solid var(--c3); }
.post-hero__back { display: inline-block; margin-bottom: 28px; font-family: var(--font-display); font-weight: 700; font-size: 16px; letter-spacing: 0.08em; text-transform: uppercase; text-decoration: none; }
.post-hero__eyebrow, .notebook-hero__eyebrow, .post-card__eyebrow {
    font-family: var(--font-display); font-size: 16px; font-weight: 700;
    letter-spacing: 0.18em; text-transform: uppercase;
}
.post-hero__eyebrow, .notebook-hero__eyebrow { color: var(--c3); margin-bottom: 14px; }
.post-hero h1, .notebook-hero h1 {
    margin: 0 0 18px; max-width: 22ch; font-family: var(--font-display);
    font-size: clamp(40px, 6vw, 80px); line-height: 0.95; font-weight: 800; text-wrap: balance;
}
.post-hero__meta, .notebook-hero__sub { margin: 0; max-width: 720px; font-size: 21px; line-height: 1.5; }

.post-body, .notebook-section { padding-top: 56px; }
.post-article { max-width: 720px; }
.post-article > :first-child { margin-top: 0; }
.post-article p, .post-article ul, .post-article ol { margin: 0 0 22px; }
.post-article li { margin-bottom: 8px; }
.post-article h2 { font-size: clamp(28px, 3.4vw, 38px); line-height: 1.05; margin: 48px 0 18px; text-wrap: balance; }
.post-article a { text-decoration-thickness: 2px; text-underline-offset: 3px; }
.post-article code {
    font-family: ui-monospace, 'SFMono-Regular', Menlo, Consolas, monospace; font-size: 0.82em;
    background: color-mix(in srgb, var(--ink) 9%, transparent); padding: 0.1em 0.35em; border-radius: 3px;
    overflow-wrap: anywhere;
}
.post-article pre { background: var(--surface); border-radius: 8px; padding: 20px; overflow-x: auto; margin: 0 0 22px; font-size: 16px; line-height: 1.5; }
.post-article pre code { background: none; padding: 0; font-size: inherit; overflow-wrap: normal; }
.post-article table { display: block; overflow-x: auto; border-collapse: collapse; margin: 0 0 22px; font-size: 18px; font-variant-numeric: tabular-nums; }
.post-article th { font-family: var(--font-display); font-size: 15px; letter-spacing: 0.1em; text-transform: uppercase; text-align: left; border-bottom: 2px solid var(--ink); padding: 8px 20px 8px 0; white-space: nowrap; }
.post-article td { border-bottom: 1px solid color-mix(in srgb, var(--ink) 30%, transparent); padding: 8px 20px 8px 0; }

.post-note, .stat-callout, .status-callout, .event-box { background: var(--surface); border-radius: 8px; padding: 24px 28px; margin: 32px 0; }
.post-note { border-top: 6px solid var(--c3); }
.status-callout { border-top: 6px solid var(--c1); }
.stat-callout, .event-box { border-top: 6px solid var(--c2); }
.post-note > :last-child { margin-bottom: 0; }
.post-note__label, .event-box__label { font-family: var(--font-display); font-size: 15px; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: var(--c1); }
.post-note__label { margin-bottom: 12px; }
.stat-callout__row + .stat-callout__row { margin-top: 10px; }
.event-box__row { display: flex; flex-wrap: wrap; gap: 4px 20px; padding: 8px 0; }
.event-box__label { flex: 0 0 90px; }
.btn {
    display: inline-block; margin-top: 12px; padding: 14px 24px; border-radius: 4px;
    background: var(--c1); color: var(--surface); text-decoration: none;
    font-family: var(--font-display); font-weight: 800; font-size: 18px; letter-spacing: 0.08em; text-transform: uppercase;
}
.post-article .btn:hover { background: var(--ink); color: var(--surface); }

.notebook-list { max-width: 880px; }
.post-card { display: block; border-top: 2px solid var(--ink); padding: 22px 0 26px; text-decoration: none; }
.post-card__eyebrow { color: var(--c1); margin-bottom: 8px; }
.post-card__title { font-family: var(--font-display); font-size: clamp(24px, 3vw, 32px); font-weight: 800; line-height: 1.08; margin-bottom: 8px; text-wrap: balance; }
.post-card__teaser { margin: 0 0 10px; max-width: 720px; }
.post-card__read { font-family: var(--font-display); font-weight: 700; font-size: 16px; letter-spacing: 0.08em; text-transform: uppercase; }
.post-card:hover { color: inherit; }
.post-card:hover .post-card__title, .post-card:hover .post-card__read { color: var(--c1); }

@media (max-width: 800px) {
    .container { padding-inline: 16px; }
    .post-hero, .notebook-hero { padding-block: 24px 36px; }
    .post-hero__meta, .notebook-hero__sub { font-size: 18px; }
    .post-body, .notebook-section { padding-top: 36px; }
}
