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

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

:root {
  --red: #ff0000;
  --purple: #8b00ff;
  --glow: #cba6ff;
  --deep: #180d0d;
  --ink: #261717;
  --txt: #f8eeee;
  --dim: rgba(248, 238, 238, .68);
  --line: rgba(255, 255, 255, .18);
  --glass: rgba(255, 255, 255, .07);
  --sans: "Source Sans 3", system-ui, -apple-system, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --disp: "Bebas Neue", "Source Sans 3", system-ui, "PingFang SC", "Microsoft YaHei", sans-serif;
}

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

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.72;
  color: var(--txt);
  background:
    radial-gradient(1100px 620px at 12% -8%, rgba(255, 0, 0, .34), transparent 62%),
    radial-gradient(900px 700px at 92% 4%, rgba(139, 0, 255, .36), transparent 60%),
    radial-gradient(700px 620px at 50% 112%, rgba(255, 0, 0, .16), transparent 66%),
    var(--deep);
  background-attachment: fixed;
  min-height: 100vh;
  overflow-x: hidden;
}

/* ---------- 顶栏 ---------- */
.top {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(24, 13, 13, .62);
  backdrop-filter: blur(18px) saturate(1.3);
  -webkit-backdrop-filter: blur(18px) saturate(1.3);
  border-bottom: 1px solid var(--line);
}

.top-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 10px 18px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 10px;
}

.menu { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.menu-r { justify-content: flex-end; }

.top-right { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: flex-end; }

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 8px 15px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--glass);
  color: var(--txt);
  text-decoration: none;
  font-size: 16px;
  line-height: 1.2;
  white-space: nowrap;
  transition: background .2s, border-color .2s, transform .2s, color .2s;
}
.pill:hover, .pill:focus-visible {
  background: rgba(255, 0, 0, .3);
  border-color: rgba(255, 0, 0, .72);
  transform: translateY(-1px);
}

.brand {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 6px 14px;
  font-family: var(--disp);
  font-size: clamp(1.4rem, 2.4vw, 2rem);
  letter-spacing: .1em;
  line-height: 1;
  color: #fff;
  text-decoration: none;
  border-bottom: 2px solid var(--red);
  white-space: nowrap;
}

.search { display: flex; gap: 6px; align-items: center; justify-content: flex-end; }
.search input {
  width: 118px;
  min-height: 40px;
  padding: 8px 13px;
  font: inherit;
  font-size: 16px;
  color: var(--txt);
  background: rgba(255, 255, 255, .07);
  border: 1px solid var(--line);
  border-radius: 999px;
  outline-offset: 2px;
}
.search input::placeholder { color: var(--dim); }
.search input:focus { border-color: rgba(139, 0, 255, .8); }
.search button {
  min-height: 40px;
  padding: 8px 15px;
  font: inherit;
  font-size: 16px;
  cursor: pointer;
  color: #fff;
  background: rgba(139, 0, 255, .42);
  border: 1px solid rgba(139, 0, 255, .78);
  border-radius: 999px;
  transition: background .2s, border-color .2s;
}
.search button:hover { background: rgba(255, 0, 0, .52); border-color: rgba(255, 0, 0, .8); }

/* ---------- 头屏 ---------- */
.hero {
  position: relative;
  overflow: hidden;
  min-height: 45vh;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  padding: clamp(26px, 5vw, 56px) 18px 0;
  background-image: radial-gradient(rgba(255, 255, 255, .13) 1px, transparent 1px);
  background-size: 22px 22px;
  border-bottom: 1px solid var(--line);
}

.hero-copy {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding-bottom: clamp(18px, 3vw, 32px);
  text-align: left;
}

.hero h1 {
  margin: 0;
  font-family: var(--disp);
  font-weight: 400;
  font-size: clamp(2.1rem, 7vw, 4.6rem);
  line-height: 1.04;
  letter-spacing: .03em;
  color: #fff;
  text-shadow: 0 10px 44px rgba(255, 0, 0, .38);
  text-wrap: balance;
}
.hero h1::after {
  content: "";
  display: block;
  width: 76px;
  height: 4px;
  margin: 18px 0 16px;
  background: linear-gradient(90deg, var(--red), var(--purple));
}

.lede {
  margin: 0;
  max-width: 62ch;
  color: var(--dim);
  font-size: 17px;
  line-height: 1.7;
}

