:root {
  color-scheme: dark;
  --bg: #101112;
  --surface: #171819;
  --surface-strong: #1d1e20;
  --text: #e9e4d8;
  --muted: #a8a397;
  --faint: #77746d;
  --line: rgba(233, 228, 216, 0.14);
  --line-strong: rgba(233, 228, 216, 0.28);
  --accent: #bd4b35;
  --gold: #c7a565;
  --shadow: rgba(5, 6, 7, 0.35);
  --serif: "Songti SC", "STSong", "Noto Serif CJK SC", "Source Han Serif SC", serif;
  --sans: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  --mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  --page: min(1280px, calc(100vw - 64px));
  --reading: min(760px, calc(100vw - 40px));
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

[data-theme="light"] {
  color-scheme: light;
  --bg: #e9e6de;
  --surface: #f1eee7;
  --surface-strong: #dedad0;
  --text: #202123;
  --muted: #5f5d58;
  --faint: #7c7971;
  --line: rgba(32, 33, 35, 0.16);
  --line-strong: rgba(32, 33, 35, 0.3);
  --accent: #a83f2c;
  --gold: #806635;
  --shadow: rgba(32, 33, 35, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  background: var(--bg);
}

body {
  margin: 0;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
}

.article-page {
  --ink: var(--bg);
  --panel: var(--surface);
  --panel2: var(--surface-strong);
  --moon: var(--text);
  --moon-dim: var(--muted);
  --mist: var(--faint);
  --cf-wx-radius: 2px;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  color: inherit;
  font: inherit;
}

img {
  display: block;
  max-width: 100%;
}

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

.grain {
  position: fixed;
  inset: 0;
  z-index: 20;
  pointer-events: none;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.82' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.8'/%3E%3C/svg%3E");
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  width: 100%;
  min-height: 70px;
  padding: 0 max(24px, calc((100vw - 1280px) / 2));
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  justify-self: start;
  gap: 12px;
  width: max-content;
}

.brand-seal {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 2px;
  background: var(--accent);
  color: #f2e9dc;
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
}

.brand-name {
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 34px;
  font-size: 14px;
  color: var(--muted);
}

.site-nav a,
.text-link {
  transition: color 220ms ease;
}

.site-nav a:hover,
.site-nav a:focus-visible,
.text-link:hover,
.text-link:focus-visible {
  color: var(--accent);
}

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

.theme-toggle,
.menu-toggle {
  border: 0;
  background: transparent;
  cursor: pointer;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-self: end;
  gap: 8px;
  padding: 10px 0;
  color: var(--muted);
  font-family: var(--serif);
}

.theme-divider {
  width: 22px;
  height: 1px;
  background: var(--line-strong);
}

.menu-toggle {
  display: none;
}

.home-hero {
  display: grid;
  grid-template-columns: minmax(260px, 0.72fr) minmax(560px, 1.45fr);
  gap: clamp(48px, 7vw, 112px);
  align-items: center;
  width: var(--page);
  min-height: calc(100dvh - 70px);
  margin: 0 auto;
  padding: clamp(48px, 7vh, 82px) 0;
}

.home-intro {
  align-self: start;
  padding-top: clamp(30px, 7vh, 86px);
}

.edition,
.article-category {
  margin: 0 0 22px;
  color: var(--gold);
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.18em;
}

.home-intro h1 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(58px, 7.3vw, 112px);
  font-weight: 600;
  letter-spacing: -0.08em;
  line-height: 0.98;
}

.home-lead {
  max-width: 22em;
  margin: 30px 0 34px;
  color: var(--muted);
  font-family: var(--serif);
  font-size: clamp(18px, 1.7vw, 23px);
  line-height: 1.8;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid var(--line-strong);
  font-size: 14px;
  font-weight: 600;
}

.text-link span {
  transition: transform 260ms var(--ease);
}

.text-link:hover span {
  transform: translateX(5px);
}

.article-waterfall {
  min-width: 0;
}

.article-card {
  display: block;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: 0 22px 70px var(--shadow);
  break-inside: avoid;
  transition: border-color 260ms ease, transform 400ms var(--ease);
}

.article-card:hover {
  border-color: var(--line-strong);
  transform: translateY(-4px);
}

.article-card-cover {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: var(--surface-strong);
}

.article-card-cover::after {
  position: absolute;
  inset: 0;
  border: 1px solid rgba(255, 255, 255, 0.11);
  content: "";
  pointer-events: none;
}

.article-card-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 900ms var(--ease), filter 500ms ease;
}

