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

:root{
  --blue:#3bb1ff;
  --red:#ff5252;
  --ink:#000;
  --paper:#fff;
  --tint-b:#e4f5ff;
  --tint-r:#ffe8e8;
  --tint-y:#fff7d9;
  --rail:250px;
  --sh:5px 5px 0 #000;
  --sh-sm:3px 3px 0 #000;
  --body-font:'DM Sans','Space Grotesk',"PingFang SC","Hiragino Sans GB","Microsoft YaHei",system-ui,-apple-system,sans-serif;
  --head-font:'Space Grotesk','DM Sans',"PingFang SC","Hiragino Sans GB","Microsoft YaHei",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(--body-font);
  font-size:17px;
  line-height:1.75;
  overflow-x:hidden;
}

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

a{color:var(--ink)}

/* ---------- 左侧固定竖排导航 ---------- */
.rail{
  position:fixed;
  top:0;left:0;bottom:0;
  width:var(--rail);
  z-index:40;
  display:flex;
  flex-direction:column;
  gap:12px;
  padding:20px 16px;
  background:var(--blue);
  border-right:3px solid var(--ink);
  overflow-y:auto;
}

.rail-brand{
  display:flex;
  align-items:center;
  gap:10px;
  min-height:50px;
  padding:10px 12px;
  background:var(--paper);
  border:3px solid var(--ink);
  box-shadow:var(--sh-sm);
  font-family:var(--head-font);
  font-size:18px;
  font-weight:700;
  line-height:1.2;
  text-decoration:none;
}

.rail-brand img{width:30px;height:30px;object-fit:contain;flex:0 0 auto}

.rail ol{
  list-style:none;
  margin:0;
  padding:0;
  display:flex;
  flex-direction:column;
  gap:10px;
}

.rail ol a.pill{
  display:flex;
  align-items:center;
  min-height:46px;
  padding:10px 14px;
  background:var(--paper);
  border:3px solid var(--ink);
  box-shadow:4px 4px 0 var(--ink);
  font-size:16px;
  font-weight:700;
  line-height:1.2;
  text-decoration:none;
  transition:transform .12s ease,box-shadow .12s ease,background .12s ease;
}

.rail ol a.pill:hover,
.rail ol a.pill:focus-visible{
  transform:translate(2px,2px);
  box-shadow:2px 2px 0 var(--ink);
  background:var(--tint-y);
}

.rail ol a.pill[aria-current]{
  background:var(--red);
  color:var(--ink);
}

.rail-cta{
  margin-top:auto;
  display:flex;
  align-items:center;
  justify-content:center;
  min-height:50px;
  padding:12px 14px;
  background:var(--red);
  border:3px solid var(--ink);
  box-shadow:4px 4px 0 var(--ink);
  font-size:16px;
  font-weight:700;
  text-decoration:none;
  transition:transform .12s ease,box-shadow .12s ease;
}

.rail-cta:hover{transform:translate(2px,2px);box-shadow:2px 2px 0 var(--ink)}

/* ---------- 主栅格 ---------- */
main{display:block}

.wrap{
  max-width:1180px;
  margin:0 auto;
  padding:26px 22px 46px;
  display:grid;
  grid-template-columns:minmax(0,1fr) 292px;
  gap:26px;
  align-items:start;
}

/* ---------- Hero ---------- */
.hero{grid-column:1 / -1;margin:0}

.hero-card{
  position:relative;
  min-height:45vh;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:34px 22px;
  background:var(--blue);
  border:3px solid var(--ink);
  box-shadow:6px 6px 0 var(--ink);
  overflow:hidden;
}

.hero-media{position:absolute;inset:0;z-index:0}

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

.hero-veil{position:absolute;inset:0;z-index:1;background:rgba(0,0,0,.5)}

.hero-num{
  position:absolute;
  right:6px;
  bottom:-8px;
  z-index:2;
  font-family:var(--head-font);
  font-size:clamp(96px,20vw,210px);
  font-weight:700;
  line-height:.78;
  letter-spacing:-.05em;
  color:rgba(255,255,255,.38);
  pointer-events:none;
  user-select:none;
}

.hero-card.has-pic .hero-num{color:rgba(255,255,255,.5)}

.hero-txt{position:relative;z-index:3;text-align:center;max-width:26ch}

