@font-face {
  font-family: Inter;
  src: url("/assets/fonts/inter-400-700.woff2") format("woff2");
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
}

:root {
  color-scheme: dark;
  --canvas: #111413;
  --panel: #191e1b;
  --panel-hover: #202622;
  --text: #f0f3ed;
  --subtle: #b2bcb3;
  --rule: #363f37;
  --accent: #d1ea8d;
  --on-accent: #182111;
  --shell: 80rem;
  --gutter: clamp(1rem, 4vw, 4rem);
  --font: Inter, system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

body {
  margin: 0;
  background: var(--canvas);
  color: var(--text);
  font: 1rem / 1.55 var(--font);
  -webkit-text-size-adjust: 100%;
}

a { color: inherit; }
a:focus-visible, input:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

img { display: block; max-width: 100%; }
p { text-wrap: pretty; }

h1, h2, h3 {
  margin: 0;
  font-weight: 700;
  letter-spacing: -.047em;
  line-height: 1.07;
  text-wrap: balance;
}

.wrap {
  width: min(var(--shell), calc(100% - 2 * var(--gutter)));
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  inset: .8rem auto auto .8rem;
  z-index: 2;
  padding: .6rem .85rem;
  background: var(--accent);
  color: var(--on-accent);
  transform: translateY(-170%);
}
.skip-link:focus { transform: translateY(0); }

.site-header { border-bottom: 1px solid var(--rule); }
.header-inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  min-height: 4.8rem;
  align-items: center;
  gap: 0 1.6rem;
}
.wordmark {
  display: inline-flex;
  max-width: 100%;
  width: max-content;
  align-items: center;
  gap: .66rem;
  font-size: clamp(1rem, 2.15vw, 1.25rem);
  font-weight: 700;
  letter-spacing: -.06em;
  line-height: 1.2;
  text-decoration: none;
}
.brand-mark {
  display: grid;
  width: 2.1rem;
  height: 2.1rem;
  place-items: center;
  border-radius: .36rem;
  background: var(--accent);
  color: var(--on-accent);
  font-size: .89rem;
  letter-spacing: -.11em;
}
.nav-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0 clamp(.95rem, 2.8vw, 2.4rem);
  margin: 0;
  padding: 0;
  list-style: none;
}
.nav-list a {
  display: flex;
  min-height: 2.75rem;
  align-items: center;
  color: var(--subtle);
  font-size: .875rem;
  font-weight: 650;
  text-decoration: none;
}
.nav-list a:hover, .nav-list a[aria-current="page"] { color: var(--accent); }
.nav-list a[aria-current="page"] {
  text-decoration: underline;
  text-underline-offset: .43em;
}
.guide-search {
  display: flex;
  justify-self: end;
  min-height: 2.75rem;
  align-items: center;
  gap: .5rem;
  border: 1px solid var(--rule);
  border-radius: .4rem;
  padding: 0 .75rem;
  font-size: .83rem;
  font-weight: 650;
  text-decoration: none;
  white-space: nowrap;
}
.guide-search:hover, .guide-search[aria-current="page"] {
  border-color: var(--accent);
  color: var(--accent);
}
.search-suffix { margin-inline-start: -.3rem; }
.search-mark {
  position: relative;
  display: inline-block;
  width: .74rem;
  height: .74rem;
  margin: 0 .13rem .11rem 0;
  border: 1.5px solid currentColor;
  border-radius: 50%;
}
.search-mark::after {
  position: absolute;
  inset: auto -.26rem -.16rem auto;
  width: .37rem;
  height: 1.5px;
  background: currentColor;
  content: "";
  transform: rotate(45deg);
}

.front-page {
  display: grid;
  grid-template-columns: minmax(0, 2.2fr) minmax(0, 1fr);
  align-items: start;
  gap: clamp(1.25rem, 3vw, 2.5rem);
  padding-block: clamp(1.5rem, 3.4vw, 3rem) clamp(2.4rem, 4.5vw, 3.75rem);
}

