/* Parliament Commentary: Monthly SOTU + Weekly Pieces */
/* Warm editorial paper palette, Newsreader serif headlines, IBM Plex Sans body, IBM Plex Mono numbers */

:root {
    --bg-canvas: #e6e0d2;
    --panel-base: #f1ece2;
    --panel-raised: #ebe4d6;
    --text-primary: #1c1915;
    --text-secondary: #5c5348;
    --text-tertiary: #8a7f72;
    --border-subtle: rgba(28, 25, 21, 0.14);
    --up: #1f6f4a;
    --down: #a63a2b;
    --warn: #9a6715;
    --inflect: #2b5b84;
    --link: #1c1915;
    --link-hover: #5c5348;
}

body {
    background: var(--bg-canvas);
    color: var(--text-primary);
    font-family: 'IBM Plex Sans', -apple-system, system-ui, sans-serif;
    line-height: 1.6;
    margin: 0;
    padding: 0;
}

/* === NC-PILL (universal pill component from nowcast.css) === */
.nc-pill {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    border-radius: 999px;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
    font-weight: 600;
    line-height: 1.2;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

/* === POSTURE PILLS === */
.posture-leading {
    background: rgba(22, 101, 52, 0.16);
    color: #14532d;
    border: 1px solid rgba(22, 101, 52, 0.35);
}

.posture-accelerating {
    background: rgba(15, 118, 110, 0.15);
    color: #134e4a;
    border: 1px solid rgba(15, 118, 110, 0.32);
}

.posture-broadening {
    background: rgba(37, 99, 155, 0.14);
    color: #1e3a5f;
    border: 1px solid rgba(37, 99, 155, 0.30);
}

.posture-inflecting-up,
.posture-inflecting {
    background: rgba(180, 83, 9, 0.15);
    color: #78350f;
    border: 1px solid rgba(180, 83, 9, 0.32);
}

.posture-cooling,
.posture-neutral {
    background: rgba(120, 113, 108, 0.14);
    color: #44403c;
    border: 1px solid rgba(120, 113, 108, 0.28);
}

.posture-lagging {
    background: rgba(154, 52, 18, 0.14);
    color: #7c2d12;
    border: 1px solid rgba(154, 52, 18, 0.30);
}

.posture-unwinding {
    background: rgba(153, 27, 27, 0.16);
    color: #7f1d1d;
    border: 1px solid rgba(153, 27, 27, 0.34);
}

/* === CORRELATION MATRIX (from nowcast.css) === */
.correlation-matrix-wrapper {
    overflow-x: auto;
    border: 1px solid rgba(28, 25, 21, 0.15);
    border-radius: 8px;
    background: #f1ece2;
    margin: 1.5rem 0;
}

.correlation-table {
    width: 100%;
    border-collapse: collapse;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.85rem;
}

.correlation-table th {
    padding: 0.75rem;
    background: #ebe4d6;
    border: 1px solid rgba(28, 25, 21, 0.12);
    font-weight: 600;
    text-align: center;
    vertical-align: middle;
}

.correlation-table th:first-child,
.correlation-table td:first-child {
    text-align: left;
    white-space: nowrap;
}

.correlation-table td {
    padding: 0.75rem;
    border: 1px solid rgba(28, 25, 21, 0.12);
    text-align: center;
    vertical-align: middle;
}

.corr-cell {
    font-weight: 600;
}

.corr-diag {
    background: rgba(28, 25, 21, 0.08);
    color: #5c5348;
}

.corr-pos-strong {
    background: rgba(185, 56, 41, 0.28);
    color: #5c160e;
    font-weight: 600;
}

.corr-pos-mild {
    background: rgba(217, 119, 6, 0.16);
    color: #78350f;
}

.corr-neutral {
    background: rgba(28, 25, 21, 0.02);
    color: #5c5348;
}

.corr-neg-mild {
    background: rgba(37, 99, 155, 0.14);
    color: #1e3a5f;
}

.corr-neg-strong {
    background: rgba(29, 78, 137, 0.28);
    color: #122b4a;
    font-weight: 600;
}

/* === UTILITY CLASSES === */
.mono {
    font-family: 'IBM Plex Mono', monospace;
}

.up {
    color: var(--up);
    font-weight: 600;
}

.down {
    color: var(--down);
    font-weight: 600;
}

/* === HISTORICAL TABLE === */
.historical-table {
    width: 100%;
    border-collapse: collapse;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.85rem;
    background: var(--panel-base);
    border: 1px solid var(--border-subtle);
    border-radius: 6px;
    overflow: hidden;
    margin: 1.5rem 0;
}

.historical-table th {
    padding: 6px 6px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-tertiary);
    background: var(--panel-raised);
    text-align: left;
    border-bottom: 1px solid var(--border-subtle);
}

