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

:root {
  --ink: #1c1726;
  --ink-deep: #160f22;
  --violet: #6514ff;
  --fuchsia: #bf00ff;
  --paper: #efe8ff;
  --mute: #b9aed2;
  --line: rgba(191, 0, 255, 0.34);
  --rail-w: 224px;
}

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

html {
  background: var(--ink);
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100%;
  color: var(--paper);
  font-family: "Libre Baskerville", "Songti SC", "Noto Serif SC", Georgia, serif;
  font-size: 17px;
  line-height: 1.72;
  position: relative;
}

body::before {
  content: "";
  position: fixed;
  inset: -22%;
  z-index: -1;
  pointer-events: none;
  background-image:
    repeating-linear-gradient(135deg, rgba(101, 20, 255, 0.20) 0 2px, rgba(101, 20, 255, 0) 2px 24px),
    radial-gradient(circle at 84% 6%, rgba(191, 0, 255, 0.30), rgba(191, 0, 255, 0) 48%),
    radial-gradient(circle at 8% 92%, rgba(101, 20, 255, 0.26), rgba(101, 20, 255, 0) 46%);
  animation: drift 30s linear infinite;
}

@keyframes drift {
  to { transform: translate3d(24px, 24px, 0); }
}

::selection {
  background: var(--fuchsia);
  color: #160f22;
}

