/* Cormorant Garamond and Inter are under the SIL Open Font License. See /fonts. */
@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal;
  font-weight: 600;
  font-display: optional;
  src: url("../fonts/cormorant-garamond-600.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: Inter;
  font-style: normal;
  font-weight: 400 600;
  font-display: optional;
  src: url("../fonts/inter-400.woff2") format("woff2");
  size-adjust: 100%;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --bg: #0b0b0c;
  --bg-elev: #111113;
  --bg-elev-2: #17171a;
  --gold: #c9a24a;
  --gold-bright: #e0b65a;
  --gold-link: #f0d48a;
  --text: #ece6d8;
  --muted: #cfc6b4;
  --line: rgba(201, 162, 74, 0.32);
  --focus: #f3d98a;
  --header-h: 4.25rem;
  --serif: "Cormorant Garamond", "Palatino Linotype", Palatino, Georgia, serif;
  --sans: Inter, "Segoe UI", sans-serif;
  color-scheme: dark;
}

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

html {
  background: var(--bg);
  scroll-padding-top: 5.5rem;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(ellipse 90% 45% at 0% -10%, rgba(201, 162, 74, 0.1), transparent 52%),
    radial-gradient(ellipse 50% 35% at 100% 0%, rgba(224, 182, 90, 0.05), transparent 46%),
    var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.55;
  font-variant-numeric: tabular-nums;
}

[id] {
  scroll-margin-top: 5.5rem;
}

img,
svg {
  max-width: 100%;
}

h1,
h2,
h3 {
  font-family: var(--serif);
  font-weight: 600;
  line-height: 0.98;
  letter-spacing: -0.02em;
}

h1 {
  font-size: clamp(2.7rem, 7vw, 6.2rem);
  margin: 0.2rem 0 0.55rem;
}

h2 {
  font-size: clamp(1.8rem, 3vw, 2.55rem);
  margin: 0 0 0.75rem;
}

h3 {
  font-size: clamp(1.35rem, 2vw, 1.7rem);
  margin: 0 0 0.4rem;
}

p {
  margin: 0.45rem 0;
}

a {
  color: var(--gold-link);
  text-underline-offset: 0.18em;
  overflow-wrap: anywhere;
}

p,
td,
dd,
li {
  overflow-wrap: anywhere;
}

::placeholder {
  color: var(--muted);
  opacity: 1;
}

a:hover {
  color: #fff4d2;
}

:focus {
  outline: none;
}

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

.skip-link {
  position: absolute;
  left: 0.75rem;
  top: 0.5rem;
  transform: translateY(-150%);
  z-index: 100;
  background: var(--gold-bright);
  color: var(--bg);
  font-weight: 600;
  text-decoration: none;
  padding: 0.55rem 0.85rem;
}

.skip-link:focus {
  transform: none;
}

.wrap {
  width: min(1120px, calc(100% - 2rem));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(11, 11, 12, 0.96);
  border-bottom: 1px solid var(--line);
}

.header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  min-height: var(--header-h);
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text);
  text-decoration: none;
  font-family: var(--serif);
  font-size: 1.4rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1;
}

.wordmark:hover {
  color: var(--gold-link);
}

.mark {
  display: inline-grid;
  place-items: center;
  width: 1.8rem;
  height: 1.8rem;
  border: 1px solid var(--gold);
  color: var(--gold-bright);
  font-size: 0.95rem;
  flex: 0 0 auto;
}

.nav-toggle {
  display: none;
  width: 2.75rem;
  height: 2.75rem;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--gold-bright);
  padding: 0;
  cursor: pointer;
}

.bars {
  display: grid;
  gap: 5px;
  width: 1.15rem;
}

.bars span {
  display: block;
  height: 1px;
  background: var(--gold-bright);
  transform-origin: center;
}

.site-nav ul {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.1rem 0.2rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  padding: 0.2rem 0.45rem;
  color: var(--text);
  text-decoration: none;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--gold-link);
}

.site-nav a[aria-current="page"] {
  box-shadow: inset 0 -1px 0 var(--gold-bright);
}

.nav-backdrop {
  position: fixed;
  inset: 0;
  z-index: 30;
  border: 0;
  background: rgba(0, 0, 0, 0.55);
  cursor: pointer;
}

