/* The reader page, served by the app through the bos: scheme and by the website
   for its preview. No web fonts: it has to work offline. */
:root {
  --bg: #fbfaf7;
  --ink: #1c1e20;
  --muted: #5d6267;
  --line: #e3dfd6;
  --accent: #a85f00;
  --quote: #f3f0e9;
  --status-bg: #fff3d6;
  --status-line: #e3a336;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #151719;
    --ink: #ebe9e4;
    --muted: #a4a9ae;
    --line: #2c3035;
    --accent: #f2ad45;
    --quote: #1d2023;
    --status-bg: #2a2214;
    --status-line: #8a6420;
  }
}
* { box-sizing: border-box; }
html { background: var(--bg); }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 17px/1.62 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
article { max-width: 44rem; margin: 0 auto; padding: 2rem 1.5rem 4rem; }
.crumbs { color: var(--muted); font-size: 0.85rem; }
.crumbs span { margin: 0 0.25rem; }
h1 { font-size: 2rem; line-height: 1.2; margin: 0.4rem 0 0.6rem; letter-spacing: -0.01em; }
h1 .code {
  font: 600 0.95rem/1 ui-monospace, "SF Mono", Consolas, monospace;
  color: var(--accent);
  vertical-align: middle;
  margin-right: 0.35rem;
}
h2 { font-size: 1.3rem; margin: 2.4rem 0 0.6rem; padding-top: 0.6rem; border-top: 1px solid var(--line); }
.tags { display: flex; flex-wrap: wrap; gap: 0.4rem; align-items: center; margin: 0 0 1rem; }
.tag {
  font: 600 0.72rem/1 ui-monospace, "SF Mono", Consolas, monospace;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.25rem 0.5rem;
}
.tag-caution { border-color: var(--status-line); color: var(--accent); }
.meta { color: var(--muted); font-size: 0.82rem; margin-left: 0.2rem; }
.status {
  background: var(--status-bg);
  border-left: 4px solid var(--status-line);
  padding: 0.7rem 0.9rem;
  border-radius: 4px;
  font-size: 0.92rem;
}
.summary { font-size: 1.12rem; }
.toc { color: var(--muted); padding-left: 1.2rem; font-size: 0.95rem; }
a { color: var(--accent); }
blockquote {
  margin: 1rem 0;
  padding: 0.6rem 1rem;
  background: var(--quote);
  border-left: 3px solid var(--accent);
  border-radius: 0 4px 4px 0;
}
blockquote p { margin: 0; }
table { border-collapse: collapse; width: 100%; margin: 1rem 0; font-size: 0.95rem; }
th, td { text-align: left; padding: 0.45rem 0.6rem; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-weight: 600; }
.cites { color: var(--muted); font-size: 0.85rem; margin-top: 1rem; }
.cites a { text-decoration: none; }
.sources { font-size: 0.88rem; color: var(--muted); }
.sources li { margin-bottom: 0.8rem; }
.sources strong { color: var(--ink); }
.url { font-family: ui-monospace, "SF Mono", Consolas, monospace; font-size: 0.8rem; word-break: break-all; }
footer { margin-top: 2.5rem; padding-top: 1rem; border-top: 1px solid var(--line); color: var(--muted); font-size: 0.85rem; }
