/* =============================================================
   Arkansas Surveillance Wiki — publish.css
   A FOIA-derived investigation into Arkansas law-enforcement
   adoption of automatic license plate readers (ALPR).

   Design language: "Machine Vision" — a cold, forensic editorial
   register. The wiki documents systems built to watch; the page
   is the lens that watches them back. Two accents encode the
   logic of an ALPR system:
     · scan  (cyan-teal) — the ambient watch: links, structure
     · alert (red)       — the hot-list hit: findings, warnings
   Display serif (Cormorant) carries the human, documentary
   voice; monospace (IBM Plex Mono) carries the machine record.
   ============================================================= */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,400;0,500;0,600;1,400;1,500&family=Source+Serif+4:ital,opsz,wght@0,8..60,400;0,8..60,500;0,8..60,600;1,8..60,400;1,8..60,500&family=Inter:wght@400;500;600;700&family=IBM+Plex+Mono:wght@400;500;600&display=swap');

/* =============================================================
   1. TOKENS
   ============================================================= */

:root {
  --font-display: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
  --font-text: 'Source Serif 4', Georgia, 'Times New Roman', serif;
  --font-ui: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'IBM Plex Mono', 'JetBrains Mono', 'Consolas', monospace;

  --content-width: 740px;
  --rail-width: 280px;
}

/* ---- Dark theme (the primary register — a powered monitor) ---- */
.theme-dark {
  --background-primary: #0E1116;
  --background-primary-alt: #0B0E12;
  --background-secondary: #141923;
  --background-secondary-alt: #1A2029;
  --surface-raised: #161C26;
  --surface-sunken: #0A0D11;

  --text-normal: #D3D8DF;
  --text-muted: #8B95A1;
  --text-faint: #5C6671;

  --scan: #4FB8C6;
  --scan-rgb: 79, 184, 198;
  --scan-hover: #6FCEDA;
  --scan-tint: rgba(79, 184, 198, 0.10);
  --scan-line: rgba(79, 184, 198, 0.32);

  --alert: #E85C61;
  --alert-rgb: 232, 92, 97;
  --alert-hover: #F1787C;
  --alert-tint: rgba(232, 92, 97, 0.11);

  --border: rgba(143, 165, 188, 0.14);
  --border-strong: rgba(143, 165, 188, 0.26);

  --interactive-accent: #4FB8C6;
  --interactive-accent-hover: #6FCEDA;
  --text-accent: #4FB8C6;
  --text-accent-hover: #6FCEDA;
  --background-modifier-border: rgba(143, 165, 188, 0.14);
  --background-modifier-border-hover: rgba(143, 165, 188, 0.26);
  --background-modifier-border-focus: rgba(79, 184, 198, 0.55);

  --graph-line: rgba(143, 165, 188, 0.22);
  --graph-node: #8B95A1;
  --graph-text: #D3D8DF;
  --graph-node-focused: #E85C61;
  --graph-node-tag: #4FB8C6;
  --graph-node-attachment: #5C6671;
  --graph-node-unresolved: #5C6671;

  color-scheme: dark;
}

/* ---- Light theme (a clinical document scan) ---- */
.theme-light {
  --background-primary: #F6F7F9;
  --background-primary-alt: #FFFFFF;
  --background-secondary: #ECEEF1;
  --background-secondary-alt: #E3E6EA;
  --surface-raised: #FFFFFF;
  --surface-sunken: #EAECEF;

  --text-normal: #15191F;
  --text-muted: #515860;
  --text-faint: #79828C;

  --scan: #0C6F7D;
  --scan-rgb: 12, 111, 125;
  --scan-hover: #0A5A65;
  --scan-tint: rgba(12, 111, 125, 0.07);
  --scan-line: rgba(12, 111, 125, 0.45);

  --alert: #BE2A2F;
  --alert-rgb: 190, 42, 47;
  --alert-hover: #9E2226;
  --alert-tint: rgba(190, 42, 47, 0.07);

  --border: rgba(20, 28, 40, 0.12);
  --border-strong: rgba(20, 28, 40, 0.22);

  --interactive-accent: #0C6F7D;
  --interactive-accent-hover: #0A5A65;
  --text-accent: #0C6F7D;
  --text-accent-hover: #0A5A65;
  --background-modifier-border: rgba(20, 28, 40, 0.12);
  --background-modifier-border-hover: rgba(20, 28, 40, 0.22);
  --background-modifier-border-focus: rgba(12, 111, 125, 0.55);

  --graph-line: rgba(20, 28, 40, 0.16);
  --graph-node: #515860;
  --graph-text: #15191F;
  --graph-node-focused: #BE2A2F;
  --graph-node-tag: #0C6F7D;
  --graph-node-attachment: #79828C;
  --graph-node-unresolved: #A7AEB6;

  color-scheme: light;
}

