:root {
  --ink: #071b31;
  --text: #223544;
  --muted: #5b6f7e;
  --paper: #f8faf9;
  --surface: #ffffff;
  --tint: #edf4f2;
  --accent: #007c73;
  --accent-dark: #005c55;
  --mint: #8cebc9;
  --line: #d9e4e1;
  --line-strong: #bccdc8;
  --serif: Georgia, "Iowan Old Style", "Palatino Linotype", "Book Antiqua", serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; }
a:focus-visible, summary:focus-visible { outline: 3px solid var(--mint); outline-offset: 3px; }
h1, h2, h3, h4, p { margin-top: 0; }
img { max-width: 100%; height: auto; }

.wrap { width: min(1180px, calc(100% - 48px)); margin-inline: auto; }
.skip {
  position: absolute;
  left: -9999px;
  top: 8px;
  background: var(--surface);
  color: var(--ink);
  padding: 10px 14px;
  border: 2px solid var(--accent);
  z-index: 100;
  font-weight: 700;
}
.skip:focus { left: 12px; }

/* Masthead */
.site-header {
  background: var(--ink);
  color: #fff;
  border-bottom: 1px solid rgba(255, 255, 255, .14);
}
.header-inner {
  min-height: 66px;
  display: flex;
  align-items: center;
  gap: 28px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  white-space: nowrap;
  letter-spacing: .06em;
  font-size: 13px;
  line-height: 1.15;
}
.brand strong { font-weight: 800; color: #fff; }
.brand-mark {
  width: 30px;
  height: 28px;
  display: flex;
  align-items: center;
  gap: 3px;
}
.brand-mark i { display: block; width: 4px; border-radius: 6px; background: var(--mint); }
.brand-mark i:nth-child(1), .brand-mark i:nth-child(4) { height: 11px; }
.brand-mark i:nth-child(2) { height: 24px; }
.brand-mark i:nth-child(3) { height: 18px; }
.site-header nav {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-left: auto;
  font-size: 14px;
  font-weight: 600;
  color: #dce8ec;
}
.site-header nav a:hover { color: var(--mint); text-decoration: none; }
.header-cta {
  border: 1px solid rgba(140, 235, 201, .55);
  color: var(--mint);
  padding: 7px 14px;
  border-radius: 3px;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}
.header-cta:hover { background: var(--mint); color: var(--ink); text-decoration: none; }
.mobile-menu { display: none; }

/* Topic sub-bar */
.topic-bar {
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}
.topic-bar-inner {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 10px 0;
  overflow-x: auto;
  white-space: nowrap;
}
.topic-bar-label {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
}
.topic-bar a { color: var(--text); font-weight: 600; }
.topic-bar a:hover { color: var(--accent); text-decoration: none; }

/* Shared editorial typography */
.eyebrow {
  display: inline-block;
  font-family: var(--sans);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .13em;
  text-transform: uppercase;
  color: var(--accent);
  line-height: 1.3;
}
.mono { font-family: var(--mono); font-size: 12.5px; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  border-radius: 3px;
  font-size: 14px;
  font-weight: 700;
  border: 1px solid transparent;
}
.button:hover { text-decoration: none; }
.button-dark { background: var(--ink); color: #fff; }
.button-dark:hover { background: #123355; }
.button-light { background: var(--mint); color: var(--ink); }
.button-light:hover { background: #aef1d9; }
.button-outline { background: var(--surface); color: var(--ink); border-color: var(--line-strong); }
.button-outline:hover { border-color: var(--ink); }

/* Front page newsroom layout */
.front-section { padding: 32px 0 42px; border-bottom: 1px solid var(--line); }
.front-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr);
  gap: 36px;
  align-items: start;
}
.lead-story {
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 3px solid var(--ink);
}
.lead-photo { margin: 0; position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: var(--ink); }
.lead-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.lead-photo figcaption {
  position: absolute;
  right: 12px;
  bottom: 10px;
  background: rgba(7, 27, 49, .78);
  color: #e3f0f2;
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 2px;
}
.lead-body { padding: 24px 26px 26px; }
.lead-body h1 {
  font-family: var(--serif);
  font-size: clamp(28px, 3.1vw, 38px);
  line-height: 1.18;
  color: var(--ink);
  margin: 10px 0 12px;
  font-weight: 700;
}
.lead-body h1 a:hover { color: var(--accent); text-decoration: none; }
.lead-deck { font-size: 16.5px; color: var(--text); margin: 0 0 16px; line-height: 1.55; }
.lead-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  font-size: 12.5px;
  color: var(--muted);
  border-top: 1px solid var(--line);
  padding-top: 14px;
}
.lead-meta a { color: var(--accent); font-weight: 700; margin-left: auto; }

/* Right column: Latest dispatches */
.dispatch-box {
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 3px solid var(--accent);
  padding: 20px 22px 10px;
}
.dispatch-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}
.dispatch-head h2 { font-family: var(--serif); font-size: 20px; margin: 0; color: var(--ink); }
.dispatch-head a { font-size: 13px; font-weight: 700; color: var(--accent); }
.dispatch-list { list-style: none; margin: 0; padding: 0; }
.dispatch-list li {
  padding: 15px 0;
  border-bottom: 1px solid var(--line);
}
.dispatch-list li:last-child { border-bottom: 0; }
.dispatch-list h3 {
  font-family: var(--serif);
  font-size: 17.5px;
  line-height: 1.3;
  margin: 5px 0 6px;
  color: var(--ink);
  font-weight: 700;
}
.dispatch-list h3 a:hover { color: var(--accent); text-decoration: none; }
.dispatch-list p { font-size: 13.5px; color: var(--muted); margin: 0 0 6px; line-height: 1.45; }
.dispatch-meta { font-size: 12px; color: var(--muted); display: flex; gap: 12px; }