.lead {
  min-width: 0;
  overflow: clip;
  border: 1px solid var(--rule);
  border-radius: .65rem;
  background: var(--panel);
}
.lead:only-child { grid-column: 1 / -1; }
.lead-copy { padding: clamp(1.15rem, 3vw, 2.35rem); padding-top: clamp(.7rem, 2vw, 1.4rem); }
.lead h1 {
  max-width: 26ch;
  margin-top: .65rem;
  font-size: clamp(2.3rem, 4.55vw, 3.75rem);
  letter-spacing: -.057em;
  text-wrap: pretty;
}
.lead h1 a, .rail-story h3 a, .story-card h3 a { text-decoration: none; }
.lead h1 a:hover, .rail-story h3 a:hover, .story-card h3 a:hover { color: var(--accent); }
.lead-copy > p {
  max-width: 53ch;
  margin: .8rem 0 1.25rem;
  color: var(--subtle);
  font-size: clamp(.98rem, 1.48vw, 1.12rem);
}
.story-link {
  display: inline-flex;
  min-height: 2.75rem;
  align-items: center;
  gap: .75rem;
  border: 1px solid var(--accent);
  border-radius: .35rem;
  padding: .35rem .78rem;
  background: var(--accent);
  color: var(--on-accent);
  font-size: .83rem;
  font-weight: 700;
  text-decoration: none;
}
.story-link:hover { background: #e0f5ae; }
.story-link span, .view-more span { font-size: 1.1em; }

.story-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: .25rem .85rem;
}
.section-label {
  display: inline-block;
  color: var(--accent);
  font-size: .71rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-decoration: none;
  text-transform: uppercase;
}
.section-label:hover { text-decoration: underline; text-underline-offset: .2em; }
.reading-time { color: var(--subtle); font-size: .73rem; font-weight: 500; }

.reading-rail {
  border-block-start: 2px solid var(--accent);
  padding: 1rem 0 0;
}
.reading-rail > h2 { margin-block-end: .4rem; font-size: clamp(1.32rem, 2.5vw, 1.85rem); }
.rail-story {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
  gap: .6rem;
  border-bottom: 1px solid var(--rule);
  padding-block: .85rem;
}
.rail-story h3 {
  margin-block: .38rem .45rem;
  font-size: clamp(1.04rem, 2vw, 1.28rem);
  letter-spacing: -.034em;
  line-height: 1.25;
  text-wrap: pretty;
}
.rail-story img {
  grid-row: 1;
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 1;
  border-radius: .32rem;
  object-fit: cover;
}
.view-more {
  display: inline-flex;
  min-height: 2.75rem;
  align-items: center;
  gap: .5rem;
  color: var(--accent);
  font-size: .84rem;
  font-weight: 650;
  text-decoration: none;
}
.view-more:hover { text-decoration: underline; text-underline-offset: .22em; }