.historical-table td {
    padding: 5px 6px;
    font-size: 11.5px;
    white-space: nowrap;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border-subtle);
}

.historical-table tbody tr:last-child td {
    border-bottom: none;
}

.historical-table .nc-pill {
    padding: 1px 6px;
    font-size: 10px;
    line-height: 1.3;
}

/* Archive page: hero card + filterable grid */
.commentary-archive {
    box-sizing: border-box;
    max-width: var(--frame);
    margin: 0 auto;
    padding: 3rem var(--m);
}

.archive-hero {
    background: var(--panel-base);
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    padding: 2.5rem;
    margin-bottom: 3rem;
}

.archive-hero .kind-badge {
    display: inline-flex;
    align-items: center;
    background: rgba(28, 25, 21, 0.05);
    border: 1px solid rgba(28, 25, 21, 0.12);
    color: var(--text-primary);
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 3px 10px;
    border-radius: 999px;
    margin-bottom: 1rem;
}

.archive-hero h1 {
    font-family: var(--serif);
    font-size: 2.5rem;
    font-weight: 600;
    line-height: 1.2;
    margin: 0 0 1rem 0;
    color: var(--text-primary);
}

.archive-hero .subtitle {
    font-size: 1.125rem;
    line-height: 1.6;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    overflow: hidden;
    min-height: calc(1.6em * 3);
}

.archive-hero .meta-line {
    display: flex;
    gap: 1.5rem;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.875rem;
    color: var(--text-tertiary);
    margin-bottom: 1.5rem;
}

.archive-hero .highlights {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.archive-hero .highlight-pill {
    background: var(--panel-raised);
    border: 1px solid var(--border-subtle);
    padding: 0.5rem 1rem;
    border-radius: 6px;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.875rem;
}

.archive-hero .highlight-pill .label {
    color: var(--text-secondary);
    margin-right: 0.5rem;
}

.archive-hero .highlight-pill .value {
    color: var(--text-primary);
    font-weight: 600;
}

.archive-hero .highlight-pill.tone-up .value {
    color: var(--up);
}

.archive-hero .highlight-pill.tone-down .value {
    color: var(--down);
}

.archive-hero .highlight-pill.tone-warn .value {
    color: var(--warn);
}

.archive-hero .cta-link {
    display: inline-block;
    background: var(--text-primary);
    color: var(--panel-base);
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    text-decoration: none;
    transition: opacity 0.15s ease;
}

.archive-hero .cta-link:hover {
    opacity: 0.85;
}

/* Archive filters */
.archive-filters {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
}

.archive-filters button {
    background: var(--panel-base);
    border: 1px solid var(--border-subtle);
    color: var(--text-secondary);
    font-family: 'IBM Plex Sans', sans-serif;
    font-size: 0.875rem;
    font-weight: 500;
    padding: 0.625rem 1.25rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.15s ease;
}

.archive-filters button:hover {
    background: var(--panel-raised);
    color: var(--text-primary);
}

.archive-filters button.active {
    background: var(--text-primary);
    color: var(--panel-base);
    border-color: var(--text-primary);
}

/* Archive grid */
.archive-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 1.5rem;
}

.archive-card {
    background: var(--panel-base);
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    padding: 1.75rem;
    transition: border-color 0.15s ease;
}

.archive-card:hover {
    border-color: var(--text-primary);
}

.archive-card .kind-badge {
    display: inline-flex;
    align-items: center;
    background: rgba(28, 25, 21, 0.05);
    border: 1px solid rgba(28, 25, 21, 0.12);
    color: var(--text-primary);
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 3px 10px;
    border-radius: 999px;
    margin-bottom: 0.75rem;
}

.archive-card h3 {
    font-family: var(--serif);
    font-size: 1.375rem;
    font-weight: 600;
    line-height: 1.3;
    margin: 0 0 0.75rem 0;
}

.archive-card h3 a {
    color: var(--text-primary);
    text-decoration: none;
    transition: color 0.15s ease;
}

.archive-card h3 a:hover {
    color: var(--link-hover);
}

.archive-card .meta-line {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.875rem;
    color: var(--text-tertiary);
    margin-bottom: 0.75rem;
}

.archive-card .summary {
    font-size: 0.9375rem;
    line-height: 1.6;
    color: var(--text-secondary);
}

