:root {
  --pink: #ff0080;
  --magenta: #ff00ff;
  --ink: #26171f;
  --bg: #12080f;
  --text: #f7ecf3;
  --dim: #cba9bd;
  --line: rgba(255, 0, 128, 0.26);
  --line-soft: rgba(255, 255, 255, 0.1);
  --rail: 224px;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--bg);
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100%;
  color: var(--text);
  background: transparent;
  font-family: 'Inter', system-ui, -apple-system, 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  font-size: 17px;
  line-height: 1.75;
  overflow-x: hidden;
}

body::before {
  content: '';
  position: fixed;
  inset: -22%;
  z-index: -2;
  pointer-events: none;
  background:
    radial-gradient(38% 42% at 16% 20%, rgba(255, 0, 128, 0.6), transparent 62%),
    radial-gradient(32% 38% at 80% 10%, rgba(255, 0, 255, 0.48), transparent 60%),
    radial-gradient(46% 44% at 66% 80%, rgba(255, 0, 128, 0.34), transparent 66%),
    radial-gradient(38% 36% at 10% 86%, rgba(122, 0, 255, 0.32), transparent 62%),
    conic-gradient(from 210deg at 72% 42%, rgba(255, 0, 255, 0.3), rgba(255, 0, 128, 0.1), rgba(0, 214, 255, 0.18), rgba(255, 0, 255, 0.3));
  filter: blur(42px) saturate(145%);
  mix-blend-mode: screen;
  opacity: 0.82;
  animation: aurora-drift 28s ease-in-out infinite alternate;
}

body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
  background-size: 88px 88px;
  -webkit-mask-image: radial-gradient(82% 72% at 46% 40%, #000 20%, transparent 88%);
  mask-image: radial-gradient(82% 72% at 46% 40%, #000 20%, transparent 88%);
}

@keyframes aurora-drift {
  0% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(-3%, 2.5%, 0) scale(1.09); }
  100% { transform: translate3d(3%, -2.5%, 0) scale(1.04); }
}

a {
  color: var(--text);
  text-decoration: none;
}

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

/* ---------- 左侧竖排栏 ---------- */
.rail {
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  width: var(--rail);
  z-index: 30;
  display: flex;
  flex-direction: column;
  gap: 22px;
  padding: 20px 14px 26px;
  border-right: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(38, 23, 31, 0.94), rgba(18, 8, 15, 0.9));
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
}

.brand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  background: linear-gradient(140deg, rgba(255, 0, 128, 0.28), rgba(255, 0, 255, 0.14));
  transition: border-color 0.3s ease, transform 0.3s ease;
}

.brand:hover,
.brand:focus-visible {
  border-color: var(--magenta);
  transform: translateY(-2px);
}

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

.brand-letter {
  font-weight: 800;
  font-size: 20px;
  letter-spacing: -0.02em;
  color: #fff;
}

.rail nav {
  min-height: 0;
  overflow-y: auto;
  scrollbar-width: thin;
}

.rail ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.rail nav a {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid transparent;
  color: var(--dim);
  font-size: 16px;
  line-height: 1.3;
  transition: color 0.25s ease, background 0.25s ease, border-color 0.25s ease, transform 0.25s ease;
}

.rail nav .ico {
  flex: 0 0 auto;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  border: 1px solid var(--pink);
  background: transparent;
  transition: background 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
}

.rail nav a:hover,
.rail nav a:focus-visible {
  color: #fff;
  background: linear-gradient(100deg, rgba(255, 0, 128, 0.22), rgba(255, 0, 255, 0.08));
  border-color: var(--line);
  transform: translateX(3px);
}

.rail nav a:hover .ico,
.rail nav a:focus-visible .ico {
  background: var(--magenta);
  box-shadow: 0 0 12px rgba(255, 0, 255, 0.8);
  transform: scale(1.15);
}

/* ---------- 首屏 ---------- */
main {
  margin-left: var(--rail);
  min-width: 0;
}

.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 90px 5vw 78px;
  overflow: hidden;
}

.hero-art {
  position: absolute;
  inset: 0 0 0 30%;
  z-index: 0;
  will-change: transform;
}

.tile {
  position: absolute;
  margin: 0;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 18px;
  background: linear-gradient(150deg, rgba(255, 0, 128, 0.55), rgba(255, 0, 255, 0.26) 60%, rgba(0, 214, 255, 0.22));
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.2) inset;
}

.tile-1 {
  width: 42%;
  aspect-ratio: 3 / 4;
  top: 11%;
  right: 40%;
  transform: rotate(-7deg);
}

