:root {
  --bg: #faf8f4;
  --ink: #1f1d1a;
  --muted: #8a847a;
  --rule: #e4dfd6;
  --accent: #9a3b2e;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #161513;
    --ink: #e9e4da;
    --muted: #8d877c;
    --rule: #2c2a26;
    --accent: #d98a74;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "EB Garamond", Georgia, "Times New Roman", serif;
  font-size: 20px;
  line-height: 1.6;
}
.wrap { max-width: 34rem; margin: 0 auto; padding: 4.5rem 1.5rem 3rem; }
a { color: inherit; text-decoration: none; }
header { margin-bottom: 3.5rem; }
.name { font-size: 1.1rem; letter-spacing: 0.14em; text-transform: uppercase; font-weight: 500; }
.name a:hover { color: var(--accent); }
.tag { color: var(--muted); font-style: italic; margin-top: 0.15rem; }

ol.index { list-style: none; margin: 0; padding: 0; }
ol.index li { border-top: 1px solid var(--rule); }
ol.index li:last-child { border-bottom: 1px solid var(--rule); }
ol.index a {
  display: flex; justify-content: space-between; align-items: baseline; gap: 1rem;
  padding: 0.9rem 0;
}
ol.index a:hover .t { color: var(--accent); }
ol.index .d { color: var(--muted); font-size: 0.85rem; white-space: nowrap; font-variant-numeric: oldstyle-nums; }

article h1 { font-weight: 400; font-size: 1.9rem; line-height: 1.25; margin: 0 0 0.3rem; }
article .d { color: var(--muted); font-size: 0.9rem; margin-bottom: 2.5rem; font-variant-numeric: oldstyle-nums; }
.body { white-space: pre-wrap; overflow-wrap: break-word; }

.note { margin-top: 3.5rem; font-size: 0.95rem; line-height: 1.65; }
.note-h { color: var(--muted); font-size: 0.8rem; letter-spacing: 0.14em; text-transform: uppercase; margin-bottom: 0.9rem; }
.note p { margin: 0 0 1em; }
.note a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }

nav.pn {
  display: flex; justify-content: space-between; gap: 1rem;
  margin-top: 4rem; padding-top: 1.25rem; border-top: 1px solid var(--rule);
  font-size: 0.95rem; color: var(--muted);
}
nav.pn a:hover { color: var(--accent); }
nav.pn .next { text-align: right; margin-left: auto; }

footer { margin-top: 5rem; color: var(--muted); font-size: 0.85rem; }
.empty { color: var(--muted); font-style: italic; }
@media (max-width: 480px) {
  body { font-size: 18px; }
  .wrap { padding-top: 3rem; }
}
