:root {
  color-scheme: light;
  --site-nav-height: 54px;
  --sidebar-width: 420px;
  --bg: #f3f1eb;
  --ink: #1e2326;
  --muted: #657078;
  --line: #d7d4ca;
  --panel: #ffffff;
  --panel-2: #f9f8f4;
  --accent: #277a68;
  --accent-2: #bf4b3f;
  --accent-3: #365f91;
  --shadow: 0 16px 36px rgba(42, 42, 35, 0.12);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  height: 100vh;
  background: var(--bg);
  color: var(--ink);
  overflow: hidden;
}

body.resizing-sidebar {
  cursor: col-resize;
  user-select: none;
}

[hidden] {
  display: none !important;
}

.site-nav {
  position: relative;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  height: var(--site-nav-height);
  border-bottom: 1px solid var(--line);
  background: #fbfaf6;
  padding: 0 18px;
}

.site-title {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
  font-size: 14px;
  font-weight: 850;
}

.site-title-mark {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 6px;
  background: var(--ink);
  color: white;
  font-size: 12px;
  font-weight: 850;
}

.site-credit {
  margin-left: auto;
  color: #4f5a60;
  text-decoration: none;
  font-size: 11px;
  font-weight: 750;
  white-space: nowrap;
}

.site-credit span {
  color: var(--muted);
  font-weight: 600;
}

.site-credit:hover {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.primary-view-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f0eee8;
  padding: 3px;
}

.primary-view-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-width: 112px;
  height: 34px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #4f5a60;
  padding: 0 12px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 850;
}

.primary-view-tab svg {
  width: 16px;
  height: 16px;
}

.primary-view-tab.active {
  background: white;
  color: var(--ink);
  box-shadow: 0 1px 4px rgba(42, 42, 35, 0.14);
}

button,
input,
select {
  font: inherit;
}

.app {
  display: grid;
  grid-template-columns: minmax(360px, var(--sidebar-width)) 8px minmax(0, 1fr);
  height: calc(100vh - var(--site-nav-height));
  overflow: hidden;
}

.sidebar {
  border-right: 1px solid var(--line);
  background: #fbfaf6;
  padding: 14px;
  overflow-y: auto;
  overflow-x: hidden;
  min-width: 0;
  height: calc(100vh - var(--site-nav-height));
}

.sidebar-resize {
  position: relative;
  width: 8px;
  background: linear-gradient(90deg, #eeeae0, #d9d5ca);
  cursor: col-resize;
  touch-action: none;
}

.sidebar-resize::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 3px;
  width: 2px;
  height: 54px;
  border-radius: 999px;
  background: #a8a298;
  transform: translateY(-50%);
}

.sidebar-resize:hover,
.sidebar-resize:focus-visible {
  background: linear-gradient(90deg, #e4ded1, #c7c1b5);
}

.brand {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-bottom: 14px;
}

.mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 8px;
  background: var(--ink);
  color: white;
  font-size: 21px;
  font-weight: 800;
  letter-spacing: 0;
}

.mark.text-mark {
  font-size: 15px;
}

h1 {
  margin: 0;
  font-size: 18px;
  line-height: 1.1;
}

p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.control-block,
.source-block {
  padding: 10px 0;
  border-top: 1px solid var(--line);
}

.control-block label {
  display: grid;
  gap: 6px;
  color: #30383c;
  font-size: 12px;
  font-weight: 700;
}

select,
input {
  width: 100%;
  height: 32px;
  border: 1px solid #c9c6bc;
  border-radius: 6px;
  background: white;
  color: var(--ink);
  padding: 0 10px;
}

select:focus,
input:focus,
button:focus-visible {
  outline: 2px solid rgba(39, 122, 104, 0.35);
  outline-offset: 2px;
}

.field-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 8px;
}

.wide-label {
  margin-top: 10px;
}

.toggle {
  grid-template-columns: auto 1fr;
  align-items: center;
  margin-top: 12px;
  gap: 9px !important;
}

.toggle input {
  width: 18px;
  height: 18px;
}

