:root {
  color-scheme: dark;
  --bg: #080808;
  --paper: #111111;
  --paper-soft: #171717;
  --ink: #f4f1ea;
  --muted: #bbb4aa;
  --rule: #3a3935;
  --accent: #ffffff;
  --reverse: #050505;
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
  --serif: Georgia, "Times New Roman", Times, serif;
  --sans: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

html[data-theme="light"] {
  color-scheme: light;
  --bg: #f1efe8;
  --paper: #fffdf6;
  --paper-soft: #f7f3e9;
  --ink: #101010;
  --muted: #5e5a52;
  --rule: #c9c1b5;
  --accent: #050505;
  --reverse: #ffffff;
  --shadow: 0 18px 50px rgba(32, 28, 18, 0.15);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at top, rgba(255,255,255,0.08), transparent 30rem),
    var(--bg);
  color: var(--ink);
  font-family: var(--serif);
  line-height: 1.6;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.07;
  background-image: linear-gradient(90deg, transparent 97%, var(--ink) 100%), linear-gradient(0deg, transparent 97%, var(--ink) 100%);
  background-size: 28px 28px;
  mix-blend-mode: difference;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 1rem;
  z-index: 10;
  padding: 0.75rem 1rem;
  background: var(--ink);
  color: var(--reverse);
  font-family: var(--sans);
}

.skip-link:focus {
  left: 1rem;
}

.site-header,
.page-shell,
.site-footer {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  padding: 1rem 0 0;
}