a { color: #e6c8ff; }

:focus-visible {
  outline: 2px solid var(--fuchsia);
  outline-offset: 3px;
}

/* ---------- 左侧竖排导航 ---------- */

.top {
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  width: var(--rail-w);
  z-index: 30;
  display: flex;
  flex-direction: column;
  gap: 22px;
  padding: 26px 20px 24px;
  background: linear-gradient(190deg, #241b33 0%, var(--ink) 62%, var(--ink-deep) 100%);
  border-right: 1px solid var(--line);
}

.mark {
  width: 54px;
  height: 54px;
  flex: none;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: var(--violet);
  color: #fff;
  text-decoration: none;
  font-size: 26px;
  font-weight: 700;
  line-height: 1;
  box-shadow: 0 0 0 3px rgba(191, 0, 255, 0.32);
  transition: background 0.24s ease, box-shadow 0.24s ease;
}

.mark:hover { background: var(--fuchsia); box-shadow: 0 0 0 6px rgba(191, 0, 255, 0.22); }

.mark-img { width: 100%; height: 100%; object-fit: cover; border-radius: 9px; display: block; }

.top nav {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  scrollbar-width: thin;
}

.top nav p {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.top nav a {
  display: flex;
  align-items: center;
  gap: 11px;
  min-height: 44px;
  padding: 10px 8px;
  color: var(--mute);
  text-decoration: none;
  font-size: 16px;
  line-height: 1.4;
  border-radius: 8px;
  transition: color 0.23s ease, background 0.23s ease, transform 0.23s ease;
}

.top nav a::before {
  content: "";
  width: 9px;
  height: 9px;
  flex: none;
  background: var(--fuchsia);
  transform: rotate(45deg);
  transition: background 0.23s ease, transform 0.23s ease;
}

.top nav a:hover {
  color: #fff;
  background: rgba(101, 20, 255, 0.30);
  transform: translateX(4px);
}

.top nav a:hover::before { background: #fff; transform: rotate(45deg) scale(1.25); }

.cta {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 12px;
  border-radius: 10px;
  background: var(--fuchsia);
  color: #160f22;
  font-weight: 700;
  font-size: 16px;
  letter-spacing: 0.08em;
  text-decoration: none;
  transition: background 0.23s ease, color 0.23s ease;
}

.cta:hover { background: #fff; color: var(--violet); }

/* ---------- 主区 ---------- */

main {
  margin-left: var(--rail-w);
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr);
  grid-template-areas:
    "rail hero"
    "rail body";
  column-gap: clamp(26px, 4vw, 58px);
  padding: 34px clamp(20px, 4vw, 62px) 76px 34px;
  align-items: start;
}

.hero {
  grid-area: hero;
  min-height: 70vh;
  display: flex;
  flex-direction: column;
  gap: 26px;
  padding-bottom: 8px;
}

.hero-copy {
  text-align: right;
  margin-left: auto;
  max-width: 34ch;
}

.kicker {
  margin: 0 0 12px;
  font-size: 16px;
  letter-spacing: 0.36em;
  color: var(--fuchsia);
  text-transform: uppercase;
}

h1 {
  margin: 0 0 16px;
  font-family: "Cormorant Garamond", "Songti SC", "Noto Serif SC", Georgia, serif;
  font-weight: 600;
  font-size: clamp(38px, 5.2vw, 74px);
  line-height: 1.06;
  letter-spacing: 0.01em;
}

.hero-copy .subtitle {
  margin: 0;
  color: var(--mute);
  font-size: 17px;
  line-height: 1.72;
}

.hero-media {
  position: relative;
  flex: 1 1 auto;
  min-height: 170px;
  max-height: 44vh;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 10px;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: saturate(1.16) contrast(1.05);
}

/* ---------- 左侧目录 ---------- */

.rail {
  grid-area: rail;
  position: sticky;
  top: 34px;
  padding-left: 16px;
  border-left: 6px solid var(--fuchsia);
}

.rail h2 {
  margin: 0;
  font-family: "Cormorant Garamond", "Songti SC", Georgia, serif;
  font-size: 23px;
  line-height: 1.25;
  letter-spacing: 0.05em;
}

.rail .subtitle {
  margin: 4px 0 10px;
  color: var(--fuchsia);
  font-size: 16px;
  line-height: 1.5;
}

.rail ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
}

.rail a {
  display: block;
  min-height: 40px;
  padding: 8px 0;
  color: var(--mute);
  text-decoration: none;
  font-size: 16px;
  line-height: 1.5;
  border-bottom: 1px dashed rgba(191, 0, 255, 0.20);
  transition: color 0.23s ease, padding-left 0.23s ease;
}

.rail a:hover { color: #fff; padding-left: 6px; }

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

.body {
  grid-area: body;
  max-width: 74ch;
}

.body > article {
  margin-top: 42px;
  padding-top: 32px;
  border-top: 1px solid var(--line);
  scroll-margin-top: 24px;
}

.body > article:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

.body h2 {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin: 0 0 14px;
  font-family: "Cormorant Garamond", "Songti SC", "Noto Serif SC", Georgia, serif;
  font-weight: 600;
  font-size: clamp(26px, 3vw, 38px);
  line-height: 1.2;
}

.body h2::before {
  content: "";
  width: 13px;
  height: 13px;
  flex: none;
  background: var(--fuchsia);
  transform: translateY(-3px) rotate(45deg);
}

.body h3 {
  margin: 26px 0 10px;
  font-size: 22px;
  line-height: 1.35;
  color: #fff;
  font-weight: 600;
}

.body p, .body li {
  color: #ded4f2;
  font-size: 17px;
}

.body p { margin: 0 0 16px; line-height: 1.82; }

.body ul, .body ol { margin: 0 0 18px; padding-left: 22px; }

.body li { margin-bottom: 8px; line-height: 1.75; }

.body blockquote {
  margin: 22px 0;
  padding: 14px 18px;
  border-left: 6px solid var(--violet);
  background: rgba(101, 20, 255, 0.14);
  border-radius: 0 10px 10px 0;
}

.body blockquote p:last-child { margin-bottom: 0; }

.body img { max-width: 100%; height: auto; border-radius: 10px; display: block; }

.body hr { border: 0; border-top: 1px solid var(--line); margin: 28px 0; }

.js .body > article {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.42s ease, transform 0.42s ease;
}

.js .body > article.in { opacity: 1; transform: none; }

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

footer {
  margin-left: var(--rail-w);
  padding: 42px clamp(20px, 4vw, 62px) 26px;
  background: var(--ink-deep);
  border-top: 2px solid var(--violet);
}

.foot-mark {
  margin: 0 0 26px;
  font-family: "Cormorant Garamond", "Songti SC", "Noto Serif SC", Georgia, serif;
  font-weight: 700;
  font-size: clamp(34px, 8vw, 108px);
  line-height: 0.98;
  letter-spacing: 0.01em;
  word-break: break-word;
  background: linear-gradient(100deg, var(--violet), var(--fuchsia) 72%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.foot-cols {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr);
  gap: 22px 44px;
  margin-bottom: 26px;
}

address {
  font-style: normal;
  color: var(--mute);
  font-size: 16px;
  line-height: 1.9;
  word-break: break-all;
}

.foot-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 20px;
}

.foot-links a {
  display: flex;
  align-items: center;
  min-height: 40px;
  padding: 6px 0;
  color: var(--paper);
  text-decoration: none;
  font-size: 16px;
  border-bottom: 1px solid rgba(191, 0, 255, 0.20);
  transition: color 0.23s ease, border-color 0.23s ease;
}

.foot-links a:hover { color: var(--fuchsia); border-color: var(--fuchsia); }

.foot-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 10px 20px;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--mute);
  font-size: 16px;
}

.foot-bar p { margin: 0; }

.foot-bar a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 4px 10px;
  color: var(--paper);
  text-decoration: none;
  border-radius: 8px;
  transition: background 0.23s ease, color 0.23s ease;
}

.foot-bar a:hover { background: var(--violet); color: #fff; }

/* ---------- 移动端 ---------- */

@media (max-width: 900px) {
  .top {
    position: sticky;
    left: auto;
    top: 0;
    bottom: auto;
    width: 100%;
    flex-direction: row;
    align-items: center;
    gap: 12px;
    padding: 9px 14px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    background: var(--ink);
  }

  .mark { width: 44px; height: 44px; font-size: 22px; }

  .top nav { overflow-x: auto; overflow-y: hidden; }

  .top nav p { flex-direction: row; gap: 4px; }

  .top nav a {
    white-space: nowrap;
    padding: 10px 12px;
    min-height: 44px;
    font-size: 16px;
  }

  .cta { min-height: 44px; padding: 0 14px; }

  main {
    margin-left: 0;
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "hero"
      "rail"
      "body";
    row-gap: 30px;
    padding: 20px 16px 54px;
  }

  .hero { min-height: 0; }

  .hero-copy { max-width: none; }

  .hero-media { max-height: 38vh; min-height: 150px; }

  h1 { font-size: clamp(31px, 8.6vw, 46px); }

  .rail { position: static; }

  .body > article { scroll-margin-top: 122px; }

  footer { margin-left: 0; padding: 34px 16px 22px; }

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

@media (max-width: 460px) {
  .foot-links { grid-template-columns: minmax(0, 1fr); }
  .foot-bar a { padding: 4px 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation: none !important; transition: none !important; }
  .js .body > article { opacity: 1; transform: none; }
}

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