:root {
  --page-max: 1480px;
  --page-gutter: 32px;
  --header-space: 122px;
  --ink: #172233;
  --muted: #5d7087;
  --blue: #0866ff;
  --line: rgba(26, 44, 68, 0.1);
  --glass: rgba(255, 255, 255, 0.72);
  --glass-strong: rgba(255, 255, 255, 0.86);
  --glass-soft: rgba(247, 251, 255, 0.58);
  --shadow-lg: 0 24px 58px rgba(8, 44, 96, 0.1);
  --shadow-md: 0 14px 32px rgba(8, 44, 96, 0.075);
  --section-radius: 30px;
  --card-radius: 22px;
  --item-radius: 18px;
  --section-pad: 28px;
  --card-pad: 22px;
  --gap-page: 24px;
  --gap-section: 28px;
  --gap-card: 16px;
  --gap-item: 14px;
  --type-body: 1rem;
  --type-small: 1rem;
  --type-meta: 1rem;
  --type-lead: 1rem;
  --type-stat: 1.55rem;
  --type-h1: clamp(2.5rem, 4vw, 3.5rem);
  --type-h2: 1.5rem;
  --type-h3: 1.05rem;
}

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

html {
  scroll-behavior: smooth;
  overflow-y: scroll;
  scrollbar-gutter: stable;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  font-family: Calibri, "Microsoft JhengHei", "Noto Sans TC", sans-serif;
  font-size: var(--type-body);
  line-height: 1.7;
  background:
    radial-gradient(circle at 12% 10%, rgba(8, 102, 255, 0.13), transparent 28%),
    radial-gradient(circle at 86% 12%, rgba(0, 168, 132, 0.1), transparent 24%),
    linear-gradient(135deg, #eef5ff 0%, #f8fbff 42%, #edf7ff 100%);
}

html,
body {
  max-width: 100%;
  overflow-x: clip;
}

a {
  color: var(--blue);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

button,
input,
textarea,
select {
  font: inherit;
}

code,
pre {
  font-family: Consolas, "Courier New", monospace;
}

.site-stage {
  width: min(var(--page-max), calc(100% - var(--page-gutter)));
  min-height: 100vh;
  margin: 0 auto;
  padding: var(--header-space) 0 14px;
  display: flex;
  flex-direction: column;
}

.site-header {
  position: fixed;
  top: 18px;
  left: 50%;
  z-index: 1000;
  width: min(var(--page-max), calc(100% - var(--page-gutter)));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 16px 18px 16px 28px;
  border: 1px solid rgba(8, 102, 255, 0.16);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow:
    0 18px 44px rgba(8, 44, 96, 0.13),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
  transform: translateX(-50%);
  backdrop-filter: blur(14px) saturate(1.12);
  -webkit-backdrop-filter: blur(14px) saturate(1.12);
}

.brand-lockup {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  color: inherit;
}

.brand-lockup:hover {
  text-decoration: none;
}

.brand-mark {
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  width: 48px;
  height: 48px;
  border-radius: 16px;
  color: #fff;
  font-size: var(--type-meta);
  font-weight: 800;
  letter-spacing: 0.08em;
  background: linear-gradient(135deg, #1484ff 0%, #0866ff 58%, #0050d8 100%);
  box-shadow: 0 14px 28px rgba(8, 102, 255, 0.24);
}

.brand-text {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.brand-text strong {
  color: var(--ink);
  font-size: var(--type-h3);
  line-height: 1.1;
}

.brand-text span {
  color: var(--muted);
  font-size: var(--type-small);
  line-height: 1.25;
}

.menu-toggle {
  display: none;
  min-height: 40px;
  padding: 8px 12px;
  border: 1px solid rgba(8, 102, 255, 0.14);
  border-radius: 14px;
  color: #264566;
  background: #fff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.site-nav {
  --nav-active-offset: 0px;
  position: relative;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 7px;
  border: 1px solid rgba(8, 102, 255, 0.2);
  border-radius: 999px;
  background: linear-gradient(180deg, #eef5ff 0%, #e4efff 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.96),
    0 10px 24px rgba(8, 44, 96, 0.08);
}

.site-nav::before {
  content: "";
  position: absolute;
  z-index: 0;
  top: 7px;
  bottom: 7px;
  left: 7px;
  width: calc((100% - 22px) / 3);
  border-radius: 999px;
  background: linear-gradient(135deg, #1484ff 0%, #0866ff 54%, #0050d8 100%);
  box-shadow:
    0 14px 30px rgba(8, 102, 255, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.26);
  transform: translateX(var(--nav-active-offset));
  transition: transform 240ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.site-nav a {
  position: relative;
  z-index: 1;
  min-width: 118px;
  padding: 12px 22px;
  border-radius: 999px;
  color: #475f7a;
  font-weight: 800;
  text-align: center;
  transition: color 160ms ease, transform 160ms ease;
}

.site-nav a:hover {
  color: #22384f;
  text-decoration: none;
  transform: translateY(-1px);
}

.site-nav a.is-active,
.site-nav a.is-pending {
  color: #fff;
  text-shadow: 0 1px 8px rgba(0, 50, 140, 0.18);
}

.site-nav a.is-active:hover,
.site-nav a.is-pending:hover {
  color: #fff;
}

.page-main {
  display: flex;
  flex-direction: column;
  flex: 1 0 auto;
  gap: var(--gap-page);
  margin-top: var(--gap-page);
  transition: opacity 140ms ease, transform 140ms ease;
}

.page-main.is-switching {
  opacity: 0;
  transform: translateY(6px);
}

.page-main > .section-shell[hidden] {
  display: none !important;
}

.page-main > .section-shell:not([hidden]) {
  flex: 1 0 auto;
}

.section-shell {
  width: 100%;
  min-width: 0;
  scroll-margin-top: calc(var(--header-space) + 18px);
  display: grid;
  gap: var(--gap-section);
  padding: var(--section-pad);
  border: 1px solid rgba(8, 102, 255, 0.12);
  border-radius: var(--section-radius);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.76) 0%, rgba(247, 251, 255, 0.58) 100%);
  box-shadow:
    var(--shadow-lg),
    inset 0 1px 0 rgba(255, 255, 255, 0.82);
  overflow: hidden;
}

.card,
.download-detail,
.table-wrap,
.citation-block,
.figure-caption-text,
.scenario-legend,
.figure-image {
  border: 1px solid rgba(255, 255, 255, 0.7);
  background: linear-gradient(145deg, var(--glass-strong) 0%, var(--glass-soft) 100%);
  box-shadow:
    var(--shadow-md),
    inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.card {
  min-width: 0;
  max-width: 100%;
  padding: var(--card-pad);
  border-radius: var(--card-radius);
}

.section-heading,
.card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--gap-card);
}

.section-heading {
  margin-bottom: 6px;
}

h1,
h2,
h3 {
  margin: 0 0 16px;
  color: var(--ink);
  letter-spacing: 0;
}

h1 {
  position: relative;
  display: inline-block;
  padding-bottom: 18px;
  font-size: var(--type-h1);
  line-height: 1.04;
  font-weight: 900;
  text-shadow: 0 12px 28px rgba(8, 44, 96, 0.08);
}

h1::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: min(190px, 50%);
  height: 7px;
  border-radius: 999px;
  background:
    linear-gradient(90deg, var(--blue) 0%, #24b6ff 48%, #00a884 100%);
  box-shadow:
    0 12px 26px rgba(8, 102, 255, 0.2),
    0 0 0 4px rgba(8, 102, 255, 0.06);
}

h2 {
  font-size: var(--type-h2);
  line-height: 1.18;
  font-weight: 900;
}

h3 {
  font-size: var(--type-h3);
  line-height: 1.3;
  font-weight: 850;
}

.card > h2,
.card-header h2,
.table-subsection h3 {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 22px;
}

.card > h2::before,
.card-header h2::before,
.table-subsection h3::before {
  content: "";
  flex: 0 0 auto;
  width: 9px;
  height: 1.35em;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--blue), #00a884);
  box-shadow:
    0 10px 20px rgba(8, 102, 255, 0.18),
    0 0 0 4px rgba(8, 102, 255, 0.08);
}

.card > h2::after,
.card-header h2::after,
.table-subsection h3::after {
  content: "";
  flex: 1 1 auto;
  height: 1px;
  min-width: 32px;
  background: linear-gradient(90deg, rgba(8, 102, 255, 0.24), transparent);
}

.lead,
.card p,
.card li,
figcaption,
td {
  color: var(--muted);
}

.lead,
.card .lead {
  margin: 0;
  font-size: var(--type-lead);
  line-height: 1.68;
}

.hero-layout,
.overview-grid,
.download-layout,
.code-layout,
.results-layout {
  width: 100%;
  min-width: 0;
  display: grid;
  gap: var(--gap-section);
}

.overview-shell > .hero-layout,
.overview-grid,
.results-layout {
  grid-template-columns: 1fr;
}

.overview-shell .intro-card {
  display: grid;
  grid-template-columns: minmax(480px, 1.1fr) minmax(360px, 0.9fr);
  gap: 28px;
  align-items: stretch;
  min-width: 0;
  max-width: 100%;
}

.metrics-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  width: 100%;
  max-width: 620px;
  justify-self: end;
  min-width: 0;
}

.metric-card {
  --metric-from: #0665f2;
  --metric-to: #25b7ff;
  --metric-glow: rgba(22, 119, 255, 0.24);
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  grid-template-rows: auto auto auto;
  align-content: center;
  align-items: center;
  column-gap: 14px;
  row-gap: 4px;
  min-height: 104px;
  min-width: 0;
  padding: 16px 18px;
  border: 0;
  border-radius: 18px;
  background:
    radial-gradient(circle at 88% 16%, rgba(255, 255, 255, 0.18), transparent 28%),
    radial-gradient(circle at 100% 100%, rgba(255, 255, 255, 0.12), transparent 34%),
    linear-gradient(135deg, var(--metric-from) 0%, var(--metric-to) 100%);
  box-shadow:
    0 18px 34px var(--metric-glow),
    inset 0 1px 0 rgba(255, 255, 255, 0.28);
}

.metrics-grid .metric-card:nth-child(2) {
  --metric-from: #008d72;
  --metric-to: #27d493;
  --metric-glow: rgba(0, 168, 132, 0.22);
}

.metrics-grid .metric-card:nth-child(3) {
  --metric-from: #6041f1;
  --metric-to: #a85bf4;
  --metric-glow: rgba(124, 85, 255, 0.22);
}

.metrics-grid .metric-card:nth-child(4) {
  --metric-from: #e86100;
  --metric-to: #ff6758;
  --metric-glow: rgba(255, 112, 0, 0.22);
}

.metric-card::before {
  content: "";
  position: absolute;
  right: -30px;
  bottom: -42px;
  width: 128px;
  height: 128px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
}

.metric-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(5, 18, 42, 0.28) 0%, rgba(5, 18, 42, 0.14) 42%, transparent 74%),
    linear-gradient(115deg, transparent 0%, transparent 48%, rgba(255, 255, 255, 0.08) 58%, transparent 70%);
  pointer-events: none;
}