/* =============================================================
   2. HIGH-SPECIFICITY FONT ENFORCEMENT
   Obsidian Publish ships font rules near (0,2,1). The
   `html body[class]` prefix lifts these to (0,2,3) so the
   wiki's typography actually wins. publish.js sets inline
   font-family as a further fallback on slow first paint.
   ============================================================= */

html body[class] .markdown-preview-view,
html body[class] .markdown-rendered,
html body[class] .markdown-preview-view p,
html body[class] .markdown-rendered p,
html body[class] .markdown-preview-view li,
html body[class] .markdown-rendered li,
html body[class] .markdown-preview-view td,
html body[class] .markdown-rendered td,
html body[class] .markdown-preview-view strong,
html body[class] .markdown-rendered strong,
html body[class] .markdown-preview-view em,
html body[class] .markdown-rendered em {
  font-family: var(--font-text);
}

html body[class] .markdown-preview-view h1,
html body[class] .markdown-rendered h1,
html body[class] .markdown-preview-view h2,
html body[class] .markdown-rendered h2 {
  font-family: var(--font-display);
}

html body[class] .markdown-preview-view h3,
html body[class] .markdown-rendered h3,
html body[class] .markdown-preview-view h4,
html body[class] .markdown-rendered h4,
html body[class] .markdown-preview-view h5,
html body[class] .markdown-rendered h5,
html body[class] .markdown-preview-view h6,
html body[class] .markdown-rendered h6 {
  font-family: var(--font-ui);
}

html body[class] .markdown-preview-view code,
html body[class] .markdown-rendered code,
html body[class] .markdown-preview-view pre,
html body[class] .markdown-rendered pre,
html body[class] .markdown-preview-view blockquote,
html body[class] .markdown-rendered blockquote {
  font-family: var(--font-mono);
}

html body[class] .markdown-preview-view th,
html body[class] .markdown-rendered th,
html body[class] .markdown-preview-view table,
html body[class] .markdown-rendered table,
html body[class] .page-kicker,
html body[class] .reading-time,
html body[class] .page-meta-strip,
html body[class] .foia-coversheet,
html body[class] .compilation-footer,
html body[class] .compilation-footer *,
html body[class] .site-body-left-column-site-name,
html body[class] .nav-file-title,
html body[class] .nav-folder-title,
html body[class] .tree-item-inner,
html body[class] .site-body-right-column,
html body[class] .site-body-right-column-inner,
html body[class] .site-body-right-column-inner * {
  font-family: var(--font-ui);
}

/* =============================================================
   3. BASE LAYOUT
   ============================================================= */

html {
  scroll-behavior: smooth;
}

.published-container {
  --font-text-size: 16.5px;
  --line-height: 1.75;
  background: var(--background-primary);
}

.site-body {
  background: var(--background-primary);
}

.markdown-preview-sizer {
  max-width: var(--content-width);
  padding-bottom: 4.5rem;
}

.mod-header {
  padding: 14px 0 10px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 0.5rem;
}

.markdown-preview-view,
.markdown-rendered {
  font-family: var(--font-text);
  font-size: var(--font-text-size);
  line-height: var(--line-height);
  color: var(--text-normal);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* =============================================================
   4. TYPOGRAPHY
   ============================================================= */

.markdown-preview-view h1,
.markdown-rendered h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 2.5rem;
  line-height: 1.12;
  letter-spacing: -0.018em;
  color: var(--text-normal);
  margin: 0.6rem 0 1.35rem;
  scroll-margin-top: 1.5rem;
}