.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  color: #30383c;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.icon-button,
.text-button,
.tab {
  border: 1px solid var(--line);
  background: white;
  color: var(--ink);
  cursor: pointer;
}

.icon-button {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 7px;
  padding: 0;
}

.icon-button svg,
.text-button svg {
  width: 17px;
  height: 17px;
}

.checkpoint-list {
  display: grid;
  gap: 8px;
  min-height: 0;
}

.checkpoint-block {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  max-height: min(48vh, 520px);
}

.checkpoint-block .checkpoint-list {
  overflow-y: auto;
  overflow-x: hidden;
  padding-right: 4px;
  min-height: 96px;
}

.checkpoint {
  display: grid;
  grid-template-columns: repeat(5, minmax(58px, 1fr)) 30px;
  gap: 6px;
  align-items: end;
}

.checkpoint label {
  gap: 4px;
  font-size: 10px;
}

.checkpoint input {
  height: 30px;
  padding: 0 6px;
}

.checkpoint-actions {
  display: grid;
  grid-template-columns: 30px;
  gap: 3px;
}

.checkpoint-actions .icon-button {
  width: 30px;
  height: 30px;
}

.checkpoint-actions .icon-button svg {
  width: 14px;
  height: 14px;
}

.scenario-block {
  display: grid;
  gap: 10px;
}

.scenario-group {
  display: grid;
  gap: 6px;
}

.scenario-group > span {
  color: #30383c;
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.scenario-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}

.scenario-grid .text-button {
  justify-content: center;
  min-width: 0;
  padding: 0 6px;
  line-height: 1.05;
  white-space: normal;
}

.scenario-grid .text-button.active {
  border-color: var(--accent);
  background: #e5f2ec;
  color: #174b3f;
}

.panel-toggles {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 6px;
  width: 100%;
  max-width: 100%;
}

.panel-toggle {
  display: grid;
  grid-template-columns: 16px minmax(0, 1fr);
  align-items: center;
  gap: 6px;
  min-height: 32px;
  border: 1px solid #c9c6bc;
  border-radius: 6px;
  background: white;
  padding: 6px 8px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.15;
  width: 100%;
  max-width: 100%;
}

.panel-toggle input {
  width: 16px;
  height: 16px;
  margin: 0;
}

.panel-toggle span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.workspace {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  height: calc(100vh - var(--site-nav-height));
  min-width: 0;
  overflow: auto;
}

.workspace-toolbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  border-bottom: 1px solid var(--line);
  background: rgba(243, 241, 235, 0.95);
  padding: 8px 16px;
  backdrop-filter: blur(6px);
}

.mode-row,
.action-grid {
  display: flex;
  align-items: center;
  gap: 6px;
}

.mode-row {
  margin-bottom: 8px;
}

.action-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin-bottom: 10px;
}

.tab {
  flex: 1;
  height: 32px;
  min-width: 0;
  border-radius: 7px;
  padding: 0 6px;
  font-size: 12px;
  font-weight: 800;
}

.tab.active,
.text-button.active {
  border-color: var(--accent);
  background: var(--accent);
  color: white;
}

.text-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 32px;
  border-radius: 7px;
  padding: 0 9px;
  font-size: 12px;
  font-weight: 800;
}

.text-button.primary {
  border-color: var(--ink);
}

.text-button.dirty {
  border-color: var(--accent-2);
  color: var(--accent-2);
}

.dashboard {
  position: relative;
  min-width: 0;
  min-height: calc(100vh - var(--site-nav-height) - 28px);
  padding-bottom: 18px;
}

.panel {
  position: absolute;
  display: grid;
  grid-template-rows: 43px minmax(0, 1fr);
  min-width: 260px;
  min-height: 172px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
  overflow: hidden;
  touch-action: none;
}

.panel:has(.panel-controls) {
  grid-template-rows: 43px auto minmax(0, 1fr);
}

.panel:has(.color-key:not([hidden])) {
  grid-template-rows: 43px auto auto minmax(0, 1fr);
}