/* By the numbers strip */
.stats-band { background: var(--ink); color: #fff; padding: 34px 0; }
.stats-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 18px; gap: 16px; }
.stats-head h2 { font-family: var(--serif); font-size: 22px; margin: 0; color: #fff; }
.stats-head span { font-size: 12px; color: #9ebbc4; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.stat-card {
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(255, 255, 255, .14);
  padding: 18px 18px 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.stat-card:hover { background: rgba(255, 255, 255, .1); text-decoration: none; }
.stat-num { font-family: var(--mono); font-size: 26px; font-weight: 700; color: var(--mint); line-height: 1.1; }
.stat-label { font-size: 13.5px; color: #e2eef1; line-height: 1.4; }
.stat-src { font-size: 11.5px; color: #9ab7c1; margin-top: auto; padding-top: 6px; }

/* Editorial card grids (no repetitive placeholder circles) */
.section-block { padding: 44px 0; border-bottom: 1px solid var(--line); }
.section-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 20px;
  margin-bottom: 22px;
}
.section-top h2 { font-family: var(--serif); font-size: 26px; margin: 4px 0 0; color: var(--ink); }
.section-top a { font-size: 13.5px; font-weight: 700; color: var(--accent); white-space: nowrap; }

.brief-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.brief-grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }

.brief-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 3px solid var(--accent);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: border-color .15s, box-shadow .15s;
}
.brief-card:hover { border-color: var(--line-strong); box-shadow: 0 8px 20px rgba(7, 27, 49, .05); }
.brief-card.beat-research { border-top-color: #007c73; }
.brief-card.beat-policy { border-top-color: #1d4f73; }
.brief-card.beat-technology { border-top-color: #2b4c7e; }
.brief-card.beat-data-and-market { border-top-color: #0f6b5e; }
.brief-card.beat-methods { border-top-color: #465d6e; }

.brief-thumb { aspect-ratio: 16 / 9; overflow: hidden; background: var(--tint); border-bottom: 1px solid var(--line); }
.brief-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.brief-body { padding: 20px 22px; display: flex; flex-direction: column; flex: 1; }
.brief-meta-top {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 9px;
}
.brief-meta-top span:last-child { color: var(--muted); font-weight: 600; }
.brief-card h3 {
  font-family: var(--serif);
  font-size: 19px;
  line-height: 1.3;
  margin: 0 0 9px;
  color: var(--ink);
  font-weight: 700;
}
.brief-card h3 a:hover { color: var(--accent); text-decoration: none; }
.brief-card p { font-size: 14px; color: var(--muted); margin: 0 0 16px; line-height: 1.55; }
.brief-foot {
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--muted);
}
.brief-foot a { color: var(--accent); font-weight: 700; }

/* Compact methodology strip on homepage */
.method-strip {
  background: var(--tint);
  border: 1px solid var(--line);
  padding: 26px 30px;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 28px;
  align-items: center;
}
.method-strip h2 { font-family: var(--serif); font-size: 24px; margin: 6px 0 8px; color: var(--ink); }
.method-strip p { margin: 0; font-size: 15px; color: var(--text); }
.method-strip-actions { display: flex; flex-wrap: wrap; gap: 12px; justify-content: flex-end; }

/* Page / Article / Hub headers (compact off-white editorial style — above-the-fold content!) */
.page-header {
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  padding: 26px 0 28px;
}
.breadcrumb-nav {
  font-size: 12.5px;
  color: var(--muted);
  margin-bottom: 14px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.breadcrumb-nav a { color: var(--accent); font-weight: 600; }
.page-header h1 {
  font-family: var(--serif);
  font-size: clamp(30px, 3.6vw, 44px);
  line-height: 1.15;
  color: var(--ink);
  max-width: 880px;
  margin: 8px 0 12px;
  font-weight: 700;
}
.page-deck {
  font-size: 18px;
  line-height: 1.5;
  color: var(--muted);
  max-width: 780px;
  margin: 0;
}
.byline-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: var(--muted);
}
.byline-row strong { color: var(--ink); font-weight: 700; }

/* Topic switcher pills */
.topic-pills { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.topic-pill {
  display: inline-block;
  padding: 6px 13px;
  border: 1px solid var(--line-strong);
  border-radius: 3px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  background: var(--paper);
}
.topic-pill:hover, .topic-pill.active {
  background: var(--ink);
  color: #fff;
  border-color: var(--ink);
  text-decoration: none;
}

/* Article 2-column layout */
.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 740px) minmax(260px, 1fr);
  gap: 48px;
  padding: 34px 0 76px;
  align-items: start;
}
.article-body { font-size: 17px; line-height: 1.72; color: var(--text); }
.article-body h2 {
  font-family: var(--serif);
  font-size: 25px;
  line-height: 1.25;
  color: var(--ink);
  margin: 36px 0 12px;
  scroll-margin-top: 24px;
}
.article-body h2:first-child { margin-top: 0; }
.article-body p { margin-bottom: 20px; }
.article-body ul { padding-left: 22px; margin: 0 0 22px; }
.article-body li { margin: 8px 0; }
.article-body a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.article-body a:hover { color: var(--accent-dark); }

/* Short answer box */
.short-answer {
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent);
  padding: 20px 24px;
  margin: 0 0 28px;
}
.short-answer p { margin: 8px 0 0; font-size: 16.5px; line-height: 1.65; color: var(--ink); }

/* Article figure */
.article-image { margin: 0 0 28px; }
.article-image img {
  display: block;
  width: 100%;
  max-height: 410px;
  object-fit: cover;
  border: 1px solid var(--line);
}
.article-image figcaption { padding-top: 8px; color: var(--muted); font-size: 12.5px; }

/* Tables */
.data-table {
  width: 100%;
  border-collapse: collapse;
  margin: 18px 0 28px;
  font-size: 14.5px;
  background: var(--surface);
  border: 1px solid var(--line);
}
.data-table th, .data-table td {
  text-align: left;
  padding: 11px 14px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
  line-height: 1.48;
}
.data-table th {
  background: var(--tint);
  color: var(--ink);
  font-size: 11.5px;
  letter-spacing: .07em;
  text-transform: uppercase;
  font-weight: 800;
}

/* Editorial callouts */
.takeaway {
  background: var(--tint);
  border-left: 3px solid var(--accent);
  padding: 20px 24px;
  margin: 28px 0;
}
.takeaway p { margin: 6px 0 0; font-size: 16.5px; color: var(--ink); font-weight: 600; }

.panda-note {
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 3px solid var(--ink);
  padding: 20px 24px;
  margin: 28px 0;
}
.panda-note p { margin: 8px 0 0; font-size: 15px; line-height: 1.62; color: var(--text); }

/* FAQ & Primary sources & Related */
.faq-section, .sources, .related-section {
  border-top: 1px solid var(--line);
  margin-top: 40px;
  padding-top: 28px;
}
.faq-item {
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 18px 20px;
  margin: 12px 0;
}
.faq-item h3 { font-family: var(--serif); font-size: 17.5px; line-height: 1.35; margin: 0 0 6px; color: var(--ink); }
.faq-item p { margin: 0; font-size: 15px; color: var(--text); }
.sources ul { padding-left: 20px; margin: 12px 0 14px; }
.sources li { margin: 8px 0; font-size: 15px; }
.sources > p { font-size: 13px; color: var(--muted); margin: 0; }

.related-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 14px; }
.related-card {
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-decoration: none !important;
}
.related-card:hover { border-color: var(--accent); }
.related-card span { font-size: 10.5px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--accent); }
.related-card strong { font-family: var(--serif); font-size: 15.5px; line-height: 1.3; color: var(--ink); }
.related-card p { margin: 0; font-size: 13px; color: var(--muted); line-height: 1.45; }

/* Article sidebar */
.article-aside { display: flex; flex-direction: column; gap: 18px; }
.aside-box {
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 3px solid var(--ink);
  padding: 18px 20px;
}
.aside-box.aside-accent { border-top-color: var(--accent); }
.aside-box h2 {
  font-family: var(--sans);
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink);
  margin: 0 0 12px;
}
.aside-box p { font-size: 14px; color: var(--muted); margin: 0 0 12px; line-height: 1.5; }
.aside-box a.aside-link { font-size: 13px; font-weight: 700; color: var(--accent); }
.meta-dl { margin: 0; font-size: 13px; }
.meta-dl dt { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 700; margin-top: 10px; }
.meta-dl dt:first-child { margin-top: 0; }
.meta-dl dd { margin: 2px 0 0; color: var(--ink); word-break: break-word; }
.toc-list { list-style: none; margin: 0; padding: 0; }
.toc-list li { border-top: 1px solid var(--line); }
.toc-list li:first-child { border-top: 0; }
.toc-list a {
  display: block;
  padding: 8px 0;
  font-size: 13.5px;
  color: var(--text);
  line-height: 1.35;
}
.toc-list a:hover { color: var(--accent); text-decoration: none; }