.hero,
.page-header {
  padding: 2rem 0 0.4rem;
}

.page-header {
  border-bottom: 1px solid var(--line);
  margin-bottom: 0.4rem;
  padding-bottom: 1.2rem;
}

.hero-grid {
  display: grid;
  gap: 1rem;
  align-items: end;
}

.eyebrow,
.kicker,
.stat-label,
.cell-label,
.subhead,
.matter h4,
.conflict h4 {
  margin: 0;
  color: var(--gold-bright);
  font-family: var(--sans);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.lede {
  margin: 0;
  max-width: 42rem;
  font-size: 1.125rem;
  min-height: 3.2em;
}

.notice {
  max-width: 42rem;
  color: var(--muted);
  min-height: 3.2em;
}

.hero-art svg {
  width: min(100%, 240px);
  height: auto;
}

.section {
  margin: 2.1rem 0;
}

.muted,
.asof,
.src-pub,
.trail-context,
.source-note {
  color: var(--muted);
}

.stat-grid,
.teaser-grid,
.card-grid,
.countdown-grid,
.sides {
  display: grid;
  gap: 0.9rem;
}

.stat-card,
.teaser,
.info-card,
.countdown,
.side,
.case-fallback {
  background: var(--bg-elev);
  border: 1px solid var(--line);
  padding: 1rem 1.05rem 1.1rem;
}

.stat-value,
.countdown-num,
.trail-token {
  font-family: var(--serif);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
  line-height: 1;
}

.stat-value {
  display: block;
  margin: 0.35rem 0;
  font-size: clamp(1.8rem, 4vw, 2.7rem);
}

.stat-value.long {
  font-size: clamp(1.25rem, 2vw, 1.7rem);
  line-height: 1.2;
}

.teaser {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-height: 100%;
  color: inherit;
  text-decoration: none;
}

.teaser h3 {
  margin: 0;
  color: var(--text);
}

.teaser:hover,
.stat-card:hover,
.info-card:hover {
  border-color: var(--gold-bright);
}

.badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin: 0.35rem 0 0.6rem;
}

.badge,
.role-tag {
  display: inline-block;
  border: 1px solid var(--gold);
  padding: 0.15rem 0.45rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  line-height: 1.4;
}

.badge {
  background: #2a2416;
  color: #f3d98a;
}

.badge-pending {
  background: var(--gold-bright);
  color: #0b0b0c;
  border-color: var(--gold-bright);
}

.badge-allegation {
  background: #3a2428;
  color: #f6d2cb;
  border-color: #e7b2a8;
}

.role-tag {
  color: var(--text);
  border-color: var(--line);
  letter-spacing: 0;
  text-transform: none;
  font-weight: 400;
  line-height: 1.45;
}

.facts {
  display: grid;
  gap: 0.35rem 1rem;
  margin: 0.5rem 0 0.8rem;
}

