:root {
  --bg: #f9f7f4;
  --surface: #ffffff;
  --text: #1a1a1a;
  --muted: #6b7280;
  --accent: #0f4c81;
  --tag-bg: #eef2f7;
  --border: #e5e7eb;
  --font-serif: 'Georgia', 'Times New Roman', serif;
  --font-ui: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --max-width: 720px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 18px; scroll-behavior: smooth; }
body { background: var(--bg); color: var(--text); font-family: var(--font-serif); line-height: 1.75; }

/* Header */
.site-header { background: var(--surface); border-bottom: 1px solid var(--border); padding: 1rem 2rem; position: sticky; top: 0; z-index: 100; }
.nav { max-width: 1100px; margin: 0 auto; display: flex; align-items: center; gap: 1rem; }
.site-logo { font-size: 1.3rem; font-weight: bold; color: var(--accent); text-decoration: none; }
.nav-tagline { font-family: var(--font-ui); font-size: 0.8rem; color: var(--muted); }

/* Home */
.site-main { min-height: 80vh; }
.home { max-width: 1100px; margin: 0 auto; padding: 3rem 2rem; }
.home-header { margin-bottom: 3rem; }
.home-header h1 { font-size: 2.5rem; color: var(--accent); letter-spacing: -0.03em; }
.home-header p { color: var(--muted); margin-top: 0.5rem; }

.posts-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 2rem; }
.post-card { background: var(--surface); border-radius: 8px; overflow: hidden; border: 1px solid var(--border); transition: box-shadow 0.2s, transform 0.2s; }
.post-card:hover { box-shadow: 0 8px 30px rgba(0,0,0,0.08); transform: translateY(-2px); }
.card-image-link img { width: 100%; height: 200px; object-fit: cover; display: block; }
.card-body { padding: 1.5rem; }
.card-body h2 { font-size: 1.15rem; margin: 0.5rem 0; line-height: 1.4; }
.card-body h2 a { color: var(--text); text-decoration: none; }
.card-body h2 a:hover { color: var(--accent); }
.card-description { font-size: 0.9rem; color: var(--muted); margin-bottom: 0.75rem; }
.card-body time { font-family: var(--font-ui); font-size: 0.8rem; color: var(--muted); }

/* Tags */
.tags { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 0.75rem; }
.tag { background: var(--tag-bg); color: var(--accent); font-family: var(--font-ui); font-size: 0.72rem; font-weight: 600; padding: 0.2rem 0.6rem; border-radius: 4px; text-transform: uppercase; letter-spacing: 0.05em; }

/* Article */
.article { padding-bottom: 4rem; }
.article-hero img { width: 100%; max-height: 480px; object-fit: cover; display: block; }
.article-container { max-width: var(--max-width); margin: 0 auto; padding: 2.5rem 1.5rem; }
.article-title { font-size: 2.2rem; line-height: 1.25; letter-spacing: -0.02em; margin: 1rem 0 0.75rem; }
.article-date { font-family: var(--font-ui); font-size: 0.85rem; color: var(--muted); display: block; margin-bottom: 2rem; }
.article-body { font-size: 1.05rem; line-height: 1.8; }
.article-body h2 { font-size: 1.5rem; margin: 2rem 0 0.75rem; }
.article-body h3 { font-size: 1.2rem; margin: 1.5rem 0 0.5rem; }
.article-body p { margin-bottom: 1.5rem; }
.article-body a { color: var(--accent); }
.article-body blockquote { border-left: 4px solid var(--accent); padding-left: 1.25rem; margin: 1.5rem 0; color: var(--muted); font-style: italic; }

/* Footer */
.site-footer { text-align: center; padding: 2rem; border-top: 1px solid var(--border); font-family: var(--font-ui); font-size: 0.85rem; color: var(--muted); }

/* Mobile */
@media (max-width: 640px) {
  html { font-size: 16px; }
  .home { padding: 2rem 1rem; }
  .home-header h1 { font-size: 1.8rem; }
  .article-title { font-size: 1.6rem; }
  .posts-grid { grid-template-columns: 1fr; }
  .nav { flex-direction: column; align-items: flex-start; gap: 0.25rem; }
  .nav-tagline { display: none; }
}