.article-card:hover .article-card-cover img {
  transform: scale(1.018);
  filter: contrast(1.04);
}

.article-card-body {
  display: block;
  padding: clamp(24px, 3vw, 38px);
}

.article-card-body .article-category {
  display: block;
  margin-bottom: 16px;
}

.article-card-title {
  display: block;
  font-family: var(--serif);
  font-size: clamp(29px, 3.1vw, 48px);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.22;
  transition: color 220ms ease;
}

.article-card:hover .article-card-title {
  color: var(--accent);
}

.byline {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  align-items: center;
  color: var(--faint);
  font-size: 12px;
  line-height: 1.7;
}

.article-card-body .byline {
  margin-top: 18px;
}

.article-preview {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  margin-top: 30px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-family: var(--serif);
  font-size: 16px;
  line-height: 1.85;
}

.card-read {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-top: 28px;
  padding-bottom: 7px;
  border-bottom: 1px solid var(--line-strong);
  font-size: 13px;
  font-weight: 600;
}

.card-read > span {
  transition: transform 260ms var(--ease);
}

.article-card:hover .card-read > span {
  transform: translateX(5px);
}

/*
  A single article stays full-width. From the second article onward, desktop
  uses a stable two-column editorial grid so both cards begin in the first row.
*/
.article-waterfall:has(.article-card:nth-child(2)) {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px;
  align-items: start;
}

.article-waterfall:has(.article-card:nth-child(2)) .article-card {
  display: block;
  width: 100%;
}

/* Science archive */

.section-back {
  position: fixed;
  top: calc(env(safe-area-inset-top, 0px) + 84px);
  left: max(16px, calc((100vw - 1280px) / 2));
  z-index: 40;
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  padding: 9px 14px;
  border: 1px solid color-mix(in srgb, var(--text) 22%, transparent);
  border-radius: 999px;
  background: color-mix(in srgb, var(--bg) 68%, transparent);
  box-shadow: 0 10px 30px color-mix(in srgb, var(--bg) 20%, transparent);
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  line-height: 1;
  text-decoration: none;
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  transition: color 180ms var(--ease), border-color 180ms var(--ease), background 180ms var(--ease);
}

.section-back:hover,
.section-back:focus-visible {
  border-color: var(--line-strong);
  background: color-mix(in srgb, var(--surface) 82%, transparent);
  color: var(--text);
}

.science-archive {
  width: var(--page);
  min-height: calc(100dvh - 70px);
  margin: 0 auto;
  padding: clamp(72px, 8vw, 118px) 0 clamp(96px, 10vw, 150px);
}

.science-intro {
  max-width: 820px;
  margin-bottom: clamp(48px, 6vw, 78px);
}

.science-intro h1 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(62px, 8vw, 108px);
  font-weight: 600;
  letter-spacing: -0.075em;
  line-height: 1;
}

.science-lead {
  max-width: 34em;
  margin: 28px 0 0;
  color: var(--muted);
  font-family: var(--serif);
  font-size: clamp(18px, 1.8vw, 23px);
  line-height: 1.85;
}

.science-waterfall {
  width: 100%;
}

.science-card .article-card-cover {
  aspect-ratio: 1200 / 630;
}

.site-footer {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 32px;
  width: var(--page);
  min-height: 156px;
  margin: 0 auto;
  color: var(--faint);
  font-size: 12px;
}

.site-footer > p {
  margin: 0;
}

