:root{
  --mint:#b4fde1;
  --sky:#add8e6;
  --ink:#172620;
  --paper:#f7fdfa;
  --line:rgba(23,38,32,.16);
  --r-lg:24px;
  --r-sm:4px;
  --sh:inset -3px -3px 0 rgba(23,38,32,.09), inset 3px 3px 0 rgba(255,255,255,.72), 6px 7px 0 rgba(23,38,32,.14);
  --sh-sm:inset -2px -2px 0 rgba(23,38,32,.08), 3px 4px 0 rgba(23,38,32,.12);
}

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

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

body{
  margin:0;
  font-family:'Rubik','Nunito Sans',-apple-system,BlinkMacSystemFont,'PingFang SC','Hiragino Sans GB','Microsoft YaHei',sans-serif;
  font-size:17px;
  line-height:1.7;
  color:var(--ink);
  background-color:#fbfefd;
  background-image:
    radial-gradient(120% 60% at 92% -8%, #e2fff5 0%, rgba(226,255,245,0) 62%),
    radial-gradient(90% 55% at -6% 104%, #e6f6fd 0%, rgba(230,246,253,0) 58%),
    linear-gradient(180deg,#fcfffe,#effaf6 70%,#f7fffc);
  background-attachment:fixed;
  min-height:100vh;
  overflow-x:hidden;
}

body.menu-on{ overflow:hidden; }

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

a{ color:inherit; }

:focus-visible{ outline:3px solid var(--ink); outline-offset:3px; }

/* ---------- 左侧固定竖栏 ---------- */

.rail{
  position:fixed;
  top:0; left:0; bottom:0;
  width:92px;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:space-between;
  gap:14px;
  padding:18px 8px;
  background:linear-gradient(182deg,var(--mint),var(--sky));
  border-right:4px solid var(--ink);
  box-shadow:7px 0 0 rgba(23,38,32,.08);
  z-index:70;
  overflow-y:auto;
}

.brand{
  display:block;
  writing-mode:vertical-rl;
  text-decoration:none;
  color:var(--ink);
  font-size:17px;
  font-weight:700;
  letter-spacing:.14em;
  padding:17px 9px;
  background:#ffffff;
  border:3px solid var(--ink);
  border-radius:999px;
  box-shadow:var(--sh-sm);
  transition:transform .2s cubic-bezier(.34,1.56,.64,1);
}

.brand:hover{ transform:translateY(-3px); }

.railFoot{
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:10px;
}

.railLink{
  display:block;
  writing-mode:vertical-rl;
  text-decoration:none;
  color:var(--ink);
  font-size:16px;
  font-weight:700;
  letter-spacing:.1em;
  padding:12px 9px;
  min-height:48px;
  background:linear-gradient(180deg,#ffffff,#e9fff6);
  border:3px solid var(--ink);
  border-radius:999px;
}

.burger{
  width:58px;
  min-height:58px;
  display:flex;
  align-items:center;
  justify-content:center;
  font:inherit;
  font-size:16px;
  font-weight:700;
  color:var(--ink);
  background:linear-gradient(180deg,#ffffff,#e8fff7);
  border:3px solid var(--ink);
  border-radius:18px;
  box-shadow:var(--sh-sm);
  cursor:pointer;
  transition:transform .18s ease-out, box-shadow .18s ease-out;
}

.burger:active{
  transform:translateY(3px);
  box-shadow:inset 3px 3px 0 rgba(23,38,32,.16), 1px 1px 0 rgba(23,38,32,.14);
}

/* ---------- 外壳 ---------- */

.shell{
  margin-left:92px;
  padding:20px clamp(12px,2.4vw,30px) 0;
  max-width:1180px;
}

/* ---------- 首屏 ---------- */

.hero{
  position:relative;
  display:grid;
  grid-template-columns:minmax(0,.85fr) minmax(0,1.15fr);
  gap:clamp(14px,2.6vw,26px);
  align-items:center;
  min-height:45vh;
  padding:18px 18px 34px;
  background:linear-gradient(150deg,#e9fff7,#f7ffff 52%,#e6f3fb);
  border:4px solid var(--ink);
  border-radius:var(--r-lg);
  box-shadow:var(--sh);
  overflow:hidden;
  margin-bottom:22px;
}

.hero::after{
  content:'';
  position:absolute;
  left:-8px; right:-8px; bottom:-6px;
  height:22px;
  background:linear-gradient(90deg,var(--mint),var(--sky));
  border-top:4px solid var(--ink);
  transform:skewY(-1.4deg);
  transform-origin:bottom left;
}

.heroArt{
  margin:0;
  border:4px solid var(--ink);
  border-radius:20px;
  overflow:hidden;
  aspect-ratio:4/3;
  background:linear-gradient(140deg,var(--mint),var(--sky));
  box-shadow:var(--sh-sm);
}

.heroArt.isEmpty{
  background-image:
    radial-gradient(circle at 50% 46%, rgba(255,255,255,.85) 0 34%, rgba(255,255,255,0) 35%),
    linear-gradient(140deg,var(--mint),var(--sky));
}

.heroImg{
  width:100%;
  height:100%;
  object-fit:cover;
}

.heroWords{
  text-align:center;
  padding-inline:6px;
}

.hero h1{
  margin:0 0 12px;
  font-size:clamp(26px,4.2vw,44px);
  line-height:1.18;
  letter-spacing:.01em;
  text-shadow:2px 3px 0 rgba(180,253,225,.85);
}

.dek{
  margin:0;
  font-size:16px;
  line-height:1.65;
  color:rgba(23,38,32,.78);
}

/* ---------- 正文区 ---------- */

.body{
  display:grid;
  grid-template-columns:minmax(0,1fr) 264px;
  gap:clamp(16px,2.8vw,28px);
  align-items:start;
  padding-bottom:26px;
}

.prose{
  background:var(--paper);
  border:4px solid var(--ink);
  border-radius:var(--r-lg);
  box-shadow:var(--sh);
  padding:clamp(16px,2.4vw,30px);
  min-width:0;
}

.proseHead{
  border-bottom:3px solid rgba(23,38,32,.14);
  padding-bottom:14px;
  margin-bottom:20px;
}

.proseHead h2{
  margin:0;
  font-size:clamp(21px,2.6vw,29px);
  line-height:1.28;
}

.prose small{
  display:block;
  font-size:15px;
  font-weight:700;
  letter-spacing:.12em;
  color:rgba(23,38,32,.55);
  margin-bottom:6px;
}

.prose p{ margin:0 0 14px; }

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

.prose a{
  text-decoration:underline;
  text-decoration-color:var(--sky);
  text-decoration-thickness:3px;
  text-underline-offset:3px;
}

.prose h2,.prose h3{
  line-height:1.32;
  margin:0 0 12px;
}

.prose h3{ font-size:clamp(18px,2.1vw,22px); }

.prose > section{
  scroll-margin-top:22px;
}

.prose > section + section{
  margin-top:26px;
  padding-top:26px;
  border-top:3px dashed rgba(23,38,32,.2);
}

/* ---------- 侧栏 ---------- */

.side{
  background:linear-gradient(168deg,#eafff6,#f4fcff);
  border:4px solid var(--ink);
  border-radius:var(--r-lg);
  box-shadow:var(--sh);
  padding:16px;
}

.sideNav{
  display:grid;
  gap:9px;
}

.sideNav a{
  display:block;
  text-decoration:none;
  font-size:16px;
  font-weight:600;
  line-height:1.4;
  color:var(--ink);
  background:#ffffff;
  border:3px solid var(--ink);
  border-radius:var(--r-sm);
  padding:10px 12px;
  min-height:44px;
}

.sideNav a:hover{
  background:linear-gradient(120deg,var(--mint),#ffffff);
}

/* ---------- 页脚 ---------- */

.foot{
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  justify-content:space-between;
  gap:10px 16px;
  margin:0 0 30px;
  padding:14px 18px;
  background:linear-gradient(100deg,var(--mint),#eefcff 62%,var(--sky));
  border:4px solid var(--ink);
  border-radius:var(--r-lg);
  box-shadow:var(--sh);
}

.footBrand a{
  display:inline-block;
  text-decoration:none;
  font-weight:700;
  font-size:17px;
  min-height:40px;
  line-height:40px;
  padding-inline:4px;
}

.footNav{ flex:1 1 240px; }

.footNav dl{
  display:flex;
  flex-wrap:wrap;
  gap:6px 8px;
  margin:0;
}

.footNav dt{ margin:0; }

.footNav a{
  display:inline-block;
  text-decoration:none;
  font-size:16px;
  line-height:1.5;
  padding:8px 10px;
  min-height:40px;
  background:#ffffff;
  border:3px solid var(--ink);
  border-radius:var(--r-sm);
}

.footNav a:hover{ background:#f4fffb; }

.footCopy{
  font-size:16px;
  color:rgba(23,38,32,.8);
}

/* ---------- 全屏菜单 ---------- */

.menulayer{
  position:fixed;
  inset:0;
  z-index:90;
  display:grid;
  place-items:center;
  padding:20px;
  background:linear-gradient(160deg,rgba(180,253,225,.97),rgba(173,216,230,.97));
  opacity:0;
  visibility:hidden;
  transition:opacity .22s ease-out, visibility .22s linear;
}

.menulayer[data-open="true"]{
  opacity:1;
  visibility:visible;
}

.menuBox{
  width:min(560px,100%);
  max-height:86vh;
  overflow-y:auto;
  background:#ffffff;
  border:4px solid var(--ink);
  border-radius:var(--r-lg);
  box-shadow:14px 16px 0 rgba(23,38,32,.2);
  padding:20px;
}

.menuTop{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin-bottom:16px;
  padding-bottom:14px;
  border-bottom:3px solid rgba(23,38,32,.14);
}

.menuBrand{
  margin:0;
  font-weight:700;
  font-size:17px;
}

.menuClose{
  font:inherit;
  font-size:16px;
  font-weight:700;
  color:var(--ink);
  background:#ffffff;
  border:3px solid var(--ink);
  border-radius:var(--r-sm);
  padding:10px 14px;
  min-height:44px;
  cursor:pointer;
}

.menuList{
  display:grid;
  gap:10px;
}

.menuList a{
  display:block;
  text-decoration:none;
  color:var(--ink);
  font-size:18px;
  font-weight:600;
  line-height:1.4;
  padding:13px 15px;
  min-height:48px;
  background:#ffffff;
  border:3px solid var(--ink);
  border-radius:var(--r-sm);
}

.menuList a:hover{
  background:linear-gradient(120deg,var(--mint),#ffffff);
}

@keyframes pop{
  from{ opacity:0; transform:translateY(12px) scale(.97); }
  to{ opacity:1; transform:translateY(0) scale(1); }
}

.menulayer[data-open="true"] .menuList a{
  animation:pop .36s cubic-bezier(.34,1.56,.64,1) both;
}

.menuList a:nth-child(1){ animation-delay:.04s; }
.menuList a:nth-child(2){ animation-delay:.08s; }
.menuList a:nth-child(3){ animation-delay:.12s; }
.menuList a:nth-child(4){ animation-delay:.16s; }
.menuList a:nth-child(5){ animation-delay:.2s; }
.menuList a:nth-child(6){ animation-delay:.24s; }
.menuList a:nth-child(7){ animation-delay:.28s; }

/* ---------- 滚动显现 ---------- */

[data-rv]{
  opacity:0;
  transform:translateY(16px);
  transition:opacity .5s ease-out, transform .5s cubic-bezier(.34,1.56,.64,1);
}

[data-rv].in{
  opacity:1;
  transform:translateY(0);
}

/* ---------- 响应式 ---------- */

@media (max-width:880px){
  .body{ grid-template-columns:minmax(0,1fr); }
  .side{ order:2; }
}

@media (max-width:700px){
  body{ font-size:16px; }
  .rail{ width:76px; padding:14px 7px; gap:12px; }
  .brand{ font-size:16px; padding:14px 8px; letter-spacing:.1em; }
  .burger{ width:58px; min-height:56px; border-radius:16px; }
  .railLink{ padding:11px 8px; font-size:16px; }
  .shell{ margin-left:76px; padding:14px 12px 0; }
  .hero{
    grid-template-columns:minmax(0,1fr);
    padding:14px 14px 30px;
    min-height:0;
    text-align:center;
  }
  .heroArt{ aspect-ratio:auto; height:132px; border-radius:16px; }
  .hero h1{ font-size:clamp(24px,7vw,32px); }
  .prose{ padding:16px 14px; }
  .foot{ padding:12px 14px; }
}

@media (max-width:420px){
  .shell{ padding:12px 10px 0; }
  .hero h1{ font-size:24px; }
}

@media (prefers-reduced-motion:reduce){
  html{ scroll-behavior:auto; }
  [data-rv]{ opacity:1; transform:none; transition:none; }
  .menulayer[data-open="true"] .menuList a{ animation:none; }
}

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