@import url('https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,300;0,400;0,500;0,700;1,400&display=swap');

:root{
  --rose:#eb879c;
  --pink:#ffb6c1;
  --ink:#26171a;
  --muted:#5f444a;
  --rose-ink:#bf4e6b;
  --glass:rgba(255,255,255,.76);
  --line:rgba(38,23,26,.10);
  --r:10px;
  --sh-a:0 1px 2px rgba(38,23,26,.05), 0 6px 18px rgba(235,135,156,.15);
  --sh-b:0 2px 4px rgba(38,23,26,.06), 0 16px 36px rgba(235,135,156,.22);
}

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

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

body{
  margin:0;
  font-family:'Roboto',ui-sans-serif,system-ui,-apple-system,'Segoe UI','PingFang SC','Hiragino Sans GB','Microsoft YaHei',sans-serif;
  font-size:17px;
  line-height:1.78;
  color:var(--ink);
  background:
    radial-gradient(900px 520px at 0% -8%,#ffe6ec 0%,rgba(255,230,236,0) 62%),
    radial-gradient(760px 460px at 108% 4%,#ffeef2 0%,rgba(255,238,242,0) 58%),
    linear-gradient(175deg,#fff8fa 0%,#fdeef2 45%,#fbe7ec 100%);
  background-attachment:fixed;
  min-height:100vh;
}

a{color:var(--rose-ink)}
a:focus-visible,
.cta-btn:focus-visible{
  outline:3px solid var(--rose-ink);
  outline-offset:2px;
  border-radius:8px;
}

img{max-width:100%}

/* ---------- 左侧固定竖排导航 ---------- */
.rail{
  position:fixed;
  top:0;left:0;bottom:0;
  width:236px;
  z-index:30;
  display:flex;
  flex-direction:column;
  gap:20px;
  padding:22px 16px;
  overflow-y:auto;
  background:linear-gradient(158deg,rgba(255,255,255,.92),rgba(255,242,246,.74));
  -webkit-backdrop-filter:blur(16px) saturate(120%);
  backdrop-filter:blur(16px) saturate(120%);
  border-right:1px solid var(--line);
  box-shadow:var(--sh-a);
}

.brand-mark{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:52px;height:52px;
  min-height:52px;
  flex:0 0 auto;
  border-radius:14px;
  background:linear-gradient(150deg,var(--pink),var(--rose));
  color:#fff;
  font-weight:700;
  font-size:22px;
  text-decoration:none;
  box-shadow:0 2px 4px rgba(38,23,26,.08),0 10px 22px rgba(235,135,156,.34);
  transition:transform .24s ease,box-shadow .24s ease;
}
.brand-mark:hover{transform:translateY(-2px);box-shadow:0 4px 8px rgba(38,23,26,.1),0 14px 26px rgba(235,135,156,.42)}
.brand-mark img{width:100%;height:100%;object-fit:cover;border-radius:14px;display:block}

.rail-nav{display:flex;flex-direction:column;gap:14px}

.nav-group-title{
  margin:0 0 4px;
  font-size:16px;
  font-weight:500;
  letter-spacing:.16em;
  color:var(--rose-ink);
}

.nav-links{
  display:grid;
  gap:4px;
  overflow:hidden;
  max-height:0;
  opacity:0;
  transition:max-height .26s ease,opacity .22s ease,margin-top .26s ease;
}
.nav-group:hover .nav-links,
.nav-group:focus-within .nav-links{
  max-height:340px;
  opacity:1;
  margin-top:2px;
}

.nav-link{
  display:flex;
  align-items:center;
  min-height:44px;
  padding:10px 12px;
  border-radius:var(--r);
  border:1px solid rgba(38,23,26,.06);
  background:linear-gradient(180deg,rgba(255,255,255,.94),rgba(255,255,255,.68));
  color:var(--ink);
  font-size:16px;
  text-decoration:none;
  transition:background .24s ease,border-color .24s ease,transform .24s ease,box-shadow .24s ease;
}
.nav-link:hover{
  border-color:rgba(235,135,156,.6);
  transform:translateX(3px);
  box-shadow:var(--sh-a);
}
.nav-link[aria-current="true"]{
  background:linear-gradient(150deg,rgba(255,182,193,.55),rgba(255,255,255,.85));
  border-color:rgba(235,135,156,.7);
  color:var(--rose-ink);
  font-weight:500;
}

/* ---------- 主区 ---------- */
.stage{
  margin-left:236px;
  max-width:1320px;
  padding:30px 30px 18px;
  display:grid;
  grid-template-columns:minmax(0,1fr) 266px;
  gap:26px;
  align-items:start;
}

.essay{min-width:0;overflow-wrap:break-word}

.hero{
  display:grid;
  grid-template-columns:.92fr 1.08fr;
  gap:24px;
  align-items:center;
  min-height:min(70vh,540px);
  padding:22px;
  border-radius:var(--r);
  background:linear-gradient(150deg,rgba(255,255,255,.88),rgba(255,240,245,.62));
  border:1px solid rgba(255,255,255,.9);
  box-shadow:var(--sh-b);
  -webkit-backdrop-filter:blur(14px);
  backdrop-filter:blur(14px);
}

.hero-figure{
  position:relative;
  margin:0;
  aspect-ratio:4 / 5;
  border-radius:var(--r);
  overflow:hidden;
  background:linear-gradient(150deg,var(--pink),var(--rose));
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.55),var(--sh-a);
}
.hero-img{width:100%;height:100%;object-fit:cover;display:block}
.hero-ph{
  width:100%;height:100%;
  background:
    radial-gradient(circle at 30% 24%,rgba(255,255,255,.8) 0 7%,rgba(255,255,255,0) 8%),
    radial-gradient(circle at 70% 58%,rgba(255,255,255,.55) 0 11%,rgba(255,255,255,0) 12%),
    linear-gradient(150deg,#ffc4cf,#e5899f);
}

.float-tag{
  position:absolute;
  left:12px;bottom:12px;
  padding:6px 12px;
  border-radius:999px;
  font-size:16px;
  line-height:1.5;
  color:var(--ink);
  background:rgba(255,255,255,.88);
  box-shadow:var(--sh-a);
  -webkit-backdrop-filter:blur(6px);
  backdrop-filter:blur(6px);
}

.hero-copy h1{
  margin:14px 0 12px;
  font-size:clamp(30px,4.2vw,44px);
  line-height:1.24;
  font-weight:700;
  letter-spacing:-.01em;
}

.hero-lead{
  margin:0;
  max-width:46ch;
  color:var(--muted);
  font-size:17px;
}

.badge{
  display:inline-block;
  padding:6px 12px;
  border-radius:999px;
  font-size:16px;
  line-height:1.5;
  color:#fff;
  background:linear-gradient(120deg,var(--rose),#d4697f);
  box-shadow:0 2px 4px rgba(38,23,26,.1),0 8px 16px rgba(235,135,156,.36);
}

/* ---------- 正文 ---------- */
.flow{margin-top:24px;display:block}
.flow > div{
  position:relative;
  padding:24px 26px 26px;
  margin-top:18px;
  border-radius:var(--r);
  background:var(--glass);
  border:1px solid rgba(255,255,255,.86);
  box-shadow:var(--sh-a);
  -webkit-backdrop-filter:blur(10px);
  backdrop-filter:blur(10px);
  animation:rise .3s ease both;
}
.flow > div::after{
  content:"";
  position:absolute;
  left:26px;top:0;
  width:56px;height:3px;
  border-radius:0 0 3px 3px;
  background:linear-gradient(90deg,var(--rose),var(--pink));
}
.flow > div:nth-child(2){animation-delay:.04s}
.flow > div:nth-child(3){animation-delay:.08s}
.flow > div:nth-child(4){animation-delay:.12s}
.flow > div:nth-child(5){animation-delay:.16s}
.flow > div:nth-child(6){animation-delay:.2s}
.flow > div:nth-child(7){animation-delay:.24s}

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

div[id]{scroll-margin-top:20px}

.flow h2{
  margin:0 0 10px;
  font-size:23px;
  line-height:1.36;
  font-weight:700;
}
.flow h3{margin:22px 0 8px;font-size:19px;line-height:1.4}
.flow p{margin:0 0 14px}
.flow h2 + .subtitle,
.flow h3 + .subtitle{margin-top:-2px}
.subtitle{color:var(--rose-ink);font-size:16px}
.flow ul,.flow ol{margin:0 0 14px;padding-left:1.3em}
.flow li{margin:.35em 0}
.flow a{color:var(--rose-ink);text-underline-offset:3px}
.flow strong{font-weight:700}
.flow blockquote{
  margin:16px 0;
  padding:12px 16px;
  border-left:3px solid var(--rose);
  border-radius:0 var(--r) var(--r) 0;
  background:rgba(255,182,193,.2);
  color:var(--muted);
}
.flow img{border-radius:var(--r);height:auto}
.flow table{width:100%;border-collapse:collapse;margin:0 0 14px;font-size:16px}
.flow th,.flow td{border:1px solid var(--line);padding:8px 10px;text-align:left}
.flow th{background:rgba(255,182,193,.22)}

/* ---------- 右侧浮动目录 ---------- */
.toc{
  position:sticky;
  top:24px;
  padding:18px 16px;
  border-radius:var(--r);
  background:var(--glass);
  border:1px solid rgba(255,255,255,.9);
  box-shadow:var(--sh-a);
  -webkit-backdrop-filter:blur(12px);
  backdrop-filter:blur(12px);
}
.toc h2{margin:0 0 4px;font-size:18px;font-weight:700}
.toc .subtitle{margin:0 0 12px;color:var(--rose-ink);font-size:16px}
.toc ol{list-style:none;margin:0;padding:0;counter-reset:toc}
.toc li{counter-increment:toc}
.toc a{
  display:flex;
  align-items:center;
  gap:10px;
  min-height:42px;
  padding:8px;
  border-radius:var(--r);
  color:var(--ink);
  font-size:16px;
  text-decoration:none;
  transition:background .24s ease,transform .24s ease;
}
.toc a::before{
  content:counter(toc,decimal-leading-zero);
  min-width:22px;
  font-size:16px;
  font-weight:500;
  color:var(--rose-ink);
}
.toc a:hover{background:rgba(255,182,193,.28);transform:translateX(2px)}
.toc a[aria-current="true"]{background:rgba(255,182,193,.42);font-weight:500}

/* ---------- 页脚 ---------- */
.foot{
  margin-left:236px;
  max-width:1320px;
  padding:26px 30px 46px;
}

.foot-cta{
  display:flex;
  flex-wrap:wrap;
  gap:18px;
  align-items:center;
  justify-content:space-between;
  padding:26px 28px;
  border-radius:var(--r);
  color:#fff;
  background:linear-gradient(140deg,#e07d95,#b8526d 70%);
  box-shadow:0 2px 4px rgba(38,23,26,.12),0 18px 38px rgba(184,82,109,.3);
}
.foot-cta h2{margin:0 0 4px;font-size:26px;line-height:1.3}
.foot-cta .subtitle{margin:0;color:rgba(255,255,255,.88);font-size:16px}

.cta-btn{
  display:inline-flex;
  align-items:center;
  min-height:48px;
  padding:12px 22px;
  border-radius:var(--r);
  background:#fff;
  color:var(--ink);
  font-weight:500;
  font-size:16px;
  text-decoration:none;
  box-shadow:0 2px 4px rgba(38,23,26,.16);
  transition:transform .24s ease,box-shadow .24s ease;
}
.cta-btn:hover{transform:translateY(-2px);box-shadow:0 10px 22px rgba(38,23,26,.24)}

.foot-cols{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:22px;
  margin-top:26px;
}
.foot-cols dl{margin:0}
.foot-cols dt{
  margin-bottom:8px;
  font-size:16px;
  font-weight:700;
  letter-spacing:.1em;
  color:var(--rose-ink);
}
.foot-cols dd{margin:0}
.foot-cols a{
  display:inline-flex;
  align-items:center;
  min-height:40px;
  padding:4px 0;
  color:var(--ink);
  font-size:16px;
  text-decoration:none;
  border-bottom:1px solid transparent;
  transition:color .2s ease,border-color .2s ease;
}
.foot-cols a:hover{color:var(--rose-ink);border-color:var(--rose)}

.foot-base{
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin-top:22px;
  padding-top:16px;
  border-top:1px solid var(--line);
}
.foot-base p{margin:0;color:var(--muted);font-size:16px}
.foot-nav dl{display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin:0}
.foot-nav dt{font-size:16px;color:var(--muted);letter-spacing:.08em}
.foot-nav dd{margin:0}
.foot-nav a{
  display:inline-flex;
  align-items:center;
  min-height:40px;
  padding:6px 12px;
  border-radius:var(--r);
  background:rgba(255,255,255,.72);
  color:var(--ink);
  font-size:16px;
  text-decoration:none;
  box-shadow:0 1px 2px rgba(38,23,26,.05);
  transition:background .2s ease,color .2s ease;
}
.foot-nav a:hover{background:rgba(255,182,193,.34);color:var(--rose-ink)}

/* ---------- 断点 ---------- */
@media (max-width:1120px){
  .stage{grid-template-columns:minmax(0,1fr) 240px;gap:20px}
}

@media (max-width:900px){
  .rail{
    inset:0 0 auto 0;
    width:auto;
    flex-direction:row;
    align-items:center;
    gap:10px;
    padding:8px 12px;
    overflow-x:auto;
    overflow-y:hidden;
    border-right:none;
    border-bottom:1px solid var(--line);
  }
  .brand-mark{width:44px;height:44px;min-height:44px;flex:0 0 44px;font-size:20px;border-radius:12px}
  .rail-nav{flex-direction:row;align-items:center;gap:12px}
  .nav-group{display:flex;align-items:center;gap:6px}
  .nav-group-title{margin:0;white-space:nowrap}
  .nav-links{
    display:flex;
    gap:6px;
    max-height:none;
    opacity:1;
    overflow:visible;
    margin:0;
  }
  .nav-link{white-space:nowrap;transform:none;min-height:44px;padding:10px 12px}
  .nav-link:hover{transform:none}

  .stage{
    margin-left:0;
    padding:76px 14px 16px;
    grid-template-columns:minmax(0,1fr);
    gap:18px;
  }
  .hero{grid-template-columns:1fr;min-height:0;padding:18px}
  .hero-copy{order:1}
  .hero-figure{order:2;aspect-ratio:16 / 10}
  .toc{position:static}
  div[id]{scroll-margin-top:84px}

  .foot{margin-left:0;padding:20px 14px 38px}
  .foot-cols{grid-template-columns:1fr 1fr}
}

@media (max-width:560px){
  .foot-cols{grid-template-columns:1fr}
  .foot-cta{padding:20px}
  .hero-copy h1{font-size:30px}
  .flow > div{padding:20px 18px 22px}
  .flow > div::after{left:18px}
}

@media (prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  *,*::before,*::after{
    animation-duration:.001ms !important;
    animation-iteration-count:1 !important;
    transition-duration:.001ms !important;
  }
}
</｜DSML｜ parameter>
</｜DSML｜ invoke>
</｜DSML｜ calls>

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