.hero-txt h1{
  margin:0;
  font-family:var(--head-font);
  font-size:clamp(28px,5vw,54px);
  font-weight:700;
  line-height:1.14;
  color:#fff;
  text-shadow:4px 4px 0 var(--ink);
  overflow-wrap:break-word;
}

/* ---------- 正文 ---------- */
.doc-sec{grid-column:1;min-width:0}

.doc > div{
  margin:0 0 26px;
  padding:24px 22px;
  background:var(--paper);
  box-shadow:var(--sh);
  scroll-margin-top:26px;
}

.doc > div:nth-of-type(3n+1){background:var(--tint-b)}
.doc > div:nth-of-type(3n+2){background:var(--tint-r)}
.doc > div:nth-of-type(3n+3){background:var(--tint-y)}

.doc h2{
  margin:0 0 10px;
  font-family:var(--head-font);
  font-size:clamp(22px,3vw,30px);
  font-weight:700;
  line-height:1.28;
}

.doc h3{
  margin:22px 0 8px;
  font-size:20px;
  font-weight:700;
  line-height:1.35;
}

.doc p{margin:0 0 14px}
.doc p:last-child{margin-bottom:0}

.doc ul,.doc ol{margin:0 0 14px;padding-left:24px}
.doc li{margin:0 0 8px}

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

.doc a:hover{background:var(--blue)}

.doc img{border:3px solid var(--ink);margin:14px 0}

.doc hr{height:4px;border:0;background:var(--ink);margin:4px 0 16px}

.doc blockquote{
  margin:16px 0;
  padding:12px 16px;
  background:#fff;
  border-left:8px solid var(--red);
  font-weight:500;
}

.doc time{
  display:inline-block;
  margin:0 0 12px;
  padding:3px 10px;
  background:var(--ink);
  color:#fff;
  font-size:16px;
  font-weight:700;
  line-height:1.5;
}

