:root {
  --ink-900: #0f172a;
  --ink-600: #475569;
  --ink-500: #64748b;
  --ink-400: #94a3b8;
  --brand-600: #0d9488;
  --paper: #ffffff;
  --line: #e2e8f0;
  --font: Inter, system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink-600);
  background: var(--paper);
  line-height: 1.6;
}

a { color: var(--brand-600); text-decoration: none; }

a:hover { text-decoration: underline; }

.container {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.site-header {
  border-bottom: 1px solid var(--line);
  padding: 1rem 0;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.site-logo {
  font-weight: 800;
  font-size: 1.25rem;
  color: var(--ink-900);
}

.site-header nav a {
  margin-left: 1.25rem;
  color: var(--ink-600);
  font-weight: 600;
}

.site-footer {
  border-top: 1px solid var(--line);
  margin-top: 4rem;
  padding: 2rem 0;
  text-align: center;
  color: var(--ink-400);
  font-size: 0.9rem;
}

.site-footer .fine { font-size: 0.8rem; }

.home-hero {
  padding: 4rem 0 2rem;
  text-align: center;
}

.home-hero h1 {
  color: var(--ink-900);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0 0 0.75rem;
}

.home-hero p {
  max-width: 36rem;
  margin: 0 auto 2rem;
  font-size: 1.125rem;
  color: var(--ink-500);
}

.empty-note {
  border: 1px dashed var(--line);
  border-radius: 12px;
  padding: 2rem;
  text-align: center;
  color: var(--ink-500);
  background: #f8fafc;
}

.post-page { padding: 3rem 0; }

.post-header h1 {
  color: var(--ink-900);
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  margin-bottom: 0.5rem;
}

.post-header time { color: var(--ink-400); font-size: 0.9rem; }

.post-body { margin-top: 2rem; }

/* Home post list */

.home-posts {
  padding: 0 0 4rem;
}

.post-list {
  display: grid;
  gap: 1.25rem;
  text-align: left;
}

.post-card {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

.post-card:hover {
  border-color: var(--brand-600);
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
}

.post-card-link {
  display: block;
  padding: 1.5rem 1.5rem 1.25rem;
  color: inherit;
  text-decoration: none;
}

.post-card-link:hover {
  text-decoration: none;
}

.post-card-title {
  margin: 0 0 0.5rem;
  color: var(--ink-900);
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  line-height: 1.3;
}

.post-card-excerpt {
  margin: 0 0 1rem;
  color: var(--ink-500);
  font-size: 0.98rem;
  line-height: 1.55;
}

.post-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--ink-400);
  font-size: 0.875rem;
}

.post-card-meta .read-link {
  color: var(--brand-600);
  font-weight: 700;
}

/* Post body typography */

.post-body h2 {
  color: var(--ink-900);
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  margin: 2.25rem 0 0.85rem;
  line-height: 1.25;
}

.post-body h3 {
  color: var(--ink-900);
  font-size: 1.15rem;
  font-weight: 700;
  margin: 1.75rem 0 0.6rem;
}

.post-body p {
  margin: 0 0 1.1rem;
}

.post-body ul,
.post-body ol {
  margin: 0 0 1.25rem;
  padding-left: 1.35rem;
}

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

.post-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.25rem 0 0.5rem;
  font-size: 0.95rem;
}

.post-body th,
.post-body td {
  border: 1px solid var(--line);
  padding: 0.65rem 0.75rem;
  text-align: left;
  vertical-align: top;
}

.post-body th {
  background: #f8fafc;
  color: var(--ink-900);
  font-weight: 700;
}

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

.post-body code {
  font-size: 0.9em;
  background: #f1f5f9;
  padding: 0.1em 0.35em;
  border-radius: 4px;
}

.post-body strong {
  color: var(--ink-900);
}
