/* ============================================================
   V2 视觉精修层 —— 叠加在 app.css 之后
   对应 docs/design/视觉与动效升级方案.md（S1-S3 落地）
   原则：照片为主角、一屏一主运动、材质真实细节、全员可降级、离线自足
   ============================================================ */

/* ---------- 1. 字体 / 节奏令牌 ---------- */
:root {
  --font-display: "Cormorant Garamond", "Songti SC", "Noto Serif SC", STSong, serif;
  --font-num: "Cormorant Garamond", "EB Garamond", Georgia, "Times New Roman", serif;
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --ease-io: cubic-bezier(.65, .05, .36, 1);
}

/* ---------- 2. 移除旧“整圈画框” ---------- */
.invite-surface::before { content: none; }

/* ---------- 3. 主题令牌扩展；朱砂改为“宣纸底 · 深朱砂字” ---------- */
.invite-surface[data-theme="garden"] {
  --ink: #263c35; --paper: #f4f1ea; --accent: #c69a58; --wash: #a7b6a7;
  --line: rgba(38, 60, 53, .14); --muted: #66746c;
  --surface: #faf7f0; --hairline: rgba(38, 60, 53, .12); --deep: #1e322b;
}
.invite-surface[data-theme="soiree"] {
  --ink: #f1ece3; --paper: #141519; --accent: #c89d5d; --wash: #684d5c;
  --line: rgba(241, 236, 227, .18); --muted: #b3a99d;
  --surface: #191a1f; --hairline: rgba(241, 236, 227, .14); --deep: #0d0e11;
}
.invite-surface[data-theme="vermilion"] {
  --ink: #552022; --paper: #f5eedf; --accent: #b8873f; --wash: #efe4cc;
  --line: rgba(85, 32, 34, .16); --muted: #8a6f5f;
  --surface: #faf4e6; --hairline: rgba(85, 32, 34, .12); --deep: #3f1618;
}

/* ---------- 4. 质感：颗粒层 + 层级修正 ---------- */
.invite-surface {
  font-family: "Songti SC", "Noto Serif SC", STSong, serif;
  --seal-bg: var(--deep);
  --seal-ink: var(--paper);
}
.invite-surface > .envelope,
.invite-surface > .invite-content { z-index: 2; position: relative; }

.theme-grain {
  position: fixed; inset: 0; z-index: 5; pointer-events: none;
  opacity: .05; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
}
.invite-preview .theme-grain { position: absolute; }

/* V3 沉浸式背景宇宙 — 三层 Canvas + 一层 CSS 氛围层 */
.invite-surface > .theme-canvas,
.invite-surface > .theme-fx,
.invite-surface > .theme-canvas-mid {
  position: fixed; inset: 0; pointer-events: none;
  transition: opacity .8s var(--ease-out);
}
.invite-surface > .theme-canvas { z-index: 1; opacity: .55; }
.invite-surface > .theme-canvas-mid { z-index: 2; opacity: .85; }
.invite-surface > .theme-fx { z-index: 4; mix-blend-mode: screen; opacity: .9; }
/* H5 上 mix-blend-mode 会让 CPU 飙升,改为半透叠加,体感差不多 */
@media (max-width: 720px) {
  .invite-surface > .theme-fx { mix-blend-mode: normal; opacity: .55; }
  .invite-surface > .theme-canvas-mid { opacity: .6; }
  .invite-surface > .theme-canvas { opacity: .35; }
}
.invite-preview > .theme-canvas,
.invite-preview > .theme-fx,
.invite-preview > .theme-canvas-mid { position: absolute; }
.invite-preview > .theme-canvas { opacity: .22; }
.invite-preview > .theme-canvas-mid { opacity: .35; }
.invite-preview > .theme-fx { opacity: .4; mix-blend-mode: normal; }

/* 三主题色调与混合模式微调 */
.invite-surface[data-theme="garden"] > .theme-canvas { filter: saturate(.85) brightness(1.02); }
.invite-surface[data-theme="soiree"] > .theme-canvas { filter: contrast(1.05) brightness(.85); }
.invite-surface[data-theme="vermilion"] > .theme-canvas { filter: saturate(.75) sepia(.08); }
.invite-surface[data-theme="soiree"] > .theme-canvas-mid { mix-blend-mode: screen; }
.invite-surface[data-theme="garden"] > .theme-canvas-mid,
.invite-surface[data-theme="vermilion"] > .theme-canvas-mid { mix-blend-mode: multiply; }
.invite-surface[data-theme="soiree"] > .theme-fx { mix-blend-mode: screen; }
.invite-surface[data-theme="vermilion"] > .theme-fx { mix-blend-mode: multiply; opacity: .8; }
.invite-surface[data-theme="garden"] > .theme-fx { mix-blend-mode: soft-light; }

/* 主题专属:朱砂主题宣纸"卷轴展开"开场 + 金线游移 */
@keyframes scroll-unroll {
  0%   { transform: scaleY(0); transform-origin: top center; opacity: 0; }
  60%  { opacity: 1; }
  100% { transform: scaleY(1); transform-origin: top center; opacity: 1; }
}
.invite-surface[data-theme="vermilion"][data-motion="on"] > .theme-canvas {
  animation: scroll-unroll 1.8s var(--ease-io) both;
}

/* 朱砂专属:hero 区顶部细金边(贴顶,不横穿中央) */
@keyframes gold-line-drift {
  0%, 100% { transform: translateX(-12%); }
  50%      { transform: translateX(12%); }
}
.invite-surface[data-theme="vermilion"][data-motion="on"] .hero::before {
  content: ""; position: absolute; left: 0; right: 0; top: 14%;
  height: 1px; z-index: 2; pointer-events: none;
  background: linear-gradient(90deg, transparent 0, rgba(184,135,63,.4) 50%, transparent 100%);
  animation: gold-line-drift 14s var(--ease-io) infinite;
  opacity: .4;
}
/* 原来那条突兀的 fixed 全屏横线改为只在 hero 内、且只在桌面展示(手机不显示) */
@media (max-width: 720px) {
  .invite-surface[data-theme="vermilion"][data-motion="on"] .hero::before { display: none; }
}

/* Soiree 专属:顶部黄铜光带 */
@keyframes brass-shimmer {
  0%, 100% { opacity: .14; transform: translateY(0); }
  50%      { opacity: .26; transform: translateY(-1.5%); }
}
.invite-surface[data-theme="soiree"][data-motion="on"]::after {
  content: ""; position: fixed; inset: 0 0 auto 0; height: 38%;
  z-index: 1; pointer-events: none;
  background: radial-gradient(70% 100% at 78% 0%, rgba(200,157,93,.35), transparent 60%);
  animation: brass-shimmer 6.5s var(--ease-io) infinite;
}

/* Garden 专属:底部草坡淡入 */
@keyframes garden-ground {
  0%   { opacity: 0; transform: translateY(8%); }
  100% { opacity: 1; transform: translateY(0); }
}
.invite-surface[data-theme="garden"][data-motion="on"]::after {
  content: ""; position: fixed; left: 0; right: 0; bottom: 0; height: 38%;
  z-index: 1; pointer-events: none;
  background:
    radial-gradient(80% 70% at 20% 100%, rgba(167,182,167,.45), transparent 60%),
    radial-gradient(60% 50% at 80% 100%, rgba(38,60,53,.18), transparent 65%);
  animation: garden-ground 2.2s var(--ease-out) both;
}

/* reduced-motion 完全静止:仅保留远景首帧 */
@media (prefers-reduced-motion: reduce) {
  .invite-surface > .theme-canvas-mid,
  .invite-surface > .theme-fx { display: none; }
  .invite-surface > .theme-canvas { opacity: .35; }
  .invite-surface[data-motion="on"]::after,
  .invite-surface[data-theme="vermilion"][data-motion="on"] > .theme-canvas { animation: none; }
}

/* ---------- 5. 字体层级（编辑排版感） ---------- */
.invite-surface .eyebrow {
  letter-spacing: .34em; text-transform: uppercase; font-size: 12px;
}
.envelope-card h1 { font-family: var(--font-display); font-weight: 600; letter-spacing: .02em; }
.envelope-card h1 i { font-family: var(--font-num); font-weight: 400; letter-spacing: .3em; }
.hero h2 { font-family: var(--font-display); letter-spacing: .01em; margin: 0; }
.hero h2 span { font-family: var(--font-num); font-size: .5em; }
/* V5:hero h2 改用 .hero-title 接管;避免被全局 h2 行高 / margin 影响 */
.hero h2.hero-title { font-family: inherit; letter-spacing: 0; line-height: 1.12; }
.section-heading h2, .thanks h2 { font-family: var(--font-display); }
/* 当 section-heading h2 承载新人姓名时,缩小字号 + & 改斜体 */
.section-heading h2 em {
  font-style: italic; color: var(--accent);
  margin: 0 .25em; font-size: .85em;
}
.countdown strong { font-family: var(--font-num); font-variant-numeric: lining-nums; }
.event-details dd, .envelope-meta { font-variant-numeric: lining-nums; }

/* ---------- 6. 照片语汇:去掉"贴纸错位投影",换编辑质感阴影/细边 ---------- */
.hero-image { box-shadow: 0 34px 70px -42px rgba(24, 12, 6, .5); }
.invite-surface[data-theme="garden"] .hero-image {
  border-color: color-mix(in srgb, var(--accent) 55%, transparent);
  box-shadow: 0 0 0 1px rgba(38, 60, 53, .06), 0 36px 72px -44px rgba(38, 60, 53, .45);
}
.invite-surface[data-theme="soiree"] .hero-image {
  border-color: rgba(200, 157, 93, .45);
  box-shadow: 0 0 0 1px rgba(200, 157, 93, .32), 0 30px 70px -30px rgba(0, 0, 0, .85);
}
.invite-surface[data-theme="vermilion"] .hero-image {
  border-color: rgba(85, 32, 34, .35);
  box-shadow: 0 0 0 1px rgba(85, 32, 34, .22), 0 34px 64px -40px rgba(63, 22, 24, .5);
}

/* ---------- 6a. 所有 section 共享主题光晕渗透(让背景延伸到全站) ---------- */
.invite-section { position: relative; isolation: isolate; }
.invite-section::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(60% 80% at 50% 0%, color-mix(in srgb, var(--accent) 12%, transparent), transparent 70%);
  opacity: .9;
}
/* 第二层:底部细微返光 */
.invite-section::after {
  content: ""; position: absolute; inset: auto 0 0 0; height: 240px; z-index: -1; pointer-events: none;
  background: radial-gradient(80% 100% at 50% 100%, color-mix(in srgb, var(--accent) 8%, transparent), transparent 70%);
  opacity: .7;
}
/* 相邻 section 的微小分隔:让主题色"漂浮" */
.invite-section + .invite-section::before {
  background: radial-gradient(50% 70% at 50% 0%, color-mix(in srgb, var(--accent) 18%, transparent), transparent 65%);
}
/* garden:稍微更柔的绿色调底 */
.invite-surface[data-theme="garden"] .invite-section::before {
  background: radial-gradient(60% 80% at 30% 0%, color-mix(in srgb, var(--accent) 16%, transparent), transparent 70%);
}
.invite-surface[data-theme="garden"] .invite-section::after {
  background: radial-gradient(80% 100% at 70% 100%, color-mix(in srgb, var(--accent) 12%, transparent), transparent 70%);
}
/* soiree:夜场加一抹黄铜晕 */
.invite-surface[data-theme="soiree"] .invite-section::before {
  background: radial-gradient(50% 80% at 80% 0%, color-mix(in srgb, var(--accent) 22%, transparent), transparent 70%);
}
/* vermilion:朱砂红深底 */
.invite-surface[data-theme="vermilion"] .invite-section::before {
  background: radial-gradient(60% 80% at 50% 0%, color-mix(in srgb, var(--accent) 18%, transparent), transparent 70%);
}
.invite-surface[data-theme="vermilion"] .invite-section::after {
  background: radial-gradient(80% 100% at 50% 100%, color-mix(in srgb, var(--accent) 14%, transparent), transparent 70%);
}
/* H5 上光晕减半(避免性能/视觉冲突) */
@media (max-width: 720px) {
  .invite-section::before, .invite-section::after { opacity: .5; }
}

/* ---------- 6b. 首页花束/装饰层(V5 升级) ----------
   主题色变量:petal(花瓣主色)、leaf(叶色)、accent(强调金/朱)、gem(深点缀) */
.invite-surface[data-theme="garden"] {
  --flora-petal: #e7c4c8;
  --flora-leaf: #6f8a6c;
  --flora-accent: #c69a58;
  --flora-gem: #9a5d62;
}
.invite-surface[data-theme="soiree"] {
  --flora-petal: #d8b06a;
  --flora-leaf: #8a6a3a;
  --flora-accent: #f1ece3;
  --flora-gem: #c89d5d;
}
.invite-surface[data-theme="vermilion"] {
  --flora-petal: #b8423a;
  --flora-leaf: #6f5a2a;
  --flora-accent: #b8873f;
  --flora-gem: #552022;
}

/* 花束层(全部不拦截交互);overflow:visible 让顶部花环可"溢出"出 hero 顶 */
.hero-flora { position: absolute; inset: -8% 0 -2% 0; pointer-events: none; z-index: 1; }

/* 顶部花环弧 */
.hero-arch-wrap {
  position: absolute; top: 4%; left: 50%; transform: translateX(-50%);
  width: min(1400px, 120%); height: 200px;
  opacity: .85;
}
.hero-arch { width: 100%; height: 100%; color: var(--flora-leaf); }

/* 花柱:改为顶部居中 + 底部居中（左右两侧不再放,H5 也可见） */
.hero-spray-wrap {
  position: absolute; width: 130px; height: 200px;
  color: var(--flora-leaf); opacity: .85;
  left: 50%; transform: translateX(-50%);
}
.hero-spray-top { top: 4%; }
.hero-spray-bottom { bottom: 4%; transform: translateX(-50%) scaleY(-1); }
.hero-spray { width: 100%; height: 100%; }

