/* ==========================================================================
   TRỐNG ĐỒNG & SEN — theme chính của thiệp
   Nền giấy dó, đỏ son và vàng đồng; mặt trống đồng, hoa sen, viền răng cưa
   và các khung viền kép như bức hoành phi.
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. NỀN & BỐ CỤC CHUNG
   -------------------------------------------------------------------------- */
:root {
  --vn-card-max: 900px;      /* khổ thiệp tối đa */
  --vn-content-max: 560px;   /* cột nội dung tối đa, căn giữa */
  --vn-gutter: 24px;
  --vn-inline-pad: max(var(--vn-gutter), (100% - var(--vn-content-max)) / 2);
  --vn-section-gap: 68px;
  /* Viền răng cưa vàng đồng */
  --vn-zigzag: linear-gradient(135deg, var(--vn-gold) 25%, transparent 25%) -6px 0 / 12px 12px,
               linear-gradient(225deg, var(--vn-gold) 25%, transparent 25%) -6px 0 / 12px 12px;
}

body {
  background: var(--vn-outside);
  background-image: none;
  color: var(--vn-ink);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.7;
}

::selection { background: var(--vn-red); color: var(--vn-paper-light); }

:focus-visible {
  outline: 2px solid var(--vn-gold) !important;
  outline-offset: 3px;
}

.app-container {
  width: min(var(--vn-card-max), 100%);
  min-height: 100vh;
  margin: 0 auto;
  padding: 0;
  background: var(--vn-paper);
  display: flex;
  flex-direction: column;
}

.vn-section {
  margin: var(--vn-section-gap) 0 0;
  padding: 0 var(--vn-inline-pad);
}

/* Tiêu đề khối: Playfair đỏ son */
.vn-title {
  margin: 0;
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 0;
  text-transform: none;
  text-align: center;
  color: var(--vn-red);
}
.vn-title--tight { margin-top: -6px; }

/* Nhãn in hoa giãn chữ */
.vn-kicker {
  margin: 0;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 4px;
  line-height: 1.6;
  text-transform: uppercase;
  color: var(--vn-gold-light);
}
.vn-kicker--brown { color: var(--vn-gold-text); }

.vn-lotus { display: block; flex: none; margin: 0 auto; color: var(--vn-lotus); }

.vn-zigzag { width: 100%; height: 6px; background: var(--vn-zigzag); }
.vn-zigzag--short { width: 160px; margin: 4px auto; }

/* Nút dùng chung */
.vn-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 46px;
  padding: 0 28px;
  border: 0;
  border-radius: 0;
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: none;
  text-decoration: none;
  box-shadow: none;
  cursor: pointer;
  transition: filter .2s ease, background .2s ease;
}
.vn-btn:hover { filter: brightness(1.08); }
.vn-btn svg { flex: none; }
.vn-btn[hidden] { display: none; }
.vn-btn--gold { background: var(--vn-gold); color: var(--vn-red-ink); }
.vn-btn--ink { background: var(--vn-ink); color: var(--vn-paper-light); }
.vn-btn--red { background: var(--vn-red); color: var(--vn-paper-light); }

/* Khối không ẩn cả cục — hiệu ứng chữ do scroll-animations.css */
.reveal-section { margin-bottom: 0; }

/* --------------------------------------------------------------------------
   2. BÌA: MẶT TRỐNG ĐỒNG, CHỮ HỶ GIỮA TÂM
   -------------------------------------------------------------------------- */
.envelope-screen {
  position: fixed;
  inset: 0;
  z-index: 900;
  background: var(--vn-outside);
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: stretch;
  visibility: visible;
  opacity: 1;
  transform: translateY(0);
  will-change: transform, opacity;
}

/* Trong lúc kéo bìa: không clip transform (body overflow:hidden hay cắt animation) */
body.invite-opening {
  overflow: visible !important;
}

/* Giống thiệp 14 thư tay: cả màn bìa vuốt trượt từ dưới lên trên */
#envelope-screen.opening,
.envelope-screen.opening {
  background: transparent;
  animation: vnCoverBgSlideUp 2.2s cubic-bezier(0.33, 0.05, 0.2, 1) forwards !important;
  pointer-events: none !important;
  overflow: visible !important;
}

/* Chỉ ẩn hẳn sau khi animation xong (JS gắn .opened, gỡ .opening) */
#envelope-screen.opened:not(.opening),
.envelope-screen.opened:not(.opening),
body.invite-open #envelope-screen:not(.opening) {
  display: none !important;
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
  animation: none !important;
}

@keyframes vnCoverBgSlideUp {
  0% {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }
  82% {
    opacity: 1;
    visibility: visible;
  }
  100% {
    transform: translateY(-115vh);
    opacity: 0;
    visibility: hidden;
  }
}

.envelope-box {
  width: min(var(--vn-card-max), 100%);
  min-height: 100%;
  display: flex;
  transform: translateY(0) scale(1);
  will-change: transform, opacity;
}

#envelope-screen.opening .envelope-box,
.envelope-screen.opening .envelope-box {
  animation: vnCoverCardFlyUp 2.2s cubic-bezier(0.28, 0.02, 0.18, 1) forwards !important;
  pointer-events: none !important;
}

