@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&family=Righteous&display=swap');

:root {
  --paper: #fdfbf7;
  --panel: #f5f5f5;
  --ink: #1a1a1a;
  --line: #e0e0e0;
  --sub: #6a6862;
  --rail: 272px;
  --ui: "Poppins", system-ui, -apple-system, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  --read: Georgia, "Songti SC", "Source Han Serif SC", "Noto Serif SC", serif;
  --display: "Righteous", "Poppins", system-ui, sans-serif;
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  padding-left: var(--rail);
  background: var(--paper);
  color: var(--ink);
  font-family: var(--read);
  font-size: 17px;
  line-height: 1.8;
  text-rendering: optimizeLegibility;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 70;
  pointer-events: none;
  opacity: .05;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
}

a { color: var(--ink); text-decoration-thickness: 1px; text-underline-offset: 3px; }

:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}

img { max-width: 100%; height: auto; }

/* ---------- 左侧竖排栏 ---------- */

.rail {
  position: fixed;
  inset: 0 auto 0 0;
  width: var(--rail);
  z-index: 40;
  display: flex;
  flex-direction: column;
  gap: 26px;
  padding: 30px 20px 24px;
  overflow-y: auto;
  background: var(--paper);
  border-right: 1px solid var(--line);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  padding: 6px 4px;
  min-height: 44px;
}

.mark {
  flex: none;
  width: 26px;
  height: 26px;
  display: block;
  border-radius: 4px;
  background: var(--ink);
}

img.mark { object-fit: cover; }

.brand-name {
  font-family: var(--display);
  font-size: 19px;
  line-height: 1.15;
  letter-spacing: .01em;
}

.rail-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line);
}

.rail-nav li {
  border-bottom: 1px solid var(--line);
  animation: slide .18s steps(3, end) both;
  animation-delay: calc(var(--i) * 35ms);
}

.rail-nav li[hidden] { display: none; }

@keyframes slide {
  from { transform: translateX(-6px); }
  to { transform: none; }
}

.rail-nav a {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 10px 10px;
  font-family: var(--ui);
  font-size: 16px;
  font-weight: 500;
  line-height: 1.4;
  color: var(--ink);
  text-decoration: none;
  border-radius: 0;
  transition: none;
}

.rail-nav a:hover,
.rail-nav a:focus-visible {
  background: var(--ink);
  color: var(--paper);
}

.mk {
  flex: none;
  display: block;
  width: 4px;
  height: 16px;
  background: currentColor;
}

.find { margin-top: auto; }

.find input {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  font-family: var(--ui);
  font-size: 16px;
  color: var(--ink);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 4px;
  appearance: none;
}

.find input::placeholder { color: var(--sub); }

/* ---------- 首屏 ---------- */

.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 18px;
  padding: 72px clamp(20px, 5vw, 64px) 0;
  border-bottom: 1px solid var(--line);
}

.hero h1 {
  margin: 0;
  max-width: 24ch;
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(2rem, 5.2vw, 4rem);
  line-height: 1.12;
  letter-spacing: .005em;
}

.hero .lead {
  margin: 0;
  max-width: 56ch;
  font-size: 16px;
  line-height: 1.85;
  color: var(--sub);
}

.hero-fig {
  margin: auto 0 0;
  padding-top: 34px;
  width: 100%;
  max-width: 940px;
}

.hero-img {
  display: block;
  width: 100%;
  height: min(50vh, 440px);
  object-fit: cover;
  border: 1px solid var(--line);
  border-bottom: 0;
  border-radius: 4px 4px 0 0;
  filter: saturate(.92) contrast(1.03);
}

/* ---------- 正文 ---------- */

main { display: block; }

article { display: block; }

article > section {
  padding: 72px clamp(20px, 5vw, 72px);
  border-top: 1px solid var(--line);
  scroll-margin-top: 28px;
  animation: rise .26s steps(4, end) both;
}

article > section:first-of-type { border-top: 0; }

@keyframes rise {
  from { transform: translateY(10px); }
  to { transform: none; }
}

article > section small {
  display: block;
  margin: 0 0 6px;
  font-family: var(--ui);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .22em;
  color: var(--sub);
}

article > section h2 {
  margin: 0 0 20px;
  max-width: 30ch;
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(1.5rem, 3.3vw, 2.05rem);
  line-height: 1.28;
}

article > section h2::before {
  content: "";
  display: block;
  width: 48px;
  height: 4px;
  margin-bottom: 16px;
  background: var(--ink);
}

