:root {
  color-scheme: dark light;
  --bg: #0b0b0c;
  --bg-deep: #050506;
  --surface: #111111;
  --surface-soft: #171410;
  --ink: #f5f1e8;
  --muted: #d6cec4;
  --dim: #9b9387;
  --line: rgba(245, 241, 232, 0.16);
  --line-strong: rgba(201, 106, 43, 0.34);
  --brand: #C96A2B;
  --brand-bright: #f6a436;
  --brand-soft: rgba(201, 106, 43, 0.16);
  --sun: #030405;
  --focus: #f6a436;
  --glow-x: 19%;
  --glow-y: 0%;
  --mobile-gutter: clamp(20px, 6.2vw, 28px);
  --font-heading: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  --font-body: ui-sans-serif, -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  font-family: var(--font-body);
}

/* Light mode overrides */
html[data-theme="light"] {
  --bg: #faf8f5;
  --bg-deep: #f5f1eb;
  --surface: #fefdfb;
  --surface-soft: #f7f3ed;
  --ink: #1a1714;
  --muted: #4a4340;
  --dim: #6e6760;
  --line: rgba(0, 0, 0, 0.1);
  --line-strong: rgba(201, 106, 43, 0.28);
  --brand: #C96A2B;
  --brand-bright: #b85a1e;
  --brand-soft: rgba(201, 106, 43, 0.08);
  --sun: #faf6f0;
  --focus: #b85a1e;
}

html[data-theme="light"] body {
  background:
    linear-gradient(180deg, var(--bg) 0%, var(--bg-deep) 45%, #f0ece6 100%);
}

html[data-theme="light"] .system-backdrop::before {
  background: none;
}

html[data-theme="light"] .system-backdrop span {
  display: none;
}

html[data-theme="light"] .chapter-nav a span {
  background: rgba(250, 248, 245, 0.96);
  color: #1a1714;
}

html[data-theme="light"] .primary-link {
  color: #fefdfb;
}

html[data-theme="light"] .direction-list,
html[data-theme="light"] .lab-card {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.02), rgba(0, 0, 0, 0.01));
}

html[data-theme="light"] .section-jump-veil {
  background:
    radial-gradient(circle at 50% 42%, rgba(201, 106, 43, 0.12), transparent 36%),
    linear-gradient(180deg, rgba(250, 248, 245, 0.98), rgba(240, 236, 230, 0.96));
}

html[data-theme="light"] .contact-scope li {
  background: rgba(0, 0, 0, 0.03);
}

html[data-theme="light"] .contact-scope li:hover {
  background: rgba(201, 106, 43, 0.08);
}

html[data-theme="light"] .method-flow::before {
  background: linear-gradient(var(--brand-bright), rgba(201, 106, 43, 0.12));
}

html[data-theme="light"] .contact::before {
  background: radial-gradient(circle, rgba(201, 106, 43, 0.05), transparent 64%);
}

html[data-theme="light"] .lab-card {
  background:
    linear-gradient(135deg, rgba(201, 106, 43, 0.06), transparent 52%),
    rgba(0, 0, 0, 0.02);
}

html[data-theme="light"] .direction-item:nth-child(3)::before {
  background: linear-gradient(180deg, rgba(201, 106, 43, 0.06), transparent 60%);
}

@media (prefers-reduced-transparency: reduce) {
  html[data-theme="light"] .lab-card {
    background: var(--surface);
  }
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background: var(--bg-deep);
  color: var(--ink);
  overflow-x: hidden;
  scroll-behavior: auto;
  scroll-padding-top: 88px;
  scroll-snap-type: y mandatory;
  text-size-adjust: 100%;
}

body {
  position: relative;
  width: 100%;
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  overscroll-behavior-x: none;
  background:
    linear-gradient(180deg, rgba(244, 224, 188, 0.34) 0%, rgba(201, 106, 43, 0.12) 9rem, transparent 18rem),
    radial-gradient(circle at var(--glow-x) var(--glow-y), rgba(245, 241, 232, 0.48), transparent 13rem),
    radial-gradient(circle at 30% 33%, rgba(246, 164, 54, 0.22), transparent 18rem),
    radial-gradient(circle at 74% 8%, rgba(201, 106, 43, 0.18), transparent 28rem),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-deep) 55%, #0d0c0a 100%);
}

body,
button,
input {
  font: inherit;
}

