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

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

:root {
  --ink: #0d0d0d;
  --ink-2: #140f1d;
  --ink-3: #1a1226;
  --violet: #8000ff;
  --magenta: #ff00ff;
  --neon: #cbb0ff;
  --text: #e8e2f4;
  --dim: #9b91ad;
  --line: rgba(128, 0, 255, 0.34);
  --line-hot: rgba(255, 0, 255, 0.4);
}

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

body {
  margin: 0;
  background: var(--ink);
  color: var(--text);
  font-family: Montserrat, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.72;
  overflow-x: hidden;
  background-image:
    radial-gradient(900px 420px at 12% -10%, rgba(128, 0, 255, 0.22), transparent 70%),
    radial-gradient(700px 380px at 92% 4%, rgba(255, 0, 255, 0.14), transparent 72%);
  background-repeat: no-repeat;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 60;
  pointer-events: none;
  background: repeating-linear-gradient(180deg, rgba(150, 90, 255, 0.055) 0 1px, transparent 1px 3px);
}

img { max-width: 100%; }
a { color: var(--neon); }

/* ---------- 顶栏 ---------- */

.hud-top {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 0.8rem;
  padding: 0.5rem clamp(0.9rem, 4vw, 2.4rem);
  border-bottom: 1px solid rgba(255, 0, 255, 0.2);
  background: linear-gradient(180deg, #150c22 0%, #0d0d0d 100%);
}

.nav-drawer {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  justify-self: start;
  min-width: 0;
}

.nav-drawer > summary {
  list-style: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 0.85rem;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: rgba(128, 0, 255, 0.12);
  color: var(--neon);
  font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  font-size: 0.76rem;
  letter-spacing: 0.2em;
}

.nav-drawer > summary::-webkit-details-marker { display: none; }

.nav-drawer > summary::after {
  content: "+";
  margin-left: 0.4rem;
  color: var(--magenta);
  font-size: 0.9rem;
}

.nav-drawer[open] > summary::after { content: "-"; }

.nav-pack {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.1rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-pack a {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 0 0.6rem;
  border-radius: 4px;
  color: var(--text);
  text-decoration: none;
  font-size: 0.84rem;
  transition: color 0.16s, background 0.16s, box-shadow 0.16s;
}

.nav-pack a:hover,
.nav-pack a:focus-visible {
  color: #fff;
  background: rgba(128, 0, 255, 0.24);
  box-shadow: inset 0 0 0 1px var(--line-hot);
}

.brand {
  justify-self: center;
  font-family: Cormorant, Georgia, serif;
  font-size: clamp(1.2rem, 2.4vw, 1.6rem);
  font-weight: 600;
  letter-spacing: 0.16em;
  color: #fff;
  text-decoration: none;
  padding: 0.4rem 0.8rem;
  border: 1px solid var(--line-hot);
  border-radius: 4px;
  background: rgba(255, 0, 255, 0.07);
  text-shadow: 0 0 14px rgba(255, 0, 255, 0.75);
  white-space: nowrap;
}

.top-tail {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 0.1rem;
}

.cta {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  margin-left: 0.5rem;
  padding: 0 1rem;
  border-radius: 4px;
  background: var(--magenta);
  color: #0d0d0d;
  text-decoration: none;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  box-shadow: 0 0 18px rgba(255, 0, 255, 0.55);
}

.cta:hover { background: #fff; box-shadow: 0 0 22px rgba(255, 0, 255, 0.9); }

/* ---------- 粘性锚点条 ---------- */

.hud-strip {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(13, 13, 13, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(7px);
}

.hud-strip ol {
  display: flex;
  gap: 0.1rem;
  margin: 0;
  padding: 0.3rem clamp(0.5rem, 3vw, 2rem);
  list-style: none;
  overflow-x: auto;
  scrollbar-width: none;
}

.hud-strip ol::-webkit-scrollbar { display: none; }

.hud-strip a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 0.7rem;
  border-radius: 4px;
  color: var(--dim);
  text-decoration: none;
  font-size: 0.8rem;
  white-space: nowrap;
  transition: color 0.16s, background 0.16s;
}

.hud-strip a:hover,
.hud-strip a:focus-visible {
  color: #fff;
  background: rgba(128, 0, 255, 0.24);
  text-shadow: 0 0 10px var(--magenta);
}

.n, .hud-strip .n {
  font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  font-size: 0.7rem;
  color: var(--magenta);
  margin-right: 0.42rem;
  letter-spacing: 0.08em;
}

/* ---------- 容器 ---------- */

.wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 clamp(1rem, 4vw, 2.4rem);
}

/* ---------- 头图区 ---------- */

.hero {
  padding: clamp(1.2rem, 3vw, 2rem) 0 1.5rem;
  border-bottom: 1px solid rgba(128, 0, 255, 0.24);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.88fr) minmax(0, 1.12fr);
  gap: clamp(1.2rem, 4vw, 3rem);
  align-items: center;
  min-height: 45vh;
}

.hero-grid.solo { grid-template-columns: minmax(0, 1fr); }

.hero-fig {
  position: relative;
  margin: 0;
  border-radius: 4px;
  overflow: hidden;
  background: var(--ink-3);
  box-shadow: 0 0 0 1px var(--line-hot), 0 0 46px rgba(128, 0, 255, 0.28);
}

.hero-fig::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, transparent 55%, rgba(13, 13, 13, 0.7) 100%),
    repeating-linear-gradient(180deg, rgba(255, 0, 255, 0.06) 0 1px, transparent 1px 4px);
}

