:root {
  color-scheme: light dark;
  --background: #faf9f6;
  --foreground: #24231f;
  --muted: #6c6a63;
  --border: #d9d5cc;
  --accent: #765b35;
  --measure: 46rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --background: #191816;
    --foreground: #eeeae1;
    --muted: #aaa59b;
    --border: #3a3833;
    --accent: #d3aa70;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0 auto;
  max-width: 64rem;
  padding: 2rem 1.25rem;
  background: var(--background);
  color: var(--foreground);
  font-family: ui-serif, Georgia, Cambria, "Times New Roman", serif;
  font-size: 1.08rem;
  line-height: 1.65;
}

a { color: var(--accent); text-underline-offset: 0.16em; }
a:hover { text-decoration-thickness: 0.13em; }

.site-header,
footer {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  border-color: var(--border);
}

.site-header { padding-bottom: 1rem; border-bottom: 1px solid var(--border); }
.site-title { color: var(--foreground); font-weight: 700; text-decoration: none; }
nav { display: flex; flex-wrap: wrap; gap: 1rem; }
main { max-width: var(--measure); margin: 4rem 0; }
h1, h2, h3 { line-height: 1.2; }
h1 { font-size: clamp(2rem, 6vw, 3.5rem); }
.intro p { color: var(--muted); font-size: 1.2rem; }
.note-list { padding: 0; list-style: none; }
.note-list li { padding: 1rem 0; border-bottom: 1px solid var(--border); }
.note-list a { font-size: 1.2rem; }
.note-list time { margin-left: 0.75rem; color: var(--muted); font-size: 0.9rem; }
.note-list p { margin: 0.25rem 0 0; color: var(--muted); }
.note-header time, .tags { color: var(--muted); }
.note-content img { max-width: 100%; height: auto; }
blockquote { margin-left: 0; padding-left: 1rem; border-left: 3px solid var(--border); color: var(--muted); }
code { font-size: 0.9em; }
footer { padding-top: 1rem; border-top: 1px solid var(--border); color: var(--muted); font-size: 0.9rem; }

@media (max-width: 38rem) {
  .site-header, footer { align-items: flex-start; flex-direction: column; }
  main { margin: 2.5rem 0; }
  .note-list time { display: block; margin-left: 0; }
}
