/* ============================
   水豚噜噜 · 温暖治愈风婚礼请柬
   ============================ */

:root {
  --cream: #FFF8F0;
  --warm-brown: #8B6544;
  --light-apricot: #FFE4C4;
  --soft-green: #7EC8B7;
  --blush-pink: #FFB5B5;
  --grass-green: #A8D5A2;
  --soft-gold: #FFD700;
  --card-bg: #FFFAF5;
  --shadow-soft: 0 8px 32px rgba(139, 101, 68, 0.12);
  --shadow-card: 0 4px 20px rgba(139, 101, 68, 0.1);
  --radius-lg: 24px;
  --radius-md: 16px;
  --radius-sm: 12px;
}

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

html {
  scroll-behavior: smooth;
  background: var(--cream);
}

body {
  font-family: -apple-system, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  color: var(--warm-brown);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, video { display: block; max-width: 100%; }
button { font: inherit; cursor: pointer; border: none; background: none; }
a { color: inherit; text-decoration: none; -webkit-tap-highlight-color: transparent; }

/* App Shell */
.app-shell {
  width: min(100%, 480px);
  margin: 0 auto;
  background: var(--cream);
  min-height: 100vh;
  position: relative;
}

/* ========== Section 1: Hero ========== */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
  padding: calc(44px + env(safe-area-inset-top)) 18px 64px;
  overflow: hidden;
}

/* 横屏相框：拍立得质感 */
.hero-frame {
  position: relative;
  width: 100%;
}

.hero-photo {
  position: relative;
  aspect-ratio: 3 / 2;
  padding: 8px;
  background: #FFFDFA;
  border-radius: 20px;
  box-shadow: 0 14px 34px rgba(139, 101, 68, 0.18), 0 2px 8px rgba(139, 101, 68, 0.08);
}

.hero-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 13px;
}

.placeholder-photo {
  background: linear-gradient(135deg, #FFE4C4 0%, #FFDAB9 30%, #E8C9A0 70%, #D4A574 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}

.placeholder-text {
  color: rgba(139, 101, 68, 0.5);
  font-size: 14px;
  text-align: center;
  line-height: 2;
}

.placeholder-text small {
  font-size: 11px;
  opacity: 0.7;
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 0 24px;
}

.hero-date {
  font-size: 13px;
  letter-spacing: 0.2em;
  color: var(--warm-brown);
  opacity: 0.8;
  margin-bottom: 12px;
}

.hero-names {
  font-size: clamp(28px, 8vw, 38px);
  font-weight: 800;
  color: var(--warm-brown);
  line-height: 1.3;
  margin-bottom: 12px;
}

.name-heart {
  display: inline-block;
  color: var(--blush-pink);
  font-size: 0.8em;
  animation: heartbeat 1.5s ease-in-out infinite;
}

.hero-subtitle {
  font-size: 16px;
  color: var(--warm-brown);
  opacity: 0.7;
  letter-spacing: 0.1em;
}

.hero-sticker {
  position: absolute;
  z-index: 3;
  top: -22px;
  right: -6px;
  width: 88px;
  height: 88px;
  animation: float 3s ease-in-out infinite;
  filter: drop-shadow(0 4px 12px rgba(139, 101, 68, 0.25));
  pointer-events: none;
}

.hero-sticker img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* 封面第二个贴纸（相框左下角·滑梯噜噜） */
.hero-sticker-2 {
  position: absolute;
  z-index: 3;
  bottom: -18px;
  left: -6px;
  width: 64px;
  height: 64px;
  animation: float 4s ease-in-out 0.8s infinite;
  filter: drop-shadow(0 4px 10px rgba(139, 101, 68, 0.25));
  pointer-events: none;
}

.hero-sticker-2 img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.placeholder-sticker {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
  background: rgba(255, 228, 196, 0.8);
  border-radius: 50%;
  box-shadow: var(--shadow-card);
}

.scroll-hint {
  position: absolute;
  z-index: 3;
  bottom: max(24px, env(safe-area-inset-bottom));
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  color: var(--warm-brown);
  opacity: 0.6;
  animation: bounce-down 2s ease-in-out infinite;
}

.scroll-hint small {
  font-size: 11px;
}

.scroll-arrow {
  font-size: 20px;
}

/* ========== Section 2: Invitation ========== */
.invitation {
  position: relative;
  padding: 60px 20px;
  background: linear-gradient(180deg, var(--cream) 0%, #FFF5EB 50%, var(--cream) 100%);
  overflow: hidden;
}

.invitation-card {
  position: relative;
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  padding: 40px 24px 32px;
  box-shadow: var(--shadow-soft);
  border: 2px solid rgba(255, 228, 196, 0.6);
}

.card-stickers {
  position: absolute;
  inset: -16px;
  pointer-events: none;
  z-index: 3;
}

.card-stickers .sticker {
  position: absolute;
  width: 64px;
  height: 64px;
  object-fit: contain;
  filter: drop-shadow(0 3px 8px rgba(139, 101, 68, 0.2));
}

.card-stickers .s1 { top: -12px; left: 14px; animation: float 4s ease-in-out infinite; }
.card-stickers .s2 { top: 35%; right: -20px; width: 72px; height: 72px; animation: float 3.5s ease-in-out 0.5s infinite; }
.card-stickers .s3 { bottom: -14px; left: 38%; width: 56px; height: 56px; animation: float 4.5s ease-in-out 1s infinite; }

.placeholder-sticker-sm {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  font-size: 18px;
  background: var(--light-apricot);
  border-radius: 50%;
}

.card-body {
  text-align: center;
}

.card-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--warm-brown);
  margin-bottom: 18px;
  letter-spacing: 0.05em;
}

.card-lead {
  font-size: 16px;
  color: var(--warm-brown);
  margin-bottom: 24px;
  padding: 0 8px;
  line-height: 1.8;
  font-weight: 500;
  letter-spacing: 0.04em;
  position: relative;
}

.card-lead::before,
.card-lead::after {
  content: '';
  display: block;
  width: 32px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(139, 101, 68, 0.3), transparent);
  margin: 12px auto;
}

