@import url('https://fonts.googleapis.com/css2?family=Press+Start+2P&family=VT323&display=swap');

:root {
  --red: #ff0000;
  --pink: #ff1493;
  --ink: #261717;
  --bg: #140b0b;
  --panel: rgba(38, 23, 23, 0.62);
  --line: rgba(255, 20, 147, 0.34);
  --txt: #f8e9ea;
  --dim: #c9a7ac;
  --pix: 'Press Start 2P', system-ui, -apple-system, 'PingFang SC', 'Microsoft YaHei', sans-serif;
  --term: 'VT323', system-ui, -apple-system, 'PingFang SC', 'Microsoft YaHei', sans-serif;
}

* { box-sizing: border-box; }

html {
  font-size: 17px;
  scroll-behavior: smooth;
  overflow-x: clip;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--txt);
  font-family: var(--term);
  font-size: 1.06rem;
  line-height: 1.85;
  overflow-x: clip;
}

.aura {
  position: fixed;
  inset: -25% -12%;
  z-index: 0;
  pointer-events: none;
  opacity: 0.62;
  filter: saturate(1.25) blur(26px);
  background:
    radial-gradient(36% 42% at 22% 18%, rgba(255, 0, 0, 0.55), transparent 62%),
    radial-gradient(32% 38% at 78% 24%, rgba(255, 20, 147, 0.5), transparent 64%),
    radial-gradient(44% 44% at 60% 88%, rgba(255, 60, 120, 0.3), transparent 66%),
    conic-gradient(from 200deg at 50% 50%, rgba(255, 20, 147, 0.16), rgba(255, 0, 0, 0.12), rgba(38, 23, 23, 0.55), rgba(255, 20, 147, 0.16));
  background-size: 180% 180%;
  animation: mesh 11s ease-in-out infinite alternate;
}

@keyframes mesh {
  from { background-position: 0% 0%, 100% 10%, 50% 100%, 0% 0%; }
  to { background-position: 26% 30%, 64% 26%, 36% 68%, 100% 100%; }
}

/* 顶栏 */
.top {
  position: sticky;
  top: 0;
  z-index: 40;
}

