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

:root{
  --blue:#3bb1ff;
  --red:#ff5252;
  --ink:#000;
  --bg:#f2f8ff;
  --paper:#fff;
  --soft-blue:#d9eeff;
  --soft-red:#ffe0e0;
  --ln:3px solid var(--ink);
  --sh:6px 6px 0 var(--ink);
  --r:28px;
}

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

html{scroll-behavior:smooth}

body{
  margin:0;
  background:var(--bg);
  color:var(--ink);
  font-family:Inter,"PingFang SC","Hiragino Sans GB","Microsoft YaHei",system-ui,sans-serif;
  font-size:17px;
  line-height:1.75;
  padding-bottom:158px;
  overflow-x:hidden;
}

h1,h2,h3,h4,.mark-txt,.foot-addr strong{
  font-family:Calistoga,Inter,"PingFang SC","Hiragino Sans GB","Microsoft YaHei",serif;
  font-weight:400;
  letter-spacing:.01em;
}

a:focus-visible,button:focus-visible,input:focus-visible{
  outline:3px solid var(--red);
  outline-offset:2px;
}

@keyframes fadeUp{
  from{opacity:0;transform:translateY(10px)}
  to{opacity:1;transform:none}
}

/* ---------- 底部固定条 ---------- */
.dock{
  position:fixed;
  left:0;right:0;bottom:0;
  z-index:50;
  display:flex;
  align-items:center;
  gap:10px;
  padding:8px 12px calc(8px + env(safe-area-inset-bottom,0px));
  background:var(--paper);
  border-top:var(--ln);
  box-shadow:0 -6px 0 var(--blue);
}

.dock-mark{
  flex:0 0 auto;
  display:grid;
  place-items:center;
  width:46px;height:46px;
  background:var(--blue);
  border:var(--ln);
  border-radius:14px;
  box-shadow:3px 3px 0 var(--ink);
  color:var(--ink);
  text-decoration:none;
  overflow:hidden;
  animation:fadeUp .3s both;
}
.dock-mark img{width:100%;height:100%;object-fit:cover;display:block}
.mark-txt{font-size:18px;line-height:1}

.dock-line{
  flex:1 1 auto;
  min-width:0;
  display:flex;
  gap:8px;
  padding:2px 2px 6px;
  overflow-x:auto;
  scrollbar-width:none;
  scroll-snap-type:x proximity;
}
.dock-line::-webkit-scrollbar{display:none}