.site-footer .copyright {
  justify-self: end;
}

.footer-brand {
  color: var(--text);
}

.about-section {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}

.about-inner {
  display: grid;
  grid-template-columns: 0.65fr 1.1fr auto;
  gap: clamp(36px, 7vw, 110px);
  align-items: start;
  width: var(--page);
  margin: 0 auto;
  padding: clamp(76px, 9vw, 132px) 0;
}

.about-inner h1,
.about-inner h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(30px, 3.6vw, 52px);
  font-weight: 600;
  line-height: 1.2;
}

.about-copy p {
  margin: 0 0 18px;
  color: var(--muted);
  font-family: var(--serif);
  font-size: 18px;
  line-height: 1.9;
}

.topics {
  margin: 4px 0 0;
  color: var(--gold);
  font-family: var(--serif);
  font-size: 14px;
  line-height: 2.1;
  writing-mode: vertical-rl;
}

/* Article */

.reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 30;
  width: 100%;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: 0 50%;
}

@supports (animation-timeline: scroll()) {
  .reading-progress {
    animation: reading-progress linear both;
    animation-timeline: scroll();
  }
}

.article-header {
  width: min(1120px, calc(100vw - 64px));
  margin: 0 auto;
  padding: clamp(64px, 8vw, 116px) 0 0;
}

.article-tools {
  position: fixed;
  top: calc(env(safe-area-inset-top, 0px) + 84px);
  left: max(18px, calc((100vw - 1120px) / 2));
  right: max(18px, calc((100vw - 1120px) / 2));
  z-index: 30;
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: center;
  margin: 0;
  pointer-events: none;
}

.back-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 9px 15px;
  margin-bottom: 0;
  border: 1px solid var(--line-strong);
  border-radius: 2px;
  background: rgba(12, 12, 11, 0.64);
  background: color-mix(in srgb, var(--bg) 68%, transparent);
  color: var(--muted);
  font-size: 13px;
  pointer-events: auto;
  -webkit-backdrop-filter: blur(16px) saturate(120%);
  backdrop-filter: blur(16px) saturate(120%);
  transition:
    color 180ms ease,
    border-color 180ms ease,
    background-color 180ms ease;
}

.back-link:hover {
  color: var(--accent);
  border-color: var(--accent);
}

.article-share-slot {
  display: inline-flex;
  justify-content: flex-end;
  min-width: 96px;
  min-height: 44px;
  pointer-events: auto;
}

.article-page > .cf-wx-share-trigger {
  display: none;
}

.article-share-slot .cf-wx-share-trigger {
  position: static !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 9px 15px;
  border: 1px solid var(--line-strong);
  border-radius: 2px;
  background: rgba(12, 12, 11, 0.64);
  background: color-mix(in srgb, var(--bg) 68%, transparent);
  color: var(--muted);
  font-size: 12px;
  letter-spacing: 0.08em;
  -webkit-backdrop-filter: blur(16px) saturate(120%);
  backdrop-filter: blur(16px) saturate(120%);
}

.article-share-slot .cf-wx-share-trigger:hover,
.article-share-slot .cf-wx-share-trigger:focus-visible {
  color: var(--accent);
  border-color: var(--accent);
}

.article-header .article-category {
  margin-bottom: 20px;
}

.article-header h1 {
  max-width: 1080px;
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(42px, 6vw, 82px);
  font-weight: 600;
  letter-spacing: -0.055em;
  line-height: 1.17;
}