/* 居中横排珠串:顶部/底部分隔条 */
.hero-pearls {
  position: absolute; left: 50%; transform: translateX(-50%);
  width: min(80%, 460px); height: 24px;
  color: var(--flora-accent); opacity: .55;
}
.hero-pearls-top { top: 28%; }
.hero-pearls-bottom { bottom: 28%; }
.hero-pearls svg { width: 100%; height: 100%; }

/* 漂浮花瓣(12 颗) */
.hero-petals { position: absolute; inset: 0; }
.hero-petal {
  position: absolute;
  width: calc(var(--p-size, 6) * 1px);
  height: calc(var(--p-size, 6) * 1px);
  left: calc((var(--p-i, 0) * 91 % 92) * 1%);
  top: calc(((var(--p-i, 0) * 47 % 95) - 5) * 1%);
  color: var(--flora-petal);
  animation: petal-float 11s var(--ease-io) infinite;
  animation-delay: calc(var(--p-i, 0) * -0.9s);
  opacity: 0;
}
.hero-petal svg { width: 100%; height: 100%; transform: rotate(var(--p-rot, 0deg)); }
@keyframes petal-float {
  0%   { transform: translateY(-10vh) rotate(0deg); opacity: 0; }
  10%  { opacity: .85; }
  90%  { opacity: .85; }
  100% { transform: translateY(110vh) rotate(360deg); opacity: 0; }
}

/* 底部对称弧线 + 印章晕 */
.hero-arc-bottom-wrap {
  position: absolute; left: 0; right: 0; bottom: 14%; height: 110px;
  pointer-events: none; color: var(--flora-leaf); opacity: .9;
  display: flex; justify-content: center;
}
.hero-arc-bottom { width: min(1100px, 92%); height: 100%; }

/* 照片区四角花饰 */
.hero-image-wrap { position: relative; }
.hero-image-frame {
  position: absolute; inset: -22px; pointer-events: none; z-index: 2;
}
.hero-image-frame > .hero-corner:nth-child(1) { position: absolute; top: -8px; left: -8px; transform: rotate(-10deg); width: 92px; height: 92px; }
.hero-image-frame > .hero-corner:nth-child(2) { position: absolute; top: -8px; right: -8px; transform: scaleX(-1) rotate(-10deg); width: 92px; height: 92px; }
.hero-image-frame > .hero-corner:nth-child(3) { position: absolute; bottom: -8px; left: -8px; transform: scaleY(-1) rotate(-10deg); width: 92px; height: 92px; }
.hero-image-frame > .hero-corner:nth-child(4) { position: absolute; bottom: -8px; right: -8px; transform: scale(-1, -1) rotate(-10deg); width: 92px; height: 92px; }
.hero-image-frame .hero-corner { color: var(--flora-leaf); opacity: .85; }

/* 相册镜头：焦点图极缓推移（Ken Burns），克制细圆角 */
.gallery-item { border-radius: 2px; }
.gallery-item.is-active img { animation: kenburns 6.5s var(--ease-io) forwards; }
@keyframes kenburns {
  from { transform: scale(1.035); }
  to   { transform: scale(1.075) translate(-1.1%, -.7%); }
}

/* ---------- 7. 章节导航：随滚动高亮 + 平滑反馈 ---------- */
.progress-nav a {
  background: transparent;
  transition: background .25s var(--ease-out), border-color .25s var(--ease-out),
              box-shadow .25s var(--ease-out), transform .25s var(--ease-out);
}
.progress-nav a:first-child { background: transparent; }
.progress-nav a.is-active {
  background: var(--accent); border-color: var(--accent);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 20%, transparent);
  transform: scale(1.18);
}

/* ---------- 8. 音乐播放态：律动光晕取代心跳闪烁 ---------- */
.music-toggle { position: relative; }
.music-toggle.is-playing { color: var(--paper); background: var(--accent); }
.music-toggle.is-playing::after {
  content: ""; position: absolute; inset: -1px; border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--accent) 75%, transparent);
  animation: sonar 2s var(--ease-out) infinite;
}
@keyframes sonar {
  0%   { transform: scale(.92); opacity: .9; }
  75%  { transform: scale(1.62); opacity: 0; }
  100% { opacity: 0; }
}

/* ---------- 9. 入场揭示（仅 JS 标记 motion 后启用，避免无 JS 隐藏内容） ---------- */
.invite-surface[data-motion="on"] .reveal {
  opacity: 0; transform: translateY(26px);
  transition: opacity .9s var(--ease-out), transform .9s var(--ease-out);
}
.invite-surface[data-motion="on"] .reveal.is-in { opacity: 1; transform: none; }
.invite-surface[data-motion="on"] .gallery-stage.reveal,
.invite-surface[data-motion="on"] .contact-grid.reveal { transition-duration: .7s; }

/* ---------- 10. 控件反馈 ---------- */
.button {
  transition: transform .25s var(--ease-out), background .25s, border-color .25s, box-shadow .25s;
}
.button:hover { transform: translateY(-2px); box-shadow: 0 12px 24px -16px rgba(0, 0, 0, .35); }
.button:active { transform: translateY(0); }
.theme-choice button {
  transition: transform .3s var(--ease-out), box-shadow .3s, border-color .3s;
}
.theme-choice button:hover { transform: translateY(-3px); box-shadow: 0 16px 34px -22px rgba(0, 0, 0, .45); }
.theme-choice button[data-theme="vermilion"] .theme-swatch {
  background: linear-gradient(135deg, #f5eedf 0 47%, #552022 47%);
}

/* ---------- 11. 降低动态效果时：内容必须完整可用 ---------- */
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
  .gallery-item.is-active img { animation: none !important; }
}

