:root {
  --red: #ff0000;
  --purple: #8b00ff;
  --ink: #261717;
  --glass: rgba(255, 255, 255, 0.10);
  --glass-strong: rgba(255, 255, 255, 0.16);
  --line: rgba(255, 255, 255, 0.2);
  --line-soft: rgba(255, 255, 255, 0.12);
  --text: #f7eff1;
  --body: rgba(255, 255, 255, 0.84);
  --muted: rgba(255, 255, 255, 0.58);
  --serif: "Cormorant Garamond", "Libre Baskerville", "Songti SC", "Noto Serif SC", Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --blur: 15px;
  --radius: 4px;
  --stick: 116px;
}

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

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

body {
  margin: 0;
  min-height: 100%;
  background-color: #170e0e;
  color: var(--text);
  font: 17px/1.78 var(--sans);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body::before,
body::after {
  content: "";
  position: fixed;
  z-index: -2;
  border-radius: 50%;
  filter: blur(70px);
  pointer-events: none;
  will-change: transform;
}

body::before {
  width: 58vmax;
  height: 58vmax;
  top: -20vmax;
  left: -16vmax;
  background: radial-gradient(circle at 42% 42%, rgba(255, 0, 0, 0.55), rgba(255, 0, 0, 0) 64%);
  animation: drift 28s ease-in-out infinite alternate;
}

body::after {
  width: 64vmax;
  height: 64vmax;
  right: -22vmax;
  bottom: -26vmax;
  background: radial-gradient(circle at 58% 58%, rgba(139, 0, 255, 0.6), rgba(139, 0, 255, 0) 66%);
  animation: drift 34s ease-in-out infinite alternate-reverse;
}

@keyframes drift {
  to { transform: translate3d(5vmax, 4vmax, 0) scale(1.14); }
}

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

a {
  color: #ffd6d6;
  text-decoration: none;
  transition: color 0.18s ease, background-color 0.18s ease, border-color 0.18s ease;
}

a:hover { color: #fff; }

:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 2px;
}

/* ---------- 顶部 ---------- */

.deck {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(31, 18, 18, 0.62);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  backdrop-filter: blur(18px) saturate(140%);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 12px 40px -30px #000;
}

.top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
}

.mark {
  order: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--glass-strong);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  flex: 0 0 auto;
}

.mark__img { width: 34px; height: 34px; border-radius: 50%; }

.mark__glyph {
  font-family: var(--serif);
  font-size: 1.25rem;
  color: #fff;
  line-height: 1;
}

.brand {
  order: 1;
  flex: 1 1 auto;
  margin: 0;
  font-family: var(--serif);
  font-size: 1.18rem;
  letter-spacing: 0.16em;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.nav {
  order: 3;
  flex: 1 0 100%;
  min-width: 0;
}

.nav p {
  display: flex;
  flex-wrap: nowrap;
  gap: 2px;
  margin: 0;
  padding: 0 0 2px;
  overflow-x: auto;
  scrollbar-width: none;
}

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

.nav a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 10px;
  border-radius: var(--radius);
  font-size: 0.94rem;
  color: var(--body);
  white-space: nowrap;
}

.nav a:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
}

.search { display: none; }

.menu { display: none; }

/* ---------- 锚点条 ---------- */

.anchors {
  display: flex;
  gap: 6px;
  padding: 6px 10px;
  overflow-x: auto;
  scrollbar-width: none;
  border-top: 1px solid var(--line-soft);
  background: linear-gradient(90deg, rgba(255, 0, 0, 0.18), rgba(139, 0, 255, 0.18));
}

.anchors::-webkit-scrollbar { display: none; }

.anchors a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid var(--line-soft);
  background: rgba(255, 255, 255, 0.07);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  font-size: 0.86rem;
  letter-spacing: 0.04em;
  color: var(--body);
  white-space: nowrap;
}

.anchors a:hover,
.anchors a.is-on {
  background: rgba(255, 255, 255, 0.22);
  border-color: var(--line);
  color: #fff;
}

/* ---------- 首屏 ---------- */

.stage { display: block; }

