/* 椿 · CAMELLYA 同人站 — 全站样式
   深色 / 暗红 / 冷白；标题衬线，正文系统无衬线 */
@import "archive.css";

@font-face {
  font-family: "Solaris Universal";
  src: url("../fonts/WuWa_SolarisUniversal_Regular.woff2") format("woff2");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

:root {
  --bg: #0d0b0e;
  --panel: rgba(22, 17, 21, 0.72);
  --panel-solid: #171216;
  --line: rgba(214, 60, 82, 0.22);
  --crimson: #c2273d;
  --crimson-deep: #8a1e2d;
  --petal: #e8b4bc;
  --ink: #f2ede8;
  --ink-dim: #b7adb3;
  --ink-faint: #7d737a;
  --cold: #a9b4bd;
  --serif: "Noto Serif SC", "Source Han Serif SC", "STZhongsong", "SimSun", serif;
  --sans: "PingFang SC", "Microsoft YaHei", "Segoe UI", system-ui, sans-serif;
  --font-display: var(--serif); /* 字体方案切换点，见 body[data-font] */
  --font-text: var(--sans);
  --shadow: 0 18px 48px rgba(0, 0, 0, 0.45);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-text);
  background: var(--bg);
  color: var(--ink);
  min-height: 100dvh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ---------- 字体方案（临时对比，拍板后收敛） ---------- */
body[data-font="kai"] {
  --font-display: "LXGW WenKai Screen", "LXGW WenKai", "STKaiti", "KaiTi", serif;
  --font-text: "LXGW WenKai Screen", "LXGW WenKai", "STKaiti", "KaiTi", serif;
}
body[data-font="serif"] {
  --font-display: "Noto Serif SC", "STZhongsong", "SimSun", serif;
  --font-text: var(--sans);
}
body[data-font="serif-full"] {
  --font-display: "Noto Serif SC", "STZhongsong", "SimSun", serif;
  --font-text: "Noto Serif SC", "STZhongsong", "SimSun", serif;
}

.font-demo {
  position: fixed;
  left: 14px;
  bottom: 14px;
  z-index: 50;
  display: flex;
  gap: 6px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(23, 18, 22, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.font-demo span {
  font-size: 11px;
  color: var(--ink-faint);
  letter-spacing: 1px;
  align-self: center;
  padding-left: 6px;
}
.font-demo button {
  background: none;
  border: 1px solid transparent;
  border-radius: 999px;
  color: var(--ink-dim);
  font-size: 12px;
  padding: 5px 10px;
  cursor: pointer;
  font-family: var(--sans);
}
.font-demo button:hover { color: var(--ink); }
.font-demo button.on {
  color: var(--petal);
  border-color: var(--line);
  background: rgba(194, 39, 61, 0.18);
}

/* ---------- 背景层 ---------- */
.bg-video {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
  transition: opacity 0.9s cubic-bezier(0.25, 1, 0.5, 1);
  transform: translateZ(0);
  -webkit-transform: translateZ(0);
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  will-change: opacity;
  contain: strict;
}
.bg-shade {
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(105deg, rgba(13, 9, 12, 0.61) 0%, rgba(13, 9, 12, 0.4) 42%, rgba(13, 9, 12, 0.14) 100%),
    linear-gradient(to top, rgba(13, 9, 12, 0.64) 0%, rgba(13, 9, 12, 0.03) 48%);
}
/* 内页只降低亮度，不改变视频原本的色相。 */
body:has(.page-main) .bg-shade {
  background:
    linear-gradient(105deg, rgba(13, 9, 12, 0.82) 0%, rgba(13, 9, 12, 0.62) 42%, rgba(13, 9, 12, 0.3) 100%),
    linear-gradient(to top, rgba(13, 9, 12, 0.88) 0%, rgba(13, 9, 12, 0.1) 45%);
}
/* 聊天页专属更清透遮罩：减少右侧暗度，让椿的脸部和花海清晰显露 */
body:has(.chat-layout) .bg-shade {
  background:
    linear-gradient(105deg, rgba(13, 9, 12, 0.52) 0%, rgba(13, 9, 12, 0.22) 46%, rgba(13, 9, 12, 0.08) 100%),
    linear-gradient(to top, rgba(13, 9, 12, 0.55) 0%, rgba(13, 9, 12, 0.04) 45%);
}
/* 信物与记忆页专属清透遮罩：水波与伸手特写更通透自然 */
body:has(.archive-page) .bg-shade {
  background:
    linear-gradient(105deg, rgba(13, 9, 12, 0.52) 0%, rgba(13, 9, 12, 0.22) 50%, rgba(13, 9, 12, 0.1) 100%),
    linear-gradient(to top, rgba(13, 9, 12, 0.55) 0%, rgba(13, 9, 12, 0.05) 45%);
}

.bg-petals {
  position: fixed;
  inset: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

/* ---------- 顶栏 ---------- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px clamp(18px, 4vw, 48px);
  background: rgba(13, 11, 14, 0.55);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
}
.brand-mark {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 18px;
  color: var(--crimson);
  background: radial-gradient(circle at 50% 35%, rgba(194, 39, 61, 0.28), transparent 70%);
  text-decoration: none;
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}
.brand-mark:hover,
.brand-mark.is-current-theme {
  color: #ff536d;
  border-color: rgba(255, 83, 109, 0.72);
  background: radial-gradient(circle at 50% 35%, rgba(194, 39, 61, 0.5), rgba(194, 39, 61, 0.08) 72%);
  box-shadow: 0 0 16px rgba(194, 39, 61, 0.24);
}
.brand-text {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-display);
  font-size: 19px;
  letter-spacing: 2px;
}
.test-badge {
  display: inline-flex;
  align-items: center;
  margin-left: 8px;
  padding: 2px 8px;
  border: 1px solid rgba(232, 180, 188, 0.42);
  border-radius: 999px;
  background: rgba(194, 39, 61, 0.22);
  color: var(--petal);
  font-family: var(--sans);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 1px;
  line-height: 1.2;
  flex-shrink: 0;
}
.brand-home-link {
  color: var(--ink);
  text-decoration: none;
  transition: color 0.2s ease, text-shadow 0.2s ease;
}
.brand-home-link:hover,
.brand-home-link.is-current-theme {
  color: #fff8f8;
  text-shadow: 0 0 12px rgba(255, 238, 240, 0.24);
}
.brand-text .brand-sep { color: var(--ink-faint); margin: 0 6px; }
.brand-text .brand-latin { font-size: 13px; letter-spacing: 4px; color: var(--ink-dim); }

.site-nav { display: flex; gap: clamp(14px, 2.4vw, 30px); }
.header-right {
  display: flex;
  align-items: center;
  gap: clamp(14px, 2.4vw, 30px);
  position: relative;
}
.nav-link {
  color: var(--ink-dim);
  text-decoration: none;
  font-size: 15px;
  letter-spacing: 2px;
  padding: 6px 2px;
  position: relative;
  transition: color 0.28s ease;
}
.nav-link:hover { color: var(--ink); }
.nav-link.is-active {
  color: var(--ink);
  font-weight: 500;
}
.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--crimson), transparent);
  opacity: 0;
  transform: scaleX(0.2);
  transition: opacity 0.28s cubic-bezier(0.2, 0, 0, 1), transform 0.28s cubic-bezier(0.2, 0, 0, 1);
  pointer-events: none;
}
.nav-link.is-active::after {
  opacity: 1;
  transform: scaleX(1);
  view-transition-name: active-nav-indicator;
}
.nav-link.is-locked { color: var(--ink-faint); cursor: not-allowed; }
.nav-lock {
  font-size: 10px;
  vertical-align: super;
  color: var(--crimson);
  margin-left: 2px;
}

/* ---------- 导航栏音乐唱片 + 播放列表面板 ---------- */
.music-nav {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: radial-gradient(circle at 50% 35%, rgba(194, 39, 61, 0.28), transparent 70%);
  color: var(--petal);
  font-size: 15px;
  cursor: pointer;
  display: grid;
  place-items: center;
  flex: none;
  transition: border-color 0.25s, box-shadow 0.25s;
}
.music-nav:hover { border-color: rgba(232, 180, 188, 0.5); }
.music-nav.is-playing {
  box-shadow: 0 0 14px rgba(194, 39, 61, 0.5);
  animation: spin 5s linear infinite;
}
.music-panel {
  position: absolute;
  top: calc(100% + 14px);
  right: 0;
  width: min(300px, calc(100vw - 32px));
  background: rgba(23, 18, 22, 0.94);
  border: 1px solid var(--line);
  border-radius: 14px;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: var(--shadow);
  padding: 8px;
  display: grid;
  gap: 4px;
  z-index: 40;
}
.music-panel[hidden] { display: none; } /* 防止 display:grid 覆盖 hidden 语义 */
.music-panel-head {
  font-size: 11px;
  letter-spacing: 3px;
  color: var(--ink-faint);
  padding: 8px 12px 4px;
}
.music-panel-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  background: none;
  border: none;
  text-align: left;
  padding: 10px 12px;
  border-radius: 10px;
  color: var(--ink-dim);
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.music-panel-item:hover { background: rgba(194, 39, 61, 0.14); color: var(--ink); }
.music-panel-item.is-current {
  color: var(--petal);
  background: rgba(194, 39, 61, 0.12);
}
/* 播放器：曲目信息 + 进度条 + 控制键 */
.music-now {
  padding: 8px 12px 6px;
}
.music-now strong {
  display: block;
  font-family: var(--font-display);
  font-size: 16px;
  letter-spacing: 2px;
  color: var(--ink);
}
.music-now small {
  display: block;
  font-size: 11.5px;
  color: var(--ink-faint);
  margin-top: 2px;
}
.music-progress {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 12px;
}
.mp-time {
  font-size: 11px;
  color: var(--ink-faint);
  font-variant-numeric: tabular-nums;
  min-width: 32px;
  text-align: center;
}
.mp-bar {
  flex: 1;
  height: 6px;
  border-radius: 999px;
  background: rgba(232, 180, 188, 0.18);
  cursor: pointer;
  overflow: hidden;
}
.mp-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--crimson-deep), var(--petal));
  transition: width 0.2s linear;
}
.music-ctrl {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  padding: 4px 0 10px;
}
.mc-btn {
  background: none;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--ink-dim);
  width: 34px;
  height: 34px;
  font-size: 13px;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}