.mast {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem clamp(0.7rem, 3vw, 1.6rem);
  background: rgba(20, 11, 11, 0.86);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.mast-brand {
  justify-self: center;
  max-width: 11em;
  padding: 0.45rem 0.35rem;
  text-align: center;
  font-family: var(--pix);
  font-size: 0.78rem;
  line-height: 1.7;
  text-decoration: none;
  color: transparent;
  background: linear-gradient(94deg, var(--red), var(--pink));
  -webkit-background-clip: text;
  background-clip: text;
}

.mast-nav { display: none; }
.mast-nav-l { justify-self: start; }
.mast-nav ol {
  display: flex;
  gap: 0.1rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.mast-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0.3rem 0.6rem;
  border-radius: 8px;
  color: var(--txt);
  text-decoration: none;
  font-size: 0.95rem;
  white-space: nowrap;
}
.mast-nav a:hover { color: #fff; background: rgba(255, 20, 147, 0.2); }

.mast-r {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.burger {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-height: 44px;
  padding: 0.35rem 0.85rem;
  border: 0;
  border-radius: 9px;
  cursor: pointer;
  font-family: var(--term);
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  color: #fff;
  background: linear-gradient(94deg, var(--red), var(--pink));
  transition: transform 0.18s ease, filter 0.18s ease;
}
.burger:hover { transform: translateY(-2px); filter: saturate(1.3); }
.burger-b {
  display: block;
  width: 14px;
  height: 2px;
  background: #fff;
  box-shadow: 0 4px 0 #fff, 0 -4px 0 #fff;
}

/* 粘性锚点条 */
.subbar {
  overflow-x: auto;
  background: rgba(38, 23, 23, 0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  scrollbar-width: thin;
}
.subbar ol {
  display: flex;
  gap: 0.1rem;
  width: max-content;
  margin: 0;
  padding: 0.15rem 0.5rem;
  list-style: none;
}
.subbar a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-height: 42px;
  padding: 0.25rem 0.7rem;
  border-radius: 8px;
  color: var(--dim);
  text-decoration: none;
  font-size: 0.9rem;
  white-space: nowrap;
}
.subbar b { font-family: var(--pix); font-size: 0.55rem; color: var(--pink); }
.subbar a:hover,
.subbar a.on { color: #fff; background: rgba(255, 20, 147, 0.22); }

/* 全屏菜单 */
.ovl {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  grid-template-rows: auto 1fr;
  padding: 1rem clamp(1rem, 5vw, 2.6rem);
  overflow-y: auto;
  background:
    radial-gradient(60% 55% at 82% 8%, rgba(255, 20, 147, 0.4), transparent 62%),
    radial-gradient(50% 50% at 12% 92%, rgba(255, 0, 0, 0.32), transparent 64%),
    rgba(20, 10, 10, 0.97);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
}
html.nav-open .ovl { opacity: 1; visibility: visible; transform: none; }
html.nav-open { overflow: hidden; }

.ovl-in {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 0.8rem;
  border-bottom: 1px solid var(--line);
}
.ovl-brand {
  margin: 0;
  font-family: var(--pix);
  font-size: 0.74rem;
  line-height: 1.7;
  color: transparent;
  background: linear-gradient(94deg, var(--red), var(--pink));
  -webkit-background-clip: text;
  background-clip: text;
}
.ovl-x {
  min-height: 44px;
  padding: 0.35rem 1rem;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: transparent;
  color: #fff;
  font-family: var(--term);
  font-size: 1rem;
  cursor: pointer;
}
.ovl-x:hover { background: rgba(255, 20, 147, 0.18); }

.ovl-nav ol {
  display: grid;
  gap: 0.25rem;
  margin: 1.2rem 0 2.5rem;
  padding: 0;
  list-style: none;
}
.ovl-nav a {
  display: flex;
  align-items: center;
  min-height: 52px;
  padding: 0.35rem 0.8rem;
  border-bottom: 1px solid rgba(255, 20, 147, 0.16);
  color: #fff;
  text-decoration: none;
  font-size: 1.15rem;
  transition: padding-left 0.2s ease, background 0.2s ease;
}
.ovl-nav a:hover { padding-left: 1.4rem; background: rgba(255, 20, 147, 0.16); }

/* 主体 */
main { position: relative; z-index: 1; }

.stage {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 1.1rem;
  min-height: 45vh;
  padding: clamp(2rem, 7vw, 4rem) clamp(1rem, 5vw, 3rem) clamp(1.6rem, 5vw, 2.8rem);
  border-bottom: 1px solid var(--line);
}
.stage-h1 {
  margin: 0;
  max-width: 24ch;
  font-family: var(--pix);
  font-size: clamp(1.3rem, 5vw, 2.7rem);
  line-height: 1.6;
  letter-spacing: 0.01em;
  text-shadow: 0 0 30px rgba(255, 20, 147, 0.42);
}
.stage-slash {
  display: block;
  width: min(300px, 55%);
  height: 12px;
  border-radius: 2px;
  transform: skewX(-28deg);
  background: linear-gradient(92deg, var(--red), var(--pink), transparent);
  animation: slash 9s ease-in-out infinite alternate;
}
@keyframes slash {
  from { width: min(200px, 40%); opacity: 0.6; }
  to { width: min(420px, 72%); opacity: 1; }
}

.board {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(1rem, 3vw, 2rem);
  max-width: 1160px;
  margin: 0 auto;
  padding: clamp(1.2rem, 4vw, 2.6rem) clamp(0.9rem, 4vw, 2.4rem) clamp(2rem, 5vw, 3rem);
}

/* 左侧栏 */
.rail {
  align-self: start;
  padding: 0.9rem 0.8rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--panel);
}
.rail-h {
  margin: 0 0 0.6rem;
  font-family: var(--term);
  font-size: 0.88rem;
  letter-spacing: 0.14em;
  color: var(--dim);
}
.rail-h > span {
  display: inline-block;
  padding-bottom: 0.12rem;
  border-bottom: 2px solid var(--pink);
}
.rail-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.1rem;
  margin: 0 0 0.9rem;
  padding: 0;
  list-style: none;
}
.rail-list a {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  min-height: 40px;
  padding: 0.2rem 0.3rem;
  border-radius: 7px;
  color: var(--txt);
  text-decoration: none;
  font-size: 0.9rem;
}
.rail-list b { font-family: var(--pix); font-size: 0.5rem; color: var(--pink); }
.rail-list a:hover { background: rgba(255, 20, 147, 0.16); color: #fff; }

.rail-h-top { margin: 0; }
.rail-h-top > span { border-bottom: 0; }
.rail-h-top a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 0.7rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: #fff;
  text-decoration: none;
  font-size: 0.9rem;
  letter-spacing: 0.06em;
}
.rail-h-top a:hover { background: rgba(255, 20, 147, 0.2); }

/* 正文 */
.stream {
  min-width: 0;
  display: grid;
  gap: clamp(1rem, 2.4vw, 1.6rem);
}
.stream > section {
  position: relative;
  overflow: hidden;
  padding: clamp(1.1rem, 3vw, 2rem);
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--panel);
  scroll-margin-top: 132px;
}
.stream > section::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 4px;
  background: linear-gradient(92deg, var(--red), var(--pink), transparent);
}
.stream > section:nth-child(even) { background: rgba(38, 23, 23, 0.44); }

