/* ============================================================
   LIBERTARIA MAGAZINE — print.css (The Old World)
   ------------------------------------------------------------
   The legacy quarantine (SPEC-061 v2 §2, NPS doctrine on the
   web): everything the screen world forbids lives HERE and
   only here — @page rules, physical units, paper assumptions.

   Screen stylesheets must never contain mm/cm/pt/in/pc.
   This file must never be loaded for screen media.
   ============================================================ */

@page {
    size: A4;
    margin: 25mm 20mm;
}

/* ------------------------------------------------------------
   Paper: light ground, near-black ink. The dark magazine
   theme is a screen-only luxury.
   ------------------------------------------------------------ */
html,
body {
    background: #ffffff !important;
    color: #1a1a1a !important;
}

body {
    font-family: 'Literata', Georgia, serif;
    font-size: 11pt;
    line-height: 1.5;
}

main {
    padding-top: 0 !important;
    min-height: 0 !important;
}

/* ------------------------------------------------------------ 
   Chrome: the screen apparatus does not exist on paper
   ------------------------------------------------------------ */
.navbar,
.navbar-container,
.progress-bar,
.hamburger,
.nav-links,
footer,
.newsletter-form,
.newsletter,
.search-container,
.skeleton,
.story-footer .back-link {
    display: none !important;
}

/* Navigation tags are screen wayfinding, not content */
.tags {
    display: none !important;
}

/* ------------------------------------------------------------
   Typography on paper: dark ink, no glow economy
   ------------------------------------------------------------ */
h1, h2, h3, h4 {
    color: #000000 !important;
}

h1 {
    font-size: 22pt;
    line-height: 1.2;
    break-after: avoid;
}

h2 {
    font-size: 16pt;
    break-after: avoid;
    break-inside: avoid;
}

h3 {
    font-size: 13pt;
    break-after: avoid;
}

p {
    orphans: 3;
    widows: 3;
}

/* Links: silent ink — no URL expansion, no color circus */
a,
a:visited,
a:hover {
    color: #1a1a1a !important;
    text-decoration: underline !important;
    text-decoration-color: #999999 !important;
}

/* Author/date meta stays legible */
.meta,
.post-subtitle,
.author {
    color: #444444 !important;
}

/* ------------------------------------------------------------
   TL;DR box: keep it, flatten it
   ------------------------------------------------------------ */
.tldr-box {
    background: #f5f5f0 !important;
    border-left: 3px solid #8b0000 !important;
    border-right: none !important;
    border-radius: 0 !important;
    break-inside: avoid;
}

.tldr-label {
    color: #8b0000 !important;
}

.tldr-text {
    color: #1a1a1a !important;
}

/* ------------------------------------------------------------
   Imagery: 14:9 hero, framed but not glowing
   ------------------------------------------------------------ */
img {
    max-width: 100% !important;
    break-inside: avoid;
}

img.hero-image {
    aspect-ratio: 14 / 9;
    object-fit: cover;
    border-radius: 0 !important;
    box-shadow: none !important;
    border: 0.5pt solid #cccccc;
    break-inside: avoid;
}

/* ------------------------------------------------------------
   Code and tables: neutralize dark hardcodes and shiki's
   github-dark inline colors — legibility beats highlighting
   ------------------------------------------------------------ */
pre,
pre * {
    background: #f5f5f0 !important;
    color: #1a1a1a !important;
}

pre {
    border: 0.5pt solid #cccccc !important;
    border-left: 3px solid #8b0000 !important;
    border-radius: 0 !important;
    padding: 8pt !important;
    white-space: pre-wrap;
    overflow-wrap: break-word;
    break-inside: auto;
}

code {
    font-family: 'JetBrains Mono', 'Courier New', monospace !important;
    font-size: 9pt !important;
}

p code, li code {
    background: #efefe8 !important;
    color: #1a1a1a !important;
    border-radius: 0 !important;
}

table {
    width: 100% !important;
    border-collapse: collapse !important;
    break-inside: avoid;
    font-size: 10pt;
}

th, td {
    border-bottom: 0.5pt solid #999999 !important;
    color: #1a1a1a !important;
}

th {
    color: #000000 !important;
}

/* Blockquotes: quiet on paper */
blockquote {
    background: transparent !important;
    color: #444444 !important;
    break-inside: avoid;
}

/* ------------------------------------------------------------
   Flow discipline: the article prints as ONE column, always.
   The spread is a screen instrument.
   ------------------------------------------------------------ */
.content,
.blog-post,
.story-post {
    max-width: 100% !important;
    padding: 0 !important;
}

.content {
    column-count: 1 !important;
    columns: auto !important;
    column-rule: none !important;
    font-size: 11pt !important;
    line-height: 1.5 !important;
}

.content h2,
.content h3 {
    break-after: avoid;
    break-inside: avoid;
}

.content pre,
.content table,
.content figure,
.content img {
    break-inside: avoid;
}

/* Story frame elements */
.story-badge {
    background: none !important;
    color: #8b0000 !important;
    padding: 0 !important;
    border: none;
}

.era, .theme {
    color: #444444 !important;
}

header {
    border-bottom: 1pt solid #000000 !important;
    break-after: avoid;
}