.mc-btn:hover {
  color: var(--petal);
  border-color: rgba(232, 180, 188, 0.5);
}
.mc-play {
  width: 42px;
  height: 42px;
  font-size: 16px;
  color: var(--petal);
  background: radial-gradient(circle at 50% 35%, rgba(194, 39, 61, 0.3), transparent 72%);
}
.music-panel-foot {
  font-size: 10.5px;
  letter-spacing: 2px;
  color: var(--ink-faint);
  text-align: center;
  padding: 6px 0 2px;
}
.mpi-mark {
  width: 18px;
  flex: none;
  text-align: center;
  font-size: 13px;
  color: var(--crimson);
}
.mpi-text strong {
  display: block;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 1px;
  color: inherit;
}
.mpi-text small {
  display: block;
  font-size: 11.5px;
  color: var(--ink-faint);
  margin-top: 2px;
}

/* ---------- 主页 ---------- */
.hero {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 120px clamp(20px, 6vw, 88px) 60px;
  max-width: 1080px;
}
.eyebrow {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 12px;
  font-size: 13px;
  letter-spacing: 6px;
  text-transform: uppercase;
  color: var(--petal);
  opacity: 0.85;
  animation: fadeUp 0.9s 0.05s both;
}
.fan-badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 10px;
  border: 1px solid rgba(232, 180, 188, 0.28);
  border-radius: 999px;
  background: rgba(46, 28, 35, 0.5);
  color: rgba(242, 237, 232, 0.78);
  font-family: var(--sans);
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 1px;
  line-height: 1;
  text-transform: none;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.hero-name {
  position: relative;
  width: fit-content;
  font-family: var(--font-display);
  font-size: clamp(88px, 16vw, 168px);
  font-weight: 600;
  line-height: 1.05;
  margin: 8px 0 2px;
  animation: fadeUp 0.9s 0.15s both;
}
.hero-name-glyph {
  display: block;
  color: var(--ink);
  background: linear-gradient(
    180deg,
    #fffaf5 0%,
    #f8ebe8 32%,
    #efb4bd 56%,
    #e75b72 77%,
    #bd203b 100%
  );
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 6px 40px rgba(194, 39, 61, 0.22);
}
.hero-name-flower {
  position: absolute;
  right: 0.062em;
  bottom: -0.058em;
  width: 0.276em;
  height: auto;
  pointer-events: none;
  filter: drop-shadow(0 0 7px rgba(218, 48, 72, 0.42));
}
.hero-name-translations {
  width: fit-content;
  text-align: center;
}
.hero-latin {
  font-size: clamp(15px, 2.4vw, 22px);
  letter-spacing: clamp(8px, 1.6vw, 18px);
  color: var(--ink-dim);
  animation: fadeUp 0.9s 0.25s both;
}
.hero-solaris {
  margin-top: 9px;
  width: fit-content;
  margin-left: clamp(30px, 2.4vw, 32px);
  text-align: left;
  font-family: "Solaris Universal", sans-serif;
  font-size: clamp(9px, 1.15vw, 12px);
  line-height: 1;
  letter-spacing: 0.42em;
  color: rgba(232, 180, 188, 0.58);
  text-shadow: 0 0 8px rgba(194, 39, 61, 0.24);
  animation: fadeUp 0.9s 0.29s both;
}
.hero-anniversary {
  appearance: none;
  position: fixed;
  top: 94px;
  right: clamp(22px, 4vw, 54px);
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 148px;
  min-height: 154px;
  padding: 15px 16px 13px;
  box-sizing: border-box;
  border: 1px solid rgba(232, 180, 188, 0.32);
  border-radius: 16px;
  background: linear-gradient(145deg, rgba(35, 20, 27, 0.66), rgba(13, 11, 14, 0.38));
  box-shadow: inset 0 0 0 1px rgba(255, 243, 239, 0.035), 0 12px 34px rgba(8, 5, 7, 0.14);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: rgba(232, 180, 188, 0.68);
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 2px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  cursor: pointer;
  transition: border-color 0.24s ease, background 0.24s ease, box-shadow 0.24s ease, transform 0.24s ease;
  animation: fadeUp 0.9s 0.31s both;
}
.hero-anniversary::after {
  content: "↗";
  position: absolute;
  top: 9px;
  right: 10px;
  color: rgba(255, 239, 237, 0.42);
  font-size: 10px;
  letter-spacing: 0;
}
.anniversary-flower {
  position: absolute;
  top: -27px;
  left: -32px;
  width: 76px;
  height: auto;
  pointer-events: none;
  transform: none;
  transform-origin: center;
  filter: drop-shadow(0 7px 10px rgba(4, 3, 5, 0.5)) drop-shadow(0 0 5px rgba(232, 220, 238, 0.2));
  transition: transform 0.3s ease, filter 0.3s ease;
}
.hero-anniversary:hover .anniversary-flower {
  transform: scale(1.04);
  filter: drop-shadow(0 9px 12px rgba(4, 3, 5, 0.56)) drop-shadow(0 0 7px rgba(232, 220, 238, 0.28));
}
.hero-anniversary:hover {
  transform: translateY(-2px);
  border-color: rgba(232, 180, 188, 0.55);
  background: linear-gradient(145deg, rgba(50, 26, 35, 0.72), rgba(18, 12, 16, 0.48));
  box-shadow: inset 0 0 0 1px rgba(255, 243, 239, 0.05), 0 16px 38px rgba(8, 5, 7, 0.2);
}
.hero-anniversary:focus-visible {
  outline: 2px solid rgba(242, 205, 207, 0.78);
  outline-offset: 4px;
}
.anniversary-label {
  display: block;
  width: 100%;
  white-space: nowrap;
  text-align: center;
}
.anniversary-centered {
  display: block;
  width: 100%;
  text-align: center;
}
.hero-anniversary .anniversary-label + .anniversary-centered {
  margin-top: 15px;
}
.hero-anniversary strong {
  margin: 6px 0 5px;
  color: rgba(255, 239, 237, 0.92);
  font-family: var(--font-display);
  font-size: 34px;
  font-weight: 600;
  letter-spacing: 1px;
}