/* Thẻ bìa nhích nhẹ cùng màn bìa, không cộng dồn -180vh làm mất hiệu ứng vuốt */
@keyframes vnCoverCardFlyUp {
  0% {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
  100% {
    transform: translateY(-8vh) scale(0.985);
    opacity: 1;
  }
}

.drum-cover {
  position: relative;
  flex: 1;
  box-sizing: border-box;
  min-height: 100dvh;
  overflow-y: auto;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: max(26px, calc(env(safe-area-inset-top) + 12px)) max(20px, (100% - var(--vn-content-max)) / 2) max(48px, calc(env(safe-area-inset-bottom) + 32px));
  background: var(--vn-red);
  color: var(--vn-paper-light);
  text-align: center;
  box-shadow: 0 18px 48px rgba(40, 8, 10, .35);
  cursor: pointer;
}
/* Khung chỉ vàng kép — neo theo safe-area để không bị thanh điều hướng che */
.drum-cover::before {
  content: "";
  position: absolute;
  inset: max(14px, env(safe-area-inset-top)) 14px max(14px, env(safe-area-inset-bottom)) 14px;
  border: 1px solid var(--vn-gold);
  outline: 1px solid rgba(217, 164, 65, .5);
  outline-offset: -6px;
  pointer-events: none;
}

.cover-drum {
  display: block;
  flex: none;
  width: min(255px, 66vw, 31vh);
  height: auto;
  aspect-ratio: 1;
  animation: none;
}
.cover-drum > g {
  transform-box: view-box;
  transform-origin: 100px 100px;
  animation: vn-drum-spin 120s linear infinite;
}
@keyframes vn-drum-spin { to { transform: rotate(360deg); } }

.cover-kicker {
  margin: clamp(18px, 3vh, 30px) 0 0;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 4px;
  color: var(--vn-gold-light);
}
.envelope-invite-text {
  margin: 6px 0 0;
  font-family: var(--font-display);
  font-size: clamp(20px, 4.8vw, 24px);
  font-style: italic;
  font-weight: 600;
  line-height: 1.35;
  color: var(--vn-paper-light);
  overflow-wrap: anywhere;
}
.cover-line {
  margin: clamp(10px, 1.8vh, 18px) 0 0;
  max-width: 320px;
  font-family: var(--font-display);
  font-size: clamp(13px, 3.4vw, 15px);
  font-style: italic;
  font-weight: 600;
  line-height: 1.45;
  letter-spacing: .3px;
  color: var(--vn-paper-light);
}

.envelope-names {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: baseline;
  gap: 0 10px;
  margin: clamp(18px, 3vh, 28px) 0 0;
  font-family: var(--font-display);
  font-size: clamp(28px, 6.8vw, 36px);
  font-weight: 700;
  line-height: 1.2;
  color: var(--vn-gold-light);
}
.envelope-name-line { overflow-wrap: anywhere; }

.envelope-date {
  margin: clamp(14px, 2.4vh, 22px) 0 0;
  font-size: clamp(13px, 3.2vw, 15px);
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
}
.envelope-date:empty { display: none; }
.envelope-lunar { margin: 6px 0 0; font-size: 12px; font-style: italic; }
.envelope-lunar[hidden] { display: none; }

.btn-open {
  margin-top: clamp(22px, 3.4vh, 36px);
  min-height: 48px;
  padding: 0 clamp(28px, 6vw, 40px);
  border: 0;
  border-radius: 0;
  background: var(--vn-gold);
  color: var(--vn-red-ink);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  cursor: pointer;
  transition: filter .2s ease, opacity .2s ease;
  flex-shrink: 0;
}
.btn-open:hover { filter: brightness(1.08); }
.btn-open:disabled { opacity: .5; cursor: progress; }

/* Màn hình điện thoại ngắn (iPhone SE, màn hình có thanh công cụ Safari/Zalo WebView) */
@media (max-height: 700px) {
  .drum-cover {
    padding-top: max(18px, calc(env(safe-area-inset-top) + 8px));
    padding-bottom: max(40px, calc(env(safe-area-inset-bottom) + 24px));
  }
  .cover-drum {
    width: min(195px, 52vw, 26vh);
  }
  .envelope-names {
    font-size: 26px;
  }
  .btn-open {
    min-height: 44px;
    margin-top: 14px;
  }
}

/* Lớp chờ tải dữ liệu thiệp trên bìa */
#envelope-screen .cover-loading-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--vn-red);
}
#envelope-screen .cover-loading-overlay[hidden] { display: none; }
.cover-loading-spinner {
  width: 32px;
  height: 32px;
  border: 2px solid rgba(217, 164, 65, .35);
  border-top-color: var(--vn-gold);
  border-radius: 50%;
  animation: vn-spin .9s linear infinite;
}
@keyframes vn-spin { to { transform: rotate(360deg); } }

/* --------------------------------------------------------------------------
   3. NGÀY CHUNG ĐÔI (HERO)
   -------------------------------------------------------------------------- */
.hero-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding-top: 0;
  margin-top: clamp(16px, 2.5vh, 24px) !important;
  text-align: center;
}

.envelope-stage { width: 100%; }
.hero-frame {
  padding: 4px;
  background: var(--vn-red);
}
.photo-frame {
  aspect-ratio: 4 / 5;
  overflow: hidden;
  background: var(--vn-paper-mat);
  outline: none;
  box-shadow: none;
  cursor: zoom-in;
}
.photo-frame img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .6s ease;
}
.photo-frame:hover img { transform: scale(1.02); }

.hero-title-box { margin-top: 8px; }
.hero-names {
  margin: 0;
  font-family: var(--font-display);
  font-size: 30px;
  font-style: italic;
  font-weight: 700;
  line-height: 1.3;
  color: var(--vn-ink);
  overflow-wrap: anywhere;
}
.hero-names .amp { color: var(--vn-red); }
.hero-invite-guest {
  margin: 6px 0 0;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--vn-gold-text);
}
.hero-quote {
  margin: 0;
  max-width: 300px;
  font-size: 16px;
  font-style: italic;
  color: var(--vn-ink);
}

/* --------------------------------------------------------------------------
   4. HAI GIA ĐÌNH: BỨC HOÀNH PHI + HAI THẺ GIA ĐÌNH
   -------------------------------------------------------------------------- */
.red-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 0;
  background: none;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}
.vn-banner {
  padding: 14px;
  background: var(--vn-red);
  color: var(--vn-gold-light);
  text-align: center;
  box-shadow: inset 0 0 0 4px var(--vn-red), inset 0 0 0 5px var(--vn-gold);
}
.vn-banner .card-heading {
  margin: 0;
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: 0;
  text-transform: none;
  color: var(--vn-paper-light);
}

.parents-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
}
.family-side {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 0;
  padding: 16px 12px 18px;
  background: var(--vn-paper-light);
  border: 1px solid var(--vn-gold);
  outline: 1px solid var(--vn-gold);
  outline-offset: -5px;
  text-align: center;
}
.family-side small {
  display: block;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--vn-red);
}
.family-side h4 {
  margin: 4px 0 0;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.6;
  color: var(--vn-ink);
  overflow-wrap: anywhere;
}
.family-side p {
  margin: 2px 0 0;
  font-size: 13px;
  line-height: 1.6;
  color: var(--vn-ink-muted);
  overflow-wrap: anywhere;
}
.family-side .groom-name,
.family-side .bride-name {
  margin-top: auto;
  padding-top: 8px;
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--vn-ink);
  overflow-wrap: anywhere;
}
.family-side .role-badge {
  display: block;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  font-size: 13px;
  font-style: italic;
  letter-spacing: 0;
  text-transform: none;
  color: var(--vn-ink-muted);
}
.family-side .role-badge:empty { display: none; }

/* --------------------------------------------------------------------------
   5. LỄ THÀNH HÔN: NỀN TRỐNG ĐỒNG CHÌM
   -------------------------------------------------------------------------- */
