/* THE PLAIN BLOG PAGE (/s/<name>/blog) for a business with no website
   template. The business's colour arrives through /shared/accent.js
   (--accent-ink for words, --accent-fill + --on-accent for the button).
   ⚠ The .blog-* / .post-* class names are a contract shared with the
   showcases' Journal pages and the F&B and Forge stylesheets; see
   lib/merchant-blog.js. */
:root {
  --bg: #FBFAF7; --card: #fff; --ink: #16181D; --ink-2: #3A3F4A; --ink-3: #5E6470;
  --line: #E6E2DA; --tint: #F2EEE6;
  --accent: #4038B8; --accent-ink: #4038B8; --accent-fill: #4038B8; --on-accent: #fff;
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #111317; --card: #181B21; --ink: #EEF0F3; --ink-2: #CDD1D8; --ink-3: #A1A7B2;
          --line: #2A2E36; --tint: #1D2027; --accent-ink: #A9A3F5; }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 17px/1.6 var(--sans); -webkit-font-smoothing: antialiased; }
a { color: inherit; }
img { max-width: 100%; }

/* header and footer */
.bh { border-bottom: 1px solid var(--line); background: var(--bg); position: sticky; top: 0; z-index: 10; }
.bh-in { max-width: 1120px; margin: 0 auto; padding: 16px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.bh-name { font: 600 22px/1.2 var(--serif); text-decoration: none; letter-spacing: -.01em; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bh-nav { display: flex; gap: 4px; flex-shrink: 0; }
.bh-nav a { text-decoration: none; font-size: 15px; font-weight: 500; color: var(--ink-2); padding: 8px 12px; border-radius: 999px; }
.bh-nav a:hover { background: var(--tint); }
.bh-nav a.on { color: var(--ink); background: var(--tint); }
.bf { border-top: 1px solid var(--line); margin-top: 72px; }
.bf-in { max-width: 1120px; margin: 0 auto; padding: 24px 16px 40px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; font-size: 14px; color: var(--ink-3); }
.bf a { color: var(--ink-3); }

/* ── Journal (blog) ─ the contract ── */
.blog { max-width: 1120px; margin: 0 auto; padding: 56px 16px 0; }
.blog-head { max-width: 760px; margin-bottom: 40px; }
.blog-kicker { margin: 0 0 12px; font-size: 13px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--accent-ink); }
.blog-title { margin: 0; font: 600 clamp(38px, 6vw, 64px)/1.04 var(--serif); letter-spacing: -.025em; }
.blog-intro { margin: 16px 0 0; font-size: 19px; color: var(--ink-2); }
.blog-empty { color: var(--ink-3); }
.blog-meta { margin: 0 0 10px; font-size: 13px; color: var(--ink-3); letter-spacing: .02em; }

.blog-card { display: flex; flex-direction: column; text-decoration: none; color: inherit; background: var(--card); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; transition: transform .2s ease, box-shadow .2s ease; }
.blog-card:hover { transform: translateY(-2px); box-shadow: 0 14px 32px rgba(20, 20, 30, .08); }
.blog-card:focus-visible { outline: 3px solid var(--accent-ink); outline-offset: 3px; }
.blog-cover { aspect-ratio: 16 / 10; background: var(--tint); overflow: hidden; }
.blog-cover img, .post-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.blog-card-body { padding: 22px 22px 24px; display: flex; flex-direction: column; flex: 1; }
.blog-card-title { margin: 0 0 10px; font: 600 23px/1.2 var(--serif); letter-spacing: -.01em; }
.blog-excerpt { margin: 0 0 18px; color: var(--ink-2); font-size: 16px; }
.blog-more { margin-top: auto; font-size: 14px; font-weight: 600; color: var(--accent-ink); }
.blog-more::after { content: " \2192"; }
.blog-card.no-cover .blog-card-body { border-top: 6px solid var(--accent); }

.blog-lead { margin-bottom: 28px; }
@media (min-width: 820px) {
  .blog-lead { flex-direction: row; min-height: 380px; }
  .blog-lead.no-cover { min-height: 0; }
  .blog-lead .blog-cover { flex: 1.35; aspect-ratio: auto; }
  .blog-lead .blog-card-body { flex: 1; padding: 40px; justify-content: center; }
  .blog-lead .blog-card-title { font-size: 36px; }
  .blog-lead.no-cover .blog-card-body { border-top: 0; border-left: 8px solid var(--accent); }
}
.blog-grid { display: grid; gap: 24px; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }

/* one article */
.blog-post { padding-top: 40px; }
.post { max-width: 760px; margin: 0 auto; }
.post-head { margin-bottom: 32px; }
.post-back { display: inline-block; margin-bottom: 28px; font-size: 14px; font-weight: 500; color: var(--ink-3); text-decoration: none; }
.post-back::before { content: "\2190  "; }
.post-back:hover { color: var(--ink); }
.post-title { margin: 0; font: 600 clamp(34px, 5.4vw, 56px)/1.06 var(--serif); letter-spacing: -.025em; }
.post-dek { margin: 18px 0 0; font-size: 21px; line-height: 1.5; color: var(--ink-2); }
.post-cover { margin: 0 -16px 40px; aspect-ratio: 16 / 9; background: var(--tint); overflow: hidden; }
@media (min-width: 820px) { .post-cover { margin: 0 -80px 48px; border-radius: 20px; } }
.post-body { font-size: 18.5px; line-height: 1.75; color: var(--ink); }
.post-body > * { max-width: 68ch; }
.post-body p { margin: 0 0 1.3em; }
.post-body h2 { margin: 2em 0 .6em; font: 600 30px/1.2 var(--serif); letter-spacing: -.015em; }
.post-body h3 { margin: 1.8em 0 .5em; font: 600 22px/1.3 var(--sans); }
.post-body ul, .post-body ol { margin: 0 0 1.3em; padding-left: 1.3em; }
.post-body li { margin: .35em 0; }
.post-body li::marker { color: var(--accent-ink); }
.post-body a { color: var(--accent-ink); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.post-body blockquote { margin: 1.8em 0; padding: 4px 0 4px 24px; border-left: 4px solid var(--accent); font: italic 500 24px/1.45 var(--serif); color: var(--ink); }
.post-body blockquote p { margin: 0; }
.post-body .post-fig { margin: 2em 0; }
.post-body .post-fig img { width: 100%; height: auto; display: block; border-radius: 14px; }
.post-body figcaption { margin-top: 10px; font-size: 14px; color: var(--ink-3); }

.post-cta { margin: 48px 0 0; padding: 32px; border-radius: 20px; background: var(--tint); }
.post-cta h2 { margin: 0 0 8px; font: 600 26px/1.2 var(--serif); }
.post-cta p { margin: 0 0 20px; color: var(--ink-2); }
.btn { display: inline-block; padding: 13px 22px; border-radius: 999px; background: var(--accent-fill); color: var(--on-accent); font-weight: 600; font-size: 15px; text-decoration: none; }
.btn:focus-visible { outline: 3px solid var(--accent-ink); outline-offset: 3px; }

.post-more { max-width: 1120px; margin: 72px auto 0; padding-top: 40px; border-top: 1px solid var(--line); }
.post-more-title { margin: 0 0 24px; font: 600 28px/1.2 var(--serif); }

@media (max-width: 560px) {
  body { font-size: 16px; }
  .blog { padding-top: 36px; }
  .bh-nav a { padding: 8px 9px; font-size: 14px; }
  .post-body { font-size: 17.5px; }
  .post-cta { padding: 24px 20px; }
}
