@import url('https://fonts.googleapis.com/css2?family=Kalam:wght@400;700&family=Patrick+Hand&display=swap');

:root{
  --ink:#1f1f1f;
  --paper:#ffffff;
  --ash:#f5f5f5;
  --muted:#565656;
  --r:10px;
  --e1:0 1px 0 rgba(31,31,31,.85);
  --e2:0 6px 16px -10px rgba(31,31,31,.5);
  --e3:0 14px 30px -16px rgba(31,31,31,.55);
  --e4:0 30px 60px -30px rgba(31,31,31,.6);
  --hand:'Patrick Hand','Kalam','PingFang SC','Hiragino Sans GB','Microsoft YaHei',system-ui,-apple-system,sans-serif;
  --head:126px;
}

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

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

body{
  margin:0;
  background:var(--ash);
  color:var(--ink);
  font-family:var(--hand);
  font-size:17px;
  line-height:1.75;
  letter-spacing:.01em;
  overflow-x:hidden;
}

img{max-width:100%}

a{color:var(--ink)}

.sr{
  position:absolute;
  width:1px;height:1px;
  overflow:hidden;
  clip-path:inset(50%);
  white-space:nowrap;
}

/* ---------- 顶部两行 ---------- */
.top{
  position:sticky;
  top:0;
  z-index:60;
  background:rgba(255,255,255,.84);
  backdrop-filter:blur(12px) saturate(1.15);
  border-bottom:1px solid var(--ink);
  box-shadow:var(--e2);
}

.top__row1{
  display:flex;
  align-items:center;
  padding:8px clamp(14px,4vw,30px);
  border-bottom:1px dashed rgba(31,31,31,.28);
}

.brand{
  display:inline-flex;
  align-items:center;
  gap:10px;
  min-height:44px;
  text-decoration:none;
  color:var(--ink);
  font-size:23px;
  line-height:1;
  letter-spacing:.02em;
}

.brand__mark{
  width:34px;height:34px;
  border:1px solid var(--ink);
  border-radius:9px;
  background:var(--paper);
}

.brand__txt{position:relative;z-index:2}

.top__row2{
  display:flex;
  align-items:center;
  gap:8px;
  padding:6px clamp(10px,3vw,30px) 8px;
}

.menu{
  display:flex;
  align-items:center;
  gap:2px;
  flex:1 1 auto;
  min-width:0;
  overflow-x:auto;
  scrollbar-width:none;
  -webkit-overflow-scrolling:touch;
}

.menu::-webkit-scrollbar{display:none}

.menu__a{
  flex:0 0 auto;
  display:inline-flex;
  align-items:center;
  min-height:44px;
  padding:6px 11px;
  border-radius:8px;
  text-decoration:none;
  color:var(--ink);
  white-space:nowrap;
  font-size:16px;
  transition:background .2s ease,transform .2s ease;
}

.menu__a:hover,
.menu__a:focus-visible{
  background:var(--ash);
  transform:translateY(-1px);
}

.cta{
  flex:0 0 auto;
  display:inline-flex;
  align-items:center;
  min-height:44px;
  padding:6px 16px;
  border:1px solid var(--ink);
  border-radius:8px;
  background:var(--ink);
  color:var(--paper);
  text-decoration:none;
  font-size:16px;
  box-shadow:var(--e1);
  transition:transform .2s ease,box-shadow .2s ease;
}

.cta:hover,
.cta:focus-visible{
  transform:translateY(-2px);
  box-shadow:var(--e3);
}

/* ---------- 首屏 ---------- */
.hero{
  position:relative;
  z-index:1;
  display:grid;
  grid-template-columns:minmax(0,1.05fr) minmax(0,1fr);
  align-items:center;
  gap:clamp(24px,4vw,56px);
  min-height:100vh;
  min-height:calc(100vh - var(--head));
  padding:clamp(26px,6vw,70px) clamp(16px,5vw,64px);
  background:var(--paper);
  overflow:hidden;
}

.hero::before{
  content:"";
  position:absolute;
  right:-8vw;
  bottom:-14vw;
  width:56vw;
  height:56vw;
  background:var(--ash);
  border:1px solid rgba(31,31,31,.14);
  border-radius:28px;
  transform:rotate(-6deg);
  z-index:0;
}

.hero__media{
  position:relative;
  z-index:2;
  transform:rotate(-1.1deg);
}

.hero__frame{
  position:relative;
  padding:10px;
  background:var(--paper);
  border:1px solid var(--ink);
  border-radius:var(--r);
  box-shadow:var(--e4);
}

.hero__frame::after{
  content:"";
  position:absolute;
  inset:10px -14px -14px 10px;
  border:1px solid rgba(31,31,31,.22);
  border-radius:var(--r);
  z-index:-1;
}

.hero__img{
  display:block;
  width:100%;
  height:auto;
  border-radius:6px;
  border:1px solid rgba(31,31,31,.2);
}