.panel header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
  border-bottom: 1px solid var(--line);
  background: var(--panel-2);
  padding: 0 10px 0 14px;
  cursor: move;
}

.panel header span {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 13px;
  font-weight: 850;
}

.panel.collapsed {
  height: 43px !important;
  min-height: 43px;
}

.panel.collapsed .chart {
  display: none;
}

.panel.collapsed .panel-controls {
  display: none;
}

.panel-controls {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  align-items: end;
  border-bottom: 1px solid var(--line);
  background: #fffdf8;
  padding: 8px 10px;
}

.panel-controls label {
  display: grid;
  gap: 4px;
  min-width: 0;
  color: #30383c;
  font-size: 11px;
  font-weight: 800;
}

.panel-controls input,
.panel-controls select {
  height: 30px;
  min-width: 0;
}

.mortality-controls {
  grid-template-columns: minmax(78px, 0.75fr) minmax(76px, 0.75fr) auto minmax(0, 2fr);
}

.percentile-controls {
  grid-template-columns: minmax(100px, 1fr) auto;
}

.panel[data-panel="pyramid"] .panel-controls,
.panel[data-panel="feelPyramid"] .panel-controls {
  grid-template-columns: minmax(86px, 1fr) minmax(86px, 1fr) auto;
}

.compact-controls {
  display: flex;
  justify-content: flex-end;
  padding: 5px 10px;
}

.multi-controls {
  gap: 8px;
  align-items: center;
}

.panel-toggle-inline {
  display: inline-flex !important;
  grid-template-columns: none !important;
  align-items: center;
  gap: 6px !important;
  font-size: 11px !important;
  line-height: 1;
  white-space: nowrap;
}

.panel-toggle-inline input {
  width: 14px;
  height: 14px;
  margin: 0;
}

.mini-button {
  height: 28px;
  min-width: max-content;
  padding: 0 7px;
  font-size: 11px;
}

.dynamic-age-button {
  align-self: end;
}

.color-key {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
  gap: 5px 8px;
  border-bottom: 1px solid var(--line);
  background: #fffdf8;
  padding: 7px 10px;
}

.color-key[hidden] {
  display: none;
}

.key-item {
  display: inline-flex;
  align-items: center;
  min-width: 0;
  gap: 5px;
  color: #30383c;
  font-size: 10px;
  font-weight: 800;
}

.key-swatch {
  width: 18px;
  height: 7px;
  flex: 0 0 18px;
  border: 1px solid rgba(0, 0, 0, 0.45);
  border-radius: 999px;
}

.curve-list {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  align-items: center;
  min-width: 0;
}

.curve-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 26px;
  border: 1px solid #c9c6bc;
  border-radius: 6px;
  background: white;
  padding: 3px 6px;
  font-size: 11px;
  font-weight: 800;
}

.curve-chip button {
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  border: 0;
  background: transparent;
  cursor: pointer;
  padding: 0;
}

.chart {
  width: 100%;
  height: 100%;
  min-height: 0;
}

.source-block p {
  margin: 0;
}

.explanation-view {
  height: calc(100vh - var(--site-nav-height));
  overflow-y: auto;
  overflow-x: hidden;
  background: #ffffff;
  scroll-behavior: smooth;
}

.explanation-shell {
  display: grid;
  grid-template-columns: 236px minmax(0, 1fr);
  min-height: 100%;
}

.guide-nav {
  min-width: 0;
  border-right: 1px solid var(--line);
  background: #f5f6f3;
}

.guide-nav-inner {
  position: sticky;
  top: 0;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  gap: 16px;
  height: calc(100vh - var(--site-nav-height));
  overflow-y: auto;
  padding: 28px 18px 20px;
}

.guide-nav-label,
.guide-eyebrow {
  margin: 0;
  color: var(--accent);
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0;
  text-transform: uppercase;
}

.guide-nav-links {
  display: grid;
  align-content: start;
  gap: 2px;
}

.guide-nav-links a {
  border-left: 2px solid transparent;
  color: #4f5a60;
  padding: 7px 9px;
  text-decoration: none;
  font-size: 12px;
  font-weight: 750;
  line-height: 1.25;
}