.tile-2 {
  width: 38%;
  aspect-ratio: 3 / 4;
  top: 24%;
  right: 5%;
  transform: rotate(6deg);
}

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

.tile-fill {
  display: block;
  width: 100%;
  height: 100%;
  background: linear-gradient(140deg, rgba(255, 0, 128, 0.7), rgba(255, 0, 255, 0.35), rgba(0, 214, 255, 0.25));
}

.hero-copy {
  position: relative;
  z-index: 2;
  text-align: right;
}

.hero-copy h1 {
  margin: 0;
  font-weight: 800;
  font-size: clamp(42px, 8.4vw, 122px);
  line-height: 0.98;
  letter-spacing: -0.035em;
  background: linear-gradient(100deg, #ffffff 6%, #ffd9ec 32%, var(--pink) 62%, var(--magenta) 96%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 6px 26px rgba(255, 0, 128, 0.35));
}

.hero-band {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 8px;
  z-index: 3;
  background: linear-gradient(90deg, var(--pink), var(--magenta) 46%, #00d6ff 100%);
}

.hero::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 168px;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(180deg, transparent, rgba(18, 8, 15, 0.88) 72%);
  -webkit-clip-path: polygon(0 62%, 100% 0, 100% 100%, 0 100%);
  clip-path: polygon(0 62%, 100% 0, 100% 100%, 0 100%);
}

/* ---------- 正文 ---------- */
.wrap {
  max-width: 1000px;
  margin: 0 auto;
  padding: 58px 5vw 96px;
}

.wrap-head {
  margin-bottom: 36px;
}

.wrap-head h2 {
  margin: 0;
  font-size: clamp(26px, 3.4vw, 40px);
  line-height: 1.2;
  letter-spacing: -0.02em;
  font-weight: 800;
  background: linear-gradient(96deg, #fff, #ffb7dd 55%, var(--magenta));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.subtitle {
  margin: 10px 0 0;
  padding-left: 14px;
  border-left: 3px solid var(--pink);
  color: var(--dim);
  font-size: 16.5px;
  line-height: 1.7;
  max-width: 62ch;
}

.content div > article {
  position: relative;
  margin: 0 0 26px;
  padding: 30px 26px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(158deg, rgba(255, 0, 128, 0.09), rgba(255, 0, 255, 0.035) 46%, rgba(18, 8, 15, 0.2) 76%);
  transition: border-color 0.35s ease, transform 0.35s ease, background 0.35s ease;
}

.content div > article:hover {
  border-color: rgba(255, 0, 255, 0.6);
  background: linear-gradient(158deg, rgba(255, 0, 128, 0.14), rgba(255, 0, 255, 0.06) 48%, rgba(18, 8, 15, 0.2) 78%);
  transform: translateY(-3px);
}

.content div > :first-child,
.content div > article > :first-child {
  margin-top: 0;
}

.content div > article > :last-child {
  margin-bottom: 0;
}

.content div h2 {
  position: relative;
  margin: 0 0 14px;
  padding-left: 16px;
  font-size: clamp(22px, 2.9vw, 30px);
  line-height: 1.28;
  letter-spacing: -0.015em;
  font-weight: 800;
  color: #fff;
}

.content div h2::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.32em;
  width: 5px;
  height: 1.05em;
  border-radius: 4px;
  background: linear-gradient(180deg, var(--pink), var(--magenta));
}

.content div h3 {
  margin: 24px 0 10px;
  font-size: 19px;
  line-height: 1.4;
  font-weight: 700;
  color: #ffe4f2;
}

.content div p {
  margin: 0 0 15px;
  color: #ecdee7;
}

.content div strong {
  color: #fff;
  font-weight: 700;
  background: linear-gradient(180deg, transparent 62%, rgba(255, 0, 128, 0.42) 62%);
  padding: 0 2px;
}

.content div a {
  color: #ffb3dd;
  text-decoration: underline;
  text-decoration-color: rgba(255, 0, 128, 0.7);
  text-underline-offset: 3px;
}

.content div ul,
.content div ol {
  margin: 0 0 16px;
  padding-left: 22px;
}

.content div li {
  margin: 0 0 8px;
  color: #ecdee7;
}

.content div li::marker {
  color: var(--pink);
}

.content div blockquote {
  margin: 0 0 16px;
  padding: 12px 18px;
  border-left: 3px solid var(--magenta);
  border-radius: 0 12px 12px 0;
  background: rgba(255, 0, 255, 0.08);
  color: #f3deeb;
}

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

.content div code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 15px;
  padding: 1px 6px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.1);
}

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