.stream p { margin: 0 0 1em; line-height: 1.95; color: #efe0e1; }
.stream p:last-child { margin-bottom: 0; }
.stream h2,
.stream h3 {
  margin: 0 0 0.8em;
  font-family: var(--pix);
  font-size: clamp(0.98rem, 2.5vw, 1.25rem);
  line-height: 1.7;
}
.stream h2 > span,
.stream h3 > span {
  display: inline-block;
  position: relative;
  padding-bottom: 0.3em;
  color: transparent;
  background: linear-gradient(94deg, var(--red), var(--pink));
  -webkit-background-clip: text;
  background-clip: text;
}
.stream h2 > span::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 4px;
  transform: skewX(-26deg);
  background: linear-gradient(94deg, var(--red), var(--pink));
}
.stream ul,
.stream ol { margin: 0 0 1em; padding-left: 1.25em; line-height: 1.9; }
.stream li { margin: 0.4em 0; }
.stream a { color: #ff9dc4; text-decoration: underline; text-underline-offset: 3px; }
.stream a:hover { color: #fff; }
.stream strong { color: #fff; }
.stream figure {
  margin: 1rem 0;
  padding: 0.6rem;
  border: 1px solid var(--line);
  border-radius: 10px;
}
.stream figcaption { color: var(--dim); font-size: 0.9rem; }
.stream blockquote {
  margin: 1rem 0;
  padding: 0.5rem 0 0.5rem 1rem;
  border-left: 3px solid var(--pink);
  color: var(--dim);
}

/* 页脚 */
.foot {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 0.8rem;
  margin-top: 1.5rem;
  padding: clamp(1.6rem, 5vw, 2.6rem) clamp(1rem, 5vw, 2.4rem) 2.2rem;
  border-top: 1px solid var(--line);
  background: rgba(20, 10, 10, 0.74);
  text-align: center;
}
.foot-brand {
  margin: 0;
  font-family: var(--pix);
  font-size: clamp(1rem, 3.2vw, 1.7rem);
  line-height: 1.6;
  color: transparent;
  background: linear-gradient(94deg, var(--red), var(--pink));
  -webkit-background-clip: text;
  background-clip: text;
}
.foot-mid { margin: 0; color: var(--dim); font-size: 0.95rem; }
.foot-small { color: var(--dim); font-size: 0.88rem; }

@media (min-width: 880px) {
  .board { grid-template-columns: 250px minmax(0, 1fr); }
  .rail { position: sticky; top: 118px; }
  .rail-list { grid-template-columns: 1fr; }
}

@media (min-width: 960px) {
  .mast-nav { display: block; }
}

@media (min-width: 760px) {
  .foot {
    grid-template-columns: 1.4fr 1fr 1fr;
    align-items: center;
    text-align: left;
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * {
    animation: none !important;
    transition: none !important;
  }
}

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