.markdown-preview-view h2,
.markdown-rendered h2 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.92rem;
  line-height: 1.2;
  letter-spacing: -0.012em;
  color: var(--text-normal);
  margin: 3.4rem 0 1.05rem;
  padding-bottom: 0;
  border-bottom: none;
  position: relative;
  scroll-margin-top: 1.5rem;
}

.markdown-preview-view h2::after,
.markdown-rendered h2::after {
  content: "";
  display: block;
  width: 46px;
  height: 2px;
  margin-top: 12px;
  background: var(--scan);
}

.markdown-preview-view h3,
.markdown-rendered h3 {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: 1.18rem;
  line-height: 1.4;
  letter-spacing: -0.003em;
  color: var(--text-normal);
  margin: 2.3rem 0 0.65rem;
  scroll-margin-top: 1.5rem;
}

.markdown-preview-view h4,
.markdown-rendered h4 {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: 0.82rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 2rem 0 0.5rem;
}

.markdown-preview-view h5,
.markdown-rendered h5,
.markdown-preview-view h6,
.markdown-rendered h6 {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: 0.78rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin: 1.6rem 0 0.4rem;
}

.markdown-preview-view p,
.markdown-rendered p {
  margin: 0 0 1.15rem;
}

.markdown-preview-view strong,
.markdown-rendered strong {
  font-weight: 600;
  color: var(--text-normal);
}

.markdown-preview-view em,
.markdown-rendered em {
  font-style: italic;
}

.markdown-preview-view mark,
.markdown-rendered mark {
  background: var(--scan-tint);
  color: var(--text-normal);
  padding: 0 3px;
  border-radius: 2px;
}

/* =============================================================
   5. LINKS — the connective tissue of the wiki
   ============================================================= */

.markdown-preview-view a,
.markdown-rendered a,
.internal-link,
.external-link {
  color: var(--text-accent);
  text-decoration: underline;
  text-decoration-color: var(--scan-line);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  border-bottom: none;
  transition: color 0.15s ease, text-decoration-color 0.15s ease,
              text-underline-offset 0.15s ease;
}

.markdown-preview-view a:hover,
.markdown-rendered a:hover,
.internal-link:hover,
.external-link:hover {
  color: var(--text-accent-hover);
  text-decoration-color: var(--text-accent-hover);
  text-underline-offset: 4px;
}

/* Broken / not-yet-created wikilinks — surfaced, not hidden */
.internal-link.is-unresolved {
  color: var(--text-faint);
  text-decoration-style: dashed;
  text-decoration-color: var(--border-strong);
}

/* =============================================================
   6. BLOCKQUOTE — verbatim evidence from the public record
   The evidentiary spine of the wiki: every quoted record sits
   in the machine register (monospace), framed as a captured
   document fragment.
   ============================================================= */

.markdown-preview-view blockquote,
.markdown-rendered blockquote {
  font-family: var(--font-mono);
  font-size: 0.83rem;
  line-height: 1.66;
  color: var(--text-normal);
  background: var(--scan-tint);
  border: 1px solid var(--border);
  border-left: 3px solid var(--scan);
  border-radius: 0 2px 2px 0;
  margin: 1.6rem 0;
  padding: 14px 18px;
}

.markdown-preview-view blockquote p,
.markdown-rendered blockquote p {
  margin-bottom: 0.7rem;
}

.markdown-preview-view blockquote p:last-child,
.markdown-rendered blockquote p:last-child {
  margin-bottom: 0;
}

.markdown-preview-view blockquote a,
.markdown-rendered blockquote a {
  font-family: var(--font-mono);
}

/* =============================================================
   7. CODE — document IDs, file paths, statutory citations
   ============================================================= */

.markdown-preview-view code,
.markdown-rendered code {
  font-family: var(--font-mono);
  font-size: 0.82em;
  padding: 1px 5px;
  border-radius: 3px;
  background: var(--background-secondary);
  border: 1px solid var(--border);
  color: var(--text-normal);
}

