@import url('https://fonts.googleapis.com/css2?family=Libre+Baskerville:ital,wght@0,400;0,700;1,400&family=Inter:wght@400;500&display=swap');

:root {
  --ink: #1a1a1a;
  --paper: #faf8f4;
  --accent: #c0392b;
  --muted: #767676;
  --rule: #d8d4cc;
  --max: 38rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #e8e4dc;
    --paper: #18171a;
    --accent: #e06b5f;
    --muted: #9a9494;
    --rule: #2e2c30;
  }
}

body {
  font-family: 'Libre Baskerville', Georgia, serif;
  background-color: var(--paper);
  color: var(--ink);
  font-size: 1rem;
  line-height: 1.8;
}

a {
  color: var(--ink);
  text-decoration-color: var(--accent);
  text-underline-offset: 3px;
}

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

/* Strip */
.strip {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.75rem;
  background: var(--paper);
  border-bottom: 1px solid var(--rule);
  color: var(--muted);
  padding: 0.5rem 1.2rem;
}

.strip a {
  color: var(--muted);
  text-decoration: none;
}

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

/* Masthead */
.masthead {
  max-width: var(--max);
  padding-top: 4rem;
  padding-bottom: 2rem;
  border-bottom: 2px solid var(--ink);
  margin-bottom: 2.5rem;
}

.blog-title {
  font-family: 'Libre Baskerville', Georgia, serif;
  font-size: 1.9rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 0.6rem 0 0;
}

.blog-title a {
  text-decoration: none;
  color: var(--ink);
}

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

.tagline {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.85rem;
  color: var(--muted);
  margin-top: 0.5rem;
  font-style: normal;
  letter-spacing: 0.01em;
}

/* Avatar */
.avatar {
  display: block;
  width: 4rem;
  height: 4rem;
  margin-bottom: 0.8rem;
  border-radius: 0;
}

/* Main content */
main {
  max-width: var(--max);
}

/* About section */
.about {
  margin-bottom: 3rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--rule);
}

.about p {
  margin-top: 0;
  font-size: 0.95rem;
  color: var(--ink);
}

/* Posts section */
.posts h2 {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 1rem;
  border: none;
}

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

.post-list li {
  border-bottom: 1px solid var(--rule);
  padding: 0.8rem 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.3rem 1rem;
}

.post-link {
  font-family: 'Libre Baskerville', Georgia, serif;
  font-size: 1rem;
  text-decoration: none;
  color: var(--ink);
}

.post-link:hover {
  color: var(--accent);
}

time {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.78rem;
  color: var(--muted);
  white-space: nowrap;
}

.empty {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.85rem;
  color: var(--muted);
  font-style: italic;
}

/* Post page */
article {
  margin-top: 1rem;
}

.post-header h1 {
  font-size: 1.7rem;
  font-weight: 700;
  line-height: 1.25;
  margin: 0 0 0.4rem;
  letter-spacing: -0.02em;
}

.post-header time {
  display: block;
  margin-bottom: 2rem;
}

.post-body {
  font-size: 1rem;
  line-height: 1.85;
}

.post-body p {
  margin: 0 0 1.4em;
}

.post-body h2 {
  font-size: 1.2rem;
  margin-top: 2.5rem;
  margin-bottom: 0.5rem;
  font-weight: 700;
}

.post-body h3,
.post-body h4 {
  font-size: 1rem;
  font-weight: 700;
  margin-top: 2rem;
  margin-bottom: 0.4rem;
}

.post-body blockquote {
  border-left: 3px solid var(--accent);
  color: var(--muted);
  padding-left: 1.2rem;
  margin: 1.5rem 0;
  font-style: italic;
}

.post-body pre {
  background: var(--rule);
  border: none;
  border-radius: 3px;
  padding: 1rem 1.2rem;
  font-size: 0.82rem;
  line-height: 1.6;
  overflow-x: auto;
}

.post-body code {
  font-size: 0.85em;
  background: var(--rule);
  padding: 0.1em 0.3em;
  border-radius: 2px;
}

.post-body pre code {
  background: none;
  padding: 0;
}

.post-body hr {
  border: none;
  border-top: 1px solid var(--rule);
  margin: 2.5rem 0;
}

/* Notice and receipt */
.notice {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.82rem;
  color: var(--muted);
  border-left: 3px solid var(--accent);
  padding-left: 0.8rem;
  margin-top: 2rem;
}

.receipt {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.78rem;
  color: var(--muted);
  margin-top: 3rem;
  padding-top: 1rem;
  border-top: 1px solid var(--rule);
}

/* Colophon */
.colophon {
  border-top: 1px solid var(--rule);
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.75rem;
  color: var(--muted);
  padding-top: 1.2rem;
  padding-bottom: 3rem;
}

/* Responsive */
@media (max-width: 480px) {
  .masthead {
    padding-top: 2.5rem;
  }

  .blog-title {
    font-size: 1.5rem;
  }

  .post-header h1 {
    font-size: 1.4rem;
  }
}