.doc table{width:100%;border-collapse:collapse;margin:0 0 16px;font-size:16px}
.doc th,.doc td{border:3px solid var(--ink);padding:8px 10px;text-align:left}
.doc th{background:var(--ink);color:#fff}
.doc pre{overflow-x:auto;padding:14px;background:var(--ink);color:#fff;border:3px solid var(--ink)}
.doc code{font-size:16px}

/* ---------- 右侧侧栏 ---------- */
.side{
  grid-column:2;
  position:sticky;
  top:24px;
  padding:18px 16px;
  background:var(--ink);
  color:#fff;
  box-shadow:var(--sh);
}

.side h2{
  margin:0 0 8px;
  font-family:var(--head-font);
  font-size:19px;
  font-weight:700;
  color:#fff;
}

.side hr{height:4px;border:0;background:var(--blue);margin:0 0 14px}

.side ol{
  list-style:none;
  margin:0;
  padding:0;
  display:flex;
  flex-direction:column;
  gap:8px;
}

.side li a{
  display:flex;
  align-items:center;
  min-height:44px;
  padding:9px 12px;
  background:var(--paper);
  font-size:16px;
  font-weight:700;
  line-height:1.25;
  text-decoration:none;
  transition:background .15s ease,transform .15s ease;
}

.side li a:hover{background:var(--blue);transform:translateX(3px)}

/* ---------- 页脚 ---------- */
footer{
  border-top:3px solid var(--ink);
  background:var(--paper);
}

footer > div{border-bottom:3px solid var(--ink)}

.foot-in{
  width:100%;
  max-width:1180px;
  margin:0 auto;
  padding:0 22px;
}

.foot-cta{background:var(--ink);color:#fff;padding:34px 0}

.foot-cta .foot-in{
  display:flex;
  flex-wrap:wrap;
  gap:16px;
  align-items:center;
  justify-content:space-between;
}

.foot-cta h2{
  margin:0;
  font-family:var(--head-font);
  font-size:clamp(24px,4.5vw,44px);
  font-weight:700;
  line-height:1.15;
  color:#fff;
  overflow-wrap:break-word;
}

.cta-btn{
  display:inline-flex;
  align-items:center;
  min-height:54px;
  padding:12px 24px;
  background:var(--red);
  color:var(--ink);
  border:3px solid #fff;
  box-shadow:5px 5px 0 #fff;
  font-size:17px;
  font-weight:700;
  text-decoration:none;
  transition:transform .12s ease,box-shadow .12s ease;
}

.cta-btn:hover{transform:translate(2px,2px);box-shadow:3px 3px 0 #fff}

.foot-cols{background:var(--blue);padding:32px 0}

.cols{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:26px;
  align-items:start;
}

.foot-brand{
  display:flex;
  align-items:center;
  gap:10px;
  font-family:var(--head-font);
  font-size:20px;
  font-weight:700;
  line-height:1.25;
}

.foot-brand img{width:34px;height:34px;object-fit:contain;flex:0 0 auto}

.foot-col h3{
  margin:0 0 10px;
  font-family:var(--head-font);
  font-size:17px;
  font-weight:700;
  line-height:1.4;
}

.foot-col ul{
  list-style:none;
  margin:0;
  padding:0;
  display:flex;
  flex-direction:column;
  gap:6px;
}

.foot-col a.pill{
  display:inline-flex;
  align-items:center;
  min-height:40px;
  padding:4px 2px;
  font-size:16px;
  font-weight:700;
  text-decoration:none;
  border-bottom:3px solid transparent;
}

.foot-col a.pill:hover{border-bottom-color:var(--ink)}

.foot-bottom{background:var(--paper);padding:16px 0}

.foot-bottom .bar{
  display:flex;
  flex-wrap:wrap;
  gap:10px 18px;
  align-items:center;
  justify-content:space-between;
}

.foot-bottom p{margin:0;font-size:16px;font-weight:600}

.foot-links{display:flex;flex-wrap:wrap;gap:8px 18px}

.foot-links a{
  display:inline-flex;
  align-items:center;
  min-height:40px;
  font-size:16px;
  font-weight:700;
  text-decoration:underline;
  text-decoration-thickness:3px;
  text-underline-offset:3px;
}

.foot-links a:hover{background:var(--tint-y)}

/* ---------- 动效 ---------- */
.js .reveal{
  opacity:0;
  transform:translateY(16px);
  transition:opacity .5s ease,transform .55s cubic-bezier(.2,.7,.4,1);
}

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

/* ---------- 断点 ---------- */
@media (max-width:1024px){
  body{padding-left:0}

  .rail{
    position:sticky;
    top:0;left:auto;bottom:auto;
    width:auto;
    flex-direction:row;
    align-items:center;
    gap:10px;
    padding:10px 12px;
    border-right:0;
    border-bottom:3px solid var(--ink);
    overflow-x:auto;
    overflow-y:hidden;
  }

  .rail-brand{
    flex:0 0 auto;
    min-height:44px;
    padding:8px 10px;
    font-size:16px;
    box-shadow:var(--sh-sm);
  }

  .rail-brand img{width:26px;height:26px}

  .rail ol{flex-direction:row;gap:8px}

  .rail ol a.pill{
    white-space:nowrap;
    min-height:44px;
    padding:8px 12px;
    box-shadow:var(--sh-sm);
  }

  .rail-cta{
    flex:0 0 auto;
    margin-top:0;
    min-height:44px;
    padding:8px 14px;
    box-shadow:var(--sh-sm);
  }

  .wrap{
    grid-template-columns:minmax(0,1fr);
    padding:18px 14px 36px;
    gap:18px;
  }

  .hero-card{
    min-height:46vh;
    align-items:flex-start;
    justify-content:flex-start;
    padding:26px 16px;
  }

  .hero-txt{text-align:left;max-width:100%}

  .doc > div{scroll-margin-top:130px;padding:20px 16px}

  .side{grid-column:1;position:static}

  .cols{grid-template-columns:minmax(0,1fr);gap:20px}

  .foot-cta{padding:26px 0}

  .foot-cta .foot-in{flex-direction:column;align-items:flex-start}

  .foot-bottom .bar{flex-direction:column;align-items:flex-start}
}

@media (max-width:560px){
  .hero-txt h1{text-shadow:3px 3px 0 var(--ink)}
  .doc > div{box-shadow:4px 4px 0 var(--ink)}
  .side{box-shadow:4px 4px 0 var(--ink)}
}

@media (prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  .js .reveal{opacity:1;transform:none;transition:none}
  .rail ol a.pill,.rail-cta,.side li a,.cta-btn{transition:none}
}

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