.markdown-preview-view pre,
.markdown-rendered pre {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  line-height: 1.6;
  background: var(--surface-sunken);
  border: 1px solid var(--border);
  border-radius: 3px;
  padding: 14px 16px;
  margin: 1.5rem 0;
  overflow-x: auto;
}

.markdown-preview-view pre code,
.markdown-rendered pre code {
  background: none;
  border: none;
  padding: 0;
  font-size: inherit;
}

/* =============================================================
   8. LISTS
   ============================================================= */

.markdown-preview-view ul,
.markdown-rendered ul,
.markdown-preview-view ol,
.markdown-rendered ol {
  padding-left: 1.5rem;
  margin: 0 0 1.15rem;
}

.markdown-preview-view li,
.markdown-rendered li {
  margin-bottom: 0.4rem;
}

.markdown-preview-view ul > li::marker,
.markdown-rendered ul > li::marker {
  color: var(--scan);
}

.markdown-preview-view ol > li::marker,
.markdown-rendered ol > li::marker {
  color: var(--text-faint);
  font-family: var(--font-mono);
  font-size: 0.85em;
}

/* =============================================================
   9. HORIZONTAL RULE — a measured scan mark
   ============================================================= */

.markdown-preview-view hr,
.markdown-rendered hr {
  border: none;
  height: 1px;
  background: var(--border-strong);
  margin: 3.25rem 0;
  position: relative;
}

.markdown-preview-view hr::before,
.markdown-rendered hr::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 44px;
  height: 1px;
  background: var(--scan);
}

/* =============================================================
   10. TABLES — forensic data
   ============================================================= */

.markdown-preview-view table,
.markdown-rendered table {
  font-family: var(--font-ui);
  font-size: 0.86rem;
  font-variant-numeric: tabular-nums lining-nums;
  border-collapse: collapse;
  width: 100%;
  margin: 1.9rem 0 2.2rem;
  border: none;
}

.markdown-preview-view thead,
.markdown-rendered thead {
  border-bottom: 2px solid var(--scan);
}

.markdown-preview-view th,
.markdown-rendered th {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: 0.66rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  text-align: left;
  color: var(--text-muted);
  background: transparent;
  padding: 11px 14px 9px;
}

.markdown-preview-view td,
.markdown-rendered td {
  font-family: var(--font-ui);
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  line-height: 1.5;
  color: var(--text-normal);
  transition: background 0.12s ease;
}

.markdown-preview-view tbody tr:hover,
.markdown-rendered tbody tr:hover {
  background: var(--scan-tint);
}

.markdown-preview-view td:first-child strong,
.markdown-rendered td:first-child strong {
  font-weight: 600;
  color: var(--text-normal);
}

/* =============================================================
   11. CALLOUTS
   The wiki uses standard callouts (note / warning / important)
   plus the documented contradiction and web-research flags.
   Two colour families: scan (informational) and alert (caution
   / conflict).
   ============================================================= */

.callout {
  --cc: var(--scan-rgb);
  font-family: var(--font-text);
  margin: 1.7rem 0;
  padding: 12px 16px;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-left: 3px solid rgb(var(--cc));
  border-radius: 0 3px 3px 0;
  mix-blend-mode: normal;
}

.callout-title {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: 0.74rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgb(var(--cc));
  padding: 0;
  align-items: center;
  gap: 7px;
}

.callout-title-inner {
  font-family: var(--font-ui);
  color: rgb(var(--cc));
}

.callout-icon {
  color: rgb(var(--cc));
}

.callout-icon .svg-icon {
  width: 15px;
  height: 15px;
}

.callout-content {
  font-family: var(--font-text);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-top: 7px;
  color: var(--text-normal);
}

.callout-content p:last-child {
  margin-bottom: 0;
}

.callout-content code {
  font-size: 0.82em;
}

/* Caution / conflict family → alert red */
.callout[data-callout="warning"],
.callout[data-callout="important"],
.callout[data-callout="caution"],
.callout[data-callout="error"],
.callout[data-callout="danger"],
.callout[data-callout="bug"],
.callout[data-callout="failure"],
.callout[data-callout="contradiction"] {
  --cc: var(--alert-rgb);
  background: var(--alert-tint);
}