div > section h3 {
  margin: 34px 0 12px;
  font-family: var(--ui);
  font-size: 18px;
  font-weight: 600;
  line-height: 1.5;
}

div > section p,
div > section ul,
div > section ol,
div > section blockquote {
  max-width: 66ch;
}

div > section p { margin: 0 0 1.1em; color: #22211f; }

div > section ul,
div > section ol {
  margin: 0 0 1.2em;
  padding-left: 1.3em;
}

div > section li { margin: 0 0 .5em; }

div > section blockquote {
  margin: 26px 0;
  padding: 4px 0 4px 18px;
  border-left: 4px solid var(--ink);
  color: var(--sub);
}

div > section figure { margin: 26px 0; }

div > section figcaption {
  margin-top: 8px;
  font-family: var(--ui);
  font-size: 13px;
  color: var(--sub);
}

div > section img { border-radius: 4px; }

div > section table {
  width: 100%;
  max-width: 66ch;
  margin: 0 0 1.4em;
  border-collapse: collapse;
  font-size: 16px;
}

div > section th,
div > section td {
  padding: 10px 12px;
  text-align: left;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

div > section th {
  font-family: var(--ui);
  font-size: 14px;
  letter-spacing: .06em;
  border-bottom: 2px solid var(--ink);
}

/* ---------- 页脚 ---------- */

.tail { display: block; }

.cta {
  padding: 56px clamp(20px, 5vw, 72px) 60px;
  background: var(--ink);
  color: var(--paper);
}

.cta small {
  display: block;
  margin: 0 0 10px;
  font-family: var(--ui);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .22em;
  color: #b6b2aa;
}

.cta h2 {
  margin: 0;
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(1.9rem, 5.5vw, 3.4rem);
  line-height: 1.15;
}

.cta h2 a { color: var(--paper); text-decoration: none; }
.cta h2 a:hover { text-decoration: underline; }

.tail-row {
  display: flex;
  align-items: center;
  gap: 22px;
  padding: 22px clamp(20px, 5vw, 72px) 34px;
  border-top: 1px solid var(--line);
  font-family: var(--ui);
  font-size: 15px;
}

.tail-brand {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 44px;
  text-decoration: none;
  font-family: var(--display);
  font-size: 17px;
}

.tail-brand .mark { width: 22px; height: 22px; }

.tail-nav { flex: 1 1 auto; }

.tail-nav ul {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px 6px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.tail-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 10px;
  text-decoration: none;
  color: var(--ink);
  border-radius: 4px;
}

.tail-nav a:hover,
.tail-nav a:focus-visible {
  background: var(--ink);
  color: var(--paper);
}

.cr {
  margin: 0;
  flex: none;
  color: var(--sub);
  font-size: 14px;
}

/* ---------- 移动端 ---------- */

@media (max-width: 900px) {
  body { padding-left: 0; }

  .rail {
    position: sticky;
    top: 0;
    inset: auto;
    width: auto;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 10px;
    padding: 10px 14px;
    overflow: visible;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    background: var(--paper);
  }

  .rail .brand { flex: 1 1 auto; padding: 4px 0; min-height: 40px; }

  .find {
    order: 2;
    flex: 0 0 auto;
    width: 116px;
    margin-top: 0;
  }

  .find input { min-height: 40px; padding: 8px 10px; font-size: 16px; }

  .rail-nav {
    order: 3;
    flex: 1 1 100%;
    width: 100%;
    overflow-x: auto;
  }

  .rail-nav ul {
    display: flex;
    gap: 4px;
    border-top: 0;
  }

  .rail-nav li { border-bottom: 0; }

  .rail-nav a {
    padding: 11px 13px;
    min-height: 44px;
    white-space: nowrap;
  }

  .hero {
    min-height: 0;
    padding: 34px 16px 0;
    gap: 14px;
  }

  .hero h1 { font-size: clamp(1.7rem, 7.4vw, 2.5rem); }

  .hero-fig { padding-top: 22px; }

  .hero-img { height: 200px; }

  div > section {
    padding: 44px 18px;
    scroll-margin-top: 108px;
  }

  div > section h2 { font-size: 1.55rem; }

  .cta { padding: 42px 18px 46px; }

  .tail-row {
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 22px 16px 30px;
    text-align: center;
  }

  .tail-nav { flex: 1 1 auto; width: 100%; }
  .tail-nav ul { justify-content: center; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }
}

button[aria-expanded]{min-width:44px;min-height:44px}