.hero__ph{
  display:grid;
  place-items:center;
  aspect-ratio:4/3;
  padding:16px;
  border:1px dashed rgba(31,31,31,.5);
  border-radius:6px;
  background:var(--ash);
  text-align:center;
  font-size:clamp(19px,3vw,26px);
  line-height:1.3;
}

.hero__copy{
  position:relative;
  z-index:3;
  text-align:left;
}

.hero__h1{
  margin:0 0 .6rem;
  font-size:clamp(30px,5.2vw,56px);
  line-height:1.14;
  letter-spacing:.01em;
  text-wrap:balance;
}

.hero__h1::after{
  content:"";
  display:block;
  width:clamp(60px,14vw,140px);
  height:6px;
  margin-top:14px;
  background:var(--ink);
  border-radius:6px;
}

.hero__lead{
  margin:14px 0 0;
  max-width:36ch;
  color:var(--muted);
}

/* ---------- 主体 ---------- */
.shell{
  display:grid;
  grid-template-columns:minmax(198px,238px) minmax(0,1fr);
  gap:clamp(20px,3vw,40px);
  align-items:start;
  max-width:1180px;
  margin:0 auto;
  padding:clamp(26px,5vw,60px) clamp(14px,4vw,32px);
}

.rail{
  position:sticky;
  top:calc(var(--head) + 10px);
  z-index:3;
  padding:14px 12px 16px;
  background:var(--paper);
  border:1px solid var(--ink);
  border-radius:var(--r);
  box-shadow:var(--e2);
}

.rail__ttl{
  margin:0 0 10px;
  padding:0 4px 8px;
  border-bottom:1px dashed rgba(31,31,31,.35);
  font-size:16px;
  font-weight:400;
  letter-spacing:.06em;
}

.rail__list{
  margin:0;
  padding:0;
  list-style:none;
}

.rail__li + .rail__li{margin-top:2px}

.rail__a{
  display:flex;
  align-items:center;
  gap:9px;
  min-height:42px;
  padding:4px 6px;
  border-radius:8px;
  text-decoration:none;
  color:var(--ink);
  font-size:16px;
  transition:background .2s ease,padding-left .2s ease;
}

.rail__a:hover,
.rail__a:focus-visible{
  background:var(--ash);
  padding-left:11px;
}

.rail__num{
  flex:0 0 auto;
  font-style:normal;
  font-size:14px;
  color:var(--muted);
  letter-spacing:.05em;
}

/* 正文 */
.doc{
  position:relative;
  z-index:2;
  min-width:0;
}

.doc > section{
  position:relative;
  margin:0 0 clamp(16px,2.6vw,26px);
  padding:clamp(18px,3vw,32px);
  background:var(--paper);
  border:1px solid var(--ink);
  border-radius:var(--r);
  scroll-margin-top:calc(var(--head) + 16px);
  animation:rise .5s cubic-bezier(.2,.7,.3,1) both;
  transition:box-shadow .25s ease;
}

.doc > section:nth-child(odd){z-index:1}
.doc > section:nth-child(even){z-index:2}

.doc > section:hover{box-shadow:var(--e3)}

.doc > section:nth-child(1){animation-delay:.02s}
.doc > section:nth-child(2){animation-delay:.07s}
.doc > section:nth-child(3){animation-delay:.12s}
.doc > section:nth-child(4){animation-delay:.17s}
.doc > section:nth-child(5){animation-delay:.22s}
.doc > section:nth-child(6){animation-delay:.27s}
.doc > section:nth-child(n+7){animation-delay:.32s}

@keyframes rise{
  from{opacity:0;transform:translateY(16px)}
  to{opacity:1;transform:translateY(0)}
}

.doc h2{
  margin:0 0 .6em;
  font-size:clamp(22px,3vw,30px);
  line-height:1.3;
  font-weight:400;
  letter-spacing:.01em;
}

.doc h2 > span,
.doc h3 > span{
  border-bottom:3px solid var(--ink);
  padding-bottom:2px;
}

.doc h3{
  margin:1.4em 0 .5em;
  font-size:clamp(19px,2.3vw,23px);
  line-height:1.35;
  font-weight:400;
}

.doc p{margin:0 0 1em}
.doc p:last-child{margin-bottom:0}

.doc a{text-decoration:underline;text-underline-offset:3px}
.doc a:hover{background:var(--ash)}

.doc ul,
.doc ol{margin:0 0 1em;padding-left:1.35em}
.doc li{margin:.25em 0}

.doc blockquote{
  margin:0 0 1em;
  padding:12px 16px;
  border-left:4px solid var(--ink);
  background:var(--ash);
  border-radius:0 var(--r) var(--r) 0;
}

.doc code{
  font-family:ui-monospace,SFMono-Regular,Menlo,monospace;
  font-size:.94em;
  background:var(--ash);
  padding:1px 5px;
  border-radius:5px;
}

.doc img{
  display:block;
  height:auto;
  margin:0 0 1em;
  border:1px solid rgba(31,31,31,.28);
  border-radius:8px;
}

