/* The blog's styles, copied to /blog/blog.css by scripts/site/build_blog.mjs.
   Same tokens and look as the landing pages (public/site/, DESIGN.md), without
   their scroll animations: blog pages are for reading. */
:root {
  color-scheme: light;
  --brand: #1f7a52;
  --brand-deep: #0e3226;
  --brand-light: #2f8f5f;
  --ball: #d7e34b;
  --surface: #f2f5f1;
  --ink: #0b1a14;
  --ink-soft: #56645c;
  --ghost: #d4ddd6;
  --hairline: #e3e9e4;
  --radius-sm: 0.75rem;
  --radius-card: 1.5rem;
  --radius-card-lg: 2rem;
  --radius-pill: 62.5rem;
}
html { font-size: clamp(0.9375rem, 0.88rem + 0.24vw, 1.125rem); }
[hidden] { display: none !important; }
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
ul, ol { padding: 0; }
body { min-height: 100vh; background: #fff; color: var(--ink); font-family: "Onest", system-ui, sans-serif; font-weight: 400; line-height: 1.5; -webkit-font-smoothing: antialiased; }
:focus-visible { outline: 2px solid var(--brand-light); outline-offset: 2px; }
.on-dark :focus-visible { outline-color: var(--ball); }
::selection { background: var(--ball); color: var(--brand-deep); }
.skip { position: absolute; left: -9999px; top: 0.5rem; z-index: 300; background: #fff; color: var(--ink); padding: 0.5rem 1rem; border-radius: var(--radius-pill); }
.skip:focus { left: 1rem; }

main { width: 100%; overflow-x: clip; padding: 0.5rem; }
@media (min-width: 640px) { main { padding: 0.75rem; } }
.px { padding-left: 1.5rem; padding-right: 1.5rem; }
@media (min-width: 640px) { .px { padding-left: 2.5rem; padding-right: 2.5rem; } }
.on-dark { color: #fff; }
.mark { flex: none; }

.eyebrow { display: inline-flex; align-items: center; gap: 0.5rem; font-size: 0.8rem; font-weight: 500; text-transform: uppercase; letter-spacing: 0.22em; color: var(--ink-soft); }
.eyebrow::before { content: ""; width: 0.375rem; height: 0.375rem; border-radius: var(--radius-pill); background: var(--brand); }
.eyebrow.light { color: rgba(255, 255, 255, 0.7); }
.eyebrow.light::before { background: var(--ball); }

.pill { display: inline-flex; align-items: center; gap: 0.5rem; border-radius: var(--radius-pill); padding: 0.875rem 1.75rem; font-size: 0.875rem; font-weight: 500; text-transform: uppercase; letter-spacing: 0.04em; transition: background-color 200ms ease, color 200ms ease, border-color 200ms ease; border: 1px solid transparent; white-space: nowrap; }
.pill svg { width: 1rem; height: 1rem; flex: none; }
.pill.light { background: #fff; color: var(--brand-deep); }
.pill.light:hover { background: var(--ball); }
.pill.outline { border-color: currentColor; color: var(--ink); }
.pill.outline:hover { background: var(--ink); color: #fff; }

/* Header band */
.band { background: var(--brand-deep); color: #fff; border-radius: var(--radius-card-lg); padding-bottom: 3rem; }
@media (min-width: 640px) { .band { padding-bottom: 4rem; } }
.site-header { display: flex; align-items: center; padding: 1.5rem 1.5rem 0; font-size: 0.8rem; }
@media (min-width: 640px) { .site-header { padding: 2rem 2.5rem 0; } }
.hnav { flex: 1; display: none; gap: 2rem; }
.hnav a { white-space: nowrap; color: rgba(255, 255, 255, 0.9); text-transform: uppercase; letter-spacing: 0.08em; }
.hnav a:hover { color: #fff; }
.hnav a[aria-current="page"] { text-decoration: underline; text-decoration-color: var(--ball); text-decoration-thickness: 2px; text-underline-offset: 0.45em; }
@media (min-width: 1024px) { .hnav { display: flex; } }
.brand { display: inline-flex; align-items: center; gap: 0.5rem; font-size: 1rem; font-weight: 500; text-transform: uppercase; letter-spacing: 0.2em; }
.brand svg { width: 1.25rem; height: 1.25rem; }
.brand .logo { display: block; height: 1.4em; width: auto; }
.hbrand { flex: 1; }
@media (min-width: 1024px) { .hbrand { display: flex; justify-content: center; } }
.hright { flex: 1; display: flex; justify-content: flex-end; align-items: center; gap: 1rem; }
@media (min-width: 640px) { .hright { gap: 1.25rem; } }
.textbtn { text-transform: uppercase; letter-spacing: 0.08em; text-underline-offset: 0.3em; white-space: nowrap; }
.textbtn:hover { text-decoration: underline; }
.textbtn.wide { display: none; }
@media (min-width: 640px) { .textbtn.wide { display: inline; } }
/* The header nav has Blog on wide screens; below that, this link stands in. */
@media (min-width: 1024px) { .textbtn.narrow { display: none; } }

.band-title { padding-top: 4rem; max-width: 52rem; }
@media (min-width: 640px) { .band-title { padding-top: 6rem; } }
.band-title h1 { font-size: 3rem; font-weight: 500; line-height: 0.95; letter-spacing: -0.02em; margin-top: 1rem; }
@media (min-width: 640px) { .band-title h1 { font-size: 4.5rem; } }
.band-title.post h1 { font-size: 2.4rem; line-height: 1.02; }
@media (min-width: 640px) { .band-title.post h1 { font-size: 3.5rem; } }
.band-title p { margin-top: 1.5rem; max-width: 40rem; font-size: 1.0625rem; line-height: 1.55; color: rgba(255, 255, 255, 0.78); }

/* Index: post list */
.posts { padding-top: 3rem; padding-bottom: 4rem; }
@media (min-width: 640px) { .posts { padding-top: 4rem; padding-bottom: 5rem; } }
.post-grid { list-style: none; display: grid; gap: 0.75rem; }
@media (min-width: 720px) { .post-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .post-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.post-card { display: flex; flex-direction: column; height: 100%; background: var(--surface); border-radius: var(--radius-card); overflow: hidden; transition: background-color 200ms ease; }
.post-card:hover { background: #e9eee8; }
.post-card img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.post-card .body { padding: 1.5rem; display: flex; flex-direction: column; gap: 0.75rem; flex: 1; }
.post-card time { font-size: 0.8rem; font-weight: 500; text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-soft); }
.post-card h2 { font-size: 1.375rem; font-weight: 500; line-height: 1.2; letter-spacing: -0.02em; }
.post-card p { font-size: 0.9375rem; line-height: 1.55; color: var(--ink-soft); }
.post-card .more { margin-top: auto; padding-top: 0.5rem; display: inline-flex; align-items: center; gap: 0.5rem; font-size: 0.8rem; font-weight: 500; text-transform: uppercase; letter-spacing: 0.08em; color: var(--brand); }
.post-card .more svg { width: 1rem; height: 1rem; }
.empty { background: var(--surface); border-radius: var(--radius-card); padding: 2.5rem 1.5rem; color: var(--ink-soft); }

/* Post */
.cover { margin-top: 0.75rem; border-radius: var(--radius-card-lg); overflow: hidden; background: var(--surface); }
.cover img { width: 100%; max-height: 34rem; object-fit: cover; }
.article { padding-top: 3rem; padding-bottom: 4rem; }
@media (min-width: 640px) { .article { padding-top: 4rem; padding-bottom: 5rem; } }
.prose { max-width: 42rem; margin: 0 auto; font-size: 1.0625rem; line-height: 1.7; }
.prose > * + * { margin-top: 1.25em; }
.prose h2 { font-size: 1.875rem; font-weight: 500; line-height: 1.15; letter-spacing: -0.02em; margin-top: 2em; }
.prose h3 { font-size: 1.375rem; font-weight: 500; line-height: 1.25; letter-spacing: -0.01em; margin-top: 1.75em; }
.prose h4 { font-size: 1.125rem; font-weight: 500; margin-top: 1.5em; }
.prose a { color: var(--brand); text-decoration: underline; text-underline-offset: 0.2em; }
.prose a:hover { color: var(--brand-deep); }
.prose strong { font-weight: 500; }
.prose ul, .prose ol { padding-left: 1.4em; }
.prose li + li { margin-top: 0.4em; }
.prose li::marker { color: var(--brand); }
.prose blockquote { border-left: 3px solid var(--brand); padding: 0.25em 0 0.25em 1.25em; color: var(--ink-soft); }
.prose img { border-radius: var(--radius-card); }
.prose figure figcaption, .prose img + em { display: block; margin-top: 0.5rem; font-size: 0.875rem; color: var(--ink-soft); }
.prose hr { border: 0; border-top: 1px solid var(--hairline); margin: 2.5em 0; }
.prose code { font-size: 0.9em; background: var(--surface); border-radius: 0.375rem; padding: 0.1em 0.35em; }
.prose pre { background: var(--surface); border-radius: var(--radius-sm); padding: 1rem 1.25rem; overflow-x: auto; }
.prose pre code { background: none; padding: 0; }
.prose table { width: 100%; border-collapse: collapse; font-size: 0.9375rem; }
.prose th, .prose td { text-align: left; padding: 0.6rem 0.75rem; border-bottom: 1px solid var(--hairline); }
.prose th { font-weight: 500; }
.back { max-width: 42rem; margin: 3rem auto 0; padding-top: 2rem; border-top: 1px solid var(--hairline); }

/* Footer band */
.site-footer { background: var(--brand-deep); color: #fff; border-radius: var(--radius-card-lg); margin-top: 0.75rem; padding-top: 3.5rem; padding-bottom: 3.5rem; }
@media (min-width: 640px) { .site-footer { padding-top: 4rem; padding-bottom: 4rem; } }
.f-cta { border-bottom: 1px solid rgba(255, 255, 255, 0.15); padding-bottom: 3.5rem; display: flex; flex-direction: column; gap: 2rem; }
@media (min-width: 640px) { .f-cta { flex-direction: row; justify-content: space-between; align-items: flex-end; } }
.f-big { font-size: 3rem; font-weight: 500; line-height: 0.92; letter-spacing: -0.02em; margin-top: 1rem; }
@media (min-width: 640px) { .f-big { font-size: 3.75rem; } }
.f-cols { display: grid; gap: 2.5rem; padding-top: 3.5rem; }
@media (min-width: 768px) { .f-cols { grid-template-columns: 1.4fr 1fr 1fr 1fr; } }
.f-brand .brand { font-size: 1.125rem; }
.f-brand p { font-size: 0.875rem; color: rgba(255, 255, 255, 0.65); margin-top: 1rem; max-width: 20rem; line-height: 1.6; }
.f-col h2 { font-size: 0.8rem; font-weight: 500; text-transform: uppercase; letter-spacing: 0.2em; color: rgba(255, 255, 255, 0.5); }
.f-col ul { list-style: none; margin-top: 1rem; display: grid; gap: 0.75rem; font-size: 0.875rem; color: rgba(255, 255, 255, 0.8); }
.f-col a:hover, .f-bottom a:hover { color: #fff; text-decoration: underline; text-underline-offset: 0.2em; }
.f-bottom { border-top: 1px solid rgba(255, 255, 255, 0.15); margin-top: 3.5rem; padding-top: 2rem; font-size: 0.875rem; color: rgba(255, 255, 255, 0.6); display: flex; flex-direction: column; gap: 1.25rem; }
@media (min-width: 640px) { .f-bottom { flex-direction: row; justify-content: space-between; align-items: center; } }
.f-bottom nav { display: flex; gap: 1.25rem; }

/* Legal pages (/privacy, /terms): long reading, wide tables scroll on a phone. */
.prose .table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.prose .table-wrap table { min-width: 34rem; }
.legal .prose [id] { scroll-margin-top: 1.5rem; }