.metric-card strong,
.metric-card .metric-label,
.metric-card small,
.metric-icon {
  position: relative;
  z-index: 1;
}

.metric-card strong {
  grid-column: 2;
  margin: 0;
  color: #fff;
  font-size: var(--type-stat);
  line-height: 1;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.34);
}

.metric-card .metric-label {
  grid-column: 2;
  color: #fff;
  font-size: var(--type-small);
  font-weight: 900;
  line-height: 1.12;
  letter-spacing: 0;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.metric-card small {
  grid-column: 2;
  margin-top: 4px;
  color: rgba(255, 255, 255, 0.82);
  font-size: var(--type-meta);
  font-weight: 700;
  line-height: 1.28;
  overflow-wrap: anywhere;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.28);
}

.metric-icon {
  grid-column: 1;
  grid-row: 1 / span 3;
  align-self: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  color: rgba(255, 255, 255, 0.94);
  background: rgba(255, 255, 255, 0.18);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.24),
    0 10px 20px rgba(0, 0, 0, 0.08);
}

.metric-icon::before {
  content: "";
  position: absolute;
  inset: 10px;
  background: currentColor;
  -webkit-mask: var(--metric-icon-url) center / contain no-repeat;
  mask: var(--metric-icon-url) center / contain no-repeat;
  pointer-events: none;
}

