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

:root {
  --ink: #000000;
  --paper: #ffffff;
  --soft: #f2f2f2;
  --mute: #4a4a4a;
  --rail: 238px;
  --disp: "Space Grotesk", "Helvetica Neue", Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
  --prose: Georgia, "Songti SC", "SimSun", "Times New Roman", serif;
}

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

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--disp);
  font-size: 17px;
  line-height: 1.6;
  overflow-x: hidden;
}

menu {
  margin: 0;
  padding: 0;
  list-style: none;
}

a { color: inherit; }

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

/* ---------- 左侧固定栏 ---------- */
.rail {
  position: fixed;
  inset: 0 auto 0 0;
  width: var(--rail);
  z-index: 40;
  display: flex;
  flex-direction: column;
  gap: 26px;
  padding: 30px 20px 26px;
  background: var(--paper);
  border-right: 3px solid var(--ink);
}

.mark {
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-decoration: none;
  min-height: 44px;
}

.mark-rule {
  display: block;
  height: 14px;
  background: var(--ink);
}

.mark-txt {
  font-weight: 700;
  font-size: 1.28rem;
  line-height: 1.14;
  letter-spacing: -0.02em;
}

.menu { position: relative; }

.menu summary {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 6px 12px;
  border: 2px solid var(--ink);
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  cursor: pointer;
  list-style: none;
  user-select: none;
}

.menu summary::-webkit-details-marker { display: none; }

.bars {
  display: block;
  width: 16px;
  height: 10px;
  border-top: 2px solid var(--ink);
  border-bottom: 2px solid var(--ink);
}

.menu[open] summary { background: var(--ink); color: var(--paper); }
.menu[open] .bars { border-color: var(--paper); }

.menu menu {
  margin-top: 10px;
  display: grid;
  gap: 2px;
}

.menu menu a {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 8px 10px;
  font-size: 0.95rem;
  line-height: 1.3;
  text-decoration: none;
  border-bottom: 1px solid #d8d8d8;
  transition: background 0.15s ease, padding-left 0.2s ease;
}

.menu menu a::before {
  content: "";
  flex: 0 0 auto;
  width: 7px;
  height: 7px;
  background: var(--ink);
}

.menu menu a:hover,
.menu menu a:focus-visible {
  background: var(--soft);
  padding-left: 16px;
}

.num {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--mute);
}

.reach {
  margin-top: auto;
  border-top: 6px solid var(--ink);
  padding-top: 12px;
  display: grid;
  gap: 4px;
}

.reach-k {
  font-size: 0.72rem;
  letter-spacing: 0.24em;
  color: var(--mute);
}

.reach a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-weight: 700;
  font-size: 1.05rem;
  text-decoration: none;
  border-bottom: 3px solid var(--ink);
  width: max-content;
  max-width: 100%;
}

