@import url('https://fonts.googleapis.com/css2?family=Cormorant+Infant:wght@300;400;500;600;700&family=Great+Vibes&display=swap');

:root{
  --ink:#17111e;
  --ink-2:#1f1726;
  --card:#241b2f;
  --card-2:#2c2138;
  --line:rgba(236,228,220,.14);
  --txt:#ece4dc;
  --muted:#b6a9bf;
  --grape:#56228b;
  --grape-lt:#c3a2e6;
  --clay:#8b4513;
  --clay-lt:#cf9163;
  --r:18px;
  --shadow:0 22px 48px -30px rgba(0,0,0,.95);
}

*{box-sizing:border-box}

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

body{
  margin:0;
  color:var(--txt);
  font-family:"Cormorant Infant","Songti SC","Noto Serif SC",Georgia,"Microsoft YaHei",serif;
  font-size:17px;
  line-height:1.78;
  background:
    radial-gradient(900px 520px at 8% -10%,rgba(86,34,139,.45),transparent 70%),
    radial-gradient(720px 480px at 98% 2%,rgba(139,69,19,.32),transparent 72%),
    var(--ink);
  background-attachment:fixed;
}

body::before{
  content:"";
  position:fixed;
  inset:0;
  pointer-events:none;
  z-index:0;
  opacity:.05;
  background-image:repeating-linear-gradient(115deg,#fff 0 1px,transparent 1px 7px);
}

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

.wrap{
  width:min(1120px,100% - 2.4rem);
  margin-inline:auto;
  position:relative;
  z-index:1;
}

a{color:var(--grape-lt);text-decoration:none}
a:hover{color:#fff;text-decoration:underline;text-underline-offset:3px}

:focus-visible{outline:2px solid var(--clay-lt);outline-offset:3px;border-radius:10px}

/* 头部 */
.site-head{
  position:sticky;
  top:0;
  z-index:60;
  background:rgba(23,17,30,.9);
  backdrop-filter:blur(10px);
  border-bottom:1px solid var(--line);
}

.head-top{
  display:flex;
  align-items:center;
  padding:.7rem 0 .35rem;
}

.brand{
  display:inline-flex;
  align-items:center;
  gap:.5rem;
  min-height:44px;
  color:var(--txt);
  font-size:1.12rem;
  letter-spacing:.06em;
}

.brand:hover{text-decoration:none;color:var(--clay-lt)}

.brand .mark{
  font-family:"Great Vibes",cursive;
  font-size:1.7rem;
  line-height:1;
  color:var(--clay-lt);
}

.brand .bn{font-weight:600}

.head-nav{border-top:1px solid var(--line)}

.menu{
  display:flex;
  align-items:center;
  gap:.4rem;
  flex-wrap:wrap;
  padding:.35rem 0 .55rem;
  font-size:16px;
}

.menu p{
  margin:0;
  display:flex;
  flex-wrap:wrap;
  gap:.3rem;
}

.menu a,
.fold summary{
  display:inline-flex;
  align-items:center;
  min-height:40px;
  padding:.45rem .8rem;
  border-radius:999px;
  border:1px solid transparent;
  color:var(--txt);
  white-space:nowrap;
}

.menu a:hover,
.fold summary:hover{
  background:rgba(86,34,139,.4);
  border-color:rgba(195,162,230,.35);
  color:#fff;
  text-decoration:none;
}

.fold{position:relative}

.fold summary{
  cursor:pointer;
  list-style:none;
  background:rgba(139,69,19,.28);
  border-color:rgba(207,145,99,.4);
}

.fold summary::-webkit-details-marker{display:none}

.fold summary::after{content:"";width:7px;height:7px;margin-left:.45rem;border-right:1.6px solid currentColor;border-bottom:1.6px solid currentColor;transform:rotate(45deg) translateY(-1px);transition:transform .25s}

.fold[open] summary::after{transform:rotate(-135deg) translateY(-2px)}

.fold p{
  position:absolute;
  right:0;
  top:calc(100% + .45rem);
  z-index:70;
  display:grid;
  gap:.2rem;
  min-width:210px;
  padding:.5rem;
  background:var(--card);
  border:1px solid var(--line);
  border-radius:20px;
  box-shadow:var(--shadow);
}

.fold p a{border-radius:14px}

/* 首屏 */
.hero{
  position:relative;
  overflow:hidden;
  min-height:clamp(270px,45vh,430px);
  display:grid;
  align-items:center;
  padding:1.2rem 0 1.6rem;
}

.hero-in{
  position:relative;
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  gap:2rem;
  align-items:center;
}

.ghost{
  position:absolute;
  left:-3%;
  top:-4%;
  z-index:0;
  font-size:clamp(2.6rem,11vw,7.4rem);
  line-height:.92;
  letter-spacing:.04em;
  color:rgba(195,162,230,.11);
  white-space:nowrap;
  pointer-events:none;
  animation:drift 26s ease-in-out infinite alternate;
}

.hero-copy{position:relative;z-index:1;max-width:34ch}

.hero-copy h1{
  margin:.2rem 0 .7rem;
  font-size:clamp(1.85rem,5.4vw,3.1rem);
  line-height:1.24;
  letter-spacing:.02em;
  font-weight:600;
  text-wrap:balance;
}

.lede{
  margin:0;
  max-width:40ch;
  color:var(--muted);
  font-size:1.02rem;
  border-left:3px solid var(--clay);
  padding-left:.85rem;
  border-radius:2px;
}

.hero-side{position:relative;z-index:1;width:clamp(120px,18vw,196px)}

.blob{
  width:100%;
  height:auto;
  filter:drop-shadow(0 24px 40px rgba(0,0,0,.55));
  animation:float 12s ease-in-out infinite alternate;
}

.hero-art{
  width:100%;
  aspect-ratio:1;
  object-fit:cover;
  border-radius:46% 54% 52% 48% / 48% 44% 56% 52%;
  box-shadow:var(--shadow);
  animation:float 14s ease-in-out infinite alternate;
}

@keyframes drift{
  from{transform:translateX(0)}
  to{transform:translateX(3.5%)}
}

@keyframes float{
  from{transform:translateY(0) rotate(-1.5deg)}
  to{transform:translateY(-12px) rotate(1.5deg)}
}

/* 主体 */
.band{
  display:grid;
  grid-template-columns:minmax(0,1fr) 268px;
  gap:2.4rem;
  align-items:start;
  padding:1.4rem 0 3.4rem;
}

.prose{
  background:linear-gradient(180deg,var(--card),var(--ink-2));
  border:1px solid var(--line);
  border-radius:var(--r);
  box-shadow:var(--shadow);
  padding:1.6rem clamp(1rem,3vw,2.1rem) 2rem;
  min-width:0;
}

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

.prose > section + section{
  margin-top:2.1rem;
  padding-top:1.5rem;
  border-top:1px dashed var(--line);
}

.prose h2{
  margin:1.4rem 0 .35rem;
  font-size:1.45rem;
  line-height:1.35;
  letter-spacing:.02em;
  color:#f0e3f7;
}

.prose > section > h2:first-child{margin-top:.2rem}

.prose h3{
  margin:1.2rem 0 .3rem;
  font-size:1.14rem;
  color:var(--clay-lt);
}

.prose hr{
  border:0;
  height:1px;
  margin:.2rem 0 1rem;
  background:linear-gradient(90deg,var(--clay-lt),rgba(207,145,99,0));
}

.prose p{margin:0 0 1.05rem}

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

.prose li{margin:.35rem 0}

.prose li::marker{color:var(--grape-lt)}

.prose strong{color:#fff;font-weight:600}

.prose blockquote{
  margin:1.2rem 0;
  padding:.7rem 1rem;
  border-left:3px solid var(--grape);
  background:rgba(86,34,139,.22);
  border-radius:0 14px 14px 0;
  color:#e6dcee;
}

.prose a{border-bottom:1px solid rgba(195,162,230,.45)}

.prose table{width:100%;border-collapse:collapse;margin:1rem 0;font-size:16px}

.prose th,
.prose td{border:1px solid var(--line);padding:.5rem .65rem;text-align:left}

.prose th{background:rgba(86,34,139,.3)}

/* 侧栏 */
.side{
  background:rgba(139,69,19,.16);
  border:1px solid rgba(207,145,99,.32);
  border-radius:24px;
  padding:1.1rem 1rem 1.2rem;
  box-shadow:var(--shadow);
}

.side h2{
  margin:0;
  font-size:1.12rem;
  letter-spacing:.14em;
  color:var(--clay-lt);
}

.side hr{
  border:0;
  height:1px;
  margin:.55rem 0 .8rem;
  background:linear-gradient(90deg,rgba(207,145,99,.75),rgba(207,145,99,0));
}

.side-links{
  margin:0;
  display:grid;
  gap:.15rem;
  font-size:16px;
}

.side-links a{
  display:flex;
  align-items:center;
  min-height:40px;
  padding:.3rem .55rem;
  border-radius:14px;
  color:var(--txt);
  border:1px solid transparent;
}

.side-links a:hover{
  background:rgba(86,34,139,.42);
  border-color:rgba(195,162,230,.3);
  color:#fff;
  text-decoration:none;
}

@media (min-width:861px){
  .side{position:sticky;top:132px}
}

/* 页脚 */
footer{
  position:relative;
  z-index:1;
  border-top:1px solid var(--line);
  padding:1.8rem 1rem 2.4rem;
  text-align:center;
}

footer p{margin:0 0 .3rem;letter-spacing:.08em}

footer small{
  display:block;
  font-size:16px;
  color:var(--muted);
  letter-spacing:.12em;
}

/* 动效 */
.js .rv{
  opacity:0;
  transform:translateY(18px);
  transition:opacity .65s ease,transform .65s ease;
}

.js .rv.on{opacity:1;transform:none}

@media (prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  .ghost,.blob,.hero-art{animation:none}
  .js .rv{opacity:1;transform:none;transition:none}
  .fold summary::after{transition:none}
}

/* 移动端 */
@media (max-width:860px){
  body{font-size:17px}
  .wrap{width:min(1120px,100% - 1.7rem)}
  .hero{min-height:0;padding:1rem 0 1.3rem}
  .hero-in{grid-template-columns:1fr;gap:.9rem}
  .hero-side{width:96px;order:-1}
  .ghost{font-size:clamp(2.3rem,15vw,4rem);top:-1%}
  .lede{font-size:1rem}
  .band{grid-template-columns:1fr;gap:1.5rem;padding-bottom:2.6rem}
  .prose{padding:1.2rem 1rem 1.6rem;border-radius:16px}
  .prose > section{scroll-margin-top:150px}
  .side{border-radius:20px}
  .fold p{right:auto;left:0}
}

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