:root {
  --bg-1: #14091c;
  --bg-2: #1f0a2a;
  --bg-3: #2a0c2e;
  --pink: #ff6b9d;
  --pink-soft: #ffa8c5;
  --rose: #ff4d7d;
  --gold: #ffd36e;
  --cream: #fff4f7;
  --text: #f6e9f0;
  --muted: #c9a9bb;
  --card: rgba(255, 255, 255, 0.06);
  --border: rgba(255, 170, 200, 0.22);
  --radius: 20px;
  --font-serif: "Noto Serif SC", "Songti SC", "STSong", "SimSun", Georgia, serif;
  --font-body: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  --font-hand: "Xingkai SC", "STXingkai", "KaiTi", "楷体", "STKaiti", cursive;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 96px; }

body {
  font-family: var(--font-body);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  background:
    radial-gradient(60% 50% at 15% 5%, rgba(255, 77, 125, 0.28), transparent 60%),
    radial-gradient(50% 40% at 85% 30%, rgba(138, 77, 255, 0.22), transparent 60%),
    radial-gradient(60% 50% at 50% 70%, rgba(255, 150, 180, 0.10), transparent 60%),
    radial-gradient(70% 60% at 50% 100%, rgba(255, 150, 180, 0.14), transparent 60%),
    linear-gradient(180deg, var(--bg-1) 0%, var(--bg-2) 50%, var(--bg-3) 100%);
  background-attachment: fixed;
}

::selection { background: rgba(255, 107, 157, 0.4); color: #fff; }

::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: var(--bg-1); }
::-webkit-scrollbar-thumb { background: rgba(255, 107, 157, 0.35); border-radius: 5px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255, 107, 157, 0.6); }

#bg-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

.cursor-glow {
  position: fixed;
  left: 0;
  top: 0;
  width: 420px;
  height: 420px;
  margin: -210px 0 0 -210px;
  border-radius: 50%;
  pointer-events: none;
  z-index: 1;
  transform: translate(-999px, -999px);
  background: radial-gradient(circle, rgba(255, 120, 170, 0.18) 0%, rgba(255, 120, 170, 0.06) 40%, transparent 70%);
}
@media (hover: none) { .cursor-glow { display: none; } }

.nav, .hero, .section, .footer { position: relative; z-index: 2; }

/* ---------- 导航（融合星空胶囊导航） ---------- */
.nav {
  position: fixed;
  top: 14px;
  left: 12px;
  right: 12px;
  max-width: 1120px;
  margin: 0 auto;
  z-index: 50;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 9px 14px 9px 20px;
  border-radius: 999px;
  background: rgba(10, 7, 16, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transform: translateY(-160%);
  transition: transform 0.5s ease;
}
.nav.show { transform: translateY(0); }
.nav-brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  text-decoration: none;
  color: #fecdd3;
  white-space: nowrap;
}
.brand-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #34d399;
  animation: ping 2.2s ease-out infinite;
}
.brand-text { font-size: 11px; font-weight: 500; letter-spacing: 0.2em; }
.nav-links { display: flex; gap: 4px; }
.nav-links a {
  color: var(--muted);
  text-decoration: none;
  padding: 7px 14px;
  border-radius: 999px;
  font-size: 14px;
  transition: all 0.3s;
}
.nav-links a:hover, .nav-links a.active { color: #fff; background: rgba(255, 107, 157, 0.18); }
.nav-tools { display: flex; align-items: center; gap: 8px; }
.icon-btn {
  width: 34px; height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
  color: #ffb3c6;
  font-size: 15px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.25s;
}
.icon-btn:hover { background: rgba(255, 255, 255, 0.12); }
.icon-btn.active {
  color: #fff;
  background: rgba(255, 107, 157, 0.35);
  border-color: rgba(255, 107, 157, 0.6);
}
.nav-bpm {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px 5px 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #ff8fa8;
  transition: opacity 0.3s;
}
.nav-bpm.is-paused { opacity: 0.5; }
.ecg { width: 44px; height: 16px; }
.ecg-line {
  stroke-dasharray: 100;
  stroke-dashoffset: 100;
  animation: ecgDash 2.4s linear infinite;
}
#bpmDisplay {
  font-size: 11px;
  letter-spacing: 0.08em;
  color: #fda4af;
  font-family: ui-monospace, Menlo, Consolas, monospace;
}
@keyframes ecgDash { to { stroke-dashoffset: -100; } }
@keyframes ping {
  0% { box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.5); }
  70% { box-shadow: 0 0 0 8px rgba(52, 211, 153, 0); }
  100% { box-shadow: 0 0 0 0 rgba(52, 211, 153, 0); }
}