.content div th,
.content div td {
  border: 1px solid var(--line);
  padding: 9px 12px;
  text-align: left;
}

.content div th {
  background: rgba(255, 0, 128, 0.14);
  color: #fff;
}

.content div img {
  border-radius: 14px;
}

.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s ease, transform 0.6s ease,
    border-color 0.35s ease, background 0.35s ease;
}

.reveal.is-in {
  opacity: 1;
  transform: none;
}

/* ---------- 页脚 ---------- */
footer {
  margin-left: var(--rail);
  border-top: 1px solid var(--line);
  padding: 46px 5vw 30px;
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  gap: 28px 40px;
  background: linear-gradient(180deg, rgba(38, 23, 31, 0.72), rgba(18, 8, 15, 0.92));
}

footer article {
  min-width: 0;
}

.foot-name {
  margin: 0 0 8px;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: #fff;
}

.foot-desc {
  margin: 0;
  max-width: 44ch;
  color: var(--dim);
  font-size: 16px;
  line-height: 1.7;
}

.foot-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2px 12px;
}

.foot-nav a {
  display: block;
  padding: 10px 0;
  min-height: 44px;
  color: var(--dim);
  font-size: 16px;
  line-height: 1.5;
  border-bottom: 1px solid transparent;
  transition: color 0.25s ease, border-color 0.25s ease;
}

.foot-nav a:hover,
.foot-nav a:focus-visible {
  color: #fff;
  border-bottom-color: var(--magenta);
}

.foot-base {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 18px;
  border-top: 1px solid var(--line-soft);
}

.foot-base p {
  margin: 0;
}

.copy {
  color: #a98a9b;
  font-size: 16px;
}

.totop a {
  display: inline-block;
  padding: 10px 16px;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 12px;
  color: var(--dim);
  font-size: 16px;
  line-height: 1.5;
  transition: color 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}

.totop a:hover,
.totop a:focus-visible {
  color: #fff;
  border-color: var(--magenta);
  background: rgba(255, 0, 255, 0.14);
}

:focus-visible {
  outline: 2px solid var(--magenta);
  outline-offset: 2px;
}

/* ---------- 响应式 ---------- */
@media (max-width: 1000px) {
  .hero-copy h1 {
    font-size: clamp(40px, 9vw, 92px);
  }
}

@media (max-width: 860px) {
  :root {
    --rail: 0px;
  }

  .rail {
    position: sticky;
    top: 0;
    left: auto;
    bottom: auto;
    width: auto;
    height: auto;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    padding: 9px 12px;
    overflow: hidden;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .brand {
    width: 42px;
    height: 42px;
    flex: 0 0 auto;
  }

  .rail nav {
    flex: 1 1 auto;
    min-width: 0;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
  }

  .rail nav::-webkit-scrollbar {
    display: none;
  }

  .rail ul {
    flex-direction: row;
    gap: 4px;
  }

  .rail nav a {
    padding: 10px 12px;
    white-space: nowrap;
  }

  .rail nav a:hover {
    transform: none;
  }

  main,
  footer {
    margin-left: 0;
  }

  .hero {
    min-height: 0;
    padding: 22px 20px 56px;
  }

  .hero-art {
    position: relative;
    inset: auto;
    height: 210px;
    margin: 6px 0 26px;
  }

  .tile-1 {
    width: 50%;
    aspect-ratio: 4 / 3;
    top: 0;
    right: 46%;
  }

  .tile-2 {
    width: 46%;
    aspect-ratio: 4 / 3;
    top: 18%;
    right: 2%;
  }

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

  .hero-copy h1 {
    font-size: clamp(38px, 11.5vw, 62px);
  }

  .hero::after {
    height: 90px;
  }

  .wrap {
    padding: 38px 20px 64px;
  }

  .content div > article {
    padding: 24px 18px;
  }

  .content div > article:hover {
    transform: none;
  }

  article[id] {
    scroll-margin-top: 74px;
  }

  footer {
    grid-template-columns: minmax(0, 1fr);
    padding: 36px 20px 26px;
  }

  .foot-nav ul {
    grid-template-columns: minmax(0, 1fr);
  }

  .foot-base {
    flex-wrap: wrap;
  }
}

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

  body::before {
    animation: none;
  }

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

  .content div > article,
  .brand,
  .rail nav a,
  .foot-nav a,
  .totop a {
    transition: none;
  }

  .content div > article:hover,
  .brand:hover {
    transform: none;
  }
}

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