:root {
  --ivory: #faf7f0;
  --paper: #f4efe3;
  --ink: #2a2a2c;
  --muted: #7a766c;
  --accent: #5a6876;
  --rule: rgba(42, 42, 44, 0.18);
}

@media (prefers-color-scheme: dark) {
  :root {
    --ivory: #1c1a16;
    --paper: #221f18;
    --ink: #ede3ce;
    --muted: #9a9286;
    --accent: #98a6b3;
    --rule: rgba(237, 227, 206, 0.22);
  }
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  background: var(--ivory);
  color: var(--ink);
  font-family: "Iowan Old Style", "Charter", "Georgia", serif;
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -webkit-text-size-adjust: 100%;
}

main {
  max-width: 720px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4rem;
}

header {
  border-bottom: 1px dashed var(--rule);
  padding-bottom: 1rem;
  margin-bottom: 1.5rem;
}

h1 {
  margin: 0;
  font-weight: 500;
  font-size: 1.9rem;
  letter-spacing: 0.04em;
}

h2 {
  margin: 2rem 0 0.6rem;
  font-weight: 500;
  font-size: 1.15rem;
  letter-spacing: 0.03em;
  color: var(--ink);
}

p { margin: 0 0 0.7rem; }

ul, ol {
  margin: 0 0 0.8rem;
  padding-left: 1.3rem;
}

li { margin-bottom: 0.35rem; }

a {
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px dotted var(--accent);
}
a:hover { border-bottom-style: solid; }

.sub {
  color: var(--muted);
  font-size: 0.95rem;
  margin: 0.2rem 0;
}
.sub.italic { font-style: italic; }

code {
  font-family: "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.9em;
  background: var(--paper);
  padding: 0.05rem 0.35rem;
  border-radius: 2px;
  letter-spacing: 0.02em;
}

em { font-style: italic; color: var(--ink); }
strong { font-weight: 600; }

footer {
  margin-top: 3rem;
  padding-top: 1.2rem;
  border-top: 1px dashed var(--rule);
  text-align: center;
}

.muted {
  color: var(--muted);
  font-style: italic;
  font-size: 0.9rem;
}
.muted.small {
  font-size: 0.78rem;
  margin-top: 0.4rem;
}