/* ---------- 椿卡池纪事弹窗 ---------- */
body.banner-history-open { overflow: hidden; }
.banner-history-modal[hidden] { display: none; }
.banner-history-modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 24px;
}
.banner-history-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(7, 5, 7, 0.72);
  backdrop-filter: blur(7px);
  -webkit-backdrop-filter: blur(7px);
  animation: modalFade 0.24s both;
}
.banner-history-dialog {
  position: relative;
  width: min(560px, 100%);
  max-height: min(720px, calc(100dvh - 48px));
  overflow: auto;
  padding: 30px 32px 34px;
  border: 1px solid rgba(232, 180, 188, 0.3);
  border-radius: 24px;
  background:
    radial-gradient(circle at 86% 8%, rgba(194, 39, 61, 0.16), transparent 34%),
    rgba(20, 14, 18, 0.94);
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.46);
  animation: modalRise 0.3s both;
}
.banner-history-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}
.banner-history-kicker {
  color: rgba(232, 180, 188, 0.58);
  font-size: 10px;
  letter-spacing: 3px;
}
.banner-history-head h2 {
  margin-top: 7px;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(25px, 4vw, 34px);
  font-weight: 400;
  letter-spacing: 3px;
}
.banner-history-close {
  flex: 0 0 auto;
  width: 36px;
  height: 36px;
  border: 1px solid rgba(232, 180, 188, 0.24);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.035);
  color: rgba(242, 237, 232, 0.72);
  font: 300 25px/1 var(--sans);
  cursor: pointer;
}
.banner-history-close:hover { color: #fff; border-color: rgba(232, 180, 188, 0.5); }
.banner-history-intro {
  margin-top: 13px;
  color: var(--ink-dim);
  font-size: 13px;
  letter-spacing: 1px;
}
.banner-history-timeline {
  position: relative;
  margin-top: 28px;
  padding-left: 34px;
  list-style: none;
}
.banner-history-timeline::before {
  content: "";
  position: absolute;
  top: 9px;
  bottom: 9px;
  left: 8px;
  width: 1px;
  background: linear-gradient(to bottom, var(--petal), var(--crimson));
  opacity: 0.58;
}
.banner-history-event { position: relative; }
.banner-history-dot {
  position: absolute;
  top: 20px;
  left: -32px;
  width: 13px;
  height: 13px;
  border: 2px solid rgba(242, 205, 207, 0.82);
  border-radius: 50%;
  background: #8a1e2d;
  box-shadow: 0 0 13px rgba(194, 39, 61, 0.52);
}
.banner-history-event.is-current .banner-history-dot {
  background: rgba(20, 14, 18, 0.96);
  box-shadow: 0 0 0 4px rgba(194, 39, 61, 0.1), 0 0 15px rgba(194, 39, 61, 0.48);
}
.banner-history-card {
  padding: 18px 20px 19px;
  border: 1px solid rgba(232, 180, 188, 0.18);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.035);
}
.banner-history-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: rgba(232, 180, 188, 0.62);
  font-size: 10px;
  letter-spacing: 2px;
}
.banner-history-card h3 {
  margin: 9px 0 12px;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 400;
  letter-spacing: 2px;
}
.banner-history-card time,
.banner-history-range,
.banner-history-now {
  color: var(--ink-dim);
  font-size: 12px;
  letter-spacing: 1px;
}
.banner-history-now { color: var(--petal); }
.banner-history-range { margin: 0 7px; color: var(--crimson-bright); }
.banner-history-card.is-waiting {
  border-style: dashed;
  background: linear-gradient(135deg, rgba(194, 39, 61, 0.055), rgba(255, 255, 255, 0.025));
}
.banner-history-quote {
  margin-top: 14px;
  color: rgba(242, 205, 207, 0.78);
  font-family: var(--font-display);
  font-size: 13px;
  line-height: 1.85;
  letter-spacing: 0.8px;
}
.banner-history-gap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 12px 0;
  padding: 0 4px;
  color: var(--ink-faint);
  font-size: 10.5px;
  letter-spacing: 1px;
}
.banner-history-gap strong {
  color: var(--petal);
  font-weight: 400;
}
@keyframes modalFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes modalRise {
  from { opacity: 0; transform: translateY(14px) scale(0.975); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.vine-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 26px 0;
  animation: fadeUp 0.9s 0.32s both;
}
.vine-line {
  width: clamp(60px, 12vw, 150px);
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--crimson));
}
.vine-line:last-child { transform: scaleX(-1); }
.vine-dot {
  width: 8px;
  height: 8px;
  border-radius: 50% 50% 50% 0;
  background: var(--crimson);
  transform: rotate(45deg);
  box-shadow: 0 0 12px rgba(194, 39, 61, 0.8);
}
.hero-intro {
  max-width: 560px;
  font-size: 16.5px;
  line-height: 2;
  color: var(--ink-dim);
  animation: fadeUp 0.9s 0.4s both;
}
/* 与已有背景主题同步；SPA 返回主页时沿用 body 上的主题。 */
.hero-intro[data-home-copy="red"],
body[data-home-theme="red"] .hero-intro[data-home-copy="white"] {
  display: none;
}
body[data-home-theme="red"] .hero-intro[data-home-copy="red"] {
  display: block;
}
.hero-intro em {
  font-style: normal;
  color: var(--petal);
}
.hero-actions {
  display: flex;
  align-items: center;
  gap: 22px;
  margin-top: 34px;
  flex-wrap: wrap;
  animation: fadeUp 0.9s 0.5s both;
}
.btn-primary {
  display: inline-block;
  padding: 14px 40px;
  font-size: 16px;
  letter-spacing: 4px;
  text-decoration: none;
  color: var(--ink);
  border: 1px solid rgba(194, 39, 61, 0.65);
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(138, 30, 45, 0.85), rgba(194, 39, 61, 0.65));
  box-shadow: 0 8px 30px rgba(194, 39, 61, 0.3);
  transition: transform 0.25s, box-shadow 0.25s;
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(194, 39, 61, 0.5);
}
.hero-music-hint {
  background: none;
  border: none;
  border-bottom: 1px dashed rgba(232, 180, 188, 0.4);
  font-family: var(--font-text);
  font-size: 13.5px;
  letter-spacing: 1px;
  color: var(--ink-dim);
  cursor: pointer;
  padding: 6px 10px;
  border-radius: 999px;
  transition: color 0.25s, border-color 0.25s;
}
.hero-music-hint:hover {
  color: var(--petal);
  border-bottom-color: var(--petal);
}