/* Quiet / unresolved family → muted */
.callout[data-callout="web-research-unresolved"],
.callout[data-callout="question"],
.callout[data-callout="todo"],
.callout[data-callout="quote"] {
  --cc: var(--scan-rgb);
  background: var(--background-secondary);
  border-left-color: var(--text-faint);
}

.callout[data-callout="web-research-unresolved"] .callout-title,
.callout[data-callout="web-research-unresolved"] .callout-title-inner,
.callout[data-callout="web-research-unresolved"] .callout-icon,
.callout[data-callout="question"] .callout-title,
.callout[data-callout="question"] .callout-title-inner,
.callout[data-callout="question"] .callout-icon {
  color: var(--text-muted);
}

/* =============================================================
   12. IMAGES & EMBEDS
   ============================================================= */

.markdown-preview-view img,
.markdown-rendered img {
  max-width: 100%;
  height: auto;
  border: 1px solid var(--border);
  border-radius: 2px;
  margin: 1.25rem 0;
  cursor: zoom-in;
}

.markdown-rendered span.internal-embed.image-embed,
.markdown-preview-view span.internal-embed.image-embed {
  display: block;
}

.markdown-rendered span.internal-embed.image-embed img,
.markdown-preview-view span.internal-embed.image-embed img {
  display: block;
  width: 100%;
}

.markdown-embed {
  border-left: 2px solid var(--border-strong);
  padding-left: 16px;
  margin: 1.5rem 0;
}

/* =============================================================
   13. MERMAID DIAGRAMS — network / flow graphics
   ============================================================= */

.markdown-preview-view .mermaid,
.markdown-rendered .mermaid {
  font-family: var(--font-ui) !important;
  background: var(--surface-sunken);
  border: 1px solid var(--border);
  border-radius: 3px;
  padding: 1.5rem 1rem;
  margin: 1.7rem 0;
  overflow-x: auto;
  text-align: center;
}

.mermaid .node rect,
.mermaid .node circle,
.mermaid .node ellipse,
.mermaid .node polygon,
.mermaid .node path {
  fill: var(--surface-raised) !important;
  stroke: var(--scan) !important;
  stroke-width: 1.4px !important;
}

.mermaid .nodeLabel,
.mermaid .edgeLabel {
  font-family: var(--font-ui) !important;
  font-size: 12px !important;
  color: var(--text-normal) !important;
}

.mermaid .edgeLabel {
  background: var(--background-primary) !important;
  padding: 1px 5px !important;
}

.mermaid .edgePath path,
.mermaid .flowchart-link {
  stroke: var(--text-faint) !important;
  stroke-width: 1.2px !important;
}

.mermaid .arrowheadPath,
.mermaid marker path {
  fill: var(--text-faint) !important;
  stroke: var(--text-faint) !important;
}

.mermaid .cluster rect {
  fill: var(--background-secondary) !important;
  stroke: var(--border-strong) !important;
  stroke-dasharray: 4 3 !important;
}

.mermaid .cluster text {
  font-family: var(--font-ui) !important;
  font-weight: 600 !important;
  font-size: 11px !important;
  fill: var(--text-muted) !important;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* =============================================================
   14. FRONTMATTER — hidden (metadata, not content)
   ============================================================= */

.frontmatter-container,
.metadata-container {
  display: none;
}

/* =============================================================
   15. LEFT NAV / SIDEBAR
   ============================================================= */

.site-body-left-column {
  border-right: 1px solid var(--border);
  background: var(--background-primary-alt);
}

.site-body-left-column-site-name {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.nav-folder-title,
.nav-file-title,
.tree-item-inner {
  font-family: var(--font-ui);
  font-size: 0.8rem;
  color: var(--text-muted);
  border-radius: 2px;
}

.nav-folder-title {
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text-faint);
  text-transform: uppercase;
  font-size: 0.68rem;
}

.nav-file-title:hover,
.nav-folder-title:hover {
  color: var(--text-normal);
  background: var(--scan-tint);
}

.nav-file-title.is-active,
.tree-item-self.is-active {
  color: var(--scan);
  background: var(--scan-tint);
  box-shadow: inset 2px 0 0 var(--scan);
}

/* =============================================================
   16. RIGHT COLUMN — outline rail + graph view
   ============================================================= */

.site-body-right-column {
  z-index: 2;
}

.site-body-right-column-inner {
  max-width: var(--rail-width);
  font-family: var(--font-ui);
  font-size: 0.78rem;
}

.site-body-right-column-inner .outline-view-outer h3,
.site-body-right-column-inner .graph-view-outer h3 {
  font-family: var(--font-ui);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin-bottom: 0.9rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border);
}