a {
  color: inherit;
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
}

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

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 100;
  padding: 10px 14px;
  border-radius: 6px;
  background: var(--ink);
  color: var(--bg-deep);
  transform: translateY(-160%);
  transition: transform 160ms ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.system-backdrop {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.system-backdrop::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, transparent 0 18%, rgba(246, 164, 54, 0.045) 18.15%, transparent 18.4%),
    linear-gradient(180deg, transparent 0 28%, rgba(245, 241, 232, 0.035) 28.1%, transparent 28.3%);
  background-size: 180px 100%, 100% 132px;
  mask-image: radial-gradient(circle at 34% 36%, #000 0, transparent 58%);
}

.system-backdrop span {
  position: absolute;
  width: 1px;
  height: 34vh;
  background: linear-gradient(180deg, transparent, rgba(246, 164, 54, 0.5), transparent);
  opacity: 0.28;
  transform: translateY(-40vh);
  will-change: transform, opacity;
}

.system-backdrop span:nth-child(1) {
  left: 18vw;
  top: 12vh;
}

.system-backdrop span:nth-child(2) {
  left: 61vw;
  top: 4vh;
}

.system-backdrop span:nth-child(3) {
  left: 83vw;
  top: 30vh;
}

.section-jump-veil {
  position: fixed;
  inset: 0;
  z-index: 18;
  background:
    radial-gradient(circle at 50% 42%, rgba(246, 164, 54, 0.18), transparent 36%),
    linear-gradient(180deg, rgba(5, 5, 6, 0.98), rgba(12, 9, 6, 0.96));
  opacity: 0;
  pointer-events: none;
  transform: scaleY(0);
  transform-origin: top;
  will-change: transform, opacity;
}

.site-header,
.hero,
.directions,
.method,
.lab,
.contact,
.site-footer {
  width: min(1120px, calc(100% - 40px));
  margin-inline: auto;
}

.site-header {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 18px max(20px, calc((100vw - 1120px) / 2));
}

.brand {
  display: inline-flex;
  align-items: center;
  border-radius: 8px;
  text-decoration: none;
}

.brand-lockup {
  display: inline-flex;
  align-items: center;
  padding: 0;
  border-radius: 6px;
  filter: drop-shadow(0 0 16px rgba(246, 164, 54, 0.18));
}

.brand-logo {
  display: block;
  width: clamp(118px, 14vw, 166px);
  height: auto;
}

.brand-lockup {
  transform-origin: left center;
  will-change: transform, opacity, filter;
}

.chapter-nav {
  position: fixed;
  top: 18px;
  right: max(20px, calc((100vw - 1120px) / 2));
  z-index: 21;
  display: flex;
  gap: 9px;
  align-items: center;
}

.chapter-nav a {
  position: relative;
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 50%;
  color: var(--muted);
  text-decoration: none;
}

.chapter-nav a::after {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 0 0 rgba(246, 164, 54, 0);
  transition: width 180ms ease, border-radius 180ms ease, background-color 180ms ease, box-shadow 180ms ease;
}

.chapter-nav a span {
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  padding: 4px 7px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: rgba(5, 5, 6, 0.92);
  color: #f5f1e8;
  font-size: 0.72rem;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-4px);
  transition: opacity 160ms ease, transform 160ms ease;
  white-space: nowrap;
}

.chapter-nav a:hover span,
.chapter-nav a:focus-visible span {
  opacity: 1;
  transform: translateY(0);
}

.chapter-nav a.is-active {
  color: var(--brand-bright);
}

.chapter-nav a.is-active::after {
  width: 18px;
  border-radius: 999px;
  box-shadow: 0 0 18px rgba(246, 164, 54, 0.58);
}

.theme-toggle {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  margin-left: 4px;
  font-size: 14px;
  line-height: 1;
  padding: 0;
  transition: border-color 180ms ease, color 180ms ease;
}

.theme-toggle::before {
  content: "☀";
}

html[data-theme="dark"] .theme-toggle::before {
  content: "☾";
}

html[data-theme="light"] .theme-toggle::before {
  content: "☀";
}

.theme-toggle:hover {
  border-color: var(--line-strong);
  color: var(--ink);
}

.story-panel {
  position: relative;
  min-height: 100svh;
  scroll-snap-align: start;
  scroll-snap-stop: always;
}

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(260px, 430px);
  align-items: center;
  gap: clamp(36px, 7vw, 108px);
  min-height: 100svh;
  padding-block: clamp(60px, 8vw, 96px) clamp(68px, 8vw, 110px);
}

.hero-content {
  max-width: 760px;
}

.hero-kicker {
  margin: 0 0 18px;
  color: var(--brand-bright);
  font-size: 0.95rem;
  font-weight: 700;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  font-family: var(--font-heading);
}