.hero-fig img {
  display: block;
  width: 100%;
  height: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  filter: saturate(1.12) contrast(1.06);
}

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

.hero-copy h1 {
  position: relative;
  margin: 0 0 0.7rem;
  font-family: Cormorant, Georgia, serif;
  font-weight: 600;
  font-size: clamp(2rem, 5.2vw, 3.5rem);
  line-height: 1.12;
  letter-spacing: 0.02em;
  color: #fff;
  text-shadow: 0 0 18px rgba(255, 0, 255, 0.42), 0 0 46px rgba(128, 0, 255, 0.38);
}

.hero-copy h1::before,
.hero-copy h1::after {
  content: attr(data-t);
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  pointer-events: none;
}

.hero-copy h1::before {
  color: var(--magenta);
  clip-path: polygon(0 0, 100% 0, 100% 46%, 0 46%);
  opacity: 0.8;
  animation: gl-a 7s steps(1) infinite;
}

.hero-copy h1::after {
  color: #9b6bff;
  clip-path: polygon(0 54%, 100% 54%, 100% 100%, 0 100%);
  opacity: 0.66;
  animation: gl-b 5.5s steps(1) infinite;
}

@keyframes gl-a {
  0%, 90%, 100% { transform: translate(0, 0); }
  91% { transform: translate(-3px, 1px); }
  94% { transform: translate(2px, -1px); }
  97% { transform: translate(-1px, 0); }
}

@keyframes gl-b {
  0%, 88%, 100% { transform: translate(0, 0); }
  90% { transform: translate(3px, -1px); }
  93% { transform: translate(-2px, 1px); }
  96% { transform: translate(1px, 0); }
}

.lede {
  max-width: 36ch;
  margin: 0 auto;
  color: var(--dim);
  font-size: 1rem;
  line-height: 1.68;
}

/* ---------- 主体布局 ---------- */

.layout {
  display: grid;
  grid-template-columns: minmax(0, 218px) minmax(0, 1fr);
  gap: clamp(1.4rem, 3.5vw, 3rem);
  align-items: start;
  padding: clamp(1.5rem, 3vw, 2.4rem) 0 3rem;
}

.rail {
  position: sticky;
  top: 58px;
  padding: 0.95rem 0.85rem 1rem;
  border-radius: 4px;
  background: var(--ink-2);
  box-shadow: inset 0 0 0 1px var(--line);
}

.rail h2 {
  margin: 0 0 0.45rem;
  font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  font-size: 0.74rem;
  font-weight: 500;
  letter-spacing: 0.3em;
  color: var(--magenta);
}