/* Outline rail entries — publish.js marks active / passed */
.site-body-right-column-inner .outline a,
.site-body-right-column-inner a {
  color: var(--text-muted);
  border-left: 2px solid transparent;
  padding-left: 9px;
  margin-left: -11px;
  transition: color 0.18s ease, border-left-color 0.18s ease;
}

.site-body-right-column-inner a:hover {
  color: var(--text-normal);
}

.site-body-right-column-inner a.is-active {
  color: var(--text-normal);
  border-left-color: var(--scan);
  font-weight: 600;
}

.site-body-right-column-inner a.is-passed {
  color: var(--text-faint);
}

.graph-view-container {
  border: 1px solid var(--border);
  border-radius: 3px;
  overflow: hidden;
  background: var(--surface-sunken);
}

/* =============================================================
   17. PAGE KICKER — entity-type label injected by publish.js
   A small monitoring indicator: a status mark + the page type.
   ============================================================= */

.page-kicker {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: 0.64rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--scan);
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 2px 0 12px;
}

.page-kicker::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  background: var(--scan);
  flex: none;
}

[data-page-type="source"] .page-kicker {
  font-family: var(--font-mono);
  font-weight: 500;
  letter-spacing: 0.1em;
}

/* =============================================================
   18. PAGE META STRIP — reading time injected by publish.js
   ============================================================= */

.page-meta-strip {
  font-family: var(--font-ui);
  font-size: 0.75rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  margin: -0.35rem 0 1.4rem;
  padding-bottom: 0.8rem;
  border-bottom: 1px solid var(--border);
}

.reading-time {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-faint);
  display: inline-flex;
  align-items: center;
}

.reading-time::before {
  content: "";
  display: inline-block;
  width: 5px;
  height: 5px;
  margin-right: 7px;
  border: 1px solid var(--text-faint);
  border-radius: 50%;
}

/* =============================================================
   19. FOIA COVER SHEET — injected by publish.js on source pages
   The header of a produced record: agency, production, requester.
   Corner ticks echo the ALPR capture frame.
   ============================================================= */

.foia-coversheet {
  position: relative;
  display: grid;
  grid-template-columns: 108px 1fr;
  gap: 7px 20px;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  color: var(--text-muted);
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-top: 2px solid var(--scan);
  padding: 16px 18px;
  margin: 1.1rem 0 2.4rem;
}

.foia-coversheet::before,
.foia-coversheet::after {
  content: "";
  position: absolute;
  width: 9px;
  height: 9px;
  border: 1px solid var(--scan);
}

.foia-coversheet::before {
  top: 6px;
  right: 6px;
  border-left: none;
  border-bottom: none;
}

.foia-coversheet::after {
  bottom: 6px;
  left: 6px;
  border-right: none;
  border-top: none;
}

.foia-coversheet .cs-label {
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--text-faint);
  padding-top: 1px;
}

.foia-coversheet .cs-value {
  color: var(--text-normal);
  word-break: break-word;
}

/* =============================================================
   20. SCAN LINE — scroll progress bar injected by publish.js
   ============================================================= */

.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 2px;
  width: 0%;
  background: var(--scan);
  box-shadow: 0 0 8px var(--scan-line);
  opacity: 0;
  z-index: 9000;
  pointer-events: none;
  transition: opacity 0.25s ease, width 0.08s linear;
}

.scroll-progress.is-visible {
  opacity: 0.85;
}

/* =============================================================
   21. HEADING ANCHORS — section links injected by publish.js
   ============================================================= */

.markdown-preview-view h2,
.markdown-rendered h2,
.markdown-preview-view h3,
.markdown-rendered h3 {
  position: relative;
}