.photo { min-width: 0; margin: 0; }
.photo img {
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  background: var(--panel);
  object-fit: cover;
  object-position: var(--photo-position, center);
}
.photo--lead img { aspect-ratio: 2.38 / 1; }
.photo figcaption {
  min-height: 1rem;
  margin-top: .45rem;
  color: var(--subtle);
  font-size: .67rem;
  line-height: 1.45;
}
.photo--lead figcaption { padding-inline: clamp(1.15rem, 3vw, 2.35rem); }
.photo figcaption a { text-decoration-color: #77837a; text-underline-offset: .18em; }
.photo figcaption a:hover { color: var(--accent); }

.story-section { padding-bottom: clamp(2.55rem, 5.5vw, 5rem); }
.section-heading {
  display: flex;
  flex-wrap: wrap;
  min-height: 3rem;
  align-items: center;
  justify-content: space-between;
  gap: .25rem 1rem;
  border-top: 1px solid var(--rule);
  margin-bottom: 1.05rem;
  padding-top: .75rem;
}
.section-heading h2 { font-size: clamp(1.6rem, 3.4vw, 2.35rem); }

.story-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1rem, 2.9vw, 2.3rem);
}
.story-card {
  min-width: 0;
  border: 1px solid var(--rule);
  border-radius: .55rem;
  background: var(--panel);
  overflow: clip;
}
.story-card:hover { border-color: #707e6a; }
.story-card .photo figcaption { padding-inline: .95rem; }
.story-copy { padding: .95rem 1rem 1.15rem; }
.story-card h3 {
  margin-top: .45rem;
  font-size: clamp(1.25rem, 2.28vw, 1.65rem);
  line-height: 1.15;
  text-wrap: pretty;
}
.story-card p {
  margin: .55rem 0 0;
  color: var(--subtle);
  font-size: .9rem;
  line-height: 1.55;
}

.page-heading, .article-header {
  padding-block: clamp(2.1rem, 4.35vw, 4rem) clamp(1.65rem, 3vw, 2.6rem);
}
.page-heading h1, .article-header h1 {
  max-width: 20ch;
  font-size: clamp(2.45rem, 6.4vw, 5.45rem);
  letter-spacing: -.064em;
}
.page-heading p, .article-dek {
  max-width: 55ch;
  margin: .85rem 0 0;
  color: var(--subtle);
  font-size: clamp(1.02rem, 1.8vw, 1.25rem);
}
.article-header h1 { margin-top: .6rem; }
.byline {
  margin: 1.2rem 0 0;
  color: var(--subtle);
  font-size: .82rem;
  font-weight: 650;
}
.byline span { margin-inline: .3rem; }

.photo--feature img {
  aspect-ratio: 2.45 / 1;
  max-height: 28rem;
  border-radius: .65rem;
}
.article-layout {
  display: grid;
  grid-template-columns: minmax(10rem, 15rem) minmax(0, 44rem);
  align-items: start;
  gap: clamp(1.9rem, 6vw, 6rem);
  padding-block: clamp(2rem, 5vw, 4.1rem) clamp(2.6rem, 6vw, 4.7rem);
}
.contents {
  position: sticky;
  top: 1.25rem;
  border: 1px solid var(--rule);
  border-radius: .55rem;
  background: var(--panel);
  padding: .95rem 1rem;
}
.contents h2 { margin-bottom: .4rem; font-size: .86rem; letter-spacing: 0; }
.contents ul { margin: 0; padding: 0; list-style: none; font-size: .84rem; }
.contents a {
  display: block;
  padding-block: .36rem;
  color: var(--subtle);
  text-decoration: none;
}
.contents a:hover { color: var(--accent); text-decoration: underline; }
.article-body {
  max-width: 45rem;
  font-size: clamp(1rem, 1.45vw, 1.12rem);
  line-height: 1.76;
}
.article-section + .article-section, .sources { margin-top: clamp(1.8rem, 4vw, 3rem); }
.article-section h2, .sources h2 {
  margin: 0 0 .7rem;
  font-size: clamp(1.45rem, 3vw, 2.05rem);
  line-height: 1.13;
  text-wrap: pretty;
  scroll-margin-top: 1.2rem;
}
.article-section h2:target { color: var(--accent); }
.article-section p { margin: 0 0 .85rem; }
.article-section p:last-child { margin-bottom: 0; }
.article-section ul, .sources ul { padding-inline-start: 1.35rem; }
.article-section li + li, .sources li + li { margin-top: .38rem; }
.article-body a { color: var(--accent); overflow-wrap: anywhere; text-underline-offset: .17em; }
.sources {
  border-top: 1px solid var(--rule);
  padding-top: 1.1rem;
  color: var(--subtle);
  font-size: .94rem;
}
.sources ul { margin-block: .6rem 0; }
.about-body { padding-bottom: clamp(3rem, 8vw, 6rem); }
.missing .story-link { margin-top: 1.25rem; }

.guide-filter {
  display: grid;
  max-width: 35rem;
  gap: .55rem;
  margin-bottom: 1.45rem;
}
.guide-filter label { font-size: .875rem; font-weight: 650; }
.guide-filter input {
  min-height: 3rem;
  width: 100%;
  min-width: 0;
  border: 1px solid var(--rule);
  border-radius: .4rem;
  padding: .6rem .85rem;
  background: var(--panel);
  color: var(--text);
  font: inherit;
}
.guide-filter input::placeholder { color: var(--subtle); }
.guide-filter p { margin: 0; color: var(--subtle); font-size: .86rem; }

.site-footer {
  border-top: 1px solid var(--rule);
  background: var(--panel);
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: .4rem 1.3rem;
  padding-block: 1rem;
}
.footer-brand { font-size: 1.04rem; font-weight: 700; text-decoration: none; }
.footer-links { display: flex; flex-wrap: wrap; gap: 0 1.2rem; }
.footer-links a {
  display: inline-flex;
  min-height: 2.75rem;
  align-items: center;
  color: var(--subtle);
  font-size: .82rem;
  text-decoration: none;
}
.footer-links a:hover { color: var(--accent); text-decoration: underline; }

@media (max-width: 58rem) {
  .front-page { grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr); }
  .story-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .search-suffix { display: none; }
}

@media (max-width: 43rem) {
  .header-inner { grid-template-columns: minmax(0, 1fr) auto; padding-top: .65rem; }
  .header-inner nav { grid-row: 2; grid-column: 1 / -1; }
  .guide-search { grid-row: 1; grid-column: 2; }
  .front-page { grid-template-columns: minmax(0, 1fr); gap: 1.65rem; }
  .lead h1 { font-size: clamp(2.15rem, 8.6vw, 3.55rem); }
  .photo--lead img { aspect-ratio: 16 / 9; }
  .rail-story { grid-template-columns: minmax(0, 1fr) auto; gap: 1rem; }
  .rail-story img { grid-row: auto; width: 4.6rem; aspect-ratio: 1 / 1; }
  .article-layout { grid-template-columns: 1fr; }
  .contents { position: static; max-width: 44rem; }
  .photo--feature img { aspect-ratio: 16 / 9; }
}

@media (max-width: 30rem) {
  .story-grid { grid-template-columns: 1fr; }
  .story-card h3 { font-size: 1.45rem; }
}
