:root {
  --ink: #171714;
  --paper: #f3efe5;
  --paper-deep: #e7dfce;
  --red: #c93427;
  --red-dark: #8f211a;
  --blue: #164b65;
  --muted: #716c62;
  --rule: #c9c0ad;
  --white: #fffdf8;
  --shadow: 0 18px 50px rgba(55, 44, 27, .12);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(rgba(91, 74, 48, .035) 1px, transparent 1px),
    var(--paper);
  background-size: 100% 6px;
  font-family: "Avenir Next", Avenir, "Gill Sans", sans-serif;
  line-height: 1.5;
}

.masthead {
  position: relative;
  overflow: hidden;
  min-height: 440px;
  padding: 54px max(6vw, 24px) 42px;
  color: var(--white);
  background: var(--ink);
  border-bottom: 9px solid var(--red);
}
.masthead::after {
  content: "10";
  position: absolute;
  right: 2vw;
  bottom: -132px;
  color: rgba(255, 255, 255, .055);
  font: 900 36rem/.8 Georgia, serif;
  letter-spacing: -.12em;
  pointer-events: none;
}
.edition, .section-kicker {
  color: var(--red);
  font-size: .76rem;
  font-weight: 800;
  letter-spacing: .19em;
  text-transform: uppercase;
}
.edition { color: #f06a58; }
h1 {
  position: relative;
  z-index: 1;
  max-width: 1000px;
  margin: 18px 0 10px;
  font: 700 clamp(4.3rem, 11vw, 9.4rem)/.77 Georgia, "Times New Roman", serif;
  letter-spacing: -.075em;
}
h1 em {
  color: #ffdf9e;
  font-weight: 400;
}
.dek {
  position: relative;
  z-index: 1;
  max-width: 630px;
  margin: 32px 0 34px;
  color: #d9d1c1;
  font: 1.15rem/1.55 Georgia, serif;
}
.mast-meta {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 28px;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .11em;
  text-transform: uppercase;
}

main { width: min(1180px, calc(100% - 36px)); margin: 0 auto; }
section {
  padding: 76px 0;
  border-bottom: 1px solid var(--rule);
}
h2 {
  margin: 7px 0 12px;
  font: 700 clamp(2.3rem, 5vw, 4.4rem)/.96 Georgia, serif;
  letter-spacing: -.045em;
}
.section-intro {
  max-width: 760px;
  margin: 0 0 28px;
  color: var(--muted);
  font-family: Georgia, serif;
  font-size: 1.05rem;
}

.control-panel {
  margin-top: -28px;
  padding: 48px clamp(20px, 4vw, 52px);
  background: var(--white);
  border: 1px solid var(--rule);
  border-top: 7px solid var(--red);
  box-shadow: var(--shadow);
}
.controls {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 38px;
}
.control {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 70px;
  gap: 4px 14px;
  align-items: center;
  padding: 17px 0 14px;
  border-top: 1px solid var(--rule);
}
.control label { font-weight: 750; }
.control small {
  display: block;
  color: var(--muted);
  font-size: .72rem;
  font-weight: 500;
}
.readout {
  grid-column: 2;
  grid-row: 1 / span 2;
  justify-self: end;
  min-width: 64px;
  padding: 7px 8px;
  color: var(--white);
  background: var(--ink);
  text-align: center;
  font: 700 .9rem Georgia, serif;
  font-variant-numeric: tabular-nums;
}
input[type="range"] {
  grid-column: 1 / -1;
  width: 100%;
  height: 22px;
  margin: 3px 0 0;
  accent-color: var(--red);
  cursor: ew-resize;
}
.assumption-summary {
  margin: 24px 0 0;
  padding: 15px 18px;
  color: var(--white);
  background: var(--blue);
  font-size: .83rem;
  font-weight: 650;
  letter-spacing: .01em;
}
.telemetry-bar {
  margin-top: 10px;
  padding: 10px 14px;
  color: var(--ink);
  background: #efe7d6;
  border: 1px solid var(--rule);
  font-size: .72rem;
  font-variant-numeric: tabular-nums;
  letter-spacing: .01em;
}
.telemetry-bar strong {
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--red-dark);
}
.status-pill {
  display: inline-block;
  margin-right: 12px;
  padding: 2px 8px;
  border: 1px solid rgba(255, 255, 255, .35);
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.status-pill[data-status="preview"] { background: rgba(255, 223, 158, .25); }
.status-pill[data-status="refining"] { background: rgba(255, 255, 255, .18); }
.status-pill[data-status="final"] { background: rgba(255, 255, 255, .28); }
.status-row {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  margin-top: 12px;
  color: var(--muted);
  font-size: .75rem;
}
#status { color: var(--red-dark); font-weight: 750; }

.table-shell {
  overflow-x: auto;
  background: var(--white);
  border: 1px solid var(--rule);
  box-shadow: 0 8px 24px rgba(55, 44, 27, .07);
}
table { width: 100%; border-collapse: collapse; font-size: .87rem; }
th {
  padding: 12px 14px;
  color: var(--white);
  background: var(--ink);
  font-size: .68rem;
  letter-spacing: .1em;
  text-align: right;
  text-transform: uppercase;
}
th:first-child, td:first-child { text-align: left; }
td {
  padding: 11px 14px;
  border-bottom: 1px solid #ded7c8;
  text-align: right;
  font-variant-numeric: tabular-nums;
}
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: #fff8e9; }
.player-name, .film-name { font-weight: 750; }
.rank-num { color: var(--muted); font-family: Georgia, serif; }
.prob-strong { color: var(--red-dark); font-weight: 800; }

.chart-card {
  overflow-x: auto;
  margin-top: 24px;
  padding: 20px;
  background: var(--white);
  border: 1px solid var(--rule);
  box-shadow: 0 8px 24px rgba(55, 44, 27, .07);
}
.chart-card svg { display: block; width: 100%; min-width: 720px; height: auto; }

.scenario-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.scenario-card {
  position: relative;
  padding: 24px;
  background: var(--white);
  border: 1px solid var(--rule);
}
.scenario-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 5px;
  background: var(--red);
}
.scenario-card h3 {
  margin: 0;
  font: 700 1.6rem Georgia, serif;
}
.scenario-meta {
  margin: 4px 0 16px;
  color: var(--muted);
  font-size: .73rem;
  font-weight: 700;
}
.scenario-card ol {
  margin: 0;
  padding-left: 27px;
  font-size: .79rem;
}
.scenario-card li { margin: 3px 0; padding-left: 3px; }