.guide-nav-links a:hover,
.guide-nav-links a:focus-visible,
.guide-nav-links a.active {
  border-left-color: var(--accent);
  background: #e5f2ec;
  color: #174b3f;
}

.guide-open-simulator {
  justify-content: center;
  width: 100%;
}

.guide-article {
  width: min(100%, 1050px);
  min-width: 0;
  margin: 0 auto;
  padding: 58px 68px 100px;
}

.guide-article h1,
.guide-article h2,
.guide-article h3 {
  color: var(--ink);
  letter-spacing: 0;
}

.guide-article h1 {
  max-width: 760px;
  margin: 12px 0 18px;
  font-size: 42px;
  line-height: 1.08;
  font-weight: 850;
}

.guide-article h2 {
  margin: 8px 0 18px;
  font-size: 28px;
  line-height: 1.16;
  font-weight: 850;
}

.guide-article h3 {
  margin: 0 0 8px;
  font-size: 17px;
  line-height: 1.25;
  font-weight: 850;
}

.guide-article p,
.guide-article li,
.guide-article dd,
.guide-article td,
.guide-article th {
  color: #3f494f;
  font-size: 15px;
  line-height: 1.68;
}

.guide-article p {
  margin: 0 0 15px;
}

.guide-hero {
  padding-bottom: 44px;
}

.guide-deck {
  max-width: 820px;
  color: #30383c !important;
  font-size: 19px !important;
  line-height: 1.55 !important;
}

.guide-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 34px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.guide-summary > div {
  min-width: 0;
  padding: 18px 18px 16px;
}

.guide-summary > div + div {
  border-left: 1px solid var(--line);
}

.guide-summary span {
  display: block;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.guide-summary strong {
  display: block;
  margin-bottom: 6px;
  color: var(--ink);
  font-size: 18px;
}

.guide-summary p {
  margin: 0;
  font-size: 12px;
  line-height: 1.45;
}

.guide-section {
  scroll-margin-top: 24px;
  border-top: 1px solid var(--line);
  padding: 52px 0 54px;
}

.guide-section > p {
  max-width: 850px;
}

.guide-callout,
.guide-note {
  max-width: 850px;
  margin: 26px 0;
  border-left: 4px solid var(--accent);
  background: #eef7f2;
  padding: 17px 20px;
}

.guide-callout strong,
.guide-note strong {
  color: #174b3f;
  font-size: 15px;
}

.guide-callout p,
.guide-note p {
  margin: 5px 0 0;
  color: #34564d;
  font-size: 13px;
  line-height: 1.55;
}

.caution-note {
  border-left-color: #bf4b3f;
  background: #fff2ef;
}

.caution-note strong,
.caution-note p {
  color: #76342d;
}

.final-callout {
  margin-top: 34px;
}

.model-equation {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
  margin: 30px 0 0;
  border-radius: 8px;
  background: var(--ink);
  color: white;
  padding: 19px 22px;
  font-size: 14px;
  font-weight: 750;
}

.model-equation b {
  color: #8ed1bf;
  font-size: 18px;
}

.guide-steps,
.limits-list {
  max-width: 860px;
  margin: 22px 0 30px;
  padding-left: 24px;
}

.guide-steps li,
.limits-list li {
  margin-bottom: 14px;
  padding-left: 5px;
}

.guide-steps strong,
.limits-list strong {
  color: #30383c;
}

.table-wrap,
.question-table-wrap {
  width: 100%;
  margin: 28px 0 8px;
  overflow-x: auto;
}

.guide-table {
  width: 100%;
  min-width: 700px;
  border-collapse: collapse;
  text-align: left;
}

.guide-table th {
  border-top: 2px solid var(--ink);
  border-bottom: 1px solid var(--ink);
  color: var(--ink);
  padding: 10px 12px;
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.guide-table td {
  border-bottom: 1px solid #e4e2dc;
  padding: 11px 12px;
  vertical-align: top;
  font-size: 13px;
  line-height: 1.45;
}

.guide-table td:first-child {
  color: #30383c;
  font-weight: 800;
}

.compact-table td:first-child {
  width: 18%;
}

.panel-guide-table td:first-child {
  width: 20%;
}

.history-band {
  display: grid;
  grid-template-columns: 1.05fr 1fr 1.05fr;
  margin: 28px 0 30px;
  border-bottom: 1px solid var(--line);
}

.history-era {
  min-width: 0;
  border-top: 5px solid var(--accent-3);
  padding: 16px 18px 19px;
}

.history-era + .history-era {
  border-left: 1px solid var(--line);
}

.history-era.observed {
  border-top-color: var(--accent);
}

.history-era.simulated {
  border-top-color: var(--accent-2);
}

.history-era strong,
.history-era span {
  display: block;
}

.history-era strong {
  margin-bottom: 7px;
  color: var(--ink);
  font-size: 14px;
}

.history-era span {
  color: #566168;
  font-size: 12px;
  line-height: 1.5;
}

.decision-list,
.glossary-list {
  max-width: 880px;
  margin: 25px 0;
}

.decision-list > div,
.glossary-list > div {
  display: grid;
  grid-template-columns: 170px minmax(0, 1fr);
  gap: 22px;
  border-top: 1px solid #e4e2dc;
  padding: 13px 0;
}

.decision-list > div:last-child,
.glossary-list > div:last-child {
  border-bottom: 1px solid #e4e2dc;
}

.decision-list dt,
.glossary-list dt {
  color: #30383c;
  font-size: 13px;
  font-weight: 850;
}

.decision-list dd,
.glossary-list dd {
  margin: 0;
  font-size: 13px;
  line-height: 1.55;
}

.small-list > div {
  grid-template-columns: 130px minmax(0, 1fr);
}

.engine-steps {
  display: grid;
  gap: 0;
  max-width: 870px;
  margin: 28px 0 30px;
  padding: 0;
  list-style: none;
}

.engine-steps li {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 15px;
  border-top: 1px solid #e4e2dc;
  padding: 14px 0;
}

.engine-steps li:last-child {
  border-bottom: 1px solid #e4e2dc;
}

.engine-steps li > span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--ink);
  color: white;
  font-size: 12px;
  font-weight: 850;
}