.article-header .byline {
  margin-top: 28px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.article-cover {
  width: min(1280px, calc(100vw - 64px));
  overflow: hidden;
  aspect-ratio: 16 / 9;
  margin: clamp(48px, 6vw, 86px) auto 0;
  background: var(--surface);
}

.article-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.article-body {
  width: var(--reading);
  margin: 0 auto;
  padding: clamp(70px, 9vw, 124px) 0 136px;
  font-family: var(--serif);
}

.article-body .standfirst {
  margin: 0 0 58px;
  padding-bottom: 44px;
  border-bottom: 1px solid var(--line-strong);
  color: var(--text);
  font-size: clamp(22px, 2.3vw, 30px);
  font-weight: 500;
  line-height: 1.75;
}

.article-body h2 {
  margin: 90px 0 34px;
  color: var(--text);
  font-size: clamp(28px, 3.3vw, 42px);
  font-weight: 650;
  letter-spacing: -0.035em;
  line-height: 1.35;
}

.article-body p {
  margin: 0 0 30px;
  color: color-mix(in srgb, var(--text) 91%, var(--muted));
  font-size: clamp(18px, 1.65vw, 21px);
  letter-spacing: 0.012em;
  line-height: 2.05;
}

.article-body strong {
  color: var(--text);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 2px;
  text-underline-offset: 6px;
}

.article-body .key-line {
  margin: 64px -44px;
  padding: 30px 0 30px 42px;
  border-left: 3px solid var(--accent);
  color: var(--text);
  font-size: clamp(22px, 2.5vw, 32px);
  font-weight: 600;
  line-height: 1.75;
}

.article-body .ending {
  margin-top: 70px;
  color: var(--text);
  font-size: clamp(24px, 2.8vw, 36px);
  font-weight: 600;
  line-height: 1.7;
}

.wechat-follow {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 196px;
  align-items: center;
  gap: clamp(30px, 5vw, 68px);
  width: var(--reading);
  margin: 0 auto 76px;
  padding: clamp(28px, 4vw, 42px);
  border: 1px solid var(--line);
  border-top-color: var(--accent);
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--surface) 92%, transparent), color-mix(in srgb, var(--bg) 82%, transparent));
}

.wechat-follow-kicker {
  margin: 0 0 12px;
  color: var(--accent);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.28em;
}

.wechat-follow h2 {
  margin: 0;
  color: var(--text);
  font-family: var(--serif);
  font-size: clamp(25px, 3vw, 34px);
  font-weight: 650;
  letter-spacing: -0.025em;
  line-height: 1.35;
}

.wechat-follow-copy > p:not(.wechat-follow-kicker) {
  margin: 18px 0 0;
  color: var(--muted);
  font-family: var(--serif);
  font-size: 16px;
  line-height: 1.85;
}

.wechat-follow-copy .wechat-follow-hint {
  color: var(--faint);
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: 0.04em;
}

.wechat-follow-code {
  justify-self: end;
  width: 196px;
  padding: 10px;
  background: #fff;
  box-shadow: 0 18px 50px color-mix(in srgb, var(--bg) 32%, transparent);
}

.wechat-follow-code img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
}

.article-end {
  width: var(--reading);
  margin: 0 auto 120px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}

.article-end p {
  margin: 0 0 18px;
  color: var(--faint);
  font-size: 13px;
}

.article-end a {
  color: var(--text);
  font-family: var(--serif);
  font-size: 18px;
}

.stats-main {
  width: var(--page);
  margin: 0 auto;
  padding: clamp(58px, 8vw, 112px) 0 120px;
}

.stats-intro {
  display: grid;
  grid-template-columns: minmax(240px, 0.75fr) minmax(360px, 1.25fr);
  gap: clamp(48px, 8vw, 128px);
  align-items: end;
  padding-bottom: clamp(48px, 7vw, 86px);
  border-bottom: 1px solid var(--line);
}

.stats-intro h1 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(64px, 9vw, 124px);
  font-weight: 600;
  letter-spacing: -0.08em;
  line-height: 0.92;
}

.stats-intro-copy > p {
  max-width: 36em;
  margin: 0;
  color: var(--muted);
  font-family: var(--serif);
  font-size: clamp(18px, 1.7vw, 23px);
  line-height: 1.85;
}

.stats-intro-copy .stats-privacy {
  margin-top: 22px;
  color: var(--faint);
  font-family: var(--sans);
  font-size: 13px;
  line-height: 1.7;
}