.warning {
  margin: 0 0 18px;
  padding: 14px 18px;
  color: #5d3513;
  background: #f8dfaa;
  border-left: 5px solid #c66b17;
  font-size: .82rem;
}
.warning strong { display: block; margin-bottom: 4px; }
.warning ul { margin: 5px 0 0; padding-left: 18px; }
.released-mark {
  display: inline-block;
  margin-left: 6px;
  color: var(--blue);
  font-size: .6rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}

footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 34px max(6vw, 24px);
  color: #bdb4a3;
  background: var(--ink);
  font-size: .72rem;
}
footer strong { color: var(--white); text-transform: uppercase; letter-spacing: .08em; }
.loading { padding: 30px 0; color: var(--muted); font-family: Georgia, serif; }
.error { color: var(--red-dark); font-weight: 700; }

@media (max-width: 820px) {
  .controls, .scenario-grid { grid-template-columns: 1fr; }
  .scenario-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .masthead { min-height: 380px; }
}
@media (max-width: 560px) {
  main { width: min(100% - 20px, 1180px); }
  section { padding: 54px 0; }
  .control-panel { padding: 36px 16px; }
  .scenario-grid { grid-template-columns: 1fr; }
  .status-row, footer { flex-direction: column; }
  .method-note { display: none; }
  h1 { font-size: 4rem; }
}

@media (prefers-reduced-motion: no-preference) {
  .masthead h1, .masthead .dek, .masthead .mast-meta {
    animation: reveal .65s both;
  }
  .masthead .dek { animation-delay: .08s; }
  .masthead .mast-meta { animation-delay: .16s; }
  @keyframes reveal {
    from { opacity: 0; transform: translateY(14px); }
    to { opacity: 1; transform: none; }
  }
}