.hero {
  position: relative;
  isolation: isolate;
  display: grid;
  place-items: center;
  min-height: 70svh;
  padding: 40px 18px 56px;
  text-align: center;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image: radial-gradient(rgba(255, 255, 255, 0.18) 1px, transparent 1px);
  background-size: 22px 22px;
  opacity: 0.6;
  -webkit-mask-image: radial-gradient(circle at 50% 46%, #000 4%, transparent 74%);
  mask-image: radial-gradient(circle at 50% 46%, #000 4%, transparent 74%);
}

.hero__inner {
  max-width: 34rem;
  display: grid;
  justify-items: center;
  gap: 14px;
  animation: rise 0.7s cubic-bezier(0.2, 0.7, 0.3, 1) both;
}

.hero__badge {
  width: 78px;
  height: 78px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--glass-strong);
  -webkit-backdrop-filter: blur(var(--blur));
  backdrop-filter: blur(var(--blur));
  box-shadow: 0 18px 44px -24px rgba(255, 0, 0, 0.9), inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

.hero__img { width: 100%; height: 100%; object-fit: cover; }

.hero__glyph {
  font-family: var(--serif);
  font-size: 2rem;
  color: #fff;
  line-height: 1;
}

.hero__h1 {
  margin: 0;
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(2rem, 8.2vw, 3.5rem);
  line-height: 1.14;
  letter-spacing: 0.01em;
  color: #fff;
  text-shadow: 0 2px 30px rgba(255, 0, 0, 0.45), 0 1px 0 rgba(255, 255, 255, 0.25);
}

.hero__desc {
  margin: 0;
  max-width: 30rem;
  font-size: 0.98rem;
  line-height: 1.8;
  color: var(--muted);
}

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

/* ---------- 正文骨架 ---------- */

.sheet {
  display: block;
  max-width: 1180px;
  margin: 0 auto;
  padding: 6px 14px 48px;
}

.sheet > section {
  scroll-margin-top: var(--stick);
}

.rail {
  position: relative;
  margin-bottom: 18px;
  padding: 14px 14px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--glass-strong);
  -webkit-backdrop-filter: blur(var(--blur));
  backdrop-filter: blur(var(--blur));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.28);
}

.rail__eb {
  display: block;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  color: rgba(255, 255, 255, 0.5);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rail__title {
  margin: 2px 0 8px;
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.3rem;
  letter-spacing: 0.08em;
  color: #fff;
}

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

.rail__list li { counter-increment: rail; }

.rail__list a {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 40px;
  padding: 4px 8px;
  border-radius: var(--radius);
  font-size: 0.92rem;
  color: var(--body);
  border-bottom: 1px solid var(--line-soft);
}

.rail__list li:last-child a { border-bottom: 0; }

.rail__list a::before {
  content: counter(rail, decimal-leading-zero);
  font-family: var(--serif);
  font-size: 0.86rem;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.42);
}

.rail__list a:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
}

/* ---------- 正文分节 ---------- */

.sheet > section {
  position: relative;
  margin-bottom: 16px;
  padding: 22px 18px 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--glass);
  -webkit-backdrop-filter: blur(var(--blur)) saturate(130%);
  backdrop-filter: blur(var(--blur)) saturate(130%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22), 0 26px 50px -40px #000;
  animation: rise 0.55s cubic-bezier(0.2, 0.7, 0.3, 1) both;
}

.sheet > section:nth-of-type(1) { animation-delay: 0.04s; }
.sheet > section:nth-of-type(2) { animation-delay: 0.09s; }
.sheet > section:nth-of-type(3) { animation-delay: 0.14s; }
.sheet > section:nth-of-type(4) { animation-delay: 0.19s; }
.sheet > section:nth-of-type(5) { animation-delay: 0.24s; }
.sheet > section:nth-of-type(6) { animation-delay: 0.29s; }
.sheet > section:nth-of-type(7) { animation-delay: 0.34s; }

.sheet > section::after {
  content: "";
  position: absolute;
  left: 18px;
  right: 18px;
  top: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 0, 0, 0.7), rgba(139, 0, 255, 0.7), transparent);
}

.sheet > section > small {
  display: block;
  margin-bottom: 6px;
  font-size: 0.7rem;
  letter-spacing: 0.24em;
  color: rgba(255, 255, 255, 0.5);
}

.sheet > section h2 {
  margin: 0 0 12px;
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(1.4rem, 5.4vw, 2.05rem);
  line-height: 1.28;
  letter-spacing: 0.01em;
  color: #fff;
}

.sheet > section small + h2 { margin-top: 0; }

.sheet > section h3 {
  margin: 22px 0 10px;
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.2rem;
  line-height: 1.4;
  color: #fff;
}

.sheet > section p {
  margin: 0 0 1em;
  color: var(--body);
}

.sheet > section ul,
.sheet > section ol {
  margin: 0 0 1em;
  padding-left: 1.25em;
  color: var(--body);
}

.sheet > section li { margin: 0.4em 0; }

.sheet > section li::marker { color: rgba(255, 0, 0, 0.8); }

