:root{
  --mint:#5cc6b0;
  --sand:#d4c4a8;
  --ink:#172623;
  --clay:#c67b5c;
  --paper:#f3ead9;
  --card:#fbf7ef;
  --line:#d8c9b0;
  --mono:"Fira Code","Share Tech Mono",ui-monospace,SFMono-Regular,Menlo,monospace;
  --sans:"PingFang SC","Hiragino Sans GB","Microsoft YaHei",system-ui,-apple-system,"Segoe UI",sans-serif;
  --r:4px;
}
*,*::before,*::after{box-sizing:border-box}
html{font-size:16px;-webkit-text-size-adjust:100%;scroll-behavior:smooth}
body{
  margin:0;
  font-family:var(--sans);
  font-size:1.0625rem;
  line-height:1.75;
  color:var(--ink);
  background:
    radial-gradient(1100px 620px at 88% -12%,#e8dabf 0%,rgba(232,218,191,0) 62%),
    radial-gradient(900px 520px at -8% 18%,#efe6d3 0%,rgba(239,230,211,0) 58%),
    var(--paper);
}
body::before{
  content:"";
  position:fixed;
  inset:0;
  z-index:2;
  pointer-events:none;
  opacity:.14;
  mix-blend-mode:multiply;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='150' height='150'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2'/%3E%3C/filter%3E%3Crect width='150' height='150' filter='url(%23n)'/%3E%3C/svg%3E");
}
img{max-width:100%;height:auto}
a{color:inherit}
:focus-visible{outline:2px solid var(--mint);outline-offset:3px}

/* 顶栏 */
.bar{
  position:relative;
  z-index:50;
  display:grid;
  grid-template-columns:1fr auto 1fr;
  align-items:center;
  gap:.6rem;
  padding:.45rem clamp(.7rem,3vw,1.6rem);
  border-bottom:1px solid var(--line);
  background:linear-gradient(180deg,#f8f1e4,#f1e7d4);
}
.logo{
  justify-self:center;
  display:inline-flex;
  align-items:center;
  gap:.5rem;
  min-height:44px;
  padding:.2rem .3rem;
  text-decoration:none;
  font-weight:700;
  letter-spacing:.02em;
  font-size:1.02rem;
  white-space:nowrap;
}
.logo img{width:30px;height:30px;border-radius:50%;object-fit:cover;border:1px solid var(--line)}
.drawer{justify-self:start}
.drawer > summary{
  list-style:none;
  cursor:pointer;
  display:inline-flex;
  align-items:center;
  gap:.5rem;
  min-height:44px;
  padding:.35rem .8rem;
  border:1px solid var(--line);
  border-radius:var(--r);
  background:var(--card);
  font-family:var(--mono);
  font-size:.8125rem;
  letter-spacing:.1em;
}
.drawer > summary::-webkit-details-marker{display:none}
.bars{position:relative;display:inline-block;width:15px;height:10px;border-top:2px solid var(--ink);border-bottom:2px solid var(--ink)}
.bars::after{content:"";position:absolute;left:0;right:0;top:2px;height:2px;background:var(--ink)}
.drv{
  position:absolute;
  z-index:70;
  top:100%;
  left:0;
  right:0;
  margin:.2rem 0 0;
  padding:.5rem;
  list-style:none;
  display:grid;
  gap:.12rem;
  background:var(--card);
  border:1px solid var(--line);
  border-bottom:4px solid var(--mint);
  border-radius:var(--r);
  box-shadow:0 22px 44px rgba(23,38,35,.2);
}
.drv a{
  display:flex;
  align-items:center;
  gap:.65rem;
  min-height:46px;
  padding:.3rem .7rem;
  border-radius:var(--r);
  text-decoration:none;
  font-size:1rem;
}
.drv a:hover{background:#f2e7d4}
.dot{flex:0 0 auto;width:8px;height:8px;border:2px solid var(--mint);border-radius:50%}
.call{
  justify-self:end;
  display:inline-flex;
  align-items:center;
  min-height:44px;
  padding:.35rem .85rem;
  border-radius:var(--r);
  border:1px solid #47ab97;
  background:var(--mint);
  color:#0d1e1a;
  text-decoration:none;
  font-family:var(--mono);
  font-size:.8125rem;
  letter-spacing:.1em;
}

/* 粘性锚点条 */
.tabs{
  position:sticky;
  top:0;
  z-index:46;
  background:rgba(243,234,217,.96);
  border-bottom:1px solid var(--line);
  backdrop-filter:blur(8px);
}
.tabs-in{
  display:flex;
  gap:.15rem;
  overflow-x:auto;
  padding:.3rem .6rem;
  scrollbar-width:none;
}
.tabs-in::-webkit-scrollbar{display:none}
.tabs-in a{
  flex:0 0 auto;
  display:inline-flex;
  align-items:center;
  min-height:40px;
  padding:0 .7rem;
  border-radius:var(--r);
  border-bottom:2px solid transparent;
  text-decoration:none;
  color:#25423b;
  font-size:.9rem;
  white-space:nowrap;
}
.tabs-in a:hover{border-bottom-color:var(--mint);background:#efe3cf}

/* 首屏 */
.hero{
  position:relative;
  display:flex;
  align-items:flex-start;
  min-height:100svh;
  overflow:hidden;
  clip-path:polygon(0 0,100% 0,100% calc(100% - 58px),0 100%);
  background:linear-gradient(158deg,#e6d7be,#f1e7d5 46%,#ddceb1);
}
.hero-media{position:absolute;inset:0;z-index:0;overflow:hidden}
.hero-img{display:block;width:100%;height:114%;object-fit:cover;will-change:transform;transform:translate3d(0,0,0) scale(1.06)}
.hero::after{
  content:"";
  position:absolute;
  inset:0;
  z-index:1;
  background:linear-gradient(104deg,rgba(243,234,217,.96) 0%,rgba(243,234,217,.8) 44%,rgba(23,38,35,.16) 100%);
}
.hero-in{
  position:relative;
  z-index:3;
  max-width:44rem;
  padding:clamp(1.6rem,8vh,5rem) clamp(1rem,5vw,4rem) 5.5rem;
}
.badge{
  display:inline-block;
  margin:0;
  padding:.35rem .85rem;
  background:var(--card);
  border:1px solid var(--line);
  border-bottom:3px solid var(--mint);
  border-radius:var(--r);
  font-family:var(--mono);
  font-size:.8125rem;
  letter-spacing:.12em;
  color:#2a4a42;
  clip-path:polygon(0 0,100% 0,100% 100%,7px 100%,0 calc(100% - 8px));
}
.hero h1{
  margin:.7rem 0 .9rem;
  font-size:clamp(1.95rem,6.2vw,3.5rem);
  line-height:1.2;
  letter-spacing:-.01em;
}
.lead{
  margin:0;
  max-width:30rem;
  font-size:1.05rem;
  line-height:1.7;
  color:#2c4a42;
}
.hero-down{
  position:absolute;
  z-index:4;
  left:clamp(1rem,5vw,4rem);
  bottom:4.4rem;
  width:48px;
  height:48px;
  display:grid;
  place-items:center;
  border-radius:50%;
  background:var(--ink);
  color:var(--paper);
  text-decoration:none;
  font-size:1.15rem;
}

/* 正文区 */
.wrap{
  max-width:1180px;
  margin:0 auto;
  padding:clamp(1.8rem,5vw,3.6rem) clamp(.85rem,4vw,2rem);
  display:grid;
  grid-template-columns:minmax(0,1fr) 268px;
  gap:clamp(1.4rem,3vw,3rem);
  align-items:start;
}
.post{max-width:64ch}
.post > div{
  scroll-margin-top:120px;
  margin:0 0 1.2rem;
  padding:clamp(1.05rem,3vw,1.9rem);
  background:var(--card);
  border:1px solid var(--line);
  border-bottom:3px solid var(--sand);
  border-radius:var(--r);
  box-shadow:0 10px 26px rgba(23,38,35,.06);
}
.post > div:nth-of-type(even){border-bottom-color:var(--mint)}
.post h2{
  margin:0 0 .8rem;
  font-size:clamp(1.28rem,2.6vw,1.72rem);
  line-height:1.35;
}
.post h2 > span{display:inline-block;padding-bottom:.16em;border-bottom:3px solid var(--mint)}
.post h3{margin:1.2rem 0 .5rem;font-size:1.16rem;line-height:1.4}
.post h3 > span{display:inline-block;padding-bottom:.14em;border-bottom:2px solid var(--sand)}
.post p{margin:0 0 1rem}
.post ul,.post ol{margin:0 0 1rem;padding-left:1.35rem}
.post li{margin:.25rem 0}
.post a{color:#1c6b5c;text-decoration:underline;text-decoration-color:var(--mint);text-underline-offset:3px}
.post strong{color:#0e201b}
.post blockquote{margin:1rem 0;padding:.6rem 1rem;border-left:4px solid var(--sand);background:#f6efe1;border-radius:0 var(--r) var(--r) 0}
.post img{border-radius:var(--r)}
.post table{display:block;width:100%;overflow-x:auto;border-collapse:collapse;font-size:.95rem}
.post th,.post td{border:1px solid var(--line);padding:.5rem .6rem;text-align:left}
.post > div:last-child{margin-bottom:0}

/* 侧栏 */
.rail{
  position:sticky;
  top:78px;
  padding:1rem 1rem 1.2rem;
  background:#efe4d0;
  border:1px solid var(--line);
  border-left:4px solid var(--mint);
  border-radius:var(--r);
}
.rail h2{
  margin:0 0 .6rem;
  font-family:var(--mono);
  font-size:.95rem;
  letter-spacing:.08em;
  line-height:1.5;
}
.rail h2 > span{display:inline-block;padding-bottom:.2em;border-bottom:2px solid var(--mint)}
.rail ol{list-style:none;counter-reset:r;margin:0;padding:0;display:grid}
.rail li{counter-increment:r}
.rail a{
  display:flex;
  align-items:baseline;
  gap:.55rem;
  min-height:40px;
  padding:.35rem .1rem;
  border-bottom:1px dashed var(--line);
  text-decoration:none;
  color:#22403a;
  font-size:.95rem;
}
.rail a::before{content:counter(r,decimal-leading-zero);font-family:var(--mono);font-size:.75rem;color:#7c6952}
.rail a:hover{color:#12483d}

/* 页脚 */
.foot{margin-top:2.5rem;background:#1c2e2a;color:#e9dec9;border-top:4px solid var(--mint)}
.foot-in{max-width:1180px;margin:0 auto;padding:clamp(1.8rem,5vw,3.2rem) clamp(.9rem,4vw,2rem) 1.1rem}
.foot-top{display:grid;grid-template-columns:1.15fr .85fr;gap:1.6rem;align-items:start}
.foot-brand h2{margin:0 0 .5rem;font-size:1.15rem;letter-spacing:.04em}
.foot-brand h2 > span{display:inline-block;padding-bottom:.2em;border-bottom:3px solid var(--mint)}
.foot-brand p{margin:0;font-family:var(--mono);font-size:.8125rem;letter-spacing:.1em;color:#a9bcb2}
.sub{display:flex;flex-wrap:wrap;gap:.5rem}
.sub input{
  flex:1 1 11rem;
  min-height:44px;
  padding:.45rem .8rem;
  border:1px solid #3c574f;
  border-radius:var(--r);
  background:#15241f;
  color:#eee3cf;
  font-family:var(--sans);
  font-size:1rem;
}
.sub input::placeholder{color:#8ea499}
.sub button{
  min-height:44px;
  padding:0 1.15rem;
  border:0;
  border-radius:var(--r);
  background:var(--mint);
  color:#10201c;
  font-family:var(--mono);
  font-size:.8125rem;
  letter-spacing:.1em;
  cursor:pointer;
}
.foot-cols{
  display:grid;
  grid-template-columns:minmax(0,.8fr) minmax(0,1.4fr);
  gap:1.2rem;
  margin-top:1.8rem;
  padding-top:1.4rem;
  border-top:1px solid #35504a;
}
.foot address{
  font-style:normal;
  font-family:var(--mono);
  font-size:.8125rem;
  letter-spacing:.06em;
  color:#afc0b6;
  word-break:break-all;
}
.foot-cols ul{list-style:none;margin:0;padding:0;display:flex;flex-wrap:wrap;gap:.1rem 1rem}
.foot-cols ul a{
  display:inline-flex;
  align-items:center;
  min-height:40px;
  color:#e3d8c4;
  text-decoration:none;
  font-size:.95rem;
  border-bottom:1px dashed #3c594f;
}
.foot-cols ul a:hover{color:var(--mint)}
.copy{
  margin:1.4rem 0 0;
  padding-top:.9rem;
  border-top:1px solid #35504a;
  font-family:var(--mono);
  font-size:.78rem;
  letter-spacing:.1em;
  color:#8fa69c;
}

.toTop{
  position:fixed;
  right:.85rem;
  bottom:.85rem;
  z-index:48;
  display:inline-flex;
  align-items:center;
  min-height:44px;
  padding:0 .9rem;
  border-radius:var(--r);
  border:1px solid #43635a;
  background:#16migrate;
  background:#16241f;
  color:#e9dec9;
  text-decoration:none;
  font-size:.85rem;
}

/* 动效 */
@keyframes rise{from{opacity:0;transform:translateY(10px)}to{opacity:1;transform:none}}
.tabs-in a,.rail li{animation:rise .5s cubic-bezier(.2,.75,.3,1) both}
.tabs-in a:nth-child(1),.rail li:nth-child(1){animation-delay:.02s}
.tabs-in a:nth-child(2),.rail li:nth-child(2){animation-delay:.06s}
.tabs-in a:nth-child(3),.rail li:nth-child(3){animation-delay:.1s}
.tabs-in a:nth-child(4),.rail li:nth-child(4){animation-delay:.14s}
.tabs-in a:nth-child(5),.rail li:nth-child(5){animation-delay:.18s}
.tabs-in a:nth-child(6),.rail li:nth-child(6){animation-delay:.22s}
.tabs-in a:nth-child(7),.rail li:nth-child(7){animation-delay:.26s}

/* 桌面：抽屉展开为横向菜单 */
@media (min-width:1000px){
  .bar{grid-template-columns:1fr auto 1fr;padding:.4rem clamp(1rem,3vw,1.8rem)}
  .drawer{position:relative}
  .drawer > summary{display:none}
  .drv{
    position:static;
    display:flex;
    flex-wrap:wrap;
    gap:.1rem;
    max-width:min(600px,50vw);
    margin:0;
    padding:0;
    border:0;
    background:transparent;
    box-shadow:none;
  }
  .drv a{
    min-height:44px;
    padding:0 .55rem;
    border:1px solid transparent;
    font-size:.9rem;
  }
  .drv a:hover{background:var(--card);border-color:var(--line)}
  .drv .dot{display:none}
}

/* 中屏 */
@media (max-width:980px){
  .wrap{grid-template-columns:minmax(0,1fr)}
  .rail{position:static;order:2}
  .foot-top{grid-template-columns:minmax(0,1fr)}
  .foot-cols{grid-template-columns:minmax(0,1fr)}
  .hero{min-height:80svh}
}
@media (max-width:640px){
  .logo{font-size:.98rem}
  .logo img{width:26px;height:26px}
  .hero{min-height:74svh}
  .hero-in{padding-top:2.4rem}
  .hero-down{bottom:3.6rem;width:44px;height:44px}
  .foot-cols ul{gap:.1rem .8rem}
}

@media (prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  *,*::before,*::after{animation:none!important;transition:none!important}
  .hero-img{transform:none!important}
}

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