.utility-bar {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  padding: 0.45rem 0;
  color: var(--muted);
  font-family: var(--sans);
  font-size: 0.73rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.masthead {
  margin: 1rem 0 0.8rem;
  background: #fff;
  border: 1px solid var(--rule);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.masthead img {
  display: block;
  width: 100%;
  height: auto;
}

.section-nav {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  border-top: 2px solid var(--ink);
  border-bottom: 1px solid var(--rule);
  background: color-mix(in srgb, var(--paper) 94%, transparent);
  backdrop-filter: blur(10px);
  padding: 0.55rem 0;
  overflow-x: auto;
}

.section-nav a,
.theme-toggle,
.read-link {
  color: var(--ink);
  font-family: var(--sans);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-decoration: none;
  text-transform: uppercase;
}

.section-nav a {
  padding: 0.45rem 0.7rem;
  border-right: 1px solid var(--rule);
  white-space: nowrap;
}

.theme-toggle {
  margin-left: auto;
  padding: 0.5rem 0.8rem;
  border: 1px solid var(--ink);
  background: transparent;
  cursor: pointer;
  white-space: nowrap;
}

.theme-toggle:hover,
.section-nav a:hover,
.read-link:hover {
  background: var(--ink);
  color: var(--reverse);
}

.page-shell {
  background: var(--paper);
  border-left: 1px solid var(--rule);
  border-right: 1px solid var(--rule);
  padding: 1rem;
  box-shadow: var(--shadow);
}

.headline-grid {
  display: grid;
  grid-template-columns: minmax(0, 2.1fr) minmax(280px, 0.9fr);
  gap: 1rem;
  padding-bottom: 1rem;
  border-bottom: 3px double var(--rule);
}

.article-card,
.quote-card {
  background: var(--paper-soft);
  border: 1px solid var(--rule);
  padding: clamp(1rem, 2vw, 1.4rem);
}

.lead-story {
  min-height: 100%;
}

.kicker {
  margin: 0 0 0.4rem;
  color: var(--muted);
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 0.97;
  font-weight: 500;
  letter-spacing: -0.04em;
}

h1 {
  max-width: 900px;
  font-size: clamp(3rem, 8vw, 6.9rem);
}

h2 {
  font-size: clamp(2rem, 4vw, 3.8rem);
}

h3 {
  font-size: clamp(1.35rem, 2.2vw, 2.1rem);
}

.dek {
  color: var(--ink);
  font-size: clamp(1.15rem, 2vw, 1.55rem);
  line-height: 1.35;
}

.article-card p:last-child,
.quote-card p:last-child {
  margin-bottom: 0;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.2rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--rule);
  color: var(--muted);
  font-family: var(--sans);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.front-column {
  display: grid;
  gap: 1rem;
}

.compact h2,
.compact h3 {
  font-size: clamp(1.4rem, 2.4vw, 2rem);
}

.quote-card {
  display: grid;
  align-content: center;
  min-height: 190px;
  background: var(--ink);
  color: var(--reverse);
}

.quote-card p {
  margin: 0;
  font-size: 1.45rem;
  line-height: 1.18;
}

.quote-card span {
  display: block;
  margin-top: 1rem;
  font-family: var(--sans);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.issue-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  margin: 1rem 0;
  background: var(--rule);
  border: 1px solid var(--rule);
}

.issue-strip div {
  display: grid;
  gap: 0.2rem;
  place-items: center;
  min-height: 110px;
  background: var(--paper-soft);
  text-align: center;
}

.stat {
  font-size: clamp(1.7rem, 3vw, 3.1rem);
  line-height: 1;
}

.label {
  color: var(--muted);
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.section-block {
  padding: 1.25rem 0;
  border-top: 1px solid var(--rule);
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.story-grid {
  display: grid;
  gap: 1rem;
}

.three-up {
  grid-template-columns: repeat(3, 1fr);
}

.two-up {
  grid-template-columns: repeat(2, 1fr);
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(260px, 0.8fr);
  gap: 1rem;
}

.feature-card {
  display: grid;
  align-content: center;
}

.mini-list {
  border-top: 1px solid var(--rule);
}

.mini-list article {
  padding: 1rem 0;
  border-bottom: 1px solid var(--rule);
}

.mini-list h3 {
  font-size: 1.6rem;
}

.mini-list p {
  margin-bottom: 0;
  color: var(--muted);
}

.read-link {
  display: inline-block;
  margin-top: 0.8rem;
  border-bottom: 1px solid currentColor;
}

.archive-table {
  border: 1px solid var(--rule);
}

.archive-table > div {
  display: grid;
  grid-template-columns: 0.75fr 2fr 0.5fr;
  gap: 1rem;
  padding: 0.8rem 1rem;
  border-top: 1px solid var(--rule);
}

.archive-table > div:first-child {
  border-top: 0;
}

.table-head {
  background: var(--ink);
  color: var(--reverse);
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.site-footer {
  padding: 1rem 0 2rem;
  color: var(--muted);
  font-family: var(--sans);
  font-size: 0.85rem;
}

.site-footer p {
  margin: 0.2rem 0;
}

@media (max-width: 860px) {
  .headline-grid,
  .split,
  .three-up,
  .two-up {
    grid-template-columns: 1fr;
  }

  .section-heading {
    display: block;
  }

  .issue-strip {
    grid-template-columns: repeat(2, 1fr);
  }

  .archive-table > div {
    grid-template-columns: 1fr;
    gap: 0.25rem;
  }
}

@media (max-width: 560px) {
  .site-header,
  .page-shell,
  .site-footer {
    width: min(100% - 18px, 1180px);
  }

  .utility-bar {
    display: none;
  }

  .page-shell {
    padding: 0.6rem;
  }

  .section-nav {
    padding-left: 0.25rem;
  }

  h1 {
    font-size: 2.8rem;
  }

  .issue-strip {
    grid-template-columns: 1fr;
  }
}

/* Single-column lead page: no sidebar, mission article fills the available newspaper width. */
.headline-grid.mission-only {
  grid-template-columns: 1fr;
}

.headline-grid.mission-only .lead-story {
  grid-column: 1 / -1;
}

.site-footer {
  border-top: 1px solid var(--rule);
  text-align: center;
}
