*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --text: #1a1a1a;
  --muted: #767676;
  --border: #e5e5e5;
  --bg: #ffffff;
  --link: #1a1a1a;
  --link-hover: #555;
  --max-width: 660px;
}

html {
  font-size: 18px;
}

body {
  font-family: Georgia, 'Times New Roman', serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.75;
  padding: 0 1.5rem;
}

/* ── Layout ── */
.site {
  max-width: var(--max-width);
  margin: 0 auto;
}

/* ── Header ── */
header {
  padding: 3rem 0 2rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.site-title {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-decoration: none;
  color: var(--text);
}

nav {
  display: flex;
  gap: 1.5rem;
}

nav a {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 0.85rem;
  color: var(--muted);
  text-decoration: none;
  letter-spacing: 0.04em;
}

nav a:hover,
nav a.active {
  color: var(--text);
}

/* ── Main content ── */
main {
  padding: 3rem 0;
}

/* ── Post list (index) ── */
.post-list {
  list-style: none;
}

.post-list li {
  padding: 1.75rem 0;
  border-bottom: 1px solid var(--border);
}

.post-list li:first-child {
  padding-top: 0;
}

.post-date {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 0.78rem;
  color: var(--muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 0.35rem;
}

.post-title {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
}

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

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

.post-excerpt {
  font-size: 0.95rem;
  color: #444;
  line-height: 1.65;
}

/* ── Single post ── */
.post-header {
  margin-bottom: 2.5rem;
}

.post-header .post-date {
  margin-bottom: 0.6rem;
}

.post-header h1 {
  font-size: 1.8rem;
  line-height: 1.3;
  font-weight: 700;
}

.post-body h2 {
  font-size: 1.25rem;
  margin-top: 2.5rem;
  margin-bottom: 0.75rem;
}

.post-body p {
  margin-bottom: 1.4rem;
}

.post-body a {
  color: var(--link);
}

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

.post-body ul,
.post-body ol {
  margin: 0 0 1.4rem 1.5rem;
}

.post-body li {
  margin-bottom: 0.3rem;
}

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

.post-body code {
  font-family: 'Courier New', monospace;
  font-size: 0.85em;
  background: #f4f4f4;
  padding: 0.1em 0.4em;
  border-radius: 3px;
}

.back-link {
  display: inline-block;
  margin-top: 3rem;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 0.85rem;
  color: var(--muted);
  text-decoration: none;
  letter-spacing: 0.04em;
}

.back-link:hover {
  color: var(--text);
}

/* ── About page ── */
.about h1 {
  font-size: 1.8rem;
  margin-bottom: 1.5rem;
}

.about p {
  margin-bottom: 1.4rem;
}

/* ── Footer ── */
footer {
  padding: 2rem 0 3rem;
  border-top: 1px solid var(--border);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 0.8rem;
  color: var(--muted);
}