.hero-notes {
  margin-top: 30px;
  list-style: none;
  display: grid;
  gap: 6px;
  animation: fadeUp 0.9s 0.6s both;
}
.hero-notes li {
  font-size: 13px;
  color: var(--ink-faint);
  letter-spacing: 1px;
}
.hero-notes li::before {
  content: "❀";
  color: var(--crimson);
  margin-right: 8px;
  font-size: 11px;
}

/* ---------- 入口卡片 ---------- */
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  padding: 0 clamp(20px, 6vw, 88px) 80px;
  max-width: 1080px;
}
.card {
  display: block;
  text-decoration: none;
  color: var(--ink);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 22px 24px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
  animation: fadeUp 0.9s 0.7s both;
}
.card:nth-child(2) { animation-delay: 0.78s; }
.card:nth-child(3) { animation-delay: 0.86s; }
.card:hover {
  transform: translateY(-4px);
  border-color: rgba(232, 180, 188, 0.5);
  box-shadow: var(--shadow);
}
.card-title {
  font-family: var(--font-display);
  font-size: 19px;
  letter-spacing: 3px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.card-tag {
  font-size: 11px;
  letter-spacing: 2px;
  color: var(--crimson);
  border: 1px solid var(--line);
  padding: 2px 8px;
  border-radius: 999px;
}
.card-desc {
  margin-top: 10px;
  font-size: 13.5px;
  line-height: 1.8;
  color: var(--ink-dim);
}

/* ---------- 内页通用 ---------- */
.page-main {
  min-height: 100dvh;
  padding: 110px clamp(18px, 5vw, 72px) 60px;
  max-width: 1200px;
  margin: 0 auto;
}
.page-title {
  font-family: var(--font-display);
  font-size: clamp(30px, 5vw, 44px);
  letter-spacing: 6px;
  animation: fadeUp 0.8s both;
}
.page-sub {
  margin-top: 10px;
  color: var(--ink-dim);
  font-size: 15px;
  letter-spacing: 1px;
  animation: fadeUp 0.8s 0.1s both;
}

/* ---------- 聊天页 ---------- */
.chat-layout {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 22px;
  align-items: stretch;
  height: calc(100dvh - 186px); /* header 60 + main 上下 padding：页面零滚动，导航永不遮内容 */
  min-height: 460px;
}
.chat-aside { overflow-y: auto; scrollbar-width: thin; scrollbar-color: rgba(194, 39, 61, 0.4) transparent; }
.page-main:has(.chat-layout) { padding-bottom: 16px; }
body:has(.chat-layout) .site-footer { display: none; } /* 聊天页隐藏页脚，声明见关于页 */
.chat-aside {
  background: rgba(18, 12, 17, 0.38);
  border: 1px solid rgba(214, 60, 82, 0.25);
  border-radius: 16px;
  padding: 30px 26px;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.35);
  display: flex;
  flex-direction: column;
  gap: 16px;
  animation: fadeUp 0.8s 0.1s both;
}
.avatar-img {
  width: 84px;
  height: 84px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: transparent;
  object-fit: cover;
  flex: none;
}
.avatar-img.avatar-sm { width: 36px; height: 36px; }
.aside-name {
  font-family: var(--font-display);
  font-size: 26px;
  letter-spacing: 4px;
}
.aside-role {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  letter-spacing: 2px;
  color: var(--petal);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 12px;
  width: fit-content;
}
.aside-bio {
  font-size: 13.5px;
  line-height: 1.9;
  color: var(--ink-dim);
}
.aside-back {
  margin-top: auto;
  font-size: 13.5px;
  color: var(--ink-dim);
  text-decoration: none;
  letter-spacing: 2px;
  transition: color 0.25s;
}
.aside-back:hover { color: var(--petal); }

.chat-panel {
  display: flex;
  flex-direction: column;
  background: rgba(16, 11, 15, 0.2);
  border: 1px solid rgba(214, 60, 82, 0.25);
  border-radius: 16px;
  backdrop-filter: blur(1.5px);
  -webkit-backdrop-filter: blur(1.5px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35), inset 0 0 0 1px rgba(255, 255, 255, 0.04);
  overflow: hidden;
  animation: fadeUp 0.8s 0.18s both;
}
.chat-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 20px;
  border-bottom: 1px solid rgba(214, 60, 82, 0.2);
  background: rgba(18, 12, 17, 0.32);
}
.chat-peer { display: flex; align-items: center; gap: 12px; }
.peer-name { font-family: var(--font-display); font-size: 18px; letter-spacing: 3px; display: block; }
.peer-role { font-size: 11.5px; color: var(--petal); letter-spacing: 2px; }
.chat-head-tools { display: flex; align-items: center; gap: 10px; }
.btn-ghost {
  background: none;
  border: 1px solid var(--line);
  color: var(--ink-dim);
  font-size: 13px;
  letter-spacing: 2px;
  padding: 8px 16px;
  border-radius: 999px;
  cursor: pointer;
  transition: color 0.25s, border-color 0.25s;
}
.btn-ghost:hover:not(:disabled) { color: var(--petal); border-color: rgba(232, 180, 188, 0.5); }
.btn-ghost:disabled { opacity: 0.45; cursor: not-allowed; }