.engine-steps strong {
  color: #30383c;
  font-size: 14px;
}

.engine-steps p {
  margin: 3px 0 0;
  font-size: 13px;
  line-height: 1.5;
}

.guide-details {
  max-width: 850px;
  margin: 28px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.guide-details summary {
  padding: 14px 2px;
  color: #30383c;
  cursor: pointer;
  font-size: 13px;
  font-weight: 850;
}

.guide-details > div {
  padding: 0 2px 13px;
}

.guide-details p {
  font-size: 13px;
  line-height: 1.55;
}

.mortality-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  max-width: 850px;
  margin: 27px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.mortality-pair > div {
  padding: 17px 19px;
}

.mortality-pair > div + div {
  border-left: 1px solid var(--line);
}

.mortality-pair strong {
  color: var(--ink);
  font-size: 14px;
}

.mortality-pair p {
  margin: 5px 0 0;
  font-size: 13px;
  line-height: 1.5;
}

.concept-block {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  gap: 18px;
  max-width: 880px;
  border-top: 1px solid var(--line);
  padding: 28px 0 24px;
}

.concept-number {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 1px solid var(--accent);
  border-radius: 50%;
  color: var(--accent);
  font-size: 12px;
  font-weight: 850;
}

.concept-equation {
  margin: 18px 0;
  border-left: 3px solid var(--accent-3);
  background: #eef3f9;
  color: #294d76;
  padding: 13px 16px;
  font-size: 14px;
  font-weight: 850;
}

.concept-limit {
  color: #6c3b36 !important;
  font-size: 13px !important;
}

.source-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px;
  margin: 30px 0;
}

.source-grid > div {
  border-top: 3px solid var(--ink);
  padding-top: 14px;
}