.metric-icon-samples {
  --metric-icon-url: url("https://cdn.jsdelivr.net/npm/lucide-static@1.8.0/icons/images.svg");
}

.metric-icon-scenarios {
  --metric-icon-url: url("https://cdn.jsdelivr.net/npm/lucide-static@1.8.0/icons/grid-2x2.svg");
}

.metric-icon-protocols {
  --metric-icon-url: url("https://cdn.jsdelivr.net/npm/lucide-static@1.8.0/icons/list-checks.svg");
}

.metric-icon-maps {
  --metric-icon-url: url("https://cdn.jsdelivr.net/npm/lucide-static@1.8.0/icons/layers.svg");
}

.concept-panel {
  display: grid;
  align-content: center;
  gap: 20px;
  min-width: 0;
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, 0.64);
  border-radius: var(--card-radius);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.6) 0%, rgba(244, 250, 255, 0.38) 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.72),
    0 12px 28px rgba(8, 44, 96, 0.055);
}

.concept-panel .lead {
  max-width: 980px;
  color: #4f637b;
  overflow-wrap: anywhere;
}

.concept-list {
  display: grid;
  min-width: 0;
}

.concept-item {
  display: grid;
  grid-template-columns: 14px minmax(0, 1fr);
  gap: 14px;
  min-width: 0;
  padding: 16px 0;
  border-top: 1px solid rgba(8, 44, 96, 0.1);
}