.chat-body {
  flex: 1;
  overflow-y: auto;
  padding: 22px 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  scrollbar-width: thin;
  scrollbar-color: rgba(194, 39, 61, 0.4) transparent;
}
.chat-divider {
  text-align: center;
  font-size: 12px;
  letter-spacing: 2px;
  color: var(--ink-faint);
  margin: 4px 0;
}
.msg {
  display: flex;
  align-items: flex-end;
  gap: 10px;
  max-width: 78%;
  animation: popIn 0.5s both;
}
.msg .bubble {
  padding: 12px 16px;
  border-radius: 14px;
  font-size: 14.5px;
  line-height: 1.9;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
.msg-camellya { align-self: flex-start; animation-delay: 0.15s; }
.msg-camellya .bubble {
  background: linear-gradient(135deg, rgba(138, 30, 45, 0.5), rgba(194, 39, 61, 0.32));
  border: 1px solid rgba(232, 180, 188, 0.22);
  border-bottom-left-radius: 4px;
}
.msg-user { align-self: flex-end; animation-delay: 0.3s; }
.msg-user .bubble {
  background: rgba(93, 106, 116, 0.38);
  border: 1px solid rgba(169, 180, 189, 0.2);
  border-bottom-right-radius: 4px;
}
.msg:nth-child(4) { animation-delay: 0.45s; }
.msg:nth-child(5) { animation-delay: 0.6s; }
.msg:nth-child(6) { animation-delay: 0.75s; }
.msg:nth-child(7) { animation-delay: 0.9s; }

/* ---- 点击椿的气泡播放语音 ---- */
.msg-camellya .bubble {
  position: relative;
  cursor: pointer;
  transition: border-color 0.25s;
}
.msg-camellya .bubble:hover {
  border-color: rgba(232, 180, 188, 0.6);
}
.msg-camellya .bubble:focus-visible {
  outline: 1px solid rgba(232, 180, 188, 0.7);
  outline-offset: 2px;
}
.bubble.is-voice-loading { cursor: progress; }
.voice-tag {
  position: absolute;
  top: -9px;
  right: -9px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1px solid rgba(232, 180, 188, 0.35);
  background: var(--panel-solid);
  color: var(--petal);
  display: grid;
  place-items: center;
  opacity: 0.55;
  transition: opacity 0.2s;
  pointer-events: none;
}
.msg-camellya .bubble:hover .voice-tag { opacity: 1; }
.voice-eq { display: none; align-items: flex-end; gap: 1.5px; height: 10px; }
.bubble.is-voice-loading .voice-icon,
.bubble.is-voice-playing .voice-icon { display: none; }
.bubble.is-voice-loading .voice-tag::after {
  content: "";
  width: 9px;
  height: 9px;
  border: 1.5px solid var(--petal);
  border-top-color: transparent;
  border-radius: 50%;
  animation: voice-spin 0.8s linear infinite;
}
.bubble.is-voice-playing .voice-eq { display: inline-flex; }
.voice-eq i {
  width: 2px;
  background: var(--petal);
  border-radius: 1px;
  transform-origin: bottom;
  animation: voice-eq 0.9s ease-in-out infinite;
}
.voice-eq i:nth-child(1) { height: 5px; }
.voice-eq i:nth-child(2) { height: 9px; animation-delay: 0.25s; }
.voice-eq i:nth-child(3) { height: 6px; animation-delay: 0.5s; }
@keyframes voice-spin { to { transform: rotate(360deg); } }
@keyframes voice-eq {
  0%, 100% { transform: scaleY(0.45); }
  50% { transform: scaleY(1.15); }
}
.voice-note {
  position: absolute;
  bottom: calc(100% + 7px);
  left: 0;
  font-size: 12px;
  letter-spacing: 1px;
  color: var(--ink-faint);
  background: var(--panel-solid);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 3px 11px;
  white-space: nowrap;
  animation: fadeUp 0.3s both;
  pointer-events: none;
}
.voice-note.is-out { opacity: 0; transition: opacity 0.6s; }

.chat-input {
  border-top: 1px solid rgba(214, 60, 82, 0.2);
  padding: 14px 18px 12px;
  background: rgba(18, 12, 17, 0.32);
}
.input-row {
  display: flex;
  gap: 12px;
  align-items: flex-end;
}
.input-row textarea {
  flex: 1;
  resize: none;
  background: rgba(13, 10, 14, 0.42);
  border: 1px solid var(--line);
  border-radius: 12px;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 14.5px;
  line-height: 1.7;
  padding: 12px 14px;
  min-height: 52px;
}
.input-row textarea::placeholder { color: var(--ink-faint); }
.btn-send {
  display: flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, rgba(138, 30, 45, 0.9), rgba(194, 39, 61, 0.7));
  color: var(--ink);
  border: 1px solid rgba(232, 180, 188, 0.3);
  border-radius: 12px;
  padding: 12px 20px;
  font-size: 14px;
  letter-spacing: 2px;
  cursor: pointer;
}
.btn-send:disabled { opacity: 0.4; cursor: not-allowed; }
.btn-send.is-stop {
  background: rgba(93, 106, 116, 0.5);
  border-color: rgba(169, 180, 189, 0.3);
}
.bubble.bubble-error {
  color: #e8a0a8;
  background: rgba(138, 30, 45, 0.25);
  border-color: rgba(232, 160, 168, 0.4);
}
.input-notice {
  margin-top: 8px;
  text-align: center;
  font-size: 12px;
  letter-spacing: 2px;
  color: var(--ink-faint);
}

/* ---------- 画廊占位 ---------- */
.teaser {
  min-height: 58dvh;
  display: grid;
  place-items: center;
  text-align: center;
  animation: fadeUp 0.9s 0.15s both;
}
.teaser-inner {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: clamp(40px, 8vw, 80px) clamp(30px, 8vw, 90px);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.teaser-flower {
  font-size: 40px;
  color: var(--crimson);
  text-shadow: 0 0 24px rgba(194, 39, 61, 0.6);
}
.teaser-title {
  font-family: var(--font-display);
  font-size: clamp(26px, 4.6vw, 38px);
  letter-spacing: 8px;
  margin: 16px 0 10px;
}
.teaser-text {
  color: var(--ink-dim);
  font-size: 14.5px;
  line-height: 2;
  letter-spacing: 1px;
}

/* ---------- 关于页 ---------- */
.about-grid {
  display: grid;
  gap: 18px;
  margin-top: 34px;
  animation: fadeUp 0.9s 0.2s both;
}
.about-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 26px 30px;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.about-card h2 {
  font-family: var(--font-display);
  font-size: 19px;
  letter-spacing: 4px;
  color: var(--petal);
  margin-bottom: 14px;
}
.about-card p, .about-card li {
  font-size: 14px;
  line-height: 2;
  color: var(--ink-dim);
}
.about-card ul { list-style: none; display: grid; gap: 6px; }
.about-card li::before {
  content: "❀";
  color: var(--crimson);
  margin-right: 8px;
  font-size: 11px;
}
.about-card strong { color: var(--ink); font-weight: 600; }

/* ---------- 页脚 ---------- */
.site-footer {
  position: relative;
  z-index: 5;
  text-align: center;
  padding: 30px 20px 36px;
  border-top: 1px solid var(--line);
  background: rgba(13, 11, 14, 0.65);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.footer-domain {
  font-family: var(--font-display);
  letter-spacing: 6px;
  font-size: 15px;
  color: var(--ink-dim);
}
.footer-declare {
  margin-top: 8px;
  font-size: 12.5px;
  color: var(--ink-faint);
  letter-spacing: 1px;
}

/* ---------- 动画 ---------- */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(22px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes popIn {
  from { opacity: 0; transform: translateY(14px) scale(0.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- 响应式 ---------- */
@media (max-width: 880px) {
  /* 竖屏：仅使用中性遮罩提高文字可读性。 */
  .bg-shade {
    background:
      linear-gradient(to bottom, rgba(13, 9, 12, 0.22) 0%, rgba(13, 9, 12, 0.37) 55%, rgba(13, 9, 12, 0.64) 100%),
      linear-gradient(to right, rgba(13, 9, 12, 0.27), rgba(13, 9, 12, 0.14));
  }
  /* 主页内容落到底部深色区，上半屏留给视频中的角色 */
  .hero { justify-content: flex-end; padding-bottom: 56px; }
  .site-header { padding: 12px 16px; }
  .brand-text { font-size: 16px; }
  .brand-text .brand-latin { display: none; }
  .site-nav { gap: 14px; }
  .nav-link { font-size: 13.5px; letter-spacing: 1px; }
  .hero { padding: 100px 20px 40px; }
  .hero-anniversary {
    top: 76px;
    right: 14px;
    width: 116px;
    min-height: 132px;
    padding: 12px 11px 10px;
    border-radius: 13px;
    font-size: 9.5px;
    letter-spacing: 1.4px;
  }
  .hero-anniversary .anniversary-label + .anniversary-centered { margin-top: 11px; }
  .hero-anniversary strong { margin: 4px 0; font-size: 27px; }
  .anniversary-flower {
    top: -16px;
    left: -22px;
    width: 58px;
  }
  .banner-history-modal { padding: 14px; }
  .banner-history-dialog {
    max-height: calc(100dvh - 28px);
    padding: 24px 18px 26px;
    border-radius: 20px;
  }
  .banner-history-kicker { font-size: 8.5px; letter-spacing: 2px; }
  .banner-history-head h2 { font-size: 26px; }
  .banner-history-intro { max-width: 260px; font-size: 12px; }
  .banner-history-timeline { margin-top: 22px; padding-left: 27px; }
  .banner-history-timeline::before { left: 7px; }
  .banner-history-dot { left: -26px; }
  .banner-history-card { padding: 15px 14px 16px; }
  .banner-history-card h3 { font-size: 18px; }
  .banner-history-card time,
  .banner-history-range,
  .banner-history-now { font-size: 10.5px; }
  .banner-history-range { margin: 0 4px; }
  .cards { grid-template-columns: 1fr; padding: 0 20px 60px; }
  .chat-layout { grid-template-columns: 1fr; height: calc(100dvh - 158px); min-height: 420px; }
  .chat-aside {
    flex-direction: row;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
  }
  .avatar-img { width: 52px; height: 52px; }
  .aside-name { font-size: 19px; }
  .aside-bio, .aside-back { display: none; }
  .msg { max-width: 88%; }
  .page-main { padding-top: 90px; }
}

/* ---------- 减少动态效果 ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
}


/* ==========================================
   信物与记忆档案页面样式 (全局收敛合并)
   ========================================== */
/* 椿 · 信物与记忆档案专属样式 (纯粹官方质感，PC优先) */

.archive-page {
  padding-top: 86px;
  padding-bottom: 90px;
  max-width: 1240px;
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
  position: relative;
  z-index: 10;
}

/* 顶部 Banner */
.archive-hero {
  text-align: center;
  margin-bottom: 44px;
  padding-top: 20px;
}
.archive-kicker {
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: 4px;
  color: #ff536d;
  margin-bottom: 8px;
  text-transform: uppercase;
  font-weight: 600;
}
.archive-title {
  font-family: var(--font-display);
  font-size: clamp(32px, 4vw, 44px);
  color: var(--ink);
  letter-spacing: 3px;
  margin-bottom: 12px;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.85), 0 0 24px rgba(194, 39, 61, 0.5);
}
.archive-lead {
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 1.5px;
  color: #ff8299;
  max-width: 680px;
  margin: 0 auto;
  line-height: 1.8;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.95), 0 2px 10px rgba(0, 0, 0, 0.85);
}

/* 章节通用标题栏 */
.section-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 12px;
}
.section-title-group {
  display: flex;
  align-items: baseline;
  gap: 12px;
}
.section-title {
  font-family: var(--font-display);
  font-size: 22px;
  color: var(--ink);
  letter-spacing: 1.5px;
}
.section-sub {
  font-size: 12px;
  letter-spacing: 2px;
  color: var(--ink-faint);
  font-family: var(--sans);
}

/* ====================================================
   第一部分：好感度故事 (官方风格小方框 Tabs)
   ==================================================== */
.stories-container {
  background: rgba(18, 14, 18, 0.82);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  padding: 24px 30px;
  box-shadow: var(--shadow);
}

/* 小方框 Tabs 导航（对齐官方 UI） */
.story-tabs-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 22px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  flex-wrap: wrap;
}

.story-tab-btn {
  padding: 8px 20px;
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 500;
  color: #c9c1c7;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s ease;
}
.story-tab-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.28);
}