/* ---------- 12. 三套主题的版式与材质差异（S2） ---------- */
/* 星夜晚宴：剧照大画幅 + 节目单细节 */
.invite-surface[data-layout="stage"] .hero { grid-template-columns: minmax(0, .86fr) minmax(430px, 1.14fr); align-items: center; }
.invite-surface[data-layout="stage"] .hero-image { aspect-ratio: 3 / 4; max-height: 74vh; }
.invite-surface[data-layout="stage"] .event-details dt { letter-spacing: .2em; font-size: 12px; }
.invite-surface[data-theme="soiree"] .gallery { background: linear-gradient(180deg, var(--paper) 0%, color-mix(in srgb, var(--paper) 90%, #000) 100%); }
.invite-surface[data-theme="soiree"] .section-heading h2 { letter-spacing: .05em; }
.invite-surface[data-theme="soiree"] .countdown div { background: color-mix(in srgb, var(--paper) 94%, #000); border-top: 1px solid var(--hairline); }
.invite-surface[data-theme="soiree"] .countdown { background: color-mix(in srgb, var(--paper) 94%, #000); border: 1px solid var(--hairline); }
.invite-surface[data-theme="soiree"] .contact { border-top: 1px solid var(--hairline); }

/* 朱砂喜宴：印章章法（宣纸底 + 深朱砂字 + 收紧字距） */
.invite-surface[data-theme="vermilion"] .hero h2 { font-weight: 600; letter-spacing: .03em; }
.invite-surface[data-theme="vermilion"] .hero-invitation { letter-spacing: .5em; border-color: color-mix(in srgb, var(--accent) 65%, transparent); }
.invite-surface[data-theme="vermilion"] .wax-seal { background: var(--deep); color: var(--paper); box-shadow: inset 0 0 0 5px rgba(0, 0, 0, .18), 0 4px 12px rgba(63, 22, 24, .4); }
.invite-surface[data-theme="vermilion"] .envelope-card h1 i { color: var(--deep); }
.invite-surface[data-theme="vermilion"] .contact { border-top: 1px solid var(--hairline); }

/* 晨雾花园：柔和编辑感 */
.invite-surface[data-theme="garden"] .hero-image { border-radius: 3px; }
.invite-surface[data-theme="garden"] .section-heading h2 { letter-spacing: .02em; }

/* 章节与分隔材质 */
.invite-surface .invite-section#gallery,
.invite-surface .invite-section#contact { border-top: 1px solid var(--hairline); }

/* ---------- 13. 信封开启精修（S3 → P5 简化三拍） ---------- */
.envelope {
  overflow: hidden;
  isolation: isolate;
  display: grid; place-items: center;
  min-height: 100dvh;
  padding: clamp(28px, 6vw, 60px);
  background: linear-gradient(180deg,
    color-mix(in srgb, var(--paper) 96%, transparent),
    color-mix(in srgb, var(--accent) 8%, var(--paper)));
}
/* 信封背景流动光晕(微动画) */
.envelope::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(60% 50% at 18% 22%, color-mix(in srgb, var(--accent) 16%, transparent), transparent 70%),
    radial-gradient(50% 45% at 84% 78%, color-mix(in srgb, var(--flora-gem, var(--accent)) 14%, transparent), transparent 72%);
  filter: blur(4px);
  animation: env-breathe 6s ease-in-out infinite;
}
@keyframes env-breathe {
  0%, 100% { transform: scale(1) rotate(0); opacity: 1; }
  50% { transform: scale(1.04) rotate(.6deg); opacity: .85; }
}

/* 中央信封卡:精致质感 */
.envelope-card {
  position: relative;
  width: min(100%, 460px);
  padding: clamp(40px, 6vw, 64px) clamp(28px, 5vw, 48px) clamp(34px, 5vw, 50px);
  display: flex; flex-direction: column; align-items: center; text-align: center;
  background:
    radial-gradient(120% 80% at 50% 0%, color-mix(in srgb, var(--paper) 100%, white), var(--paper)),
    var(--paper);
  border: 1px solid color-mix(in srgb, var(--accent) 60%, transparent);
  border-radius: 3px;
  box-shadow:
    inset 0 0 0 1px color-mix(in srgb, var(--accent) 22%, transparent),
    inset 0 0 0 6px color-mix(in srgb, var(--paper) 92%, transparent),
    0 30px 70px -28px color-mix(in srgb, var(--deep, #251e1a) 55%, transparent),
    0 12px 28px -18px color-mix(in srgb, var(--deep, #251e1a) 35%, transparent);
  transition: transform .35s var(--ease-out), box-shadow .35s;
  cursor: pointer;
  user-select: none;
}
.envelope-card:hover { transform: translateY(-4px); box-shadow:
  inset 0 0 0 1px color-mix(in srgb, var(--accent) 30%, transparent),
  inset 0 0 0 6px color-mix(in srgb, var(--paper) 92%, transparent),
  0 40px 90px -28px color-mix(in srgb, var(--deep, #251e1a) 60%, transparent),
  0 16px 32px -16px color-mix(in srgb, var(--deep, #251e1a) 40%); }
.envelope-card:active { transform: translateY(-1px) scale(.997); }

/* 内层金色细线(信封四角装饰) */
.envelope-edge {
  position: absolute; inset: 14px; pointer-events: none;
  border: 1px solid color-mix(in srgb, var(--accent) 45%, transparent);
  border-radius: 1px;
}
.envelope-edge::before, .envelope-edge::after {
  content: ""; position: absolute; width: 12px; height: 12px;
  border: 1px solid var(--accent);
}
.envelope-edge::before { top: -1px; left: -1px; border-right: 0; border-bottom: 0; }
.envelope-edge::after  { bottom: -1px; right: -1px; border-left: 0; border-top: 0; }

/* 标题字号 + 间距微调 */
.envelope-card .eyebrow {
  font-family: Georgia, "Times New Roman", serif;
  letter-spacing: .4em; font-size: 12px;
  color: color-mix(in srgb, var(--accent) 88%, transparent);
  margin: 0 0 14px;
}
.envelope-card h1 {
  max-width: 360px;
  font-family: var(--font-display); font-weight: 600;
  font-size: clamp(28px, 5vw, 38px); line-height: 1.45;
  letter-spacing: .04em;
  margin: 0 0 12px;
}
.envelope-card h1 i {
  display: block; margin: 4px 0;
  color: var(--accent); font-style: italic;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 400; font-size: 22px; letter-spacing: .5em;
}
.envelope-divider {
  width: 56px; height: 1px; margin: 6px auto 16px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
}
.envelope-meta {
  max-width: 320px; margin: 0 auto 6px;
  font-size: 14px; line-height: 1.85;
  color: color-mix(in srgb, var(--ink) 78%, var(--muted));
}
.envelope-guest {
  margin: 12px 0 22px;
  font-family: var(--font-display); font-weight: 500;
  color: var(--accent); font-size: 15px;
  letter-spacing: .35em; text-indent: .35em;
}

/* 蜡封(红色 囍) */
.wax-seal {
  width: 78px; height: 78px; margin: 8px 0 4px;
  display: grid; place-items: center;
  filter: drop-shadow(0 6px 12px rgba(120, 14, 6, .35));
  animation: seal-pulse 3.2s ease-in-out infinite;
}
.wax-seal .seal { width: 100%; height: 100%; }
@keyframes seal-pulse {
  0%, 100% { transform: scale(1) rotate(-2deg); }
  50% { transform: scale(1.04) rotate(-1deg); }
}

/* "轻触开启"提示 + 手指图标 + 光圈涟漪 */
.envelope-tap-hint {
  margin-top: 18px;
  display: inline-flex; align-items: center; gap: 10px;
  padding: 8px 18px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 10%, transparent);
  border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent);
  color: color-mix(in srgb, var(--accent) 95%, var(--ink));
  font-family: var(--font-num), serif;
  font-size: 13px; letter-spacing: .25em; text-indent: .25em;
  position: relative;
  animation: tap-breathe 2.4s ease-in-out infinite;
}
.envelope-tap-hint .tap-icon {
  display: inline-grid; place-items: center;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--accent); color: var(--paper);
  font-size: 13px; line-height: 1;
  transform: translateY(-1px);
}
.envelope-tap-hint .tap-text { font-style: italic; }
/* 涟漪(两层错峰) */
.envelope-tap-hint::before, .envelope-tap-hint::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit;
  border: 1px solid var(--accent); pointer-events: none;
  animation: tap-ripple 2.4s ease-out infinite;
  opacity: 0;
}
.envelope-tap-hint::after { animation-delay: 1.2s; }
@keyframes tap-breathe {
  0%, 100% { transform: translateY(0); box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 30%, transparent); }
  50%      { transform: translateY(-1px); box-shadow: 0 0 0 6px color-mix(in srgb, var(--accent) 0%, transparent); }
}
@keyframes tap-ripple {
  0%   { transform: scale(1); opacity: .55; }
  100% { transform: scale(1.35); opacity: 0; }
}

/* 打开动画:信封卡片整体上旋消失 + 蜡封破裂闪光 */
.envelope.is-opening .wax-seal { animation: v2-seal .55s var(--ease-out) forwards; }
.envelope.is-opening .envelope-card { animation: v2-open .8s var(--ease-out) .1s forwards; }
.envelope.is-opening::after {
  content: ""; position: absolute; left: 50%; top: 50%; width: 0; height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: 0; transform: translateX(-50%);
  animation: v2-beam .55s var(--ease-out) .18s forwards; pointer-events: none;
}
.envelope.is-opening .envelope-tap-hint { animation: tap-out .4s ease-out forwards; }

/* ===== 12C. 心形开门按钮(取代原 .envelope-tap-hint 「轻触开启」胶囊) ===== */
.envelope-heart {
  margin: 22px 0 4px;
  display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
  padding: 8px 12px;
  background: transparent;
  border: 0;
  cursor: pointer;
  color: var(--heart-color, #e8445a);
  font: inherit;
  -webkit-tap-highlight-color: transparent;
  outline: none;
}
.envelope-heart__svg {
  display: block;
  width: 64px; height: 64px;
  filter:
    drop-shadow(0 0 8px color-mix(in srgb, var(--heart-color) 60%, transparent))
    drop-shadow(0 4px 8px rgba(160, 20, 30, .25));
  transition: transform .25s ease, filter .25s ease;
  animation: env-heart-beat 1.6s ease-in-out infinite;
}
.envelope-heart:hover .envelope-heart__svg,
.envelope-heart:focus-visible .envelope-heart__svg {
  transform: scale(1.1);
  filter:
    drop-shadow(0 0 14px color-mix(in srgb, var(--heart-color) 80%, transparent))
    drop-shadow(0 6px 12px rgba(160, 20, 30, .35));
}
.envelope-heart:active .envelope-heart__svg { transform: scale(.94); }
.envelope-heart__svg svg { width: 100%; height: 100%; overflow: visible; }
.envelope-heart__svg svg path {
  fill: url(#envelope-heart-grad);
  stroke: rgba(255, 255, 255, .45);
  stroke-width: 1.2;
}
.envelope-heart__label {
  font-family: var(--font-num), serif;
  font-size: 12px; letter-spacing: .32em; text-indent: .32em;
  color: color-mix(in srgb, var(--heart-color) 88%, var(--ink));
  animation: env-heart-label 1.8s ease-in-out infinite;
}
@keyframes env-heart-beat {
  0%, 100% { transform: scale(1); }
  14%      { transform: scale(1.16); }
  28%      { transform: scale(.97); }
  42%      { transform: scale(1.08); }
  56%      { transform: scale(.99); }
}
@keyframes env-heart-label {
  0%, 100% { opacity: .65; }
  50%      { opacity: 1; }
}
/* 主题色映射 */
.invite-surface[data-theme="garden"] .envelope-heart { --heart-color: #e8445a; }
.invite-surface[data-theme="soiree"] .envelope-heart { --heart-color: #ff6b88; }
.invite-surface[data-theme="vermilion"] .envelope-heart { --heart-color: #ff3855; }
/* 开门放大退出 */
.envelope.is-opening .envelope-heart__svg { animation: env-heart-pop .8s var(--ease-out) forwards; }
.envelope.is-opening .envelope-heart__label { animation: tap-out .35s ease-out forwards; }
@keyframes env-heart-pop {
  0%   { transform: scale(1); }
  40%  { transform: scale(1.5); filter: drop-shadow(0 0 24px rgba(232, 37, 63, .9)); }
  100% { transform: scale(2.4); opacity: 0; filter: drop-shadow(0 0 60px rgba(232, 37, 63, 1)); }
}
@media (prefers-reduced-motion: reduce) {
  .envelope-heart__svg,
  .envelope-heart__label { animation: none !important; }
}

@keyframes tap-out {
  to { opacity: 0; transform: translateY(8px) scale(.92); }
}
@keyframes v2-seal {
  0% { transform: scale(1) rotate(-2deg); opacity: 1; filter: drop-shadow(0 6px 12px rgba(120, 14, 6, .35)); }
  35% { transform: scale(1.18) rotate(8deg); opacity: 1; }
  100% { transform: scale(2.1) rotate(20deg); opacity: 0; filter: drop-shadow(0 0 60px rgba(200, 48, 42, .9)); }
}
@keyframes v2-open {
  from { opacity: 1; transform: none; }
  to   { opacity: 0; transform: translateY(-72px) rotateX(14deg) scale(.96); }
}
@keyframes v2-beam {
  0% { width: 0; opacity: .9; }
  100% { width: min(46vw, 420px); opacity: 0; }
}
.invite-content.is-open { animation: v2-appear .6s var(--ease-out); }
@keyframes v2-appear { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

/* ---------- 14. 相册溶解过渡（S4） ---------- */
.gallery-story .gallery-item { transition: opacity .7s var(--ease-io), transform .7s var(--ease-io); }

/* ---------- 15. 字体栈补全 + 首屏逐层入场（S2/S3） ---------- */
:root { font-family: "Noto Serif SC", "Songti SC", SimSun, "宋体", STSong, serif; }

.invite-surface[data-motion="on"] .hero-copy.reveal:not(.is-in) > * { opacity: 0; transform: translateY(20px); }
.invite-surface[data-motion="on"] .hero-copy.reveal.is-in > * {
  opacity: 1; transform: none;
  transition: opacity .8s var(--ease-out), transform .8s var(--ease-out);
}
.invite-surface[data-motion="on"] .hero-copy.reveal.is-in > *:nth-child(2) { transition-delay: .1s; }
.invite-surface[data-motion="on"] .hero-copy.reveal.is-in > *:nth-child(3) { transition-delay: .2s; }
.invite-surface[data-motion="on"] .hero-copy.reveal.is-in > *:nth-child(4) { transition-delay: .3s; }
.invite-surface[data-motion="on"] .hero-copy.reveal.is-in > *:nth-child(5) { transition-delay: .4s; }
.invite-surface[data-motion="on"] .hero-copy.reveal.is-in > *:nth-child(6) { transition-delay: .5s; }

@media (prefers-reduced-motion: reduce) {
  .invite-surface[data-motion="on"] .hero-copy.reveal > * {
    opacity: 1 !important; transform: none !important; transition: none !important;
  }
}

/* ---------- 16. 每套主题的氛围材质（S2，纯 CSS/SVG 离线近似位图纹理） ---------- */
/* 晨雾花园：纸面左上自然高光 + 右下枝叶淡绿晕染 */
.invite-surface[data-theme="garden"] {
  background-image:
    radial-gradient(90% 60% at 80% 8%, rgba(255, 255, 255, .4), transparent 62%),
    radial-gradient(70% 50% at 8% 92%, rgba(167, 182, 167, .16), transparent 60%);
}
/* 星夜晚宴：暗场右上的黄铜聚光 + 底部勃艮第暗晕 */
.invite-surface[data-theme="soiree"] {
  background-image:
    radial-gradient(80% 55% at 82% 6%, rgba(200, 157, 93, .1), transparent 62%),
    radial-gradient(65% 45% at 15% 95%, rgba(104, 77, 92, .18), transparent 65%);
}
/* 朱砂喜宴：宣纸顶部古金淡染 + 极淡朱砂底色过渡 */
.invite-surface[data-theme="vermilion"] {
  background-image:
    radial-gradient(75% 48% at 50% -4%, rgba(184, 135, 63, .08), transparent 62%),
    linear-gradient(180deg, rgba(85, 32, 34, .05), transparent 34%);
}

/* ---------- 17. 婚礼信息模块（P1） ---------- */
.invite-section.wedding { padding-top: 120px; padding-bottom: 110px; }
.wedding-layout {
  display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(320px, .95fr);
  gap: clamp(36px, 6vw, 96px); align-items: center;
  max-width: 1200px; width: 100%; margin-inline: auto;
}

/* ---------- 酒店信息模块 ---------- */
.hotel-layout {
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(280px, .85fr);
  gap: clamp(28px, 5vw, 84px); align-items: start;
  max-width: 1200px; width: 100%; margin-inline: auto;
}
.hotel-info { min-width: 0; }
.hotel-name {
  font-family: var(--font-display); font-weight: 500; font-size: clamp(24px, 3vw, 36px);
  letter-spacing: .02em; margin: 0 0 12px;
  padding-bottom: 14px; border-bottom: 1px solid var(--hairline);
}
.hotel-desc { color: var(--muted); line-height: 1.75; margin: 0 0 18px; font-size: 14px; }
.hotel-lines { list-style: none; margin: 0 0 22px; padding: 0; display: grid; gap: 12px; }
.hotel-lines li {
  display: grid; grid-template-columns: 56px 1fr; gap: 8px; align-items: baseline;
  font-size: 14px; line-height: 1.7;
}
.hotel-label {
  color: var(--muted); font-size: 12px; letter-spacing: .2em;
  text-transform: uppercase; font-family: var(--font-num);
}
.hotel-lines a { color: var(--accent); text-decoration: none; }
.hotel-lines a:hover { text-decoration: underline; }
.hotel-actions { display: flex; gap: 8px; flex-wrap: wrap; }

.hotel-gallery {
  position: relative; margin: 0;
}
.hotel-rail {
  display: flex; gap: 12px; overflow-x: auto; padding: 4px 4px 14px;
  scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.hotel-rail::-webkit-scrollbar { display: none; }
.hotel-tile {
  flex: none; width: min(78vw, 320px); aspect-ratio: 4 / 3; scroll-snap-align: center;
  border: 1px solid var(--hairline); border-radius: 4px; padding: 0; background: var(--wash);
  overflow: hidden; cursor: pointer;
  transition: transform .25s var(--ease-out), border-color .25s;
}
.hotel-tile:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--accent) 50%, transparent); }
.hotel-tile img { width: 100%; height: 100%; object-fit: cover; display: block; }

.hotel-controls {
  display: flex; align-items: center; justify-content: center; gap: 10px; margin-top: 12px;
}
.hotel-arrow {
  width: 32px; height: 32px; border-radius: 50%; border: 1px solid var(--hairline); background: transparent;
  color: var(--ink); cursor: pointer; font-size: 14px;
  transition: border-color .2s, background .2s;
}
.hotel-arrow:hover { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 10%, transparent); }
.hotel-dots { display: flex; gap: 6px; align-items: center; }
.hotel-dots button {
  width: 6px; height: 6px; border-radius: 50%; border: 0; padding: 0;
  background: color-mix(in srgb, var(--ink) 22%, transparent);
  transition: width .25s var(--ease-out), background .25s;
}
.hotel-dots button.is-active { width: 18px; background: var(--accent); border-radius: 3px; }

@media (max-width: 720px) {
  .hotel-layout { grid-template-columns: 1fr; gap: 22px; }
  .hotel-tile { width: min(86vw, 360px); }
}
@media (prefers-reduced-motion: reduce) {
  .hotel-tile { transition: none; }
}

/* ---------- THE DAY 大卡 + 酒店信息卡(统一卡片视觉,P5+ 重构) ---------- */
.day-card {
  position: relative; max-width: 980px; width: 100%; margin: 0 auto;
  padding: clamp(28px, 4vw, 48px);
  background: var(--paper);
  border: 1px solid var(--hairline);
  border-radius: 6px;
  box-shadow: 0 36px 72px -56px color-mix(in srgb, var(--ink) 40%, transparent);
}
.invite-surface[data-theme="garden"] .day-card {
  background: color-mix(in srgb, var(--paper) 96%, var(--accent));
  border-color: color-mix(in srgb, var(--accent) 30%, var(--hairline));
  box-shadow: 0 36px 72px -56px color-mix(in srgb, var(--accent) 60%, transparent);
}
.invite-surface[data-theme="soiree"] .day-card {
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  border-color: rgba(200, 157, 93, .35);
  box-shadow: 0 36px 72px -56px rgba(0, 0, 0, .8);
}
.invite-surface[data-theme="vermilion"] .day-card {
  background: color-mix(in srgb, var(--paper) 92%, var(--wash));
  border-color: rgba(184, 135, 63, .35);
  box-shadow: 0 36px 64px -52px rgba(63, 22, 24, .5);
}
.day-card::before {
  content: ''; position: absolute; inset: 8px; border: 1px solid var(--hairline);
  border-radius: 4px; pointer-events: none;
  opacity: .55;
}
.day-card-top {
  display: grid; grid-template-columns: minmax(0, 1fr) auto;
  gap: clamp(20px, 4vw, 40px); align-items: center;
  padding-bottom: 22px; border-bottom: 1px solid var(--hairline);
}
.day-card-date { min-width: 0; }
.day-big {
  margin: 0 0 6px;
  font-family: var(--font-display); font-weight: 500;
  font-size: clamp(28px, 4vw, 42px); letter-spacing: .04em;
  color: var(--ink); font-variant-numeric: lining-nums;
}
.day-big em {
  font-style: normal; font-family: var(--font-num); font-size: .55em;
  margin-left: 8px; color: var(--accent); letter-spacing: .2em;
}
.day-card-time {
  margin: 0; font-family: var(--font-num); font-size: 14px; color: var(--muted);
  font-variant-numeric: tabular-nums; letter-spacing: .06em;
}
.day-card-countdown { min-width: 0; }
.countdown {
  display: grid; grid-template-columns: repeat(4, minmax(56px, 1fr));
  gap: 6px;
}
.countdown-cell {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 14px 8px; min-width: 64px;
  border-radius: 4px;
  background: var(--wash);
  border: 1px solid var(--hairline);
}
.countdown-cell strong {
  font-family: var(--font-num); font-weight: 500;
  font-size: clamp(22px, 3vw, 30px); line-height: 1;
  color: var(--accent); font-variant-numeric: lining-nums;
  letter-spacing: .04em;
}
.countdown-cell span {
  font-size: 11px; color: var(--muted); letter-spacing: .24em;
  text-transform: uppercase;
}
.countdown-ended {
  margin: 0; font-family: var(--font-display); font-size: 16px; color: var(--accent);
  letter-spacing: .12em;
}
.invite-surface[data-theme="garden"] .countdown-cell {
  background: color-mix(in srgb, var(--wash) 90%, var(--paper));
}
.invite-surface[data-theme="soiree"] .countdown-cell {
  background: rgba(0, 0, 0, .35); border-color: rgba(200, 157, 93, .35);
  backdrop-filter: blur(4px);
}
.invite-surface[data-theme="soiree"] .countdown-cell span { color: rgba(241, 236, 227, .65); }
.invite-surface[data-theme="vermilion"] .countdown-cell {
  background: color-mix(in srgb, var(--wash) 85%, var(--paper));
  border-color: rgba(184, 135, 63, .4);
}

.day-card-mid {
  padding: 18px 0 22px; border-bottom: 1px solid var(--hairline);
  display: grid; gap: 8px;
}
/* 婚礼信息模块内的喜字印章:夹在 day-card-top 和 day-card-mid 之间,居中 */
.day-card-seal {
  display: flex; justify-content: center; align-items: center;
  margin: 18px auto 4px;
}
.day-card-seal .seal {
  width: 48px; height: 48px;
  border-radius: 2px;
  font-size: 22px;
}
.day-card-mid .event-line {
  display: grid; grid-template-columns: 64px 1fr; gap: 8px; align-items: baseline;
  padding: 6px 0;
}
.event-label {
  color: var(--accent); font-size: 12px; letter-spacing: .24em; text-transform: uppercase;
  font-family: var(--font-num);
}
.wedding-sub {
  margin: 24px 0 12px; font-size: 12px; color: var(--muted);
  letter-spacing: .24em; text-transform: uppercase; font-weight: 500;
}
.wedding-timeline { position: relative; padding-top: 4px; }
.schedule { list-style: none; margin: 0; padding: 0; position: relative; }
.schedule::before {
  content: ''; position: absolute; left: 38px; top: 8px; bottom: 8px;
  width: 1px; background: var(--hairline); opacity: .65;
}
.schedule-item {
  display: grid; grid-template-columns: 56px 1fr; gap: 24px; align-items: baseline;
  padding: 10px 0 10px 0;
  position: relative;
}
.schedule-item::before {
  content: ''; position: absolute; left: 33px; top: 18px;
  width: 11px; height: 11px; border-radius: 50%;
  background: var(--paper); border: 2px solid var(--accent);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 14%, transparent);
}
.schedule-item.is-last::before { background: var(--accent); }
.schedule-time {
  font-family: var(--font-num); font-variant-numeric: tabular-nums;
  letter-spacing: .04em; color: var(--accent); font-size: 14px;
}
.schedule-title { color: var(--ink); font-size: 15px; line-height: 1.6; }
.invite-surface[data-theme="soiree"] .schedule::before { background: rgba(200, 157, 93, .25); }

.venue-figure { margin: 22px 0 0; }
.venue-figure img {
  width: 100%; aspect-ratio: 16 / 10; object-fit: cover; border-radius: 4px;
  border: 1px solid var(--hairline); box-shadow: 0 28px 56px -40px rgba(0, 0, 0, .5);
}
.map-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.map-actions .button.small { min-height: 36px; padding: 7px 16px; font-size: 13px; }

/* 合并:当酒店作为婚礼场地时,场地信息合并到 wedding 卡的同一模块 */
.day-card-venue {
  margin: 6px 0 0;
  padding: 22px 0 8px;
  border-top: 1px solid var(--hairline);
  display: grid; gap: 18px;
}
.day-card-venue-info {
  display: grid; gap: 12px;
  font-family: "Songti SC", "Noto Serif SC", serif;
  text-align: center;
}
.venue-name {
  font-family: var(--font-display); font-weight: 500;
  font-size: clamp(22px, 2.8vw, 30px); letter-spacing: .04em;
  margin: 0;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--hairline);
  display: inline-block;
  align-self: center;
  position: relative;
}
.venue-name::before, .venue-name::after {
  content: ""; position: absolute; top: 50%; width: 16px; height: 1px;
  background: var(--accent); opacity: .55;
}
.venue-name::before { right: 100%; margin-right: 12px; }
.venue-name::after { left: 100%; margin-left: 12px; }
.venue-desc {
  color: color-mix(in srgb, var(--ink) 84%, var(--muted));
  line-height: 1.85; margin: 0 auto; font-size: 15px;
  max-width: 540px;
}
.venue-lines {
  list-style: none; margin: 0 auto; padding: 0;
  display: grid; gap: 8px; max-width: 460px;
  font-size: 14px;
}
.venue-lines li {
  display: grid; grid-template-columns: 60px 1fr; gap: 12px;
  align-items: baseline;
}
.venue-label {
  text-align: justify; text-align-last: justify;
  font-size: 12px; letter-spacing: .4em;
  color: var(--muted); padding-right: 4px;
  font-family: var(--font-num), serif;
}
.venue-lines li > span:last-child,
.venue-lines li > a {
  font-size: 15px; color: var(--ink); letter-spacing: .04em;
  text-decoration: none; word-break: break-word;
}
.venue-lines li a:hover { color: var(--accent); }
.venue-actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; margin-top: 4px; }
/* 当 wedding 模块作为场地时,把 eyebrow "THE DAY · THE VENUE" 视觉强调 */
.invite-section.wedding.is-venue .eyebrow {
  color: var(--accent);
}
/* 桌面:场地图与场地信息并排 */
@media (min-width: 760px) {
  .day-card-venue { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); align-items: start; }
  .day-card-venue .day-card-media { margin: 0; }
  .day-card-venue-info { text-align: left; padding-top: 4px; }
  .venue-desc { margin-left: 0; }
  .venue-actions { justify-content: flex-start; }
}

/* 酒店信息模块复用 day-card */
.day-card-media { margin: -8px -8px 22px; }
.day-card-media .hotel-gallery { margin: 0; }
.day-card-media .hotel-rail { padding: 4px; }
.hotel-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }

.invite-section.hotel .hotel-name {
  font-family: var(--font-display); font-weight: 500;
  font-size: clamp(22px, 2.6vw, 30px); letter-spacing: .02em;
  margin: 0 0 12px; padding-bottom: 12px; border-bottom: 1px solid var(--hairline);
}
.invite-section.hotel .hotel-desc {
  color: var(--muted); line-height: 1.75; margin: 0 0 18px; font-size: 14px;
}
.invite-section.hotel .hotel-lines {
  list-style: none; margin: 0 0 6px; padding: 0; display: grid; gap: 10px;
}
.invite-section.hotel .hotel-lines li {
  display: grid; grid-template-columns: 56px 1fr; gap: 8px; align-items: baseline;
  font-size: 14px; line-height: 1.7;
}

@media (max-width: 820px) {
  .day-card-top { grid-template-columns: 1fr; gap: 16px; align-items: start; }
  .day-card-countdown { justify-self: start; }
  .countdown { grid-template-columns: repeat(4, minmax(58px, 1fr)); width: 100%; }
  .invite-section.wedding { padding-top: 84px; }
}
@media (max-width: 480px) {
  .day-card { padding: 22px 18px; }
  .schedule-item { grid-template-columns: 52px 1fr; gap: 16px; }
  .schedule-item::before { left: 31px; }
  .schedule::before { left: 36px; }
}

/* ---------- 17b. 编辑台：婚礼信息表单（P1） ---------- */
.schedule-editor { display: grid; gap: 8px; margin-top: 12px; }
.schedule-row { display: grid; grid-template-columns: 84px 1fr auto; gap: 8px; align-items: center; }
.schedule-row input { min-width: 0; }
.venue-preview { max-width: 220px; margin-top: 8px; border: 1px solid var(--line); border-radius: 4px; }
.venue-preview img { width: 100%; display: block; border-radius: 4px; }

/* ---------- 18. 新人介绍 / 恋爱历程模块（P2） ---------- */
.couple-grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(28px, 5vw, 72px); max-width: 1080px; margin-inline: auto; align-items: start;
}
.person-card { display: grid; justify-items: center; text-align: center; }
.person-photo {
  width: min(100%, 380px); aspect-ratio: 4 / 5; overflow: hidden;
  background: var(--wash); border-radius: 4px;
  border: 1px solid var(--hairline);
}
.person-photo img { width: 100%; height: 100%; object-fit: cover; }
.person-photo-empty { display: grid; place-items: center; color: var(--accent); font-size: 44px; }
.person-meta h3 {
  margin: 20px 0 8px; font-family: var(--font-display);
  font-size: clamp(22px, 3vw, 32px); font-weight: 600;
}
.person-quote { color: var(--accent); font-size: 15px; letter-spacing: .04em; }
.person-bio { color: var(--muted); font-size: 14px; line-height: 1.9; max-width: 430px; }
.person-tags {
  display: flex; flex-wrap: wrap; gap: 8px; justify-content: center;
  padding: 0; margin: 16px 0 0; list-style: none;
}
.person-tags li {
  padding: 5px 13px; border: 1px solid var(--hairline);
  border-radius: 999px; font-size: 12px; color: var(--muted);
}

.story { position: relative; }
.story-timeline { list-style: none; margin: 0 auto; padding: 6px 0 0; max-width: 1000px; position: relative; }
.story-timeline::before {
  content: ""; position: absolute; top: 8px; bottom: 8px; left: calc(50% - 1px);
  width: 2px; background: color-mix(in srgb, var(--accent) 30%, transparent);
}
.story-item { position: relative; padding: 8px 0 34px; }
.story-item:nth-child(odd) { padding-right: calc(50% + 36px); text-align: right; }
.story-item:nth-child(even) { padding-left: calc(50% + 36px); }
.story-dot {
  position: absolute; top: 16px; left: calc(50% - 7px); width: 14px; height: 14px;
  border-radius: 50%; border: 2px solid var(--accent); background: var(--paper);
  box-sizing: border-box;
}
.story-item.is-last .story-dot {
  background: var(--accent);
  box-shadow: 0 0 0 5px color-mix(in srgb, var(--accent) 22%, transparent);
}
.story-card { display: inline-block; text-align: left; max-width: 430px; }
.story-item time {
  display: block; margin-bottom: 6px; color: var(--accent);
  font-family: var(--font-num); letter-spacing: .14em; font-size: 14px;
}
.story-card h3 {
  margin: 0 0 8px; font-family: var(--font-display);
  font-size: clamp(19px, 2.4vw, 26px); font-weight: 600;
}
.story-card p { margin: 0; color: var(--muted); line-height: 1.85; font-size: 15px; }
.story-photo { margin: 12px 0 0; }
.story-photo img {
  width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 3px;
  border: 1px solid var(--hairline);
}
@media (max-width: 720px) {
  .couple-grid { grid-template-columns: 1fr; gap: 40px; }
  .story-timeline::before { left: 10px; }
  .story-item:nth-child(odd), .story-item:nth-child(even) {
    padding: 0 0 30px 44px; text-align: left;
  }
  .story-dot { left: 4px; }
  .story-card { max-width: none; }
}

/* ---------- 18b. 编辑台：新人介绍 / 恋爱历程（P2） ---------- */
.couple-panel { border: 1px solid var(--line); border-radius: 4px; padding: 14px; margin: 0 0 14px; background: #fff; }
.couple-panel legend { color: var(--accent); font-size: 13px; padding: 0 6px; }
.cp-thumb, .story-thumb { width: 72px; aspect-ratio: 1; object-fit: cover; border-radius: 4px; border: 1px solid var(--line); }
.story-fields { display: grid; gap: 8px; min-width: 0; }
.story-file-line { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); flex-wrap: wrap; }
.story-file-line em { color: var(--muted); font-style: normal; }
.story-admin-row { grid-template-columns: minmax(0, 1fr) auto; }

/* ---------- 19. 祝福墙模块（P3） ---------- */
.invite-section.blessings { padding-top: 120px; padding-bottom: 110px; }
.blessing-wrap {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(28px, 5vw, 72px); max-width: 1200px; margin-inline: auto; align-items: start;
}
.blessing-compose {
  border: 1px solid var(--hairline); border-radius: 4px; padding: 22px;
  background: color-mix(in srgb, var(--paper) 76%, transparent);
}
.blessing-tip { color: var(--muted); font-size: 13px; margin: 0 0 12px; }

/* V4 自动翻页的预置祝福(无按钮,手机上下铺满,桌面多列) */
.blessing-rotator {
  position: relative; min-height: 178px; margin-bottom: 14px;
}
.blessing-pages {
  display: grid; gap: 8px;
  grid-template-columns: 1fr 1fr;             /* 默认两列(平板也安全) */
}
.blessing-pages.is-enter > .blessing-rotator-card {
  animation: rotator-in .55s var(--ease-out) both;
}
.blessing-pages.is-enter > .blessing-rotator-card:nth-child(2) { animation-delay: .04s; }
.blessing-pages.is-enter > .blessing-rotator-card:nth-child(3) { animation-delay: .08s; }
.blessing-pages.is-enter > .blessing-rotator-card:nth-child(4) { animation-delay: .12s; }
.blessing-pages.is-enter > .blessing-rotator-card:nth-child(5) { animation-delay: .16s; }
.blessing-pages.is-enter > .blessing-rotator-card:nth-child(6) { animation-delay: .20s; }
@keyframes rotator-in {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: none; }
}
.blessing-rotator-card {
  display: grid; grid-template-columns: 1fr auto; gap: 6px 10px; align-items: end;
  text-align: left; padding: 10px 12px; min-height: 64px;
  border: 1px solid var(--hairline); border-radius: 6px;
  background: color-mix(in srgb, var(--paper) 72%, transparent);
  color: var(--ink); font: inherit; line-height: 1.55;
  transition: transform .2s var(--ease-out), background .2s, border-color .2s, box-shadow .2s;
}
.blessing-rotator-card:hover {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--accent) 55%, transparent);
  background: color-mix(in srgb, var(--accent) 10%, var(--paper));
  box-shadow: 0 10px 20px -16px color-mix(in srgb, var(--accent) 60%, transparent);
}
.blessing-rotator-card-text {
  font-size: 14px; line-height: 1.55;
}
.blessing-rotator-card-tag {
  font-size: 11px; color: var(--accent); font-style: normal; letter-spacing: .12em;
  border: 1px solid color-mix(in srgb, var(--accent) 45%, transparent);
  border-radius: 999px; padding: 1px 7px; align-self: start; justify-self: end;
  white-space: nowrap;
}
.blessing-dots {
  display: flex; gap: 5px; justify-content: center; margin-top: 10px; min-height: 6px;
}
.blessing-dot {
  width: 5px; height: 5px; border-radius: 50%;
  background: color-mix(in srgb, var(--ink) 22%, transparent);
  transition: width .25s var(--ease-out), background .25s;
}
.blessing-dot.is-active { width: 16px; background: var(--accent); border-radius: 3px; }
/* 用户开始打字/输入框聚焦 → 翻页停,但保留当前页可见 */
.blessing-rotator.is-paused .blessing-dots { opacity: .4; }
@media (min-width: 880px) {
  .blessing-pages { grid-template-columns: repeat(3, 1fr); }   /* 桌面三列 */
}
@media (max-width: 480px) {
  .blessing-pages { grid-template-columns: 1fr; }              /* 手机单列,上下排列 */
  .blessing-rotator-card { min-height: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .blessing-pages.is-enter > .blessing-rotator-card { animation: none; }
  .blessing-rotator { display: none; }
}
.blessing-text {
  width: 100%; border: 1px solid var(--hairline); border-radius: 4px; color: inherit;
  padding: 10px; font: inherit; resize: vertical;
  background: color-mix(in srgb, var(--paper) 62%, transparent);
}
.blessing-submit-line { display: flex; gap: 10px; margin-top: 10px; }
.blessing-submit-line input {
  flex: 1; min-width: 0; border: 1px solid var(--hairline); border-radius: 4px;
  background: transparent; color: inherit; padding: 10px; font: inherit;
}
.blessing-feedback { min-height: 18px; font-size: 13px; color: var(--accent); margin: 8px 0 0; }
.blessing-wall { list-style: none; margin: 0; padding: 0; columns: 2; column-gap: 14px; }
.blessing-card {
  break-inside: avoid; border: 1px solid var(--hairline); border-radius: 4px;
  padding: 12px 14px; margin-bottom: 12px;
  background: color-mix(in srgb, var(--paper) 70%, transparent);
}
.blessing-card p { margin: 0 0 8px; line-height: 1.75; font-size: 14px; }
.blessing-card footer { display: flex; justify-content: space-between; color: var(--accent); font-size: 12px; }
.blessing-card footer span { font-weight: 600; }
.blessing-card footer time { color: var(--muted); }
@media (max-width: 820px) {
  .blessing-wrap { grid-template-columns: 1fr; }
  .blessing-wall { columns: 1; }
}

/* ---------- 19c. 祝福弹幕 + 快捷祝福（用户反馈打磨） ---------- */
.blessing-wrap { grid-template-columns: 1fr; gap: 18px; }
.blessing-compose { max-width: 780px; margin-inline: auto; width: 100%; box-sizing: border-box; }
.blessing-stage {
  position: relative; height: 300px; overflow: hidden; border-radius: 8px;
  border: 1px solid var(--hairline);
  background:
    radial-gradient(120% 120% at 50% -10%, color-mix(in srgb, var(--surface, var(--paper)) 70%, transparent), transparent 72%),
    color-mix(in srgb, var(--paper) 58%, transparent);
}
.blessing-stage.is-paused .danmaku { animation-play-state: paused; }
.blessing-stage-empty {
  position: absolute; inset: 0; margin: 0; display: grid; place-items: center;
  color: var(--muted); font-size: 14px; letter-spacing: .1em;
}
.danmaku {
  position: absolute; left: 100%; top: var(--lane, 20%); white-space: nowrap;
  padding: 7px 17px; border-radius: 999px; font-size: 14px; line-height: 1.4;
  background: color-mix(in srgb, var(--paper) 82%, transparent);
  border: 1px solid var(--hairline); color: var(--ink);
  /* 去掉 box-shadow:动画期间每帧重绘,改用 border 强化存在感 */
  will-change: transform;
  /* 强制 GPU 层,避免父层 mix-blend-mode 引发整表面重绘 */
  transform: translate3d(0, 0, 0);
  backface-visibility: hidden;
  animation: danmaku linear forwards;
  animation-duration: var(--dur, 11s);
  contain: layout paint style;
}
.danmaku.is-new { background: color-mix(in srgb, var(--accent) 14%, var(--paper)); border-color: color-mix(in srgb, var(--accent) 60%, transparent); }
.danmaku b { color: var(--accent); font-weight: 600; margin-left: 10px; font-size: 12px; opacity: .85; }
@keyframes danmaku {
  0%   { transform: translate3d(0, 0, 0); opacity: 0; }
  4%   { opacity: 1; }
  100% { transform: translate3d(-110vw, 0, 0); opacity: 1; }
}
.danmaku-static {
  display: grid; gap: 4px; width: max-content; max-width: 100%;
  border: 1px solid var(--hairline); border-radius: 999px; padding: 9px 18px;
  margin: 8px auto; background: color-mix(in srgb, var(--paper) 80%, transparent);
}
.danmaku-static p { margin: 0; font-size: 14px; line-height: 1.5; white-space: normal; }
.danmaku-static span { color: var(--accent); font-size: 12px; justify-self: end; }
@media (prefers-reduced-motion: reduce) {
  .blessing-stage { height: auto; max-height: 360px; overflow: auto; padding: 8px; }
  .danmaku { position: static; transform: none !important; animation: none !important; width: max-content; max-width: 100%; margin: 6px auto; display: block; }
}

/* 祝福区：允许子项收缩，避免 min-content 撑爆窄屏 */
.blessing-wrap { width: 100%; }
.blessing-wrap > * { min-width: 0; max-width: 100%; }
.blessing-compose { max-width: min(780px, 100%); }
.blessing-submit-line { min-width: 0; }
@media (max-width: 600px) {
  .blessing-compose { padding: 16px 14px; }
  .blessing-submit-line { flex-direction: column; align-items: stretch; }
  .blessing-submit-line .button { width: 100%; }
  .blessing-static-list { max-width: 100%; }
  .danmaku-overlay { top: 46px; }
  .danmaku-overlay .danmaku { font-size: 13px; padding: 6px 13px; }
}
/* ---------- 20. RSVP 回执模块（P4） ---------- */
.invite-section.rsvp { padding-top: 120px; padding-bottom: 110px; }
.rsvp-layout { max-width: 640px; margin-inline: auto; }
.rsvp-form {
  border: 1px solid var(--hairline); border-radius: 4px; padding: 26px 26px 22px;
  background: color-mix(in srgb, var(--paper) 78%, transparent);
  display: grid; gap: 16px;
}
.rsvp-field { display: grid; gap: 8px; }
.rsvp-label { font-size: 14px; color: var(--ink); }
.rsvp-label small { color: var(--muted); font-weight: 400; }
.rsvp-form input[type="text"], .rsvp-form input:not([type]), .rsvp-form select, .rsvp-form textarea {
  width: 100%; border: 1px solid var(--hairline); border-radius: 4px; background: transparent;
  color: inherit; padding: 10px 12px; font: inherit; min-height: 40px;
}
.rsvp-choice, .rsvp-diet { display: flex; flex-wrap: wrap; gap: 8px; }
.rsvp-choice button, .rsvp-diet button {
  border: 1px solid var(--hairline); background: transparent; color: var(--muted);
  border-radius: 999px; padding: 8px 16px; font-size: 13px;
}
.rsvp-choice button.is-active, .rsvp-diet button.is-active {
  border-color: var(--accent); color: var(--paper); background: var(--accent);
}
.rsvp-check { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.rsvp-check input { accent-color: var(--accent); }
.rsvp-privacy { font-size: 12px; color: var(--muted); margin: 0; }
.rsvp-feedback { min-height: 18px; font-size: 13px; color: var(--accent); margin: 0; }
.rsvp-success {
  text-align: center; padding: 46px 20px; border: 1px solid var(--hairline);
  border-radius: 4px; background: color-mix(in srgb, var(--paper) 78%, transparent);
}
.seal-mark {
  display: inline-grid; place-items: center; width: 76px; height: 76px; border-radius: 4px;
  background: var(--deep); color: var(--paper); font-size: 20px; letter-spacing: .3em;
  transform: rotate(-2deg); margin-bottom: 18px;
  box-shadow: inset 0 0 0 5px rgba(0, 0, 0, .14), 0 6px 14px rgba(0, 0, 0, .18);
}
.rsvp-success p { color: var(--muted); font-size: 15px; }
@media (max-width: 720px) { .invite-section.rsvp { padding-top: 84px; } }

/* ---------- 20b. 编辑台：回执管理（P4） ---------- */
.rsvp-summary { display: flex; gap: 10px; flex-wrap: wrap; }
.rsvp-summary .chip {
  border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px;
  font-size: 13px; background: #fff;
}
.rsvp-summary .chip strong { color: var(--accent); margin-left: 4px; }
.rsvp-attend-ok { color: #2e7d4f; }
.rsvp-attend-no { color: #b13d36; }

/* ---------- 21. 红漆印记组件（P5） ---------- */
/* 默认所有喜字印章 = 婚礼红 #c8302a(朱砂红),而不是品牌深色 */
.seal {
  --seal-bg: #c8302a;            /* 喜字主红 */
  --seal-ink: #fff8ec;           /* 喜字上的米色字 */
  display: inline-grid; place-items: center; user-select: none;
  font-family: var(--font-display); flex: none; letter-spacing: .05em;
}
.seal-solid { background: var(--seal-bg); color: var(--seal-ink); }
.seal-stamp {
  width: 34px; height: 34px; border-radius: 2px; font-size: 15px;
  transform: rotate(-2deg);
  box-shadow:
    inset 0 0 0 2px rgba(255, 255, 255, .28),
    inset 0 0 0 3px var(--seal-bg),
    0 6px 14px -8px rgba(120, 14, 6, .55);   /* 红色外发光 */
}
.invitation-seal { display: flex; justify-content: flex-end; margin: -4px 0 16px; }
.seal-mark-lg {
  width: 58px; height: 58px; border-radius: 3px; font-size: 24px; transform: rotate(-2deg);
  box-shadow: inset 0 0 0 5px rgba(0, 0, 0, .12), 0 8px 16px rgba(0, 0, 0, .18);
}
.thanks-seal { margin-top: 20px; display: flex; justify-content: center; }
.seal .seal-char { line-height: 1; }
.story-item.is-last .story-card { padding-bottom: 4px; }

/* ---------- 21b. 编辑台：内容编排（P6 补 P0） ---------- */
.content-switches { display: grid; gap: 8px; margin-bottom: 18px; }
.content-switch {
  display: flex; align-items: center; gap: 12px; padding: 12px 14px;
  border: 1px solid var(--line); border-radius: 4px; background: #fff;
}
.content-switch input { accent-color: var(--accent); width: 18px; height: 18px; }
.content-switch span { display: grid; gap: 2px; }
.content-switch strong { font-size: 14px; font-weight: 500; }
.content-switch small { color: var(--muted); font-size: 12px; }

/* ---------- 22. 全局质感与动效升级（用户反馈打磨） ---------- */
/* 章节标题：居中 + eyebrow 双线饰件 + blur 入场 */
.invite-section .section-heading { text-align: center; margin-bottom: 52px; }
.invite-section .section-heading .eyebrow {
  letter-spacing: .46em; margin-bottom: 20px; padding-left: .46em; text-indent: 0;
}
.invite-section .section-heading .eyebrow::before,
.invite-section .section-heading .eyebrow::after {
  content: ""; display: inline-block; width: 34px; height: 1px;
  vertical-align: middle; margin: 0 0 3px;
  background: linear-gradient(90deg, transparent, var(--accent));
}
.invite-section .section-heading .eyebrow::before { margin-right: 14px; }
.invite-section .section-heading .eyebrow::after { margin-left: 14px; background: linear-gradient(90deg, var(--accent), transparent); }
.invite-section .section-heading h2 { letter-spacing: .02em; }
.invite-surface[data-motion="on"] .section-heading:not(.is-in) h2 {
  opacity: 0; transform: translateY(14px); filter: blur(6px);
}
.invite-surface[data-motion="on"] .section-heading.is-in h2 { animation: v2-heading .9s var(--ease-out) forwards; }
@keyframes v2-heading {
  from { opacity: 0; transform: translateY(14px); filter: blur(6px); }
  to { opacity: 1; transform: none; filter: blur(0); }
}
/* 按钮扫光 */
.button { position: relative; overflow: hidden; }
.button::after {
  content: ""; position: absolute; top: 0; left: -90%; width: 55%; height: 100%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .28), transparent);
  transform: skewX(-18deg); pointer-events: none;
}
.button:hover::after { animation: sheen .85s var(--ease-out); }
@keyframes sheen { to { left: 135%; } }
/* 火漆环纹 */
.wax-seal { position: relative; }
.wax-seal::after {
  content: ""; position: absolute; inset: 5px; border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .22);
}
/* Hero 引导箭头轻柔浮动 */
.hero-next { animation: next-float 2.6s ease-in-out infinite; }
@keyframes next-float { 50% { transform: translateY(7px); } }
/* 新人照片悬停推移；相册相邻间距呼吸 */
.person-photo img { transition: transform 1.3s var(--ease-out); }
.person-photo:hover img { transform: scale(1.045); }
.person-card:nth-child(2) { margin-top: 34px; }
@media (max-width: 720px) { .person-card:nth-child(2) { margin-top: 0; } }
/* 选区与细节 */
.invite-surface ::selection { background: color-mix(in srgb, var(--accent) 32%, transparent); }
@media (prefers-reduced-motion: reduce) {
  .invite-surface[data-motion="on"] .section-heading:not(.is-in) h2 {
    opacity: 1 !important; transform: none !important; filter: none !important;
  }
  .button::after, .hero-next { animation: none !important; }
}

/* ---------- 23. 镜头感与印章开合（用户反馈打磨 II） ---------- */
/* Hero 主视觉：入场微缩放 + 镜头推移（动效时） */
.invite-surface[data-motion="on"] .hero-image.reveal { transform: translateY(24px) scale(1.05); }
.invite-surface[data-motion="on"] .hero-image.reveal.is-in { transform: none; transition: transform 1.4s var(--ease-out); }
/* 相册焦点层次：非焦点弱化仅桌面；焦点更有"台面感" */
@media (min-width: 1000px) {
  .gallery-story .gallery-item { filter: saturate(.82); transition: opacity .7s var(--ease-io), transform .7s var(--ease-io), filter .9s var(--ease-io), box-shadow .7s var(--ease-io); }
  .gallery-story .gallery-item.is-active { filter: saturate(1.05); box-shadow: 0 26px 60px -34px rgba(0, 0, 0, .5); }
}
/* 印章开合：英雄落款 / 结尾署名 / RSVP 收到 */
@keyframes seal-in {
  from { transform: rotate(-9deg) scale(.55); opacity: 0; }
  to { transform: rotate(-2deg) scale(1); opacity: 1; }
}
.invite-surface[data-motion="on"] .hero-copy.reveal.is-in .invitation-seal .seal { animation: seal-in .55s var(--ease-out) .4s both; }
.invite-surface[data-motion="on"] .thanks:has(.reveal.is-in) .thanks-seal .seal { animation: seal-in .55s var(--ease-out) .2s both; }
.rsvp-success .seal-mark { animation: seal-in .5s var(--ease-out) both; }
/* 章节间更舒展的滚动节奏 */
.invite-section { scroll-margin-top: 72px; }
.invite-section.wedding, .invite-section.blessings,
.invite-section.rsvp, .invite-section.story { padding-bottom: 128px; }
@media (prefers-reduced-motion: reduce) {
  .invite-surface[data-motion="on"] .hero-image.reveal,
  .invite-surface[data-motion="on"] .hero-image.reveal.is-in { transform: none; transition: none; }
  .seal, .seal-mark { animation: none !important; }
}

/* ---------- 24. 用户反馈修改（印章真实盖印 / 顶部弹幕 / 首页去重与背景） ---------- */
/* 印章：不再是按钮样式，而是一方真实朱印 */
.invite-surface .seal,
.invite-surface .seal-mark {
  pointer-events: none;
  background: radial-gradient(circle at 32% 24%, #bf4a3d 0%, #98271f 62%, #7e1f18 100%);
  color: #f8eeda;
  border: 0;
  box-shadow:
    inset 0 0 0 2px rgba(248, 238, 218, .5),
    inset 0 0 0 4px rgba(60, 8, 6, .1),
    0 5px 12px rgba(70, 12, 8, .28);
}
/* .seal-solid 在更高特异性下用喜庆红实色覆盖上面的渐变 */
.invite-surface .seal.seal-solid,
.invite-surface .seal-mark.seal-solid {
  background: var(--seal-bg);
  color: var(--seal-ink);
  box-shadow:
    inset 0 0 0 2px rgba(255, 255, 255, .28),
    inset 0 0 0 3px var(--seal-bg),
    0 6px 14px -8px rgba(120, 14, 6, .55);
}
.invite-surface .seal-stamp { font-size: 16px; }
@keyframes seal-in {
  0% { opacity: 0; transform: rotate(-18deg) scale(.2); }
  55% { opacity: 1; transform: rotate(5deg) scale(1.16); }
  80% { transform: rotate(-4deg) scale(.97); }
  100% { opacity: 1; transform: rotate(-3deg) scale(1); }
}
/* 首页去重：单行信息行 */
.hero-meta {
  max-width: 440px; font-size: 14px; color: var(--muted);
  letter-spacing: .05em; line-height: 1.9; margin: 0 0 6px;
}
.hero-invitation { margin-bottom: 14px; }
/* 首页背景：主题光雾 */
.hero { position: relative; }
.hero-aurora {
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(62% 55% at 16% 10%, color-mix(in srgb, var(--accent) 15%, transparent), transparent 62%),
    radial-gradient(52% 46% at 88% 20%, color-mix(in srgb, var(--wash) 34%, transparent), transparent 64%),
    radial-gradient(80% 64% at 52% 100%, color-mix(in srgb, var(--accent) 9%, transparent), transparent 72%);
}
.hero .hero-copy, .hero .hero-image { position: relative; z-index: 1; }
/* 顶部工具条按钮组 + 弹幕开关 */
.tool-group { display: inline-flex; gap: 8px; align-items: center; }
.danmaku-toggle { font-size: 13px; letter-spacing: 0; }
.danmaku-toggle.is-on {
  color: var(--paper); background: var(--accent);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 22%, transparent);
}
/* 视频式顶部弹幕：半透明、悬浮、不拦截交互 */
.danmaku-overlay {
  position: fixed; top: 54px; left: 0; right: 0; height: 46vh;
  z-index: 6; pointer-events: none; overflow: hidden;
}
.danmaku-overlay .danmaku {
  background: color-mix(in srgb, var(--paper) 42%, transparent);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  color: var(--ink);
  border: 1px solid color-mix(in srgb, var(--hairline) 120%, transparent);
  box-shadow: 0 4px 14px -8px rgba(0, 0, 0, .3);
  opacity: .92;
}
.danmaku-overlay .danmaku b { color: var(--accent); }
/* 静态回退列表 */
.blessing-static-list {
  display: grid; gap: 8px; width: 100%; max-width: 760px; margin: 0 auto;
}
.blessing-static-list .danmaku-static { width: auto; margin: 0; justify-items: start; }
.blessing-static-list .wedding-sub { text-align: center; }
@media (prefers-reduced-motion: reduce) {
  .danmaku-overlay { display: none; }
}

/* ---------- 25. 信封火漆：真实蜡印质感（用户关注点） ---------- */
.invite-surface .wax-seal,
.invite-surface[data-theme="garden"] .wax-seal,
.invite-surface[data-theme="soiree"] .wax-seal,
.invite-surface[data-theme="vermilion"] .wax-seal {
  width: 76px; height: 76px;
  border-radius: 46% 54% 56% 44% / 54% 46% 52% 48%;
  color: #f6e7cd;
  font-size: 30px;
  line-height: 1;
  background:
    radial-gradient(circle at 32% 24%, rgba(255, 230, 214, .3), transparent 46%),
    radial-gradient(circle at 70% 80%, rgba(58, 6, 4, .4), transparent 58%),
    radial-gradient(circle at 50% 46%, #b84232 0%, #982b21 58%, #7e1f18 100%);
  box-shadow:
    inset 0 0 0 3px rgba(246, 231, 205, .38),
    inset 0 0 0 5px rgba(120, 22, 14, .18),
    inset -5px -7px 12px rgba(64, 7, 5, .55),
    inset 5px 6px 10px rgba(255, 232, 218, .22),
    0 12px 20px -8px rgba(42, 6, 4, .55);
  text-shadow: 0 1px 0 rgba(255, 235, 220, .22), 0 -1px 2px rgba(52, 4, 2, .7);
  position: relative;
  animation: wax-breathe 3.6s ease-in-out infinite;
  filter: drop-shadow(0 2px 3px rgba(50, 5, 3, .18));
}
/* 压印徽记（更深的字形=烙进去的感觉） */
.invite-surface .wax-seal { place-content: center; }
.invite-surface .wax-seal::before {
  content: ""; position: absolute; top: calc(100% - 3px); left: 30%; width: 16px; height: 13px;
  background: #7e1f18; border-radius: 60% 40% 70% 30% / 60% 60% 40% 40%;
  opacity: .9;
}
.invite-surface .wax-seal::after {
  content: ""; position: absolute;
  inset: auto; top: calc(100% - 2px); right: 24%; bottom: auto; left: auto;
  width: 11px; height: 12px;
  background: #8c231c; border-radius: 40% 60% 30% 70%;
  opacity: .85; border: 0;
}
/* 缓慢"呼吸"提醒可点击 */
@keyframes wax-breathe {
  0%, 100% { transform: rotate(-3deg) scale(1); }
  50% { transform: rotate(-3deg) scale(1.035); }
}
@media (prefers-reduced-motion: reduce) {
  .invite-surface .wax-seal { animation: none; }
}

/* ---------- 26. 火漆强化：与"开启按钮"彻底区分（用户反馈） ---------- */
.invite-surface .wax-seal,
.invite-surface[data-theme="garden"] .wax-seal,
.invite-surface[data-theme="soiree"] .wax-seal,
.invite-surface[data-theme="vermilion"] .wax-seal {
  width: 92px; height: 92px; font-size: 34px;
  transform: rotate(-3deg);
  border-radius: 44% 56% 58% 42% / 56% 44% 50% 50%;
  background:
    radial-gradient(circle at 28% 22%, rgba(255, 236, 214, .34), transparent 44%),
    radial-gradient(circle at 30% 70%, rgba(128, 20, 12, .28), transparent 52%),
    radial-gradient(circle at 68% 82%, rgba(58, 6, 4, .4), transparent 60%),
    radial-gradient(circle at 50% 48%, #c14a39 0%, #a13027 55%, #811f17 100%);
  box-shadow:
    inset 0 0 0 3px rgba(247, 232, 205, .42),
    inset 0 0 0 6px rgba(122, 22, 13, .16),
    inset -6px -9px 16px rgba(56, 6, 4, .6),
    inset 6px 7px 14px rgba(255, 232, 216, .28),
    0 14px 26px -10px rgba(38, 5, 3, .6);
}
.invite-surface .wax-seal::before {
  width: 19px; height: 16px; background: #7e1f18; left: 22%;
}
.invite-surface .wax-seal::after {
  width: 12px; height: 14px; background: #8c231c; right: 18%;
}
/* 开启按钮改为描边胶囊，避免与蜡印混淆 */
.invite-surface .envelope-card .open-invite {
  background: transparent;
  color: var(--accent);
  border: 1px solid color-mix(in srgb, var(--accent) 60%, transparent);
  letter-spacing: .3em;
  padding: 12px 26px 12px 32px;
  border-radius: 999px;
  box-shadow: none;
}
.invite-surface .envelope-card .open-invite:hover {
  background: color-mix(in srgb, var(--accent) 14%, transparent);
  color: var(--accent);
  transform: translateY(-1px);
  box-shadow: none;
}
.invite-surface .envelope-card .open-invite::after { display: none; }

/* ---------- 27. 火漆位置：压在信封封口线正中，整卡点击开启（用户反馈） ---------- */
.invite-surface .envelope { cursor: pointer; }
.invite-surface .envelope:focus-visible { outline: 2px solid color-mix(in srgb, var(--accent) 60%, transparent); outline-offset: 4px; }
.invite-surface .envelope-card { position: relative; overflow: visible; padding-top: 80px; }
.invite-surface .wax-seal,
.invite-surface[data-theme="garden"] .wax-seal,
.invite-surface[data-theme="soiree"] .wax-seal,
.invite-surface[data-theme="vermilion"] .wax-seal {
  position: absolute; top: -46px; left: 50%;
  transform: translateX(-50%) rotate(-3deg);
}
.invite-surface .envelope-hint {
  margin: 26px 0 0; padding-left: .45em;
  font-size: 12px; letter-spacing: .45em;
  color: var(--accent); opacity: .8;
}
@keyframes wax-breathe {
  0%, 100% { transform: translateX(-50%) rotate(-3deg) scale(1); }
  50% { transform: translateX(-50%) rotate(-3deg) scale(1.035); }
}

/* ---------- 28. 右上控制:小幽灵按钮 + 状态小圆点(用户反馈) ---------- */
/* 原 .brand(新人名字)已移除,.invite-tools 现在只剩 .tool-group,改为右对齐 */
.invite-tools { gap: 8px; justify-content: flex-end; }
.invite-tools .icon-button {
  width: 34px; height: 34px; font-size: 13px;
  background: color-mix(in srgb, var(--paper) 24%, transparent);
  border: 1px solid transparent; color: var(--muted);
  opacity: .55; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  transition: opacity .3s var(--ease-out), color .3s var(--ease-out), background .3s var(--ease-out);
}
.invite-tools .icon-button:hover,
.invite-tools .icon-button:focus-visible {
  opacity: 1; color: var(--ink);
  background: color-mix(in srgb, var(--paper) 55%, transparent);
}
/* 状态：不再整体填色，只亮图标 + 角落小圆点 */
.music-toggle.is-playing,
.danmaku-toggle.is-on {
  opacity: .95; color: var(--accent);
  background: transparent; box-shadow: none;
}
.music-toggle.is-playing::before,
.danmaku-toggle.is-on::before {
  content: ""; position: absolute; top: 2px; right: 2px;
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 8px color-mix(in srgb, var(--accent) 70%, transparent);
}
.music-toggle.is-playing::after {
  border-color: color-mix(in srgb, var(--accent) 40%, transparent);
}
@media (hover: none) {
  .invite-tools .icon-button { opacity: .8; }
}

/* ---------- 29. 火漆放回卡片底部中央，去掉"轻触开启"提示（用户反馈 III） ---------- */
.invite-surface .envelope-card { padding-top: 48px; }
.invite-surface .wax-seal,
.invite-surface[data-theme="garden"] .wax-seal,
.invite-surface[data-theme="soiree"] .wax-seal,
.invite-surface[data-theme="vermilion"] .wax-seal {
  position: static; top: auto; left: auto;
  transform: none;
  margin: 28px auto 4px;
}
.invite-surface .envelope-hint { display: none; }
@keyframes wax-breathe {
  0%, 100% { transform: rotate(-3deg) scale(1); }
  50% { transform: rotate(-3deg) scale(1.035); }
}

/* ---------- 30. 顶部工具默认隐藏、更小（用户反馈） ---------- */
.invite-tools { pointer-events: none; }
.invite-tools .icon-button {
  width: 30px; height: 30px; font-size: 12px;
  opacity: 0; transform: translateY(-4px); pointer-events: none;
}
.invite-tools.is-visible { pointer-events: auto; }
.invite-tools.is-visible .icon-button {
  opacity: .78; transform: none; pointer-events: auto;
}
.invite-tools.is-visible .icon-button:hover,
.invite-tools:focus-within .icon-button { opacity: 1; }
@media (prefers-reduced-motion: reduce) {
  .invite-tools .icon-button { transition: none; }
}

/* ---------- 31. 首页精致化 / 分享海报面板（用户反馈） ---------- */
.hero-divider {
  width: 96px; height: 1px; margin: 14px auto 18px; position: relative;
  background: linear-gradient(90deg, transparent, var(--accent) 18%, var(--accent) 82%, transparent);
  opacity: .95;
}
.hero-divider::before, .hero-divider::after {
  content: ""; position: absolute; top: -2.5px; width: 6px; height: 6px;
  background: var(--accent); border-radius: 50%;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent);
}
.hero-divider::before { left: -10px; }
.hero-divider::after { right: -10px; }
.hero-eyebrow { display: inline-flex; align-items: center; gap: 14px; }
.hero-eyebrow-line {
  display: inline-block; width: 38px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent));
}
.hero-eyebrow-line:last-child { background: linear-gradient(90deg, var(--accent), transparent); }
.hero-title {
  display: inline-flex; align-items: baseline; justify-content: center;
  flex-wrap: wrap; gap: clamp(12px, 2.2vw, 28px); margin: 8px 0 0;
  font-family: var(--font-display); font-weight: 500;
  letter-spacing: .04em;
}
.hero-title-name {
  font-size: clamp(40px, 6.4vw, 84px);
  line-height: 1.12;
}
.hero-title-amp {
  font-family: var(--font-num); font-style: italic; font-weight: 400;
  font-size: clamp(34px, 4.6vw, 64px); color: var(--accent);
  letter-spacing: .1em; padding: 0 4px; position: relative; top: -.04em;
}
/* 卡片内 & 字号强制跟随名字(不受全局 .hero-title-amp 影响) */
.hero-card .hero-title-amp { font-size: .8em; }
/* & 两侧的细金线:仅在桌面 soiree 主题下显示(H5 / 默认隐藏,避免名字中央像被截断) */
.hero-title-amp::before, .hero-title-amp::after {
  content: ""; position: absolute; top: 50%; width: 8px; height: 1px; background: var(--accent); opacity: 0;
}
.invite-surface[data-theme="soiree"] .hero-title-amp::before,
.invite-surface[data-theme="soiree"] .hero-title-amp::after { opacity: .55; }
.hero-title-amp::before { right: 100%; margin-right: 2px; }
.hero-title-amp::after  { left: 100%;  margin-left: 2px;  }
.invite-surface[data-theme="vermilion"] .hero-title { letter-spacing: .12em; }
.invite-surface[data-theme="vermilion"] .hero-title-name { font-weight: 600; }
.invite-surface[data-theme="soiree"] .hero-title-name { font-weight: 400; letter-spacing: .08em; }
.hero-invitation::before,
.hero-invitation::after {
  content: ""; width: 38px; height: 1px; display: inline-block;
  vertical-align: middle; margin: 0 14px 3px;
  background: linear-gradient(90deg, transparent, var(--accent));
}
.hero-invitation::after { background: linear-gradient(90deg, var(--accent), transparent); }
.hero h2 { letter-spacing: .04em; }

/* V5 响应式:hero 整体在窄屏上下堆叠 + 装饰自动收窄 */
@media (max-width: 980px) {
  .hero-arch-wrap { height: 200px; opacity: .75; }
  .hero-spray-wrap { width: 90px; opacity: .7; }
  .hero-pearls { width: 16px; opacity: .4; }
}
@media (max-width: 720px) {
  .hero-arch-wrap { height: 110px; opacity: .8; top: -2%; }
  /* H5 上下花柱:和桌面共用样式,只是尺寸缩放 */
  .hero-spray-wrap {
    width: min(86%, 320px); height: 130px;
    opacity: .9;
  }
  .hero-spray-top { top: 3%; }
  .hero-spray-bottom { bottom: 5%; }
  /* H5 上下珠串 */
  .hero-pearls {
    width: 76%; height: 16px;
    opacity: .6;
  }
  .hero-pearls-top { top: 24%; }
  .hero-pearls-bottom { bottom: 24%; }
  .hero-arc-bottom-wrap { height: 70px; opacity: .7; bottom: 4%; }
  .hero-petals { opacity: .55; }    /* H5 上半透保留装饰 */
  /* H5 静态花点兜底(仅在主装饰已加载时仍额外补一点星光) */
  .hero::after {
    content: ""; position: absolute; left: 0; right: 0; top: 38%; height: 4px;
    background:
      radial-gradient(4px 4px at 12% 50%, var(--flora-accent), transparent 70%),
      radial-gradient(5px 5px at 88% 50%, var(--flora-petal), transparent 70%),
      radial-gradient(3px 3px at 50% 50%, var(--flora-accent), transparent 70%);
    opacity: .35; pointer-events: none;
  }
}

/* 主题专属:朱砂 hero 名字用书法感小衬线;晚宴 hero 名字更细更宽 */
.invite-surface[data-theme="vermilion"] .hero-title-amp { color: var(--deep); }
.share-panel {
  position: fixed; inset: 0; z-index: 40;
  display: grid; place-items: center; padding: 20px;
  background: rgba(12, 10, 8, .55);
  backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
  animation: share-fade-in .25s ease-out;
}
@keyframes share-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}
.share-card {
  position: relative; width: min(100%, 460px); box-sizing: border-box;
  padding: 38px 28px 26px; border-radius: 6px; text-align: center;
  background: linear-gradient(180deg, #fdfaf3 0%, #f7f0e2 100%);
  color: #2a211c;
  border: 1px solid color-mix(in srgb, var(--accent, #b99258) 30%, transparent);
  box-shadow:
    0 24px 70px rgba(10, 6, 4, .35),
    0 0 0 6px rgba(255, 250, 240, .04);
  animation: share-card-in .35s cubic-bezier(.22, .61, .36, 1);
}
@keyframes share-card-in {
  from { opacity: 0; transform: translateY(20px) scale(.96); }
  to   { opacity: 1; transform: none; }
}
.share-card .eyebrow {
  color: var(--accent, #b99258); letter-spacing: .4em;
  font-family: Georgia, "Times New Roman", serif;
  margin: 0 0 8px;
}
.share-card h3 {
  margin: 0 0 8px; font-family: "Songti SC", "Noto Serif SC", serif;
  font-weight: 600; font-size: 22px; letter-spacing: .04em;
}
.share-sub {
  margin: 0 0 22px; font-size: 13px;
  color: color-mix(in srgb, #2a211c 70%, transparent);
  letter-spacing: .04em;
}
.share-qr {
  display: grid; place-items: center; width: min(100%, 260px); aspect-ratio: 1;
  margin: 0 auto 8px; padding: 12px; background: #fff;
  border: 1px solid color-mix(in srgb, var(--accent, #b99258) 36%, transparent);
  box-shadow: 0 10px 24px rgba(20, 10, 6, .14);
}
.share-qr img { display: block; width: 100%; height: 100%; object-fit: contain; }
.share-close { position: absolute; top: 12px; right: 12px; width: 30px; height: 30px; font-size: 18px; }
/* 分享按钮区 */
.share-actions {
  display: flex; gap: 12px; justify-content: center; flex-wrap: wrap;
  margin-bottom: 6px;
}
.share-actions .button {
  display: inline-flex; align-items: center; gap: 6px;
  min-width: 156px; padding: 12px 18px;
}
.share-actions .btn-ic { font-size: 15px; }
/* 海报区:严格居中 + 精致画框 */
.share-poster {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 18px 0 4px;
  animation: share-fade-in .3s ease-out;
}
.share-poster-frame {
  display: flex; align-items: center; justify-content: center;
  width: min(100%, 320px); max-height: 60vh;
  margin: 0 auto;
  padding: 12px;
  background: linear-gradient(135deg, var(--accent, #b99258) 0%, color-mix(in srgb, var(--accent, #b99258) 60%, #fff8ec) 100%);
  border-radius: 4px;
  box-shadow:
    inset 0 0 0 1px color-mix(in srgb, var(--accent, #b99258) 30%, transparent),
    0 12px 28px rgba(20, 10, 6, .25);
}
.share-poster-frame img {
  display: block; width: 100%; max-width: 280px;
  height: auto; aspect-ratio: 9 / 16;
  object-fit: cover; border-radius: 3px;
  background: #2a211c;
  box-shadow: 0 8px 18px rgba(0, 0, 0, .2);
}
.share-poster-tip {
  margin: 12px 0 8px; font-size: 12px;
  color: color-mix(in srgb, #2a211c 70%, transparent);
  letter-spacing: .04em;
}
.share-poster-actions { display: flex; justify-content: center; gap: 10px; margin-top: 6px; }
.share-poster-actions .button { min-width: 140px; }
.share-tip { min-height: 18px; font-size: 13px; color: #b99258; margin: 10px 0 0; }
/* 海报生成后,隐藏副标题 + 两个按钮(海报 + 下载按钮仍可见) */
.share-panel.is-poster-ready .share-sub,
.share-panel.is-poster-ready .share-actions { display: none; }
.share-panel.is-poster-ready .share-card { padding-bottom: 24px; }
/* hidden 兜底 */
.share-panel[hidden],
.share-poster[hidden] { display: none !important; }
/* 限制卡片最大高度并允许内部滚动 */
.share-card { max-height: min(92vh, 720px); overflow: auto; padding-right: 24px; padding-left: 24px; }
.share-card::-webkit-scrollbar { width: 4px; }
.share-card::-webkit-scrollbar-thumb { background: color-mix(in srgb, var(--accent, #b99258) 30%, transparent); border-radius: 2px; }

/* ---------- 32. 首页邀请函卡片（用户反馈：内容更丰富 + 居中 + 有质感） ---------- */
/* 整个 hero 改为"垂直舞台 + 中央请柬"布局,摆脱左右分栏错位 */
.hero {
  position: relative;
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) !important;
  place-items: center !important;
  justify-items: center !important;
  padding: clamp(48px, 8vw, 110px) clamp(20px, 5vw, 60px) clamp(60px, 9vw, 130px);
  min-height: 100dvh;
  isolation: isolate;
}
.hero-aurora {
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(62% 55% at 16% 10%, color-mix(in srgb, var(--accent) 18%, transparent), transparent 62%),
    radial-gradient(52% 46% at 88% 22%, color-mix(in srgb, var(--wash) 32%, transparent), transparent 64%),
    radial-gradient(80% 64% at 52% 100%, color-mix(in srgb, var(--accent) 12%, transparent), transparent 72%);
}
/* 中央舞台,容纳整张请柬 */
.hero-stage {
  position: relative; z-index: 2;
  width: min(100%, 920px);
  max-width: min(100%, 920px);
  display: grid; place-items: center;
  margin: 0 auto;
  justify-self: center;
}
/* 整张请柬 = 一张可居中、有质感、带暗纹 + 描边的卡片 */
.hero-card {
  position: relative;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  padding: clamp(28px, 5vw, 56px) clamp(22px, 5vw, 64px) clamp(32px, 5vw, 60px);
  text-align: center;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  border: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
  border-radius: 4px;
  box-shadow:
    0 1px 0 color-mix(in srgb, var(--paper) 100%, transparent) inset,
    0 30px 80px -40px color-mix(in srgb, var(--deep) 70%, transparent),
    0 8px 24px -16px color-mix(in srgb, var(--deep) 40%, transparent);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  overflow: hidden;
}
/* 卡片内所有子元素都不能溢出 */
.hero-card > * { max-width: 100%; box-sizing: border-box; }
/* 卡片四角花饰(取代之前浮在图外面的 .hero-image-frame) */
.hero-card-frame {
  position: absolute; inset: -10px; pointer-events: none; z-index: 0;
  overflow: hidden;    /* 裁剪 SVG 角花越界 */
}
.hero-card-frame > .hero-corner { position: absolute; color: var(--flora-leaf); opacity: 0; width: 1px; height: 1px; overflow: hidden; }
/* 干净的角线(替代 SVG 花角):每角一个 L 形金色线 */
.hero-card::after {
  content: "";
  position: absolute; inset: 0; pointer-events: none; z-index: 0;
  background:
    linear-gradient(90deg, var(--accent) 0 28px, transparent 28px) top left   / 28px 1px no-repeat,
    linear-gradient(0deg,  var(--accent) 0 28px, transparent 28px) top left   / 1px 28px no-repeat,
    linear-gradient(90deg, transparent calc(100% - 28px), var(--accent) calc(100% - 28px) 100%) top right / 28px 1px no-repeat,
    linear-gradient(0deg,  var(--accent) 0 28px, transparent 28px) top right   / 1px 28px no-repeat,
    linear-gradient(90deg, var(--accent) 0 28px, transparent 28px) bottom left / 28px 1px no-repeat,
    linear-gradient(0deg,  transparent calc(100% - 28px), var(--accent) calc(100% - 28px) 100%) bottom left / 1px 28px no-repeat,
    linear-gradient(90deg, transparent calc(100% - 28px), var(--accent) calc(100% - 28px) 100%) bottom right / 28px 1px no-repeat,
    linear-gradient(0deg,  transparent calc(100% - 28px), var(--accent) calc(100% - 28px) 100%) bottom right / 1px 28px no-repeat;
  opacity: .55;
}
/* 卡片内部所有内容相对卡片中心对齐 */
.hero-card-head, .hero-card-foot { position: relative; z-index: 1; }
.hero-card > * { position: relative; z-index: 1; }
.hero-card-cn {
  margin: 14px 0 4px;
  font-family: "Songti SC", "Noto Serif SC", serif;
  font-size: clamp(18px, 2.4vw, 24px);
  letter-spacing: .22em;
  color: var(--accent);
  text-indent: .22em;
}
.hero-card-to {
  display: inline-flex; align-items: center; gap: 8px;
  margin: 8px auto 0; padding: 6px 14px;
  font-size: 13px; letter-spacing: .14em;
  color: var(--muted);
  border-top: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
}
.hero-card-to strong { font-weight: 600; color: var(--ink); letter-spacing: .06em; font-size: 14px; }
.hero-card-to span { color: var(--muted); }
/* 在 hero-card 里复用现有 hero-title 样式,确保居中 */
.hero-card .hero-title {
  justify-content: center; margin: 18px 0 0;
  flex-wrap: wrap;                /* 名字允许换行(在 H5 窄屏自动堆叠) */
  white-space: normal;
  row-gap: 6px;
  column-gap: clamp(10px, 2vw, 24px);
}
.hero-card .hero-title-name { font-size: clamp(28px, 5vw, 60px); }
.hero-card .hero-title-amp { font-size: clamp(22px, 3.4vw, 44px); }
.hero-card .hero-divider { margin: 18px auto 14px; }
.hero-card .hero-invitation { letter-spacing: .45em; text-indent: .45em; }
.hero-divider-thin { width: 60px; opacity: .55; margin: 18px auto; }
/* 婚礼信息表(公历 / 农历 / 时间 / 地点) */
.hero-meta {
  margin: 4px auto 6px;
  display: grid; grid-template-columns: 1fr; gap: 4px;
  font-family: "Songti SC", "Noto Serif SC", serif;
  font-size: 15px; line-height: 1.95;
  color: var(--ink);
  max-width: 460px;
}
.hero-meta-row { display: grid; grid-template-columns: 64px 1fr; align-items: baseline; gap: 14px; justify-content: center; text-align: left; }
.hero-meta-label {
  text-align: justify; text-align-last: justify;
  font-size: 12px; letter-spacing: .4em;
  color: var(--muted); padding-right: 4px;
  font-family: var(--font-num), serif;
}
.hero-meta-value { font-size: 16px; letter-spacing: .04em; }
.hero-meta-value strong { font-weight: 600; font-size: 17px; letter-spacing: .12em; margin-right: 10px; }
.hero-meta-value em { font-style: normal; font-size: 13px; color: var(--muted); letter-spacing: .08em; }
/* 邀请正文 */
.hero-card .invitation-copy {
  margin: 6px auto 4px; max-width: 460px;
  font-family: "Songti SC", "Noto Serif SC", serif;
  font-size: 15px; line-height: 1.95;
  color: color-mix(in srgb, var(--ink) 88%, var(--muted));
}
.hero-card .invitation-copy p { margin: 0; }
.hero-card .invitation-copy p + p { color: var(--muted); margin-top: 4px; }
/* 底部:倒计时 + 头像(并排;手机堆叠) */
.hero-card-foot {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, auto);
  gap: clamp(18px, 3vw, 32px);
  align-items: center;
  margin-top: 18px;
}
.hero-card-countdown { justify-self: start; }
.hero-card-countdown .countdown {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px; padding: 10px 12px;
  border: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
  border-radius: 4px;
  background: color-mix(in srgb, var(--paper) 60%, transparent);
  min-width: 230px;
}
.hero-card-countdown .countdown-cell { text-align: center; padding: 0; }
.hero-card-countdown .countdown-cell strong {
  display: block; font-family: var(--font-num), serif;
  font-size: clamp(20px, 3vw, 26px); line-height: 1.1;
  color: var(--accent); font-weight: 500;
}
.hero-card-countdown .countdown-cell span { font-size: 11px; letter-spacing: .25em; color: var(--muted); }
.hero-card-countdown .countdown-ended { font-size: 14px; color: var(--accent); padding: 12px; }
.hero-card-image {
  width: clamp(96px, 18vw, 140px); aspect-ratio: 1 / 1;
  border-radius: 50%;
  border: 2px solid color-mix(in srgb, var(--accent) 55%, transparent);
  box-shadow:
    0 0 0 6px color-mix(in srgb, var(--accent) 14%, transparent),
    0 14px 30px -16px color-mix(in srgb, var(--deep) 60%, transparent);
  overflow: hidden;
  background: color-mix(in srgb, var(--accent) 14%, var(--paper));
  display: grid; place-items: center;
  color: var(--muted); font-family: var(--font-num), serif;
  letter-spacing: .14em;
}
.hero-card-image img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* 新人合照(首页视觉焦点):卡片上半部分,优雅画框 */
.hero-portrait {
  position: relative;
  margin: 18px auto 8px;
  width: min(82%, 360px);
  aspect-ratio: 4 / 5;
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--accent) 45%, transparent);
  box-shadow:
    inset 0 0 0 4px color-mix(in srgb, var(--paper) 70%, transparent),
    0 30px 60px -28px color-mix(in srgb, var(--deep) 50%, transparent),
    0 12px 24px -16px color-mix(in srgb, var(--deep) 30%, transparent);
  background: color-mix(in srgb, var(--accent) 10%, var(--paper));
}
.hero-portrait img {
  display: block; width: 100%; height: 100%; object-fit: cover;
  filter: saturate(.95) contrast(1.02);
}
.hero-portrait.is-placeholder {
  display: grid; place-items: center;
  background: linear-gradient(135deg,
    color-mix(in srgb, var(--accent) 22%, var(--paper)),
    color-mix(in srgb, var(--paper) 92%, var(--accent)));
}
.hero-portrait-fallback {
  display: block;
  width: 70%;
  height: auto;
  max-width: 220px;
  filter: drop-shadow(0 4px 12px rgba(160, 20, 30, .18));
  animation: hero-fb-bob 4s ease-in-out infinite;
}
@keyframes hero-fb-bob {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-4px); }
}
/* 头像下方小提示 */
.hero-footer-note {
  margin: 12px auto 0;
  font-size: 12px; letter-spacing: .18em;
  color: color-mix(in srgb, var(--muted) 92%, transparent);
  text-indent: .18em;
  max-width: 460px;
}

/* 兼容旧 .hero-copy 类:旧 app.css 设了 max-width:550px,这里重置让 hero-card 居中 */
.hero-card .hero-copy { max-width: none; padding: 0; }
/* 重置旧 app.css 里 `.hero h2 { max-width: 560px; font-size: 68px }` 对邀请函卡的限制 */
.hero-card h2.hero-title { max-width: none; font-size: inherit; margin: 0; word-break: keep-all; }
.hero-card .invitation-copy { max-width: 520px; }   /* 覆盖旧 app.css 的 455px */
/* 印章已移除,改为 hero-card 心心装饰(取代旧 stamp) */
.hero-card .invitation-seal { display: none; }

/* hero-card 暗水印改为渐变 + 心形(静态) */
.hero-card::before {
  content: "❤";
  position: absolute; left: 50%; top: 50%;
  transform: translate(-50%, -50%) rotate(-6deg);
  font-size: clamp(280px, 38vw, 460px);
  color: color-mix(in srgb, var(--accent, #c8302a) 8%, transparent);
  pointer-events: none; user-select: none;
  z-index: 0;
  font-weight: 400;
  line-height: 1;
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
}

/* ===== 12B. 炫酷心心组件(双心跳动 + 脉冲光环 + 飞散小爱心) ===== */
.hero-heart {
  position: absolute; right: 18px; bottom: 18px;
  width: 86px; height: 86px;
  z-index: 3;
  display: grid; place-items: center;
  pointer-events: none;
}
/* 三层脉冲光环(错峰扩散) */
.hero-heart::before,
.hero-heart::after,
.hero-heart .ring {
  content: ""; position: absolute; inset: 0;
  border-radius: 50%;
  border: 1.5px solid var(--heart-color, #e8445a);
  opacity: 0;
  pointer-events: none;
}
.hero-heart::before { animation: heart-pulse 2.6s ease-out infinite; }
.hero-heart::after  { animation: heart-pulse 2.6s ease-out .87s infinite; }
.hero-heart .ring   { animation: heart-pulse 2.6s ease-out 1.74s infinite; border-color: var(--heart-glow, #ffb3bf); }
@keyframes heart-pulse {
  0%   { transform: scale(.55); opacity: .8; }
  60%  { opacity: .35; }
  100% { transform: scale(2.4); opacity: 0; }
}
/* 主体心形 */
.hero-heart .core {
  position: relative;
  width: 52px; height: 52px;
  display: grid; place-items: center;
  filter:
    drop-shadow(0 0 8px color-mix(in srgb, var(--heart-color, #e8445a) 75%, transparent))
    drop-shadow(0 0 22px color-mix(in srgb, var(--heart-color, #e8445a) 50%, transparent))
    drop-shadow(0 6px 10px rgba(160, 20, 30, .35));
  animation: heart-beat 1.4s ease-in-out infinite;
}
.hero-heart .core svg { width: 100%; height: 100%; overflow: visible; }
.hero-heart .core svg path {
  fill: url(#heart-gradient);
  stroke: rgba(255, 255, 255, .45);
  stroke-width: 1.2;
}
/* 金色流光扫过 */
.hero-heart .shimmer {
  position: absolute; inset: 6px;
  border-radius: 50%;
  pointer-events: none;
  background: conic-gradient(from 0deg, transparent 0%, rgba(255, 240, 180, .65) 18%, transparent 36%);
  mask: radial-gradient(circle, transparent 38%, #000 40%, #000 95%, transparent 100%);
  -webkit-mask: radial-gradient(circle, transparent 38%, #000 40%, #000 95%, transparent 100%);
  animation: heart-spin 3.2s linear infinite;
  opacity: .9;
}
@keyframes heart-spin { to { transform: rotate(360deg); } }
/* 心跳节奏:放大-回弹 */
@keyframes heart-beat {
  0%, 100% { transform: scale(1); }
  14%      { transform: scale(1.18); }
  28%      { transform: scale(.96); }
  42%      { transform: scale(1.1); }
  56%      { transform: scale(.99); }
}
/* 飞散小爱心(粒子) */
.hero-heart .sparks {
  position: absolute; inset: 0; pointer-events: none;
}
.hero-heart .sparks span {
  position: absolute; left: 50%; top: 50%;
  width: 9px; height: 9px;
  color: var(--heart-color, #e8445a);
  font-size: 12px; line-height: 1;
  transform-origin: center;
  animation: heart-spark 2.4s ease-out infinite;
  opacity: 0;
}
.hero-heart .sparks span:nth-child(1) { animation-delay: .0s; --sx: -36px; --sy: -38px; }
.hero-heart .sparks span:nth-child(2) { animation-delay: .3s; --sx:  40px; --sy: -34px; }
.hero-heart .sparks span:nth-child(3) { animation-delay: .6s; --sx: -42px; --sy:  10px; }
.hero-heart .sparks span:nth-child(4) { animation-delay: .9s; --sx:  44px; --sy:  14px; }
.hero-heart .sparks span:nth-child(5) { animation-delay: 1.2s; --sx: -10px; --sy: -52px; }
.hero-heart .sparks span:nth-child(6) { animation-delay: 1.5s; --sx:  14px; --sy:  50px; }
@keyframes heart-spark {
  0%   { transform: translate(-50%, -50%) scale(.3); opacity: 0; }
  20%  { transform: translate(calc(-50% + var(--sx) * .35), calc(-50% + var(--sy) * .35)) scale(1); opacity: 1; }
  60%  { transform: translate(calc(-50% + var(--sx)), calc(-50% + var(--sy))) scale(.7); opacity: .8; }
  100% { transform: translate(calc(-50% + var(--sx) * 1.25), calc(-50% + var(--sy) * 1.25)) scale(0); opacity: 0; }
}

/* 主题色映射 */
.hero-heart {
  --heart-color: #e8445a;
  --heart-glow: #ffb3bf;
}
.invite-surface[data-theme="soiree"] .hero-heart {
  --heart-color: #ff6b88;
  --heart-glow: #ffd4dc;
}
.invite-surface[data-theme="vermilion"] .hero-heart {
  --heart-color: #ff3855;
  --heart-glow: #ff97a8;
}
/* H5 排版紧凑 */
@media (max-width: 720px) {
  .hero { padding: 96px 14px 64px !important; min-height: auto !important; grid-template-columns: 1fr !important; }
  .hero-card { padding: 24px 16px 26px; border-radius: 3px; }
  /* 重置 app.css 的 .hero h2 { font-size: 47px } 强制 */
  .hero-card h2.hero-title { font-size: inherit; }
  .hero-card .hero-title { white-space: normal; flex-wrap: wrap; row-gap: 4px; column-gap: 8px; }
  .hero-card .hero-title-name { font-size: clamp(22px, 7.5vw, 30px) !important; line-height: 1.1; }
  .hero-card .hero-title-amp { font-size: clamp(16px, 5vw, 22px) !important; }
  .hero-card-cn { font-size: 16px; letter-spacing: .18em; }
  .hero-portrait { width: min(78%, 320px); aspect-ratio: 4 / 5; margin: 14px auto 6px; }
  .hero-heart { width: 64px; height: 64px; right: 12px; bottom: 12px; }
  .hero-heart .core { width: 38px; height: 38px; }
  .hero-heart .sparks span { font-size: 10px; width: 7px; height: 7px; }
  .hero-card-foot { grid-template-columns: 1fr; justify-items: center; gap: 16px; }
  .hero-card-countdown { justify-self: stretch; width: 100%; }
  .hero-card-countdown .countdown { min-width: 0; width: 100%; }
  .hero-card-image { width: 96px; }
  .hero-card .invitation-seal { width: 42px; height: 42px; right: 10px; bottom: 10px; }
  .hero-card .invitation-seal .seal { font-size: 16px; }
  /* 重置 app.css 的 .hero-invitation { letter-spacing: 5px } */
  .hero-card .hero-invitation { letter-spacing: .4em; }
}