.concept-item:first-child {
  padding-top: 0;
  border-top: 0;
}

.concept-item:last-child {
  padding-bottom: 0;
}

.concept-dot {
  width: 10px;
  height: 10px;
  margin-top: 8px;
  border-radius: 999px;
  background: #1677ff;
  box-shadow: 0 0 0 5px rgba(22, 119, 255, 0.12);
}

.concept-item:nth-child(2) .concept-dot {
  background: #00a884;
  box-shadow: 0 0 0 5px rgba(0, 168, 132, 0.12);
}

.concept-item:nth-child(3) .concept-dot {
  background: #7c6be8;
  box-shadow: 0 0 0 5px rgba(124, 107, 232, 0.12);
}

.concept-item strong {
  display: block;
  margin-bottom: 4px;
  color: var(--ink);
  line-height: 1.3;
}

.concept-item p {
  margin: 0;
  color: #60748a;
  font-size: var(--type-body);
  line-height: 1.62;
  overflow-wrap: anywhere;
}

.media-view {
  margin: 0;
}

.side-caption-figure {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
  gap: 24px;
  align-items: stretch;
}

.figure-image {
  display: block;
  width: 100%;
  max-width: 100%;
  max-height: 480px;
  padding: 12px;
  object-fit: contain;
  border-radius: var(--card-radius);
}

.media-card .figure-image {
  max-height: 380px;
}

.figure-side-copy {
  display: grid;
  gap: 14px;
  align-content: stretch;
  margin: 0;
}

.figure-caption-text {
  position: relative;
  min-height: 100%;
  margin: 0;
  padding: 24px;
  border-radius: var(--item-radius);
  color: var(--muted);
  font-size: var(--type-body);
  line-height: 1.72;
}

.scenario-legend {
  display: flex;
  flex-wrap: wrap;
  align-content: flex-start;
  gap: 10px;
  height: auto;
  margin: 0;
  padding: 16px;
  border-radius: var(--item-radius);
}

.scenario-legend div {
  display: inline-flex;
  flex: 1 1 220px;
  gap: 8px;
  align-items: center;
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid rgba(8, 102, 255, 0.1);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.58);
}

.scenario-legend dt,
.scenario-legend dd {
  margin: 0;
}

.scenario-legend dt {
  display: inline-grid;
  place-items: center;
  min-width: 62px;
  padding: 3px 8px;
  border-radius: 999px;
  color: #22384f;
  font-size: var(--type-meta);
  font-weight: 800;
  line-height: 1.2;
  background: rgba(8, 102, 255, 0.09);
}

.scenario-legend dd {
  color: var(--muted);
  font-size: var(--type-small);
  line-height: 1.35;
}

.table-card,
.results-table-card {
  padding: var(--card-pad);
}

.table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: var(--item-radius);
}

