/* Blog index and post pages (built by site/blog/build.js). Loaded after styles.css. */

/* ---------- Index ---------- */
.blog-hero { padding: 72px 0 24px; }
.blog-hero h1 { font-size: clamp(38px, 5.4vw, 64px); line-height: 1.04; letter-spacing: -0.03em; max-width: 880px; }
.blog-hero .lede { font-size: 19px; color: var(--slate); max-width: 660px; margin: 20px 0 32px; }
.blog-group { padding: 56px 0; }
.blog-group + .blog-group { border-top: 1px solid var(--line); }
.blog-group .section-title { font-size: clamp(26px, 3vw, 34px); }

.post-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 32px; }
.post-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; display: flex; flex-direction: column; gap: 10px; position: relative; transition: border-color .15s, box-shadow .15s; }
.post-card:hover { border-color: var(--mist); box-shadow: var(--shadow); }
.post-card h3 { font-size: 20px; line-height: 1.25; letter-spacing: -0.01em; }
.post-card h3 a { text-decoration: none; }
.post-card h3 a::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.post-card p:last-child { color: var(--slate); font-size: 15px; }
.post-meta { font-size: 13px; color: var(--slate); font-weight: 500; }
.post-cat { font-weight: 700; text-transform: uppercase; letter-spacing: .08em; font-size: 12px; color: var(--navy); }

/* ---------- Post ---------- */
.post-head { max-width: 800px; padding-top: 64px; padding-bottom: 8px; }
.crumbs { font-size: 14px; color: var(--slate); margin-bottom: 20px; }
.crumbs a { color: var(--navy); font-weight: 600; text-underline-offset: 3px; }
.post-head h1 { font-size: clamp(34px, 4.6vw, 54px); line-height: 1.06; letter-spacing: -0.03em; }
.post-head .lede { font-size: 20px; color: var(--slate); margin: 20px 0 20px; }

.post-body { max-width: 800px; padding-top: 32px; padding-bottom: 72px; font-size: 18px; line-height: 1.7; }
.post-body > * + * { margin-top: 20px; }
.post-body h2 { font-size: clamp(25px, 2.8vw, 31px); line-height: 1.2; margin-top: 52px; }
.post-body h3 { font-size: 20px; line-height: 1.3; letter-spacing: -0.01em; margin-top: 36px; }
.post-body h2 + *, .post-body h3 + * { margin-top: 12px; }
.post-body a { color: var(--navy); font-weight: 600; text-underline-offset: 3px; text-decoration-color: var(--mist); }
.post-body a:hover { text-decoration-color: var(--navy); }
.post-body ul, .post-body ol { padding-left: 24px; }
.post-body li + li { margin-top: 8px; }
.post-body strong { font-weight: 650; }
.post-body blockquote { margin: 28px 0; padding: 4px 0 4px 22px; border-left: 3px solid var(--navy); color: var(--navy-3); }
.post-body .note { background: var(--paper-2); border-radius: 12px; padding: 20px 24px; font-size: 16px; color: var(--slate); }
.post-body .note strong { color: var(--navy); }
.post-body .prompt { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 18px 22px; font-size: 16px; line-height: 1.6; white-space: pre-wrap; font-family: var(--font); }
.post-body .checklist { list-style: none; padding: 0; }
.post-body .checklist li { position: relative; padding-left: 32px; }
.post-body .checklist li::before { content: ""; position: absolute; left: 2px; top: .45em; width: 16px; height: 16px; border-radius: 5px; border: 2px solid var(--navy); }
.post-body table { width: 100%; border-collapse: collapse; font-size: 16px; }
.post-body th, .post-body td { text-align: left; vertical-align: top; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.post-body th { font-weight: 700; background: var(--paper-2); }
.table-scroll { overflow-x: auto; }

.post-cta { padding: 0 0 72px; }
.cta-band { background: var(--navy); color: #fff; border-radius: var(--radius); padding: 40px; display: flex; align-items: center; justify-content: space-between; gap: 32px; }
.cta-band h3 { font-size: 24px; letter-spacing: -0.01em; }
.cta-band p { color: var(--mist); margin-top: 8px; max-width: 520px; }
.cta-band .cta-row { flex-shrink: 0; }

.post-related { background: #fff; border-top: 1px solid var(--line); padding: 72px 0 96px; }
.post-related h2 { font-size: 28px; }
.post-related .post-card { background: var(--paper); }

@media (max-width: 960px) {
  .post-grid { grid-template-columns: 1fr 1fr; }
  .cta-band { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 640px) {
  .post-grid { grid-template-columns: 1fr; }
  .blog-hero { padding-top: 48px; }
  .post-head { padding-top: 40px; }
  .post-body { font-size: 17px; }
  .cta-band { padding: 28px 24px; }
  .cta-band .cta-row, .cta-band .btn { width: 100%; }
}

/* ---------- Author ---------- */
.post-body .author-box { display: flex; gap: 18px; align-items: flex-start; margin-top: 56px; padding: 24px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); font-size: 16px; line-height: 1.6; }
.author-mark { flex-shrink: 0; width: 52px; height: 52px; border-radius: 50%; background: var(--navy); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 18px; letter-spacing: .02em; }
.author-box .author-name { font-weight: 700; font-size: 17px; }
.author-box .author-role { font-size: 14px; color: var(--slate); margin-bottom: 8px; }
.author-box p { color: var(--slate); }
.author-box .author-name { color: var(--navy); }
img.author-mark { object-fit: cover; }
.author-box .author-link { margin-top: 8px; font-size: 15px; }

/* ---------- Home page strip ---------- */
.home-blog { border-top: 1px solid var(--line); }
.home-blog-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.home-blog .post-card h3 { font-size: 19px; }

/* ---------- 404 ---------- */
.not-found { padding: 96px 0 120px; }
.not-found h1 { font-size: clamp(38px, 5.4vw, 64px); line-height: 1.04; letter-spacing: -0.03em; }
.not-found .lede { font-size: 19px; color: var(--slate); max-width: 560px; margin: 20px 0 32px; }
.post-body .prompt.mono { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: 14px; overflow-x: auto; white-space: pre; }