.doc table{
  display:block;
  width:100%;
  overflow-x:auto;
  border-collapse:collapse;
  margin:0 0 1em;
}

.doc th,
.doc td{
  border:1px solid rgba(31,31,31,.3);
  padding:8px 10px;
  text-align:left;
}

.doc hr{
  border:0;
  border-top:1px dashed rgba(31,31,31,.4);
  margin:1.4em 0;
}

/* ---------- 页脚 ---------- */
.foot{
  position:relative;
  z-index:5;
  display:grid;
  grid-template-columns:minmax(0,1.35fr) minmax(0,1fr) minmax(0,1fr);
  gap:clamp(22px,4vw,44px);
  margin-top:clamp(24px,5vw,56px);
  padding:clamp(28px,5vw,56px) clamp(16px,4vw,44px) 0;
  background:var(--ink);
  color:var(--paper);
  box-shadow:var(--e4);
}

.foot a{color:var(--paper)}

.foot__sec{
  position:relative;
  z-index:1;
  min-width:0;
}

.foot__sec h2{
  margin:0 0 12px;
  font-size:18px;
  font-weight:400;
  letter-spacing:.03em;
}

.foot__sec h2 > span{
  border-bottom:2px solid rgba(255,255,255,.55);
  padding-bottom:2px;
}

.foot__sec p{margin:0 0 10px}

.sub{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  margin-top:4px;
}

.sub input{
  flex:1 1 140px;
  min-width:0;
  min-height:44px;
  padding:8px 12px;
  font-family:inherit;
  font-size:16px;
  color:var(--paper);
  background:rgba(255,255,255,.08);
  border:1px solid rgba(255,255,255,.5);
  border-radius:8px;
}

.sub input::placeholder{color:rgba(255,255,255,.65)}

.sub button{
  flex:0 0 auto;
  min-height:44px;
  padding:8px 20px;
  font-family:inherit;
  font-size:16px;
  color:var(--ink);
  background:var(--paper);
  border:1px solid var(--paper);
  border-radius:8px;
  cursor:pointer;
  transition:transform .2s ease;
}

.sub button:hover{transform:translateY(-2px)}

.foot dl{margin:0}
.foot dt{
  margin:0 0 4px;
  font-size:14px;
  letter-spacing:.08em;
  color:rgba(255,255,255,.65);
}
.foot dd{margin:0}

.foot nav dd a,
.foot .quick a,
.foot .totop a{
  display:inline-flex;
  align-items:center;
  min-height:40px;
  padding-right:14px;
  text-decoration:none;
  font-size:16px;
}

.foot nav dd a:hover,
.foot .quick a:hover,
.foot .totop a:hover{text-decoration:underline}

.quick{
  display:flex;
  flex-wrap:wrap;
  gap:0 4px;
}

.foot__bar{
  grid-column:1 / -1;
  margin-top:6px;
  padding:12px 0 18px;
  border-top:1px solid rgba(255,255,255,.32);
  font-size:16px;
}

.foot__bar p{margin:0;color:rgba(255,255,255,.8)}

/* ---------- 断点 ---------- */
@media (min-width:861px){
  .doc > section:nth-child(even){margin-left:14px}
  .doc > section:nth-child(odd){margin-right:14px}
  .hero{min-height:calc(100vh - var(--head))}
}

@media (max-width:860px){
  :root{--head:120px}

  .hero{
    grid-template-columns:1fr;
    min-height:0;
    padding:clamp(22px,6vw,40px) clamp(14px,5vw,28px) clamp(26px,7vw,44px);
  }

  .hero__copy{order:1}
  .hero__media{order:2;transform:rotate(-.8deg)}
  .hero::before{display:none}
  .hero__ph{aspect-ratio:16/9}

  .shell{
    grid-template-columns:1fr;
    gap:18px;
    padding:clamp(18px,4vw,28px) clamp(12px,4vw,20px);
  }

  .rail{
    position:static;
    padding:12px;
    box-shadow:none;
  }

  .rail__list{
    display:flex;
    gap:6px;
    overflow-x:auto;
    scrollbar-width:none;
  }

  .rail__list::-webkit-scrollbar{display:none}

  .rail__li{flex:0 0 auto}
  .rail__li + .rail__li{margin-top:0}

  .rail__a{
    border:1px solid rgba(31,31,31,.28);
    border-radius:999px;
    padding:4px 12px;
  }

  .rail__a:hover{padding-left:12px;background:var(--ash)}

  .rail__num{font-size:13px}

  .doc > section:hover{box-shadow:none}

  .foot{grid-template-columns:1fr}
  .foot__bar{padding-bottom:22px}
}

@media (prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  .doc > section{animation:none}
  .menu__a,
  .cta,
  .rail__a,
  .sub button,
  .doc > section{transition:none}
}
</｜DSML｜ parameter>
</｜DSML｜ invoke>
</｜DSML｜ calls>

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