@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@300;400;500;700&display=swap');

:root {
  --ink: #26171f;
  --mag: #ff0080;
  --vio: #ff00ff;
  --bg: #120a10;
  --txt: #f7eef4;
  --dim: #cbb2c1;
  --line: rgba(255, 255, 255, 0.15);
  --soft: rgba(255, 255, 255, 0.045);
  --r: 18px;
}

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

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

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--txt);
  font-family: 'Noto Sans SC', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', system-ui, sans-serif;
  font-size: 17px;
  font-weight: 300;
  line-height: 1.78;
  letter-spacing: 0.012em;
  overflow-x: hidden;
}

body::before {
  content: '';
  position: fixed;
  inset: -12%;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(42% 46% at 14% 18%, rgba(255, 0, 128, 0.55), transparent 62%),
    radial-gradient(38% 42% at 86% 8%, rgba(255, 0, 255, 0.42), transparent 64%),
    radial-gradient(52% 54% at 72% 88%, rgba(150, 0, 110, 0.55), transparent 66%),
    conic-gradient(from 210deg at 52% 50%, rgba(255, 0, 128, 0.22), rgba(255, 0, 255, 0.16), rgba(18, 10, 16, 0.96), rgba(255, 0, 128, 0.22));
  filter: blur(48px) saturate(150%);
  opacity: 0.86;
  transform: scale(1.02);
  animation: aurora 28s ease-in-out infinite alternate;
}

@keyframes aurora {
  0% {
    transform: scale(1.02) translate3d(0, 0, 0);
    filter: blur(48px) saturate(150%) hue-rotate(0deg);
  }
  50% {
    transform: scale(1.1) translate3d(-2%, 2%, 0);
    filter: blur(56px) saturate(165%) hue-rotate(24deg);
  }
  100% {
    transform: scale(1.04) translate3d(2%, -2%, 0);
    filter: blur(48px) saturate(150%) hue-rotate(-16deg);
  }
}

.page {
  position: relative;
  z-index: 1;
}

a {
  color: inherit;
}

/* 顶栏：图标角落 + 胶囊导航 */
.bar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 18px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(18, 10, 16, 0.94), rgba(18, 10, 16, 0.62));
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
}

.mark {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid rgba(255, 0, 128, 0.6);
  background: rgba(255, 0, 128, 0.12);
  text-decoration: none;
  overflow: hidden;
  transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.3, 1), box-shadow 0.35s ease;
}

.mark img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.mark-glyph {
  font-size: 1.02rem;
  font-weight: 500;
  letter-spacing: 0;
  color: #fff;
}

.mark:hover {
  transform: rotate(-8deg) scale(1.06);
  box-shadow: 0 0 0 4px rgba(255, 0, 255, 0.16);
}

.bar nav {
  flex: 1 1 auto;
  min-width: 0;
}

.bar nav p {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
}

.bar nav a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 6px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 400;
  color: var(--txt);
  text-decoration: none;
  background: var(--soft);
  white-space: nowrap;
  transition: color 0.25s ease, border-color 0.25s ease, background 0.35s ease, transform 0.25s ease;
}

.bar nav a:hover,
.bar nav a:focus-visible {
  border-color: transparent;
  color: #fff;
  background: linear-gradient(92deg, var(--mag), var(--vio));
  transform: translateY(-1px);
}

/* 首屏 */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: 42px;
  align-items: center;
  max-width: 1180px;
  margin: 0 auto;
  padding: 62px 28px 48px;
  min-height: calc(100svh - 62px);
}

.eyebrow {
  margin: 0 0 14px;
  font-size: 0.86rem;
  font-weight: 400;
  letter-spacing: 0.28em;
  color: var(--dim);
  text-transform: none;
}

.eyebrow span {
  display: inline-block;
  padding-left: 14px;
  border-left: 2px solid var(--mag);
}

