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

:root{
  --ink:#000000;
  --paper:#ffffff;
  --mint:#00ff80;
  --blue:#0000ff;
}

*,*::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:Inter,system-ui,-apple-system,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans SC",sans-serif;
  font-size:17px;
  line-height:1.62;
  font-weight:400;
  -webkit-font-smoothing:antialiased;
}

h1,h2,h3,h4{
  font-weight:700;
  line-height:1.15;
  letter-spacing:-.02em;
  margin:0;
}

p{margin:0 0 16px}

a{color:var(--blue);text-decoration:none}
a:hover{text-decoration:underline;text-decoration-thickness:2px;text-underline-offset:3px}

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

/* 顶栏 */
.top{
  position:sticky;
  top:0;
  z-index:30;
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:6px 14px;
  padding:10px 18px;
  background:var(--paper);
  border-bottom:3px solid var(--ink);
}

.brand{
  display:inline-flex;
  align-items:center;
  gap:9px;
  min-height:44px;
  padding-right:14px;
  border-right:3px solid var(--ink);
  font-size:18px;
  font-weight:700;
  letter-spacing:-.02em;
  color:var(--ink);
}
.brand:hover{text-decoration:none}

.brand-mark{
  width:14px;
  height:14px;
  flex:none;
  background:var(--mint);
  border:3px solid var(--ink);
}

.top-nav{
  display:flex;
  flex-wrap:wrap;
  gap:4px;
  flex:1 1 auto;
  min-width:0;
}
.top-nav a{
  display:inline-flex;
  align-items:center;
  gap:7px;
  min-height:42px;
  padding:8px 9px;
  font-size:16px;
  font-weight:600;
  color:var(--ink);
  border:2px solid transparent;
}
.top-nav a:hover{
  background:var(--mint);
  border-color:var(--ink);
  text-decoration:none;
}

.dot{
  width:7px;
  height:7px;
  flex:none;
  background:var(--blue);
}

.ring{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:44px;
  padding:10px 16px;
  background:var(--mint);
  border:3px solid var(--ink);
  color:var(--ink);
  font-size:16px;
  font-weight:700;
}
.ring:hover{
  background:var(--blue);
  color:var(--paper);
  text-decoration:none;
}

/* 主体网格 */
.stage{
  display:grid;
  grid-template-columns:minmax(0,1fr) 286px;
  gap:0 34px;
  align-items:start;
  max-width:1200px;
  margin:0 auto;
  padding:0 18px 64px;
}

.stage > article{
  padding:46px 0;
  border-top:3px solid var(--ink);
  scroll-margin-top:112px;
}

.stage > .hero{
  grid-column:1 / -1;
  border-top:0;
  padding:30px 0;
  min-height:58vh;
}

.hero{
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:20px;
  text-align:center;
}

.hero-art{
  margin:0;
  border:0;
}
.hero-art svg{width:116px;height:116px}

.hero-copy h1,
.stage h1{
  font-size:clamp(31px,5.2vw,56px);
  line-height:1.06;
  letter-spacing:-.035em;
  margin:0;
}

/* 正文排版 */
.stage > article h2{
  font-size:clamp(23px,3.2vw,36px);
  margin:0 0 18px;
}
.stage > article h3{
  font-size:20px;
  margin:26px 0 10px;
}

.stage > article small{
  display:inline-block;
  margin-bottom:10px;
  padding:3px 9px;
  background:var(--ink);
  color:var(--mint);
  font-size:13px;
  font-weight:700;
  letter-spacing:.14em;
  line-height:1.5;
}

.stage > article p,
.stage > article li{max-width:66ch}

.stage > article ul,
.stage > article ol{
  margin:0 0 18px;
  padding-left:22px;
}
.stage > article li{margin-bottom:9px}

.stage > article strong{
  background:var(--mint);
  padding:0 3px;
  font-weight:700;
}

.stage > article blockquote{
  margin:18px 0;
  padding:12px 16px;
  border-left:6px solid var(--blue);
  background:#f2f2f2;
}

.stage > article figure{
  margin:22px 0;
  padding:10px;
  border:3px solid var(--ink);
}
.stage > article figcaption{
  margin-top:8px;
  font-size:14px;
}
.stage > article img{
  border:3px solid var(--ink);
}