.ceremony-card {
  position: relative;
  margin-top: var(--vn-section-gap);
  overflow: hidden;
  padding: 32px 22px 28px;
  background: var(--vn-red);
  color: var(--vn-paper-light);
  text-align: center;
  box-shadow: inset 0 0 0 6px var(--vn-red), inset 0 0 0 7px var(--vn-gold);
}
.ceremony-drum {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 360px;
  height: 360px;
  transform: translate(-50%, -50%);
  opacity: .16;
  pointer-events: none;
}
.ceremony-inner { position: relative; }
.ceremony-type-title {
  margin: 0;
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  line-height: 1.3;
}

.ceremony-time-badge { margin-top: 12px; }
.ceremony-date-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 12px;
}
.ceremony-dow,
.ceremony-month {
  padding: 6px 0;
  border-top: 1px solid var(--vn-gold);
  border-bottom: 1px solid var(--vn-gold);
  font-size: 14px;
  font-weight: 600;
}
.ceremony-day {
  font-family: var(--font-display);
  font-size: 60px;
  font-weight: 800;
  line-height: 1;
  color: var(--vn-gold-light);
}
.ceremony-time { margin: 8px 0 0; font-size: 17px; font-weight: 700; }
.ceremony-time:empty { display: none; }
.ceremony-time-badge .lunar { margin: 2px 0 0; font-size: 14px; }
.ceremony-note { margin: 2px 0 0; font-size: 14px; }
.ceremony-direction { margin-top: 16px; }

/* --------------------------------------------------------------------------
   6. ALBUM ẢNH CƯỚI
   -------------------------------------------------------------------------- */
#gallery {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.artwork-wall {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  width: 100%;
}
.artwork-item {
  position: relative;
  display: block;
  aspect-ratio: 1;
  padding: 0;
  overflow: hidden;
  border: 4px solid var(--vn-red);
  border-radius: 0;
  background: var(--vn-paper-mat);
  cursor: zoom-in;
}
.artwork-item img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .5s ease;
}
.artwork-item:hover img { transform: scale(1.04); }

.artwork-item.is-feature {
  grid-column: span 2;
  grid-row: span 2;
  aspect-ratio: auto;
  outline: 1px solid var(--vn-gold);
  outline-offset: -8px;
}
.artwork-item.is-feature img { position: absolute; inset: 0; }
.artwork-wall.is-single .artwork-item.is-feature { grid-column: 1 / -1; grid-row: auto; aspect-ratio: 4 / 5; }

.artwork-more {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--vn-red);
  color: var(--vn-paper-light);
  font-size: 13px;
}
.artwork-more b {
  font-family: var(--font-display);
  font-size: 30px;
  line-height: 1.1;
  color: var(--vn-gold-light);
}

/* Lightbox */
.lightbox-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 64px 16px;
  background: rgba(42, 10, 10, .95);
  opacity: 0;
  visibility: hidden;
  transition: opacity .3s ease, visibility .3s ease;
}
.lightbox-modal.open { opacity: 1; visibility: visible; }
.lightbox-modal img {
  max-width: min(92vw, 720px);
  max-height: 80vh;
  object-fit: contain;
  border: 6px solid var(--vn-red);
  outline: 1px solid var(--vn-gold);
  outline-offset: -6px;
  border-radius: 0;
  box-shadow: none;
}
.lightbox-close,
.lightbox-nav {
  position: absolute;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--vn-gold);
  border-radius: 0;
  background: transparent;
  color: var(--vn-gold-light);
  font-size: 22px;
  line-height: 1;
}
.lightbox-close { top: 16px; right: 16px; font-size: 16px; }
.lightbox-nav { top: 50%; transform: translateY(-50%); font-size: 28px; }
.lightbox-nav.prev { left: 12px; }
.lightbox-nav.next { right: 12px; }
.lightbox-nav[hidden], .lightbox-counter[hidden] { display: none; }
.lightbox-counter {
  position: absolute;
  bottom: 22px;
  left: 50%;
  transform: translateX(-50%);
  color: var(--vn-gold-light);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2px;
}

/* --------------------------------------------------------------------------
   7. TIỆC CƯỚI
   -------------------------------------------------------------------------- */
.reception-card {
  padding: 28px 20px 24px;
  background: var(--vn-paper-light);
  border: 2px solid var(--vn-red);
  border-radius: 0;
  outline: 1px solid var(--vn-gold);
  outline-offset: -8px;
  box-shadow: none;
  color: var(--vn-ink);
  text-align: center;
}
.reception-date-text { margin: 2px 0 0; font-size: 14px; }
.reception-lunar { margin: 0; font-size: 13px; font-style: italic; color: var(--vn-ink-muted); }

.reception-times {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}
.reception-time-col {
  min-width: 0;
  padding: 10px;
  background: var(--vn-red);
  color: var(--vn-paper-light);
}
.reception-time-col small {
  display: block;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--vn-gold-light);
}
.reception-time-col strong {
  display: block;
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 700;
  line-height: 1.3;
}

.calendar-paper {
  margin-top: 16px;
  padding: 0;
  background: none;
  border: 0;
  box-shadow: none;
  color: var(--vn-ink);
}
.calendar-paper-title {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 700;
}
.calendar-grid-header,
.calendar-grid-days {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  font-size: 13px;
  text-align: center;
}
.calendar-grid-header { margin-top: 4px; }
.calendar-grid-header span,
.calendar-grid-days span {
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.calendar-grid-header span { font-size: 11px; font-weight: 700; color: var(--vn-red); }
.calendar-grid-days .wedding-day {
  width: 34px;
  margin: 0 auto;
  border-radius: 50%;
  background: var(--vn-red);
  color: var(--vn-gold-light);
  font-weight: 700;
  box-shadow: 0 0 0 2px var(--vn-gold);
}

.reception-actions { display: flex; gap: 10px; margin-top: 16px; }
.reception-actions button {
  flex: 1;
  min-height: 48px;
  padding: 0 8px;
  border: 1.5px solid var(--vn-red);
  border-radius: 0;
  background: transparent;
  color: var(--vn-red);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: 0;
  text-transform: none;
  box-shadow: none;
  transition: background .2s ease, color .2s ease;
}
.reception-actions .btn-gold-outline:hover { background: rgba(155, 28, 28, .06); }
.reception-actions .btn-cream-solid { border-color: var(--vn-red); background: var(--vn-red); color: var(--vn-paper-light); }
.reception-actions .btn-cream-solid:hover { background: var(--vn-red-deep); }

/* --------------------------------------------------------------------------
   8. ĐỊA ĐIỂM (& TIỆC NHÀ GÁI)
   -------------------------------------------------------------------------- */
.venue-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 0;
  background: none;
  border: 0;
  box-shadow: none;
  text-align: center;
}
.venue-name {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 0;
  font-family: var(--font-body);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.4;
  color: var(--vn-ink);
  overflow-wrap: anywhere;
}
.venue-location-icon {
  flex: none;
  width: 16px;
  height: 16px;
  color: var(--vn-red);
}
.ceremony-note-place .venue-location-icon {
  color: var(--vn-gold-light);
}
.venue-address { margin: 0; font-size: 14px; color: var(--vn-ink); }