.stats-intro-copy .stats-status {
  margin-top: 18px;
  color: var(--gold);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
}

.stats-status.is-error {
  color: var(--accent);
}

.stats-overview {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 44px 0;
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.stats-number-card {
  min-height: 220px;
  padding: clamp(24px, 3vw, 38px);
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(150deg, color-mix(in srgb, var(--surface) 88%, transparent), transparent);
}

.stats-number-card p,
.stats-kicker {
  margin: 0;
  color: var(--gold);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.18em;
}

.stats-number-card strong {
  display: block;
  margin: 35px 0 18px;
  font-family: var(--serif);
  font-size: clamp(44px, 5.4vw, 78px);
  font-weight: 500;
  letter-spacing: -0.06em;
  line-height: 0.9;
  font-variant-numeric: tabular-nums;
}

.stats-number-card > span {
  color: var(--faint);
  font-size: 12px;
  line-height: 1.6;
}

.stats-panel {
  margin-top: 32px;
  padding: clamp(28px, 4vw, 48px);
  border: 1px solid var(--line);
  background: color-mix(in srgb, var(--surface) 74%, transparent);
}

.stats-panel-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 34px;
}

.stats-panel-head h2 {
  margin: 8px 0 0;
  font-family: var(--serif);
  font-size: clamp(28px, 3.4vw, 44px);
  font-weight: 600;
  letter-spacing: -0.035em;
}

.stats-panel-head > span,
.stats-panel-head > time {
  color: var(--faint);
  font-family: var(--mono);
  font-size: 11px;
}

.stats-chart {
  display: grid;
  grid-template-columns: repeat(14, minmax(18px, 1fr));
  gap: clamp(5px, 1vw, 13px);
  height: 300px;
  padding-top: 16px;
  border-bottom: 1px solid var(--line-strong);
}

.stats-day {
  display: grid;
  grid-template-rows: 24px 1fr 30px;
  gap: 8px;
  min-width: 0;
}

.stats-day-value {
  overflow: hidden;
  color: var(--faint);
  font-family: var(--mono);
  font-size: 9px;
  text-align: center;
  text-overflow: ellipsis;
}

.stats-day-track {
  position: relative;
  overflow: hidden;
  min-height: 140px;
  background:
    linear-gradient(to top, color-mix(in srgb, var(--line) 48%, transparent), transparent 70%);
}

.stats-day-bar {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  min-height: 3px;
  background: linear-gradient(to top, var(--accent), var(--gold));
  transition: height 700ms var(--ease);
}

.stats-day time {
  overflow: hidden;
  color: var(--faint);
  font-family: var(--mono);
  font-size: 9px;
  text-align: center;
  white-space: nowrap;
}

.stats-ranking {
  border-top: 1px solid var(--line);
}

.stats-rank-row {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) auto;
  gap: 22px;
  align-items: center;
  min-height: 106px;
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
  transition: color 180ms ease, padding 240ms var(--ease);
}

.stats-rank-row:hover,
.stats-rank-row:focus-visible {
  padding-right: 12px;
  padding-left: 12px;
  color: var(--gold);
}

.stats-rank-order {
  color: var(--faint);
  font-family: var(--mono);
  font-size: 12px;
}

