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

:root {
  --magenta: #ff0080;
  --fuchsia: #ff00ff;
  --ink: #26171f;
  --bg: #0b060d;
  --text: #f4e9f3;
  --muted: #c3aec1;
  --line: rgba(255, 255, 255, .13);
  --glass: rgba(22, 9, 22, .8);
  --radius: 10px;
  --wrap: 1180px;
  --serif: 'Cormorant', 'Songti SC', 'Noto Serif SC', Georgia, serif;
  --ui: 'Montserrat', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', system-ui, sans-serif;
}

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

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

body {
  margin: 0;
  padding-bottom: 116px;
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--ui);
  font-size: 1rem;
  line-height: 1.75;
  overflow-x: hidden;
}

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

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* —— 极光网格底 —— */
body::before {
  content: "";
  position: fixed;
  inset: -25%;
  z-index: -2;
  pointer-events: none;
  background-image:
    radial-gradient(42% 46% at 16% 20%, rgba(255, 0, 128, .62), transparent 70%),
    radial-gradient(46% 40% at 84% 12%, rgba(255, 0, 255, .48), transparent 72%),
    radial-gradient(52% 52% at 64% 84%, rgba(126, 32, 255, .44), transparent 74%),
    radial-gradient(40% 42% at 10% 90%, rgba(255, 0, 128, .38), transparent 72%);
  background-repeat: no-repeat;
  filter: blur(34px) saturate(140%);
  animation: drift 26s ease-in-out infinite alternate;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(11, 6, 13, .3), rgba(11, 6, 13, .84) 52%, rgba(11, 6, 13, .96));
}

@keyframes drift {
  0% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(2%, -2%, 0) scale(1.07); }
  100% { transform: translate3d(-2%, 2%, 0) scale(1.03); }
}

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

@keyframes pop {
  from { opacity: 0; transform: translateY(-6px) scale(.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

/* —— 页头 —— */
.site-head {
  position: relative;
  z-index: 60;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 16px clamp(14px, 4vw, 40px) 10px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  text-decoration: none;
}

.brand-mark { width: 30px; height: 30px; border-radius: 8px; object-fit: cover; }

.brand-name {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-family: var(--serif);
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: .06em;
  background: linear-gradient(96deg, #ffffff, var(--fuchsia) 46%, var(--magenta));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.head-tools { display: flex; flex: 1 1 210px; gap: 8px; justify-content: flex-end; }

.finder { display: flex; flex: 1 1 120px; min-width: 0; }

.finder input {
  width: 100%;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, .05);
  color: var(--text);
  font: inherit;
  font-size: 1rem;
}

.finder input::placeholder { color: var(--muted); }

.finder input:focus-visible,
.menu-btn:focus-visible,
.navbar a:focus-visible {
  outline: 2px solid var(--magenta);
  outline-offset: 2px;
}

.menu-btn {
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: linear-gradient(120deg, rgba(255, 0, 128, .24), rgba(255, 0, 255, .16));
  color: var(--text);
  font: inherit;
  font-size: 1rem;
  cursor: pointer;
  transition: border-color .2s, background .2s;
}

.menu-btn:hover { border-color: rgba(255, 0, 128, .6); }

/* —— 分组下拉 —— */
.menu-panel {
  position: fixed;
  top: 78px;
  right: clamp(14px, 4vw, 40px);
  z-index: 70;
  display: none;
  width: min(330px, calc(100% - 28px));
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--glass);
  backdrop-filter: blur(16px);
  box-shadow: 0 20px 44px rgba(0, 0, 0, .5);
}

.menu-panel.is-open { display: grid; gap: 12px; animation: pop .22s ease both; }

.menu-group + .menu-group { border-top: 1px solid var(--line); padding-top: 12px; }

.menu-cap {
  margin: 0 0 8px;
  font-size: 1rem;
  letter-spacing: .2em;
  color: var(--muted);
}

.menu-links { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; }

.menu-links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-size: 1rem;
  text-decoration: none;
  color: var(--text);
  transition: transform .2s, border-color .2s, background .2s;
}

.menu-links a:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 0, 128, .65);
  background: rgba(255, 0, 128, .14);
}