.hero-art {
  position: relative;
  margin: auto 0 0;
  width: 100%;
  height: clamp(140px, 26vh, 260px);
  overflow: hidden;
  border-top: 1px solid var(--line);
  background: linear-gradient(120deg, rgba(255, 0, 0, .42), rgba(139, 0, 255, .46));
  -webkit-mask-image: linear-gradient(180deg, rgba(0, 0, 0, .5), #000);
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, .5), #000);
}
.hero-art img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.hero-art:has(img:nth-child(2)) img { opacity: 0; animation: heroRot 15s infinite; }
.hero-art:has(img:nth-child(2)) img:nth-child(1) { animation-delay: 0s; }
.hero-art:has(img:nth-child(2)) img:nth-child(2) { animation-delay: 5s; }
.hero-art:has(img:nth-child(2)) img:nth-child(3) { animation-delay: 10s; }

@keyframes heroRot {
  0% { opacity: 0; }
  4% { opacity: 1; }
  30% { opacity: 1; }
  34% { opacity: 0; }
  100% { opacity: 0; }
}

/* ---------- 主体 ---------- */
.stage {
  max-width: 1280px;
  margin: 0 auto;
  padding: clamp(26px, 4vw, 52px) 18px clamp(40px, 6vw, 80px);
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  gap: clamp(18px, 3vw, 36px);
  align-items: start;
}

.rail {
  position: sticky;
  top: 92px;
  padding: 16px 14px 18px;
  background: var(--glass);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--line);
  border-bottom: 2px solid var(--purple);
}

.rail-t {
  margin: 0 0 10px;
  font-family: var(--disp);
  font-weight: 400;
  font-size: 1.15rem;
  letter-spacing: .16em;
  color: #fff;
}
.rail-t .hs { display: inline-block; }

.bar {
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-left: 8px;
  background: var(--red);
  vertical-align: middle;
}

.rail-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.rail-list a {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 40px;
  padding: 6px 8px;
  font-size: 16px;
  line-height: 1.3;
  color: var(--txt);
  text-decoration: none;
  border-left: 2px solid transparent;
  transition: background .18s, border-color .18s;
}
.rail-list a:hover { background: rgba(255, 0, 0, .16); border-left-color: var(--red); }
.rail-list .num {
  font-family: var(--disp);
  font-size: 14px;
  letter-spacing: .1em;
  color: var(--glow);
}

.stage-main {
  min-width: 0;
  padding: clamp(18px, 3vw, 40px);
  background: rgba(255, 255, 255, .05);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--line);
  border-bottom: 3px solid var(--red);
  overflow-wrap: break-word;
}

.stage-main article[id] {
  scroll-margin-top: 104px;
  padding-top: clamp(22px, 3vw, 36px);
  margin-top: clamp(22px, 3vw, 36px);
  border-top: 1px solid rgba(255, 255, 255, .13);
}
.stage-main article[id]:first-of-type { padding-top: 0; margin-top: 0; border-top: 0; }

.stage-main h2,
.stage-main h3 {
  font-family: var(--disp);
  font-weight: 400;
  line-height: 1.16;
  letter-spacing: .04em;
  color: #fff;
  margin: 0 0 14px;
}
.stage-main h2 {
  font-size: clamp(1.6rem, 3.4vw, 2.3rem);
  padding-bottom: 12px;
  border-bottom: 2px solid rgba(255, 0, 0, .7);
}
.stage-main h3 { font-size: 1.32rem; color: var(--glow); }
.stage-main h2 span, .stage-main h3 span { display: inline-block; }