.card-text {
  margin-bottom: 28px;
}

.card-text p {
  font-size: 14px;
  line-height: 2.2;
  color: rgba(139, 101, 68, 0.78);
  margin-bottom: 18px;
  letter-spacing: 0.02em;
}

.card-text p:last-child {
  margin-bottom: 0;
}

.card-invite {
  font-size: 15px !important;
  color: var(--warm-brown) !important;
  font-weight: 500;
  padding-top: 4px;
}

.card-date {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 20px;
  font-weight: 300;
  color: var(--warm-brown);
  letter-spacing: 0.15em;
  margin-bottom: 28px;
  padding: 14px 0;
  border-top: 1px solid rgba(139, 101, 68, 0.15);
  border-bottom: 1px solid rgba(139, 101, 68, 0.15);
}

.date-dot {
  color: var(--blush-pink);
  font-size: 14px;
}

.card-info {
  display: flex;
  flex-direction: column;
  gap: 16px;
  text-align: left;
  padding: 20px;
  background: rgba(255, 228, 196, 0.3);
  border-radius: var(--radius-md);
}

.info-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.info-icon {
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(145deg, #FFFDF9, #FBEEDC);
  border: 1px solid rgba(139, 101, 68, 0.14);
  border-radius: 50%;
  box-shadow: 0 2px 8px rgba(139, 101, 68, 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.8);
  color: var(--warm-brown);
  flex-shrink: 0;
}

.info-icon svg {
  width: 20px;
  height: 20px;
}

.info-detail b {
  display: block;
  font-size: 15px;
  color: var(--warm-brown);
}

.info-detail small {
  font-size: 12px;
  color: rgba(139, 101, 68, 0.6);
}

/* ========== Section 3: Video ========== */
.video-section {
  position: relative;
  padding: 60px 20px;
  background: var(--cream);
}

/* 视频区角落贴纸（开大车噜噜，趴在视频框右下角） */
.video-corner-sticker {
  position: absolute;
  right: 8px;
  bottom: -14px;
  width: 72px;
  height: 72px;
  object-fit: contain;
  z-index: 4;
  pointer-events: none;
  filter: drop-shadow(0 4px 10px rgba(139, 101, 68, 0.25));
  animation: float 4.2s ease-in-out 0.4s infinite;
}

.section-heading {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  font-size: 20px;
  font-weight: 700;
  color: var(--warm-brown);
  margin-bottom: 24px;
}

.heading-sticker {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  object-fit: contain;
  filter: drop-shadow(0 2px 6px rgba(139, 101, 68, 0.18));
  animation: float 3.5s ease-in-out infinite;
}

.video-wrapper {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  background: #2a1f14;
  aspect-ratio: 16/9;
}

.video-wrapper video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.video-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: linear-gradient(135deg, #3d2b1a, #5a3d25);
  color: rgba(255, 228, 196, 0.8);
  font-size: 13px;
  text-align: center;
  line-height: 1.8;
}

.video-placeholder small {
  font-size: 11px;
  opacity: 0.6;
}

.play-icon {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 228, 196, 0.2);
  border-radius: 50%;
  font-size: 22px;
  border: 2px solid rgba(255, 228, 196, 0.4);
}