/* Post page: the article fills the frame; the rail stays on the right edge. */
.commentary-post {
    box-sizing: border-box;
    width: 100%;
    max-width: var(--frame);
    margin: 0 auto;
    padding: 32px var(--m) 48px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 240px;
    column-gap: 48px;
    row-gap: 0;
    align-items: start;
}

.post-header,
.post-body,
.commentary-disclaimer,
.post-nav {
    grid-column: 1;
    width: 100%;
    min-width: 0;
    max-width: none;
}

.post-rail {
    grid-column: 2;
    grid-row: 1 / span 3;
    align-self: start;
    position: sticky;
    top: calc(var(--bar-h, 64px) + 20px);
}

@media (max-width: 860px) {
    .commentary-post {
        grid-template-columns: minmax(0, 1fr);
    }
    .post-rail {
        grid-column: 1;
        grid-row: auto;
        position: static;
        margin-top: 32px;
    }
}

.post-header {
    margin-bottom: 28px;
}

.post-header .kind-badge {
    display: inline-flex;
    align-items: center;
    background: rgba(28, 25, 21, 0.05);
    border: 1px solid rgba(28, 25, 21, 0.12);
    color: var(--text-primary);
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 3px 10px;
    border-radius: 999px;
    margin-bottom: 1rem;
}

.post-header h1 {
    font-family: var(--serif);
    font-size: 2.75rem;
    font-weight: 600;
    line-height: 1.2;
    margin: 0 0 1rem 0;
    color: var(--text-primary);
}

.post-header .subtitle {
    font-size: 1.25rem;
    line-height: 1.5;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    overflow: hidden;
    min-height: calc(1.5em * 3);
}

.archive-hero .lede-wrap,
.post-header .lede-wrap {
    margin-bottom: 1.5rem;
}

.archive-hero .lede-wrap .subtitle,
.post-header .lede-wrap .subtitle {
    margin-bottom: 0;
}

.archive-hero .lede-wrap.is-open .subtitle,
.post-header .lede-wrap.is-open .subtitle {
    display: block;
    -webkit-line-clamp: unset;
    line-clamp: unset;
    overflow: visible;
}

.archive-hero .lede-more,
.post-header .lede-more {
    display: inline-flex;
    align-items: center;
    margin-top: 8px;
    padding: 2px 10px;
    border: 0;
    border-radius: 999px;
    background: rgba(28, 25, 21, 0.06);
    color: var(--ink, #1c1915);
    font: 500 13px/1.4 var(--sans);
    letter-spacing: 0;
    text-transform: none;
    cursor: pointer;
}

.archive-hero .lede-more:hover,
.post-header .lede-more:hover {
    background: rgba(28, 25, 21, 0.12);
}

.archive-hero .lede-more:focus-visible,
.post-header .lede-more:focus-visible {
    outline: 2px solid var(--ink, #1c1915);
    outline-offset: 2px;
}

.archive-hero .lede-more[hidden],
.post-header .lede-more[hidden] {
    display: none;
}

.post-header .meta-line {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem 1.5rem;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.875rem;
    color: var(--text-tertiary);
}

.post-header .meta-line span {
    white-space: nowrap;
}

/* Embedded figures in posts */
.sotu-intro-banner {
    background: var(--panel-base);
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    padding: 2rem;
    margin: 2rem 0;
}

.sotu-intro-banner h2 {
    font-family: var(--serif);
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0 0 1rem 0;
    color: var(--text-primary);
}

.sotu-intro-banner p {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--text-primary);
    margin: 0.75rem 0;
}

.commentary-lede,
.commentary-lede p {
    font-size: 1.0625rem;
    font-weight: 400;
    line-height: 1.7;
    color: var(--text-primary);
    margin: 0 0 1.25rem 0;
    background: none;
    border: none;
    padding: 0;
}

.commentary-lede strong,
.commentary-lede b {
    font-weight: 400;
}

.post-body > :first-child,
.post-lead > :first-child {
    margin-top: 0;
}

/* Comfortable article body: 16px (1rem) reading size matching intro banner */
.post-body {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--text-primary);
}

.post-body .commentary-table-wrap,
.post-body table,
.post-body .sotu-intro-banner,
.post-body .commentary-figure,
.post-body .correlation-matrix-wrapper,
.post-body .figure-pillar-grid,
.post-body .figure-flips-split,
.post-body .quadrant-svg-wrap,
.post-body .rotation-snap-table,
.post-body .corr-and-guardrail-grid,
.post-body .historical-table {
    width: 100%;
    max-width: none;
}

.post-body p,
.post-body li {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--text-primary);
}

.post-body p {
    margin: 0 0 1.2rem 0;
}

.post-body ul,
.post-body ol {
    margin: 0 0 1.25rem 0;
    padding-left: 1.4rem;
}