.stage-main p { margin: 0 0 1em; line-height: 1.8; }
.stage-main a { color: #ff8080; text-decoration: underline; text-underline-offset: 3px; }
.stage-main a:hover { color: #fff; }
.stage-main ul, .stage-main ol { padding-left: 1.35em; margin: 0 0 1em; }
.stage-main li { margin-bottom: .45em; }
.stage-main img { max-width: 100%; height: auto; display: block; margin: 1em 0; }
.stage-main figure { margin: 1em 0; }
.stage-main blockquote {
  margin: 1.2em 0;
  padding: 12px 16px;
  border-left: 3px solid var(--purple);
  background: rgba(139, 0, 255, .12);
  color: var(--dim);
}
.stage-main blockquote p:last-child { margin-bottom: 0; }
.stage-main table { width: 100%; border-collapse: collapse; font-size: 16px; margin: 1em 0; }
.stage-main th, .stage-main td { border-bottom: 1px solid var(--line); padding: 9px 10px; text-align: left; vertical-align: top; }
.stage-main th { color: #fff; background: rgba(255, 255, 255, .07); }
.stage-main code {
  font-size: .95em;
  padding: 2px 6px;
  background: rgba(255, 255, 255, .1);
  border: 1px solid var(--line);
}

/* ---------- 页脚 ---------- */
.foot {
  border-top: 1px solid var(--line);
  padding: clamp(30px, 5vw, 64px) 18px 0;
  background: linear-gradient(180deg, rgba(255, 0, 0, .1), rgba(139, 0, 255, .12) 42%, rgba(255, 255, 255, .03));
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.cta {
  max-width: 1180px;
  margin: 0 auto clamp(28px, 4vw, 44px);
  padding: clamp(26px, 5vw, 56px);
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(120deg, rgba(255, 0, 0, .24), rgba(139, 0, 255, .24)), rgba(255, 255, 255, .05);
  border: 1px solid var(--line);
  border-bottom: 3px solid var(--red);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}
.cta-t {
  margin: 0;
  font-family: var(--disp);
  font-weight: 400;
  font-size: clamp(1.8rem, 5vw, 3.2rem);
  letter-spacing: .06em;
  line-height: 1.1;
  color: #fff;
}
.cta-t .hs { display: inline-block; }

.cta-btn {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 12px 26px;
  font-family: var(--disp);
  font-size: 1.05rem;
  letter-spacing: .14em;
  color: #fff;
  text-decoration: none;
  background: rgba(255, 0, 0, .55);
  border: 1px solid rgba(255, 255, 255, .42);
  transition: background .2s, transform .2s;
}
.cta-btn:hover { background: rgba(139, 0, 255, .62); transform: translateY(-2px); }

.foot-main {
  max-width: 1180px;
  margin: 0 auto clamp(24px, 4vw, 40px);
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 1.2fr);
  gap: 28px;
}
.foot-nav { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.foot-nav dl { margin: 0; }
.foot-nav dt {
  font-family: var(--disp);
  font-size: 14px;
  letter-spacing: .16em;
  color: rgba(255, 255, 255, .58);
  padding-bottom: 8px;
  margin-bottom: 8px;
  border-bottom: 1px solid rgba(255, 0, 0, .5);
}
.foot-nav dd { margin: 0 0 4px; }
.foot-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 2px 0;
  font-size: 16px;
  color: var(--txt);
  text-decoration: none;
}
.foot-nav a:hover { color: #ff8080; }

.foot-brand { border-left: 1px solid var(--line); padding-left: 24px; }
.foot-brand strong {
  display: block;
  font-family: var(--disp);
  font-weight: 400;
  font-size: 1.5rem;
  letter-spacing: .12em;
  color: #fff;
}
.foot-brand .mark { display: block; width: 42px; height: 3px; margin-top: 12px; background: var(--red); }

.foot-base {
  max-width: 1180px;
  margin: 0 auto;
  padding: 16px 0 26px;
  border-top: 1px solid rgba(255, 255, 255, .12);
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: space-between;
  align-items: center;
  font-size: 15px;
  color: var(--dim);
}
.foot-base p { margin: 0; }
.foot-base a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  color: var(--txt);
  text-decoration: none;
}
.foot-base a:hover { color: #ff8080; }

/* ---------- 响应式 ---------- */
@media (max-width: 1000px) {
  .top-inner { display: flex; flex-wrap: wrap; justify-content: center; padding: 10px 12px; }
  .brand { order: -1; flex: 0 0 100%; justify-content: center; border-bottom: 0; }
  .top-left, .top-right { display: contents; }
  .menu { justify-content: center; width: 100%; }
  .search { justify-content: center; width: 100%; }
  .search input { flex: 1 1 auto; width: auto; }
}

@media (max-width: 900px) {
  .stage { grid-template-columns: minmax(0, 1fr); }
  .rail { position: static; order: 2; }
  .foot-main { grid-template-columns: minmax(0, 1fr); }
  .foot-nav { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .foot-brand { border-left: 0; border-top: 1px solid var(--line); padding: 18px 0 0; }
}

@media (max-width: 520px) {
  body { font-size: 17px; }
  .pill { padding: 8px 12px; }
  .hero { padding-left: 14px; padding-right: 14px; }
  .stage, .foot { padding-left: 14px; padding-right: 14px; }
  .cta { padding: 22px 18px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-art img { animation: none !important; opacity: 1 !important; }
  .pill, .cta-btn { transition: none; }
}

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