@import url('https://fonts.googleapis.com/css2?family=Kalam:wght@400;700&family=Patrick+Hand&display=swap');

:root{
  --ink:#0d0d0d;
  --ink-2:#141018;
  --pur:#8000ff;
  --mag:#ff00ff;
  --txt:#e9e3f3;
  --dim:#a89db8;
  --faint:#7c7288;
  --line:rgba(255,0,255,.26);
  --hand:'Patrick Hand','Kalam',ui-rounded,system-ui,'Noto Sans SC','PingFang SC','Microsoft YaHei',sans-serif;
  --mono:ui-monospace,'SFMono-Regular',Menlo,Consolas,'Courier New',monospace;
}

*{box-sizing:border-box}

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

body{
  margin:0;
  background:
    radial-gradient(900px 620px at 92% -12%,rgba(128,0,255,.3),transparent 68%),
    radial-gradient(720px 520px at -10% 102%,rgba(255,0,255,.16),transparent 70%),
    var(--ink);
  color:var(--txt);
  font-family:var(--hand);
  font-size:17px;
  line-height:1.72;
  overflow-x:hidden;
  min-height:100vh;
}

body::before{
  content:"";
  position:fixed;
  inset:0;
  z-index:9;
  pointer-events:none;
  opacity:.5;
  mix-blend-mode:screen;
  background:repeating-linear-gradient(180deg,rgba(255,255,255,.05) 0 1px,transparent 1px 4px);
}

body::after{
  content:"";
  position:fixed;
  inset:0;
  z-index:8;
  pointer-events:none;
  background:radial-gradient(120% 100% at 50% 0,transparent 55%,rgba(0,0,0,.55) 100%);
}

a{color:var(--mag)}

:focus-visible{
  outline:2px dashed var(--mag);
  outline-offset:3px;
}

/* ---------- 骨架 ---------- */
.wrap{
  display:grid;
  grid-template-columns:252px minmax(0,1fr);
  max-width:1340px;
  margin:0 auto;
}

/* ---------- 左栏 ---------- */
.rail{
  position:sticky;
  top:0;
  align-self:start;
  height:100vh;
  padding:24px 18px 26px;
  display:flex;
  flex-direction:column;
  gap:14px;
  border-right:1px solid var(--line);
  background:linear-gradient(180deg,rgba(20,16,24,.94),rgba(13,13,13,.72));
  backdrop-filter:blur(4px);
}

.brand{
  display:flex;
  align-items:center;
  gap:10px;
  min-height:44px;
  text-decoration:none;
  color:#fff;
}

.mono{
  display:grid;
  place-items:center;
  width:40px;
  height:40px;
  flex:0 0 40px;
  border:1px solid var(--mag);
  border-radius:4px;
  font-family:var(--mono);
  font-size:17px;
  color:var(--mag);
  box-shadow:inset 0 0 14px rgba(255,0,255,.42),0 0 14px rgba(255,0,255,.32);
  transform:rotate(-3deg);
}

.brand-name{
  font-size:19px;
  letter-spacing:.08em;
  text-shadow:0 0 12px rgba(128,0,255,.95);
}

.rail-line{
  display:block;
  height:1px;
  background:repeating-linear-gradient(90deg,var(--line) 0 6px,transparent 6px 12px);
}

.rail-head{
  margin:0;
  font-family:var(--mono);
  font-size:12px;
  font-weight:400;
  letter-spacing:.3em;
  color:var(--faint);
}

.rail-head span{color:var(--mag)}

.rail-nav{min-width:0}

.pills{
  list-style:none;
  margin:0;
  padding:0;
  display:flex;
  flex-direction:column;
  gap:9px;
}

.pills a{
  display:flex;
  align-items:center;
  min-height:40px;
  padding:8px 14px;
  border:1px solid rgba(128,0,255,.5);
  border-radius:999px;
  background:rgba(128,0,255,.09);
  color:var(--txt);
  font-size:16px;
  line-height:1.3;
  text-decoration:none;
  transition:background .18s ease,box-shadow .18s ease,border-color .18s ease,color .18s ease;
}