.map-embed-wrapper {
  width: 100%;
  height: 210px;
  margin-top: 10px;
  padding: 6px;
  box-sizing: border-box;
  background: var(--vn-red);
  border: 0;
  border-radius: 0;
}
.map-embed-wrapper iframe {
  display: block;
  width: 100%;
  height: 100%;
  background: var(--vn-paper-mat);
  box-shadow: 0 0 0 1px var(--vn-gold);
}
.venue-direction-btn { margin-top: 12px; }

#reception-bride {
  --rb-ink: var(--vn-ink);
  --rb-muted: var(--vn-ink-muted);
  --rb-paper: transparent;
  --rb-border: var(--vn-line);
  max-width: none;
  margin: var(--vn-section-gap) 0 0;
  padding: 0 var(--vn-inline-pad);
  font-family: var(--font-body);
  text-align: center;
}
#reception-bride .bride-reception-card {
  padding: 28px 20px 24px;
  background: var(--vn-paper-light);
  border: 2px solid var(--vn-red);
  border-radius: 0;
  outline: 1px solid var(--vn-gold);
  outline-offset: -8px;
  box-shadow: none;
}
#reception-bride .rb-lead,
#reception-bride .rb-venue-label {
  margin-top: 12px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--vn-gold-text);
}
#reception-bride .rb-weekday { margin: 4px 0 0; font-size: 14px; font-weight: 600; }
#reception-bride .rb-date { justify-content: center; }
#reception-bride .rb-day { font-family: var(--font-display); font-weight: 800; font-size: 56px; color: var(--vn-red); }
#reception-bride .rb-year { font-family: var(--font-display); font-weight: 700; }
#reception-bride .rb-lunar { font-size: 13px; font-style: italic; text-transform: none; }
#reception-bride .rb-times {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}
#reception-bride .rb-time-col { padding: 10px; background: var(--vn-red); color: var(--vn-paper-light); }
#reception-bride .rb-time-col small { font-size: 12px; font-weight: 700; letter-spacing: 2px; color: var(--vn-gold-light); }
#reception-bride .rb-time-col strong { font-family: var(--font-display); font-weight: 700; font-size: 28px; color: var(--vn-paper-light); }
#reception-bride .rb-venue-name-row { justify-content: center; }
#reception-bride .rb-venue-name { font-family: var(--font-body); font-weight: 700; font-size: 18px; }
#reception-bride .rb-venue-address { font-size: 14px; }
#reception-bride .rb-direction { margin-top: 12px; }

/* --------------------------------------------------------------------------
   9. ĐẾM NGƯỢC: BỐN MẶT TRỐNG NHỎ
   -------------------------------------------------------------------------- */
#countdown { padding: 0 var(--vn-inline-pad); }
.countdown-card { padding: 0; background: none; border: 0; box-shadow: none; text-align: center; }
.countdown-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 14px;
  padding: 4px;
}
.count-box {
  box-sizing: border-box;
  aspect-ratio: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 3px dashed var(--vn-gold);
  border-radius: 50%;
  background: var(--vn-red);
  color: var(--vn-paper-light);
  box-shadow: 0 0 0 3px var(--vn-paper), 0 0 0 4px var(--vn-red);
}
.count-box .num {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 700;
  line-height: 1.1;
  color: var(--vn-gold-light);
  font-variant-numeric: tabular-nums;
}
.count-box .lbl {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
  color: var(--vn-paper-light);
}

/* --------------------------------------------------------------------------
   10. TRÌNH TỰ HÔN LỄ
   -------------------------------------------------------------------------- */
.timeline-card { padding: 0; background: none; border: 0; box-shadow: none; }
.timeline-list {
  margin-top: 12px;
  padding: 6px 18px;
  background: var(--vn-paper-light);
  border: 1px solid var(--vn-gold);
}
.timeline-list:empty { display: none; }
.timeline-item {
  display: grid;
  grid-template-columns: 30px 74px minmax(0, 1fr);
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px dashed var(--vn-line-dashed);
}
.timeline-item:last-child { border-bottom: 0; }
/* Cột trái: búp sen nhỏ */
.timeline-line-col {
  grid-column: 1;
  grid-row: 1;
  width: 22px;
  height: 15px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 60 40' fill='%23B3261E'%3E%3Cpath d='M30 36C20 32 14 22 14 12c8 4 14 14 16 24zM30 36c10-4 16-14 16-24-8 4-14 14-16 24z' opacity='.7'/%3E%3Cpath d='M30 36C24 26 24 14 30 4c6 10 6 22 0 32z'/%3E%3C/svg%3E") center / contain no-repeat;
}
.timeline-dot { display: none; }
.timeline-left { grid-column: 2; grid-row: 1; }
.timeline-time {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 700;
  color: var(--vn-red);
}
.timeline-right { grid-column: 3; grid-row: 1; min-width: 0; }
.timeline-text { font-size: 15px; font-weight: 500; color: var(--vn-ink); }

/* --------------------------------------------------------------------------
   11. TRANG PHỤC
   -------------------------------------------------------------------------- */
.dresscode-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 0;
  background: none;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  text-align: center;
  overflow: visible;
}
.dresscode-note {
  margin: 0;
  max-width: 300px;
  font-family: var(--font-body);
  font-style: normal;
  font-size: 15px;
  color: var(--vn-ink);
}
.dresscode-palettes {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
  margin-top: 4px;
}
.dresscode-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  width: 64px;
  max-width: none;
}
.dresscode-item:hover {
  transform: none;
}
.dresscode-swatch {
  width: 54px;
  height: 54px;
  border: 0;
  border-radius: 50%;
  box-shadow: 0 0 0 3px var(--vn-paper), 0 0 0 4px var(--vn-gold);
  transform: none !important;
}
.dresscode-name {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
  text-align: center;
  white-space: normal;
  color: var(--vn-ink);
}

/* --------------------------------------------------------------------------
   12. CHUYỆN CHÚNG MÌNH
   -------------------------------------------------------------------------- */