table {
  width: 100%;
  min-width: 860px;
  border-collapse: collapse;
}

th,
td {
  padding: 10px 9px;
  border-bottom: 1px solid rgba(26, 44, 68, 0.08);
  text-align: center;
  vertical-align: middle;
}

th {
  color: #22384f;
  font-size: var(--type-small);
  font-weight: 800;
  line-height: 1.35;
  background: rgba(232, 242, 255, 0.78);
}

td {
  font-size: var(--type-small);
  line-height: 1.45;
}

td:first-child,
tbody td[rowspan] {
  color: var(--ink);
  font-weight: 700;
}

tbody tr:nth-child(even) td,
.highlight-row td {
  background: rgba(255, 255, 255, 0.34);
}

.table-note {
  margin: 14px 0 0;
  color: var(--muted);
}

.table-subsection {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid rgba(26, 44, 68, 0.08);
}

.methods-list {
  margin: 0;
  padding-left: 18px;
}

.methods-list li + li {
  margin-top: 8px;
}

.citation-block {
  margin: 0;
  padding: 14px;
  overflow-x: auto;
  border-radius: var(--item-radius);
  color: #304256;
  font-size: var(--type-small);
  line-height: 1.45;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.download-layout {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: stretch;
}

.code-layout {
  grid-template-columns: minmax(0, 1fr);
}

.code-shell {
  align-content: start;
}

.code-card {
  display: grid;
  align-content: start;
  gap: 18px;
}

.code-action {
  align-self: start;
  justify-self: start;
}

.download-layout > .intro-card {
  grid-column: 1 / -1;
}

.access-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 18px;
}

.download-panel-card,
.download-materials,
.step-list {
  display: grid;
  gap: var(--gap-card);
}

.download-detail {
  padding: var(--card-pad);
  border-radius: var(--card-radius);
}

.download-detail strong {
  display: block;
  margin-bottom: 10px;
  color: var(--ink);
}

.download-detail p {
  margin: 0 0 10px;
}

.download-detail p:last-child {
  margin-bottom: 0;
}

.primary-action,
.secondary-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border-radius: 999px;
  font-weight: 800;
}

.primary-action {
  color: #fff;
  background: var(--blue);
  box-shadow: 0 12px 22px rgba(8, 102, 255, 0.16);
}

.primary-action:hover {
  color: #fff;
  background: #0758db;
  text-decoration: none;
}

.secondary-action {
  color: #0866ff;
  border: 1px solid rgba(8, 102, 255, 0.22);
  background: rgba(255, 255, 255, 0.78);
  box-shadow:
    0 12px 22px rgba(8, 102, 255, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.88);
}

.secondary-action:hover {
  color: #0758db;
  border-color: rgba(8, 102, 255, 0.36);
  background: #fff;
  text-decoration: none;
}

.download-action {
  width: fit-content;
  margin-top: 12px;
}

.step-row {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  gap: var(--gap-card);
  align-items: start;
  padding: 12px 0;
  border-bottom: 1px solid rgba(26, 44, 68, 0.08);
}

.step-row:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.step-row span {
  display: inline-grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border-radius: 16px;
  color: #fff;
  font-weight: 800;
  background: var(--blue);
  box-shadow: 0 10px 18px rgba(8, 102, 255, 0.14);
}

.step-row h3,
.step-row p {
  margin: 0;
}

.site-footer {
  margin-top: auto;
  padding-top: 14px;
  text-align: center;
}

.site-footer p {
  margin: 0;
  color: var(--muted);
  font-size: var(--type-small);
  line-height: 1.2;
}

.back-to-top {
  position: fixed;
  right: 28px;
  bottom: 28px;
  z-index: 900;
  display: inline-grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(8, 102, 255, 0.18);
  border-radius: 999px;
  color: #fff;
  font-size: var(--type-h3);
  font-weight: 800;
  background: linear-gradient(135deg, #1484ff 0%, #0866ff 58%, #0050d8 100%);
  box-shadow: 0 16px 32px rgba(8, 102, 255, 0.24);
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transform: translateY(10px);
  transition: opacity 160ms ease, transform 160ms ease;
}

.back-to-top.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.back-to-top:hover {
  transform: translateY(-2px);
}

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

  .page-main,
  .site-nav::before,
  .site-nav a,
  .back-to-top {
    transition: none;
  }
}