.dock-a{
  flex:0 0 auto;
  scroll-snap-align:start;
  display:inline-flex;
  align-items:center;
  gap:7px;
  min-height:44px;
  padding:8px 13px;
  background:var(--paper);
  border:2px solid var(--ink);
  border-radius:14px;
  box-shadow:3px 3px 0 var(--ink);
  color:var(--ink);
  font-size:16px;
  font-weight:700;
  text-decoration:none;
  white-space:nowrap;
  transition:transform .12s ease,box-shadow .12s ease,background .12s ease,color .12s ease;
  animation:fadeUp .32s both;
}
.dock-a:nth-child(2){animation-delay:.04s}
.dock-a:nth-child(3){animation-delay:.08s}
.dock-a:nth-child(4){animation-delay:.12s}
.dock-a:nth-child(5){animation-delay:.16s}
.dock-a:nth-child(6){animation-delay:.2s}
.dock-a:nth-child(7){animation-delay:.24s}
.dock-a:hover{transform:translate(-2px,-2px);box-shadow:5px 5px 0 var(--ink);background:var(--soft-blue)}
.dock-a.on{background:var(--red);color:#fff}

.ico{
  flex:0 0 auto;
  width:12px;height:12px;
  border:2px solid var(--ink);
  border-radius:2px;
  background:var(--blue);
}
.ico.v1{background:var(--red);border-radius:50%}
.ico.v2{background:var(--paper);transform:rotate(45deg)}

/* ---------- 主区 ---------- */
.shell{
  max-width:1140px;
  margin:0 auto;
  padding:0 16px 36px;
  display:grid;
  grid-template-columns:1fr;
  gap:22px;
}

/* ---------- 侧栏 ---------- */
.rail{
  order:2;
  background:var(--paper);
  border:var(--ln);
  border-radius:20px;
  box-shadow:5px 5px 0 var(--ink);
  padding:14px 16px 16px;
}
.eyebrow{
  display:inline-block;
  background:var(--ink);
  color:#fff;
  font-size:16px;
  font-weight:700;
  line-height:1.4;
  padding:2px 10px;
  border-radius:999px;
}
.rail-h{
  font-size:21px;
  line-height:1.3;
  margin:10px 0 6px;
}
.rail-list{
  list-style:none;
  margin:0;
  padding:0;
  display:grid;
  gap:2px;
}
.rail-list li{animation:fadeUp .38s both}
.rail-list li:nth-child(2){animation-delay:.05s}
.rail-list li:nth-child(3){animation-delay:.1s}
.rail-list li:nth-child(4){animation-delay:.15s}
.rail-list li:nth-child(5){animation-delay:.2s}
.rail-list li:nth-child(6){animation-delay:.25s}
.rail-list li:nth-child(7){animation-delay:.3s}
.rail-list a{
  display:block;
  min-height:40px;
  padding:9px 6px;
  border-bottom:2px solid var(--soft-blue);
  color:var(--ink);
  font-size:16px;
  font-weight:600;
  text-decoration:none;
  transition:background .12s ease,border-color .12s ease,padding-left .12s ease;
}
.rail-list a:hover{background:var(--soft-red);border-bottom-color:var(--red);padding-left:12px}

/* ---------- 正文 ---------- */
.doc{min-width:0}

.hero{
  min-height:70vh;
  display:grid;
  gap:16px;
  align-content:center;
  text-align:right;
  padding:26px 0 8px;
}
.hero-art{
  justify-self:end;
  width:106px;
  aspect-ratio:1/1;
  display:grid;
  place-items:center;
  background:var(--blue);
  border:var(--ln);
  border-radius:22px;
  box-shadow:var(--sh);
  overflow:hidden;
}
.hero-art img{width:100%;height:100%;object-fit:cover;display:block}
.hero-star{font-size:46px;line-height:1;color:var(--ink)}
.hero-h1{
  margin:0;
  font-size:clamp(2.1rem,9vw,3.5rem);
  line-height:1.22;
}
.hero-sub{
  margin:12px 0 0 auto;
  max-width:44ch;
  font-size:17px;
  line-height:1.7;
}

.doc > div{
  margin:0 0 26px;
  padding:24px 18px;
  background:var(--paper);
  border-radius:var(--r);
  box-shadow:var(--sh);
  scroll-margin-top:20px;
  scroll-margin-bottom:120px;
}
.doc > div:nth-of-type(3n+1){background:var(--soft-blue)}
.doc > div:nth-of-type(3n+2){background:var(--soft-red)}

.doc > div h2{
  font-size:clamp(1.35rem,4.7vw,1.85rem);
  line-height:1.32;
  margin:0 0 12px;
}
.doc > div h3{
  font-size:1.16rem;
  line-height:1.4;
  margin:22px 0 8px;
}
.doc > div p{margin:0 0 14px}
.doc > div p:last-child{margin-bottom:0}
.doc > div ul,.doc > div ol{margin:0 0 14px;padding-left:1.3em}
.doc > div li{margin-bottom:6px}
.doc > div a{
  color:var(--ink);
  font-weight:600;
  text-decoration:underline;
  text-decoration-thickness:3px;
  text-decoration-color:var(--red);
  text-underline-offset:2px;
}
.doc > div a:hover{background:var(--ink);color:#fff;text-decoration-color:var(--blue)}
.doc > div strong{font-weight:800}
.doc > div img{
  max-width:100%;
  height:auto;
  display:block;
  border:var(--ln);
  border-radius:18px;
  box-shadow:4px 4px 0 var(--ink);
  background:var(--paper);
}
.doc > div figure{margin:0 0 14px}
.doc > div blockquote{
  margin:0 0 14px;
  padding:12px 16px;
  border-left:7px solid var(--red);
  background:var(--paper);
  border-radius:14px;
}
.doc > div blockquote p:last-child{margin-bottom:0}
.doc > div table{
  width:100%;
  border-collapse:collapse;
  font-size:16px;
  margin:0 0 14px;
  background:var(--paper);
}
.doc > div th,.doc > div td{
  border:2px solid var(--ink);
  padding:8px 10px;
  text-align:left;
  vertical-align:top;
}
.doc > div th{background:var(--blue);font-weight:700}
.doc > div hr{border:0;border-top:3px solid var(--ink);margin:20px 0}
.doc > div code,.doc > div pre{
  font-family:"JetBrains Mono",ui-monospace,SFMono-Regular,Menlo,monospace;
  font-size:15px;
}

/* ---------- 页脚 ---------- */
.foot{
  margin-top:44px;
  padding:30px 16px 36px;
  background:var(--ink);
  color:#fff;
  border-top:6px solid var(--blue);
}
.foot-top{
  max-width:1140px;
  margin:0 auto;
  display:grid;
  gap:22px;
}
.foot-addr{font-style:normal;display:block;margin:0}
.foot-addr strong{
  display:block;
  font-size:1.5rem;
  line-height:1.3;
  color:#fff;
  margin-bottom:8px;
}
.foot-addr span{display:block;font-size:16px;line-height:1.7;color:#e6f4ff}

.foot-nav dl{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:2px 18px;
  margin:0;
}
.foot-nav dt{margin:0}
.foot-nav a{
  display:inline-block;
  min-height:40px;
  padding:9px 0;
  color:#fff;
  font-size:16px;
  font-weight:600;
  text-decoration:none;
  border-bottom:2px solid var(--red);
}
.foot-nav a:hover{color:var(--blue);border-bottom-color:var(--blue)}

.foot-form{
  max-width:1140px;
  margin:24px auto 0;
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:10px;
  padding:14px;
  background:var(--paper);
  color:var(--ink);
  border:var(--ln);
  border-radius:20px;
  box-shadow:5px 5px 0 var(--blue);
}
.foot-form label{font-size:16px;font-weight:700}
.foot-form input{
  flex:1 1 190px;
  min-width:0;
  min-height:44px;
  padding:11px 13px;
  font:inherit;
  font-size:16px;
  color:var(--ink);
  background:#fff;
  border:2px solid var(--ink);
  border-radius:12px;
}
.foot-form button{
  flex:0 0 auto;
  min-height:44px;
  padding:11px 22px;
  font:inherit;
  font-size:16px;
  font-weight:800;
  color:#fff;
  background:var(--ink);
  border:2px solid var(--ink);
  border-radius:12px;
  box-shadow:3px 3px 0 var(--blue);
  cursor:pointer;
  transition:transform .12s ease,box-shadow .12s ease,background .12s ease,color .12s ease;
}
.foot-form button:hover{transform:translate(-2px,-2px);box-shadow:5px 5px 0 var(--blue);background:var(--blue);color:var(--ink)}

.foot-bot{
  max-width:1140px;
  margin:26px auto 0;
  padding-top:16px;
  border-top:2px solid #3d3d3d;
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  justify-content:space-between;
  gap:10px 20px;
  font-size:16px;
}
.copy{margin:0}
.foot-links{
  list-style:none;
  display:flex;
  flex-wrap:wrap;
  gap:8px 18px;
  margin:0;
  padding:0;
}
.foot-links a{
  display:inline-block;
  min-height:40px;
  padding:8px 0;
  color:#fff;
  font-weight:600;
  text-decoration:none;
  border-bottom:2px solid var(--blue);
}
.foot-links a:hover{color:var(--blue)}

/* ---------- 宽屏 ---------- */
@media (min-width:700px){
  .hero{
    grid-template-columns:150px minmax(0,1fr);
    align-items:center;
    gap:26px;
  }
  .hero-art{width:150px;justify-self:center;border-radius:26px}
  .hero-star{font-size:64px}
  .doc > div{padding:34px 32px;margin-bottom:34px}
}

@media (min-width:760px){
  .foot-top{grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:42px;align-items:start}
  .foot-form{padding:18px}
}

@media (min-width:820px){
  body{padding-bottom:112px}
  .dock{justify-content:center;gap:14px;padding:10px 20px calc(10px + env(safe-area-inset-bottom,0px))}
  .dock-line{flex:0 1 auto;overflow:visible;padding-bottom:2px}
  .dock-mark{width:48px;height:48px}
}

@media (min-width:900px){
  .shell{
    grid-template-columns:258px minmax(0,1fr);
    gap:30px;
    padding-top:26px;
  }
  .rail{order:1;position:sticky;top:22px}
}

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