.hero h1 {
  margin: 0 0 18px;
  font-size: clamp(2.05rem, 5.4vw, 3.7rem);
  font-weight: 700;
  line-height: 1.22;
  letter-spacing: -0.02em;
  background: linear-gradient(98deg, #ffffff 8%, #ffd6ea 40%, #ff7ec2 72%, #ff5cf0 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lede {
  margin: 0 0 26px;
  max-width: 34em;
  font-size: 1.03rem;
  color: var(--dim);
}

.jump {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0;
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 20px;
  border-radius: 999px;
  border: 1px solid rgba(255, 0, 128, 0.5);
  font-size: 0.94rem;
  font-weight: 400;
  text-decoration: none;
  color: #fff;
  background: rgba(255, 0, 128, 0.1);
  transition: background 0.35s ease, border-color 0.3s ease, transform 0.3s ease;
}

.pill:hover,
.pill:focus-visible {
  background: linear-gradient(92deg, var(--mag), var(--vio));
  border-color: transparent;
  transform: translateY(-2px);
}

.hero-art {
  position: relative;
  aspect-ratio: 4 / 5;
  max-height: 68vh;
  border: 1px solid var(--line);
  border-radius: var(--r);
  overflow: hidden;
  background: rgba(38, 23, 31, 0.55);
}

.hero-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mesh {
  position: absolute;
  inset: -30%;
  background:
    conic-gradient(from 40deg at 40% 40%, #ff0080, #ff00ff, #7a0d4d, #ff0080),
    radial-gradient(60% 60% at 70% 70%, rgba(255, 255, 255, 0.5), transparent 60%);
  background-blend-mode: screen;
  filter: blur(26px) saturate(150%);
  animation: morph 18s linear infinite alternate;
}

@keyframes morph {
  0% {
    transform: rotate(0deg) scale(1.05);
    filter: blur(26px) saturate(150%) hue-rotate(0deg);
  }
  100% {
    transform: rotate(26deg) scale(1.18);
    filter: blur(34px) saturate(170%) hue-rotate(46deg);
  }
}

/* 内容区：左栏目录 + 正文 */
.cols {
  display: grid;
  grid-template-columns: 232px minmax(0, 1fr);
  gap: 46px;
  align-items: start;
  max-width: 1180px;
  margin: 0 auto;
  padding: 26px 28px 0;
}

.rail {
  position: sticky;
  top: 84px;
  align-self: start;
  padding: 20px 18px;
  border: 1px solid var(--line);
  border-radius: var(--r);
  background: rgba(38, 23, 31, 0.5);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  font-size: 0.94rem;
}

.rail h2 {
  margin: 0 0 12px;
  font-size: 0.78rem;
  font-weight: 400;
  letter-spacing: 0.3em;
  color: var(--dim);
}

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

.rail li {
  counter-increment: rail;
}

.rail ol a {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 40px;
  padding: 2px 0;
  text-decoration: none;
  color: var(--txt);
  font-weight: 300;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.09);
  transition: color 0.25s ease, border-color 0.25s ease;
}

.rail ol a::before {
  content: counter(rail, decimal-leading-zero);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  color: var(--mag);
  font-variant-numeric: tabular-nums;
}

.rail ol a:hover,
.rail ol a:focus-visible {
  color: #ff86c6;
  border-color: rgba(255, 0, 128, 0.6);
}

.rail .up {
  margin: 14px 0 0;
}

.rail .up a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 0.84rem;
  text-decoration: none;
  color: var(--dim);
  transition: color 0.25s ease, border-color 0.25s ease;
}

.rail .up a:hover {
  color: #fff;
  border-color: var(--mag);
}

/* 正文排版 */
.prose {
  min-width: 0;
  padding-bottom: 30px;
}

.prose article {
  padding: 46px 0;
  border-top: 1px solid var(--line);
}

.prose article:first-child {
  padding-top: 6px;
  border-top: 0;
}

.prose article[id] {
  scroll-margin-top: 112px;
}

.prose h2 {
  margin: 0 0 0.6em;
  font-size: 1.55rem;
  font-weight: 500;
  line-height: 1.36;
  letter-spacing: -0.01em;
}

.prose h3 {
  margin: 1.6em 0 0.5em;
  font-size: 1.16rem;
  font-weight: 500;
  line-height: 1.45;
}