@media (max-width: 1280px) {
  .overview-shell .intro-card {
    grid-template-columns: minmax(0, 1fr);
  }

  .metrics-grid {
    max-width: none;
    justify-self: stretch;
  }
}

@media (max-width: 980px) {
  :root {
    --type-h1: 2.32rem;
    --section-pad: 22px;
    --card-pad: 18px;
  }

  .overview-shell .intro-card,
  .side-caption-figure,
  .download-layout {
    grid-template-columns: 1fr;
  }

  .concept-panel {
    order: 1;
  }

  .metrics-grid {
    order: 2;
    max-width: none;
    justify-self: stretch;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .figure-image,
  .media-card .figure-image {
    max-height: 360px;
  }
}

@media (max-width: 860px) {
  :root {
    --header-space: 104px;
  }

  .site-header {
    top: 10px;
    flex-wrap: wrap;
    gap: 10px;
    padding: 10px 12px 10px 16px;
    border-radius: 22px;
  }

  .brand-lockup {
    flex: 1 1 auto;
    max-width: calc(100% - 82px);
    gap: 10px;
  }

  .brand-mark {
    width: 42px;
    height: 42px;
    border-radius: 13px;
    font-size: var(--type-meta);
  }

  .brand-text strong {
    font-size: var(--type-h3);
  }

  .brand-text span {
    font-size: var(--type-small);
  }

  .menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-left: auto;
  }

  .site-nav {
    display: none;
    width: 100%;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
    padding: 6px;
    border-radius: 18px;
  }

  .site-header.is-open .site-nav {
    display: grid;
  }

  .site-nav::before {
    display: none;
  }

  .site-nav a {
    min-width: 0;
    min-height: 42px;
    padding: 10px 12px;
  }

  .site-nav a.is-active,
  .site-nav a.is-pending {
    color: #fff;
    background: var(--blue);
    box-shadow: 0 10px 18px rgba(8, 102, 255, 0.18);
  }
}

@media (max-width: 760px) {
  :root {
    --page-gutter: 16px;
    --header-space: 104px;
    --section-pad: 14px;
    --card-pad: 14px;
    --gap-page: 16px;
    --gap-section: 14px;
    --gap-card: 12px;
    --gap-item: 10px;
    --section-radius: 22px;
    --card-radius: 18px;
    --item-radius: 16px;
    --type-body: 1rem;
    --type-small: 1rem;
    --type-meta: 1rem;
    --type-lead: 1rem;
    --type-stat: 1.5rem;
    --type-h1: 2.1rem;
    --type-h2: 1.26rem;
    --type-h3: 1rem;
  }

  body {
    overflow-x: hidden;
  }

  .site-stage {
    width: 100%;
    padding-inline: 8px;
  }

  .site-header {
    top: 10px;
    width: calc(100% - 16px);
    flex-wrap: wrap;
    gap: 10px;
    padding: 10px 12px 10px 16px;
    border-radius: 22px;
  }

  .brand-lockup {
    flex: 1 1 auto;
    max-width: calc(100% - 82px);
    gap: 10px;
  }

  .brand-mark {
    width: 42px;
    height: 42px;
    border-radius: 13px;
    font-size: var(--type-meta);
  }

  .brand-text strong {
    font-size: var(--type-h3);
  }

  .brand-text span {
    font-size: var(--type-small);
  }

  .menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-left: auto;
  }

  .site-nav {
    display: none;
    width: 100%;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
    padding: 6px;
    border-radius: 18px;
  }

  .site-header.is-open .site-nav {
    display: grid;
  }

  .site-nav::before {
    display: none;
  }

  .site-nav a {
    min-width: 0;
    min-height: 42px;
    padding: 10px 12px;
  }

  .site-nav a.is-active,
  .site-nav a.is-pending {
    color: #fff;
    background: var(--blue);
    box-shadow: 0 10px 18px rgba(8, 102, 255, 0.18);
  }

  .page-main {
    margin-top: 12px;
  }

  .section-heading,
  .card-header {
    gap: 8px;
  }

  .concept-panel {
    gap: 14px;
    padding: 14px;
  }

  .concept-panel .lead {
    line-height: 1.58;
  }

  .concept-item {
    grid-template-columns: 12px minmax(0, 1fr);
    gap: 10px;
    padding: 12px 0;
  }

  .concept-dot {
    width: 8px;
    height: 8px;
    margin-top: 7px;
    box-shadow: 0 0 0 4px rgba(22, 119, 255, 0.12);
  }

  .concept-item p {
    font-size: var(--type-body);
    line-height: 1.5;
  }

  .metric-card {
    grid-template-columns: 40px minmax(0, 1fr);
    min-height: 86px;
    padding: 16px 16px 16px 18px;
    border-radius: 16px;
    column-gap: 12px;
    row-gap: 3px;
  }

  .metric-card::before {
    right: -36px;
    bottom: -52px;
    width: 116px;
    height: 116px;
  }

  .metric-card strong {
    font-size: var(--type-stat);
  }

  .metric-card .metric-label {
    font-size: var(--type-small);
  }

  .metric-card small {
    margin-top: 3px;
    font-size: var(--type-meta);
  }

  .metric-icon {
    width: 38px;
    height: 38px;
    border-radius: 13px;
  }

  .figure-image,
  .media-card .figure-image {
    max-height: 300px;
    padding: 8px;
    border-radius: 16px;
  }

  .figure-caption-text {
    padding: 16px;
  }

  .scenario-legend {
    padding: 16px;
  }

  .scenario-legend div {
    flex-basis: 220px;
    padding: 10px 12px;
  }

  th,
  td {
    padding: 9px 8px;
  }

  .download-action,
  .primary-action,
  .secondary-action {
    width: 100%;
  }

  .access-actions {
    gap: 10px;
  }

  .step-row {
    grid-template-columns: 42px minmax(0, 1fr);
    padding: 10px 0;
  }

  .step-row span {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    font-size: var(--type-meta);
  }
}

