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

:root {
  --bg: #faf9f7;
  --white: #ffffff;
  --border: #e8e6e1;
  --border-soft: #f0ede8;
  --accent: #c9622f;
  --ink: #0f0f0f;
  --ink-soft: #3a3a3a;
  --ink-muted: #888880;
}

body {
  font-family: inherit;
  background: var(--bg);
  color: var(--ink-soft);
  line-height: 1.75;
  font-size: 16px;
}


.container { max-width: 760px; margin: 0 auto; padding: 0 28px; }

/* Header */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 20px 0;
}
.site-header .container {
  display: flex; align-items: center; justify-content: space-between;
}
.site-logo {
  font-family: inherit;
  font-weight: 700; font-size: 18px;
  color: var(--ink); text-decoration: none;
}
.site-nav a {
  color: var(--ink-muted); text-decoration: none;
  font-size: 14px; margin-left: 24px;
  transition: color 0.15s;
}
.site-nav a:hover { color: var(--ink); }

/* Index */
.index-hero {
  padding: 64px 0 48px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 48px;
}
.index-hero h1 {
  font-family: inherit;
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 700; color: var(--ink);
  line-height: 1.2; margin-bottom: 14px;
  letter-spacing: -0.5px;
}
.index-hero p { font-size: 16px; color: var(--ink-muted); }

.posts-grid { display: flex; flex-direction: column; }

/* Post card */
.post-card {
  padding: 32px 0;
  border-bottom: 1px solid var(--border-soft);
}
.post-card:last-child { border-bottom: none; }
.post-card-meta {
  font-size: 12px; color: var(--ink-muted);
  margin-bottom: 10px;
  display: flex; gap: 12px; align-items: center;
  text-transform: uppercase; letter-spacing: 0.6px;
}
.post-card h2 {
  font-family: inherit;
  font-size: 22px; font-weight: 700;
  color: var(--ink); line-height: 1.3; margin-bottom: 10px;
}
.post-card h2 a { color: inherit; text-decoration: none; }
.post-card h2 a:hover { color: var(--accent); }
.post-card p { color: var(--ink-muted); font-size: 15px; margin-bottom: 14px; line-height: 1.6; }
.read-more {
  font-size: 13px; color: var(--accent);
  text-decoration: none; font-weight: 500;
  letter-spacing: 0.2px;
}
.read-more:hover { text-decoration: underline; }

/* Post page */
.post-header {
  padding: 48px 0 36px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 40px;
}
.post-meta {
  display: flex; gap: 14px; align-items: center;
  font-size: 12px; color: var(--ink-muted);
  margin-bottom: 20px;
  text-transform: uppercase; letter-spacing: 0.6px;
}
.category {
  color: var(--accent); text-decoration: none;
  font-weight: 600;
}
.post-title {
  font-family: inherit;
  font-size: clamp(26px, 4vw, 40px);
  font-weight: 700; color: var(--ink);
  line-height: 1.2; letter-spacing: -0.5px;
  margin-bottom: 16px;
}
.post-description {
  font-size: 18px; color: var(--ink-muted);
  font-style: italic; line-height: 1.6;
}

/* Post content */
.post-content { font-size: 16px; line-height: 1.8; color: var(--ink-soft); }
.post-content h1, .post-content h2, .post-content h3 {
  font-family: inherit;
  color: var(--ink); font-weight: 700;
  margin: 40px 0 16px; line-height: 1.3;
}
.post-content h1 { font-size: 30px; }
.post-content h2 { font-size: 24px; }
.post-content h3 { font-size: 19px; }
.post-content p { margin-bottom: 22px; }
.post-content a { color: var(--accent); text-decoration: underline; }
.post-content blockquote {
  border-left: 3px solid var(--border);
  padding: 4px 20px; margin: 28px 0;
  color: var(--ink-muted); font-style: italic;
}
.post-content code {
  background: var(--border-soft); padding: 2px 6px;
  border-radius: 3px; font-size: 14px;
}
.post-content pre {
  background: var(--white); border: 1px solid var(--border);
  border-radius: 6px; padding: 20px;
  overflow-x: auto; margin: 24px 0;
}
.post-content pre code { background: none; padding: 0; }
.post-content img { max-width: 100%; border-radius: 6px; margin: 24px 0; }
.post-content ul, .post-content ol { margin: 0 0 22px 24px; }
.post-content li { margin-bottom: 6px; }
.post-content hr { border: none; border-top: 1px solid var(--border); margin: 40px 0; }

/* Post footer */
.post-footer { margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--border); }
.tag {
  display: inline-block; padding: 4px 12px;
  border: 1px solid var(--border); border-radius: 20px;
  font-size: 12px; color: var(--ink-muted);
  text-decoration: none; margin-right: 6px;
}
.tag:hover { border-color: var(--ink-muted); color: var(--ink); }

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 32px 0; margin-top: 80px;
}
.site-footer p { font-size: 13px; color: var(--ink-muted); text-align: center; }

/* ── Homepage builder card styles ── */
.hp-grid .post-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  padding: 0;
  display: flex; flex-direction: column;
}
.hp-grid .post-card-image img {
  width: 100%; aspect-ratio: 16/9;
  object-fit: cover; display: block;
}
.hp-grid .post-card-title,
.hp-grid .post-card-date,
.hp-grid .post-card-author,
.hp-grid .post-card-desc,
.hp-grid .post-card-cat,
.hp-grid .post-card-more { padding: 0 18px; }
.hp-grid .post-card-title { padding-top: 16px; padding-bottom: 6px; }
.hp-grid .post-card-more  { padding-bottom: 18px; margin-top: auto; }
.hp-grid .post-card-title a {
  font-family: inherit;
  font-size: 17px; font-weight: 700;
  color: var(--ink); text-decoration: none; line-height: 1.3;
}
.hp-grid .post-card-title a:hover { color: var(--accent); }
.hp-grid .post-card-date,
.hp-grid .post-card-author { font-size: 12px; color: var(--ink-muted); }
.hp-grid .post-card-desc { font-size: 14px; color: var(--ink-soft); line-height: 1.6; margin: 6px 0; }
.hp-grid .post-card-cat { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.6px; color: var(--accent); text-decoration: none; display: block; padding-top: 12px; }
.hp-grid .post-card-more { font-size: 13px; color: var(--accent); text-decoration: none; font-weight: 500; display: block; padding-top: 12px; }

/* 1-col list mode */
.hp-grid[style*="repeat(1,"] .post-card {
  flex-direction: row; align-items: flex-start;
}
.hp-grid[style*="repeat(1,"] .post-card-image {
  width: 200px; flex-shrink: 0;
}
.hp-grid[style*="repeat(1,"] .post-card-image img {
  aspect-ratio: 4/3; height: 100%;
}

/* Pagination */
.pagination { display: flex; gap: 8px; align-items: center; margin-top: 32px; }
.pagination .page-current {
  padding: 6px 12px; background: var(--ink); color: var(--cream);
  border-radius: 4px; font-size: 13px; font-weight: 600;
}
.pagination .page-link {
  padding: 6px 12px; border: 1px solid var(--border);
  border-radius: 4px; font-size: 13px; color: var(--ink-muted);
  text-decoration: none;
}
.pagination .page-link:hover { border-color: var(--ink-muted); color: var(--ink); }
.hp-main { max-width: 100%; padding: 0 20px; }