h1 {
  margin-bottom: 24px;
  max-width: 10ch;
  color: var(--ink);
  font-size: clamp(4.4rem, 10vw, 6rem);
  line-height: 0.95;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

.hero-intro {
  max-width: 35rem;
  margin-bottom: 34px;
  color: var(--muted);
  font-size: clamp(1.12rem, 2vw, 1.38rem);
  line-height: 1.75;
  text-wrap: pretty;
}

.primary-link {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 0 23px;
  border: 1px solid var(--brand);
  border-radius: 999px;
  background: linear-gradient(180deg, var(--brand-bright), var(--brand));
  color: #090806;
  font-weight: 800;
  text-decoration: none;
  transition: border-color 180ms ease, filter 180ms ease, transform 180ms ease;
}

.primary-link:hover {
  border-color: var(--brand-bright);
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.hero-visual {
  position: relative;
  justify-self: end;
  width: min(100%, 540px);
  aspect-ratio: 44 / 46;
  display: grid;
  place-items: center;
  contain: layout;
  overflow: visible;
  will-change: transform, opacity, filter;
}

.hero-sun {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 50%;
  filter: drop-shadow(0 0 42px rgba(246, 164, 54, 0.34));
}

.hero-orbit,
.hero-pulse,
.scan-beam {
  position: absolute;
  inset: 7%;
  border-radius: 50%;
  pointer-events: none;
}

.hero-orbit {
  border: 1px solid rgba(246, 164, 54, 0.22);
  box-shadow: inset 0 0 38px rgba(246, 164, 54, 0.05);
  will-change: transform, opacity;
}

.orbit-two {
  inset: 15%;
  border-style: dashed;
  opacity: 0.42;
}

.hero-pulse {
  inset: 9%;
  border: 1px solid rgba(246, 164, 54, 0.34);
  box-shadow:
    0 0 34px rgba(246, 164, 54, 0.16),
    inset 0 0 28px rgba(246, 164, 54, 0.08);
  opacity: 0;
  will-change: transform, opacity;
}

.pulse-two {
  inset: 17%;
}

.energy-node {
  position: absolute;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--brand-bright);
  box-shadow: 0 0 18px rgba(246, 164, 54, 0.82);
  opacity: 0;
  pointer-events: none;
  will-change: transform, opacity;
}

.node-one {
  top: 15%;
  left: 52%;
}

.node-two {
  right: 15%;
  top: 54%;
}

.node-three {
  bottom: 15%;
  left: 41%;
}

.scan-beam {
  inset: 3%;
  background: conic-gradient(from 270deg, transparent 0deg, rgba(246, 164, 54, 0.48) 10deg, transparent 22deg);
  mix-blend-mode: screen;
  opacity: 0;
  will-change: transform, opacity;
}

[data-animate] {
  will-change: transform, opacity;
}

.directions {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-block: clamp(104px, 12vw, 150px);
}

.section-heading {
  display: flex;
  flex-direction: column;
  gap: clamp(24px, 4vw, 40px);
  margin-bottom: clamp(36px, 6vw, 72px);
}

.section-mark {
  margin: 0;
  color: var(--brand-bright);
  font-size: clamp(1.55rem, 2.5vw, 2.25rem);
  font-weight: 800;
  line-height: 1;
  opacity: 0.72;
  text-wrap: balance;
}

.section-heading h2,
.contact h2 {
  margin-bottom: 24px;
  font-size: clamp(2.45rem, 5.6vw, 5.2rem);
  line-height: 1.02;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

.method h2,
.lab h2 {
  margin-bottom: 22px;
  font-size: clamp(1.72rem, 3.4vw, 3rem);
  line-height: 1.08;
  letter-spacing: -0.015em;
  text-wrap: balance;
}

.section-heading p {
  max-width: 42rem;
  margin-bottom: 0;
  color: var(--muted);
  font-size: clamp(1rem, 1.6vw, 1.2rem);
  line-height: 1.8;
  text-wrap: pretty;
}

.direction-list {
  display: grid;
  grid-template-columns: 3fr 2fr;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(245, 241, 232, 0.045), rgba(245, 241, 232, 0.018));
}

.direction-item {
  position: relative;
  min-width: 0;
  min-height: 260px;
  padding: clamp(26px, 3.2vw, 40px);
  overflow: hidden;
}

.direction-item:nth-child(2) {
  border-left: 1px solid var(--line);
}

.direction-item:nth-child(3) {
  grid-column: span 2;
  border-top: 1px solid var(--line);
  min-height: 200px;
}

/* Differentiated gradient backgrounds per card */
.direction-item:nth-child(1)::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(246, 164, 54, 0.18), transparent 48%);
  opacity: 0;
  transition: opacity 220ms ease;
}