/* 官方同款古铜金色选中小方框 */
.story-tab-btn.is-active {
  background: #bfa15f;
  color: #17130e;
  border-color: #bfa15f;
  font-weight: 600;
  box-shadow: 0 0 16px rgba(191, 161, 95, 0.45);
}

/* 故事面板内容 */
.story-panel {
  display: none;
}
.story-panel.is-active {
  display: block;
  animation: storyFadeIn 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
}

@keyframes storyFadeIn {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.story-header {
  margin-bottom: 18px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(191, 161, 95, 0.2);
}
.story-title {
  font-family: var(--font-display);
  font-size: 24px;
  color: #d8be82;
  letter-spacing: 1.5px;
}

.story-body {
  max-height: 480px;
  overflow-y: auto;
  padding-right: 18px;
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.9;
  color: #dfd8d6;
}
.story-body p {
  margin-bottom: 16px;
  text-indent: 2em;
}
.story-body p:first-of-type {
  text-indent: 0;
  font-size: 16px;
  font-family: var(--serif);
  color: #ff859c;
  margin-bottom: 20px;
}

/* 自定义滚动条 */
.story-body::-webkit-scrollbar {
  width: 6px;
}
.story-body::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 3px;
}
.story-body::-webkit-scrollbar-thumb {
  background: rgba(191, 161, 95, 0.35);
  border-radius: 3px;
}
.story-body::-webkit-scrollbar-thumb:hover {
  background: #bfa15f;
}

/* ====================================================
   第二部分：随身信物 3D 翻转卡片网格
   ==================================================== */
.relic-category-header {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 16px;
  padding-left: 2px;
}
.relic-category-title {
  font-family: var(--font-display);
  font-size: 17px;
  color: #d8be82;
  letter-spacing: 1.5px;
}
.relic-category-sub {
  font-size: 11px;
  letter-spacing: 2px;
  color: var(--ink-faint);
  font-family: var(--sans);
}

.relics-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin-bottom: 36px;
}
.relics-grid:last-of-type {
  margin-bottom: 60px;
}

.relic-card-wrapper {
  perspective: 1200px;
  height: 380px;
  cursor: pointer;
}

.relic-card {
  width: 100%;
  height: 100%;
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.65s cubic-bezier(0.2, 0.8, 0.2, 1);
  border-radius: 10px;
}

.relic-card-wrapper:hover .relic-card {
  box-shadow: 0 10px 28px rgba(194, 39, 61, 0.22);
}

.relic-card-wrapper.is-flipped .relic-card {
  transform: rotateY(180deg);
}

/* 卡片正反面通用 */
.card-face {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border-radius: 10px;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(18, 14, 18, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  padding: 20px 22px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* 正面 */
.card-face.front {
  align-items: center;
  justify-content: space-between;
  background: radial-gradient(circle at 50% 30%, rgba(194, 39, 61, 0.14), transparent 70%),
              rgba(18, 14, 18, 0.92);
  transition: border-color 0.3s ease;
}
.relic-card-wrapper:hover .card-face.front {
  border-color: rgba(255, 83, 109, 0.45);
}

.relic-tag {
  align-self: flex-start;
  font-size: 11px;
  letter-spacing: 1px;
  padding: 2px 8px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.08);
  color: #bfa15f;
  border: 1px solid rgba(191, 161, 95, 0.3);
}

.relic-visual {
  width: 140px;
  height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 6px 0;
  position: relative;
}
.relic-visual img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 8px 18px rgba(0, 0, 0, 0.6));
  transition: transform 0.4s ease;
}
.relic-card-wrapper:hover .relic-visual img {
  transform: scale(1.05);
}

.relic-info {
  text-align: center;
  width: 100%;
}
.relic-name {
  font-family: var(--font-display);
  font-size: 19px;
  color: var(--ink);
  letter-spacing: 1px;
  margin-bottom: 6px;
}
.relic-desc {
  font-size: 12px;
  color: var(--ink-dim);
  line-height: 1.5;
}

/* 背面 */
.card-face.back {
  transform: rotateY(180deg) translateZ(1px);
  background: linear-gradient(145deg, rgba(26, 18, 24, 0.95), rgba(16, 12, 16, 0.97));
  border-color: rgba(191, 161, 95, 0.35);
  justify-content: space-between;
}