@media (max-width: 480px) {
  :root {
    --page-gutter: 12px;
    --header-space: 98px;
    --section-pad: 12px;
    --card-pad: 12px;
    --type-h1: 1.9rem;
    --type-h2: 1.18rem;
  }

  .site-stage {
    padding-inline: 6px;
  }

  .site-header {
    width: calc(100% - 12px);
    padding-left: 12px;
    padding-right: 10px;
    border-radius: 20px;
  }

  .brand-lockup {
    max-width: calc(100% - 68px);
  }

  .brand-mark {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    font-size: var(--type-meta);
  }

  .brand-text span {
    display: none;
  }

  .metric-card {
    grid-template-columns: 36px minmax(0, 1fr);
    min-height: 82px;
    padding: 13px 12px;
    column-gap: 10px;
    row-gap: 3px;
  }

  .metric-card strong {
    font-size: var(--type-stat);
  }

  .metric-card .metric-label {
    font-size: var(--type-small);
  }

  .metric-card small {
    display: none;
  }

  .metric-icon {
    width: 36px;
    height: 36px;
    border-radius: 12px;
  }

  .scenario-legend div {
    flex-basis: 100%;
    align-items: flex-start;
    border-radius: 14px;
  }
}

@media (max-width: 640px) and (orientation: portrait) {
  :root {
    --header-space: 88px;
    --section-pad: 14px;
    --card-pad: 14px;
    --gap-page: 16px;
    --gap-section: 16px;
    --gap-card: 14px;
    --gap-item: 12px;
    --section-radius: 18px;
    --card-radius: 16px;
    --item-radius: 14px;
    --type-h1: 2.05rem;
    --type-h2: 1.28rem;
    --type-h3: 1.05rem;
    --type-body: 1rem;
    --type-small: 1rem;
    --type-meta: 1rem;
    --type-lead: 1rem;
    --type-stat: 1.5rem;
  }

  html,
  body {
    max-width: 100%;
    overflow-x: hidden;
  }

  .site-stage {
    width: 100%;
    padding: var(--header-space) 8px 14px;
  }

  .site-header {
    top: 8px;
    width: calc(100% - 12px);
    gap: 8px;
    padding: 8px 10px 8px 12px;
    border-radius: 18px;
  }

  .brand-lockup {
    max-width: calc(100% - 64px);
    gap: 8px;
  }

  .brand-mark {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    font-size: var(--type-meta);
  }

  .brand-text strong {
    font-size: var(--type-h3);
    line-height: 1.1;
  }

  .brand-text span {
    display: none;
  }

  .menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    padding: 7px 11px;
    margin-left: auto;
  }

  .site-nav {
    display: none;
    width: 100%;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
    padding: 6px;
    border-radius: 16px;
  }

  .site-header.is-open .site-nav {
    display: grid;
  }

  .site-nav::before {
    display: none;
  }

  .site-nav a {
    min-width: 0;
    min-height: 40px;
    padding: 9px 10px;
  }

  .site-nav a.is-active,
  .site-nav a.is-pending {
    color: #fff;
    background: var(--blue);
    box-shadow: 0 8px 16px rgba(8, 102, 255, 0.18);
  }

  .page-main {
    gap: var(--gap-page);
    margin-top: 4px;
  }

  .section-shell,
  .card,
  .concept-panel,
  .download-detail,
  .figure-caption-text,
  .scenario-legend,
  .table-wrap,
  .citation-block {
    max-width: 100%;
    min-width: 0;
  }

  .section-shell {
    padding: var(--section-pad);
  }

  .section-heading,
  .card-header {
    flex-direction: column;
    gap: 8px;
  }

  h1 {
    font-size: var(--type-h1);
    line-height: 1.08;
  }

  h2 {
    font-size: var(--type-h2);
  }

  .overview-shell .intro-card,
  .side-caption-figure,
  .download-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--gap-section);
  }

  .concept-panel {
    gap: 14px;
    padding: 14px;
  }

  .concept-panel .lead {
    font-size: var(--type-lead);
    line-height: 1.62;
  }

  .concept-item {
    grid-template-columns: 12px minmax(0, 1fr);
    gap: 12px;
    padding: 13px 0;
  }

  .concept-dot {
    width: 8px;
    height: 8px;
    margin-top: 7px;
    box-shadow: 0 0 0 4px rgba(22, 119, 255, 0.12);
  }

  .concept-item strong {
    font-size: var(--type-body);
  }

  .concept-item p {
    font-size: var(--type-body);
    line-height: 1.58;
  }

  .metrics-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

  .metric-card {
    grid-template-columns: 36px minmax(0, 1fr);
    min-height: 96px;
    padding: 16px 14px;
    column-gap: 10px;
    row-gap: 3px;
  }

  .metric-card strong {
    font-size: var(--type-stat);
  }

  .metric-card .metric-label {
    font-size: var(--type-small);
    line-height: 1.32;
  }

  .metric-card small {
    display: none;
  }

  .metric-icon {
    width: 36px;
    height: 36px;
    border-radius: 12px;
  }

  .figure-image,
  .media-card .figure-image {
    width: 100%;
    max-height: 260px;
    padding: 8px;
  }

  .figure-caption-text {
    padding: 16px;
  }

  .scenario-legend {
    padding: 16px;
  }

  .scenario-legend div {
    flex-basis: 100%;
    align-items: flex-start;
    border-radius: 14px;
    padding: 12px;
  }

  .table-wrap {
    overflow-x: auto;
  }

  table {
    min-width: 760px;
  }

  th,
  td {
    padding: 8px 7px;
  }

  .download-layout,
  .download-panel-card,
  .download-materials,
  .step-list {
    gap: 12px;
  }

  .download-detail,
  .steps-card,
  .download-panel-card {
    padding: 14px;
  }

  .primary-action,
  .secondary-action,
  .download-action {
    width: 100%;
    min-height: 42px;
  }

  .access-actions {
    gap: 10px;
  }

  .step-row {
    grid-template-columns: 38px minmax(0, 1fr);
    gap: 12px;
    padding: 12px 0;
  }

  .step-row span {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    font-size: var(--type-meta);
  }

  .back-to-top {
    right: 16px;
    bottom: 16px;
    width: 44px;
    height: 44px;
    font-size: var(--type-h3);
  }

  .step-row h3 {
    font-size: var(--type-h3);
  }

  .step-row p,
  .download-detail p,
  .citation-block,
  .scenario-legend dd {
    font-size: var(--type-small);
  }
}