.stage > article a{
  text-decoration:underline;
  text-underline-offset:3px;
}

.stage > article aside{
  margin:22px 0;
  padding:14px 16px;
  border:3px solid var(--ink);
  background:#fafafa;
}

/* 右侧目录 */
.rail{
  grid-column:2;
  grid-row:2;
  align-self:start;
  margin-top:44px;
  padding:14px 14px 18px;
  border:3px solid var(--ink);
  background:var(--paper);
}
.rail small{
  display:block;
  margin-bottom:2px;
  font-size:13px;
  font-weight:700;
  letter-spacing:.16em;
  color:var(--blue);
}
.rail h2{
  font-size:21px;
  margin:0 0 12px;
  padding-bottom:10px;
  border-bottom:3px solid var(--ink);
}

.rail-list{
  list-style:none;
  margin:0;
  padding:0;
  counter-reset:r;
}
.rail-list li{
  counter-increment:r;
  border-top:2px solid #e4e4e4;
}
.rail-list li:first-child{border-top:0}
.rail-list a{
  display:flex;
  align-items:baseline;
  gap:9px;
  min-height:42px;
  padding:9px 0;
  color:var(--ink);
  font-size:16px;
  font-weight:600;
}
.rail-list a::before{
  content:counter(r,decimal-leading-zero);
  flex:none;
  font-size:13px;
  font-weight:700;
  color:var(--blue);
}
.rail-list a:hover{
  background:var(--mint);
  text-decoration:none;
}

/* 页脚 */
.foot{
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:10px 22px;
  padding:22px 18px;
  background:var(--ink);
  color:var(--paper);
  border-top:4px solid var(--mint);
}

.foot-brand a{
  display:inline-flex;
  align-items:center;
  min-height:42px;
  color:var(--paper);
  font-size:17px;
  font-weight:700;
  border-bottom:3px solid var(--mint);
}
.foot-brand a:hover{
  color:var(--mint);
  text-decoration:none;
}

.foot-nav{
  flex:1 1 auto;
  min-width:0;
}
.foot-dl{
  display:flex;
  flex-wrap:wrap;
  gap:0 16px;
  margin:0;
}
.foot-dl dt,
.foot-dl dd{margin:0}
.foot-dl dd{display:none}
.foot-dl a{
  display:inline-flex;
  align-items:center;
  min-height:40px;
  padding:8px 0;
  color:var(--mint);
  font-size:16px;
  font-weight:600;
}

.foot-copy{
  font-size:16px;
  color:var(--paper);
  opacity:.9;
}

/* 动效 */
@keyframes pop{
  from{opacity:0;transform:translateY(10px)}
  to{opacity:1;transform:none}
}

.hero-art{animation:pop .24s steps(3) both}
.hero-copy{animation:pop .24s steps(3) .06s both}
.rail-list li{animation:pop .2s steps(2) both}
.rail-list li:nth-child(1){animation-delay:.03s}
.rail-list li:nth-child(2){animation-delay:.07s}
.rail-list li:nth-child(3){animation-delay:.11s}
.rail-list li:nth-child(4){animation-delay:.15s}
.rail-list li:nth-child(5){animation-delay:.19s}
.rail-list li:nth-child(6){animation-delay:.23s}
.rail-list li:nth-child(7){animation-delay:.27s}

/* 窄屏 */
@media (max-width:900px){
  .stage{grid-template-columns:minmax(0,1fr)}
  .rail{
    grid-column:1;
    grid-row:auto;
    margin:0 0 38px;
  }
}

@media (max-width:760px){
  body{font-size:16px}
  .top{gap:6px 10px;padding:9px 12px}
  .brand{font-size:17px}
  .top-nav{
    flex-basis:100%;
    order:3;
    flex-wrap:nowrap;
    overflow-x:auto;
    scrollbar-width:none;
  }
  .top-nav::-webkit-scrollbar{display:none}
  .top-nav a{white-space:nowrap}
  .stage{padding:0 12px 50px}
  .stage > .hero{min-height:30vh;padding:22px 0;gap:14px}
  .hero-art svg{width:84px;height:84px}
  .stage > article{padding:34px 0;scroll-margin-top:98px}
  .stage > article h2{font-size:23px}
  .foot{flex-direction:column;align-items:flex-start;gap:6px}
}

@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}