.section-desc {
  text-align: center;
  font-size: 14px;
  color: rgba(139, 101, 68, 0.6);
  margin-bottom: 20px;
}

/* ========== Section 3.5: Album (Grid + Lightbox) ========== */
.album-section {
  padding: 60px 16px;
  background: linear-gradient(180deg, var(--cream) 0%, #FFF5EB 50%, var(--cream) 100%);
}

/* 缩略图网格 */
.album-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  max-width: 480px;
  margin: 0 auto;
  padding: 0;
}

.album-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  background: #f0e6d8;
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.25s;
  -webkit-tap-highlight-color: transparent;
  padding: 0;
  border: none;
  display: block;
}

.album-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease, opacity 0.3s;
  opacity: 0;
}

.album-thumb img.is-loaded {
  opacity: 1;
}

.album-thumb:active {
  transform: scale(0.94);
}

@media (hover: hover) {
  .album-thumb:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(139, 101, 68, 0.25);
    z-index: 2;
  }
  .album-thumb:hover img {
    transform: scale(1.08);
  }
}

/* 缩略图序号角标 */
.album-thumb::after {
  content: attr(data-index);
  position: absolute;
  bottom: 4px;
  right: 6px;
  font-size: 10px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.85);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s;
}

.album-thumb:hover::after {
  opacity: 1;
}

/* ========== Lightbox 全屏看图 ========== */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(20, 14, 8, 0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: none;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.25s ease;
  -webkit-user-select: none;
  user-select: none;
}

.lightbox.is-open {
  display: flex;
  opacity: 1;
}

.lightbox-stage {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  touch-action: pan-y;
}

.lightbox-image {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
  transition: opacity 0.25s ease, transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  -webkit-user-drag: none;
  will-change: transform, opacity;
}

.lightbox-image.is-loading {
  opacity: 0;
}

.lightbox-spinner {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 40px;
  height: 40px;
  margin: -20px 0 0 -20px;
  border: 3px solid rgba(255, 228, 196, 0.2);
  border-top-color: var(--soft-gold);
  border-radius: 50%;
  animation: lb-spin 0.8s linear infinite;
  display: none;
}

.lightbox-spinner.is-visible {
  display: block;
}

@keyframes lb-spin {
  to { transform: rotate(360deg); }
}

/* 关闭按钮 */
.lightbox-close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 10;
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-radius: 50%;
  color: white;
  font-size: 26px;
  font-weight: 300;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 0 4px 0;
  border: none;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
}

.lightbox-close:hover { background: rgba(255, 255, 255, 0.28); }
.lightbox-close:active { transform: scale(0.9); }

/* 翻页按钮 */
.lightbox-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 44px;
  height: 64px;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: white;
  font-size: 32px;
  font-weight: 300;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
  padding: 0;
}

.lightbox-btn:hover { background: rgba(255, 255, 255, 0.22); }
.lightbox-btn:active { transform: translateY(-50%) scale(0.92); }

.lightbox-prev { left: 8px; }
.lightbox-next { right: 8px; }

/* 底部信息栏 */
.lightbox-info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 10;
  padding: 16px 20px calc(20px + env(safe-area-inset-bottom, 0));
  background: linear-gradient(to top, rgba(20, 14, 8, 0.85), transparent);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: white;
  font-size: 13px;
}

.lightbox-counter {
  font-weight: 500;
  letter-spacing: 0.05em;
  opacity: 0.9;
}

.lightbox-counter b {
  font-size: 16px;
  color: var(--soft-gold);
  font-weight: 700;
}

