/* Northline Standard — /research/ shared styles
   Matches the main site: Inter body, Source Serif 4 headings, slate palette.
   Fonts are referenced from the site's existing /fonts/ directory — no external requests. */

@font-face {
  font-family: 'Inter';
  src: url('/fonts/inter-latin.woff2') format('woff2');
  font-weight: 300 600;
  font-display: swap;
}
@font-face {
  font-family: 'Source Serif 4';
  src: url('/fonts/source-serif-4-latin.woff2') format('woff2');
  font-weight: 400 600;
  font-display: swap;
}

:root {
  --ink:        #0f172a;
  --body:       #334155;
  --muted:      #64748b;
  --rule:       #e2e8f0;
  --rule-soft:  #f1f5f9;
  --bg:         #ffffff;
  --bg-soft:    #f8fafc;
  --accent:     #1e3a5f;
  --warn-bg:    #fffbeb;
  --warn-rule:  #f59e0b;
  --measure:    42rem;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--body);
  font-family: Inter, -apple-system, system-ui, 'Segoe UI', sans-serif;
  font-size: 1rem;
  line-height: 1.7;
  font-feature-settings: 'kern' 1, 'liga' 1;
  -webkit-font-smoothing: antialiased;
}

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--ink);
  color: #fff;
  padding: 0.75rem 1.25rem;
  z-index: 100;
  text-decoration: none;
}
.skip:focus { left: 0; }

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

/* ---- masthead ---- */

.masthead {
  border-bottom: 1px solid var(--rule);
  padding: 1.25rem 1.5rem;
}
.masthead-inner {
  max-width: 62rem;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  align-items: baseline;
  justify-content: space-between;
}
.wordmark {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.01em;
}
.wordmark:hover { text-decoration: underline; }
.masthead nav { font-size: 0.875rem; }
.masthead nav a {
  color: var(--muted);
  text-decoration: none;
  margin-left: 1.25rem;
}
.masthead nav a:first-child { margin-left: 0; }
.masthead nav a:hover { color: var(--ink); text-decoration: underline; }

/* ---- layout ---- */

main { padding: 0 1.5rem; }

.wrap { max-width: var(--measure); margin: 0 auto; }
.wrap-wide { max-width: 62rem; margin: 0 auto; }

article { padding: 3.5rem 0 4rem; }

.eyebrow {
  font-size: 0.75rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 1rem;
  font-weight: 600;
}

h1 {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: clamp(2rem, 5vw, 2.85rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 0 0 1rem;
  font-weight: 600;
}

.standfirst {
  font-size: 1.1875rem;
  line-height: 1.6;
  color: var(--muted);
  margin: 0 0 1.75rem;
}

.byline {
  font-size: 0.875rem;
  color: var(--muted);
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--rule);
  margin-bottom: 2.5rem;
}

h2 {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: 1.6rem;
  line-height: 1.3;
  letter-spacing: -0.015em;
  color: var(--ink);
  margin: 3rem 0 1rem;
  font-weight: 600;
}
h2 .num {
  color: var(--muted);
  font-weight: 400;
  margin-right: 0.4rem;
}

h3 {
  font-size: 1.0625rem;
  color: var(--ink);
  margin: 2rem 0 0.6rem;
  font-weight: 600;
}

p { margin: 0 0 1.15rem; }

a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
a:hover { text-decoration-thickness: 2px; }

strong { color: var(--ink); font-weight: 600; }

ul, ol { margin: 0 0 1.15rem; padding-left: 1.35rem; }
li { margin-bottom: 0.5rem; }

blockquote {
  margin: 1.75rem 0;
  padding: 0.25rem 0 0.25rem 1.25rem;
  border-left: 3px solid var(--rule);
  color: var(--muted);
}
blockquote p:last-child { margin-bottom: 0; }

hr {
  border: 0;
  border-top: 1px solid var(--rule);
  margin: 3rem 0;
}

/* ---- tables ---- */

.table-scroll { overflow-x: auto; margin: 1.75rem 0; }
table {
  border-collapse: collapse;
  width: 100%;
  font-size: 0.9375rem;
  min-width: 30rem;
}
caption {
  text-align: left;
  font-size: 0.875rem;
  color: var(--muted);
  padding-bottom: 0.6rem;
}
th, td {
  text-align: left;
  vertical-align: top;
  padding: 0.7rem 1rem 0.7rem 0;
  border-bottom: 1px solid var(--rule);
  line-height: 1.55;
}
th {
  color: var(--ink);
  font-weight: 600;
  border-bottom: 1px solid var(--body);
  font-size: 0.8125rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
td:last-child, th:last-child { padding-right: 0; }

/* ---- callout ---- */

.note {
  background: var(--bg-soft);
  border-left: 3px solid var(--body);
  padding: 1.25rem 1.5rem;
  margin: 2rem 0;
  font-size: 0.9375rem;
}
.note p:last-child { margin-bottom: 0; }

/* ---- sources ---- */

.sources {
  margin-top: 3.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--rule);
  font-size: 0.875rem;
  color: var(--muted);
}
.sources h2 { font-size: 1.125rem; margin-top: 0; }
.sources ul { list-style: none; padding-left: 0; }
.sources li {
  padding-left: 1rem;
  text-indent: -1rem;
  margin-bottom: 0.6rem;
}

.signoff {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--rule);
  font-size: 0.9375rem;
  color: var(--muted);
}
.signoff strong { color: var(--body); }

/* ---- index listing ---- */

.index-head { padding: 3.5rem 0 0; }
.index-head h1 { font-size: clamp(1.85rem, 4.5vw, 2.4rem); }

.entries { list-style: none; padding: 0; margin: 2.5rem 0 4rem; }
.entry {
  padding: 1.75rem 0;
  border-top: 1px solid var(--rule);
}
.entry:last-child { border-bottom: 1px solid var(--rule); }
.entry h2 {
  font-size: 1.3rem;
  margin: 0 0 0.5rem;
  line-height: 1.35;
}
.entry h2 a { color: var(--ink); text-decoration: none; }
.entry h2 a:hover { text-decoration: underline; }
.entry .meta {
  font-size: 0.8125rem;
  color: var(--muted);
  margin: 0 0 0.6rem;
}
.entry p.dek { margin: 0; color: var(--muted); font-size: 0.9375rem; }

/* ---- footer ---- */

.site-footer {
  border-top: 1px solid var(--rule);
  margin-top: 4rem;
  padding: 2.5rem 1.5rem 3rem;
  font-size: 0.875rem;
  color: var(--muted);
}
.site-footer .wrap-wide > p { margin: 0 0 0.4rem; }
.site-footer .tagline {
  font-family: 'Source Serif 4', Georgia, serif;
  color: var(--body);
  font-size: 0.9375rem;
}

@media (max-width: 34rem) {
  .masthead nav a { margin-left: 0; margin-right: 1rem; }
  article { padding-top: 2.5rem; }
}

@media print {
  .masthead nav, .skip { display: none; }
  a { color: var(--body); }
  body { font-size: 11pt; }
}