.pills a:hover,
.pills a:focus-visible{
  background:rgba(255,0,255,.18);
  border-color:var(--mag);
  color:#fff;
  box-shadow:0 0 16px rgba(255,0,255,.45);
}

.pills a[aria-current="true"]{
  background:linear-gradient(90deg,rgba(128,0,255,.42),rgba(255,0,255,.34));
  border-color:var(--mag);
  color:#fff;
  box-shadow:0 0 18px rgba(255,0,255,.5);
}

.cta{
  margin-top:auto;
  display:flex;
  align-items:center;
  justify-content:center;
  min-height:46px;
  padding:10px 16px;
  border-radius:999px;
  background:linear-gradient(90deg,var(--pur),var(--mag));
  color:#fff;
  font-size:16px;
  letter-spacing:.1em;
  text-decoration:none;
  box-shadow:0 0 22px rgba(255,0,255,.42);
}

.cta:hover{box-shadow:0 0 30px rgba(255,0,255,.72)}

/* ---------- 主区 ---------- */
.main{
  min-width:0;
  padding:0 clamp(16px,4vw,54px) 56px;
}

.hero{
  display:grid;
  grid-template-columns:minmax(0,1fr) minmax(0,.92fr);
  gap:22px;
  align-items:center;
  min-height:45vh;
  padding:34px 0 24px;
  border-bottom:1px dashed rgba(255,0,255,.24);
}

.hero-copy{
  order:2;
  text-align:right;
}

.hero-art{
  order:1;
  position:relative;
  min-height:190px;
}

h1{
  margin:0 0 12px;
  font-size:clamp(30px,4.4vw,52px);
  line-height:1.14;
  letter-spacing:.01em;
  color:#fff;
  animation:neon 5.5s ease-in-out infinite alternate;
}

@keyframes neon{
  from{
    text-shadow:0 0 10px rgba(128,0,255,.95),0 0 22px rgba(255,0,255,.28);
    transform:skewX(0deg);
  }
  to{
    text-shadow:0 0 18px rgba(255,0,255,.95),0 0 38px rgba(128,0,255,.6);
    transform:skewX(-1.1deg);
  }
}

.lede{
  margin:0 0 0 auto;
  max-width:34ch;
  color:var(--dim);
  font-size:16px;
}

.shot{
  position:absolute;
  display:block;
  max-width:100%;
  height:auto;
  border:1px solid var(--line);
  border-radius:4px;
  box-shadow:0 20px 42px rgba(0,0,0,.62);
  filter:saturate(.92) contrast(1.06);
}

.shot.a{top:0;left:0;width:74%;transform:rotate(-2.4deg)}
.shot.b{bottom:-6px;right:0;width:58%;transform:rotate(2deg)}

.hero-art:empty{
  border:1px dashed rgba(128,0,255,.4);
  border-radius:4px;
}

/* ---------- 正文 ---------- */
.body{position:relative;padding-top:8px}

.body > .body-head{
  margin:22px 0 4px;
  font-family:var(--mono);
  font-size:13px;
  font-weight:400;
  letter-spacing:.34em;
  color:var(--faint);
  text-shadow:none;
}

.body > .body-head span{border:0;color:var(--mag);padding:0}

.body > article{
  position:relative;
  padding:26px 0 22px;
  border-top:1px solid rgba(255,0,255,.15);
  scroll-margin-top:18px;
}

.body > article:first-of-type{
  border-top:0;
  padding-top:14px;
}

.body > article:nth-of-type(odd)::before{
  content:"";
  position:absolute;
  left:-14px;
  top:26px;
  width:3px;
  height:26px;
  border-radius:2px;
  background:linear-gradient(180deg,var(--pur),transparent);
}

.body h2{
  margin:0 0 12px;
  font-size:clamp(22px,2.6vw,30px);
  line-height:1.26;
  color:#fff;
  text-shadow:0 0 14px rgba(128,0,255,.8);
}