.lightbox-autoplay {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-radius: 20px;
  color: white;
  font-size: 12px;
  font-weight: 500;
  border: none;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
}

.lightbox-autoplay:hover { background: rgba(255, 255, 255, 0.25); }
.lightbox-autoplay:active { transform: scale(0.95); }

.lightbox-autoplay.is-playing {
  background: var(--soft-gold);
  color: #2a1f14;
}

.lightbox-autoplay .autoplay-icon {
  font-size: 10px;
  line-height: 1;
}

/* 移动端：缩小翻页按钮，避免遮挡图片 */
@media (max-width: 600px) {
  .lightbox-btn {
    width: 36px;
    height: 56px;
    font-size: 26px;
  }
  .lightbox-prev { left: 4px; }
  .lightbox-next { right: 4px; }
  .lightbox-info {
    padding: 12px 14px calc(14px + env(safe-area-inset-bottom, 0));
    font-size: 12px;
  }
  .lightbox-autoplay .autoplay-text {
    display: none;
  }
  .lightbox-autoplay {
    padding: 8px 12px;
  }
  .album-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
  }
}

/* ========== Section 4: Wishes Pool ========== */
.wishes-section {
  padding: 60px 20px;
  background: linear-gradient(180deg, var(--cream) 0%, #F0FFF8 50%, var(--cream) 100%);
  text-align: center;
}

.pool-container {
  position: relative;
  width: 100%;
  max-width: 340px;
  margin: 0 auto 24px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-soft), 0 0 0 4px rgba(126, 200, 183, 0.2);
  cursor: pointer;
  transition: transform 0.15s ease;
  -webkit-user-select: none;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.pool-container:active {
  transform: scale(0.96);
}

.pool-video-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 1/1;
  background: linear-gradient(135deg, #7EC8B7, #5BA89A);
  overflow: hidden;
}

.pool-video-wrap video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.pool-hearts {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.pool-hearts .heart {
  position: absolute;
  font-size: 24px;
  animation: heart-float 1.5s ease-out forwards;
  pointer-events: none;
}

.blessing-bubble {
  position: absolute;
  max-width: 200px;
  padding: 8px 14px;
  border: 2px solid;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  pointer-events: none;
  animation: blessing-float 2.6s cubic-bezier(0.2, 0.6, 0.4, 1) forwards;
  transform-origin: center;
}

.blessing-bubble::before {
  content: '💕';
  margin-right: 4px;
  font-size: 12px;
}

.combo-display {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 6px 14px;
  background: rgba(255, 181, 181, 0.9);
  border-radius: 20px;
  color: white;
  font-size: 14px;
  font-weight: 700;
  box-shadow: 0 2px 12px rgba(255, 181, 181, 0.4);
  animation: combo-pop 0.3s ease;
}

.combo-display b {
  font-size: 11px;
  opacity: 0.9;
}

.wishes-counter {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 8px;
  margin-bottom: 20px;
}

.counter-label {
  font-size: 14px;
  color: rgba(139, 101, 68, 0.6);
}

.counter-number {
  font-size: 36px;
  font-weight: 800;
  color: var(--soft-green);
  line-height: 1;
}

.counter-unit {
  font-size: 14px;
  color: rgba(139, 101, 68, 0.6);
}

.wish-button {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 10px 26px 10px 12px;
  background: linear-gradient(145deg, #FFFDF9, #FBEEDC);
  border: 1px solid rgba(139, 101, 68, 0.28);
  color: var(--warm-brown);
  border-radius: 50px;
  box-shadow: 0 4px 16px rgba(139, 101, 68, 0.16), inset 0 1px 0 rgba(255, 255, 255, 0.8);
  transition: transform 0.15s, box-shadow 0.15s;
}

.wish-button:active {
  transform: scale(0.95);
  box-shadow: 0 2px 8px rgba(139, 101, 68, 0.12);
}

/* 朱砂印章 */
.wish-btn-seal {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(145deg, #C0504A, #A93226);
  color: #FFF6EE;
  font-family: "Songti SC", "STSong", "SimSun", serif;
  font-size: 19px;
  font-weight: 700;
  border-radius: 8px;
  box-shadow: inset 0 0 0 1.5px rgba(255, 246, 238, 0.55), 0 2px 6px rgba(169, 50, 38, 0.35);
  transform: rotate(-6deg);
}

.wish-btn-label {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.35;
  text-align: left;
}

.wish-btn-label b {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.14em;
}

.wish-btn-label small {
  font-size: 11px;
  opacity: 0.62;
  letter-spacing: 0.06em;
}

/* ========== Section 5: Ending ========== */
.ending {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 52px 18px 44px;
  overflow: hidden;
  background: linear-gradient(to bottom, var(--cream) 0%, #FBEEDC 100%);
}

/* 横屏相框：与封面呼应的拍立得质感 */
.ending-frame {
  position: relative;
  width: 100%;
}

.ending-photo {
  position: relative;
  aspect-ratio: 3 / 2;
  padding: 8px;
  background: #FFFDFA;
  border-radius: 20px;
  box-shadow: 0 14px 34px rgba(139, 101, 68, 0.18), 0 2px 8px rgba(139, 101, 68, 0.08);
}

.ending-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 13px;
}

.ending-content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 26px 24px 8px;
  color: var(--warm-brown);
}

.countdown-box {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 8px;
  margin-bottom: 24px;
}

.countdown-label {
  font-size: 14px;
  opacity: 0.8;
}

.countdown-number {
  font-size: 52px;
  font-weight: 800;
  color: #C0504A;
  line-height: 1;
  text-shadow: 0 2px 10px rgba(192, 80, 74, 0.18);
}

.countdown-unit {
  font-size: 16px;
  opacity: 0.8;
}

.ending-words {
  font-size: 15px;
  line-height: 2;
  opacity: 0.85;
  margin-bottom: 28px;
}

.map-button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 14px 28px;
  background: #FFFDF9;
  border: 1.5px solid rgba(139, 101, 68, 0.25);
  border-radius: 50px;
  color: var(--warm-brown);
  font-size: 14px;
  font-weight: 600;
  box-shadow: 0 4px 14px rgba(139, 101, 68, 0.12);
  transition: background 0.2s;
}

.map-button:active {
  background: #FBEEDC;
}

.ending-names {
  margin-top: 32px;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.05em;
}

.ending-date {
  margin-top: 8px;
  font-size: 13px;
  opacity: 0.7;
}

.ending-sticker {
  position: absolute;
  z-index: 3;
  top: -20px;
  right: -6px;
  width: 80px;
  height: 80px;
  animation: float 3.5s ease-in-out infinite;
  filter: drop-shadow(0 4px 12px rgba(139, 101, 68, 0.25));
  pointer-events: none;
}

.ending-sticker img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* 尾页第二个贴纸（相框左下角·刷牙噜噜） */
.ending-sticker-2 {
  position: absolute;
  z-index: 3;
  bottom: -16px;
  left: -6px;
  width: 64px;
  height: 64px;
  animation: float 4s ease-in-out 1.2s infinite;
  filter: drop-shadow(0 4px 10px rgba(139, 101, 68, 0.25));
  pointer-events: none;
}

.ending-sticker-2 img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* ========== 花瓣氛围层 ========== */
.petals {
  position: fixed;
  inset: 0;
  z-index: 50;
  pointer-events: none;
  overflow: hidden;
}

.petal {
  position: absolute;
  top: -5vh;
  left: var(--x);
  width: var(--s);
  height: calc(var(--s) * 0.8);
  background: linear-gradient(135deg, var(--c1), var(--c2));
  border-radius: 100% 0 100% 0;
  opacity: 0;
  animation: petal-fall var(--d) linear var(--delay) infinite;
  will-change: transform, opacity;
}

@keyframes petal-fall {
  0% {
    transform: translate3d(0, 0, 0) rotate(var(--r0));
    opacity: 0;
  }
  8% {
    opacity: var(--op);
  }
  50% {
    transform: translate3d(var(--sway), 55vh, 0) rotate(calc(var(--r0) + 150deg));
  }
  90% {
    opacity: var(--op);
  }
  100% {
    transform: translate3d(calc(var(--sway) * -0.7), 112vh, 0) rotate(calc(var(--r0) + 330deg));
    opacity: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .petal {
    animation: none;
    opacity: 0;
  }
}

/* ========== Footer ========== */
.app-footer {
  padding: 24px 20px calc(70px + env(safe-area-inset-bottom));
  text-align: center;
  font-size: 12px;
  color: rgba(139, 101, 68, 0.4);
  background: var(--cream);
}

/* 页脚贴纸（秋天噜噜） */
.footer-sticker {
  display: block;
  width: 48px;
  height: 48px;
  object-fit: contain;
  margin: 0 auto 8px;
  opacity: 0.9;
  filter: drop-shadow(0 2px 6px rgba(139, 101, 68, 0.15));
  animation: float 4.5s ease-in-out infinite;
}

/* ========== Quick Nav ========== */
.quick-nav {
  position: fixed;
  z-index: 100;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: min(100%, 480px);
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  background: rgba(255, 248, 240, 0.92);
  backdrop-filter: blur(12px);
  border-top: 1px solid rgba(139, 101, 68, 0.1);
  padding-bottom: env(safe-area-inset-bottom);
}

.quick-nav a {
  padding: 12px 4px;
  text-align: center;
  font-size: 11px;
  font-weight: 600;
  color: rgba(139, 101, 68, 0.6);
  transition: color 0.2s;
}

.quick-nav a:active {
  color: var(--warm-brown);
}

/* ========== Music Control ========== */
.music-control {
  position: fixed;
  z-index: 100;
  right: max(12px, calc((100vw - 480px) / 2 + 12px));
  bottom: calc(56px + env(safe-area-inset-bottom));
}

.music-control button {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--card-bg);
  box-shadow: var(--shadow-card);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  border: 2px solid rgba(139, 101, 68, 0.1);
  transition: transform 0.2s;
  color: var(--warm-brown);
}

.music-control button.playing {
  background: var(--soft-green);
  color: white;
  border-color: var(--soft-green);
  animation: music-pulse 1.5s ease-in-out infinite;
}

.music-control button:active {
  transform: scale(0.9);
}

/* ========== Floating Bubbles ========== */
.floating-bubbles {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.floating-bubbles i {
  position: absolute;
  bottom: -20px;
  width: 8px;
  height: 8px;
  background: rgba(126, 200, 183, 0.2);
  border-radius: 50%;
  animation: bubble-rise var(--duration, 8s) linear var(--delay, 0s) infinite;
}

/* ========== Reveal Animation ========== */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* ========== Keyframes ========== */
@keyframes heartbeat {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.2); }
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

@keyframes bounce-down {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(6px); }
}

@keyframes heart-float {
  0% {
    opacity: 1;
    transform: translateY(0) scale(0.5);
  }
  50% {
    opacity: 0.8;
    transform: translateY(-60px) scale(1.2);
  }
  100% {
    opacity: 0;
    transform: translateY(-120px) scale(0.8);
  }
}

@keyframes blessing-float {
  0% {
    opacity: 0;
    transform: translateY(20px) scale(0.6) rotate(0deg);
  }
  15% {
    opacity: 1;
    transform: translateY(0) scale(1.05) rotate(var(--rotate, 0deg));
  }
  25% {
    transform: translateY(-8px) scale(1) rotate(var(--rotate, 0deg));
  }
  75% {
    opacity: 1;
    transform: translateY(-80px) translateX(var(--drift, 0px)) scale(1) rotate(var(--rotate, 0deg));
  }
  100% {
    opacity: 0;
    transform: translateY(-130px) translateX(var(--drift, 0px)) scale(0.9) rotate(var(--rotate, 0deg));
  }
}

@keyframes combo-pop {
  0% { transform: scale(0.5); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

@keyframes music-pulse {
  0%, 100% { box-shadow: 0 4px 20px rgba(126, 200, 183, 0.3); }
  50% { box-shadow: 0 4px 20px rgba(126, 200, 183, 0.6), 0 0 0 6px rgba(126, 200, 183, 0.1); }
}

@keyframes bubble-rise {
  0% {
    transform: translateY(0) translateX(0);
    opacity: 0.6;
  }
  100% {
    transform: translateY(-600px) translateX(20px);
    opacity: 0;
  }
}

/* ========== Reduced Motion ========== */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
  html { scroll-behavior: auto; }
}

/* ========== Small Screen ========== */
@media (max-width: 360px) {
  .hero-names { font-size: 24px; }
  .invitation-card { padding: 32px 18px 24px; }
  .countdown-number { font-size: 42px; }
  .pool-container { max-width: 280px; }
}

[hidden] { display: none !important; }