.direction-item:nth-child(2)::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 80% 20%, rgba(246, 164, 54, 0.13), transparent 55%);
  opacity: 0;
  transition: opacity 220ms ease;
}

.direction-item:nth-child(3)::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(246, 164, 54, 0.10), transparent 60%);
  opacity: 0;
  transition: opacity 220ms ease;
}

.direction-item:hover::before {
  opacity: 1;
}

.direction-item h3 {
  margin: clamp(54px, 7vw, 86px) 0 15px;
  color: var(--ink);
  font-size: clamp(1.2rem, 2vw, 1.45rem);
  line-height: 1.3;
}

.direction-item p {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.78;
  text-wrap: pretty;
}

.module-index {
  color: var(--brand-bright);
  font-size: 0.78rem;
  font-weight: 800;
}

.method {
  display: grid;
  grid-template-columns: minmax(0, 0.72fr) minmax(340px, 1fr);
  gap: clamp(48px, 8vw, 120px);
  align-items: center;
  padding-block: clamp(106px, 12vw, 160px);
}

.method-intro > p:last-child {
  max-width: 38rem;
  margin: 0;
  color: var(--muted);
  font-size: clamp(1.02rem, 1.6vw, 1.2rem);
  line-height: 1.8;
}

.method-intro .section-mark,
.lab-copy .section-mark {
  margin-bottom: clamp(28px, 5vw, 56px);
}

.method-flow {
  position: relative;
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
  --flow-progress: 1;
}

.method-flow::before {
  content: "";
  position: absolute;
  top: 18px;
  bottom: 18px;
  left: 13px;
  width: 1px;
  background: linear-gradient(var(--brand-bright), rgba(201, 106, 43, 0.18));
  transform: scaleY(var(--flow-progress));
  transform-origin: top;
}

.method-step {
  position: relative;
  padding-block: 18px 24px;
  padding-left: 44px;
}

.method-step::before {
  content: "";
  position: absolute;
  top: 24px;
  left: 11px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--brand-bright);
  box-shadow: 0 0 8px rgba(246, 164, 54, 0.5);
  transition: background-color 280ms ease, box-shadow 280ms ease;
}

.method-step h3 {
  margin-bottom: 7px;
  font-size: 1.1rem;
}

.method-step p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.lab {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: clamp(56px, 6vw, 88px);
  padding-block: clamp(106px, 12vw, 160px);
}

.lab-copy {
  max-width: 48rem;
  margin-inline: auto;
  text-align: center;
}

.lab-copy > p:last-child {
  max-width: 42rem;
  margin: 0;
  color: var(--muted);
  font-size: clamp(1.02rem, 1.6vw, 1.2rem);
  line-height: 1.85;
}

.lab-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.lab-list .lab-card:nth-child(3) {
  grid-column: span 2;
}

.lab-card {
  position: relative;
  min-height: 172px;
  padding: clamp(22px, 3vw, 30px);
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(246, 164, 54, 0.12), transparent 52%),
    rgba(245, 241, 232, 0.026);
  overflow: hidden;
}

.lab-card::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(246, 164, 54, 0.68), transparent);
}

.lab-card span {
  display: block;
  margin-bottom: clamp(24px, 4vw, 38px);
  color: var(--brand-bright);
  font-size: 0.82rem;
  font-weight: 800;
}

.lab-card h3 {
  margin-bottom: 10px;
  font-size: clamp(1.2rem, 2vw, 1.46rem);
}

.lab-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.72;
  text-wrap: pretty;
}

.contact {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding-top: clamp(128px, 17vw, 210px);
}

.contact::before {
  content: "";
  position: absolute;
  top: 18%;
  right: -12%;
  width: min(58vw, 760px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(246, 164, 54, 0.09), transparent 64%);
  pointer-events: none;
}

.contact-main {
  position: relative;
  z-index: 1;
}

.contact-prelude {
  max-width: 45rem;
  margin-bottom: 30px;
  color: var(--muted);
  font-size: clamp(1.02rem, 1.8vw, 1.25rem);
  line-height: 1.75;
}

.contact-summary {
  max-width: 42rem;
  margin: 0 0 clamp(36px, 4vw, 52px);
  color: var(--muted);
  font-size: clamp(0.96rem, 1.4vw, 1.1rem);
  line-height: 1.85;
  text-wrap: pretty;
}

.contact-scope {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 0 0 clamp(42px, 5vw, 64px);
  padding: 0;
  list-style: none;
}