.facts dt {
  color: var(--gold-bright);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.facts dd {
  margin: 0 0 0.45rem;
}

.filter-bar {
  display: grid;
  gap: 0.75rem;
  margin: 0.8rem 0 1rem;
}

.filter-bar label,
.stack-label {
  display: grid;
  gap: 0.3rem;
  color: var(--gold-bright);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

input[type="search"],
select {
  width: 100%;
  min-height: 2.75rem;
  padding: 0.5rem 0.65rem;
  border: 1px solid rgba(201, 162, 74, 0.5);
  background: var(--bg-elev);
  color: var(--text);
  border-radius: 0;
  font: inherit;
  letter-spacing: 0;
  text-transform: none;
  font-weight: 400;
  font-size: 1rem;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0.4rem 0 1rem;
}

.chip {
  min-height: 2.75rem;
  padding: 0.35rem 0.8rem;
  border: 1px solid rgba(201, 162, 74, 0.5);
  background: transparent;
  color: var(--text);
  font: inherit;
  cursor: pointer;
}

.chip[aria-pressed="true"] {
  background: var(--gold-bright);
  border-color: var(--gold-bright);
  color: #0b0b0c;
  font-weight: 600;
}

.timeline,
.mini-timeline,
.plain-list,
.legend,
.source-list,
.price-trail {
  margin: 0.4rem 0 0.8rem;
  padding: 0;
}

.timeline,
.mini-timeline {
  list-style: none;
  border-left: 1px solid var(--line);
}

.timeline > li,
.mini-timeline > li {
  position: relative;
  padding: 0 0 1.15rem 1rem;
}

.timeline > li::before,
.mini-timeline > li::before {
  content: "";
  position: absolute;
  left: -4px;
  top: 0.45rem;
  width: 7px;
  height: 7px;
  background: var(--gold-bright);
}

.source-list,
.plain-list,
.price-trail {
  padding-left: 1.15rem;
}

.source-list li,
.plain-list li,
.price-trail li {
  margin: 0.28rem 0;
}

.matter,
.conflict {
  padding: 1.15rem 0 1.3rem;
  border-top: 1px solid var(--line);
}

.motif {
  display: grid;
  place-items: center;
  height: 6.25rem;
  margin: -1rem -1.05rem 0.85rem;
  background:
    linear-gradient(180deg, rgba(201, 162, 74, 0.08), transparent 75%),
    #0e0e10;
  border-bottom: 1px solid var(--line);
}

.motif svg {
  width: 68%;
  height: 4.4rem;
}

.trail-token {
  display: block;
  font-size: 1.35rem;
  margin-bottom: 0.15rem;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
}

.data-table caption {
  display: block;
  text-align: left;
  font-family: var(--serif);
  font-size: 1.35rem;
  font-weight: 600;
  margin: 0.4rem 0 0.7rem;
}

.data-table thead {
  display: none;
}

.data-table,
.data-table tbody,
.data-table tr,
.data-table td {
  display: block;
}

.data-table tr {
  background: var(--bg-elev);
  border: 1px solid var(--line);
  margin: 0 0 0.85rem;
  padding: 0.7rem 0.85rem;
}

.data-table td {
  padding: 0.38rem 0;
  border: 0;
}

.cell-label {
  display: block;
  margin-bottom: 0.12rem;
}

.chart {
  margin: 0.6rem 0 1rem;
}

.bar-row {
  margin: 0 0 1rem;
}

.bar-name {
  margin: 0 0 0.25rem;
}

.bar-track {
  height: 0.7rem;
  background: #1c1c1f;
  margin: 0.2rem 0;
}

.bar-fill {
  height: 100%;
  background: var(--gold-bright);
}

.bar-fill.alt {
  height: 0.55rem;
  background: repeating-linear-gradient(
    -45deg,
    #d7c4a1,
    #d7c4a1 4px,
    #8a7352 4px,
    #8a7352 8px
  );
}

.legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 1rem;
  list-style: none;
}

.legend li {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.swatch {
  width: 0.95rem;
  height: 0.95rem;
  flex: 0 0 auto;
  background: var(--gold-bright);
}

.swatch-after {
  background: repeating-linear-gradient(-45deg, #d7c4a1, #d7c4a1 3px, #8a7352 3px, #8a7352 6px);
}

.donut-layout {
  display: grid;
  gap: 1rem;
  align-items: center;
}

.donut-svg {
  width: min(100%, 220px);
  height: auto;
}

.range-wrap {
  padding: 0.2rem 0 0.4rem;
}

.range-track {
  position: relative;
  height: 2px;
  margin: 6.2rem 0.35rem 6.2rem;
  background: linear-gradient(90deg, #8a7030, var(--gold-bright));
}

.range-marker {
  position: absolute;
  top: 0;
  width: 0.75rem;
  height: 0.75rem;
  border: 2px solid var(--gold-bright);
  background: var(--bg);
  transform: translate(-50%, -50%);
}

.range-label {
  position: absolute;
  width: 10.5rem;
  font-size: 0.8rem;
  line-height: 1.35;
  font-weight: 400;
  letter-spacing: 0;
  text-transform: none;
  color: var(--text);
}

.range-marker[data-slot="0"] .range-label {
  bottom: 0.95rem;
}

.range-marker[data-slot="1"] .range-label {
  top: 0.95rem;
}

.range-marker[data-edge="start"] .range-label {
  left: 0;
}

.range-marker[data-edge="end"] .range-label {
  right: 0;
  text-align: right;
}

.range-marker[data-edge="mid"] .range-label {
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
}

.countdown-num {
  margin: 0.2rem 0;
  font-size: clamp(3rem, 8vw, 4.6rem);
  color: var(--focus);
}

.disclaimer {
  border-left: 2px solid var(--gold-bright);
  margin: 0 0 1rem;
  padding: 0.1rem 0 0.1rem 0.9rem;
  max-width: 48rem;
}

.alert {
  border: 1px solid #e7b2a8;
  background: #2a1c1e;
  padding: 0.9rem 1rem;
}

/* Keep the footer below the first viewport until the dataset is painted,
   so injecting the record does not shift a visible footer. */
body:not(.is-ready) main {
  min-height: 100vh;
}

.site-footer {
  border-top: 1px solid var(--line);
  margin-top: 2.5rem;
  padding: 1.3rem 0 2.4rem;
  color: var(--muted);
}

.site-footer p {
  max-width: 48rem;
}

.type-jump {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 0.8rem;
  margin: 0.4rem 0 1rem;
  padding: 0;
  list-style: none;
}

.type-jump a {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
}

@media (min-width: 700px) {
  .facts {
    grid-template-columns: 11rem minmax(0, 1fr);
  }

  .facts dd {
    margin-bottom: 0.2rem;
  }

  .stat-grid,
  .teaser-grid,
  .card-grid,
  .countdown-grid,
  .sides,
  .donut-layout {
    grid-template-columns: 1fr 1fr;
  }

  .card-grid.cols-3 {
    grid-template-columns: 1fr 1fr;
  }
}

@media (min-width: 900px) {
  .hero-grid {
    grid-template-columns: minmax(0, 1.55fr) minmax(0, 0.55fr);
    align-items: center;
  }

  .hero-art {
    justify-self: end;
  }

  .filter-bar.cases {
    grid-template-columns: 1.4fr 0.7fr 0.9fr 0.9fr;
    align-items: end;
  }

  .card-grid.cols-3 {
    grid-template-columns: 1fr 1fr 1fr;
  }
}

@media (min-width: 1100px) {
  .data-table {
    display: table;
    table-layout: fixed;
    width: 100%;
  }

  .data-table caption {
    display: table-caption;
  }

  .data-table thead {
    display: table-header-group;
  }

  .data-table tbody {
    display: table-row-group;
  }

  .data-table tr {
    display: table-row;
    background: transparent;
    border: 0;
    margin: 0;
    padding: 0;
  }

  .data-table th,
  .data-table td {
    display: table-cell;
    text-align: left;
    vertical-align: top;
    padding: 0.7rem 0.55rem;
    border-bottom: 1px solid rgba(201, 162, 74, 0.22);
  }

  .data-table th {
    color: var(--gold-bright);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
  }

  .cell-label {
    display: none;
  }
}

@media (max-width: 860px) {
  .nav-toggle {
    display: inline-flex;
  }

  .wordmark {
    font-size: 1.2rem;
  }

  .site-nav {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 35;
    width: min(22rem, 100%);
    padding: calc(var(--header-h) + 0.5rem) 1.15rem 2rem;
    background: #111113;
    border-left: 1px solid var(--line);
    overflow: auto;
    transform: translateX(100%);
    visibility: hidden;
  }

  .site-nav[data-open="true"] {
    transform: none;
    visibility: visible;
  }

  .site-nav ul {
    flex-direction: column;
    align-items: stretch;
  }

  .site-nav a {
    font-family: var(--serif);
    font-size: 1.55rem;
    border-bottom: 1px solid var(--line);
  }
}

@media (max-width: 380px) {
  .wordmark {
    font-size: 1.05rem;
  }

  .mark {
    width: 1.55rem;
    height: 1.55rem;
  }
}

@media (prefers-reduced-motion: no-preference) {
  .site-nav,
  .bars span,
  .teaser,
  .stat-card,
  .info-card {
    transition: transform 180ms ease, border-color 160ms ease, opacity 160ms ease;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}

body.nav-open {
  overflow: hidden;
}

body.nav-open .bars span:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

body.nav-open .bars span:nth-child(2) {
  opacity: 0;
}

body.nav-open .bars span:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

::selection {
  background: var(--gold);
  color: var(--bg);
}