.body h2 span{
  display:inline-block;
  padding-bottom:3px;
  border-bottom:2px dashed rgba(255,0,255,.55);
}

.body h3{
  margin:22px 0 8px;
  font-size:20px;
  color:#f4eeff;
}

.body h3 span{border-bottom:1px dotted rgba(128,0,255,.6)}

.body p{
  margin:0 0 14px;
  color:#ded7ea;
}

.body ul,
.body ol{
  margin:0 0 16px;
  padding-left:1.25em;
  color:#ded7ea;
}

.body li{margin:0 0 7px}

.body a{
  color:var(--mag);
  text-decoration:underline dotted;
  text-underline-offset:3px;
}

.body a:hover{color:#fff}

.body strong{color:#fff;text-shadow:0 0 10px rgba(255,0,255,.5)}

.body blockquote{
  margin:18px 0;
  padding:12px 16px;
  border-left:3px dashed var(--mag);
  border-radius:4px;
  background:rgba(128,0,255,.1);
  color:#eee6fa;
  transform:rotate(-.25deg);
}

.body blockquote p:last-child{margin:0}

.body img{
  max-width:100%;
  height:auto;
  border:1px solid var(--line);
  border-radius:4px;
}

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

.body th,
.body td{
  border:1px solid rgba(255,0,255,.2);
  padding:8px 10px;
  text-align:left;
}

.body th{background:rgba(128,0,255,.16);color:#fff}

/* 滚动进入 */
.fade{
  opacity:.001;
  transform:translateY(12px);
  transition:opacity .5s ease,transform .5s ease;
}

.fade.in{
  opacity:1;
  transform:none;
}

/* ---------- 页脚 ---------- */
.foot{
  grid-column:1 / -1;
  border-top:1px solid var(--line);
  padding:24px clamp(16px,4vw,54px) 40px;
}

.foot-cols{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:18px;
}

.foot dl{margin:0}

.foot dt{
  margin:0 0 6px;
  font-family:var(--mono);
  font-size:12px;
  letter-spacing:.26em;
  color:var(--mag);
}

.foot dd{margin:0}

.foot dd a{
  display:inline-flex;
  align-items:center;
  min-height:40px;
  padding:0 2px;
  color:var(--dim);
  font-size:16px;
  text-decoration:none;
}

.foot dd a:hover,
.foot dd a:focus-visible{color:#fff;text-shadow:0 0 10px var(--mag)}

.copy{
  margin:16px 0 0;
  font-family:var(--mono);
  font-size:12px;
  letter-spacing:.16em;
  color:var(--faint);
}

/* ---------- 断点 ---------- */
@media (max-width:920px){
  .wrap{grid-template-columns:minmax(0,1fr)}

  .rail{
    position:static;
    height:auto;
    border-right:0;
    border-bottom:1px solid var(--line);
    padding:16px 16px 18px;
    gap:10px;
  }

  .rail-line{display:none}

  .rail-head{display:none}

  .pills{
    flex-direction:row;
    flex-wrap:wrap;
    gap:8px;
  }

  .pills a{
    padding:8px 12px;
    font-size:16px;
  }

  .cta{
    margin-top:6px;
    align-self:flex-start;
    padding:10px 18px;
  }

  .main{padding:0 16px 40px}

  .hero{
    grid-template-columns:minmax(0,1fr);
    min-height:0;
    gap:16px;
    padding:20px 0 18px;
  }

  .hero-copy{order:1;text-align:left}

  .hero-art{order:2;min-height:170px}

  .lede{margin:0;max-width:none}

  .body > article:nth-of-type(odd)::before{left:-6px}

  .foot{padding:20px 16px 34px}
}

@media (max-width:560px){
  .foot-cols{grid-template-columns:minmax(0,1fr)}

  .foot dt{margin-bottom:2px}

  .hero-art{min-height:150px}
}

@media (prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}

  h1{animation:none}

  .fade{opacity:1;transform:none;transition:none}
}

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