/* —— 底部固定条 —— */
.navbar {
  position: fixed;
  left: 50%;
  bottom: 14px;
  z-index: 80;
  width: min(1060px, calc(100% - 20px));
  padding: 6px;
  transform: translateX(-50%);
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(18, 8, 18, .82);
  backdrop-filter: blur(18px);
  box-shadow: 0 14px 36px rgba(0, 0, 0, .55);
}

.navbar p {
  display: flex;
  gap: 2px;
  margin: 0;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

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

.navbar a {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 1rem;
  white-space: nowrap;
  text-decoration: none;
  color: var(--muted);
  transition: color .2s, background .2s;
}

.navbar a:hover { color: #fff; background: rgba(255, 0, 128, .18); }

.navbar a[aria-current] {
  color: #fff;
  background: linear-gradient(120deg, rgba(255, 0, 128, .48), rgba(255, 0, 255, .34));
}

.navbar a.is-dim { opacity: .3; }

/* —— 主体骨架 —— */
.page-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: clamp(20px, 3vw, 46px);
  align-items: start;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: clamp(8px, 2vw, 18px) clamp(14px, 4vw, 40px) 30px;
}

/* —— 首屏 —— */
.hero {
  grid-column: 1 / -1;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 18px;
  min-height: 45vh;
  padding: clamp(20px, 4vw, 42px);
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  scroll-margin-top: 88px;
  background: linear-gradient(140deg, rgba(255, 0, 128, .17), rgba(38, 23, 31, .52) 46%, rgba(255, 0, 255, .15));
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background-image: radial-gradient(rgba(255, 255, 255, .18) 1px, transparent 1px);
  background-size: 20px 20px;
  opacity: .45;
  -webkit-mask-image: linear-gradient(180deg, #000, transparent 74%);
  mask-image: linear-gradient(180deg, #000, transparent 74%);
}

.hero-copy { position: relative; z-index: 1; }

.hero-eyebrow {
  margin: 0 0 8px;
  font-size: 1rem;
  letter-spacing: .24em;
  color: var(--muted);
}

.hero h1 {
  margin: 0 0 12px;
  font-family: var(--serif);
  font-size: clamp(2rem, 6vw, 3.5rem);
  font-weight: 600;
  line-height: 1.14;
  letter-spacing: .01em;
  background: linear-gradient(100deg, #ffffff, #ffd8ee 42%, var(--magenta));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-lead {
  position: relative;
  z-index: 1;
  margin: 0;
  max-width: 56ch;
  font-size: 1rem;
  line-height: 1.8;
  color: var(--muted);
}

.hero-art { position: relative; z-index: 1; margin: 0; }
.hero-art img { display: block; width: 100%; border: 1px solid var(--line); border-radius: var(--radius); }

/* —— 正文区块 —— */
.page-grid > article:not(.hero) {
  grid-column: 1;
  padding: clamp(18px, 3vw, 30px) 0;
  border-top: 1px solid var(--line);
  scroll-margin-top: 88px;
  animation: rise .55s ease both;
}

.page-grid > article:not(.hero):nth-of-type(2) { animation-delay: .04s; }
.page-grid > article:not(.hero):nth-of-type(3) { animation-delay: .08s; }
.page-grid > article:not(.hero):nth-of-type(4) { animation-delay: .12s; }
.page-grid > article:not(.hero):nth-of-type(5) { animation-delay: .16s; }
.page-grid > article:not(.hero):nth-of-type(6) { animation-delay: .2s; }
.page-grid > article:not(.hero):nth-of-type(7) { animation-delay: .24s; }
.page-grid > article:not(.hero):nth-of-type(8) { animation-delay: .28s; }

.page-grid h2 {
  margin: 0 0 .5em;
  font-family: var(--serif);
  font-size: clamp(1.55rem, 3.4vw, 2.15rem);
  font-weight: 600;
  line-height: 1.24;
  letter-spacing: .01em;
  color: #fff;
}

.page-grid h3 {
  margin: 1.4em 0 .4em;
  font-size: 1.1rem;
  font-weight: 600;
  color: #ffd6ea;
}

.page-grid p { margin: 0 0 1em; line-height: 1.85; }

.page-grid ul, .page-grid ol { margin: 0 0 1.2em; padding-left: 1.3em; }

.page-grid li { line-height: 1.85; }

.subtitle {
  margin: -.3em 0 1em;
  color: var(--muted);
  font-style: italic;
}

.page-grid a {
  color: #ffc2e0;
  text-underline-offset: 3px;
  text-decoration-color: rgba(255, 0, 128, .6);
}

.page-grid a:hover { color: #fff; }

.page-grid img {
  margin: .4em 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.page-grid blockquote {
  margin: 0 0 1.2em;
  padding: 12px 18px;
  border-left: 3px solid var(--magenta);
  border-radius: 0 var(--radius) var(--radius) 0;
  background: rgba(255, 0, 128, .09);
}

/* —— 右侧栏 —— */
.rail {
  grid-column: 2;
  grid-row: 2 / span 40;
  align-self: start;
  position: sticky;
  top: 16px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, .045);
  backdrop-filter: blur(6px);
}

.rail-title {
  margin: 0 0 6px;
  font-family: var(--serif);
  font-size: 1.3rem;
  font-weight: 600;
  color: #fff;
}

.rail .subtitle { margin: 0 0 14px; font-size: 1rem; }

.rail-list { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }

.rail-list a {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-size: 1rem;
  text-decoration: none;
  color: var(--muted);
  transition: transform .2s, color .2s, border-color .2s, background .2s;
}

.rail-list a:hover {
  transform: translateX(3px);
  border-color: rgba(255, 0, 128, .6);
  background: rgba(255, 0, 128, .12);
  color: #fff;
}

/* —— 页脚 —— */
.site-foot {
  position: relative;
  z-index: 10;
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr 1.5fr;
  gap: 24px;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 34px clamp(14px, 4vw, 40px) 26px;
  border-top: 1px solid var(--line);
}

.foot-title {
  margin: 0 0 10px;
  font-family: var(--serif);
  font-size: 1.15rem;
  font-weight: 600;
  color: #fff;
}

.foot-list { display: grid; gap: 2px; margin: 0; padding: 0; list-style: none; }

.foot-list a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding-right: 8px;
  font-size: 1rem;
  text-decoration: none;
  color: var(--muted);
  transition: color .2s;
}

.foot-list a:hover { color: #fff; }

.subscribe { display: flex; flex-wrap: wrap; gap: 8px; }

.subscribe input {
  flex: 1 1 130px;
  min-width: 0;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, .05);
  color: var(--text);
  font: inherit;
  font-size: 1rem;
}

.subscribe input::placeholder { color: var(--muted); }

.subscribe button {
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid rgba(255, 0, 128, .5);
  border-radius: var(--radius);
  background: linear-gradient(120deg, var(--magenta), var(--fuchsia));
  color: #fff;
  font: inherit;
  font-size: 1rem;
  cursor: pointer;
  transition: filter .2s;
}

.subscribe button:hover { filter: hue-rotate(-18deg) brightness(1.08); }

.foot-bar {
  grid-column: 1 / -1;
  margin-top: 4px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  text-align: center;
  font-size: 1rem;
  color: var(--muted);
}

/* —— 断点 —— */
@media (max-width: 900px) {
  .page-grid { grid-template-columns: minmax(0, 1fr); }
  .rail { grid-column: 1; grid-row: auto; position: static; }
  .site-foot { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 560px) {
  .site-foot { grid-template-columns: 1fr; }
  .hero { min-height: 0; padding: 20px 18px; }
  .hero h1 { font-size: clamp(1.85rem, 9vw, 2.5rem); }
  .head-tools { flex: 1 1 100%; }
  body { padding-bottom: 108px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
}

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