:root{
  --mint:#b4fde1;
  --blue:#add8e6;
  --ink:#172620;
  --paper:#f6fffc;
  --panel:#ffffff;
  --r-xl:24px;
  --r-lg:20px;
  --bs-in:inset -3px -3px 10px rgba(23,38,32,.12);
  --bs-out:6px 7px 18px rgba(23,38,32,.16);
}

*{ box-sizing:border-box; }

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

body{
  margin:0;
  min-height:100vh;
  font-family:'Atkinson Hyperlegible', system-ui, -apple-system, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  font-size:17px;
  line-height:1.75;
  color:var(--ink);
  background:
    radial-gradient(circle at 90% 6%, #e0f6ff 0, transparent 44%),
    radial-gradient(circle at 4% 92%, #dcfff1 0, transparent 42%),
    var(--paper);
  background-attachment:fixed;
}

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

a{ color:#0f5f47; }

a:focus-visible,
button:focus-visible{
  outline:3px solid #2a7f63;
  outline-offset:3px;
}

.shell{
  display:flex;
  flex-direction:column;
  min-height:100vh;
}

main{ flex:1 1 auto; }

/* ---------- 左栏 ---------- */
.rail{
  margin:12px;
  padding:16px 14px 18px;
  display:flex;
  flex-direction:column;
  gap:12px;
  border:3px solid var(--ink);
  border-radius:var(--r-xl);
  background:linear-gradient(168deg,#d9fff3 0%,#cdeefa 60%,#d7fbf0 100%);
  box-shadow:var(--bs-in), var(--bs-out);
}

.rail-brand{
  padding-bottom:12px;
  border-bottom:3px dashed rgba(23,38,32,.28);
}

.logo{
  display:inline-flex;
  align-items:center;
  gap:10px;
  min-height:44px;
  padding:4px 2px;
  text-decoration:none;
  font-size:1.06rem;
  font-weight:700;
  letter-spacing:.01em;
}

.logo-img{
  width:40px;
  height:40px;
  border:3px solid var(--ink);
  border-radius:14px;
  background:#fff;
}

.eyebrow{
  display:block;
  font-size:.72rem;
  font-weight:700;
  letter-spacing:.26em;
  color:#1f6a53;
  margin-bottom:-6px;
}

.rail-h2{
  margin:0;
  font-size:1rem;
  letter-spacing:.04em;
}

.rail-nav ol{
  list-style:none;
  margin:0;
  padding:0;
}

.rail-nav a{
  display:flex;
  align-items:center;
  min-height:44px;
  padding:8px 10px;
  border:3px solid transparent;
  border-radius:0;
  text-decoration:none;
  font-size:.98rem;
  line-height:1.5;
  transition:background .2s ease-out, border-color .2s ease-out, transform .2s cubic-bezier(.34,1.56,.64,1);
}

.rail-nav a:hover,
.rail-nav a:focus-visible{
  background:#fff;
  border-color:var(--ink);
  transform:translateX(2px);
}

.rail-nav li{
  animation:rise .5s cubic-bezier(.34,1.56,.64,1) both;
}
.rail-nav li:nth-child(1){ animation-delay:.03s; }
.rail-nav li:nth-child(2){ animation-delay:.07s; }
.rail-nav li:nth-child(3){ animation-delay:.11s; }
.rail-nav li:nth-child(4){ animation-delay:.15s; }
.rail-nav li:nth-child(5){ animation-delay:.19s; }
.rail-nav li:nth-child(6){ animation-delay:.23s; }
.rail-nav li:nth-child(7){ animation-delay:.27s; }

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

.cta{
  margin-top:6px;
  display:flex;
  align-items:center;
  justify-content:center;
  min-height:48px;
  padding:12px 18px;
  border:3px solid var(--ink);
  border-radius:999px;
  background:linear-gradient(160deg,#c9ecfa,var(--blue));
  box-shadow:inset -2px -2px 8px rgba(23,38,32,.16), 4px 4px 10px rgba(23,38,32,.18);
  font-weight:700;
  text-decoration:none;
  transition:transform .2s ease-out, box-shadow .2s ease-out;
}

.cta:hover{
  transform:translateY(-2px);
  box-shadow:inset -2px -2px 8px rgba(23,38,32,.16), 6px 7px 14px rgba(23,38,32,.24);
}

.cta:active{ transform:translateY(1px) scale(.99); }

/* ---------- 主区 ---------- */
.wrap{ padding:0 12px; }

.hero{
  position:relative;
  margin:12px 0 0;
  min-height:clamp(340px,70vh,640px);
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:16px;
  text-align:center;
  padding:44px 20px 60px;
  overflow:hidden;
  border:3px solid var(--ink);
  border-radius:var(--r-xl);
  background:linear-gradient(175deg,#e7fff6,#dcf1fb);
  box-shadow:var(--bs-in), var(--bs-out);
}

.hero::before{
  content:'';
  position:absolute;
  inset:-22%;
  background:
    radial-gradient(circle at 26% 30%, rgba(180,253,225,.95), transparent 56%),
    radial-gradient(circle at 76% 68%, rgba(173,216,230,.9), transparent 56%);
  animation:drift 20s ease-in-out infinite alternate;
  z-index:0;
}

@keyframes drift{
  from{ transform:translate3d(-2%,-1%,0) scale(1); }
  to{ transform:translate3d(3%,2%,0) scale(1.08); }
}

.hero::after{
  content:'';
  position:absolute;
  left:0;
  right:0;
  bottom:0;
  height:16px;
  background:linear-gradient(90deg,var(--mint),var(--blue));
  clip-path:polygon(0 100%, 100% 22%, 100% 100%);
  z-index:2;
}

.hero > *{
  position:relative;
  z-index:1;
}

.hero h1{
  margin:0;
  font-size:clamp(1.85rem,5.6vw,3rem);
  line-height:1.28;
  letter-spacing:.01em;
  text-wrap:balance;
}

.lede{
  margin:0;
  max-width:40ch;
  font-size:clamp(1rem,2.4vw,1.12rem);
  line-height:1.7;
  color:#1e4638;
}

.hero-figure{ margin-top:6px; }

.hero-img{
  width:min(560px,100%);
  border:3px solid var(--ink);
  border-radius:0;
  background:#fff;
}

/* ---------- 正文 ---------- */
.body-sec{ margin:24px 0 0; }

.prose{
  max-width:76ch;
  margin:0 auto;
  padding:26px 20px 34px;
  border:3px solid var(--ink);
  border-radius:var(--r-xl);
  background:var(--panel);
  box-shadow:var(--bs-in), var(--bs-out);
}

.prose article{
  scroll-margin-top:16px;
  padding-top:26px;
  margin-top:26px;
  border-top:3px dashed rgba(23,38,32,.2);
}

.prose article:first-of-type{
  padding-top:0;
  margin-top:0;
  border-top:0;
}

.prose h2{
  margin:.2em 0 .55em;
  font-size:clamp(1.24rem,3.4vw,1.48rem);
  line-height:1.4;
  letter-spacing:.01em;
}

.prose h2::before{
  content:'';
  display:inline-block;
  width:13px;
  height:13px;
  margin-right:9px;
  vertical-align:middle;
  border:3px solid var(--ink);
  border-radius:0;
  background:var(--mint);
}

.prose h3{
  margin:1.2em 0 .5em;
  font-size:1.08rem;
  line-height:1.5;
}

.prose small{
  display:block;
  margin-bottom:.35em;
  font-size:.74rem;
  font-weight:700;
  letter-spacing:.22em;
  color:#1f6a53;
}

.prose p{ margin:0 0 1em; }

.prose ul,
.prose ol{
  margin:0 0 1.1em;
  padding-left:1.35em;
}

.prose li{ margin-bottom:.45em; }

.prose a{
  font-weight:700;
  text-underline-offset:3px;
}

.prose figure{ margin:1.4em 0; }

.prose img{
  border:3px solid var(--ink);
  border-radius:0;
  margin-bottom:.5em;
}

.prose figcaption{
  font-size:.86rem;
  color:#33544a;
}

.prose blockquote{
  margin:1.4em 0;
  padding:14px 18px;
  border:3px solid var(--ink);
  border-radius:0;
  background:linear-gradient(150deg,#f0fff9,#e6f7ff);
}

.prose blockquote p:last-child{ margin-bottom:0; }

.prose table{
  width:100%;
  border-collapse:collapse;
  font-size:.95rem;
}

.prose th,
.prose td{
  border:3px solid rgba(23,38,32,.5);
  padding:8px 10px;
  text-align:left;
}

/* ---------- 页脚 ---------- */
.foot{
  margin:26px 12px 16px;
  padding:14px 16px;
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:10px 18px;
  border:3px solid var(--ink);
  border-radius:var(--r-xl);
  background:linear-gradient(120deg,#dbfff2,#d3ecf8);
  box-shadow:var(--bs-in), 4px 6px 16px rgba(23,38,32,.16);
}

.foot .logo{ font-size:.96rem; }

.foot .logo-img{ width:32px; height:32px; border-radius:11px; }

.foot-nav{ flex:1 1 240px; }

.foot-nav ol{
  display:flex;
  flex-wrap:wrap;
  gap:2px 14px;
  list-style:none;
  margin:0;
  padding:0;
}

.foot-nav a{
  display:inline-flex;
  align-items:center;
  min-height:40px;
  padding:0 2px;
  font-size:.9rem;
  text-decoration:none;
  border-bottom:3px solid transparent;
}

.foot-nav a:hover{ border-bottom-color:var(--ink); }

.foot-cta{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:48px;
  padding:12px 22px;
  border:3px solid var(--ink);
  border-radius:999px;
  background:linear-gradient(160deg,#d3fde e,#b4fde1);
  background:linear-gradient(160deg,#d6fdee,#b4fde1);
  box-shadow:inset -2px -2px 8px rgba(23,38,32,.14), 3px 4px 0 rgba(23,38,32,.2);
  font-weight:700;
  text-decoration:none;
  transition:transform .2s ease-out;
}

.foot-cta:hover{ transform:translateY(-2px); }

.foot-copy{
  margin-left:auto;
  font-size:.85rem;
  color:#22493c;
  white-space:nowrap;
}

/* ---------- 响应式 ---------- */
@media (max-width:959px){
  .rail-nav ol{
    display:flex;
    flex-wrap:wrap;
    gap:8px;
  }
  .rail-nav a{
    border-color:var(--ink);
    border-radius:999px;
    background:#fff;
    padding:8px 14px;
    font-size:.95rem;
  }
  .rail-nav a:hover{ transform:none; }
  .cta{ margin-top:2px; }
}

@media (min-width:960px){
  .shell{ padding-left:278px; }
  .rail{
    position:fixed;
    top:14px;
    left:14px;
    bottom:14px;
    width:250px;
    margin:0;
    overflow:auto;
  }
  .rail .cta{ margin-top:auto; }
  .wrap{ padding:0 22px; }
  .hero{ margin:16px 0 0; }
  .body-sec{ margin:30px 0 0; }
  .foot{ margin:32px 22px 20px; }
}

@media (max-width:520px){
  body{ font-size:16.5px; }
  .prose{ padding:22px 15px 28px; }
  .foot-copy{ margin-left:0; }
}

/* ---------- 减少动效 ---------- */
@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}