.back-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(191, 161, 95, 0.22);
  padding-bottom: 10px;
  margin-bottom: 14px;
}
.back-title {
  font-family: var(--font-display);
  font-size: 18px;
  color: #e2be72;
  letter-spacing: 1.2px;
  font-weight: 600;
}
.back-id {
  font-size: 11.5px;
  color: #d6cdc3;
  background: rgba(191, 161, 95, 0.15);
  padding: 2px 7px;
  border-radius: 4px;
  border: 1px solid rgba(191, 161, 95, 0.28);
  letter-spacing: 0.5px;
}

.back-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  margin: auto 0;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(191, 161, 95, 0.28) transparent;
  padding: 2px 4px 2px 0;
}
.back-body::-webkit-scrollbar {
  width: 4px;
}
.back-body::-webkit-scrollbar-thumb {
  background: rgba(191, 161, 95, 0.28);
  border-radius: 4px;
}

.back-quote {
  font-family: var(--serif);
  font-size: 15px;
  line-height: 1.68;
  color: #f7f3ef;
  font-weight: 500;
  position: relative;
  padding-left: 14px;
  border-left: 2.5px solid #ff4d6a;
  letter-spacing: 0.3px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.75);
  margin: auto 0;
}

/* 玩家名称动态高亮占位符 */
.player-name {
  color: #ffc436;
  font-weight: 600;
  border-bottom: 1px dashed rgba(255, 196, 54, 0.6);
  padding: 0 2px;
  transition: all 0.2s ease;
}
.player-name:hover {
  border-bottom-color: #ffc436;
  text-shadow: 0 0 8px rgba(255, 196, 54, 0.5);
}

/* ---------- 椿的收藏匣与气泡收藏按钮 ---------- */
.msg-camellya {
  position: relative;
}
.msg-camellya .bubble-container {
  position: relative;
  display: flex;
  flex-direction: column;
  max-width: 100%;
}
.btn-bubble-fav {
  align-self: flex-start;
  margin-top: 4px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  background: rgba(30, 18, 24, 0.55);
  border: 1px solid rgba(232, 180, 188, 0.2);
  border-radius: 999px;
  font-size: 11px;
  color: var(--ink-faint);
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.2, 0, 0, 1);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  opacity: 0.7;
}
.btn-bubble-fav:hover {
  opacity: 1;
  color: var(--petal);
  border-color: rgba(232, 180, 188, 0.5);
  background: rgba(45, 20, 28, 0.75);
}
.btn-bubble-fav.is-fav {
  opacity: 1;
  color: #f7b801;
  border-color: rgba(247, 184, 1, 0.45);
  background: rgba(50, 36, 20, 0.7);
}
.btn-bubble-fav svg {
  transition: transform 0.2s;
}
.btn-bubble-fav:active svg {
  transform: scale(1.25);
}

/* 收藏匣模态弹窗 */
.fav-modal {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.fav-modal[hidden] {
  display: none !important;
}
.fav-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(8, 5, 8, 0.78);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.fav-dialog {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 600px;
  max-height: 82vh;
  display: flex;
  flex-direction: column;
  background: linear-gradient(165deg, rgba(38, 20, 28, 0.94), rgba(24, 12, 18, 0.96));
  border: 1px solid rgba(232, 180, 188, 0.24);
  border-radius: 18px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.65), 0 0 40px rgba(194, 39, 61, 0.15);
  padding: 24px;
  animation: popIn 0.35s cubic-bezier(0.16, 1, 0.3, 1) both;
}
.fav-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(232, 180, 188, 0.15);
  padding-bottom: 14px;
}
.fav-head-title {
  display: flex;
  align-items: center;
  gap: 12px;
}
.fav-head-title h3 {
  font-family: var(--font-display);
  font-size: 20px;
  color: var(--ink);
  letter-spacing: 1px;
}
.fav-counter {
  font-size: 12px;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(247, 184, 1, 0.12);
  color: #f7b801;
  border: 1px solid rgba(247, 184, 1, 0.28);
}
.fav-close-btn {
  background: transparent;
  border: none;
  font-size: 24px;
  line-height: 1;
  color: var(--ink-faint);
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 8px;
  transition: all 0.2s;
}
.fav-close-btn:hover {
  color: var(--petal);
  background: rgba(255, 255, 255, 0.08);
}
.fav-tip {
  font-size: 12px;
  color: var(--ink-faint);
  margin: 10px 0 16px;
  line-height: 1.5;
}
.fav-list {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-right: 6px;
  scrollbar-width: thin;
  scrollbar-color: rgba(194, 39, 61, 0.4) transparent;
}
.fav-empty {
  text-align: center;
  padding: 48px 20px;
  color: var(--ink-faint);
  font-size: 13.5px;
  line-height: 1.8;
}
.fav-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  background: rgba(50, 24, 34, 0.45);
  border: 1px solid rgba(232, 180, 188, 0.14);
  border-radius: 12px;
  transition: all 0.25s;
}
.fav-item:hover {
  border-color: rgba(232, 180, 188, 0.32);
  background: rgba(55, 26, 38, 0.65);
}
.fav-play-btn {
  flex-shrink: 0;
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(194, 39, 61, 0.25);
  border: 1px solid rgba(232, 180, 188, 0.3);
  color: var(--petal);
  cursor: pointer;
  transition: all 0.2s;
  margin-top: 2px;
}
.fav-play-btn:hover {
  background: rgba(194, 39, 61, 0.55);
  transform: scale(1.06);
}
.fav-play-btn.is-playing {
  background: #f7b801;
  color: #1a0f12;
  border-color: #f7b801;
  box-shadow: 0 0 12px rgba(247, 184, 1, 0.45);
}
.fav-content {
  flex: 1;
  min-width: 0;
}
.fav-text {
  font-family: var(--serif);
  font-size: 14px;
  line-height: 1.8;
  color: var(--ink);
  word-break: break-word;
}
.fav-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  color: var(--ink-faint);
  margin-top: 6px;
}
.fav-del-btn {
  flex-shrink: 0;
  background: transparent;
  border: none;
  color: var(--ink-faint);
  cursor: pointer;
  padding: 6px;
  border-radius: 6px;
  font-size: 13px;
  transition: all 0.2s;
}
.fav-del-btn:hover {
  color: #ff536d;
  background: rgba(255, 83, 109, 0.1);
}