.sheet > section strong { color: #fff; }

.sheet > section a {
  color: #ffc0c0;
  border-bottom: 1px solid rgba(255, 0, 0, 0.55);
}

.sheet > section a:hover {
  color: #fff;
  border-bottom-color: #fff;
}

.sheet > section blockquote {
  margin: 0 0 1em;
  padding: 12px 14px;
  border-left: 2px solid var(--purple);
  border-radius: 0 var(--radius) var(--radius) 0;
  background: rgba(255, 255, 255, 0.08);
  color: var(--body);
}

.sheet > section blockquote p:last-child { margin-bottom: 0; }

.sheet > section img {
  margin: 6px 0 14px;
  border-radius: var(--radius);
  border: 1px solid var(--line-soft);
}

.sheet > section table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1em;
  font-size: 0.95rem;
}

.sheet > section th,
.sheet > section td {
  padding: 8px 10px;
  border-bottom: 1px solid var(--line-soft);
  text-align: left;
}

.sheet > section th { color: #fff; font-weight: 600; }

/* ---------- 页脚 ---------- */

.foot {
  display: grid;
  gap: 22px;
  padding: 34px 16px 18px;
  border-top: 1px solid var(--line);
  background: rgba(24, 14, 14, 0.68);
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
}

.foot__big {
  margin: 0;
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(2.4rem, 13vw, 5rem);
  line-height: 0.94;
  letter-spacing: 0.02em;
  background: linear-gradient(96deg, #fff 8%, #ff9a9a 46%, #c98bff 92%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.foot__desc {
  margin: 12px 0 0;
  max-width: 32rem;
  font-size: 0.94rem;
  color: var(--muted);
}

.foot__map p {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 14px;
}

.foot__map a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  font-size: 0.94rem;
  color: var(--body);
}

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

.foot__base {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding-top: 14px;
  border-top: 1px solid var(--line-soft);
}

.foot__base p { margin: 0; font-size: 0.84rem; color: var(--muted); }

.foot__top a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--body);
}

.foot__top a:hover { background: rgba(255, 255, 255, 0.16); color: #fff; }

/* ---------- 桌面 ---------- */

@media (min-width: 900px) {
  :root { --stick: 128px; }

  .top { flex-wrap: nowrap; gap: 14px; padding: 10px 22px; }

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

  .nav p { flex-wrap: wrap; overflow: visible; }

  .brand { flex: 0 0 auto; }

  .search {
    display: flex;
    order: 3;
    align-items: center;
    gap: 6px;
    padding: 3px 4px 3px 12px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
  }

  .search__label {
    font-size: 0.78rem;
    letter-spacing: 0.14em;
    color: var(--muted);
  }

  .search__input {
    width: 112px;
    min-height: 34px;
    border: 0;
    background: transparent;
    color: #fff;
    font: inherit;
    font-size: 0.9rem;
    outline: none;
  }

  .search__btn {
    min-height: 34px;
    padding: 0 14px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: linear-gradient(100deg, rgba(255, 0, 0, 0.55), rgba(139, 0, 255, 0.55));
    color: #fff;
    font: inherit;
    font-size: 0.84rem;
    cursor: pointer;
  }

  .search__btn:hover { filter: brightness(1.15); }

  .menu { display: block; order: 4; position: relative; }

  .menu__sum {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    padding: 0 14px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--glass);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    font-size: 0.88rem;
    color: var(--body);
    cursor: pointer;
    list-style: none;
  }

  .menu__sum::-webkit-details-marker { display: none; }

  .menu[open] .menu__sum { color: #fff; background: rgba(255, 255, 255, 0.2); }

  .menu__panel {
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px 18px;
    padding: 12px 16px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(38, 23, 23, 0.86);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    box-shadow: 0 24px 50px -30px #000;
  }

  .menu__col { display: grid; gap: 2px; }

  .menu__col a {
    display: flex;
    align-items: center;
    min-height: 40px;
    padding: 0 8px;
    border-radius: var(--radius);
    font-size: 0.9rem;
    color: var(--body);
    white-space: nowrap;
  }

  .menu__col a:hover { background: rgba(255, 255, 255, 0.14); color: #fff; }

  .hero { padding: 64px 24px 80px; }

  .hero__inner { gap: 20px; }

  .sheet {
    display: grid;
    grid-template-columns: 216px minmax(0, 1fr);
    gap: 26px;
    padding: 40px 24px 64px;
    align-items: start;
  }

  .rail {
    grid-column: 1;
    align-self: start;
    position: sticky;
    top: calc(var(--stick) + 8px);
    margin-bottom: 0;
  }

  .sheet > section {
    grid-column: 2;
    margin-bottom: 0;
    padding: 30px 32px 32px;
  }

  .foot {
    grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
    gap: 28px 40px;
    padding: 52px 28px 22px;
  }

  .foot__base { grid-column: 1 / -1; }
}

@media (min-width: 1180px) {
  .hero__desc { font-size: 1.02rem; }
  .sheet { grid-template-columns: 240px minmax(0, 1fr); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  body::before,
  body::after,
  .hero__inner,
  .sheet > section { animation: none !important; }
  a { transition: none !important; }
}

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