.heading-anchor {
  position: absolute;
  right: -26px;
  top: 0.15em;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-faint);
  text-decoration: none;
  border: none;
  opacity: 0;
  padding: 2px 5px;
  transition: opacity 0.16s ease, color 0.16s ease;
}

.markdown-preview-view h2:hover .heading-anchor,
.markdown-rendered h2:hover .heading-anchor,
.markdown-preview-view h3:hover .heading-anchor,
.markdown-rendered h3:hover .heading-anchor {
  opacity: 0.6;
}

.heading-anchor:hover {
  opacity: 1;
  color: var(--scan);
}

/* =============================================================
   22. BACKLINKS — the inbound-citation panel
   ============================================================= */

.backlinks {
  font-family: var(--font-ui);
  font-size: 0.82rem;
  margin-top: 4rem;
  padding-top: 1.6rem;
  position: relative;
}

.backlinks::before {
  content: "";
  display: block;
  width: 44px;
  height: 2px;
  background: var(--scan);
  margin-bottom: 1.4rem;
}

.backlink-title {
  font-family: var(--font-ui);
  font-weight: 700;
  font-size: 0.64rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.9rem;
}

.backlinks .tree-item-self {
  padding: 6px 0;
  border-bottom: 1px solid var(--border);
  transition: padding-left 0.16s ease;
}

.backlinks .tree-item-self:hover {
  padding-left: 7px;
}

.backlinks a {
  font-family: var(--font-ui);
  text-decoration: none;
}

/* =============================================================
   23. COMPILATION FOOTER — injected by publish.js
   ============================================================= */

.compilation-footer {
  display: block;
  margin-top: 5rem;
  padding: 1.7rem 0 1.4rem;
  border-top: 1px solid var(--border);
  font-family: var(--font-ui);
  font-size: 0.78rem;
  line-height: 1.6;
  color: var(--text-muted);
  clear: both;
}

.compilation-footer .footer-rule {
  width: 34px;
  height: 2px;
  background: var(--scan);
  margin-bottom: 1rem;
}

.compilation-footer .footer-attribution {
  font-weight: 500;
  color: var(--text-normal);
  margin-bottom: 0.55rem;
}

.compilation-footer .footer-license {
  font-size: 0.74rem;
  color: var(--text-muted);
  margin-bottom: 0.7rem;
}

.compilation-footer .footer-meta {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.03em;
  color: var(--text-faint);
}

.compilation-footer a {
  color: var(--text-muted);
  text-decoration: underline;
  text-decoration-color: var(--border-strong);
}

.compilation-footer a:hover {
  color: var(--text-accent);
  text-decoration-color: var(--text-accent);
}

/* =============================================================
   24. TAGS
   ============================================================= */

.tag {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  padding: 1px 7px;
  border-radius: 2px;
  background: var(--scan-tint);
  border: 1px solid var(--border);
  color: var(--text-accent);
  text-decoration: none;
}

.tag:hover {
  border-color: var(--scan);
}

/* =============================================================
   25. LANDING PAGES — Home, About, How to Read
   The hero title sits inside an ALPR capture frame.
   ============================================================= */

[data-page-type="landing"] .markdown-preview-view h1,
[data-page-type="landing"] .markdown-rendered h1 {
  font-size: 3.35rem;
  line-height: 1.05;
  letter-spacing: -0.026em;
  margin: 1.4rem 0 1.9rem;
  position: relative;
  display: inline-block;
  max-width: 100%;
}

[data-page-type="landing"] .markdown-preview-view h1::before,
[data-page-type="landing"] .markdown-rendered h1::before,
[data-page-type="landing"] .markdown-preview-view h1::after,
[data-page-type="landing"] .markdown-rendered h1::after {
  content: "";
  position: absolute;
  width: 20px;
  height: 20px;
  border: 2px solid var(--scan);
}

[data-page-type="landing"] .markdown-preview-view h1::before,
[data-page-type="landing"] .markdown-rendered h1::before {
  top: -14px;
  left: -18px;
  border-right: none;
  border-bottom: none;
}

[data-page-type="landing"] .markdown-preview-view h1::after,
[data-page-type="landing"] .markdown-rendered h1::after {
  bottom: -14px;
  right: -18px;
  border-left: none;
  border-top: none;
}