/* Toast 提示浮窗 */
.fav-toast {
  position: fixed;
  top: 72px;
  left: 50%;
  transform: translateX(-50%) translateY(-10px);
  z-index: 1300;
  padding: 8px 18px;
  background: rgba(36, 18, 25, 0.92);
  border: 1px solid rgba(247, 184, 1, 0.4);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
  border-radius: 999px;
  color: #fff;
  font-size: 12.5px;
  pointer-events: none;
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
.fav-toast.is-show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ---------- 未开放 / 筹备中页面通用样式 ---------- */
.coming-container {
  max-width: 780px;
  margin: 20px auto 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.coming-hero-card {
  width: 100%;
  background: linear-gradient(165deg, rgba(38, 20, 28, 0.88), rgba(24, 12, 18, 0.94));
  border: 1px solid rgba(232, 180, 188, 0.2);
  border-radius: 20px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.55), 0 0 40px rgba(194, 39, 61, 0.12);
  padding: 44px 36px 40px;
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  animation: popIn 0.45s cubic-bezier(0.16, 1, 0.3, 1) both;
}
.coming-hero-card::before {
  content: "";
  position: absolute;
  top: -50px;
  right: -50px;
  width: 160px;
  height: 160px;
  background: radial-gradient(circle, rgba(194, 39, 61, 0.25), transparent 70%);
  pointer-events: none;
}
.coming-status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  letter-spacing: 1.5px;
  padding: 4px 14px;
  border-radius: 999px;
  background: rgba(247, 184, 1, 0.12);
  color: #f7b801;
  border: 1px solid rgba(247, 184, 1, 0.32);
  margin-bottom: 20px;
}
.coming-icon-wrap {
  width: 76px;
  height: 76px;
  margin: 0 auto 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: radial-gradient(circle at 40% 40%, rgba(194, 39, 61, 0.35), rgba(30, 14, 20, 0.6));
  border: 1px solid rgba(232, 180, 188, 0.3);
  color: var(--petal);
  box-shadow: 0 0 28px rgba(194, 39, 61, 0.3);
}
.coming-icon-wrap svg {
  width: 38px;
  height: 38px;
}
.coming-quote {
  font-family: var(--serif);
  font-size: 15.5px;
  line-height: 2;
  color: #f0e6e8;
  margin: 20px auto 32px;
  max-width: 600px;
  padding: 16px 22px;
  background: rgba(50, 22, 32, 0.45);
  border-left: 3px solid var(--crimson);
  border-radius: 4px 10px 10px 4px;
  text-align: left;
}
.coming-quote-author {
  display: block;
  text-align: right;
  font-size: 12.5px;
  color: var(--petal);
  margin-top: 8px;
}
.coming-plan-title {
  font-size: 12px;
  letter-spacing: 2px;
  color: var(--ink-faint);
  margin-bottom: 14px;
}
.coming-features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 36px;
  text-align: left;
}
.coming-feature-card {
  padding: 16px;
  background: rgba(50, 24, 34, 0.45);
  border: 1px solid rgba(232, 180, 188, 0.14);
  border-radius: 12px;
  transition: border-color 0.25s, transform 0.25s;
}
.coming-feature-card:hover {
  border-color: rgba(232, 180, 188, 0.35);
  transform: translateY(-2px);
}
.coming-feature-title {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.coming-feature-desc {
  font-size: 12px;
  line-height: 1.6;
  color: var(--ink-dim);
}
.coming-btn-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
}
.coming-btn {
  padding: 9px 24px;
  font-size: 13.5px;
  letter-spacing: 1.5px;
  border-radius: 999px;
  text-decoration: none;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.coming-btn-primary {
  background: linear-gradient(135deg, rgba(194, 39, 61, 0.8), rgba(138, 30, 45, 0.9));
  color: #fff;
  border: 1px solid rgba(232, 180, 188, 0.4);
  box-shadow: 0 4px 16px rgba(194, 39, 61, 0.35);
}
.coming-btn-primary:hover {
  background: linear-gradient(135deg, rgba(220, 45, 70, 0.9), rgba(160, 35, 52, 1));
  box-shadow: 0 6px 22px rgba(194, 39, 61, 0.5);
  transform: translateY(-1px);
  color: #fff;
}
.coming-btn-secondary {
  background: rgba(255, 255, 255, 0.06);
  color: var(--ink-dim);
  border: 1px solid rgba(255, 255, 255, 0.16);
}
.coming-btn-secondary:hover {
  background: rgba(255, 255, 255, 0.12);
  color: var(--ink);
  border-color: rgba(232, 180, 188, 0.35);
}

@media (max-width: 880px) {
  .site-nav {
    gap: 10px;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .site-nav::-webkit-scrollbar {
    display: none;
  }
  .nav-link {
    font-size: 13px;
    white-space: nowrap;
    padding: 6px 1px;
  }
  .coming-features-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .coming-hero-card {
    padding: 30px 18px;
  }
  .coming-btn-row {
    flex-direction: column;
    width: 100%;
  }
  .coming-btn {
    width: 100%;
    justify-content: center;
  }
}

/* ---------- 全站页面无缝路由 View Transitions ---------- */
.site-header {
  view-transition-name: site-header;
}
#app {
  view-transition-name: page-content;
}

::view-transition-group(site-header) {
  animation-duration: 0.22s;
}

::view-transition-group(active-nav-indicator) {
  animation-duration: 0.32s;
  animation-timing-function: cubic-bezier(0.2, 0, 0, 1);
}

::view-transition-old(page-content) {
  animation: 180ms cubic-bezier(0.4, 0, 0.2, 1) both pageFadeOut;
}
::view-transition-new(page-content) {
  animation: 280ms cubic-bezier(0, 0, 0.2, 1) 30ms both pageFadeIn;
}

@keyframes pageFadeOut {
  from { opacity: 1; transform: translateY(0); }
  to { opacity: 0; transform: translateY(-4px); }
}
@keyframes pageFadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  ::view-transition-group(*),
  ::view-transition-old(*),
  ::view-transition-new(*) {
    animation: none !important;
  }
}

/* 登录弹窗 */
.auth-modal {
  position: fixed;
  inset: 0;
  z-index: 1300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.auth-modal[hidden],
.auth-modal [hidden] { display: none !important; }
.auth-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(8, 5, 8, 0.78);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.auth-dialog {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 420px;
  background: linear-gradient(165deg, rgba(38, 20, 28, 0.94), rgba(24, 12, 18, 0.96));
  border: 1px solid rgba(232, 180, 188, 0.24);
  border-radius: 18px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.65), 0 0 40px rgba(194, 39, 61, 0.15);
  padding: 22px 24px 24px;
  animation: popIn 0.35s cubic-bezier(0.16, 1, 0.3, 1) both;
}
.auth-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.auth-head h3 {
  font-family: var(--font-display);
  font-size: 20px;
  color: var(--ink);
  letter-spacing: 2px;
}
.auth-tabs {
  display: flex;
  gap: 8px;
  margin: 8px 0 12px;
}
.auth-tab {
  flex: 1;
  background: transparent;
  border: 1px solid var(--line);
  color: var(--ink-dim);
  border-radius: 999px;
  padding: 8px 0;
  letter-spacing: 2px;
  cursor: pointer;
}
.auth-tab.is-active {
  color: var(--petal);
  border-color: rgba(232, 180, 188, 0.55);
  background: rgba(194, 39, 61, 0.16);
}
.auth-tip {
  font-size: 12px;
  color: var(--ink-faint);
  line-height: 1.6;
  margin: 0 0 12px;
}
.auth-error {
  font-size: 13px;
  color: #ff8a9a;
  margin: 0 0 12px;
}
.auth-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.auth-form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12px;
  letter-spacing: 1px;
  color: var(--ink-dim);
}
.auth-form input {
  background: rgba(16, 10, 14, 0.55);
  border: 1px solid rgba(232, 180, 188, 0.2);
  color: var(--ink);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 14px;
}
.auth-form input:focus {
  outline: none;
  border-color: rgba(232, 180, 188, 0.55);
}
.auth-submit {
  margin-top: 6px;
  background: linear-gradient(135deg, rgba(194, 39, 61, 0.92), rgba(140, 28, 46, 1));
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 10px 16px;
  letter-spacing: 2px;
  cursor: pointer;
}
.auth-submit:hover { filter: brightness(1.08); }
.auth-account-name {
  font-family: var(--font-display);
  font-size: 22px;
  letter-spacing: 2px;
  margin: 8px 0 10px;
}