.post-body li {
    margin-bottom: 0.5rem;
}

.post-body > :not(aside) a {
    color: inherit;
    text-decoration-line: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.16em;
}

.post-body > :not(aside) a:hover {
    color: #8b3a2b;
}

.commentary-figure {
    margin: 2.5rem 0;
}

.figure-caption {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.875rem;
    color: var(--text-tertiary);
    margin-top: 0.75rem;
}

/* Pillar grid */
.figure-pillar-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1rem;
    margin: 1.5rem 0;
}

.fig-pillar-card {
    background: var(--panel-base);
    border: 1px solid var(--border-subtle);
    border-radius: 6px;
    padding: 1.25rem;
}

.fig-pillar-card .pillar-label {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-tertiary);
    margin-bottom: 0.5rem;
}

.fig-pillar-card .pillar-value {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.fig-pillar-card .pillar-change {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.875rem;
}

.fig-pillar-card .pillar-change.up {
    color: var(--up);
}

.fig-pillar-card .pillar-change.down {
    color: var(--down);
}

.fig-pillar-card .pillar-change.warn {
    color: var(--warn);
}

/* Flips split layout */
.figure-flips-split {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.regime-compare-grid {
    background: var(--panel-base);
    border: 1px solid var(--border-subtle);
    border-radius: 6px;
    padding: 1.5rem;
}

.regime-compare-grid h4 {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-tertiary);
    margin: 0 0 1rem 0;
}

.regime-compare-grid .regime-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border-subtle);
}

.regime-compare-grid .regime-row:last-child {
    border-bottom: none;
}

.regime-compare-grid .regime-name {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.regime-compare-grid .regime-score {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* RRG quadrant SVG */
.quadrant-svg-wrap {
    background: var(--panel-base);
    border: 1px solid var(--border-subtle);
    border-radius: 6px;
    padding: 1.5rem;
    margin: 1.5rem 0;
}

.quadrant-svg-wrap svg {
    width: 100%;
    height: auto;
}

/* Rotation snapshot table */
.rotation-snap-table {
    margin: 1.5rem 0;
    overflow-x: auto;
}

.rotation-snap-table table {
    width: 100%;
    border-collapse: collapse;
    background: var(--panel-base);
    border: 1px solid var(--border-subtle);
    border-radius: 6px;
    overflow: hidden;
}

.rotation-snap-table th {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-tertiary);
    background: var(--panel-raised);
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-subtle);
}

.rotation-snap-table td {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.875rem;
    color: var(--text-secondary);
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border-subtle);
}

.rotation-snap-table tbody tr:last-child td {
    border-bottom: none;
}

.rotation-snap-table .num-col {
    font-weight: 600;
    color: var(--text-primary);
    text-align: right;
}

.rotation-snap-table .up {
    color: var(--up);
}

.rotation-snap-table .down {
    color: var(--down);
}

.rotation-snap-table .warn {
    color: var(--warn);
}

/* Correlation and guardrail grid */
.corr-and-guardrail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.guardrail-card {
    background: var(--panel-base);
    border: 1px solid var(--border-subtle);
    border-radius: 6px;
    padding: 1.5rem;
}

.guardrail-card h4 {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-tertiary);
    margin: 0 0 1rem 0;
}

.guardrail-card .metric-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
}

.guardrail-card .metric-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.guardrail-card .metric-value {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
}

.guardrail-card .metric-value.up {
    color: var(--up);
}

.guardrail-card .metric-value.down {
    color: var(--down);
}

.guardrail-card .metric-value.warn {
    color: var(--warn);
}

/* Commentary tables */
.commentary-table-wrap {
    margin: 1.5rem 0;
    overflow-x: auto;
}

table.commentary-table,
.commentary-table table {
    width: 100%;
    border-collapse: collapse;
    background: var(--panel-base);
    border: 1px solid var(--border-subtle);
    border-radius: 6px;
    overflow: hidden;
}

.commentary-table th {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-tertiary);
    background: var(--panel-raised);
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-subtle);
}

.commentary-table td {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.875rem;
    color: var(--text-secondary);
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border-subtle);
}

.commentary-table tbody tr:last-child td {
    border-bottom: none;
}

.commentary-table .num-col {
    font-weight: 600;
    color: var(--text-primary);
    text-align: right;
}

/* Figure badges */
/* fig-badge removed - use .nc-pill instead */

/* Post navigation */
.post-nav {
    display: flex;
    justify-content: space-between;
    gap: 1.5rem;
    margin: 3rem 0;
    padding-top: 2rem;
    border-top: 1px solid var(--border-subtle);
}