.story-banner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 0;
  background: none;
  border: 0;
  box-shadow: none;
  text-align: center;
}
.story-banner blockquote {
  margin: 4px 0 0;
  max-width: 320px;
  font-family: var(--font-body);
  font-style: italic;
  font-size: 16px;
  line-height: 1.6;
  color: var(--vn-ink);
}
.story-banner p { margin: 0; font-size: 14px; color: var(--vn-ink-muted); }
.story-banner .btn-line { margin-top: 6px; }

/* --------------------------------------------------------------------------
   13. SỔ LƯU BÚT
   -------------------------------------------------------------------------- */
.guestbook-card { padding: 0; background: none; border: 0; border-radius: 0; box-shadow: none; }
.guestbook-form { display: flex; flex-direction: column; gap: 8px; margin: 0; }
.field-label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: none;
  color: var(--vn-ink);
}

.form-input,
.form-textarea {
  width: 100%;
  min-height: 48px;
  padding: 10px 14px;
  border: 1.5px solid var(--vn-input-border);
  border-radius: 0;
  background: var(--vn-paper-light);
  color: var(--vn-ink);
  font-family: var(--font-body);
  font-size: 15px;
  box-shadow: none;
}
.form-textarea { min-height: 112px; resize: none; }
.form-input::placeholder,
.form-textarea::placeholder { color: #8C6D50; }
.form-input:focus,
.form-textarea:focus { border-color: var(--vn-red); box-shadow: 0 0 0 2px rgba(155, 28, 28, .14); }

.guestbook-actions { display: flex; gap: 10px; }
.btn-wish-icon {
  flex: none;
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid var(--vn-red);
  border-radius: 0;
  background: transparent;
  color: var(--vn-red);
}
.btn-wish-icon:hover { background: rgba(155, 28, 28, .06); }

/* Nút chính (đỏ son đặc) */
.btn-submit-wish,
.rsvp-btn-submit,
.btn-modal-refresh {
  min-height: 50px;
  padding: 0 22px;
  border: 0;
  border-radius: 0;
  background: var(--vn-red);
  color: var(--vn-paper-light);
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: none;
  box-shadow: none;
  cursor: pointer;
  transition: background .2s ease, opacity .2s ease;
}
.btn-submit-wish:hover,
.rsvp-btn-submit:hover,
.btn-modal-refresh:hover { background: var(--vn-red-deep); }
.btn-submit-wish { flex: 1; }
.btn-submit-wish.is-submitting,
.rsvp-btn-submit.is-submitting { opacity: .6; cursor: progress; }

.wishes-list {
  margin-top: 20px;
  max-height: 460px;
  padding-right: 4px;
  gap: 10px;
}
.wishes-list::-webkit-scrollbar-thumb { background: var(--vn-line); border-radius: 0; }
.wish-item {
  padding: 12px 16px;
  background: var(--vn-paper-light);
  border: 1px solid var(--vn-line);
  border-radius: 0;
  box-shadow: none;
}
.wish-item-header { gap: 12px; margin-bottom: 2px; font-size: 12px; }
.wish-author {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: none;
  color: var(--vn-red);
  overflow-wrap: anywhere;
}
.wish-time { flex: none; font-size: 12px; color: var(--vn-ink-muted); }
.wish-message {
  margin: 2px 0 0;
  font-family: var(--font-body);
  font-style: normal;
  font-size: 15px;
  line-height: 1.6;
  color: var(--vn-ink);
  overflow-wrap: anywhere;
}

/* --------------------------------------------------------------------------
   14. HỘP QUÀ MỪNG: TRÁP CƯỚI
   -------------------------------------------------------------------------- */
.gift-section { padding-top: 0; padding-bottom: 0; text-align: center; }
.gift-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: none;
}
.gift-trap { width: 220px; }
.gift-trap-lid {
  height: 22px;
  margin: 0 -10px;
  background: var(--vn-red-deep);
  border: 1px solid var(--vn-gold);
}
.gift-trap-body {
  height: 96px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--vn-red);
  border: 1px solid var(--vn-gold);
  border-top: 0;
}
.gift-trap-seal {
  width: 58px;
  height: 58px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--vn-gold);
  color: var(--vn-red);
  font-family: var(--font-han);
  font-size: 36px;
  line-height: 1;
}
.gift-heading { margin-top: 16px; }
.gift-note { margin: 4px 0 0; max-width: 320px; font-size: 15px; color: var(--vn-ink); }

.gift-envelope-trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  margin-top: 14px;
  padding: 0 28px;
  border: 0;
  border-radius: 0;
  background: var(--vn-red);
  color: var(--vn-paper-light);
  box-shadow: none;
  cursor: pointer;
  transition: background .2s ease;
}
.gift-envelope-trigger:hover { background: var(--vn-red-deep); }
.gift-hint-text {
  margin: 0;
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: none;
  color: inherit;
}
.gift-envelope-trigger:hover .gift-hint-text { color: inherit; transform: none; }

/* --------------------------------------------------------------------------
   15. CẢM ƠN (FOOTER)
   -------------------------------------------------------------------------- */
.exit-room {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: var(--vn-section-gap);
  padding: 56px var(--vn-inline-pad) max(48px, env(safe-area-inset-bottom));
  overflow: hidden;
  background: var(--vn-red);
  color: var(--vn-paper-light);
  text-align: center;
}
.exit-room::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 8px;
  background: var(--vn-zigzag);
}
.exit-room .vn-lotus { color: var(--vn-gold-light); }
.exit-title {
  margin: 6px 0 0;
  font-family: var(--font-display);
  font-size: 34px;
  font-style: italic;
  font-weight: 700;
  line-height: 1.3;
  color: var(--vn-gold-light);
}
.exit-lead { margin: 0; font-size: 15px; }
.exit-names {
  margin: 4px 0 0;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
}
.exit-names:empty { display: none; }
.exit-room .gift-brand-footer {
  margin-top: 14px;
  opacity: 1;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--vn-gold-light);
}

/* --------------------------------------------------------------------------
   16. NÚT NỔI: NHẠC & NGÔN NGỮ
   -------------------------------------------------------------------------- */
.floating-music {
  position: fixed;
  right: 16px;
  bottom: max(16px, env(safe-area-inset-bottom));
  z-index: 800;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--vn-gold);
  border-radius: 0;
  background: var(--vn-paper-light);
  color: var(--vn-red);
  box-shadow: 0 2px 10px rgba(42, 10, 10, .18);
  opacity: 0;
  visibility: hidden;
  animation: none !important;
  transform: none !important;
  transition: opacity .4s ease, visibility .4s ease, background-color .25s ease, color .25s ease, border-color .25s ease, box-shadow .25s ease;
}
.invite-open .floating-music { opacity: 1; visibility: visible; }
.floating-music.playing {
  background: var(--vn-red);
  color: var(--vn-gold-light);
  border-color: var(--vn-gold);
  box-shadow: 0 0 0 3px rgba(155, 28, 28, .35);
  animation: none !important;
  transform: none !important;
}
.floating-music .music-icon,
.floating-music.playing .music-icon {
  display: flex;
  animation: none !important;
  transform: none !important;
}