.source-grid h3 {
  margin-bottom: 12px;
  font-size: 14px;
}

.source-grid a {
  display: block;
  border-top: 1px solid #e4e2dc;
  color: #2d5f91;
  padding: 8px 0;
  text-decoration: none;
  font-size: 12px;
  font-weight: 750;
  line-height: 1.35;
}

.source-grid a:last-child {
  border-bottom: 1px solid #e4e2dc;
}

.source-grid a:hover,
.source-grid a:focus-visible {
  color: #163f68;
  text-decoration: underline;
}

.source-footnote {
  color: var(--muted) !important;
  font-size: 12px !important;
  line-height: 1.55 !important;
}

.glossary-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 30px;
  max-width: none;
}

.glossary-list > div {
  display: block;
}

.glossary-list dt {
  margin-bottom: 4px;
}

.guide-footer-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 34px;
}

.guide-footer-actions a {
  text-decoration: none;
}

.guide-attribution {
  margin: 30px 0 0;
  border-top: 1px solid var(--line);
  padding-top: 18px;
  color: var(--muted);
  font-size: 12px;
}

.guide-attribution a {
  color: var(--ink);
  font-weight: 800;
  text-decoration-color: rgba(39, 122, 104, 0.45);
  text-underline-offset: 3px;
}

@media (max-width: 980px) {
  body {
    height: auto;
    overflow: auto;
  }

  .site-nav {
    position: sticky;
    top: 0;
  }

  .app {
    grid-template-columns: 1fr;
    height: auto;
    overflow: visible;
  }

  .sidebar {
    border-right: 0;
    border-bottom: 1px solid var(--line);
    height: auto;
    max-height: none;
  }

  .sidebar-resize {
    display: none;
  }

  .checkpoint-block {
    max-height: none;
  }

  .dashboard {
    min-width: 0;
  }

  .workspace {
    height: auto;
    overflow: visible;
  }

  .workspace-toolbar {
    position: static;
  }

  .explanation-view {
    height: auto;
    min-height: calc(100vh - var(--site-nav-height));
    overflow: visible;
  }

  .explanation-shell {
    grid-template-columns: 1fr;
  }

  .guide-nav {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .guide-nav-inner {
    position: static;
    display: block;
    height: auto;
    overflow: visible;
    padding: 18px 24px;
  }

  .guide-nav-links {
    display: flex;
    flex-wrap: wrap;
    gap: 2px 6px;
    margin-top: 8px;
  }

  .guide-nav-links a {
    border-left: 0;
    border-bottom: 2px solid transparent;
    padding: 6px 4px;
  }

  .guide-nav-links a:hover,
  .guide-nav-links a:focus-visible,
  .guide-nav-links a.active {
    border-left-color: transparent;
    border-bottom-color: var(--accent);
  }

  .guide-open-simulator {
    width: auto;
    margin-top: 12px;
  }

  .guide-article {
    padding: 48px 34px 80px;
  }
}

@media (max-width: 700px) {
  .site-nav {
    padding: 0 10px;
  }

  .site-title > span:last-child {
    display: none;
  }

  .site-credit {
    display: none;
  }

  .primary-view-tab {
    min-width: 0;
    padding: 0 10px;
  }

  .guide-article {
    padding: 38px 17px 70px;
  }

  .guide-article h1 {
    font-size: 34px;
  }

  .guide-article h2 {
    font-size: 24px;
  }

  .guide-deck {
    font-size: 17px !important;
  }

  .guide-summary,
  .history-band,
  .mortality-pair,
  .source-grid,
  .glossary-list {
    grid-template-columns: 1fr;
  }

  .guide-summary > div + div,
  .history-era + .history-era,
  .mortality-pair > div + div {
    border-left: 0;
    border-top: 1px solid var(--line);
  }

  .history-era + .history-era {
    border-top-width: 5px;
  }

  .decision-list > div,
  .glossary-list > div {
    grid-template-columns: 1fr;
    gap: 5px;
  }

  .concept-block {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .model-equation {
    display: grid;
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .model-equation b {
    line-height: 1;
  }
}