.contact-scope li {
  display: inline-flex;
  align-items: center;
  padding: 8px 18px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink);
  font-size: 0.92rem;
  background: rgba(245, 241, 232, 0.06);
  transition: border-color 220ms ease, color 220ms ease, background 220ms ease;
}

.contact-scope li:hover {
  border-color: var(--line-strong);
  color: var(--ink);
  background: rgba(246, 164, 54, 0.06);
}

.contact h2 {
  max-width: 18ch;
  margin-bottom: clamp(32px, 4vw, 46px);
  font-size: clamp(2.5rem, 5.4vw, 4.8rem);
}

.contact-link {
  min-height: 54px;
  padding-inline: 28px;
}

.site-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
  align-items: center;
  justify-content: space-between;
  padding-block: 30px 40px;
  color: var(--dim);
  font-size: 0.92rem;
}

.site-footer p {
  margin: 0;
}

.filing-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
}

.filing-links a {
  color: var(--dim);
}

.filing-links a:hover {
  color: var(--brand-bright);
}

@media (max-width: 920px) {
  .method,
  .lab {
    grid-template-columns: 1fr;
    gap: 64px;
  }

  .method-flow {
    max-width: 620px;
  }

}

@media (max-width: 760px) {
  .site-header,
  .hero,
  .directions,
  .method,
  .lab,
  .contact,
  .site-footer {
    width: min(calc(100% - (var(--mobile-gutter) * 2)), 1120px);
  }

  .site-header {
    width: 100%;
    padding-inline: var(--mobile-gutter);
  }

  .chapter-nav {
    top: 16px;
    right: var(--mobile-gutter);
    gap: 2px;
  }

  .chapter-nav a {
    width: 25px;
  }

  .chapter-nav a span {
    display: none;
  }

  .story-panel {
  }

  .hero {
    grid-template-columns: 1fr;
    gap: 26px;
    padding-block: 88px 72px;
  }

  .hero-visual {
    grid-row: 1;
    justify-self: center;
    width: min(62vw, 236px);
    max-width: 100%;
  }

  .brand-lockup {
    padding: 0;
  }

  h1 {
    font-size: clamp(3.15rem, 18.4vw, 4.65rem);
  }

  .section-heading {
    gap: 26px;
  }

  .direction-list {
    grid-template-columns: 1fr;
  }

  .direction-item {
    min-height: auto;
  }

  .direction-item:nth-child(2) {
    border-left: 0;
    border-top: 1px solid var(--line);
  }

  .direction-item:nth-child(3) {
    grid-column: span 1;
  }

  .direction-item h3 {
    margin-top: 38px;
  }

  .method,
  .lab {
    gap: 46px;
    padding-block: 96px;
  }

  .lab-list {
    grid-template-columns: 1fr;
  }

  .lab-list .lab-card:nth-child(3) {
    grid-column: span 1;
  }

  .lab-copy {
    text-align: left;
  }

  .method-intro .section-mark,
  .lab-copy .section-mark {
    margin-bottom: 38px;
  }

  .section-heading h2 {
    font-size: clamp(2.05rem, 10.3vw, 3.32rem);
  }

  .method h2,
  .lab h2 {
    font-size: clamp(1.56rem, 7.8vw, 2.48rem);
  }

  .section-heading p,
  .method-intro > p:last-child,
  .lab-copy > p:last-child,
  .contact-prelude,
  .contact-summary {
    max-width: 30rem;
  }

  .lab-card {
    min-height: auto;
    padding: 24px;
  }

  .contact {
    padding-block: 112px 42px;
  }

  .contact h2 {
    font-size: clamp(2.45rem, 11.4vw, 3.7rem);
  }

  .section-heading h2,
  .method h2,
  .lab h2,
  .contact h2 {
    width: 100%;
    max-width: none;
  }

  .site-footer {
    align-items: flex-start;
    flex-direction: column;
    width: 100%;
    margin-top: 64px;
    padding-block: 26px 0;
  }
}

/* Theme transition — temporary global transition on all elements during switch */
html.theme-transitioning,
html.theme-transitioning *,
html.theme-transitioning *::before,
html.theme-transitioning *::after {
  transition: background-color 0.80s ease, color 0.80s ease, border-color 0.80s ease, box-shadow 0.80s ease, filter 0.80s ease, background 0.80s ease !important;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-snap-type: none;
  }

  html.theme-transitioning,
  html.theme-transitioning *,
  html.theme-transitioning *::before,
  html.theme-transitioning *::after {
    transition: none !important;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