/* Info pages & hubs & 404 */
.info-body { max-width: 780px; padding: 34px 0 76px; }
.hub-section { padding: 36px 0 64px; }
.hub-divider { border-top: 1px solid var(--line); padding-top: 36px; margin-top: 36px; }
.topic-card-lg {
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 3px solid var(--ink);
  padding: 24px 26px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.topic-card-lg h2 { font-family: var(--serif); font-size: 22px; margin: 0; color: var(--ink); }
.topic-card-lg p { margin: 0; font-size: 14.5px; color: var(--muted); }
.topic-card-lg a.topic-cta { margin-top: auto; padding-top: 10px; color: var(--accent); font-weight: 700; font-size: 13.5px; }
.error-wrap { padding: 72px 0 96px; max-width: 680px; }
.error-wrap h1 { font-family: var(--serif); font-size: clamp(32px, 4vw, 46px); margin: 10px 0 14px; color: var(--ink); }
.error-wrap p { font-size: 17px; color: var(--muted); margin-bottom: 24px; }
.error-links { display: flex; flex-wrap: wrap; gap: 12px; }

/* Footer */
.site-footer {
  background: var(--ink);
  color: #bfd1d8;
  padding: 46px 0 24px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 44px;
}
.footer-brand { font-size: 15px; letter-spacing: .08em; color: #fff; }
.footer-grid p { max-width: 340px; font-size: 13.5px; color: #9ab3be; margin: 12px 0 0; }
.footer-grid h2 {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--mint);
  margin: 0 0 14px;
}
.footer-grid > div:not(:first-child) a { display: block; margin: 9px 0; font-size: 13.5px; color: #d1e0e6; }
.footer-grid > div:not(:first-child) a:hover { color: var(--mint); text-decoration: none; }
.foot-bottom {
  border-top: 1px solid rgba(255, 255, 255, .14);
  margin-top: 34px;
  padding-top: 18px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 12px;
  color: #87a4b0;
}
.foot-bottom a { text-decoration: underline; text-underline-offset: 3px; }

/* Responsive */
@media (max-width: 980px) {
  .front-grid { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .brief-grid-3 { grid-template-columns: repeat(2, 1fr); }
  .article-layout { grid-template-columns: 1fr; gap: 32px; }
  .method-strip { grid-template-columns: 1fr; }
  .method-strip-actions { justify-content: flex-start; }
  .related-grid { grid-template-columns: repeat(2, 1fr); }
  .header-cta { display: none; }
}

@media (max-width: 700px) {
  .wrap { width: min(100% - 32px, 1180px); }
  .site-header { position: relative; }
  .site-header > .wrap > nav { display: none; }
  .mobile-menu { display: block; margin-left: auto; }
  .mobile-menu summary {
    list-style: none;
    border: 1px solid rgba(255, 255, 255, .38);
    color: #fff;
    padding: 7px 12px;
    font-size: 13px;
    font-weight: 700;
    border-radius: 3px;
    cursor: pointer;
  }
  .mobile-menu summary::-webkit-details-marker { display: none; }
  .mobile-menu[open] nav {
    display: flex;
    flex-direction: column;
    position: absolute;
    left: 0;
    right: 0;
    top: 66px;
    background: var(--ink);
    border-top: 1px solid rgba(255, 255, 255, .16);
    padding: 12px 16px 18px;
    gap: 0;
    z-index: 50;
  }
  .mobile-menu nav a {
    display: block;
    width: 100%;
    padding: 10px 0;
    font-size: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, .08);
  }
  .mobile-menu nav a:last-child { border-bottom: 0; }
  .stats-grid, .brief-grid-3, .brief-grid-2, .related-grid, .footer-grid { grid-template-columns: 1fr; }
  .data-table { display: block; overflow-x: auto; }
  .lead-body { padding: 18px; }
  .method-strip { padding: 20px; }
}
