:root {
  --bg: #f5edd9;
  --bg-soft: #ede2c7;
  --fg: #2a2418;
  --muted: #6b5d44;
  --accent: #5a3a1f;
  --accent-soft: #7d5128;
  --moss: #4a5f3a;
  --rule: #d4c8a8;
  --card: #faf3df;
  --quote: #6b5128;
  --max-width: 760px;
  --serif: "Old Standard TT", "EB Garamond", Georgia, "Palatino Linotype", Palatino, serif;
  --sans: "PT Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--serif);
  font-size: 19px;
  line-height: 1.72;
  -webkit-font-smoothing: antialiased;
  font-weight: 400;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
}

.site-header {
  border-bottom: 2px solid var(--rule);
  background: var(--bg);
  padding: 1.1rem 0;
  margin-bottom: 2.5rem;
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}
.site-title {
  font-family: var(--serif);
  font-size: 1.7rem;
  font-weight: 700;
  color: var(--accent);
  text-decoration: none;
  letter-spacing: 0.04em;
  font-variant: small-caps;
}
.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.1rem;
  font-family: var(--sans);
  font-size: 0.95rem;
}
.site-nav a {
  color: var(--fg);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  padding-bottom: 2px;
}
.site-nav a:hover, .site-nav a.active { color: var(--accent); border-bottom-color: var(--accent-soft); }

main.container { padding-bottom: 3rem; min-height: 60vh; }

h1, h2, h3, h4 { font-family: var(--serif); line-height: 1.25; color: var(--fg); font-weight: 700; }
h1 { font-size: 2.15rem; margin: 0.2em 0 0.4em; letter-spacing: 0.005em; }
h2 { font-size: 1.55rem; margin: 1.9em 0 0.5em; color: var(--accent); }
h3 { font-size: 1.25rem; margin: 1.5em 0 0.4em; color: var(--accent-soft); }
p, ul, ol { margin: 0 0 1.15em; }
ul, ol { padding-left: 1.4em; }
li { margin-bottom: 0.35em; }
blockquote {
  border-left: 4px solid var(--moss);
  padding: 0.5em 1.4em;
  margin: 1.6em 0;
  color: var(--quote);
  font-style: italic;
  background: var(--bg-soft);
  border-radius: 0 4px 4px 0;
}
blockquote p:last-child { margin-bottom: 0; }
hr { border: 0; border-top: 1px solid var(--rule); margin: 2.2em 0; }
a { color: var(--accent); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 2px; text-decoration-color: rgba(90, 58, 31, 0.45); }
a:hover { color: var(--accent-soft); text-decoration-color: var(--accent-soft); }
code { background: var(--bg-soft); color: var(--accent); padding: 0.1em 0.35em; border-radius: 3px; font-size: 0.92em; }
img { max-width: 100%; height: auto; display: block; margin: 1em auto; }
strong { color: var(--fg); font-weight: 700; }
em { color: var(--quote); }

::selection { background: var(--accent); color: var(--bg); }

.home-hero { padding: 1.5rem 0 2.5rem; border-bottom: 1px solid var(--rule); margin-bottom: 2rem; text-align: center; }
.home-hero h1 { font-size: 3.2rem; margin-bottom: 0.2em; color: var(--accent); font-weight: 700; letter-spacing: 0.05em; font-variant: small-caps; }
.home-hero .lede { font-size: 1.18rem; color: var(--muted); max-width: 62ch; margin-left: auto; margin-right: auto; line-height: 1.55; font-style: italic; }

.home-sections {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
  margin: 2rem 0 3rem;
}
.section-card {
  background: var(--card);
  border: 1px solid var(--rule);
  padding: 1.4rem 1.5rem;
  border-radius: 4px;
  transition: border-color 0.15s ease, transform 0.15s ease;
}
.section-card:hover { border-color: var(--moss); transform: translateY(-1px); }
.section-card h2 { margin-top: 0; font-size: 1.25rem; color: var(--accent); }
.section-card h2 a { color: var(--accent); text-decoration: none; }
.section-card h2 a:hover { color: var(--accent-soft); }
.section-card p { margin-bottom: 0; color: var(--muted); font-size: 0.97rem; }

.home-recent h2 { font-size: 1.4rem; border-top: 1px solid var(--rule); padding-top: 2rem; margin-top: 1rem; color: var(--accent); }

.post-list { list-style: none; padding: 0; margin: 0; }
.post-item { border-bottom: 1px solid var(--rule); padding: 1.2rem 0; }
.post-item:last-child { border-bottom: 0; }
.post-link { display: block; text-decoration: none; color: inherit; }
.post-item-title { margin: 0 0 0.3em; color: var(--accent); font-size: 1.3rem; font-weight: 700; }
.post-link:hover .post-item-title { color: var(--accent-soft); }
.post-item-summary { color: var(--muted); margin: 0 0 0.4em; font-size: 1rem; font-style: italic; }
.post-item-meta { font-family: var(--sans); font-size: 0.85rem; color: var(--muted); }

.post-header { border-bottom: 1px solid var(--rule); padding-bottom: 1rem; margin-bottom: 1.5rem; }
.post-title { color: var(--accent); margin-bottom: 0.3em; font-variant: small-caps; letter-spacing: 0.015em; }
.post-meta { font-family: var(--sans); font-size: 0.88rem; color: var(--muted); }
.post-meta .dot { margin: 0 0.4em; opacity: 0.6; }
.post-meta a { color: var(--muted); }
.post-content { font-size: 1.05rem; }
.post-content p:first-of-type::first-letter { font-size: 3rem; float: left; line-height: 0.9; padding: 0.05em 0.1em 0 0; color: var(--accent); font-weight: 700; }

.post-footer { margin-top: 2.5rem; border-top: 1px solid var(--rule); padding-top: 1rem; }
.tags { font-family: var(--sans); font-size: 0.85rem; }
.tag { color: var(--muted); margin-right: 0.6em; text-decoration: none; }
.tag:hover { color: var(--accent); }

.section-list .section-header { margin-bottom: 1.5rem; padding-bottom: 1rem; border-bottom: 1px solid var(--rule); }
.section-list .section-header h1 { color: var(--accent); font-variant: small-caps; }
.section-intro { color: var(--muted); font-style: italic; font-size: 1.05rem; }

.not-found { text-align: center; padding: 3rem 0; }
.not-found h1 { color: var(--accent); }

.site-footer {
  border-top: 2px solid var(--rule);
  margin-top: 4rem;
  padding: 1.8rem 0 2rem;
  font-family: var(--sans);
  font-size: 0.86rem;
  color: var(--muted);
}
.footer-inner { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 1rem; align-items: center; }
.footer-nav { display: flex; gap: 1.2rem; flex-wrap: wrap; }
.footer-nav a { color: var(--muted); text-decoration: none; }
.footer-nav a:hover { color: var(--accent); }

@media (max-width: 560px) {
  body { font-size: 17.5px; }
  h1 { font-size: 1.8rem; }
  h2 { font-size: 1.35rem; }
  .site-nav { font-size: 0.9rem; gap: 0.8rem; }
  .home-hero h1 { font-size: 2.4rem; }
  .home-hero .lede { font-size: 1.05rem; }
  .site-title { font-size: 1.45rem; }
  .post-content p:first-of-type::first-letter { font-size: 2.3rem; }
}