/* Lead paragraph — the first paragraph after the hero title */
[data-page-type="landing"] .markdown-preview-view h1 + p,
[data-page-type="landing"] .markdown-rendered h1 + p {
  font-size: 1.16rem;
  line-height: 1.62;
  color: var(--text-muted);
}

[data-page-type="landing"] .markdown-preview-view h2,
[data-page-type="landing"] .markdown-rendered h2 {
  font-size: 2.05rem;
  margin-top: 3.8rem;
}

/* Source-page H1 — reads as a document title, not an editorial headline */
[data-page-type="source"] .markdown-preview-view h1,
[data-page-type="source"] .markdown-rendered h1 {
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 1.95rem;
  letter-spacing: -0.008em;
}

/* Entity / concept / event / synthesis H1 — tighter top margin
   since the kicker already sits above */
[data-page-type="entity"] .markdown-preview-view h1,
[data-page-type="entity"] .markdown-rendered h1,
[data-page-type="concept"] .markdown-preview-view h1,
[data-page-type="concept"] .markdown-rendered h1,
[data-page-type="event"] .markdown-preview-view h1,
[data-page-type="event"] .markdown-rendered h1,
[data-page-type="synthesis"] .markdown-preview-view h1,
[data-page-type="synthesis"] .markdown-rendered h1,
[data-page-type="source"] .markdown-preview-view h1,
[data-page-type="source"] .markdown-rendered h1 {
  margin-top: 0.2rem;
}

/* =============================================================
   26. SELECTION & SCROLLBAR
   ============================================================= */

::selection {
  background: rgba(var(--scan-rgb), 0.26);
  color: var(--text-normal);
}

::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: var(--border-strong);
  border: 2px solid var(--background-primary);
  border-radius: 0;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--scan);
}

* {
  scrollbar-width: thin;
  scrollbar-color: var(--border-strong) transparent;
}

/* =============================================================
   27. RESPONSIVE
   ============================================================= */

@media (max-width: 900px) {
  .heading-anchor {
    display: none;
  }
}

@media (max-width: 768px) {
  .markdown-preview-view,
  .markdown-rendered {
    font-size: 16px;
  }

  .markdown-preview-view h1,
  .markdown-rendered h1 {
    font-size: 1.95rem;
  }

  [data-page-type="landing"] .markdown-preview-view h1,
  [data-page-type="landing"] .markdown-rendered h1 {
    font-size: 2.2rem;
    display: block;
  }

  [data-page-type="landing"] .markdown-preview-view h1::before,
  [data-page-type="landing"] .markdown-rendered h1::before,
  [data-page-type="landing"] .markdown-preview-view h1::after,
  [data-page-type="landing"] .markdown-rendered h1::after {
    width: 14px;
    height: 14px;
  }

  .markdown-preview-view h2,
  .markdown-rendered h2 {
    font-size: 1.5rem;
    margin-top: 2.6rem;
  }

  .markdown-preview-view h3,
  .markdown-rendered h3 {
    font-size: 1.08rem;
  }

  .markdown-preview-view blockquote,
  .markdown-rendered blockquote {
    font-size: 0.78rem;
    padding: 12px 14px;
  }

  .foia-coversheet {
    grid-template-columns: 84px 1fr;
    font-size: 0.7rem;
  }

  .markdown-preview-view table,
  .markdown-rendered table {
    font-size: 0.8rem;
  }
}

/* =============================================================
   28. PRINT
   ============================================================= */

@media print {
  .site-body-left-column,
  .site-body-right-column,
  .mod-header,
  .scroll-progress,
  .heading-anchor,
  .backlinks {
    display: none;
  }

  .markdown-preview-sizer {
    max-width: 100%;
  }

  .markdown-preview-view,
  .markdown-rendered {
    color: #000;
  }

  .markdown-preview-view blockquote,
  .markdown-rendered blockquote {
    background: #f4f4f4;
    border-left: 2px solid #555;
    color: #000;
  }

  .callout,
  .foia-coversheet,
  table {
    break-inside: avoid;
  }

  a {
    color: #000;
    text-decoration: underline;
  }
}