.post-nav a {
    flex: 1;
    background: var(--panel-base);
    border: 1px solid var(--border-subtle);
    border-radius: 6px;
    padding: 1.25rem;
    text-decoration: none;
    transition: border-color 0.15s ease;
}

.post-nav a:hover {
    border-color: var(--text-primary);
}

.post-nav .nav-label {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-tertiary);
    margin-bottom: 0.5rem;
}

.post-nav .nav-arrow-circle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 999px;
    background: rgba(28, 25, 21, 0.06);
    border: 1px solid rgba(28, 25, 21, 0.16);
    color: var(--text-primary);
    flex-shrink: 0;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.post-nav a:hover .nav-arrow-circle {
    background: var(--text-primary);
    border-color: var(--text-primary);
    color: var(--panel-base);
}

.post-nav .nav-title {
    font-family: var(--serif);
    font-size: 1.125rem;
    font-weight: 600;
    line-height: 1.3;
    color: var(--text-primary);
}

/* Disclaimer footer */
.commentary-disclaimer {
    background: var(--panel-base);
    border: 1px solid var(--border-subtle);
    border-radius: 6px;
    padding: 1.5rem;
    margin: 3rem 0;
    font-size: 0.8125rem;
    line-height: 1.6;
    color: var(--text-tertiary);
}

.commentary-disclaimer h4 {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-secondary);
    margin: 0 0 0.75rem 0;
}

/* Responsive */
@media (max-width: 768px) {
    .archive-hero {
        padding: 1.75rem;
    }
    
    .archive-hero h1 {
        font-size: 2rem;
    }
    
    .archive-hero .subtitle {
        font-size: 1rem;
    }
    
    .archive-grid {
        grid-template-columns: 1fr;
    }
    
    .post-header h1 {
        font-size: 2rem;
    }
    
    .post-header .subtitle {
        font-size: 1.125rem;
    }
    
    .figure-pillar-grid,
    .figure-flips-split,
    .corr-and-guardrail-grid {
        grid-template-columns: 1fr;
    }
    
    .post-nav {
        flex-direction: column;
    }
}

.commentary-post .crumbs { color: var(--muted); margin-bottom: 12px; }
.commentary-post .crumbs a { color: var(--ink); }
.commentary-post .post-header h1 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 44px;
  line-height: 1.08;
}

/* Post Rail Styles */
.post-rail {
    font-size: 14px;
}

.rail-section {
    margin-bottom: 32px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border-subtle);
}

.rail-section:last-child {
    border-bottom: 0;
}

.rail-section h4 {
    font: 600 15px var(--sans);
    margin: 0 0 12px 0;
    color: var(--text-primary);
}

.rail-toc {
    display: grid;
    gap: 8px;
}

.rail-toc a {
    color: var(--text-secondary);
    text-decoration: none;
    padding: 4px 0;
    transition: color 0.2s;
}

.rail-toc a:hover {
    color: var(--text-primary);
}

.rail-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.rail-link {
    color: var(--link);
    text-decoration: none;
    font-weight: 500;
}

.rail-link:hover {
    color: var(--link-hover);
}

.rail-post {
    display: block;
    margin: 0 0 12px;
    color: var(--text-primary);
    font: 500 16px/1.3 var(--serif, Georgia, serif);
    text-decoration: none;
}

.rail-post span {
    display: block;
    margin-bottom: 2px;
    color: var(--text-secondary);
    font: 12px var(--sans);
}

.rail-post:hover { text-decoration: underline; }

.post-lead { position: relative; }
.paywall-fade {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 88px;
    background: linear-gradient(to bottom, rgba(230, 224, 210, 0), var(--bg-canvas));
    pointer-events: none;
    border-radius: 0 0 18px 18px;
}
.register-gate {
    display: grid;
    width: 100%;
    box-sizing: border-box;
    gap: 14px;
    justify-items: start;
    margin: 8px 0 2rem;
    padding: 28px 28px 24px;
    background: var(--panel-base);
    border-radius: 18px;
}
.register-gate p {
    margin: 0;
    max-width: 42ch;
    font: 500 18px/1.45 var(--serif, Georgia, serif);
}
.gate-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 18px;
    border-radius: 999px;
    background: var(--text-primary);
    color: #f3eee4;
    font: 600 15px/1 var(--sans);
    text-decoration: none;
}
.gate-btn:hover { background: #34302a; }
.gate-sign {
    color: var(--text-secondary);
    font: 600 15px/1.4 var(--sans);
    text-decoration: underline;
    text-underline-offset: 3px;
}
.gate-sign:hover { color: var(--text-primary); }