.prose h2 span,
.prose h3 span {
  background: linear-gradient(96deg, #ffffff 10%, #ff9ad2 55%, #ff4df0 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  box-decoration-break: clone;
}

.prose p {
  margin: 0 0 1.05em;
  color: #efe3ec;
  max-width: 40em;
}

.prose a {
  color: #ff8ccb;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}

.prose a:hover {
  color: #fff;
}

.prose ul,
.prose ol {
  margin: 0 0 1.15em;
  padding-left: 1.15em;
  max-width: 40em;
}

.prose li {
  margin: 0.42em 0;
}

.prose li::marker {
  color: var(--mag);
}

.prose blockquote {
  margin: 0 0 1.1em;
  padding: 16px 20px;
  border: 1px solid var(--line);
  border-left: 2px solid var(--mag);
  border-radius: var(--r);
  background: var(--soft);
  color: var(--dim);
}

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

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

.prose figure {
  margin: 0 0 1.2em;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--r);
  background: var(--soft);
}

.prose figcaption {
  margin-top: 8px;
  font-size: 0.88rem;
  color: var(--dim);
}

.prose table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 1.2em;
  font-size: 0.95rem;
  border: 1px solid var(--line);
  border-radius: var(--r);
  overflow: hidden;
}

.prose th,
.prose td {
  padding: 10px 12px;
  text-align: left;
  border-bottom: 1px solid var(--line);
}

.prose th {
  font-weight: 500;
  background: rgba(255, 0, 128, 0.09);
}

.prose tr:last-child td {
  border-bottom: 0;
}

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

.prose hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 1.6em 0;
}

.prose > article > strong:first-child,
.prose > article > b:first-child {
  display: block;
}

/* 页脚：大 CTA + 底栏 */
footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 24px;
  max-width: 1180px;
  margin: 70px auto 0;
  padding: 54px 28px 44px;
  border-top: 1px solid var(--line);
}

.cta {
  flex: 1 1 100%;
  margin: 0;
}

.cta a {
  display: inline-block;
  padding-bottom: 6px;
  font-size: clamp(1.55rem, 4.2vw, 2.5rem);
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: -0.01em;
  text-decoration: none;
  color: #fff;
  border-bottom: 2px solid var(--mag);
  background: linear-gradient(96deg, #ffffff, #ff8ed0);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  transition: border-color 0.3s ease, transform 0.3s ease;
}

.cta a:hover,
.cta a:focus-visible {
  border-color: var(--vio);
  transform: translateX(4px);
}

.copy {
  margin: 0;
  font-size: 0.88rem;
  color: var(--dim);
}

.fl {
  display: flex;
  gap: 16px;
  margin-left: auto;
  font-size: 0.88rem;
}

.fl a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 4px;
  color: var(--dim);
  text-decoration: none;
  transition: color 0.25s ease;
}

.fl a:hover {
  color: #ff8ccb;
}

:focus-visible {
  outline: 2px solid var(--vio);
  outline-offset: 3px;
  border-radius: 4px;
}

/* 滚动浮现 */
.js .reveal {
  opacity: 0;
  transform: translateY(20px);
}

.js .reveal.in {
  opacity: 1;
  transform: none;
  transition: opacity 0.65s ease, transform 0.7s cubic-bezier(0.2, 0.75, 0.3, 1);
}

@media (max-width: 860px) {
  body {
    font-size: 16.5px;
  }

  .bar {
    padding: 8px 14px;
    gap: 10px;
  }

  .bar nav p {
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
    padding-bottom: 2px;
  }

  .bar nav p::-webkit-scrollbar {
    display: none;
  }

  .hero {
    grid-template-columns: 1fr;
    gap: 30px;
    padding: 40px 20px 34px;
    min-height: 0;
  }

  .hero-art {
    aspect-ratio: 16 / 11;
    max-height: none;
  }

  .cols {
    grid-template-columns: 1fr;
    gap: 26px;
    padding: 18px 20px 0;
  }

  .rail {
    position: static;
  }

  .rail ol {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 8px;
  }

  .rail ol a {
    min-height: 40px;
    padding: 4px 12px;
    border: 1px solid var(--line);
    border-radius: 999px;
    border-bottom: 1px solid var(--line);
    font-size: 0.88rem;
  }

  .prose article {
    padding: 34px 0;
  }

  .prose h2 {
    font-size: 1.35rem;
  }

  footer {
    padding: 40px 20px 36px;
    margin-top: 48px;
  }

  .fl {
    margin-left: 0;
    flex: 1 1 100%;
  }
}

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

  body::before,
  .mesh {
    animation: none;
  }

  .js .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  * {
    transition-duration: 0.01ms !important;
  }
}

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