.floating-lang { top: 16px; right: 16px; }
.lang-trigger-btn,
.lang-dropdown {
  border: 1px solid var(--vn-gold);
  border-radius: 0;
  background: var(--vn-red);
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.lang-trigger-btn {
  min-height: 36px;
  padding: 0 10px 0 12px;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--vn-gold-light);
}
.lang-trigger-btn:hover,
.floating-lang.is-open .lang-trigger-btn {
  background: var(--vn-red-deep);
  border-color: var(--vn-gold);
  color: var(--vn-gold-light);
  box-shadow: none;
  transform: none;
}
.lang-dropdown { padding: 0; gap: 0; top: calc(100% - 1px); }
.lang-btn {
  min-height: 40px;
  border-radius: 0;
  font-family: var(--font-body);
  font-size: 12px;
  letter-spacing: 2px;
  color: var(--vn-paper-light);
}
.lang-btn:hover { background: var(--vn-red-deep); color: var(--vn-gold-light); }
.lang-btn.active { background: var(--vn-gold); color: var(--vn-red-ink); box-shadow: none; }

/* --------------------------------------------------------------------------
   17. MODAL: RSVP, GỢI Ý LỜI CHÚC, HỘP QUÀ
   -------------------------------------------------------------------------- */
.modal-overlay,
.wish-suggestions-modal {
  background: rgba(42, 10, 10, .72);
  backdrop-filter: none;
}
.wish-suggestions-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  visibility: hidden;
  transition: opacity .3s ease, visibility .3s ease;
}
.wish-suggestions-modal.open { opacity: 1; visibility: visible; }

.modal-box,
.wish-modal-card,
.gift-modal-box {
  width: min(440px, 100%);
  max-height: calc(100dvh - 32px);
  overflow-y: auto;
  padding: 28px 22px 24px;
  background: var(--vn-paper-light);
  border: 2px solid var(--vn-red);
  border-radius: 0;
  outline: 1px solid var(--vn-gold);
  outline-offset: -8px;
  box-shadow: none;
  color: var(--vn-ink);
  text-align: left;
}

.modal-close,
.wish-modal-close,
.gift-modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid var(--vn-red);
  border-radius: 0;
  background: var(--vn-paper-light);
  color: var(--vn-red);
  font-size: 14px;
  transform: none;
}
.modal-close:hover,
.wish-modal-close:hover,
.gift-modal-close:hover { background: var(--vn-red); color: var(--vn-paper-light); }

.modal-title,
.wish-modal-title h3,
.gift-modal-title {
  margin: 0 56px 6px 0;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 26px;
  line-height: 1.25;
  letter-spacing: 0;
  text-transform: none;
  text-align: left;
  color: var(--vn-red);
}
.modal-subtitle,
.wish-modal-subtitle {
  margin: 0 0 18px;
  font-size: 14px;
  color: var(--vn-ink-muted);
  text-align: left;
}

