:root {
  --bg: #faf7f2;
  --surface: #ffffff;
  --text: #2b2622;
  --muted: #6f655c;
  --border: #e6ded3;
  --accent: #9a3b26;
  --accent-hover: #7a2d1c;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1b1816;
    --surface: #24201d;
    --text: #ece6df;
    --muted: #a69b90;
    --border: #3a332d;
    --accent: #e08a6d;
    --accent-hover: #f0a78e;
  }
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.65 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.wrap {
  width: 100%;
  max-width: 44rem;
  margin: 0 auto;
  padding: 0 16px;
}

a {
  color: var(--accent);
}

a:hover {
  color: var(--accent-hover);
}

.site-header {
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}

.site-header .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem 1.5rem;
  padding-top: 1rem;
  padding-bottom: 1rem;
}

.site-name {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
}

.site-header nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.25rem;
}

.site-header nav a {
  color: var(--muted);
  text-decoration: none;
}

.site-header nav a:hover {
  color: var(--accent);
}

main {
  flex: 1;
  padding-top: 2.5rem;
  padding-bottom: 3rem;
}

.prose h1,
.prose h2,
.prose h3 {
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.25;
}

.prose h1 {
  font-size: 2rem;
  margin: 0 0 1rem;
}

.prose h2 {
  font-size: 1.4rem;
  margin: 2rem 0 0.75rem;
}

.prose img {
  max-width: 100%;
  height: auto;
  border-radius: 6px;
}

.prose table {
  width: 100%;
  border-collapse: collapse;
  display: block;
  overflow-x: auto;
}

.prose th,
.prose td {
  border-bottom: 1px solid var(--border);
  padding: 0.4rem 0.75rem 0.4rem 0;
  text-align: left;
}

.prose blockquote {
  margin: 1.5rem 0;
  padding: 0.25rem 1rem;
  border-left: 3px solid var(--accent);
  color: var(--muted);
}

.meta {
  color: var(--muted);
  margin-top: -0.5rem;
}

.posts {
  margin-top: 3rem;
  border-top: 1px solid var(--border);
  padding-top: 1.5rem;
}

.posts h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.4rem;
  margin: 0 0 1rem;
}

.posts ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.posts li {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0 1rem;
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--border);
}

.posts time {
  color: var(--muted);
  font-size: 0.9rem;
}

.back {
  margin-top: 2.5rem;
}

.site-footer {
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.9rem;
}

.site-footer .wrap {
  padding-top: 1.25rem;
  padding-bottom: 1.25rem;
}