.stats-rank-copy {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.stats-rank-copy strong {
  overflow: hidden;
  font-family: var(--serif);
  font-size: clamp(18px, 2vw, 25px);
  font-weight: 600;
  line-height: 1.4;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stats-rank-copy > span {
  overflow: hidden;
  color: var(--faint);
  font-family: var(--mono);
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stats-rank-metrics {
  display: flex;
  gap: 24px;
  color: var(--faint);
  font-size: 11px;
  white-space: nowrap;
}

.stats-rank-metrics span {
  display: grid;
  gap: 5px;
  text-align: right;
}

.stats-rank-metrics b {
  color: var(--text);
  font-family: var(--mono);
  font-size: 17px;
  font-weight: 500;
}

.stats-empty {
  margin: 0;
  padding: 44px 0;
  color: var(--faint);
  font-family: var(--serif);
  font-size: 17px;
}

.stats-note {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 38px;
  margin-top: 32px;
  padding: 30px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.stats-note strong {
  color: var(--gold);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
}

.stats-note p {
  max-width: 54em;
  margin: 0;
  color: var(--faint);
  font-size: 13px;
  line-height: 1.8;
}

@keyframes reading-progress {
  to {
    transform: scaleX(1);
  }
}

@keyframes intro-in {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: no-preference) {
  .home-intro,
  .science-intro,
  .article-waterfall,
  .article-header > :not(.article-tools),
  .article-cover {
    animation: intro-in 720ms var(--ease) both;
  }

  .article-waterfall,
  .article-header h1 {
    animation-delay: 90ms;
  }

  .article-header .byline,
  .article-cover {
    animation-delay: 160ms;
  }
}

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

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

@media (min-width: 681px) {
  .article-waterfall:has(.article-card:nth-child(2)) .article-card-body {
    padding: clamp(22px, 2.1vw, 30px);
  }

  .article-waterfall:has(.article-card:nth-child(2)) .article-card-title {
    font-size: clamp(25px, 2.15vw, 32px);
    line-height: 1.3;
  }

  .article-waterfall:has(.article-card:nth-child(2)) .article-preview {
    grid-template-columns: 1fr;
    gap: 12px;
    margin-top: 24px;
    padding-top: 20px;
    font-size: 15px;
  }
}

@media (max-width: 960px) {
  :root {
    --page: min(100% - 40px, 760px);
  }

  .home-hero {
    grid-template-columns: 1fr;
    gap: 46px;
    min-height: auto;
    padding: 56px 0 82px;
  }

  .home-intro {
    padding-top: 0;
  }

  .home-lead {
    max-width: 32em;
  }

  .about-inner {
    grid-template-columns: 0.7fr 1.3fr;
  }

  .stats-overview {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .topics {
    grid-column: 2;
    writing-mode: horizontal-tb;
  }
}

@media (max-width: 680px) {
  :root {
    --page: calc(100vw - 32px);
    --reading: calc(100vw - 36px);
  }

  .site-header {
    grid-template-columns: 1fr auto auto;
    min-height: 64px;
    padding: 0 16px;
  }

  .brand-name {
    font-size: 16px;
  }

  .brand-seal {
    width: 29px;
    height: 29px;
    font-size: 16px;
  }

  .menu-toggle {
    display: block;
    padding: 10px 14px;
    color: var(--muted);
    font-size: 13px;
  }

  .site-nav {
    position: absolute;
    top: 64px;
    left: 0;
    display: none;
    width: 100%;
    padding: 22px 16px 26px;
    border-bottom: 1px solid var(--line);
    background: var(--bg);
    gap: 18px 24px;
    flex-wrap: wrap;
  }

  .site-nav.is-open {
    display: flex;
  }

  .theme-toggle {
    font-size: 13px;
  }

  .theme-divider {
    width: 14px;
  }

  .home-hero {
    gap: 42px;
    padding: 48px 0 72px;
  }

  .home-intro h1 {
    font-size: clamp(56px, 18vw, 76px);
  }

  .home-lead {
    margin: 24px 0 28px;
    font-size: 18px;
  }

  .science-archive {
    padding: 58px 0 88px;
  }

  .section-back {
    top: calc(env(safe-area-inset-top, 0px) + 76px);
    left: 16px;
    min-height: 42px;
    padding: 8px 12px;
  }

  .science-intro {
    margin-bottom: 38px;
  }

  .science-intro h1 {
    font-size: clamp(56px, 18vw, 76px);
  }

  .science-lead {
    margin-top: 22px;
    font-size: 18px;
  }

  .article-card-title {
    font-size: 29px;
    line-height: 1.3;
  }

  .article-card-body .byline {
    display: grid;
    grid-template-columns: auto auto;
  }

  .article-card-body .byline time {
    grid-column: 1 / -1;
  }

  .article-preview {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .article-waterfall:has(.article-card:nth-child(2)),
  .article-waterfall:has(.article-card:nth-child(3)) {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .about-inner {
    grid-template-columns: 1fr;
    gap: 28px;
    padding: 72px 0;
  }

  .stats-main {
    padding: 52px 0 82px;
  }

  .stats-intro {
    grid-template-columns: 1fr;
    gap: 34px;
    padding-bottom: 48px;
  }

  .stats-intro h1 {
    font-size: clamp(62px, 22vw, 88px);
  }

  .stats-intro-copy > p {
    font-size: 18px;
  }

  .stats-overview {
    grid-template-columns: 1fr 1fr;
    margin: 28px 0;
  }

  .stats-number-card {
    min-height: 168px;
    padding: 22px 18px;
  }

  .stats-number-card strong {
    margin: 26px 0 14px;
    font-size: clamp(38px, 13vw, 56px);
  }

  .stats-panel {
    margin-top: 20px;
    padding: 24px 18px;
  }

  .stats-panel-head {
    display: grid;
    gap: 10px;
    margin-bottom: 26px;
  }

  .stats-chart {
    gap: 4px;
    height: 238px;
    overflow-x: auto;
    grid-template-columns: repeat(14, minmax(22px, 1fr));
    scrollbar-width: none;
  }

  .stats-chart::-webkit-scrollbar {
    display: none;
  }

  .stats-rank-row {
    grid-template-columns: 32px minmax(0, 1fr);
    gap: 12px;
    min-height: 0;
  }

  .stats-rank-copy strong {
    white-space: normal;
  }

  .stats-rank-metrics {
    grid-column: 2;
    justify-content: flex-start;
  }

  .stats-rank-metrics span {
    display: flex;
    align-items: baseline;
    gap: 6px;
    text-align: left;
  }

  .stats-note {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .about-copy p {
    font-size: 17px;
  }

  .topics {
    grid-column: 1;
  }

  .site-footer {
    grid-template-columns: 1fr;
    gap: 18px;
    padding: 44px 0;
  }

  .site-footer .copyright {
    justify-self: start;
  }

  .article-header {
    width: calc(100vw - 36px);
    padding-top: 78px;
  }

  .article-tools {
    top: calc(env(safe-area-inset-top, 0px) + 72px);
    left: 12px;
    right: 12px;
    gap: 12px;
  }

  .back-link,
  .article-share-slot .cf-wx-share-trigger {
    min-height: 42px;
    padding: 8px 12px;
  }

  .article-header h1 {
    font-size: clamp(38px, 11vw, 54px);
    letter-spacing: -0.045em;
    line-height: 1.2;
  }

  .article-header .byline {
    display: grid;
    grid-template-columns: auto auto;
    margin-top: 24px;
    padding-top: 18px;
  }

  .article-header .byline time {
    grid-column: 1 / -1;
  }

  .article-cover {
    width: calc(100vw - 24px);
    margin-top: 42px;
  }

  .article-body {
    padding: 68px 0 96px;
  }

  .article-body .standfirst {
    margin-bottom: 50px;
    padding-bottom: 36px;
    font-size: 21px;
  }

  .article-body h2 {
    margin: 70px 0 28px;
    font-size: 30px;
  }

  .article-body p {
    margin-bottom: 26px;
    font-size: 18px;
    line-height: 2;
  }

  .article-body .key-line {
    margin: 52px 0;
    padding: 24px 0 24px 22px;
    font-size: 22px;
  }

  .article-body .ending {
    font-size: 25px;
  }

  .wechat-follow {
    grid-template-columns: 1fr;
    gap: 28px;
    margin-bottom: 58px;
    padding: 26px 22px;
  }

  .wechat-follow-code {
    justify-self: center;
    width: min(190px, 68vw);
  }

  .article-end {
    margin-bottom: 88px;
  }
}
