:root {
  --bg: #fafafa;
  --surface: #ffffff;
  --text: #18181b;
  --text-dim: #52525b;
  --text-faint: #a1a1aa;
  --accent: #4f46e5;
  --accent-soft: #eef2ff;
  --line: #e4e4e7;
  --radius: 14px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #101014;
    --surface: #18181d;
    --text: #f4f4f5;
    --text-dim: #a1a1aa;
    --text-faint: #63636b;
    --accent: #818cf8;
    --accent-soft: #1e1b3a;
    --line: #27272e;
  }
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

.wrap { max-width: 880px; margin: 0 auto; padding: 0 24px; }

header.site {
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}
header.site .wrap {
  display: flex; align-items: center; justify-content: space-between;
  height: 64px;
}
.brand {
  display: flex; align-items: center; gap: 10px;
  font-weight: 700; font-size: 1.05rem; color: var(--text);
  text-decoration: none; letter-spacing: -0.01em;
}
.brand img { width: 28px; height: 28px; border-radius: 7px; }
nav.site a {
  color: var(--text-dim); text-decoration: none; font-size: 0.92rem;
  margin-left: 22px;
}
nav.site a:hover { color: var(--text); }

main { padding: 56px 0 72px; }

.hero { padding: 40px 0 8px; }
.hero h1 {
  font-size: clamp(1.9rem, 4.5vw, 2.9rem);
  line-height: 1.15; letter-spacing: -0.02em; max-width: 640px;
}
.hero p.lead {
  margin-top: 18px; font-size: 1.12rem; color: var(--text-dim);
  max-width: 620px;
}

section { margin-top: 64px; }
section > h2 {
  font-size: 1.45rem; letter-spacing: -0.01em; margin-bottom: 10px;
}
section > p.intro { color: var(--text-dim); max-width: 640px; }

.grid {
  display: grid; gap: 16px; margin-top: 28px;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
}
.card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px;
}
.card h3 { font-size: 1rem; margin-bottom: 6px; }
.card p { font-size: 0.92rem; color: var(--text-dim); }

.callout {
  margin-top: 28px; padding: 22px 24px;
  background: var(--accent-soft); border: 1px solid var(--line);
  border-radius: var(--radius);
}
.callout strong { color: var(--accent); }

article.prose { max-width: 720px; }
article.prose h1 {
  font-size: 2rem; letter-spacing: -0.02em; margin-bottom: 6px;
}
article.prose p.meta { color: var(--text-faint); font-size: 0.9rem; margin-bottom: 34px; }
article.prose h2 { font-size: 1.25rem; margin: 36px 0 10px; }
article.prose p, article.prose li { color: var(--text-dim); }
article.prose ul { padding-left: 22px; margin: 10px 0; }
article.prose li { margin: 6px 0; }
article.prose a { color: var(--accent); }
article.prose strong { color: var(--text); }

footer.site {
  border-top: 1px solid var(--line); padding: 28px 0 40px;
  font-size: 0.88rem; color: var(--text-faint);
}
footer.site .wrap {
  display: flex; flex-wrap: wrap; gap: 8px 24px;
  align-items: center; justify-content: space-between;
}
footer.site a { color: var(--text-dim); text-decoration: none; margin-right: 18px; }
footer.site a:hover { color: var(--text); }