/* ---------- Hero ---------- */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 80px 24px 120px;
}
.hero-content {
  position: relative;
  text-align: center;
  max-width: 820px;
  transition: transform 0.4s ease-out;
  will-change: transform;
}
.eyebrow {
  font-size: 14px;
  letter-spacing: 0.2em;
  color: var(--pink-soft);
  margin-bottom: 24px;
  opacity: 0;
  animation: fadeUp 1s 0.2s ease-out forwards;
}
.eyebrow-heart { display: inline-block; margin-right: 6px; animation: beat 1.4s ease-in-out infinite; }
.hero-title {
  font-family: var(--font-serif);
  font-size: clamp(48px, 9vw, 104px);
  line-height: 1.1;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.25em;
  flex-wrap: wrap;
  opacity: 0;
  animation: fadeUp 1.2s 0.4s ease-out forwards;
}
.name {
  display: inline-block;
  background: linear-gradient(135deg, #fff 0%, var(--pink-soft) 50%, var(--pink) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: float 5s ease-in-out infinite;
}
.name-b { animation-delay: -2.5s; }
.amp {
  font-size: 0.55em;
  color: var(--gold);
  font-style: italic;
  font-family: Georgia, serif;
  display: inline-block;
  animation: beat 1.8s ease-in-out infinite;
}
.typeline {
  font-size: clamp(18px, 2.4vw, 26px);
  color: var(--cream);
  min-height: 1.8em;
  margin-top: 28px;
  letter-spacing: 0.05em;
  opacity: 0;
  animation: fadeUp 1s 0.8s ease-out forwards;
}
.caret {
  display: inline-block;
  width: 2px;
  height: 1.1em;
  background: var(--pink);
  vertical-align: -0.15em;
  margin-left: 4px;
  animation: blink 1s steps(1) infinite;
}
.counter {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  margin-top: 44px;
  flex-wrap: wrap;
  opacity: 0;
  animation: fadeUp 1s 1.1s ease-out forwards;
}
.counter-box {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 14px 18px;
  min-width: 88px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.counter-box .num {
  display: block;
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: #fff;
  font-family: var(--font-serif);
  line-height: 1.1;
}
.counter-box .num.tick { animation: pop 0.45s ease; }
.counter-box .label { font-size: 12px; color: var(--muted); letter-spacing: 0.2em; }
.counter-sep { font-size: 30px; color: var(--pink); opacity: 0.6; animation: blink 1s steps(1) infinite; }
.next-anniv {
  margin-top: 22px;
  color: var(--muted);
  font-size: 14px;
  opacity: 0;
  animation: fadeUp 1s 1.4s ease-out forwards;
}
.next-anniv b { color: var(--gold); font-size: 18px; }

.hero-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  pointer-events: none;
  transition: transform 0.6s ease-out;
}
.hero-blob-1 { width: 420px; height: 420px; left: -120px; top: -100px; background: radial-gradient(circle, #ff4d7d, transparent 70%); opacity: 0.5; }
.hero-blob-2 { width: 520px; height: 520px; right: -150px; bottom: -150px; background: radial-gradient(circle, #8a4dff, transparent 70%); opacity: 0.4; }
.hero-blob-3 { width: 300px; height: 300px; left: 60%; top: 20%; background: radial-gradient(circle, #ffb347, transparent 70%); opacity: 0.28; }

.scroll-hint {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
  letter-spacing: 0.2em;
  opacity: 0;
  animation: fadeUp 1s 1.8s ease-out forwards;
}
.mouse {
  width: 22px; height: 36px;
  border: 2px solid var(--pink-soft);
  border-radius: 12px;
  position: relative;
}
.mouse::after {
  content: '';
  position: absolute;
  left: 50%; top: 6px;
  width: 4px; height: 8px;
  margin-left: -2px;
  border-radius: 2px;
  background: var(--pink);
  animation: wheel 1.6s ease-in-out infinite;
}

/* ---------- 通用区块 ---------- */
.section { padding: 110px 24px; max-width: 1100px; margin: 0 auto; }
.section-title {
  text-align: center;
  font-family: var(--font-serif);
  font-size: clamp(30px, 4.5vw, 44px);
  color: #fff;
  margin-bottom: 12px;
}
.section-title span { position: relative; display: inline-block; padding: 0 20px; }
.section-title span::before, .section-title span::after {
  content: '♥';
  color: var(--pink);
  font-size: 0.5em;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
}
.section-title span::before { left: -14px; }
.section-title span::after { right: -14px; }
.section-sub { text-align: center; color: var(--muted); margin-bottom: 56px; font-size: 15px; }

.reveal {
  opacity: 0;
  transform: translateY(36px);
  transition: opacity 0.9s ease, transform 0.9s cubic-bezier(0.2, 0.7, 0.2, 1);
  transition-delay: var(--delay, 0s);
}
.reveal.visible { opacity: 1; transform: none; }

/* ---------- 情书 ---------- */
.letter-wrap { display: flex; justify-content: center; }
.letter-paper {
  position: relative;
  max-width: 680px;
  width: 100%;
  padding: 56px 56px 44px;
  border-radius: 6px;
  color: #3b2a33;
  background: linear-gradient(180deg, #fffaf3, #fff1e6);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45), inset 0 0 80px rgba(255, 200, 160, 0.25);
  transform: rotate(-1.2deg);
  font-family: var(--font-hand);
  font-size: 18px;
  line-height: 2;
  transition: transform 0.6s ease;
}
.letter-paper:hover { transform: rotate(0deg) scale(1.01); }
.letter-paper::before {
  content: '';
  position: absolute;
  inset: 12px;
  border: 1px dashed rgba(200, 120, 140, 0.4);
  border-radius: 4px;
  pointer-events: none;
}
.letter-seal {
  position: absolute;
  top: -22px; right: 40px;
  width: 56px; height: 56px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #ff6b9d, #c2185b);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  box-shadow: 0 8px 20px rgba(194, 24, 91, 0.5);
  transform: rotate(12deg);
  animation: beat 2s ease-in-out infinite;
}
.letter-salutation { font-size: 22px; margin-bottom: 8px; color: #c2185b; }
.letter-text { white-space: pre-line; min-height: 200px; }
.letter-text::after {
  content: '';
  display: inline-block;
  width: 2px; height: 1em;
  background: #c2185b;
  vertical-align: -0.1em;
  margin-left: 2px;
  animation: blink 1s steps(1) infinite;
}
.letter-text.done::after { display: none; }
.letter-sign { text-align: right; margin-top: 24px; font-size: 20px; color: #c2185b; }
.letter-date { font-size: 14px; color: #9a6b78; }

/* ---------- 时光轴 ---------- */
.timeline { position: relative; max-width: 900px; margin: 0 auto; padding: 20px 0; }
.timeline-line {
  position: absolute;
  left: 50%; top: 0; bottom: 0;
  width: 3px;
  margin-left: -1.5px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  overflow: hidden;
}
.timeline-progress {
  width: 100%; height: 0;
  background: linear-gradient(180deg, var(--pink), var(--gold));
  border-radius: 2px;
  transition: height 0.2s ease-out;
}
.timeline-item { position: relative; width: 50%; padding: 0 48px 64px 0; }
.timeline-item.right { margin-left: 50%; padding: 0 0 64px 48px; }
.timeline-dot {
  position: absolute;
  top: 22px; right: -11px;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--bg-1);
  border: 3px solid var(--pink);
  box-shadow: 0 0 0 6px rgba(255, 107, 157, 0.2);
  z-index: 2;
}
.timeline-item.right .timeline-dot { right: auto; left: -11px; }
.timeline-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 28px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  text-align: left;
  transition: transform 0.4s ease, box-shadow 0.4s ease, border-color 0.4s;
}
.timeline-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 50px rgba(255, 107, 157, 0.15);
  border-color: rgba(255, 107, 157, 0.5);
}
.timeline-date {
  display: inline-block;
  font-size: 12px;
  letter-spacing: 0.15em;
  color: var(--gold);
  background: rgba(255, 211, 110, 0.1);
  padding: 3px 10px;
  border-radius: 999px;
  margin-bottom: 12px;
}
.timeline-card h3 { font-size: 20px; color: #fff; margin-bottom: 8px; display: flex; align-items: center; gap: 10px; }
.timeline-emoji { font-size: 24px; }
.timeline-card p { color: var(--muted); font-size: 15px; }

/* ---------- 相册 ---------- */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 36px;
  perspective: 1200px;
}
.polaroid {
  position: relative;
  background: #fff8f2;
  padding: 14px 14px 18px;
  border-radius: 4px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4);
  transform-style: preserve-3d;
  transition: transform 0.15s ease-out, box-shadow 0.3s;
  cursor: zoom-in;
  will-change: transform;
  transform: rotate(var(--rot, 0deg));
}
.polaroid:hover { box-shadow: 0 30px 60px rgba(255, 107, 157, 0.25); }
.polaroid-photo {
  aspect-ratio: 4 / 3;
  border-radius: 2px;
  overflow: hidden;
  background: var(--ph, linear-gradient(135deg, #ff9a9e, #fad0c4));
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.polaroid-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.polaroid-emoji {
  font-size: 64px;
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.25));
  transition: transform 0.4s;
}
.polaroid:hover .polaroid-emoji { transform: scale(1.15) rotate(-6deg); }
.polaroid-glare {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at var(--gx, 50%) var(--gy, 50%), rgba(255, 255, 255, 0.45), transparent 50%);
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
}
.polaroid:hover .polaroid-glare { opacity: 1; }
.polaroid-caption {
  margin-top: 12px;
  text-align: center;
  font-family: var(--font-hand);
  font-size: 20px;
  color: #5a3a44;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(10, 4, 14, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}
.lightbox.open { opacity: 1; pointer-events: auto; }
.lightbox-body { max-width: 900px; width: 100%; transform: scale(0.9); transition: transform 0.35s cubic-bezier(0.2, 0.7, 0.2, 1); }
.lightbox.open .lightbox-body { transform: scale(1); }
.lightbox .polaroid { cursor: default; transform: none !important; }
.lightbox-close {
  position: absolute;
  top: 20px; right: 28px;
  background: none;
  border: none;
  color: #fff;
  font-size: 40px;
  cursor: pointer;
  line-height: 1;
  transition: transform 0.3s;
}
.lightbox-close:hover { transform: rotate(90deg); }

/* ---------- 爱你的理由 ---------- */
.reasons { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 22px; }
.flip { perspective: 1000px; height: 200px; cursor: pointer; }
.flip-inner {
  position: relative;
  width: 100%; height: 100%;
  transition: transform 0.7s cubic-bezier(0.4, 0.2, 0.2, 1);
  transform-style: preserve-3d;
}
.flip.flipped .flip-inner { transform: rotateY(180deg); }
@media (hover: hover) { .flip:hover .flip-inner { transform: rotateY(180deg); } }
.flip-face {
  position: absolute;
  inset: 0;
  border-radius: var(--radius);
  padding: 24px;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  border: 1px solid var(--border);
  background: linear-gradient(160deg, rgba(255, 107, 157, 0.18), rgba(255, 255, 255, 0.05));
}
.flip-front .emoji { font-size: 48px; margin-bottom: 14px; display: inline-block; animation: float 4s ease-in-out infinite; }
.flip-front h4 { font-size: 18px; color: #fff; font-weight: 600; }
.flip-back {
  transform: rotateY(180deg);
  background: linear-gradient(160deg, rgba(255, 211, 110, 0.2), rgba(255, 107, 157, 0.15));
  color: var(--cream);
  font-size: 15px;
  line-height: 1.7;
}

/* ---------- 互动 ---------- */
.play-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; margin-bottom: 28px; }
.panel {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 36px 32px;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  text-align: center;
  position: relative;
  overflow: hidden;
}
.panel h3 { font-family: var(--font-serif); font-size: 24px; color: #fff; margin-bottom: 8px; }
.panel > p { color: var(--muted); font-size: 14px; margin-bottom: 24px; }

.heart-btn {
  width: 120px; height: 120px;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  background: radial-gradient(circle at 30% 30%, #ff8fb1, #ff4d7d 60%, #c2185b);
  color: #fff;
  font-size: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 30px rgba(255, 77, 125, 0.45);
  transition: transform 0.15s;
  animation: pulseRing 2s infinite;
}
.heart-btn:hover { transform: scale(1.06); }
.heart-btn:active { transform: scale(0.9); }
.heart-btn span { display: inline-block; animation: beat 1.2s ease-in-out infinite; }
.heart-count { font-size: 18px; margin-top: 20px; color: #fff; }
.heart-count span {
  font-family: var(--font-serif);
  font-size: 28px;
  color: var(--gold);
  display: inline-block;
}
.heart-count span.tick { animation: pop 0.45s ease; }
.heart-msg { margin-top: 6px; color: var(--pink-soft); min-height: 1.6em; font-size: 14px; }
.float-heart {
  position: absolute;
  pointer-events: none;
  font-size: 22px;
  z-index: 5;
  animation: floatUp 1.4s ease-out forwards;
}

.fortune-cards { display: flex; justify-content: center; gap: 14px; flex-wrap: wrap; margin-bottom: 22px; }
.fortune { width: 96px; height: 140px; perspective: 800px; cursor: pointer; }
.fortune-inner {
  position: relative;
  width: 100%; height: 100%;
  transition: transform 0.6s cubic-bezier(0.4, 0.2, 0.2, 1);
  transform-style: preserve-3d;
}
.fortune.flipped .fortune-inner { transform: rotateY(180deg); }
.fortune:not(.flipped):hover .fortune-inner { transform: rotateY(14deg) translateY(-6px); }
.fortune-face {
  position: absolute;
  inset: 0;
  border-radius: 12px;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 10px;
}
.fortune-front {
  background: linear-gradient(145deg, #3a1650, #1f0a2a);
  border: 1px solid rgba(255, 211, 110, 0.4);
  color: var(--gold);
  font-size: 40px;
  font-family: var(--font-serif);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}
.fortune-front::before {
  content: '';
  position: absolute;
  inset: 6px;
  border: 1px dashed rgba(255, 211, 110, 0.35);
  border-radius: 8px;
}
.fortune-back {
  transform: rotateY(180deg);
  background: linear-gradient(145deg, #fff4f7, #ffe3ec);
  color: #8a2a4a;
  font-size: 13px;
  line-height: 1.5;
  font-family: var(--font-hand);
  padding: 12px 8px;
}
.ghost-btn {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--pink-soft);
  padding: 8px 20px;
  border-radius: 999px;
  cursor: pointer;
  font-size: 13px;
  transition: all 0.3s;
}
.ghost-btn:hover { background: rgba(255, 107, 157, 0.15); border-color: var(--pink); }

.quiz-panel { text-align: left; }
.quiz-progress { display: flex; gap: 6px; margin: 16px 0 24px; }
.quiz-progress i { flex: 1; height: 4px; border-radius: 2px; background: rgba(255, 255, 255, 0.12); transition: background 0.4s; }
.quiz-progress i.done { background: var(--pink); }
.quiz-q { font-size: 20px; color: #fff; margin-bottom: 20px; font-family: var(--font-serif); }
.quiz-opts { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.quiz-opt {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 16px 18px;
  color: var(--cream);
  cursor: pointer;
  text-align: left;
  font-size: 15px;
  font-family: inherit;
  transition: all 0.25s;
}
.quiz-opt:hover { background: rgba(255, 107, 157, 0.15); transform: translateY(-2px); }
.quiz-opt.correct { background: rgba(80, 220, 140, 0.2); border-color: #50dc8c; color: #c9ffe0; }
.quiz-opt.wrong { background: rgba(255, 80, 100, 0.2); border-color: #ff5064; color: #ffd0d6; animation: shake 0.4s; }
.quiz-result { text-align: center; padding: 20px 0; }
.quiz-result .score {
  font-size: 64px;
  font-family: var(--font-serif);
  font-weight: 700;
  background: linear-gradient(135deg, var(--pink), var(--gold));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.quiz-result p { color: var(--muted); margin: 10px 0 24px; }
.primary-btn {
  background: linear-gradient(135deg, var(--pink), #ff4d7d);
  border: none;
  color: #fff;
  padding: 12px 32px;
  border-radius: 999px;
  font-size: 15px;
  cursor: pointer;
  box-shadow: 0 10px 25px rgba(255, 77, 125, 0.35);
  transition: all 0.3s;
}
.primary-btn:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(255, 77, 125, 0.5); }

/* ---------- 页脚 ---------- */
.footer {
  text-align: center;
  padding: 80px 24px 60px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}
.footer-heart { font-size: 36px; color: var(--pink); display: inline-block; animation: beat 1.4s ease-in-out infinite; margin-bottom: 16px; }
.footer-line { font-size: 16px; color: var(--cream); }
.footer-line b { color: var(--gold); font-family: var(--font-serif); font-size: 22px; }
.footer-small { color: var(--muted); margin-top: 10px; font-size: 14px; }
.footer-copy { margin-top: 30px; font-size: 12px; color: rgba(255, 255, 255, 0.35); }

/* ---------- 动画 ---------- */
@keyframes fadeUp { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: translateY(0); } }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-12px); } }
@keyframes beat { 0%, 100% { transform: scale(1); } 25% { transform: scale(1.15); } 40% { transform: scale(1); } 60% { transform: scale(1.12); } }
@keyframes blink { 0%, 49% { opacity: 1; } 50%, 100% { opacity: 0; } }
@keyframes pop { 0% { transform: scale(1); } 50% { transform: scale(1.25); color: var(--gold); } 100% { transform: scale(1); } }
@keyframes wheel { 0% { opacity: 1; transform: translateY(0); } 100% { opacity: 0; transform: translateY(12px); } }
@keyframes pulseRing {
  0% { box-shadow: 0 10px 30px rgba(255, 77, 125, 0.45), 0 0 0 0 rgba(255, 77, 125, 0.5); }
  70% { box-shadow: 0 10px 30px rgba(255, 77, 125, 0.45), 0 0 0 24px rgba(255, 77, 125, 0); }
  100% { box-shadow: 0 10px 30px rgba(255, 77, 125, 0.45), 0 0 0 0 rgba(255, 77, 125, 0); }
}
@keyframes floatUp {
  0% { opacity: 1; transform: translate(0, 0) scale(0.6); }
  100% { opacity: 0; transform: translate(var(--dx, 0), -220px) scale(1.4) rotate(var(--dr, 0)); }
}
@keyframes shake { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }

/* ---------- 响应式 ---------- */
@media (max-width: 860px) {
  .nav { padding: 8px 12px 8px 16px; }
  .nav-links { display: none; }
  .nav-bpm { display: none; }
  .section { padding: 80px 18px; }
  .play-grid { grid-template-columns: 1fr; }
  .quiz-opts { grid-template-columns: 1fr; }
  .panel { padding: 28px 20px; }
  .timeline-line { left: 18px; }
  .timeline-item, .timeline-item.right { width: 100%; margin-left: 0; padding: 0 0 48px 52px; }
  .timeline-item .timeline-dot, .timeline-item.right .timeline-dot { left: 7px; right: auto; }
  .letter-paper { padding: 40px 28px 32px; font-size: 16px; }
  .section-title span::before { left: -8px; }
  .section-title span::after { right: -8px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  .reveal, .hero-title, .eyebrow, .typeline, .counter, .next-anniv, .scroll-hint { opacity: 1 !important; transform: none !important; }
}

/* ==========================================================
   合并部分：星空首屏（原「星空页」）
   ========================================================== */

#mainContent { opacity: 0; transition: opacity 1s ease; }
#mainContent.revealed { opacity: 1; }
body.locked { overflow: hidden; }

/* ---------- 解锁遮罩 ---------- */
.unlock-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 18px;
  background:
    radial-gradient(circle 460px at 50% 32%, rgba(255, 226, 236, 0.92), rgba(255, 246, 242, 0.98) 70%),
    #fff8f4;
  transition: opacity 0.9s ease, visibility 0.9s;
}
.unlock-overlay.is-hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.unlock-inner {
  position: relative;
  z-index: 1;
  text-align: center;
  width: min(560px, 90vw);
  max-width: 560px;
  padding: 52px 48px 54px;
  border: 1px solid rgba(255, 150, 190, 0.42);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(74, 26, 68, 0.42), rgba(24, 10, 30, 0.55));
  box-shadow: 0 0 60px rgba(255, 107, 157, 0.14), inset 0 0 44px rgba(255, 107, 157, 0.06);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.envelope-frame {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}
.envelope-flap { fill: none; stroke: rgba(255, 150, 190, 0.42); stroke-width: 1; vector-effect: non-scaling-stroke; }
.envelope-flap-fill { fill: rgba(255, 180, 210, 0.05); stroke: none; }
@media (max-width: 480px) {
  .unlock-inner { padding: 40px 22px 42px; }
}
@media (max-height: 640px) {
  .unlock-inner { padding: 30px 30px 32px; }
  .unlock-heart { width: 108px; height: 108px; font-size: 44px; margin-bottom: 18px; }
  .unlock-sub { margin-bottom: 26px; }
}
.unlock-heart {
  width: clamp(84px, 11vw, 116px);
  height: clamp(84px, 11vw, 116px);
  margin: 0 auto 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: clamp(38px, 5vw, 50px);
  color: #fff;
  background: linear-gradient(145deg, #ff9dbb, #f2668b 55%, #e2517c);
  border: none;
  box-shadow:
    0 16px 34px rgba(232, 106, 148, 0.4),
    0 0 0 9px rgba(255, 183, 205, 0.22),
    0 0 0 19px rgba(255, 183, 205, 0.12);
  animation: beat 2.2s ease-in-out infinite;
}
.unlock-title {
  font-family: var(--font-serif);
  font-size: clamp(21px, 3.1vw, 31px);
  font-weight: 400;
  letter-spacing: 0.14em;
  color: #5c3346;
  margin: 4px 0 10px;
}
.unlock-sub { font-size: clamp(12px, 1.5vw, 13.5px); letter-spacing: 0.12em; color: #a3728a; margin: 0; }
.unlock-script {
  font-family: "Parisienne", "Segoe Script", "Brush Script MT", cursive;
  font-size: clamp(18px, 2.4vw, 23px);
  font-weight: 400;
  letter-spacing: 0.04em;
  color: #d99a5b;
  margin: 2px 0 4px;
}
.hold-wrap {
  position: absolute;
  left: 50%;
  top: 76%;
  transform: translate(-50%, -50%);
  width: 124px; height: 124px;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 6;
  transition: transform 0.7s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.7s ease;
}
.hold-ring { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); overflow: visible; }
.ring-bg { fill: none; stroke: rgba(232, 150, 180, 0.35); stroke-width: 4; }
.ring-fg {
  fill: none;
  stroke: #e2517c;
  stroke-width: 6;
  stroke-linecap: round;
  filter: drop-shadow(0 0 8px rgba(242, 102, 139, 0.55));
  transition: stroke-dashoffset 0.06s linear;
}
.hold-btn {
  position: relative;
  z-index: 2;
  width: 94px; height: 94px;
  border: none;
  border-radius: 47% 53% 50% 50% / 52% 47% 53% 48%;
  background: radial-gradient(circle at 36% 28%, #ffa7c2 0%, #f2668b 48%, #cf3f6c 100%);
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
  touch-action: none;
  box-shadow:
    0 16px 32px rgba(206, 74, 118, 0.45),
    inset 0 -7px 14px rgba(150, 30, 74, 0.32),
    inset 0 5px 12px rgba(255, 255, 255, 0.32);
  transition: transform 0.22s ease, box-shadow 0.32s ease;
}
.hold-btn::after {
  content: "";
  position: absolute;
  inset: 8px;
  border: 1.5px dashed rgba(255, 255, 255, 0.45);
  border-radius: inherit;
  pointer-events: none;
}
.hold-btn:hover { transform: scale(1.05); box-shadow: 0 20px 40px rgba(206, 74, 118, 0.55), inset 0 -7px 14px rgba(150, 30, 74, 0.3); }
.hold-btn:active { transform: scale(0.95); }
.hold-icon { font-size: 25px; line-height: 1; }
.hold-text { font-size: 10px; letter-spacing: 0.16em; opacity: 0.95; }

/* ---------- 星空世界 ---------- */
.sky-world {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(55% 40% at 50% 0%, rgba(138, 35, 135, 0.32), transparent 68%),
    radial-gradient(45% 32% at 82% 26%, rgba(255, 117, 140, 0.14), transparent 70%),
    radial-gradient(50% 35% at 10% 55%, rgba(90, 45, 160, 0.18), transparent 70%),
    linear-gradient(180deg, #05060a 0%, #0b0c10 62%, rgba(18, 8, 24, 0.94) 90%, rgba(20, 9, 28, 0) 100%);
}
#sky-stars {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}
.sky-hero, .sky-section { position: relative; z-index: 1; }

.sky-hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 130px 24px 100px;
}
.sky-hero-inner { width: 100%; max-width: 860px; }
.sky-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  border-radius: 999px;
  font-size: 12px;
  letter-spacing: 0.12em;
  color: #fecdd3;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 117, 140, 0.22);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  margin-bottom: 26px;
}
.sky-badge .spark { color: var(--pink); animation: blink 2.4s steps(1) infinite; }
.sky-title {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.28em;
  flex-wrap: wrap;
  font-family: var(--font-serif);
  font-size: clamp(40px, 8vw, 78px);
  font-weight: 300;
  letter-spacing: 0.04em;
  line-height: 1.15;
  margin-bottom: 20px;
}
.sky-title [data-name-a],
.sky-title [data-name-b] {
  background: linear-gradient(90deg, #fecdd3, #f9a8d4 55%, #e9d5ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.sky-heart {
  font-size: 0.42em;
  color: var(--rose);
  animation: beat 1.8s ease-in-out infinite;
}
.sky-quote {
  max-width: 30em;
  margin: 0 auto 14px;
  font-size: 15px;
  line-height: 1.9;
  font-weight: 300;
  color: #94a3b8;
}
.sky-typed {
  min-height: 1.9em;
  margin-bottom: 36px;
  font-size: clamp(15px, 1.8vw, 19px);
  letter-spacing: 0.06em;
  color: var(--cream);
}

/* 计时器 */
.sky-timer {
  position: relative;
  overflow: hidden;
  width: 100%;
  max-width: 820px;
  margin: 0 auto 40px;
  padding: 26px 22px 22px;
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 117, 140, 0.22);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.4);
}
.sky-timer::before,
.sky-timer::after {
  content: '';
  position: absolute;
  width: 190px; height: 190px;
  border-radius: 50%;
  filter: blur(60px);
  pointer-events: none;
}
.sky-timer::before { top: -90px; left: -70px; background: rgba(255, 77, 125, 0.22); }
.sky-timer::after { bottom: -90px; right: -70px; background: rgba(138, 77, 255, 0.2); }
.sky-timer-title {
  position: relative;
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.28em;
  color: #94a3b8;
  margin-bottom: 22px;
}
.sky-timer-grid {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.sky-cell {
  padding: 14px 6px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
}
.sky-cell .num {
  display: block;
  font-size: clamp(26px, 4vw, 44px);
  font-weight: 200;
  line-height: 1.15;
  color: #fbcfe8;
  font-variant-numeric: tabular-nums;
  font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
}
.sky-cell .num.tick { animation: pop 0.45s ease; }
.sky-cell .label { display: block; margin-top: 6px; font-size: 11px; letter-spacing: 0.1em; color: #94a3b8; }
.sky-timer .next-anniv { position: relative; margin-top: 20px; font-size: 13px; color: #94a3b8; }

/* 按钮 */
.sky-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; }
.sky-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 26px;
  border: none;
  border-radius: 999px;
  font-size: 14px;
  font-family: inherit;
  color: #fff;
  cursor: pointer;
  background: linear-gradient(135deg, #ff4d7d, #ff758c);
  box-shadow: 0 10px 30px rgba(255, 77, 125, 0.35);
  transition: transform 0.25s, box-shadow 0.3s;
}
.sky-btn:hover { transform: translateY(-2px) scale(1.02); box-shadow: 0 14px 36px rgba(255, 77, 125, 0.5); }
.sky-btn:active { transform: scale(0.96); }
.sky-btn.ghost {
  color: #fecdd3;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: none;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.sky-btn.ghost:hover { background: rgba(255, 255, 255, 0.08); border-color: rgba(255, 117, 140, 0.5); }

/* ---------- 故事轨迹（星空卡片 + 时光机样式） ---------- */
.sky-section { max-width: 900px; margin: 0 auto; padding: 30px 24px 100px; }

.sky-flip { perspective: 1200px; }
.sky-flip-inner {
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
  cursor: pointer;
}
.sky-flip.flipped .sky-flip-inner { transform: rotateY(180deg); }
.sky-front.timeline-card { backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.sky-face-back {
  position: absolute;
  inset: 0;
  transform: rotateY(180deg);
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 20px 24px;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 107, 157, 0.4);
  background: linear-gradient(160deg, rgba(72, 20, 46, 0.96), rgba(30, 12, 38, 0.96));
  box-shadow: 0 20px 50px rgba(255, 107, 157, 0.18);
  overflow: hidden;
}
.sky-flip-tip { margin-top: 12px; font-size: 10px; letter-spacing: 0.08em; color: var(--muted); text-align: right; }
.sky-emoji { font-size: 24px; margin-bottom: 8px; }
.sky-secret { font-size: 12px; line-height: 1.8; font-weight: 300; color: #ffe4ea; }

/* 刮刮乐 */
.sky-scratch-card .timeline-date { margin-bottom: 10px; }
.sky-scratch-card h3 { margin-bottom: 12px; }
.sky-scratch {
  position: relative;
  height: 128px;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: linear-gradient(135deg, rgba(74, 14, 48, 0.45), rgba(59, 7, 100, 0.45));
  display: flex;
  align-items: center;
  justify-content: center;
}
.sky-scratch p { padding: 0 18px; text-align: center; font-size: 13px; line-height: 1.8; color: #fbcfe8; }
#scratchCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  cursor: crosshair;
  touch-action: none;
}

@media (max-width: 560px) {
  .sky-hero { padding-top: 110px; }
  .sky-timer-grid { grid-template-columns: repeat(2, 1fr); }
  .sky-actions .sky-btn { width: 100%; justify-content: center; }
}

/* ---------- 情话胶囊 ---------- */
.capsule-modal {
  position: fixed;
  inset: 0;
  z-index: 150;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(2, 2, 6, 0.82);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.capsule-modal.is-open { opacity: 1; pointer-events: auto; }
.capsule-card {
  width: 100%;
  max-width: 380px;
  padding: 32px 28px;
  border-radius: 26px;
  text-align: center;
  background: rgba(18, 9, 24, 0.92);
  border: 1px solid rgba(255, 117, 140, 0.3);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
  transform: scale(0.94);
  transition: transform 0.3s ease;
}
.capsule-modal.is-open .capsule-card { transform: scale(1); }
.capsule-icon {
  width: 60px; height: 60px;
  margin: 0 auto 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  color: #fff;
  background: linear-gradient(135deg, #ff4d7d, #a855f7);
  animation: float 3s ease-in-out infinite;
}
.capsule-card h3 {
  font-family: var(--font-serif);
  font-size: 19px;
  font-weight: 500;
  color: #fecdd3;
  margin-bottom: 12px;
}
#capsuleText {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 4.5em;
  font-size: 14px;
  line-height: 1.9;
  color: #e2e8f0;
}
.capsule-close {
  margin-top: 22px;
  padding: 10px 24px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.06);
  color: #f1f5f9;
  font-size: 13px;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.25s;
}
.capsule-close:hover { background: rgba(255, 255, 255, 0.14); }

/* 星空区之后的情书区留白 */
#letter { padding-top: 70px; }

/* ---------- 回到顶部 ---------- */
.to-top {
  position: fixed;
  right: 22px;
  bottom: 26px;
  z-index: 60;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid rgba(255, 107, 157, 0.35);
  background: rgba(20, 9, 28, 0.72);
  color: var(--pink-soft);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.4);
  opacity: 0;
  transform: translateY(14px);
  pointer-events: none;
  transition: opacity 0.3s, transform 0.3s, background 0.3s, border-color 0.3s, color 0.3s;
}
.to-top.show { opacity: 1; transform: none; pointer-events: auto; }
.to-top:hover {
  background: rgba(255, 107, 157, 0.3);
  border-color: rgba(255, 107, 157, 0.7);
  color: #fff;
}
@media (max-width: 860px) {
  .to-top { right: 16px; bottom: 18px; width: 42px; height: 42px; }
}

/* ---------- 定制面板 ---------- */
.custom-backdrop {
  position: fixed;
  inset: 0;
  z-index: 155;
  background: rgba(4, 2, 8, 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.custom-backdrop.show { opacity: 1; pointer-events: auto; }
.custom-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 160;
  width: 400px;
  max-width: 92vw;
  display: flex;
  flex-direction: column;
  background: rgba(16, 9, 22, 0.97);
  border-left: 1px solid rgba(255, 107, 157, 0.22);
  box-shadow: -20px 0 60px rgba(0, 0, 0, 0.55);
  transform: translateX(105%);
  transition: transform 0.38s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.custom-drawer.open { transform: translateX(0); }
.custom-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 22px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.custom-head h3 {
  font-family: var(--font-serif);
  font-size: 19px;
  font-weight: 500;
  letter-spacing: 0.06em;
  color: #fff;
}
.custom-close {
  background: none;
  border: none;
  color: var(--muted);
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  transition: transform 0.25s, color 0.25s;
}
.custom-close:hover { color: #fff; transform: rotate(90deg); }
.custom-body { flex: 1; overflow-y: auto; padding: 18px 22px 24px; }
.custom-group {
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.custom-group > summary {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 0;
  list-style: none;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  line-height: 1.6;
  color: var(--pink-soft);
  word-break: break-word;
}
.custom-group > summary::-webkit-details-marker { display: none; }
.custom-group > summary::after {
  content: '▾';
  flex: 0 0 auto;
  font-size: 10px;
  color: var(--muted);
  transition: transform 0.25s;
}
.custom-group[open] > summary::after { transform: rotate(180deg); }
.custom-group > .custom-field { margin-top: 6px; }
.custom-group .custom-group {
  margin: 8px 0;
  padding-bottom: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}
.custom-group .custom-group > summary {
  font-weight: 500;
  letter-spacing: 0.04em;
  color: #f3d6e2;
}
.custom-field { display: block; margin-bottom: 14px; }
.custom-field > span { display: block; font-size: 12px; color: var(--muted); margin-bottom: 6px; }
.custom-field input,
.custom-field textarea,
.custom-field select {
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  font-size: 13px;
  font-family: inherit;
  line-height: 1.6;
  outline: none;
  transition: border-color 0.25s, background 0.25s;
}
.custom-field textarea { min-height: 84px; resize: vertical; }
.custom-field input:focus,
.custom-field textarea:focus,
.custom-field select:focus {
  border-color: rgba(255, 107, 157, 0.6);
  background: rgba(255, 107, 157, 0.08);
}
.custom-field input[type="datetime-local"],
.custom-field input[type="number"],
.custom-field select { color-scheme: dark; }

/* 照片上传 */
.custom-upload { margin-top: 4px; }
.custom-upload-row { display: flex; gap: 12px; align-items: center; }
.custom-upload-preview {
  flex: 0 0 auto;
  width: 76px;
  height: 58px;
  border-radius: 8px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
}
.custom-upload-preview img { width: 100%; height: 100%; object-fit: cover; display: block; }
.custom-upload-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.custom-upload-btn {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 14px;
  border-radius: 999px;
  border: none;
  font-size: 12px;
  font-family: inherit;
  color: #fff;
  background: linear-gradient(135deg, #ff4d7d, #ff758c);
  cursor: pointer;
  transition: transform 0.2s, opacity 0.2s;
}
.custom-upload-btn:hover { transform: translateY(-1px); }
.custom-upload-btn input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}
.custom-upload-btn.ghost {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: var(--pink-soft);
}
.custom-upload-btn.ghost:disabled { opacity: 0.35; cursor: not-allowed; }
.custom-upload-hint { flex-basis: 100%; margin: 0; font-size: 11px; color: var(--muted); }

/* ---------- 相册：3D 立体方块 ---------- */
.photo-cube-stage {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  height: clamp(340px, 56vw, 580px);
  perspective: 1200px;
  perspective-origin: 50% 50%;
  touch-action: pan-y;
  cursor: default;
  user-select: none;
  -webkit-user-select: none;
}
.photo-cube-stage.assembled { cursor: grab; }
.photo-cube-stage.dragging { cursor: grabbing; }
.photo-cube-spin {
  transform-style: preserve-3d;
  will-change: transform;
}
.photo-cube {
  --cube-size: clamp(170px, 32vw, 268px);
  --half: calc(var(--cube-size) / 2);
  position: relative;
  width: var(--cube-size);
  height: var(--cube-size);
  transform-style: preserve-3d;
  transition: transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.photo-cube-stage.assembled:hover .photo-cube {
  --spread: 1.8;
  transform: scale(1.06);
}
.pc-face {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  transition: transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1);
}
/* 从两行三列收拢成立方体时的过渡 */
.photo-cube.assemble .pc-face {
  transition: transform 1.15s cubic-bezier(0.2, 0.8, 0.2, 1) var(--fd, 0s);
}
/* 摆位阶段关闭过渡，避免先看到方块再散开 */
.photo-cube.prep .pc-face { transition: none; }
.pc-face:nth-child(1) { transform: translateZ(calc(var(--half) * var(--spread, 1))); }
.pc-face:nth-child(2) { transform: rotateY(180deg) translateZ(calc(var(--half) * var(--spread, 1))); }
.pc-face:nth-child(3) { transform: rotateX(90deg) translateZ(calc(var(--half) * var(--spread, 1))); }
.pc-face:nth-child(4) { transform: rotateX(-90deg) translateZ(calc(var(--half) * var(--spread, 1))); }
.pc-face:nth-child(5) { transform: rotateY(-90deg) translateZ(calc(var(--half) * var(--spread, 1))); }
.pc-face:nth-child(6) { transform: rotateY(90deg) translateZ(calc(var(--half) * var(--spread, 1))); }

.pc-photo {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  border: 1px solid rgba(255, 107, 157, 0.55);
  box-shadow: 0 0 26px rgba(255, 107, 157, 0.18), inset 0 0 50px rgba(10, 4, 14, 0.35);
  opacity: 0;
  transform: scale(0.5);
  transition: opacity 0.8s ease var(--d, 0s), transform 0.9s cubic-bezier(0.2, 0.8, 0.2, 1) var(--d, 0s);
}
.photo-cube-stage.show .pc-photo { opacity: 1; transform: none; }
/* 合成后外层稍微透明，露出内部的小方块；悬停时恢复清晰 */
.photo-cube-stage.assembled .pc-photo {
  opacity: 0.7;
  transition: opacity 0.35s ease, transform 0.9s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.photo-cube-stage.assembled:hover .pc-photo { opacity: 0.95; }

/* 内层小方块 */
.pc-inner {
  position: absolute;
  left: 50%;
  top: 50%;
  width: calc(var(--cube-size) * 0.46);
  height: calc(var(--cube-size) * 0.46);
  margin-left: calc(var(--cube-size) * -0.23);
  margin-top: calc(var(--cube-size) * -0.23);
  transform-style: preserve-3d;
  animation: pcInnerSpin 12s linear infinite;
  opacity: 0;
  transition: opacity 0.7s ease;
  pointer-events: none;
}
.photo-cube-stage.assembled .pc-inner { opacity: 1; }
@keyframes pcInnerSpin {
  from { transform: rotateX(0deg) rotateZ(0deg); }
  to { transform: rotateX(360deg) rotateZ(360deg); }
}
.pc-inner-face {
  --isz: calc(var(--cube-size) * 0.23);
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  border: 1px solid rgba(255, 107, 157, 0.5);
  box-shadow: 0 0 14px rgba(255, 107, 157, 0.25);
}
.pc-inner-face:nth-child(1) { transform: translateZ(var(--isz)); }
.pc-inner-face:nth-child(2) { transform: rotateY(180deg) translateZ(var(--isz)); }
.pc-inner-face:nth-child(3) { transform: rotateX(90deg) translateZ(var(--isz)); }
.pc-inner-face:nth-child(4) { transform: rotateX(-90deg) translateZ(var(--isz)); }
.pc-inner-face:nth-child(5) { transform: rotateY(-90deg) translateZ(var(--isz)); }
.pc-inner-face:nth-child(6) { transform: rotateY(90deg) translateZ(var(--isz)); }
.pc-photo::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(10, 4, 14, 0.72));
  pointer-events: none;
}
.pc-emoji {
  font-size: clamp(26px, 6vw, 44px);
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.3));
}
.pc-caption {
  position: absolute;
  left: 8px;
  right: 8px;
  bottom: 8px;
  z-index: 2;
  font-size: 11px;
  letter-spacing: 0.06em;
  color: #ffe6ee;
  text-align: center;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.65);
}
.custom-foot {
  display: flex;
  gap: 12px;
  padding: 16px 22px 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}
.custom-btn {
  flex: 1;
  padding: 11px 18px;
  border: none;
  border-radius: 999px;
  font-size: 14px;
  font-family: inherit;
  color: #fff;
  cursor: pointer;
  background: linear-gradient(135deg, #ff4d7d, #ff758c);
  box-shadow: 0 10px 24px rgba(255, 77, 125, 0.35);
  transition: transform 0.2s, box-shadow 0.3s;
}
.custom-btn:hover { transform: translateY(-1px); }
.custom-btn.ghost {
  flex: 0 0 auto;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: var(--pink-soft);
  box-shadow: none;
}

/* ==========================================================
   甜蜜回忆 · 奶油粉主题
   ========================================================== */
:root {
  --bg-1: #fffaf7;
  --bg-2: #fff3f6;
  --bg-3: #ffe8f0;
  --pink: #f2668b;
  --pink-soft: #e2517c;
  --rose: #dd4a76;
  --gold: #d99a5b;
  --text: #5c3346;
  --muted: #a3728a;
  --card: rgba(255, 255, 255, 0.78);
  --border: rgba(255, 176, 200, 0.5);
  --font-serif: "Noto Serif SC", "Songti SC", "STSong", "SimSun", "Microsoft YaHei", "ZCOOL XiaoWei", serif;
  --font-body: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
}

body {
  color: var(--text);
  background:
    radial-gradient(ellipse 70% 55% at 12% 8%, #ffe2ec 0%, transparent 60%),
    radial-gradient(ellipse 60% 50% at 88% 18%, #ffe7d6 0%, transparent 55%),
    radial-gradient(ellipse 90% 60% at 50% 105%, #ffdbe8 0%, transparent 65%),
    #fff8f4;
  background-attachment: fixed;
}
#bg-canvas, #sky-stars, .cursor-glow { display: none; }
::selection { background: rgba(242, 102, 139, 0.25); color: var(--text); }
::-webkit-scrollbar-track { background: #fff2f5; }
::-webkit-scrollbar-thumb { background: rgba(242, 102, 139, 0.35); }
::-webkit-scrollbar-thumb:hover { background: rgba(242, 102, 139, 0.55); }

/* 信封（开场） */
.env-scene { position: relative; width: min(860px, 94vw); perspective: 1600px; }
.env-halo {
  position: absolute;
  top: -60px; left: 50%;
  width: 420px; height: 420px;
  transform: translateX(-50%);
  background: radial-gradient(circle, rgba(255, 168, 198, 0.38), transparent 66%);
  filter: blur(12px);
  pointer-events: none;
  z-index: 0;
}
.envelope {
  position: relative;
  width: 100%;
  height: clamp(430px, 62vh, 545px);
  transform-style: preserve-3d;
}
.env-back {
  position: absolute;
  inset: 0;
  border-radius: 24px;
  background:
    radial-gradient(ellipse at 22% 12%, rgba(255, 255, 255, 0.9), transparent 55%),
    linear-gradient(158deg, #fff5f8 0%, #ffe7ef 52%, #ffdbe7 100%);
  border: 1px solid rgba(238, 156, 184, 0.5);
  box-shadow:
    0 46px 90px rgba(206, 118, 152, 0.26),
    0 12px 28px rgba(206, 118, 152, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.85);
  z-index: 1;
  overflow: hidden;
}
.env-back::after {
  content: "";
  position: absolute;
  inset: 12px;
  border-radius: 16px;
  border: 1px dashed rgba(232, 140, 172, 0.28);
  pointer-events: none;
}
.env-back::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(226, 120, 156, 0.16) 1px, transparent 1px);
  background-size: 22px 22px;
  opacity: 0.5;
}
.env-flap {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 68%;
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  background: linear-gradient(178deg, rgba(255, 255, 255, 0.78) 0%, rgba(255, 219, 231, 0.72) 62%, rgba(255, 199, 216, 0.8) 100%);
  filter: drop-shadow(0 12px 18px rgba(206, 118, 152, 0.22));
  transform-origin: top center;
  transition: transform 0.8s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.8s ease;
  z-index: 2;
}
.env-flap::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent 38%, rgba(255, 255, 255, 0.55) 50%, transparent 62%);
}
.env-pocket {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 38%;
  clip-path: polygon(0 18%, 50% 0, 100% 18%, 100% 100%, 0 100%);
  background: linear-gradient(180deg, #ffe4ed 0%, #ffd2e0 60%, #ffc6d8 100%);
  filter: drop-shadow(0 -8px 16px rgba(206, 118, 152, 0.18));
  z-index: 3;
}
.env-pocket::after {
  content: "";
  position: absolute;
  inset: 0;
  clip-path: polygon(0 18%, 50% 0, 100% 18%, 100% 22%, 50% 5%, 0 22%);
  background: rgba(255, 255, 255, 0.5);
}
.env-body {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 33%;
  z-index: 4;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 6% 14% 2%;
  text-align: center;
  transition: transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}
.unlock-overlay.is-hidden .env-flap { transform: rotateX(-26deg) translateY(-14px); opacity: 0.55; }
.unlock-overlay.is-hidden .env-body { transform: translateY(-34px); }
.unlock-overlay.is-hidden .hold-wrap { transform: translate(-50%, -50%) scale(0.82); opacity: 0; }
@media (max-width: 560px) {
  .envelope { height: clamp(400px, 74vh, 520px); }
  .env-body { padding: 10% 9% 2%; }
  .hold-wrap { width: 112px; height: 112px; }
  .hold-btn { width: 86px; height: 86px; }
}
@media (max-height: 640px) {
  .envelope { height: 430px; }
}

/* 导航 */
.nav {
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 176, 200, 0.55);
  box-shadow: 0 18px 40px rgba(224, 116, 152, 0.18);
}
.nav-brand { color: var(--gold); }
.brand-text {
  font-family: "Parisienne", "Segoe Script", "Brush Script MT", cursive;
  font-size: 22px;
  font-weight: 400;
  letter-spacing: 0.01em;
  text-transform: capitalize;
  line-height: 1.1;
}
.nav-links a { color: var(--muted); }
.nav-links a:hover, .nav-links a.active { color: var(--rose); background: rgba(242, 102, 139, 0.12); }
.icon-btn {
  border: 1px solid rgba(242, 102, 139, 0.28);
  background: rgba(255, 255, 255, 0.62);
  color: var(--rose);
}
.icon-btn:hover { background: #fff0f5; }
.icon-btn.active { color: #fff; background: var(--rose); border-color: var(--rose); }
.nav-bpm {
  background: rgba(255, 255, 255, 0.68);
  border: 1px solid rgba(242, 102, 139, 0.25);
  color: var(--rose);
}
.nav-bpm #bpmDisplay, #bpmDisplay { color: var(--rose); }
.brand-dot { background: #5fc98f; }

/* 首屏 */
.sky-world {
  background: transparent;
}
.sky-badge {
  color: var(--rose);
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(242, 102, 139, 0.25);
}
.sky-title [data-name-a],
.sky-title [data-name-b] {
  background: linear-gradient(90deg, #f58aab, #e2517c 55%, #d99a5b);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.sky-quote { color: var(--muted); }
.sky-typed { color: var(--text); }
.sky-timer {
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(255, 176, 200, 0.55);
  box-shadow: 0 24px 60px rgba(224, 116, 152, 0.18);
}
.sky-timer::before { background: rgba(255, 168, 198, 0.3); }
.sky-timer::after { background: rgba(255, 200, 175, 0.28); }
.sky-timer-title { color: var(--muted); }
.sky-cell {
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(255, 196, 214, 0.6);
}
.sky-cell .num { color: var(--rose); }
.sky-cell .label { color: var(--muted); }
.sky-timer .next-anniv { color: var(--muted); }
.sky-btn {
  background: linear-gradient(135deg, #f783a4, #e2517c);
  box-shadow: 0 10px 28px rgba(226, 81, 124, 0.28);
}
.sky-btn:hover { box-shadow: 0 14px 34px rgba(226, 81, 124, 0.4); }
.sky-btn.ghost {
  color: var(--rose);
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(242, 102, 139, 0.3);
}
.sky-btn.ghost:hover { background: #fff0f5; border-color: rgba(242, 102, 139, 0.55); }
.mouse { border-color: var(--rose); }
.mouse::after { background: var(--rose); }

/* 区块标题 */
.section-title { color: var(--text); }
.section-sub { color: var(--muted); }

/* 故事轨迹 */
.timeline-line { background: rgba(226, 140, 168, 0.25); }
.timeline-dot {
  background: #fff;
  border: 3px solid var(--rose);
  box-shadow: 0 0 0 6px rgba(242, 102, 139, 0.14);
}
.timeline-card {
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(255, 176, 200, 0.55);
  box-shadow: 0 18px 40px rgba(224, 116, 152, 0.12);
}
.timeline-card:hover {
  box-shadow: 0 24px 50px rgba(224, 116, 152, 0.2);
  border-color: rgba(242, 102, 139, 0.5);
}
.timeline-date { color: var(--rose); background: rgba(242, 102, 139, 0.1); }
.timeline-card h3 { color: var(--text); }
.timeline-card p { color: var(--muted); }
.sky-face-back {
  background: linear-gradient(160deg, #fff6fa, #ffe3ec);
  border: 1px solid rgba(242, 102, 139, 0.35);
  box-shadow: 0 20px 44px rgba(224, 116, 152, 0.16);
}
.sky-secret { color: #8a2a4a; }
.sky-scratch {
  background: linear-gradient(135deg, #fff2f6, #ffe6ef);
  border: 1px solid rgba(242, 102, 139, 0.25);
}
.sky-scratch p { color: #8a2a4a; }

/* 情书 */
.letter-paper {
  box-shadow: 0 30px 64px rgba(224, 116, 152, 0.22), inset 0 0 80px rgba(255, 200, 160, 0.25);
}
.letter-seal { box-shadow: 0 8px 20px rgba(194, 24, 91, 0.35); }

/* 相册 */
.pc-photo {
  border: 3px solid #fff;
  box-shadow: 0 16px 34px rgba(224, 116, 152, 0.22), inset 0 0 40px rgba(255, 220, 232, 0.2);
}
.pc-inner-face { border: 2px solid #fff; box-shadow: 0 8px 18px rgba(224, 116, 152, 0.22); }

/* 爱你的理由 */
.flip-face {
  background: linear-gradient(160deg, #ffffff, #ffeef4);
  border: 1px solid rgba(255, 176, 200, 0.6);
  box-shadow: 0 14px 30px rgba(224, 116, 152, 0.14);
}
.flip-front h4 { color: var(--text); }
.flip-back {
  background: linear-gradient(160deg, #ffe7ef, #ffd9e6);
  color: #7c3350;
  border-color: rgba(242, 102, 139, 0.35);
}

/* 互动 */
.panel {
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(255, 176, 200, 0.55);
  box-shadow: 0 18px 40px rgba(224, 116, 152, 0.12);
}
.panel h3 { color: var(--text); }
.panel > p { color: var(--muted); }
.heart-count { color: var(--text); }
.heart-msg { color: var(--rose); }
.fortune-front {
  background: linear-gradient(145deg, #ffe9f1, #ffd6e4);
  border: 1px solid rgba(226, 81, 124, 0.35);
  color: var(--rose);
  box-shadow: 0 8px 24px rgba(224, 116, 152, 0.18);
}
.fortune-front::before { border-color: rgba(226, 81, 124, 0.3); }
.fortune-back { background: #fff6f9; color: #8a2a4a; }
.ghost-btn {
  color: var(--rose);
  border: 1px solid rgba(242, 102, 139, 0.4);
  background: rgba(255, 255, 255, 0.6);
}
.ghost-btn:hover { background: rgba(242, 102, 139, 0.1); border-color: var(--rose); }
.quiz-progress i { background: rgba(226, 140, 168, 0.22); }
.quiz-progress i.done { background: var(--rose); }
.quiz-q { color: var(--text); }
.quiz-opt {
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(255, 176, 200, 0.5);
  color: var(--text);
}
.quiz-opt:hover { background: #fff2f7; }
.quiz-opt.correct { background: #e9fbf0; border-color: #4fc98a; color: #23794f; }
.quiz-opt.wrong { background: #ffeef0; border-color: #ef6a7e; color: #a42c40; }
.quiz-result p { color: var(--muted); }
.primary-btn, .custom-btn, .custom-upload-btn {
  background: linear-gradient(135deg, #f783a4, #e2517c);
  box-shadow: 0 10px 26px rgba(226, 81, 124, 0.3);
}

/* 页脚 */
.footer { border-top: 1px solid rgba(255, 176, 200, 0.45); }
.footer-line {
  color: var(--text);
  font-family: var(--font-hand);
  font-size: 19px;
  letter-spacing: 0.02em;
}
.footer-line b {
  font-family: "Parisienne", "Segoe Script", "Brush Script MT", cursive;
  font-weight: 400;
  font-size: 32px;
  line-height: 1;
  color: var(--rose);
  display: inline-block;
  margin: 0 0.1em;
  vertical-align: -3px;
}
.footer-small { color: var(--muted); font-family: var(--font-hand); font-size: 15px; }
.footer-copy { color: rgba(92, 51, 70, 0.45); }

/* 情话胶囊 */
.capsule-modal { background: rgba(255, 246, 242, 0.72); }
.capsule-card {
  background: #fffdfb;
  border: 1px solid rgba(255, 176, 200, 0.6);
  box-shadow: 0 30px 70px rgba(224, 116, 152, 0.26);
}
.capsule-card h3 { color: var(--rose); }
#capsuleText { color: var(--text); }
.capsule-close {
  border: 1px solid rgba(242, 102, 139, 0.35);
  background: #fff;
  color: var(--rose);
}

/* 回到顶部 */
.to-top {
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(242, 102, 139, 0.35);
  color: var(--rose);
  box-shadow: 0 10px 26px rgba(224, 116, 152, 0.22);
}
.to-top:hover { background: var(--rose); border-color: var(--rose); color: #fff; }

/* 定制面板 */
.custom-backdrop { background: rgba(92, 51, 70, 0.28); }
.custom-drawer {
  background: #fffdfb;
  border-left: 1px solid rgba(255, 176, 200, 0.5);
  box-shadow: -20px 0 60px rgba(224, 116, 152, 0.22);
}
.custom-head { border-bottom: 1px solid rgba(255, 176, 200, 0.4); }
.custom-head h3 { color: var(--text); }
.custom-close { color: var(--muted); }
.custom-close:hover { color: var(--rose); }
.custom-group { border-bottom: 1px solid rgba(255, 176, 200, 0.35); }
.custom-group > summary { color: var(--rose); }
.custom-group .custom-group { border-bottom: 1px solid rgba(255, 176, 200, 0.25); }
.custom-group .custom-group > summary { color: #8a5a6e; }
.custom-field > span { color: var(--muted); }
.custom-field input,
.custom-field textarea,
.custom-field select {
  background: #fff;
  border: 1px solid rgba(255, 176, 200, 0.55);
  color: var(--text);
}
.custom-field input:focus,
.custom-field textarea:focus,
.custom-field select:focus {
  border-color: rgba(242, 102, 139, 0.6);
  background: #fff5f8;
}
.custom-field input[type="datetime-local"],
.custom-field input[type="number"],
.custom-field select { color-scheme: light; }
.custom-upload-preview {
  background: #fff5f8;
  border: 1px solid rgba(255, 176, 200, 0.5);
}
.custom-upload-btn.ghost {
  background: #fff;
  border: 1px solid rgba(242, 102, 139, 0.35);
  color: var(--rose);
}
.custom-upload-hint { color: var(--muted); }
.custom-foot { border-top: 1px solid rgba(255, 176, 200, 0.4); }
.custom-btn.ghost {
  background: #fff;
  border: 1px solid rgba(242, 102, 139, 0.35);
  color: var(--rose);
}

/* 漂浮爱心背景 */
.hearts-bg {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  overflow: hidden;
}
.hearts-bg .fh {
  position: absolute;
  bottom: -80px;
  color: var(--rose);
  line-height: 1;
  opacity: 0;
  animation-name: heartsRise;
  animation-timing-function: linear;
  animation-iteration-count: infinite;
  will-change: transform, opacity;
}
.hearts-bg .fh.dot { border-radius: 50%; background: currentColor; }
/* 未解锁时让爱心飘在信封之上 */
body.locked .hearts-bg { z-index: 210; }
@keyframes heartsRise {
  0% { transform: translateY(0) rotate(0deg) scale(0.9); opacity: 0; }
  12% { opacity: var(--o, 0.8); }
  88% { opacity: var(--o, 0.8); }
  100% { transform: translateY(-115vh) rotate(38deg) scale(1.2); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .hearts-bg { display: none; }
}

/* 计时数字动效 */
.sky-timer { animation: timerBreath 6s ease-in-out infinite; }
@keyframes timerBreath {
  0%, 100% { box-shadow: 0 24px 60px rgba(224, 116, 152, 0.16); }
  50% { box-shadow: 0 28px 76px rgba(224, 116, 152, 0.3); }
}
.sky-cell .num { will-change: transform, opacity; font-family: "Parisienne", "Segoe Script", "Brush Script MT", cursive; font-weight: 400; font-size: clamp(30px, 4.4vw, 46px); letter-spacing: 0.02em; }
@keyframes numPop {
  0% { transform: scale(0.4) translateY(16px); opacity: 0; }
  55% { transform: scale(1.14) translateY(-4px); opacity: 1; }
  78% { transform: scale(0.97) translateY(0); }
  100% { transform: scale(1) translateY(0); }
}
.sky-timer.entering .sky-cell .num {
  animation: numPop 0.9s cubic-bezier(0.3, 1.5, 0.5, 1) both;
}
.sky-timer.entering .sky-cell:nth-child(1) .num { animation-delay: 0.05s; }
.sky-timer.entering .sky-cell:nth-child(2) .num { animation-delay: 0.13s; }
.sky-timer.entering .sky-cell:nth-child(3) .num { animation-delay: 0.21s; }
.sky-timer.entering .sky-cell:nth-child(4) .num { animation-delay: 0.29s; }

/* 卡片质感优化（游乐场 / 心动签） */
.panel {
  background:
    radial-gradient(120% 80% at 50% 0%, #fffafc 0%, #fffdfb 55%, #fff6fa 100%);
  border: 1px solid rgba(255, 176, 200, 0.42);
  box-shadow: 0 22px 52px rgba(224, 116, 152, 0.14), inset 0 1px 0 #fff;
}
.panel::before {
  content: "";
  position: absolute;
  inset: 10px;
  border-radius: 18px;
  border: 1px dashed rgba(242, 102, 139, 0.16);
  pointer-events: none;
}
.panel h3 { letter-spacing: 0.04em; }

.fortune-front {
  background:
    radial-gradient(120% 90% at 50% 0%, #fff7fb 0%, #ffe4ef 55%, #ffd2e3 100%);
  border: 1px solid rgba(226, 81, 124, 0.26);
  color: var(--rose);
  box-shadow: 0 12px 26px rgba(224, 116, 152, 0.18), inset 0 1px 0 rgba(255, 255, 255, 0.9);
}
.fortune-front::before {
  inset: 6px;
  border: 1px dashed rgba(226, 81, 124, 0.3);
  border-radius: 9px;
}
.fortune-front::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.55) 0%, rgba(255, 255, 255, 0) 45%);
  pointer-events: none;
}
.fortune-back {
  background: linear-gradient(160deg, #fffdfe, #fff2f7);
  border: 1px solid rgba(255, 176, 200, 0.45);
  color: #8a2a4a;
}

/* ---------- 爱你的理由 · 信笺翻牌卡 ---------- */
.reasons { gap: 26px; padding: 8px 4px 26px; }
.flip {
  height: 258px;
  perspective: 1000px;
  cursor: pointer;
  transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}
.flip-inner { transform: rotate(var(--r, 0deg)); }
.flip.flipped .flip-inner { transform: rotate(0deg) rotateY(180deg); }
@media (hover: hover) {
  .flip:hover { transform: translateY(-10px); }
  .flip:hover .flip-inner { transform: rotate(0deg) rotateY(180deg); }
}

.flip-face {
  border-radius: 26px;
  padding: 34px 22px 28px;
  background: linear-gradient(162deg, #ffffff 0%, #fff4f8 58%, #ffeaf1 100%);
  border: 1px solid rgba(255, 176, 200, 0.5);
  box-shadow:
    0 18px 38px rgba(216, 118, 152, 0.16),
    0 2px 6px rgba(216, 118, 152, 0.08);
  overflow: hidden;
  transition: box-shadow 0.45s ease;
}
.flip-front {
  background:
    radial-gradient(ellipse 160% 90% at 50% 118%, rgba(255, 190, 210, 0.35), transparent 62%),
    linear-gradient(162deg, #ffffff 0%, #fff4f8 58%, #ffeaf1 100%);
}
.flip:hover .flip-face {
  box-shadow:
    0 34px 62px rgba(216, 118, 152, 0.26),
    0 6px 14px rgba(216, 118, 152, 0.1);
}
/* 内层虚线信笺框 */
.flip-face::before {
  content: "";
  position: absolute;
  inset: 11px;
  border: 1px dashed rgba(238, 150, 180, 0.38);
  border-radius: 18px;
  pointer-events: none;
}
/* 右上角小爱心 */
.corner-heart {
  position: absolute;
  top: 20px;
  right: 22px;
  font-style: normal;
  font-size: 11px;
  color: rgba(238, 130, 168, 0.55);
  transform: rotate(12deg);
  transition: transform 0.4s ease, color 0.4s ease;
}
.flip:hover .corner-heart { color: var(--rose); transform: rotate(0deg) scale(1.35); }
/* 左上角编号 */
.reason-num {
  position: absolute;
  top: 16px;
  left: 22px;
  font-family: "Parisienne", var(--font-serif);
  font-size: 19px;
  color: #e0a46a;
  letter-spacing: 0.04em;
  opacity: 0.9;
}
/* 圆形徽章 */
.flip-front .medal {
  width: 84px;
  height: 84px;
  margin: 6px auto 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 38px;
  line-height: 1;
  background: radial-gradient(circle at 32% 26%, #ffffff, var(--wash, #ffdbe7) 58%, var(--wash-deep, #ffb6cf));
  box-shadow:
    0 12px 26px rgba(216, 118, 152, 0.26),
    inset 0 -6px 14px rgba(216, 118, 152, 0.18),
    inset 0 3px 8px rgba(255, 255, 255, 0.85),
    0 0 0 6px rgba(255, 255, 255, 0.55);
  transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.5s ease;
}
.flip-front .medal span {
  transform: translateY(1px);
  filter: drop-shadow(0 3px 5px rgba(180, 80, 115, 0.28));
}
.flip:hover .medal {
  transform: translateY(-4px) rotate(-7deg) scale(1.09);
  box-shadow:
    0 20px 34px rgba(216, 118, 152, 0.34),
    inset 0 -6px 14px rgba(216, 118, 152, 0.2),
    inset 0 3px 8px rgba(255, 255, 255, 0.9),
    0 0 0 8px rgba(255, 255, 255, 0.6);
}

.flip-front h4 {
  font-family: var(--font-serif);
  font-size: 19px;
  font-weight: 400;
  letter-spacing: 0.18em;
  color: var(--text);
}
.flip-front .reason-en {
  margin-top: 2px;
  font-family: "Parisienne", var(--font-serif);
  font-size: 15px;
  color: #e0a46a;
  letter-spacing: 0.03em;
}
.flip-front .reason-line {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  margin-top: 12px;
  color: #ffb7cd;
}
.flip-front .reason-line::before,
.flip-front .reason-line::after {
  content: "";
  width: 30px;
  height: 1px;
  background: linear-gradient(90deg, transparent, #ffb7cd);
}
.flip-front .reason-line::after {
  background: linear-gradient(90deg, #ffb7cd, transparent);
}
.flip-front .reason-line i {
  font-style: normal;
  font-size: 9px;
  color: var(--rose);
}

/* 卡背：理由文字 */
.flip-back {
  padding: 30px 24px;
  background:
    radial-gradient(ellipse 160% 90% at 50% 118%, rgba(255, 190, 210, 0.32), transparent 62%),
    linear-gradient(162deg, #fffdfe 0%, #ffeef5 60%, #ffdcea 100%);
  border-color: rgba(255, 176, 200, 0.5);
  color: #7c3350;
  font-family: var(--font-hand);
  font-size: 15px;
  line-height: 1.85;
}

/* 重点卡片：你的全部 */
.flip.is-featured .flip-front {
  background: linear-gradient(158deg, #f7789c 0%, #e8517e 46%, #d13f6d 100%);
  border-color: rgba(255, 255, 255, 0.42);
  box-shadow:
    0 28px 56px rgba(206, 70, 116, 0.38),
    inset 0 1px 0 rgba(255, 255, 255, 0.35);
}
.flip.is-featured .flip-front::before { border-color: rgba(255, 255, 255, 0.42); }
.flip.is-featured .flip-front h4 { color: #fff; }
.flip.is-featured .reason-en { color: #ffd9e4; }
.flip.is-featured .reason-num { color: #ffd0dd; }
.flip.is-featured .corner-heart { color: rgba(255, 255, 255, 0.75); }
.flip.is-featured .reason-line { color: rgba(255, 255, 255, 0.7); }
.flip.is-featured .reason-line::before {
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.65));
}
.flip.is-featured .reason-line::after {
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.65), transparent);
}
.flip.is-featured .reason-line i { color: #fff; }
.flip.is-featured .medal {
  background: radial-gradient(circle at 32% 26%, #ffffff, #ffe6ee 58%, #ffc2d6);
  box-shadow:
    0 16px 30px rgba(120, 24, 62, 0.34),
    inset 0 -6px 14px rgba(216, 118, 152, 0.22),
    inset 0 3px 8px rgba(255, 255, 255, 0.95),
    0 0 0 7px rgba(255, 255, 255, 0.3);
}
.flip.is-featured .flip-back {
  background: linear-gradient(158deg, #f7789c 0%, #e8517e 52%, #d13f6d 100%);
  border-color: rgba(255, 255, 255, 0.42);
  color: #fff5f8;
}
/* 金色丝带 */
.flip .ribbon {
  position: absolute;
  top: 20px;
  right: -36px;
  transform: rotate(38deg);
  background: linear-gradient(180deg, #f0c489, #dda261);
  color: #fff;
  font-family: "Parisienne", var(--font-serif);
  font-size: 13px;
  letter-spacing: 0.1em;
  padding: 5px 42px;
  box-shadow: 0 8px 18px rgba(180, 110, 50, 0.3);
  z-index: 3;
  pointer-events: none;
}

/* ---------- 互动区 · 发电站与心动签（信笺新版） ---------- */
.panel {
  border-radius: 32px;
  padding: 42px 34px 36px;
  background: linear-gradient(165deg, #fffdfa 0%, #fff4f8 55%, #ffeaf1 100%);
  border: 1px solid rgba(255, 176, 200, 0.5);
  box-shadow: 0 26px 58px rgba(216, 118, 152, 0.16), 0 2px 6px rgba(216, 118, 152, 0.06);
}
.panel::before {
  content: "";
  position: absolute;
  inset: 13px;
  border-radius: 22px;
  border: 1px dashed rgba(238, 150, 180, 0.36);
  pointer-events: none;
}
.panel::after {
  content: "";
  position: absolute;
  left: -20%;
  bottom: -45%;
  width: 140%;
  height: 85%;
  background: radial-gradient(ellipse at center, rgba(255, 190, 210, 0.3), transparent 62%);
  pointer-events: none;
}
.panel > :not(.float-heart) { position: relative; z-index: 1; }
.panel h3 {
  font-family: var(--font-serif);
  font-size: clamp(21px, 2.6vw, 27px);
  font-weight: 400;
  letter-spacing: 0.18em;
  color: var(--text);
  margin-bottom: 6px;
}
.panel > p {
  font-size: 12.5px;
  letter-spacing: 0.16em;
  color: var(--muted);
  margin-bottom: 22px;
}

/* 爱的发电站 */
.heart-btn {
  width: 138px;
  height: 138px;
  font-size: 52px;
  background: radial-gradient(circle at 34% 26%, #ffa8c4 0%, #f2668b 48%, #cf3f6c 100%);
  box-shadow:
    0 22px 44px rgba(206, 74, 118, 0.42),
    inset 0 -10px 20px rgba(150, 30, 74, 0.32),
    inset 0 6px 16px rgba(255, 255, 255, 0.4),
    0 0 0 10px rgba(255, 255, 255, 0.5);
  animation: none;
  transition: transform 0.18s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease;
}
.heart-btn:hover {
  transform: scale(1.05);
  box-shadow:
    0 26px 52px rgba(206, 74, 118, 0.5),
    inset 0 -10px 20px rgba(150, 30, 74, 0.3),
    inset 0 6px 16px rgba(255, 255, 255, 0.45),
    0 0 0 12px rgba(255, 255, 255, 0.55);
}
.heart-btn:active, .heart-btn.bump { transform: scale(0.9); }
.heart-count {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 8px;
  margin-top: 40px;
  font-size: 15px;
  letter-spacing: 0.16em;
  color: var(--muted);
}
.heart-count span {
  font-family: "Parisienne", var(--font-serif);
  font-size: 54px;
  line-height: 1;
  background: linear-gradient(115deg, #f2668b, #ff9dbb 45%, #e0a46a);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.heart-msg {
  margin-top: 10px;
  font-size: 13px;
  letter-spacing: 0.12em;
  color: var(--muted);
}

/* 今日心动签 */
.fortune-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  padding: 6px 2px 4px;
  margin-bottom: 22px;
}
.fortune {
  width: auto;
  height: 196px;
  perspective: 1100px;
  cursor: pointer;
  transform: rotate(var(--r, 0deg));
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}
.fortune-inner { transition: transform 0.85s cubic-bezier(0.22, 1, 0.36, 1); }
.fortune.flipped { transform: rotate(0deg) translateY(-8px) scale(1.04); z-index: 6; }
.fortune.flipped .fortune-inner { transform: rotateY(180deg); }
@media (hover: hover) {
  .fortune:not(.flipped):hover { transform: rotate(0deg) translateY(-9px) scale(1.04); z-index: 4; }
  .fortune:not(.flipped):hover .fortune-inner { transform: none; }
}
.fortune-face { border-radius: 18px; overflow: hidden; }

.fortune-front {
  flex-direction: column;
  background: linear-gradient(155deg, #ffe6ef 0%, #ffc9dc 55%, #f7a9c6 100%);
  border: 1px solid rgba(255, 255, 255, 0.75);
  box-shadow: 0 16px 32px rgba(216, 118, 152, 0.26), inset 0 1px 0 rgba(255, 255, 255, 0.6);
  color: #fff;
  font-size: 20px;
  font-family: var(--font-serif);
}
.fortune-front::before {
  content: "";
  position: absolute;
  inset: 9px;
  border: 1.5px solid rgba(224, 164, 106, 0.62);
  border-radius: 12px;
  pointer-events: none;
}
.fortune-front::after {
  content: "";
  position: absolute;
  inset: 14px;
  border: 1px dashed rgba(224, 164, 106, 0.42);
  border-radius: 8px;
  pointer-events: none;
}
.fortune .emblem {
  width: 62px;
  height: 62px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at 34% 26%, #fff3f7, #ffb2cd 60%, #ef7ba5);
  color: #fff;
  font-size: 24px;
  line-height: 1;
  box-shadow: 0 8px 18px rgba(190, 70, 115, 0.32), inset 0 -4px 10px rgba(190, 70, 115, 0.22);
}
.fortune .flourish {
  margin-top: 12px;
  font-family: "Parisienne", var(--font-serif);
  font-size: 12px;
  letter-spacing: 0.22em;
  color: #e0a46a;
  opacity: 0.85;
}
.fortune-front .corner {
  position: absolute;
  font-size: 9px;
  color: rgba(216, 122, 158, 0.55);
}
.fortune-front .corner.tl { top: 15px; left: 15px; }
.fortune-front .corner.tr { top: 15px; right: 15px; }
.fortune-front .corner.bl { bottom: 15px; left: 15px; }
.fortune-front .corner.br { bottom: 15px; right: 15px; }

.fortune-back {
  padding: 22px 14px 18px;
  background: linear-gradient(168deg, #ffffff 0%, #fff2f6 60%, #ffe6ee 100%);
  border: 1px solid rgba(255, 176, 200, 0.5);
  box-shadow: 0 16px 32px rgba(216, 118, 152, 0.24);
  color: #7c3350;
  font-family: var(--font-hand);
  font-size: 12.5px;
  line-height: 1.85;
}
.fortune-back::before {
  content: "";
  position: absolute;
  inset: 9px;
  border: 1px dashed rgba(238, 150, 180, 0.4);
  border-radius: 12px;
  pointer-events: none;
}
/* 翻面装饰：上上签徽章 / 图标 / 分割线 / 手写落款 */
.fortune-back .fortune-badge {
  font-family: var(--font-serif);
  font-size: 9px;
  letter-spacing: 0.2em;
  color: #c08a55;
  padding: 2px 10px;
  border: 1px solid rgba(224, 164, 106, 0.6);
  border-radius: 999px;
  background: rgba(255, 246, 232, 0.9);
}
.fortune-back .fortune-icon {
  width: 28px;
  height: 28px;
  margin: 7px 0 5px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  background: linear-gradient(145deg, #ffe4ec, #ffd2c4);
  box-shadow: inset 0 -3px 8px rgba(232, 106, 148, 0.18);
}
.fortune-back .fortune-text {
  margin: 2px 0 0;
  font-family: var(--font-hand);
  font-size: 12.5px;
  line-height: 1.8;
  letter-spacing: 0.04em;
  color: #7c3350;
}
.fortune-back .fortune-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  margin-top: 8px;
  font-size: 8px;
  color: rgba(232, 130, 168, 0.75);
}
.fortune-back .fortune-divider::before,
.fortune-back .fortune-divider::after {
  content: "";
  width: 20px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(232, 130, 168, 0.7));
}
.fortune-back .fortune-divider::after {
  background: linear-gradient(90deg, rgba(232, 130, 168, 0.7), transparent);
}
.fortune-back .fortune-script {
  margin-top: 4px;
  font-family: "Parisienne", var(--font-serif);
  font-size: 10px;
  letter-spacing: 0.12em;
  color: rgba(224, 164, 106, 0.9);
}

/* 重新抽签 */
#fortune-reset {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 22px auto 0;
  padding: 11px 28px;
  border-radius: 999px;
  border: 1px solid rgba(232, 130, 168, 0.6);
  background: linear-gradient(120deg, #fff4f8, #ffe6ee);
  color: var(--rose);
  font-family: var(--font-serif);
  font-size: 13.5px;
  letter-spacing: 0.18em;
  box-shadow: 0 12px 26px rgba(224, 116, 152, 0.18);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
#fortune-reset:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 34px rgba(224, 116, 152, 0.26);
  background: linear-gradient(120deg, #fff4f8, #ffe6ee);
  border-color: rgba(232, 130, 168, 0.75);
}

.fortune-back { flex-direction: column; }

@media (max-width: 900px) {
  .panel { padding: 32px 22px 28px; }
}
@media (max-width: 560px) {
  .panel { padding: 28px 18px 24px; }
  .fortune-cards { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .fortune { height: 168px; }
  .fortune .emblem { width: 52px; height: 52px; font-size: 21px; }
  .fortune .flourish { margin-top: 9px; font-size: 11px; }
  .fortune-back { padding: 20px 12px 15px; font-size: 11.5px; }
  .fortune-back .fortune-text { font-size: 11.5px; }
  .heart-btn { width: 122px; height: 122px; font-size: 46px; }
  .heart-count span { font-size: 46px; }
}

/* ---------- 发电站 · 等级进度与小数据 ---------- */
.level-progress {
  max-width: 300px;
  margin: 20px auto 0;
}
.bar {
  height: 8px;
  border-radius: 999px;
  background: rgba(240, 175, 198, 0.32);
  overflow: hidden;
}
.bar-fill {
  height: 100%;
  width: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, #ffb0c8, #f2668b 55%, #e0a46a);
  box-shadow: 0 0 12px rgba(242, 102, 139, 0.5);
  transition: width 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}
.level-progress .bar-text {
  margin: 22px 0 0;
  font-size: 11.5px;
  letter-spacing: 0.12em;
  color: var(--muted);
}
.bar-text b { color: var(--rose); font-weight: 600; }

.mini-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 24px;
}
.mini {
  padding: 13px 6px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.62);
  border: 1px solid rgba(255, 186, 208, 0.42);
}
.mini .v {
  display: block;
  font-family: var(--font-serif);
  font-size: 21px;
  line-height: 1.2;
  color: var(--rose);
}
.mini .k {
  display: block;
  margin-top: 2px;
  font-size: 10.5px;
  letter-spacing: 0.16em;
  color: var(--muted);
}

.station-ecg {
  display: block;
  width: 100%;
  max-width: 360px;
  height: 46px;
  margin: 22px auto 0;
  opacity: 0.75;
}
.station-ecg path {
  fill: none;
  stroke: url(#stationEcgGrad);
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 190 500;
  animation: stationEcgRun 3.4s linear infinite;
}
@keyframes stationEcgRun {
  from { stroke-dashoffset: 690; }
  to { stroke-dashoffset: 0; }
}

/* ---------- 心动签 · 放大查看 ---------- */
body.fortune-open { overflow: hidden; }
.fortune-modal {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.32s ease, visibility 0.32s ease;
}
.fortune-modal.show { opacity: 1; visibility: visible; }
/* 只模糊「今日心动签」这块大卡片 */
.panel > h3,
.panel > p,
.panel > .fortune-cards,
.panel > #fortune-reset,
.panel > .level-progress,
.panel > .mini-stats,
.panel > .station-ecg {
  transition: filter 0.32s ease, opacity 0.32s ease;
}
.panel.fortune-blurred > h3,
.panel.fortune-blurred > p,
.panel.fortune-blurred > .fortune-cards,
.panel.fortune-blurred > #fortune-reset,
.panel.fortune-blurred > .level-progress,
.panel.fortune-blurred > .mini-stats,
.panel.fortune-blurred > .station-ecg {
  filter: blur(5px);
  opacity: 0.55;
  pointer-events: none;
}
.fortune-inner.is-flipped { transform: rotateY(180deg); }
/* 关闭后留在原位的牌保持翻开状态 */
.fortune.revealed .fortune-inner { transform: rotateY(180deg); transition: none; }
.fortune.revealed:hover .fortune-inner { transform: rotateY(180deg); }
.fortune-stage {
  position: relative;
  width: min(78vw, 320px);
  height: min(56vh, 440px);
  perspective: 1400px;
  transform-origin: center center;
  transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.45s ease;
  will-change: transform;
}
.fortune-stage .fortune-face { border-radius: 26px; }
.fortune-stage .fortune-back { padding: 34px 28px; }
.fortune-stage .fortune-badge { font-size: 11px; padding: 3px 14px; }
.fortune-stage .fortune-icon { width: 42px; height: 42px; margin: 14px 0 10px; font-size: 20px; }
.fortune-stage .fortune-text { font-size: 17px; line-height: 2; }
.fortune-stage .fortune-divider { margin-top: 18px; font-size: 10px; gap: 10px; }
.fortune-stage .fortune-divider::before,
.fortune-stage .fortune-divider::after { width: 34px; }
.fortune-stage .fortune-script { margin-top: 8px; font-size: 14px; }
.fortune-stage .fortune-front .emblem { width: 86px; height: 86px; font-size: 34px; }
.fortune-stage .flourish { margin-top: 16px; font-size: 16px; }
.fortune-close {
  position: absolute;
  top: -16px;
  right: -16px;
  z-index: 8;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid rgba(232, 130, 168, 0.55);
  background: rgba(255, 255, 255, 0.95);
  color: var(--rose);
  font-size: 15px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 22px rgba(224, 116, 152, 0.25);
  transition: transform 0.25s ease, background 0.25s ease;
}
.fortune-close:hover { transform: rotate(90deg) scale(1.06); background: #fff; }
@media (max-width: 560px) {
  .fortune-stage { width: min(84vw, 300px); height: min(52vh, 400px); }
  .fortune-stage .fortune-back { padding: 28px 20px; }
  .fortune-stage .fortune-text { font-size: 15px; }
  .fortune-stage .fortune-icon { width: 36px; height: 36px; margin: 10px 0 8px; font-size: 18px; }
}

/* ==================== 送你一朵玫瑰花（2D 点阵） ==================== */
.rose-section {
  --rc-rose: #f2668b;
  --rc-rose-deep: #dd4a76;
  --rc-gold: #e0a46a;
  --rc-gold-deep: #c98a4e;
  --rc-ink: #5c3346;
  --rc-ink-soft: #a3728a;
  position: relative;
  z-index: 1;
  max-width: 1020px;
  margin: 0 auto;
  padding: 22px 22px 6px;
}
.rose-section-head { text-align: center; margin-bottom: 18px; }
.rose-head-row { display: flex; align-items: center; justify-content: center; gap: 18px; }
.rose-head-row .rose-h-side {
  color: var(--rc-rose); font-size: 17px;
  animation: roseBeat 2.2s ease-in-out infinite;
}
.rose-head-row .rose-h-side:last-child { animation-delay: .35s; }
.rose-title {
  font-family: "ZCOOL XiaoWei", "Noto Serif SC", serif;
  font-weight: 400; font-size: clamp(26px, 4vw, 38px);
  letter-spacing: .18em; color: var(--rc-ink); margin: 0;
}
.rose-script {
  display: block; margin-top: 8px;
  font-family: "Parisienne", cursive;
  font-size: 22px; color: var(--rc-gold); letter-spacing: .05em;
}
.rose-sub {
  margin: 10px 0 0; font-size: 13.5px;
  letter-spacing: .22em; color: var(--rc-ink-soft); font-weight: 300;
}
.rose-stage-wrap { position: relative; }
.rose-stage { position: relative; width: 100%; height: clamp(380px, 60vh, 560px); }
.rose-stage canvas {
  display: block; width: 100%; height: 100%;
  position: relative; z-index: 2; pointer-events: none;
}
.rose-aura {
  position: absolute; left: 50%; top: 42%;
  width: 78%; height: 78%; transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(255,176,200,.34) 0%, rgba(255,200,216,.16) 42%, transparent 68%);
  filter: blur(22px); pointer-events: none; z-index: 1;
  animation: roseGlowBreath 5.6s ease-in-out infinite;
}
.rose-shadow {
  position: absolute; left: 50%; bottom: 4%;
  width: 58%; height: 13%; transform: translateX(-50%);
  background: radial-gradient(ellipse at center, rgba(216,118,152,.26), rgba(216,118,152,.1) 45%, transparent 72%);
  filter: blur(12px); pointer-events: none; z-index: 1;
}
.rose-tag {
  position: absolute; top: 12px; left: 50%; transform: translateX(-50%); z-index: 3;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 18px; border-radius: 999px;
  border: 1px solid rgba(224,164,106,.5);
  background: rgba(255,255,255,.72);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  color: var(--rc-gold-deep);
  font-family: "Parisienne", cursive;
  font-size: 14px; letter-spacing: .16em;
  box-shadow: 0 10px 24px rgba(224,140,160,.16);
  pointer-events: none;
}
.rose-tag i { font-size: 10px; color: var(--rc-rose); }
.rose-stage-foot { display: flex; align-items: center; justify-content: center; margin-top: 14px; }
.rose-hint {
  display: inline-flex; align-items: center; gap: 9px;
  font-size: 12.5px; letter-spacing: .2em;
  color: var(--rc-ink-soft); font-weight: 300;
}
.rose-hint i { color: var(--rc-rose); font-size: 11px; animation: roseSpinSlow 6s linear infinite; }
.rose-footer-line {
  text-align: center; padding: 26px 20px 32px;
  font-family: "ZCOOL XiaoWei", "Noto Serif SC", serif;
  letter-spacing: .26em; color: var(--rc-ink);
  font-size: clamp(16px, 2.4vw, 21px); margin: 0;
}
.rose-footer-line small {
  display: block; font-family: "Parisienne", cursive;
  letter-spacing: .05em; color: var(--rc-gold);
  font-size: 18px; margin-top: 6px;
}
@keyframes roseBeat {
  0%, 100% { transform: scale(1); }
  18% { transform: scale(1.16); }
  32% { transform: scale(1); }
  52% { transform: scale(1.11); }
}
@keyframes roseSpinSlow { from { transform: rotate(0); } to { transform: rotate(360deg); } }
@keyframes roseGlowBreath {
  0%, 100% { opacity: .72; transform: translate(-50%, -50%) scale(1); }
  50% { opacity: 1; transform: translate(-50%, -50%) scale(1.08); }
}
@media (max-width: 620px) {
  .rose-stage { height: clamp(330px, 62vh, 450px); }
  .rose-tag { font-size: 12px; top: 6px; padding: 5px 14px; }
}
@media (prefers-reduced-motion: reduce) {
  .rose-aura, .rose-head-row .rose-h-side, .rose-hint i { animation: none; }
}