/* ---------- 主体 ---------- */
.stage {
  margin-left: var(--rail);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.hero {
  position: relative;
  min-height: 45vh;
  display: grid;
  place-content: center;
  text-align: center;
  padding: 58px 20px;
  border-bottom: 3px solid var(--ink);
  overflow: hidden;
}

.hero h1 {
  margin: 0;
  font-size: clamp(2.4rem, 8vw, 5.6rem);
  line-height: 0.94;
  font-weight: 700;
  letter-spacing: -0.035em;
  max-width: 15ch;
}

.stamp {
  position: absolute;
  top: 16px;
  right: 16px;
  transform: rotate(5deg);
  background: var(--ink);
  color: var(--paper);
  padding: 7px 12px;
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  max-width: 60%;
}

.body { flex: 1 0 auto; }

.zhengwen {
  max-width: 74ch;
  margin: 0 auto;
  padding: clamp(26px, 5vw, 60px) clamp(18px, 4vw, 46px);
  font-family: var(--prose);
  font-size: 1.06rem;
  line-height: 1.78;
  overflow-wrap: break-word;
}

.pull {
  margin: 0 0 clamp(22px, 4vw, 38px);
  padding: 18px 0 18px 22px;
  border-left: 12px solid var(--ink);
  font-family: var(--disp);
  font-size: clamp(1.16rem, 2.4vw, 1.5rem);
  line-height: 1.34;
  font-weight: 600;
  letter-spacing: -0.015em;
}

.pull p { margin: 0; }

.eyebrow {
  display: block;
  margin-bottom: 8px;
  font-family: var(--disp);
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
}

.zhengwen h2 {
  margin: 0 0 clamp(20px, 4vw, 34px);
  padding-bottom: 14px;
  border-bottom: 4px solid var(--ink);
  font-family: var(--disp);
  font-size: clamp(1.7rem, 4vw, 2.6rem);
  line-height: 1.04;
  letter-spacing: -0.03em;
  font-weight: 700;
}

.zhengwen > article {
  padding: clamp(24px, 4vw, 42px) 0;
  border-top: 1px solid var(--ink);
}

.zhengwen > article:first-of-type { border-top: 0; padding-top: 0; }

.zhengwen > article[id] { scroll-margin-top: 92px; }

.zhengwen h3 {
  font-family: var(--disp);
  font-size: 1.3rem;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin: 1.8em 0 0.7em;
}

.zhengwen p { margin: 0 0 1.05em; }

.zhengwen > article:first-of-type > p:first-of-type::first-letter {
  float: left;
  font-family: var(--disp);
  font-size: 3.5em;
  line-height: 0.82;
  font-weight: 700;
  padding: 0.04em 0.1em 0 0;
}

.zhengwen blockquote {
  margin: 1.4em 0;
  padding: 12px 18px;
  background: var(--soft);
  border-left: 6px solid var(--ink);
  font-style: normal;
}

.zhengwen blockquote p:last-child { margin-bottom: 0; }

.zhengwen ul,
.zhengwen ol { padding-left: 1.3em; margin: 0 0 1.1em; }

.zhengwen li { margin-bottom: 0.5em; }

.zhengwen figure { margin: 1.4em 0; }

.zhengwen img { max-width: 100%; height: auto; display: block; }

.zhengwen figcaption {
  margin-top: 8px;
  font-family: var(--disp);
  font-size: 0.82rem;
  color: var(--mute);
  border-top: 1px solid var(--ink);
  padding-top: 6px;
}

.zhengwen a {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.zhengwen table { width: 100%; border-collapse: collapse; font-size: 0.96rem; }
.zhengwen th,
.zhengwen td { border: 1px solid var(--ink); padding: 8px 10px; text-align: left; }

/* ---------- 页脚 ---------- */
footer {
  margin-top: auto;
  border-top: 3px solid var(--ink);
  padding: 22px clamp(18px, 4vw, 46px);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px 28px;
  font-size: 0.9rem;
}

.f-brand b {
  display: inline-block;
  font-size: 1rem;
  letter-spacing: -0.01em;
  border-bottom: 3px solid var(--ink);
  padding-bottom: 4px;
}

.f-nav menu {
  display: flex;
  flex-wrap: wrap;
  gap: 2px 18px;
}

.f-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  text-decoration: none;
  border-bottom: 1px solid transparent;
}

.f-nav a:hover,
.f-nav a:focus-visible { border-bottom-color: var(--ink); }

.f-copy { color: var(--mute); letter-spacing: 0.02em; }

/* ---------- 动效 ---------- */
.js .rv {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s cubic-bezier(0.2, 0.7, 0.3, 1);
}

.js .rv.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .rv { opacity: 1; transform: none; transition: none; }
}

/* ---------- 窄屏 ---------- */
@media (max-width: 900px) {
  .rail {
    position: sticky;
    inset: 0 0 auto 0;
    width: auto;
    flex-direction: row;
    align-items: center;
    gap: 14px;
    padding: 10px 14px;
    border-right: 0;
    border-bottom: 3px solid var(--ink);
  }

  .mark { gap: 6px; flex: 1 1 auto; min-width: 0; }
  .mark-rule { height: 8px; width: 56px; }
  .mark-txt { font-size: 1rem; }

  .menu[open] > menu {
    position: absolute;
    left: 12px;
    right: 12px;
    top: 100%;
    margin-top: 0;
    padding: 8px 12px 12px;
    background: var(--paper);
    border: 3px solid var(--ink);
    border-top: 0;
    z-index: 50;
    max-height: 70vh;
    overflow-y: auto;
  }

  .stage { margin-left: 0; }

  .reach { margin-top: 0; border-top: 0; padding-top: 0; }
  .reach-k { display: none; }
  .reach a { font-size: 0.92rem; min-height: 44px; border-bottom-width: 2px; }

  .hero { min-height: 40vh; padding: 46px 18px; }
  .hero h1 { font-size: clamp(2.1rem, 10vw, 3.4rem); }
  .stamp { font-size: 0.68rem; padding: 6px 10px; top: 12px; right: 12px; }

  .zhengwen { font-size: 1.02rem; }

  footer { justify-content: flex-start; }
  .f-copy { width: 100%; text-align: center; }
}

@media (max-width: 420px) {
  .mark-txt { font-size: 0.92rem; }
  .menu summary { padding: 6px 10px; letter-spacing: 0.04em; }
}
`

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