/* Styles for the static blog pages. Brand colours match the main site. */
:root {
  --brand-logo: #4eaa53;
  --brand: #1e7b3d;
  --brand-dark: #14602f;
  --ink: #10261a;
  --paper: #f5faf4;
  --white: #fff;
  --tag: #ffd84a;
  --mint: #dcf1df;
  --mint-ink: #0f5a2b;
  --line: #d3e0d4;
  --muted: #4a5f51;
  --serif: 'Young Serif', Georgia, serif;
  --sans: 'Onest', system-ui, -apple-system, 'Segoe UI', sans-serif;
}
*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  scroll-padding-top: 84px;
}
body {
  margin: 0;
  font-family: var(--sans);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img {
  max-width: 100%;
  height: auto;
  display: block;
}
a {
  color: var(--brand);
  text-underline-offset: 3px;
}
a:hover {
  color: var(--brand-dark);
}
:focus-visible {
  outline: 3px solid var(--brand);
  outline-offset: 2px;
  border-radius: 4px;
}
.wrap {
  width: min(1120px, 100% - 40px);
  margin-inline: auto;
}

/* header + footer */
.site-head {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(245, 250, 244, 0.94);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.head-in {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 64px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--ink);
  text-decoration: none;
}
.brand img {
  border-radius: 9px;
}
.site-head nav {
  display: flex;
  align-items: center;
  gap: 22px;
}
.site-head nav a:not(.btn) {
  color: var(--ink);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
}
.site-head nav a:not(.btn):hover,
.site-head nav a[aria-current] {
  color: var(--brand);
}
.btn {
  display: inline-block;
  background: var(--brand);
  color: #fff;
  font-weight: 600;
  text-decoration: none;
  padding: 12px 22px;
  border-radius: 999px;
}
.btn:hover {
  background: var(--brand-dark);
  color: #fff;
}
.btn-sm {
  padding: 8px 16px;
  font-size: 0.9rem;
}
.site-foot {
  margin-top: 72px;
  border-top: 1px solid var(--line);
  padding: 32px 0;
  color: var(--muted);
  font-size: 0.92rem;
}
.foot-in {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 32px;
  justify-content: space-between;
}
.foot-in p {
  margin: 0;
  max-width: 460px;
}
.foot-in nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
}

/* breadcrumbs, chips, meta */
.crumbs {
  font-size: 0.88rem;
  color: var(--muted);
  margin: 28px 0 8px;
}
.crumbs a {
  color: var(--muted);
}
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  padding: 0;
  margin: 0 0 12px;
}
.chips li {
  background: var(--mint);
  color: var(--mint-ink);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 3px 11px;
  border-radius: 999px;
}
.meta {
  color: var(--muted);
  font-size: 0.92rem;
  margin: 0;
}

/* blog index */
.index h1 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2.1rem, 5vw, 3.2rem);
  line-height: 1.15;
  margin: 8px 0 8px;
}
.lede {
  font-size: 1.15rem;
  color: var(--muted);
  margin: 0 0 36px;
  max-width: 640px;
}
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
}
.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.card-img img {
  width: 100%;
  aspect-ratio: 1200 / 630;
  object-fit: cover;
}
.card-body {
  padding: 18px 20px 22px;
}
.card h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.3rem;
  line-height: 1.25;
  margin: 0 0 8px;
}
.card h2 a {
  color: var(--ink);
  text-decoration: none;
}
.card h2 a:hover {
  color: var(--brand);
  text-decoration: underline;
}
.card p {
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 0.97rem;
}
.card .meta {
  font-size: 0.85rem;
  margin: 0;
}
.card-big {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  margin-bottom: 24px;
}
.card-big .card-img {
  align-self: center;
}
.card-big .card-body {
  padding: 32px;
  align-self: center;
}
.card-big h2 {
  font-size: clamp(1.5rem, 3vw, 2.1rem);
}

/* post */
.post {
  max-width: 760px;
}
.post-head h1 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2rem, 5vw, 3rem);
  line-height: 1.15;
  margin: 4px 0 14px;
}
.answer {
  background: var(--mint);
  border-left: 5px solid var(--brand);
  border-radius: 10px;
  padding: 16px 20px;
  margin: 24px 0;
}
.answer strong {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--mint-ink);
}
.answer p {
  margin: 6px 0 0;
  font-size: 1.08rem;
  font-weight: 500;
}
.hero {
  margin: 24px 0;
}
.hero img {
  width: 100%;
  aspect-ratio: 1200 / 630;
  object-fit: cover;
  border-radius: 16px;
  border: 1px solid var(--line);
}
.toc {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px 22px;
  margin: 0 0 28px;
}
.toc ol {
  margin: 8px 0 0;
  padding-left: 20px;
}
.toc li {
  margin: 4px 0;
}
.prose {
  font-size: 1.08rem;
}
.prose h2,
.faq h2,
.sources h2,
.more h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.75rem;
  line-height: 1.25;
  margin: 2.2em 0 0.6em;
}
.prose h3,
.faq h3 {
  font-size: 1.2rem;
  margin: 1.6em 0 0.4em;
}
.prose img {
  border-radius: 12px;
  border: 1px solid var(--line);
  margin: 1.4em auto;
}
.prose blockquote {
  margin: 1.4em 0;
  padding: 4px 20px;
  border-left: 4px solid var(--brand-logo);
  color: var(--muted);
}
.prose code {
  background: var(--mint);
  padding: 2px 6px;
  border-radius: 5px;
  font-size: 0.92em;
}
.prose pre {
  background: var(--ink);
  color: #e8f5ea;
  padding: 16px;
  border-radius: 10px;
  overflow-x: auto;
}
.prose pre code {
  background: none;
  padding: 0;
}
.table-wrap {
  overflow-x: auto;
  margin: 1.4em 0;
}
.prose table {
  border-collapse: collapse;
  width: 100%;
  font-size: 0.97rem;
  background: var(--white);
}
.prose th,
.prose td {
  border: 1px solid var(--line);
  padding: 10px 12px;
  text-align: left;
  vertical-align: top;
}
.prose th {
  background: var(--mint);
}
.sources ul {
  padding-left: 20px;
}
.cta {
  background: var(--brand);
  color: #fff;
  border-radius: 16px;
  padding: 28px;
  margin: 48px 0 24px;
}
.cta h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.6rem;
  line-height: 1.25;
  margin: 0 0 8px;
}
.cta p {
  margin: 0 0 18px;
  color: #e6f4e8;
}
.cta .btn {
  background: var(--tag);
  color: var(--ink);
}
.cta .btn:hover {
  background: #ffe27a;
  color: var(--ink);
}
.author {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 20px;
  font-size: 0.97rem;
}
.author img {
  border-radius: 12px;
  flex: none;
}
.author p {
  margin: 0;
  color: var(--muted);
}
.more {
  max-width: 1120px;
  margin-top: 56px;
}
.more .grid {
  margin-top: 16px;
}

@media (max-width: 720px) {
  .card-big {
    grid-template-columns: 1fr;
  }
  .card-big .card-body {
    padding: 20px;
  }
  .site-head nav a:not(.btn):not([aria-current]) {
    display: none;
  }
  .author {
    flex-direction: column;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