.rail hr {
  border: 0;
  height: 1px;
  margin: 0 0 0.65rem;
  background: linear-gradient(90deg, var(--magenta), rgba(128, 0, 255, 0.12) 70%, transparent);
}

.rail ol {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.1rem;
}

.rail ol a {
  display: flex;
  align-items: center;
  min-height: 40px;
  padding: 0 0.45rem;
  border-radius: 4px;
  color: var(--text);
  text-decoration: none;
  font-size: 0.84rem;
  transition: background 0.16s, color 0.16s;
}

.rail ol a:hover,
.rail ol a:focus-visible {
  background: rgba(255, 0, 255, 0.16);
  color: #fff;
}

.totop {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 40px;
  margin-top: 0.7rem;
  border: 1px solid var(--line);
  border-radius: 4px;
  color: var(--dim);
  text-decoration: none;
  font-size: 0.78rem;
  letter-spacing: 0.1em;
}

.totop:hover { color: #fff; border-color: var(--line-hot); }

/* ---------- 正文 ---------- */

.body-col { min-width: 0; }

.body-col div {
  scroll-margin-top: 96px;
  padding-bottom: 2rem;
  border-bottom: 1px dashed rgba(128, 0, 255, 0.28);
  margin-bottom: 2rem;
}

.body-col div:last-child { border-bottom: 0; margin-bottom: 0; }

.body-col h2 {
  margin: 0 0 0.5rem;
  font-family: Cormorant, Georgia, serif;
  font-weight: 600;
  font-size: clamp(1.5rem, 3vw, 2.05rem);
  line-height: 1.28;
  letter-spacing: 0.01em;
  color: #fff;
  text-shadow: 0 0 16px rgba(128, 0, 255, 0.5);
}

.body-col h3 {
  margin: 1.4rem 0 0.4rem;
  font-family: Cormorant, Georgia, serif;
  font-weight: 600;
  font-size: 1.28rem;
  color: #fff;
}

.body-col hr {
  border: 0;
  height: 1px;
  margin: 0 0 1rem;
  background: linear-gradient(90deg, rgba(255, 0, 255, 0.72), rgba(128, 0, 255, 0.14) 60%, transparent);
}

.body-col p { margin: 0 0 1rem; }

.body-col ul,
.body-col ol { margin: 0 0 1rem; padding-left: 1.25rem; }

.body-col li { margin: 0.35rem 0; }

.body-col strong { color: #fff; }

.body-col a {
  color: var(--neon);
  text-decoration: none;
  border-bottom: 1px solid rgba(255, 0, 255, 0.45);
}

.body-col a:hover { color: #fff; border-bottom-color: #fff; }

.body-col blockquote {
  margin: 0 0 1.2rem;
  padding: 0.65rem 1rem;
  border-radius: 0 4px 4px 0;
  border-left: 2px solid var(--magenta);
  background: var(--ink-3);
  color: var(--text);
}

.body-col table {
  width: 100%;
  margin: 0 0 1.2rem;
  border-collapse: collapse;
  font-size: 0.92rem;
  display: block;
  overflow-x: auto;
}

.body-col th,
.body-col td {
  padding: 0.55rem 0.7rem;
  text-align: left;
  border-bottom: 1px solid rgba(128, 0, 255, 0.22);
}

.body-col th { color: #fff; background: var(--ink-3); }

.body-col img { border-radius: 4px; }

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

.hud-foot {
  border-top: 1px solid var(--line-hot);
  background: linear-gradient(180deg, #120c1c, #0d0d0d);
  padding: 2.2rem clamp(1rem, 4vw, 2.4rem) 1.1rem;
}

.foot-grid {
  max-width: 1180px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 2rem;
}

.foot-brand {
  font-style: normal;
  display: grid;
  gap: 0.5rem;
  align-content: start;
}

.fb-name {
  font-family: Cormorant, Georgia, serif;
  font-size: 1.5rem;
  letter-spacing: 0.12em;
  color: #fff;
  text-shadow: 0 0 14px rgba(255, 0, 255, 0.6);
}

.fb-line { color: var(--dim); font-size: 0.9rem; line-height: 1.7; }

.foot-links {
  list-style: none;
  margin: 0 0 1.1rem;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 0.6rem;
}

.foot-links a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  color: var(--dim);
  text-decoration: none;
  font-size: 0.84rem;
}

.foot-links a:hover { color: #fff; text-shadow: 0 0 10px var(--magenta); }

.foot-form label {
  display: block;
  margin-bottom: 0.35rem;
  font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  font-size: 0.72rem;
  letter-spacing: 0.24em;
  color: var(--magenta);
}

.fc-row { display: flex; gap: 0.4rem; }

.foot-form input {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 44px;
  padding: 0 0.7rem;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--ink-3);
  color: #fff;
  font: inherit;
  font-size: 0.9rem;
}

.foot-form input:focus { outline: none; border-color: var(--magenta); box-shadow: 0 0 0 2px rgba(255, 0, 255, 0.25); }

.foot-form button {
  min-height: 44px;
  padding: 0 1.1rem;
  border: 0;
  border-radius: 4px;
  background: var(--violet);
  color: #fff;
  font: inherit;
  font-size: 0.86rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 0 16px rgba(128, 0, 255, 0.5);
}

.foot-form button:hover { background: var(--magenta); color: #0d0d0d; }

.foot-base {
  max-width: 1180px;
  margin: 1.6rem auto 0;
  padding-top: 1rem;
  border-top: 1px solid rgba(128, 0, 255, 0.2);
  text-align: center;
}

.foot-base p { margin: 0; color: var(--dim); font-size: 0.8rem; letter-spacing: 0.1em; }

/* ---------- 动效 ---------- */

@media (prefers-reduced-motion: no-preference) {
  .rail ol li,
  .foot-links li {
    animation: rise 0.5s cubic-bezier(0.22, 0.7, 0.3, 1) both;
  }

  .rail ol li:nth-child(2), .foot-links li:nth-child(2) { animation-delay: 0.04s; }
  .rail ol li:nth-child(3), .foot-links li:nth-child(3) { animation-delay: 0.08s; }
  .rail ol li:nth-child(4), .foot-links li:nth-child(4) { animation-delay: 0.12s; }
  .rail ol li:nth-child(5), .foot-links li:nth-child(5) { animation-delay: 0.16s; }
  .rail ol li:nth-child(6), .foot-links li:nth-child(6) { animation-delay: 0.2s; }
  .rail ol li:nth-child(7), .foot-links li:nth-child(7) { animation-delay: 0.24s; }

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

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-copy h1::before,
  .hero-copy h1::after { animation: none; }
  .hud-strip { backdrop-filter: none; }
}

/* ---------- 窄屏 ---------- */

@media (max-width: 860px) {
  .hud-top {
    grid-template-columns: auto 1fr;
    grid-template-areas:
      "dr brand"
      "tail tail";
    row-gap: 0.35rem;
    padding-bottom: 0.6rem;
  }

  .nav-drawer { grid-area: dr; }
  .brand { grid-area: brand; justify-self: end; font-size: 1.15rem; }
  .top-tail { grid-area: tail; justify-self: start; flex-wrap: wrap; }

  .hero-grid { grid-template-columns: minmax(0, 1fr); min-height: 0; }
  .hero-fig { order: -1; }
  .hero-copy { text-align: left; }
  .lede { margin: 0; }

  .layout { grid-template-columns: minmax(0, 1fr); gap: 1.4rem; }

  .rail {
    position: static;
    padding: 0.8rem 0.75rem;
  }

  .rail ol { grid-template-columns: 1fr 1fr; gap: 0.1rem; }
  .rail .totop { width: auto; padding: 0 0.9rem; }

  .foot-grid { grid-template-columns: minmax(0, 1fr); gap: 1.4rem; }
  .body-col div { scroll-margin-top: 110px; }
}

@media (max-width: 480px) {
  .nav-pack a { padding: 0 0.45rem; font-size: 0.8rem; }
  .cta { margin-left: 0.2rem; padding: 0 0.75rem; }
  .rail ol { grid-template-columns: minmax(0, 1fr); }
  .foot-links { grid-template-columns: minmax(0, 1fr); }
  .body-col table { font-size: 0.86rem; }
}

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