/* RSVP */
.rsvp-modal-box { position: relative; }
.rsvp-form-group { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.rsvp-form-label {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: none;
  color: var(--vn-ink);
}
select.form-input { appearance: auto; }
.rsvp-choices { gap: 8px; margin: 0; }
.rsvp-radio-label {
  min-height: 48px;
  padding: 10px 14px;
  border: 1.5px solid var(--vn-line);
  border-radius: 0;
  background: var(--vn-paper-light);
  font-size: 14px;
}
.rsvp-radio-label:has(input:checked) { border-color: var(--vn-red); background: #FFF8EC; color: var(--vn-ink); box-shadow: inset 0 0 0 1px var(--vn-red); }
.rsvp-radio-label input { accent-color: var(--vn-red); }
.rsvp-btn-submit { width: 100%; margin-top: 6px; }

/* Gợi ý lời chúc */
.wish-modal-card { position: relative; }
.wish-modal-header { display: block; }
.wish-modal-title { display: block; }
.wish-suggestions-list { display: flex; flex-direction: column; gap: 8px; }
.wish-suggestion-item {
  padding: 12px 14px;
  background: var(--vn-paper);
  border: 1px solid var(--vn-line);
  font-size: 15px;
  line-height: 1.55;
  cursor: pointer;
  transition: border-color .2s ease;
}
.wish-suggestion-item:hover { border-color: var(--vn-red); }
.wish-modal-footer { display: flex; gap: 10px; margin-top: 16px; }
.wish-modal-footer button { flex: 1; margin: 0; justify-content: center; }
.btn-modal-cancel {
  min-height: 50px;
  border: 1.5px solid var(--vn-red);
  border-radius: 0;
  background: transparent;
  color: var(--vn-red);
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 700;
}
.btn-modal-cancel:hover { background: rgba(155, 28, 28, .06); }

/* Hộp quà */
.gift-modal-box { position: relative; display: block; padding: 0; animation: none; }
.gift-modal-header { position: static; padding: 28px 22px 0; background: none; color: var(--vn-ink); text-align: left; }
.gift-modal-body { padding: 18px 22px 24px; background: none; }
.gift-cols-container { gap: 14px; }
.gift-person-card {
  padding: 14px;
  background: var(--vn-paper);
  border: 1px solid var(--vn-gold);
  text-align: center;
  align-items: stretch;
}
.gift-person-title {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--vn-red);
}
.gift-qr-card {
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  margin: 8px 0 12px;
  padding: 6px;
  background: var(--vn-red);
  border: 0;
  border-radius: 0;
  box-shadow: none;
}
.gift-qr-img { background: #FFFFFF; padding: 6px; }
.gift-bank-info { margin-bottom: 10px; }
.gift-bank-name {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--vn-gold-text);
}
.gift-bank-number {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: var(--vn-ink);
  overflow-wrap: anywhere;
}
.gift-bank-owner { font-size: 12px; color: var(--vn-ink-muted); text-transform: uppercase; letter-spacing: 1px; }

@media (max-width: 520px) {
  .gift-modal-box { width: 100%; }
  .gift-modal-title { font-size: 24px; }
  .gift-qr-card { width: 100%; height: auto; padding: 6px; border-radius: 0; }
  .gift-cols-container { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .gift-cols-container.single-col { grid-template-columns: 1fr; }
  .gift-person-card { padding: 10px; }
  .gift-bank-number { font-size: 17px; }
}

/* Toast */
.toast {
  border-radius: 0;
  border: 1px solid var(--vn-gold);
  background: var(--vn-red);
  color: var(--vn-paper-light);
  font-size: 14px;
  font-weight: 600;
  padding: 12px 18px;
  box-shadow: none;
}

/* --------------------------------------------------------------------------
   18. MÀN HÌNH LỖI / THIỆP KHÔNG TỒN TẠI
   -------------------------------------------------------------------------- */
.not-found-screen { background: var(--vn-red); }
.not-found-card {
  max-width: 420px;
  padding: 32px 24px;
  background: var(--vn-paper-light);
  border: 2px solid var(--vn-gold);
  outline: 1px solid var(--vn-gold);
  outline-offset: -8px;
  border-radius: 0;
  box-shadow: none;
  text-align: center;
}
.not-found-icon { color: var(--vn-lotus); margin-bottom: 14px; display: flex; justify-content: center; }
.not-found-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 26px;
  color: var(--vn-red);
}
.not-found-desc { font-size: 15px; color: var(--vn-ink-muted); }

/* --------------------------------------------------------------------------
   19. MÀN HÌNH NHỎ / RỘNG
   -------------------------------------------------------------------------- */
@media (min-width: 900px) {
  .app-container,
  .envelope-box { box-shadow: 0 0 0 1px rgba(217, 164, 65, .35); }
}

@media (max-width: 360px) {
  :root { --vn-gutter: 18px; }
  .envelope-names { font-size: 32px; }
  .ceremony-day { font-size: 50px; }
  .count-box .num { font-size: 22px; }
  .count-box .lbl { font-size: 11px; }
  .timeline-item { grid-template-columns: 26px 64px minmax(0, 1fr); }
}

/* --------------------------------------------------------------------------
   20. THANG CHỮ CHUNG — chữ cùng cấp dùng cùng một kiểu
   (đặt cuối file để thắng các khai báo lẻ phía trên; màu vẫn theo nền từng khối)
   -------------------------------------------------------------------------- */
/* Cấp 1 — Tiêu đề khối (in hoa) */
.vn-title,
.vn-banner .card-heading,
.ceremony-type-title,
#reception-bride .rb-heading,
.dresscode-card .card-heading,
.countdown-card .card-heading,
.timeline-card .card-heading,
.guestbook-card .guestbook-heading,
.gift-wrapper .gift-heading {
  margin: 0;
  font-family: var(--font-display);
  font-size: 22px;
  font-style: normal;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: 1px;
  text-transform: uppercase;
  text-align: center;
  text-wrap: balance;
}

/* Khoảng cách từ tiêu đề khối xuống nội dung: cùng 16px */
#gallery { gap: 16px; }
.countdown-grid,
.timeline-list,
.guestbook-form { margin-top: 16px; }
.dresscode-card { gap: 16px; }
.dresscode-card .dresscode-note { margin: 0 auto; }
.dresscode-palettes { margin-top: 0; }
.gift-wrapper .gift-heading { margin-top: 16px; }
.gift-note { margin-top: 8px; }

/* Nhãn nhỏ dưới ô tròn (Ngày/Giờ…, tên màu) */
.dresscode-name,
.count-box .lbl {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: 0;
  text-transform: none;
}

/* Cấp 2 — Tiêu đề phụ in hoa phía trên tiêu đề khối */
.vn-kicker,
.cover-kicker,
.hero-invite-guest,
#reception-bride .rb-lead,
#reception-bride .rb-venue-label {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.6;
  letter-spacing: 4px;
  text-transform: uppercase;
}

/* Cấp 3 — Nhãn nhỏ trong ô (Nhà trai, Đón khách, tên ngân hàng…) */
.family-side small,
.reception-time-col small,
#reception-bride .rb-time-col small,
.gift-bank-name {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.6;
  letter-spacing: 2px;
  text-transform: uppercase;
}

/* Tên người */
.family-side .groom-name,
.family-side .bride-name,
.gift-person-title {
  font-family: var(--font-display);
  font-size: 20px;
  font-style: normal;
  font-weight: 700;
  line-height: 1.3;
}

/* Tên địa điểm */
.venue-name,
#reception-bride .rb-venue-name {
  font-family: var(--font-body);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.4;
}
#reception-bride .rb-venue-name-row {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.ceremony-note-place {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

/* Địa chỉ & tên bố mẹ */
.venue-address,
#reception-bride .rb-venue-address,
.family-side h4,
.family-side p,
.ceremony-note {
  font-family: var(--font-body);
  font-size: 14px;
  font-style: normal;
  font-weight: 400;
  line-height: 1.6;
}
.venue-address,
#reception-bride .rb-venue-address,
.family-side p { color: var(--vn-ink-muted); }
.family-side h4 { color: var(--vn-ink); }

/* Dòng ngày giờ */
.ceremony-time,
.reception-date-text,
#reception-bride .rb-weekday {
  font-family: var(--font-body);
  font-size: 15px;
  font-style: normal;
  font-weight: 600;
  line-height: 1.6;
  letter-spacing: 0;
  text-transform: none;
}

/* Dòng âm lịch */
.envelope-lunar,
.ceremony-time-badge .lunar,
.reception-lunar,
#reception-bride .rb-lunar {
  font-family: var(--font-body);
  font-size: 13px;
  font-style: italic;
  font-weight: 400;
  line-height: 1.6;
  text-transform: none;
}

/* Số ngày lớn */
.ceremony-day,
#reception-bride .rb-day {
  font-family: var(--font-display);
  font-size: 60px;
  font-weight: 800;
  line-height: 1;
}

/* Giờ trong ô đỏ */
.reception-time-col strong,
#reception-bride .rb-time-col strong {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 700;
  line-height: 1.3;
}

/* Đoạn mô tả & câu trích */
.hero-quote,
.dresscode-note,
.gift-note,
.exit-lead,
.timeline-text,
.wish-message,
.modal-subtitle,
.wish-modal-subtitle {
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 400;
  line-height: 1.7;
}
.hero-quote { font-style: italic; }

/* Nút hành động */
.vn-btn,
.reception-actions button,
.gift-envelope-trigger,
.gift-hint-text,
.btn-submit-wish,
.rsvp-btn-submit,
.btn-modal-refresh,
.btn-modal-cancel {
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: 0;
  text-transform: none;
}
/* Màn hẹp: hai nút tiệc cưới xếp dọc để chữ không bị gãy dòng */
@media (max-width: 420px) {
  .reception-actions { flex-direction: column; }
}

