:root {
  color-scheme: light;
  --bg: #fbfaf6;
  --ink: #171819;
  --muted: #6d716b;
  --soft: #f0eee6;
  --panel: #ffffff;
  --line: #ded9cc;
  --green: #244f42;
  --moss: #dce8cb;
  --clay: #9b5d3d;
  --blue: #3d5967;
  --radius: 8px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

a { color: inherit; text-decoration: none; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  padding: 16px clamp(18px, 5vw, 72px);
  background: rgba(251, 250, 246, .94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

.brand { font-size: 19px; font-weight: 950; }

nav {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
}

nav a:hover { color: var(--green); }

main {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 clamp(18px, 5vw, 64px) 72px;
}

.masthead {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 36px;
  align-items: end;
  padding: 46px 0 30px;
  border-bottom: 1px solid var(--line);
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--green);
  font-size: 12px;
  font-weight: 950;
  letter-spacing: .12em;
  text-transform: uppercase;
}

h1, h2, h3, p { margin-top: 0; }

h1 {
  max-width: 720px;
  margin-bottom: 0;
  font-size: clamp(34px, 5vw, 54px);
  line-height: 1.02;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 14px;
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.08;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 8px;
  font-size: 22px;
  line-height: 1.18;
}

p, li {
  color: var(--muted);
  line-height: 1.62;
}

.lede {
  margin-bottom: 0;
  font-size: 17px;
}

.blog-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 32px;
  align-items: start;
  margin-top: 34px;
}

.section-title {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: end;
  margin-bottom: 14px;
}

.post-list {
  display: grid;
  gap: 12px;
}

.article-card {
  display: grid;
  gap: 10px;
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
}

.article-card .tag {
  width: fit-content;
  padding: 5px 9px;
  border-radius: 999px;
  background: var(--moss);
  color: var(--green);
  font-size: 12px;
  font-weight: 950;
}

.article-card p {
  max-width: 680px;
  margin-bottom: 0;
}

.article-card a {
  color: var(--green);
  font-weight: 950;
}

.sidebar-note {
  position: sticky;
  top: 76px;
  display: grid;
  gap: 16px;
}

.score-box,
.ad-slot,
.reference-box,
.callout,
.sources {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
}

.score-box,
.reference-box,
.callout,
.sources {
  padding: 20px;
}

.score-box h2,
.reference-box h2 {
  font-size: 24px;
}

.score-form {
  display: grid;
  gap: 12px;
}

label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 850;
}

input,
select {
  width: 100%;
  min-height: 42px;
  padding: 9px 11px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  font: inherit;
}

.score-form output {
  padding: 14px;
  border-radius: var(--radius);
  background: var(--green);
  color: #fff;
  font-size: 22px;
  font-weight: 950;
}

.ad-slot {
  padding: 18px;
  border-style: dashed;
  border-color: var(--clay);
  background: #fff7ee;
}

.ad-slot span {
  display: block;
  margin-bottom: 8px;
  color: var(--clay);
  font-size: 12px;
  font-weight: 950;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.ad-slot p,
.reference-box ul {
  margin-bottom: 0;
}

.prose {
  max-width: 820px;
  padding-top: 38px;
}

.prose h1 {
  max-width: 820px;
  margin-bottom: 16px;
  font-size: clamp(32px, 4vw, 48px);
}

.prose h2 {
  margin-top: 34px;
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin: 18px 0;
}

.meta-pill {
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.callout {
  margin: 22px 0;
}

.sources {
  margin: 26px 0;
}

.sources a {
  color: var(--green);
  text-decoration: underline;
  text-underline-offset: 3px;
}

@media (max-width: 900px) {
  .topbar { align-items: flex-start; flex-direction: column; }
  .masthead,
  .blog-layout {
    grid-template-columns: 1fr;
  }
  .sidebar-note {
    position: static;
  }
}