/* Nhãn ô nhập */
.field-label,
.rsvp-form-label {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: none;
}

@media (max-width: 360px) {
  .ceremony-day,
  #reception-bride .rb-day { font-size: 50px; }
}

/* --------------------------------------------------------------------------
   21. HỘP QUÀ: HAI NÚT TRONG THẺ NGÂN HÀNG
   Xếp dọc, rộng bằng thẻ, cao bằng nhau, chữ không xuống dòng
   -------------------------------------------------------------------------- */
.gift-person-card .gift-actions-row {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
  margin-top: 4px;
}
.gift-person-card .btn-copy-acc,
.gift-person-card .btn-save-qr {
  width: 100%;
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 12px;
  border: 1.5px solid var(--vn-red);
  border-radius: 0;
  box-shadow: none;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 0;
  text-transform: none;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background .2s ease, color .2s ease;
  transform: none;
}
.gift-person-card .btn-copy-acc svg,
.gift-person-card .btn-save-qr svg { flex: none; }
.gift-person-card .btn-copy-acc { background: var(--vn-red); color: var(--vn-paper-light); }
.gift-person-card .btn-copy-acc:hover { background: var(--vn-red-deep); border-color: var(--vn-red-deep); color: var(--vn-paper-light); transform: none; box-shadow: none; }
.gift-person-card .btn-save-qr { background: transparent; color: var(--vn-red); }
.gift-person-card .btn-save-qr:hover { background: rgba(155, 28, 28, .08); color: var(--vn-red); transform: none; box-shadow: none; }
.gift-person-card .btn-copy-acc:active,
.gift-person-card .btn-save-qr:active { transform: none; }

/* --------------------------------------------------------------------------
   22. TIỆC NHÀ GÁI: ghi đè selector #id của file cũ — cùng thang chữ & nút vuông
   -------------------------------------------------------------------------- */
#reception-bride .rb-heading,
#reception .reception-header .vn-title {
  margin: 0;
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: 1px;
  text-transform: uppercase;
  text-align: center;
  /* Không balance — để chỉ xuống dòng sau "Cưới" khi hẹp; đủ chỗ thì 1 dòng */
  text-wrap: wrap;
  color: var(--vn-red);
}
#reception-bride .rb-direction {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 46px;
  margin-top: 12px;
  padding: 0 28px;
  border: 0;
  border-radius: 0;
  background: var(--vn-ink);
  color: var(--vn-paper-light);
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 700;
  line-height: 1.3;
  text-decoration: none;
  box-shadow: none;
}
#reception-bride .rb-direction:hover { filter: brightness(1.08); }

#reception-bride .rb-lead,
#reception-bride .rb-venue-label {
  margin: 12px 0 0;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.6;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--vn-gold-text);
}
#reception-bride .rb-lead {
  white-space: nowrap;
  letter-spacing: 1.5px;
}
#reception-bride .rb-weekday {
  margin: 4px 0 0;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.6;
  letter-spacing: 0;
  text-transform: none;
}
#reception-bride .rb-day { font-size: 60px; font-weight: 800; line-height: 1; }
#reception-bride .rb-month {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
  color: var(--vn-ink);
}
#reception-bride .rb-year { font-size: 20px; line-height: 1.2; }
#reception-bride .rb-lunar {
  margin: 4px 0 0;
  font-size: 13px;
  font-style: italic;
  line-height: 1.6;
  text-transform: none;
  color: var(--vn-ink-muted);
}
#reception-bride .rb-time-col small {
  font-size: 12px;
  font-weight: 700;
  line-height: 1.6;
  letter-spacing: 2px;
  text-transform: uppercase;
}
#reception-bride .rb-time-col strong { font-size: 28px; line-height: 1.3; }
#reception-bride .rb-venue { margin-top: 20px; }
#reception-bride .rb-venue-name-row { margin: 4px 0 0; }
#reception-bride .rb-venue-name { font-size: 18px; line-height: 1.4; }
#reception-bride .rb-venue-address {
  margin: 4px 0 0;
  font-size: 14px;
  line-height: 1.6;
  color: var(--vn-ink-muted);
}
#reception-bride .bride-reception-card { border-radius: 0; box-shadow: none; }

/* --------------------------------------------------------------------------
   23. KHỐI LỄ THÀNH HÔN: nhịp xuống dòng đều nhau, mỗi dòng một cấp chữ
   -------------------------------------------------------------------------- */
.ceremony-inner { display: flex; flex-direction: column; align-items: center; }
.ceremony-inner .vn-kicker { margin: 0; }
.ceremony-type-title { margin: 6px 0 0; }
.ceremony-time-badge { width: 100%; margin-top: 20px; }
.ceremony-dow,
.ceremony-month {
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  line-height: 1.6;
}
.ceremony-time { margin: 14px 0 0; }
.ceremony-time-badge .lunar { margin: 2px 0 0; }
.ceremony-note {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  margin: 20px 0 0;
  padding-top: 16px;
  border-top: 1px solid rgba(217, 164, 65, .5);
  width: 100%;
}
.ceremony-note-label {
  font-size: 13px;
  font-style: italic;
  line-height: 1.6;
  color: var(--vn-gold-light);
}
.ceremony-note-place {
  font-family: var(--font-body);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.4;
  overflow-wrap: anywhere;
}
.ceremony-direction { margin-top: 18px; }

/* Câu trích ở phần Ngày chung đôi: luôn gọn trên 1 dòng (co chữ theo bề rộng màn hình) */
.hero-section .hero-quote {
  max-width: none;
  width: 100%;
  text-wrap: balance;
}
/* Chỉ bản tiếng Việt (câu ngắn) mới ép 1 dòng; EN/ZH tự xuống dòng bình thường */
html[lang="vi"] .hero-section .hero-quote {
  font-size: clamp(12px, 3.8vw, 15px);
  white-space: nowrap;
}

/* Tên bố mẹ: mỗi người một dòng, không tự xuống dòng (thu chữ nhẹ trên màn hẹp) */
.family-side h4 {
  white-space: nowrap;
  overflow-wrap: normal;
  font-size: clamp(11.5px, 3.3vw, 14px);
  /* Luôn giữ chỗ 2 dòng, căn giữa dọc: thiếu bố hoặc mẹ thì địa chỉ 2 bên vẫn thẳng hàng */
  display: grid;
  align-content: center;
  justify-items: center;
  width: 100%;
  min-height: calc(2 * 1.6em);
}
.family-side { padding-left: 8px; padding-right: 8px; }
