:root {
  --font-wedding: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --wine-bg: #4e1318;
  --wine-card: #4e1318;
  --wine-dark: #4e1318;
  --wine-light: #722128;
  --wine-text: #6d2027;
  --wine-muted: #9a5f5d;
  --wine-ornament: #8b3e42;
  --cream: #fbf4ec;
  --cream-soft: #fff8ef;
  --cream-text: #fff4e9;
  --olive: #92875f;
  --soft-gold: #b98a48;
  --name-weight: 300;
  --body-weight: 600;
  --heading-weight: 700;
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  min-height: 100%;
  margin: 0;
}

body {
  font-family: var(--font-wedding);
  background: var(--wine-bg);
  color: var(--wine-text);
  overflow: hidden;
}

body.invitation-opened {
  overflow-x: hidden;
  overflow-y: auto;
}

body.gift-modal-open {
  overflow: hidden;
}

button {
  font: inherit;
}

.opening-screen {
  position: fixed;
  inset: 0;
  z-index: 10;
  display: grid;
  place-items: center;
  width: 100vw;
  height: 100vh;
  min-height: 100svh;
  padding: 24px;
  overflow: hidden;
  background: var(--wine-bg);
  transition: opacity 650ms cubic-bezier(0.22, 0.8, 0.22, 1);
}

.opening-screen::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(circle at 50% 33%, rgba(255, 248, 239, 0.026), transparent 32%),
    rgba(58, 6, 12, 0.1);
  pointer-events: none;
}

.opening-screen.opening-exit {
  opacity: 0;
  pointer-events: none;
}

.opening-screen.opening-exit .falling-hearts {
  opacity: 0.28;
}

.falling-hearts {
  position: absolute;
  inset: 0;
  z-index: 1;
  overflow: hidden;
  pointer-events: none;
}

.falling-heart {
  display: block;
  position: absolute;
  top: -12vh;
  left: var(--start-x);
  width: var(--size);
  height: var(--size);
  opacity: var(--heart-opacity);
  transform: translate3d(0, -12vh, 0) rotate(var(--start-rotate));
  animation: heart-fall var(--duration) linear infinite;
  animation-delay: var(--delay);
  will-change: transform, opacity;
}

.seed-heart {
  position: absolute;
  z-index: 3;
  display: block;
  color: #c19a62;
  font-family: var(--font-wedding);
  font-size: 24px;
  line-height: 1;
  opacity: 0.9;
  pointer-events: none;
  animation: seed-heart-fall 6.8s linear infinite;
  will-change: transform, opacity;
}

.seed-heart-1 {
  left: 17vw;
  top: -12vh;
  color: #d9b59d;
  font-size: 24px;
  animation-delay: -5.5s;
  animation-duration: 6.4s;
}

.seed-heart-2 {
  left: 26vw;
  top: -12vh;
  color: #c19a62;
  font-size: 28px;
  animation-delay: -1.5s;
  animation-duration: 7.2s;
}

.seed-heart-3 {
  left: 72vw;
  top: -12vh;
  color: #c19a62;
  font-size: 30px;
  animation-delay: -8s;
  animation-duration: 8s;
}

.seed-heart-4 {
  left: 84vw;
  top: -12vh;
  color: #b98a48;
  font-size: 21px;
  animation-delay: -3.5s;
  animation-duration: 6.8s;
}

.seed-heart-5 {
  left: 92vw;
  top: -12vh;
  color: #b98a48;
  font-size: 19px;
  animation-delay: -9s;
  animation-duration: 7.6s;
}

.seed-heart-6 {
  left: 27vw;
  top: -12vh;
  color: #8f2028;
  font-size: 22px;
  opacity: 0.6;
  animation-delay: -6.5s;
  animation-duration: 6.2s;
}

.seed-heart-7 {
  left: 39vw;
  top: -12vh;
  color: #d9b59d;
  font-size: 18px;
  opacity: 0.62;
  animation-delay: -4.2s;
  animation-duration: 7s;
}

.seed-heart-8 {
  left: 58vw;
  top: -12vh;
  color: #b98a48;
  font-size: 20px;
  opacity: 0.7;
  animation-delay: -7.4s;
  animation-duration: 8.4s;
}

.seed-heart-9 {
  left: 78vw;
  top: -12vh;
  color: #c19a62;
  font-size: 26px;
  opacity: 0.82;
  animation-delay: -2.8s;
  animation-duration: 6.6s;
}

.seed-heart-10 {
  left: 7vw;
  top: -12vh;
  color: #a9373d;
  font-size: 17px;
  opacity: 0.56;
  animation-delay: -8.6s;
  animation-duration: 7.8s;
}

.falling-hearts > .falling-heart:nth-of-type(11) {
  width: 18px;
  height: 18px;
  opacity: 0.7;
  top: -10vh;
  animation: heart-fall 8s linear -2s infinite;
}

.falling-hearts > .falling-heart:nth-of-type(12) {
  width: 20px;
  height: 20px;
  opacity: 0.72;
  top: -10vh;
  animation: heart-fall 11s linear -4s infinite;
}

.falling-hearts > .falling-heart:nth-of-type(13) {
  width: 14px;
  height: 14px;
  opacity: 0.58;
  top: -10vh;
  animation: heart-fall 9s linear -5s infinite;
}

.falling-hearts > .falling-heart:nth-of-type(14) {
  width: 22px;
  height: 22px;
  opacity: 0.74;
  top: -10vh;
  animation: heart-fall 12s linear -3s infinite;
}

.falling-hearts > .falling-heart:nth-of-type(15) {
  width: 18px;
  height: 18px;
  opacity: 0.68;
  top: -10vh;
  animation: heart-fall 10s linear -6s infinite;
}

.falling-hearts > .falling-heart:nth-of-type(16) {
  width: 13px;
  height: 13px;
  opacity: 0.7;
  top: -10vh;
  animation: heart-fall 8.5s linear -1s infinite;
}

.falling-hearts > .falling-heart:nth-of-type(17) {
  width: 12px;
  height: 12px;
  opacity: 0.62;
  top: -10vh;
  animation: heart-fall 13s linear -7s infinite;
}

.falling-hearts > .falling-heart:nth-of-type(18) {
  width: 16px;
  height: 16px;
  opacity: 0.62;
  top: -10vh;
  animation: heart-fall 9.5s linear -3s infinite;
}

.falling-heart::before,
.falling-heart::after,
.heart-icon::before,
.heart-icon::after {
  content: "";
  position: absolute;
  border-radius: 50%;
}

.falling-heart {
  background: transparent;
  transform-origin: center;
}

.falling-heart {
  display: grid;
  place-items: center;
  color: var(--particle-color);
  font-family: var(--font-wedding);
  font-size: calc(var(--size) * 1.35);
  line-height: 1;
  border-radius: 0;
  text-shadow: 0 2px 6px rgba(30, 0, 4, 0.08);
}

.falling-heart::before {
  content: "♥";
  position: static;
  width: auto;
  height: auto;
  background: transparent;
  border-radius: 0;
}

.falling-heart::after {
  display: none;
}

.falling-hearts .falling-heart::before {
  content: "\2665";
}

.opening-card {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: min(82vw, 600px);
  height: min(420px, calc(100svh - 48px));
  min-height: 0;
  padding: 22px 58px 31px;
  overflow: hidden;
  border-radius: 7px;
  background: var(--cream);
  box-shadow: 0 18px 48px rgba(18, 0, 4, 0.28);
  opacity: 0;
  transform: translateY(12px) scale(0.985);
  animation: card-enter 850ms cubic-bezier(0.22, 0.8, 0.22, 1) 90ms forwards;
  transition:
    opacity 650ms cubic-bezier(0.22, 0.8, 0.22, 1),
    filter 650ms cubic-bezier(0.22, 0.8, 0.22, 1),
    transform 650ms cubic-bezier(0.22, 0.8, 0.22, 1);
}

.opening-screen.opening-exit .opening-card {
  opacity: 0;
  filter: blur(3px);
  transform: scale(1.025);
}

.floral {
  position: absolute;
  top: 23px;
  width: 175px;
  max-width: 30%;
  height: auto;
  pointer-events: none;
  user-select: none;
  transform-origin: center;
  z-index: 0;
  opacity: 0;
}

.floral-left {
  left: -35px;
  animation:
    floral-enter-left 680ms cubic-bezier(0.22, 0.8, 0.22, 1) 300ms forwards,
    floral-float-left 6.6s ease-in-out 1200ms infinite;
}

.floral-right {
  right: -35px;
  animation:
    floral-enter-right 680ms cubic-bezier(0.22, 0.8, 0.22, 1) 370ms forwards,
    floral-float-right 7s ease-in-out 1400ms infinite;
}

.heart-badge {
  position: relative;
  isolation: isolate;
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  margin-top: -17px;
  margin-bottom: 31px;
  border-radius: 50%;
  background: var(--wine-dark);
  box-shadow:
    0 13px 25px rgba(76, 12, 18, 0.25),
    0 5px 12px rgba(48, 0, 7, 0.20),
    0 0 34px rgba(91, 13, 19, 0.08);
  z-index: 1;
  animation:
    reveal-item 620ms cubic-bezier(0.22, 0.8, 0.22, 1) 400ms forwards,
    heart-badge-breath 2.35s ease-in-out 780ms infinite;
}

.heart-badge::before,
.heart-badge::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}

.heart-badge::before {
  inset: -15px;
  z-index: -1;
  background: radial-gradient(circle, rgba(90, 11, 18, 0.22) 0%, rgba(90, 11, 18, 0.10) 38%, transparent 68%);
  opacity: 0.52;
  transform: scale(0.82);
  animation: heart-badge-halo 2.35s ease-in-out 780ms infinite;
}

.heart-badge::after {
  inset: 6px 9px auto auto;
  z-index: 0;
  width: 16px;
  height: 14px;
  background: radial-gradient(circle, rgba(255, 248, 239, 0.34), rgba(255, 248, 239, 0));
  opacity: 0.58;
  animation: heart-badge-glint 2.35s ease-in-out 780ms infinite;
}

.heart-icon {
  position: relative;
  z-index: 2;
  width: 17px;
  height: 17px;
  border-radius: 4px 4px 2px 4px;
  background: var(--cream-soft);
  transform: rotate(45deg);
  animation: heart-pulse 2.35s ease-in-out 680ms infinite;
}

.heart-icon::before {
  width: 17px;
  height: 17px;
  top: -8px;
  left: 0;
  background: var(--cream-soft);
}

.heart-icon::after {
  width: 17px;
  height: 17px;
  top: 0;
  left: -8px;
  background: var(--cream-soft);
}

.couple-names {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: 0;
  color: var(--wine-text);
  font-family: var(--font-wedding);
  font-size: 38px;
  font-weight: var(--name-weight);
  line-height: 0.92;
  letter-spacing: 0;
  text-align: center;
  z-index: 1;
  animation-delay: 500ms;
}

.ampersand {
  margin: 7px 0 8px;
  font-family: var(--font-wedding);
  font-size: 21px;
  font-weight: var(--name-weight);
  line-height: 1;
}

.ornament {
  display: flex;
  align-items: center;
  gap: 11px;
  margin-top: 18px;
  color: var(--wine-ornament);
  z-index: 1;
}

.ornament span {
  display: block;
  width: 36px;
  height: 1px;
  background: rgba(141, 69, 72, 0.58);
}

.ornament i {
  position: relative;
  display: block;
  width: 13px;
  height: 9px;
}

.ornament i::before,
.ornament i::after {
  content: "";
  position: absolute;
  top: 2px;
  width: 5px;
  height: 5px;
  border-radius: 50% 50% 1px 50%;
  border: 1px solid rgba(141, 69, 72, 0.66);
  transform: rotate(45deg);
}

.ornament i::before {
  left: 1px;
}

.ornament i::after {
  right: 1px;
  transform: rotate(225deg);
}

.wedding-date,
.invitation-line {
  margin: 0;
  color: #8c4c4e;
  font-family: var(--font-wedding);
  font-size: 15px;
  font-weight: var(--body-weight);
  line-height: 1.2;
  text-align: center;
  z-index: 1;
}

.wedding-date {
  margin-top: 18px;
}

.invitation-line {
  margin-top: 24px;
}

.open-button {
  position: relative;
  isolation: isolate;
  min-width: 140px;
  min-height: 48px;
  margin-top: 27px;
  padding: 0 30px;
  border: 0;
  border-radius: 24px;
  background: var(--wine-dark);
  color: var(--cream-soft);
  cursor: pointer;
  font-family: var(--font-wedding);
  font-size: 20px;
  font-weight: var(--body-weight);
  line-height: 1;
  overflow: hidden;
  box-shadow:
    0 8px 20px rgba(75, 10, 18, 0.28),
    0 0 0 rgba(251, 244, 236, 0);
  transition:
    background-color 180ms ease,
    box-shadow 180ms ease,
    transform 180ms ease;
  z-index: 1;
  animation:
    reveal-item 620ms cubic-bezier(0.22, 0.8, 0.22, 1) 900ms forwards,
    button-breath 2.9s ease-in-out 920ms infinite;
}

.open-button span {
  position: relative;
  z-index: 3;
  display: inline-block;
  color: transparent;
  background:
    linear-gradient(
      90deg,
      var(--cream-soft) 0%,
      var(--cream-soft) 37%,
      #fffdf8 50%,
      var(--cream-soft) 63%,
      var(--cream-soft) 100%
    );
  background-size: 240% 100%;
  background-position: 120% 0;
  -webkit-background-clip: text;
  background-clip: text;
  text-shadow: 0 0 1px rgba(255, 248, 239, 0.18);
  animation:
    button-text-shine 2.55s ease-in-out 0.2s infinite,
    button-label-pulse 2.9s ease-in-out 0.9s infinite;
}

.open-button::before {
  content: "";
  position: absolute;
  inset: 2px;
  z-index: 0;
  border-radius: inherit;
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 248, 239, 0.18), transparent 46%),
    linear-gradient(180deg, rgba(255, 248, 239, 0.10), transparent 48%);
  opacity: 0.42;
  animation: button-inner-glow 2.9s ease-in-out 520ms infinite;
  pointer-events: none;
}

.open-button::after {
  content: "";
  position: absolute;
  top: -45%;
  left: -70%;
  z-index: 2;
  width: 52%;
  height: 190%;
  background: linear-gradient(
    100deg,
    transparent 0%,
    rgba(255, 249, 242, 0.0) 22%,
    rgba(255, 249, 242, 0.56) 50%,
    rgba(255, 249, 242, 0.0) 78%,
    transparent 100%
  );
  transform: skewX(-24deg);
  animation: button-shine 2.9s ease-in-out 0.2s infinite;
  pointer-events: none;
}

.open-button:hover {
  background: var(--wine-light);
  box-shadow:
    0 11px 25px rgba(75, 10, 18, 0.34),
    0 0 15px rgba(251, 244, 236, 0.08);
  transform: translateY(-2px);
}

.open-button:active,
.open-button.is-opening {
  transform: translateY(0) scale(0.96);
}

.open-button:focus-visible {
  outline: 2px solid rgba(116, 42, 49, 0.42);
  outline-offset: 4px;
}

.reveal-item {
  opacity: 0;
  transform: translateY(7px);
  animation: reveal-item 620ms cubic-bezier(0.22, 0.8, 0.22, 1) forwards;
}

.heart-badge.reveal-item {
  animation:
    reveal-item 620ms cubic-bezier(0.22, 0.8, 0.22, 1) 430ms forwards,
    heart-badge-breath 2.35s ease-in-out 780ms infinite;
}

.couple-names.reveal-item {
  animation-delay: 520ms;
}

.ornament.reveal-item {
  animation-delay: 610ms;
}

.wedding-date.reveal-item {
  animation-delay: 700ms;
}

.invitation-line.reveal-item {
  animation-delay: 790ms;
}

.open-button.reveal-item {
  animation:
    reveal-item 620ms cubic-bezier(0.22, 0.8, 0.22, 1) 880ms forwards,
    button-breath 2.9s ease-in-out 920ms infinite;
}

.main-wedding-page {
  display: none;
  min-height: 100svh;
  background: var(--wine-bg);
  opacity: 0;
  color: var(--cream-soft);
}

.main-wedding-page.show {
  display: block;
  animation: page-show 760ms cubic-bezier(0.22, 0.8, 0.22, 1) forwards;
}

.wedding-hero {
  position: relative;
  display: grid;
  place-items: end center;
  min-height: 100svh;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(78, 19, 23, 0.12), rgba(78, 19, 23, 0.88)),
    var(--wine-bg);
}

.hero-photo,
.portrait-panel {
  background-color: #eadfd4;
  background-position: center;
  background-size: cover;
}

.hero-photo-main {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(78, 19, 23, 0.34)),
    url("../assets/images/slide1.jpg"),
    linear-gradient(135deg, #f7efe8, #c9a58e 48%, #4e1317);
  filter: saturate(0.96);
  transform: scale(1.04);
  animation: hero-kenburns 18s ease-out forwards;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(28, 4, 7, 0.04) 0%, rgba(78, 19, 23, 0.22) 42%, rgba(78, 19, 23, 0.92) 100%),
    radial-gradient(circle at 50% 74%, rgba(255, 248, 239, 0.13), transparent 34%);
}

.hero-content {
  position: relative;
  z-index: 1;
  width: min(100%, 760px);
  padding: 0 24px 88px;
  text-align: center;
}

.hero-kicker,
.section-eyebrow {
  margin: 0;
  color: #d6b08a;
  font-family: var(--font-wedding);
  font-size: 12px;
  font-weight: var(--body-weight);
  letter-spacing: 2px;
  line-height: 1.2;
  text-transform: uppercase;
}

.hero-names {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: 18px 0 14px;
  color: var(--cream-soft);
  font-family: var(--font-wedding);
  font-size: clamp(52px, 9vw, 92px);
  font-weight: var(--name-weight);
  line-height: 0.88;
  text-shadow: 0 10px 34px rgba(20, 0, 3, 0.34);
}

.hero-names span:nth-child(2) {
  margin: 12px 0;
  color: #e4c7a3;
  font-size: clamp(24px, 4vw, 34px);
  line-height: 1;
}

.hero-date {
  margin: 0;
  color: #f4e5d7;
  font-family: var(--font-wedding);
  font-size: 16px;
  letter-spacing: 4px;
}

.scroll-cue {
  position: absolute;
  left: 50%;
  bottom: 26px;
  z-index: 2;
  width: 22px;
  height: 36px;
  border: 1px solid rgba(255, 248, 239, 0.58);
  border-radius: 999px;
  transform: translateX(-50%);
}

.scroll-cue span {
  position: absolute;
  top: 8px;
  left: 50%;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--cream-soft);
  transform: translateX(-50%);
  animation: scroll-dot 1.8s ease-in-out infinite;
}

.section-inner {
  width: min(100% - 32px, 1040px);
  margin: 0 auto;
}

.intro-section,
.details-section,
.schedule-section,
.venue-section {
  position: relative;
  padding: 82px 0;
}

.intro-section {
  background: var(--cream);
  color: var(--wine-text);
}

.intro-grid {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(280px, 0.9fr) minmax(180px, 1fr);
  gap: 28px;
  align-items: center;
}

.portrait-panel {
  min-height: 520px;
  border-radius: 8px;
  box-shadow: 0 18px 42px rgba(66, 16, 20, 0.16);
}

.portrait-panel-left {
  background-image:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(78, 19, 23, 0.08)),
    url("../assets/images/slide1.jpg"),
    linear-gradient(135deg, #f7efe8, #c9a58e 48%, #4e1317);
}

.portrait-panel-right {
  margin-top: 58px;
  background-image:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(78, 19, 23, 0.08)),
    url("../assets/images/slide2.jpg"),
    linear-gradient(135deg, #f7efe8, #c9a58e 48%, #4e1317);
}

.intro-copy {
  text-align: center;
}

.intro-copy h2,
.section-title,
.venue-card h2 {
  margin: 14px 0;
  font-family: var(--font-wedding);
  font-size: clamp(36px, 6vw, 58px);
  font-weight: var(--heading-weight);
  line-height: 0.95;
}

.intro-copy p {
  margin: 0 auto;
  max-width: 420px;
  color: #865052;
  font-family: var(--font-wedding);
  font-size: 15px;
  font-weight: var(--body-weight);
  line-height: 1.8;
}

.details-section,
.venue-section {
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 248, 239, 0.08), transparent 34%),
    var(--wine-bg);
  text-align: center;
}

.section-title {
  color: var(--cream-soft);
}

.details-layout {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 34px;
}

.detail-card,
.venue-card {
  border: 1px solid rgba(255, 248, 239, 0.18);
  border-radius: 8px;
  background: rgba(251, 244, 236, 0.95);
  color: var(--wine-text);
  box-shadow: 0 18px 38px rgba(18, 0, 4, 0.18);
}

.detail-card {
  padding: 30px 24px;
}

.detail-card-feature {
  background: #fff8ef;
  transform: translateY(-12px);
}

.detail-label {
  display: block;
  color: #a76868;
  font-family: var(--font-wedding);
  font-size: 12px;
  font-weight: var(--body-weight);
  letter-spacing: 1.6px;
  text-transform: uppercase;
}

.detail-card h3 {
  margin: 12px 0 10px;
  font-size: 30px;
  font-weight: var(--body-weight);
  line-height: 1.05;
}

.detail-card p {
  margin: 0;
  color: #8b4e50;
  font-family: var(--font-wedding);
  font-size: 14px;
  font-weight: var(--body-weight);
  line-height: 1.55;
}

.schedule-section {
  background: var(--cream);
  color: var(--wine-text);
}

.schedule-wrap {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 40px;
  align-items: start;
}

.schedule-copy .section-title {
  color: var(--wine-text);
}

.timeline {
  display: grid;
  gap: 18px;
}

.timeline-item {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 22px;
  align-items: start;
  padding: 24px 0;
  border-bottom: 1px solid rgba(109, 32, 39, 0.16);
}

.timeline-item time {
  color: var(--wine-dark);
  font-family: var(--font-wedding);
  font-size: 40px;
  line-height: 1;
}

.timeline-item h3 {
  margin: 0 0 8px;
  font-size: 28px;
  font-weight: var(--body-weight);
}

.timeline-item p,
.venue-card p {
  margin: 0;
  color: #895254;
  font-family: var(--font-wedding);
  font-size: 15px;
  font-weight: var(--body-weight);
  line-height: 1.7;
}

.venue-card {
  width: min(100%, 680px);
  margin: 0 auto;
  padding: 46px 28px;
}

.map-button {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  margin-top: 26px;
  padding: 0 28px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--wine-dark);
  color: var(--cream-soft);
  font-family: var(--font-wedding);
  font-size: 14px;
  font-weight: var(--body-weight);
  text-decoration: none;
  box-shadow: 0 9px 22px rgba(75, 10, 18, 0.22);
}

.map-button::after {
  content: "";
  position: absolute;
  top: -40%;
  left: -70%;
  width: 46%;
  height: 180%;
  background: linear-gradient(100deg, transparent, rgba(255, 248, 239, 0.5), transparent);
  transform: skewX(-24deg);
  animation: button-shine 3.1s ease-in-out infinite;
}

.scroll-reveal {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 760ms cubic-bezier(0.22, 0.8, 0.22, 1),
    transform 760ms cubic-bezier(0.22, 0.8, 0.22, 1);
}

.scroll-reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@keyframes card-enter {
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes page-show {
  to {
    opacity: 1;
  }
}

@keyframes hero-kenburns {
  to {
    transform: scale(1);
  }
}

@keyframes scroll-dot {
  0%,
  100% {
    opacity: 0;
    transform: translate(-50%, 0);
  }

  45% {
    opacity: 1;
  }

  70% {
    opacity: 0;
    transform: translate(-50%, 14px);
  }
}

@keyframes photo-card-float {
  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-8px);
  }
}

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

  50% {
    transform: translateY(-9px);
  }
}

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

  50% {
    transform: translateY(-8px);
  }
}

@keyframes music-pulse {
  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.06);
  }
}

@keyframes music-bar-bounce {
  0%,
  100% {
    transform: scaleY(0.46);
  }

  50% {
    transform: scaleY(1);
  }
}

@keyframes timeline-flower-float {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }

  50% {
    transform: translateY(-8px) rotate(1deg);
  }
}

@keyframes guest-flower-float {
  0%,
  100% {
    transform: translateY(0) rotate(-18deg);
  }

  50% {
    transform: translateY(-7px) rotate(-16.5deg);
  }
}

@keyframes gift-envelope-shake {
  0%,
  82%,
  100% {
    transform: rotate(0deg) translateY(0);
  }

  86% {
    transform: rotate(-2deg) translateY(-2px);
  }

  90% {
    transform: rotate(2deg) translateY(-3px);
  }

  94% {
    transform: rotate(-1.5deg) translateY(-1px);
  }

  97% {
    transform: rotate(1deg) translateY(0);
  }
}

@keyframes gift-modal-enter {
  from {
    opacity: 0;
    transform: translateY(10px) scale(0.96);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes reveal-item {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes heart-pulse {
  0%,
  28%,
  100% {
    transform: rotate(45deg) scale(1);
  }

  12% {
    transform: rotate(45deg) scale(1.12);
  }

  18% {
    transform: rotate(45deg) scale(0.98);
  }

  36% {
    transform: rotate(45deg) scale(1.08);
  }
}

@keyframes heart-badge-breath {
  0%,
  100% {
    box-shadow:
      0 13px 25px rgba(76, 12, 18, 0.25),
      0 5px 12px rgba(48, 0, 7, 0.20),
      0 0 34px rgba(91, 13, 19, 0.08);
    transform: translateY(0) scale(1);
  }

  50% {
    box-shadow:
      0 16px 32px rgba(76, 12, 18, 0.32),
      0 7px 15px rgba(48, 0, 7, 0.24),
      0 0 42px rgba(91, 13, 19, 0.13);
    transform: translateY(-1px) scale(1.045);
  }
}

@keyframes heart-badge-halo {
  0%,
  100% {
    opacity: 0.24;
    transform: scale(0.82);
  }

  48% {
    opacity: 0.48;
    transform: scale(1.08);
  }
}

@keyframes heart-badge-glint {
  0%,
  100% {
    opacity: 0.26;
    transform: translate(-1px, 1px) scale(0.82);
  }

  50% {
    opacity: 0.64;
    transform: translate(1px, -1px) scale(1.08);
  }
}

@keyframes button-breath {
  0%,
  100% {
    box-shadow:
      0 7px 18px rgba(75, 10, 16, 0.24),
      0 0 0 rgba(251, 244, 236, 0);
  }

  50% {
    box-shadow:
      0 10px 24px rgba(75, 10, 18, 0.35),
      0 0 18px rgba(251, 244, 236, 0.10);
  }
}

@keyframes button-inner-glow {
  0%,
  100% {
    opacity: 0.34;
    transform: scaleX(0.96);
  }

  50% {
    opacity: 0.62;
    transform: scaleX(1);
  }
}

@keyframes button-shine {
  0%,
  36% {
    left: -70%;
    opacity: 0;
  }

  48% {
    opacity: 0.78;
  }

  66%,
  100% {
    left: 124%;
    opacity: 0;
  }
}

@keyframes button-text-shine {
  0%,
  34% {
    background-position: 120% 0;
  }

  58% {
    background-position: 0% 0;
  }

  100% {
    background-position: -120% 0;
  }
}

@keyframes button-label-pulse {
  0%,
  100% {
    transform: translateY(0) scale(1);
  }

  50% {
    transform: translateY(-1px) scale(1.035);
  }
}

@keyframes floral-enter-left {
  from {
    opacity: 0;
    transform: translateY(7px) scaleX(1);
  }

  to {
    opacity: 1;
    transform: translateY(0) scaleX(1);
  }
}

@keyframes floral-enter-right {
  from {
    opacity: 0;
    transform: translateY(7px) scaleX(-1);
  }

  to {
    opacity: 1;
    transform: translateY(0) scaleX(-1);
  }
}

@keyframes floral-float-left {
  0%,
  100% {
    opacity: 1;
    transform: translateY(0) scaleX(1);
  }

  50% {
    opacity: 1;
    transform: translateY(-1.2px) scaleX(1);
  }
}

@keyframes floral-float-right {
  0%,
  100% {
    opacity: 1;
    transform: translateY(0) scaleX(-1);
  }

  50% {
    opacity: 1;
    transform: translateY(-1.4px) scaleX(-1);
  }
}

@keyframes heart-fall {
  0% {
    transform: translate3d(0, -12vh, 0) rotate(var(--start-rotate));
  }

  100% {
    transform: translate3d(var(--drift), 124vh, 0) rotate(var(--end-rotate));
  }
}

@keyframes seed-heart-drift {
  0% {
    transform: translate3d(0, -18px, 0) rotate(var(--start-rotate));
  }

  50% {
    transform: translate3d(calc(var(--drift) * 0.45), 38px, 0) rotate(calc(var(--start-rotate) + 120deg));
  }

  100% {
    transform: translate3d(var(--drift), 92px, 0) rotate(var(--end-rotate));
  }
}

@keyframes seed-heart-fall {
  0% {
    top: -12vh;
    transform: translate3d(0, 0, 0) rotate(-12deg);
    opacity: 0.15;
  }

  12% {
    opacity: 0.9;
  }

  50% {
    top: 54vh;
    transform: translate3d(24px, 0, 0) rotate(18deg);
    opacity: 0.9;
  }

  88% {
    opacity: 0.55;
  }

  100% {
    top: 112vh;
    transform: translate3d(52px, 0, 0) rotate(36deg);
    opacity: 0;
  }
}

@media (max-width: 640px) {
  body {
    overflow: hidden;
  }

  .opening-screen {
    padding: 16px;
  }

  .opening-card {
    width: calc(100vw - 32px);
    height: auto;
    min-height: min(420px, calc(100svh - 48px));
    padding: 30px 22px 28px;
  }

  .floral {
    top: 52px;
    width: 122px;
    max-width: 34%;
  }

  .floral-left {
    left: -34px;
  }

  .floral-right {
    right: -34px;
  }

  .heart-badge {
    width: 52px;
    height: 52px;
    margin-top: -10px;
    margin-bottom: 25px;
  }

  .couple-names {
    font-size: 35px;
  }

  .wedding-date,
  .invitation-line {
    font-size: 14px;
  }

  .open-button {
    min-width: 128px;
    min-height: 44px;
    margin-top: 22px;
    font-size: 18px;
  }

  .hero-content {
    padding-bottom: 74px;
  }

  .hero-names {
    font-size: 52px;
  }

  .intro-section,
  .details-section,
  .schedule-section,
  .venue-section {
    padding: 58px 0;
  }

  .intro-grid,
  .details-layout,
  .schedule-wrap {
    grid-template-columns: 1fr;
  }

  .portrait-panel {
    min-height: 440px;
  }

  .portrait-panel-right {
    margin-top: 0;
  }

  .detail-card-feature {
    transform: none;
  }

  .timeline-item {
    grid-template-columns: 78px 1fr;
    gap: 16px;
  }

  .timeline-item time {
    font-size: 34px;
  }
}

@media (max-height: 620px) {
  .opening-card {
    min-height: auto;
    padding-top: 24px;
    padding-bottom: 24px;
  }

  .heart-badge {
    margin-bottom: 12px;
  }

  .ornament {
    margin-top: 12px;
  }

  .invitation-line {
    margin-top: 16px;
  }

  .open-button {
    margin-top: 14px;
  }
}

/* Main invitation layout */
.main-wedding-page {
  background: #ffffff;
  color: var(--wine-text);
}

.page-shell {
  position: relative;
  width: min(100%, 900px);
  min-height: 100svh;
  margin: 0 auto;
  overflow: hidden;
  background-color: #f8f3ec;
  background-image: url("../assets/images/backgroud.6d3f68914081.webp");
  background-repeat: repeat-y;
  background-position: center top;
  background-size: 100% auto;
  box-shadow:
    1px 0 0 rgba(79, 36, 25, 0.12),
    -1px 0 0 rgba(79, 36, 25, 0.12);
}

.paper-section {
  position: relative;
  z-index: 1;
  padding: 70px 24px;
  text-align: center;
}

.save-section {
  min-height: 760px;
  padding-top: 66px;
  padding-bottom: 54px;
}

.save-title,
.paper-heading {
  margin: 0;
  color: var(--wine-dark);
  font-family: var(--font-wedding);
  font-size: 20px;
  font-weight: var(--heading-weight);
  letter-spacing: 7px;
  line-height: 1.2;
}

.save-title {
  position: relative;
  z-index: 3;
  color: var(--wine-dark);
  font-size: 19px;
  font-weight: var(--heading-weight);
  letter-spacing: 5.7px;
}

.paper-heading {
  margin-bottom: 46px;
  font-size: 22px;
  letter-spacing: 1.8px;
}

.envelope-scene {
  position: relative;
  width: 100%;
  display: flex;
  justify-content: center;
  height: auto;
  margin: 54px auto 0;
}

.weding-layout {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  margin: 0 auto 42px;
  pointer-events: none;
}

.weding-composite {
  display: block;
  width: 500px;
  max-width: 72vw;
  height: auto;
  margin: 0 auto;
  transform-origin: 50% 72%;
  filter: drop-shadow(0 10px 18px rgba(45, 12, 16, 0.12));
  animation: weding-float 4.2s ease-in-out infinite;
  will-change: transform;
}

.save-section .photo-layout {
  position: absolute;
  left: 36%;
  top: -24px;
  z-index: 2;
  width: 282px;
  height: 374px;
  transform: rotate(9deg);
  transform-origin: 52% 82%;
}

.save-section .photo-card {
  position: relative;
  width: 100%;
  height: 100%;
  padding: 11px;
  background: #fff;
  box-shadow: 0 10px 20px rgba(38, 15, 12, 0.20);
  transform: translateY(0);
  transform-origin: 50% 82%;
  animation: photo-card-float 3.4s ease-in-out 600ms infinite;
  will-change: transform;
}

.save-section .photo-fill {
  width: 100%;
  height: 100%;
  background-color: #efe5dc;
  background-position: center;
  background-size: cover;
}

.photo-1 {
  background-image:
    linear-gradient(135deg, rgba(255, 255, 255, 0.18), rgba(78, 19, 23, 0.05)),
    url("../assets/images/slide1.jpg"),
    radial-gradient(circle at 48% 34%, #ffffff 0 12%, #ead7c7 30%, #bd927e 52%, #4e1317 100%);
}

.photo-2 {
  background-image:
    linear-gradient(135deg, rgba(255, 255, 255, 0.34), rgba(78, 19, 23, 0.16)),
    url("../assets/images/slide2.jpg"),
    radial-gradient(circle at 54% 28%, #ffffff 0 12%, #ead7c7 32%, #bd927e 54%, #4e1317 100%);
}

.save-section .photo-card .photo-1 {
  background-image:
    url("../assets/images/wd1.jpg");
  background-repeat: no-repeat;
  background-size: 185% auto;
  background-position: 50% 16%;
}

.save-section .flower-layout {
  position: absolute;
  left: 5px;
  top: -108px;
  z-index: 3;
  width: 330px;
  height: 480px;
  overflow: hidden;
  transform: rotate(-3deg);
  transform-origin: 50% 78%;
  pointer-events: none;
}

.save-section .flower-layout .envelope-flower {
  position: relative;
  top: 0;
  display: block;
  width: 100%;
  height: auto;
  transform: translateY(0);
  filter: drop-shadow(0 10px 12px rgba(33, 8, 8, 0.16));
  clip-path: none;
  animation: flower-float 3.4s ease-in-out 600ms infinite;
  transform-origin: 52% 78%;
  will-change: transform;
}

.envelope {
  position: absolute;
  left: 50%;
  bottom: 3px;
  z-index: 5;
  width: 420px;
  height: 280px;
  transform: translateX(-50%);
  filter: drop-shadow(0 14px 16px rgba(50, 10, 14, 0.24));
}

.envelope::before,
.envelope::after,
.envelope-flap,
.envelope-front {
  content: "";
  position: absolute;
  inset: auto;
}

.envelope::before {
  left: 0;
  bottom: 0;
  width: 100%;
  height: 218px;
  background:
    radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.05), transparent 22%),
    repeating-linear-gradient(18deg, rgba(255, 255, 255, 0.018) 0 1px, transparent 1px 7px),
    linear-gradient(160deg, #84232c, #5b1118 58%, #450a10);
}

.envelope::after {
  left: 0;
  bottom: 0;
  z-index: 3;
  border-left: 210px solid #69151d;
  border-right: 210px solid #581017;
  border-top: 162px solid transparent;
  border-bottom: 0 solid transparent;
}

.envelope-flap {
  left: 0;
  bottom: 128px;
  z-index: 1;
  border-left: 210px solid transparent;
  border-right: 210px solid transparent;
  border-bottom: 120px solid #4b0c12;
  filter: drop-shadow(0 -2px 0 rgba(255, 248, 239, 0.08));
}

.envelope-front {
  left: 0;
  bottom: 0;
  z-index: 4;
  width: 100%;
  height: 170px;
  background:
    linear-gradient(138deg, transparent 49.7%, rgba(255, 248, 239, 0.12) 50%, transparent 50.5%),
    linear-gradient(42deg, transparent 49.6%, rgba(255, 248, 239, 0.10) 50%, transparent 50.5%),
    linear-gradient(145deg, #6f1720 0 49%, transparent 49.4%),
    linear-gradient(35deg, #5c1118 0 49%, transparent 49.4%),
    linear-gradient(180deg, #7c1d26, #5d1118);
  clip-path: polygon(0 0, 50% 72%, 100% 0, 100% 100%, 0 100%);
}

.wax-seal {
  position: absolute;
  left: 50%;
  top: 119px;
  z-index: 7;
  display: grid;
  place-items: center;
  width: 62px;
  height: 62px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 34% 28%, #f1c670 0 18%, #d49a3e 46%, #95601f 74%),
    #b7772d;
  color: #6b3217;
  font-size: 38px;
  transform: translateX(-50%);
  box-shadow: 0 4px 10px rgba(34, 7, 4, 0.32);
}

.envelope-image {
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 535px;
  height: 535px;
  background-image: url("../assets/images/envelope-open-transparent.png");
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
  filter: drop-shadow(0 12px 14px rgba(50, 10, 14, 0.18));
  pointer-events: none;
  transform: translateX(-50%);
}

.envelope-image.envelope-back {
  z-index: 1;
  clip-path: polygon(0 0, 100% 0, 100% 55%, 0 55%);
}

.envelope-image.envelope-front {
  z-index: 6;
  left: 50%;
  bottom: 0;
  width: 535px;
  height: 535px;
  background-image: url("../assets/images/envelope-open-transparent.png");
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
  transform: translateX(-50%);
  clip-path: polygon(0 43%, 27% 43%, 50% 62%, 73% 43%, 100% 43%, 100% 100%, 0 100%);
}

.main-couple {
  margin: 34px auto 0;
  max-width: 520px;
  color: var(--wine-text);
  font-family: var(--font-wedding);
  font-size: 56px;
  font-weight: var(--name-weight);
  line-height: 0.92;
}

.main-couple span {
  display: block;
  margin: 5px 0 8px;
  color: rgba(109, 32, 39, 0.42);
  font-size: 36px;
}

.wine-panel {
  position: relative;
  width: min(100%, 560px);
  margin: 0 auto;
  overflow: visible;
  border-radius: 10px;
  background: var(--wine-card);
  color: var(--cream-text);
  box-shadow: 0 12px 22px rgba(30, 4, 7, 0.26);
}

.ceremony-section {
  padding-top: 26px;
}

.ceremony-card {
  width: min(100%, 740px);
  min-height: 920px;
  padding: 46px 74px 64px;
  text-align: center;
}

.ceremony-card > :not(.panel-flower) {
  position: relative;
  z-index: 3;
}

.wine-panel h2 {
  margin: 0 0 30px;
  font-family: var(--font-wedding);
  font-weight: var(--heading-weight);
  font-size: 22px;
  line-height: 1.25;
}

.family-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 26px;
  margin: 0 auto 30px;
  max-width: 520px;
}

.family-row > div + div {
  border-left: 1px solid rgba(255, 248, 239, 0.42);
}

.family-row span,
.role,
.date-row span,
.party-date span,
.party-times span {
  display: block;
  color: rgba(255, 248, 239, 0.72);
  font-family: var(--font-wedding);
  font-size: 13px;
  font-weight: var(--body-weight);
}

.family-row strong {
  display: block;
  margin-top: 6px;
  font-size: 16px;
  font-weight: var(--body-weight);
}

.family-side small {
  display: block;
  margin-top: 10px;
  color: rgba(255, 248, 239, 0.66);
  font-size: 13px;
  font-weight: var(--body-weight);
  line-height: 1.45;
}

.announce,
.venue-note,
.ceremony-note,
.lunar-date {
  color: rgba(255, 248, 239, 0.82);
  font-size: 15px;
  font-weight: var(--heading-weight);
  line-height: 1.55;
}

.ceremony-card h3 {
  margin: 34px auto 12px;
  max-width: 680px;
  font-family: var(--font-wedding);
  font-size: 42px;
  font-weight: var(--name-weight);
  line-height: 1.04;
  letter-spacing: 0;
  white-space: nowrap;
}

.ceremony-card .role {
  margin: 34px auto 10px;
}

.ceremony-card .role + h3 {
  margin-top: 0;
}

.panel-amp {
  margin: 26px 0 0;
  font-size: 46px;
  font-weight: var(--name-weight);
}


/* Danh xưng nằm cùng một hàng; dấu & thư pháp ở hàng trên màu champagne. */
.ceremony-card .couple-role-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 30px;
  margin: 24px auto 32px;
}

.ceremony-card .couple-role-row .role {
  margin: 0;
  color: rgba(255, 248, 239, 0.82);
  font-family: var(--font-wedding);
  font-size: 25px;
  font-style: italic;
  font-weight: 400;
  line-height: 1;
  letter-spacing: 0.015em;
}

.ceremony-card .role-ornament-amp,
.ceremony-card .panel-amp {
  font-family: "Great Vibes", cursive;
  font-weight: 400;
  line-height: 0.72;
}

.ceremony-card .role-ornament-amp {
  display: block;
  color: #ffffff;
  font-size: 76px;
  transform: translateY(-2px);
}

.ceremony-card .groom-name,
.ceremony-card .bride-name {
  margin: 0 auto;
}

/* Dấu thư pháp thay cho dấu & thường giữa hai tên; màu trắng ngà như tên. */
.ceremony-card .panel-amp {
  margin: 10px auto 2px;
  color: #ffffff;
  font-size: 82px;
  line-height: 0.72;
  text-shadow: none;
}

.ceremony-card .bride-name {
  margin-bottom: 12px;
}

.ceremony-note {
  margin: 34px auto 12px;
  max-width: 520px;
}

.ceremony-time {
  color: var(--cream-text);
  font-size: 34px;
  font-weight: var(--heading-weight);
  line-height: 1;
}

.date-row,
.ceremony-date {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 20px;
  align-items: center;
  width: min(100%, 300px);
  margin: 28px auto 0;
}

.date-row strong,
.ceremony-date strong {
  padding-right: 18px;
  border-right: 1px solid rgba(255, 248, 239, 0.62);
  font-size: 48px;
  line-height: 1;
}

.ceremony-date span {
  color: rgba(255, 248, 239, 0.72);
  font-size: 14px;
  font-weight: var(--body-weight);
  line-height: 1.35;
}

.lunar-date {
  margin: 24px auto 0;
  font-size: 14px;
  letter-spacing: 0.8px;
}

.panel-flower {
  position: absolute;
  z-index: 2;
  width: 205px;
  filter: drop-shadow(0 9px 10px rgba(30, 4, 7, 0.25));
  pointer-events: none;
}

.panel-flower-right {
  right: -92px;
  top: 245px;
}

.ceremony-card .ceremony-flower-bottom-right {
  right: -58px;
  bottom: 8px;
  width: 210px;
  z-index: 2;
  animation: flower-float 4.6s ease-in-out infinite;
  will-change: transform;
}

.ceremony-card .ceremony-flower-top-left {
  left: -52px;
  top: 18px;
  width: 132px;
  z-index: 2;
  transform: rotate(180deg);
  opacity: 0.9;
  animation: flower-float 5s ease-in-out 500ms infinite;
  will-change: transform;
}

.panel-flower-left {
  left: -86px;
  top: 210px;
}

.album-section {
  padding-top: 44px;
  overflow: hidden;
  isolation: isolate;
  background-color: #f8f3ec;
  background-image:
    linear-gradient(rgba(248, 243, 236, 0.55), rgba(248, 243, 236, 0.55)),
    url("../assets/images/backgroud.6d3f68914081.webp");
  background-repeat: no-repeat;
  background-position: center 65%;
  background-size: 100% auto;
}

.album-section .paper-heading {
  margin-bottom: 42px;
  color: #571a23;
  font-size: 20px;
  font-weight: 600;
}

.album-section .album-stage {
  --album-width: min(320px, 68vw);
  --album-near: min(210px, 44.625vw);
  --album-middle: min(330px, 70.125vw);
  --album-far: min(440px, 93.5vw);
  --album-edge: min(560px, 119vw);
  position: relative;
  width: min(100%, 900px);
  height: calc(var(--album-width) * 1.5);
  margin: 0 auto;
  touch-action: pan-y pinch-zoom;
}

.album-section .album-strip {
  position: absolute;
  inset: 0;
  z-index: 1;
  perspective: 1200px;
  perspective-origin: center center;
  transform-style: preserve-3d;
}

.album-section .album-card {
  position: absolute;
  top: 0;
  left: 50%;
  overflow: hidden;
  width: var(--album-width);
  height: 100%;
  padding: 0;
  border: 0;
  border-radius: 16px;
  background: #f7efe8;
  box-shadow: 0 4px 14px rgba(80, 30, 20, 0.1);
  transform-style: preserve-3d;
  transform-origin: center center;
  backface-visibility: hidden;
  z-index: var(--layer, 0);
  opacity: var(--alpha, 0);
  transform: translateX(-50%) translate3d(var(--x, 0px), 0px, var(--z, -500px)) rotateY(var(--angle, 0deg)) scale(var(--scale, 0.5));
  transition-property: transform, opacity;
  transition-duration: 800ms;
  transition-timing-function: cubic-bezier(0.22, 1, 0.36, 1), ease;
  cursor: pointer;
}

.album-section .album-card img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  user-select: none;
  -webkit-user-drag: none;
}

.album-section .album-card[data-position="0"] {
  --x: 0px;
  --z: 0px;
  --angle: 0deg;
  --scale: 1;
  --alpha: 1;
  --layer: 10;
}

.album-section .album-card[data-position="-1"],
.album-section .album-card[data-position="1"] {
  --z: -130px;
  --scale: 0.85;
  --alpha: 0.85;
  --layer: 8;
}

.album-section .album-card[data-position="-1"] { --x: calc(0px - var(--album-near)); --angle: 35deg; }
.album-section .album-card[data-position="1"] { --x: var(--album-near); --angle: -35deg; }

.album-section .album-card[data-position="-2"],
.album-section .album-card[data-position="2"] {
  --z: -220px;
  --scale: 0.78;
  --alpha: 0.5;
  --layer: 6;
}

.album-section .album-card[data-position="-2"] { --x: calc(0px - var(--album-middle)); --angle: 62deg; }
.album-section .album-card[data-position="2"] { --x: var(--album-middle); --angle: -62deg; }

.album-section .album-card[data-position="-3"],
.album-section .album-card[data-position="3"] {
  --z: -300px;
  --scale: 0.65;
  --alpha: 0.28;
  --layer: 4;
}

.album-section .album-card[data-position="-3"] { --x: calc(0px - var(--album-far)); --angle: 65deg; }
.album-section .album-card[data-position="3"] { --x: var(--album-far); --angle: -65deg; }

.album-section .album-card[data-position="-4"],
.album-section .album-card[data-position="-5"] { --x: calc(0px - var(--album-edge)); --angle: 80deg; }
.album-section .album-card[data-position="4"],
.album-section .album-card[data-position="5"] { --x: var(--album-edge); --angle: -80deg; }

.album-section .album-card[aria-hidden="true"][data-position="-4"],
.album-section .album-card[aria-hidden="true"][data-position="4"],
.album-section .album-card[data-position="-5"],
.album-section .album-card[data-position="5"] {
  pointer-events: none;
}

.album-section .album-card.is-recycling {
  transition: none;
}

.album-section .album-arrow {
  position: absolute;
  top: 50%;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 248, 239, 0.82);
  color: #571a23;
  cursor: pointer;
  font-size: 0;
  line-height: 1;
  transform: translateY(-50%);
}

.album-section .album-arrow::before {
  content: "";
  width: 7px;
  height: 7px;
  border: solid currentColor;
  border-width: 0 1.5px 1.5px 0;
  transform: translateX(2px) rotate(135deg);
}

.album-section .album-next::before {
  transform: translateX(-2px) rotate(-45deg);
}

.album-section .album-prev {
  left: calc(50% - min(285px, 40vw) - 18px);
}

.album-section .album-next {
  right: calc(50% - min(285px, 40vw) - 18px);
}

.album-section .album-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-top: 32px;
}

.album-section .album-dots button {
  width: 8px;
  height: 8px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(109, 32, 39, 0.28);
  cursor: pointer;
  transition: width 760ms cubic-bezier(0.22, 1, 0.36, 1), background-color 760ms;
}

.album-section .album-dots .active {
  width: 24px;
  background: #874c55;
}

.party-card {
  width: min(100% - 32px, 560px);
  padding: 38px 44px 42px;
  border-radius: 14px;
  overflow: visible;
}

.party-card h2 {
  margin-bottom: 34px;
  font-size: 21px;
  font-weight: var(--heading-weight);
  line-height: 1.1;
}

.party-card h3 {
  margin: 0 0 26px;
  font-size: 20px;
  font-weight: var(--heading-weight);
  line-height: 1.15;
  letter-spacing: 0;
  white-space: nowrap;
}

.party-date {
  width: min(100%, 292px);
  margin: 0 auto 30px;
}

.party-date-top {
  display: grid;
  grid-template-columns: repeat(2, max-content);
  justify-content: center;
  gap: 24px;
  align-items: center;
  white-space: nowrap;
  margin-bottom: 16px;
}

.party-date-main {
  display: grid;
  grid-template-columns: auto auto;
  justify-content: center;
  align-items: center;
  gap: 18px;
}

.party-date-main strong {
  padding-right: 18px;
  border-right: 1px solid rgba(255, 248, 239, 0.62);
  font-size: 46px;
  font-weight: var(--body-weight);
  line-height: 1;
}

.party-times {
  display: flex;
  justify-content: center;
  gap: 46px;
  margin-bottom: 34px;
}

.party-times strong {
  display: block;
  margin-top: 8px;
  font-size: 21px;
  font-weight: var(--body-weight);
}

.party-card .panel-flower-left {
  left: -78px;
  top: 188px;
  width: 172px;
  animation: flower-float 4.8s ease-in-out 380ms infinite;
  will-change: transform;
}

.calendar-box {
  width: min(100%, 360px);
  margin: 0 auto 28px;
  padding: 20px 18px 22px;
  border-radius: 11px;
  background: #f3e9dc;
  color: var(--wine-text);
}

.calendar-box p {
  margin: 0 0 14px;
  font-size: 23px;
  font-weight: var(--body-weight);
  font-style: italic;
}

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  justify-items: center;
  align-items: center;
  gap: 9px 8px;
  border-top: 1px solid rgba(109, 32, 39, 0.30);
  padding-top: 12px;
  font-size: 13px;
  font-weight: var(--body-weight);
}

.heart-day {
  position: relative;
  z-index: 0;
  display: inline-grid;
  place-items: center;
  width: 24px;
  height: 22px;
  color: var(--cream-text);
  font-weight: var(--heading-weight);
  line-height: 1;
}

.heart-day::before {
  content: "\2665";
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: -1;
  color: var(--wine-dark);
  font-size: 35px;
  line-height: 1;
  transform: translate(-50%, -49%);
}

.calendar-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  margin-top: 0;
  margin-right: auto;
  margin-bottom: 16px;
  margin-left: auto;
  min-height: 38px;
  padding: 10px 24px;
  border-radius: 999px;
  background: #fff4e6;
  color: var(--wine-dark);
  font-size: 15px;
  font-weight: var(--heading-weight);
  text-decoration: none;
}

.confirm-button,
.direction-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  margin-right: auto;
  margin-left: auto;
  min-height: 38px;
  padding: 10px 28px;
  border-radius: 999px;
  background: #fff4e6;
  color: var(--wine-dark);
  font-size: 16px;
  font-weight: var(--heading-weight);
  text-decoration: none;
}

.location-section {
  padding-top: 28px;
}

.location-text {
  max-width: 560px;
  margin: -20px auto 18px;
  color: #7a363b;
  font-size: 16px;
  line-height: 1.6;
}

.map-frame {
  position: relative;
  width: min(100%, 560px);
  height: 380px;
  margin: 0 auto 20px;
  overflow: hidden;
  border-radius: 6px;
  box-shadow: 0 8px 20px rgba(68, 36, 20, 0.14);
}

.map-frame iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

.map-frame .map-fallback {
  display: grid;
  align-content: center;
  height: 100%;
  margin: 0;
  padding: 48px 24px;
  line-height: 1.6;
}

.map-frame .map-fallback[hidden] {
  display: none;
}

.map-frame .map-open-link {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 8px 12px;
  border-radius: 6px;
  background: var(--cream-soft);
  color: var(--wine-text);
  font-size: 14px;
  box-shadow: 0 2px 6px rgba(68, 36, 20, 0.14);
}

.direction-link {
  background: transparent;
  color: var(--wine-text);
  text-decoration: underline;
}

.timeline-card {
  width: min(100%, 580px);
  min-height: auto;
  padding: 38px 46px 42px;
  text-align: left;
}

.timeline-card h2 {
  margin-bottom: 28px;
  font-size: 24px;
  font-weight: var(--heading-weight);
  text-align: center;
}

.timeline-list {
  position: relative;
  display: grid;
  --timeline-gap: 22px;
  --timeline-axis: 139px;
  grid-auto-rows: 1fr;
  gap: var(--timeline-gap);
  width: min(100%, 430px);
  margin: 0 auto;
}

.timeline-list::before {
  content: "";
  position: absolute;
  left: var(--timeline-axis);
  top: calc((100% - var(--timeline-gap) * 2) / 6);
  bottom: calc((100% - var(--timeline-gap) * 2) / 6);
  width: 1px;
  background: rgba(255, 248, 239, 0.74);
  transform: translateX(-50%);
}

.timeline-list div {
  position: relative;
  display: grid;
  grid-template-columns: 40px 62px 26px minmax(120px, 1fr);
  column-gap: 12px;
  align-items: center;
  min-height: 46px;
}

.timeline-icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  background: transparent;
  box-shadow: none;
}

.timeline-icon img {
  display: block;
  width: 42px;
  height: 42px;
  object-fit: contain;
}

.timeline-list div > span:not(.timeline-icon) {
  position: relative;
  z-index: 1;
  justify-self: center;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: #fff8ef;
  border: 1px solid rgba(78, 19, 24, 0.18);
  box-shadow: 0 0 0 3px rgba(255, 248, 239, 0.24);
}

.timeline-list div > span:not(.timeline-icon)::before {
  content: none;
}

.timeline-list time,
.timeline-list p {
  margin: 0;
  color: #f8eee4;
  font-size: 17px;
  font-weight: var(--body-weight);
}

.timeline-list time {
  text-align: right;
}

.timeline-flower {
  right: -76px;
  top: 84px;
  width: 165px;
  z-index: 2;
  animation: timeline-flower-float 4.4s ease-in-out infinite;
  will-change: transform;
}

.guestbook-card {
  position: relative;
  width: min(100%, 475px);
  margin: 0 auto 62px;
  padding: 58px 56px 62px;
  border-radius: 12px;
  background: rgba(255, 248, 239, 0.86);
  box-shadow: 0 8px 18px rgba(77, 40, 27, 0.20);
}

.guestbook-card h2 {
  margin: 0 0 26px;
  color: var(--wine-dark);
  font-weight: var(--heading-weight);
}

.wish-form {
  display: grid;
  gap: 16px;
}

.wish-form input,
.wish-form textarea {
  width: 100%;
  border: 1px solid var(--wine-dark);
  border-radius: 7px;
  background: transparent;
  color: var(--wine-text);
  font-family: var(--font-wedding);
  font-size: 16px;
  font-weight: var(--body-weight);
  padding: 14px 16px;
}

.wish-form textarea {
  min-height: 108px;
  resize: vertical;
}

.wish-form button {
  justify-self: end;
  min-height: 38px;
  padding: 0 28px;
  border: 0;
  border-radius: 999px;
  background: var(--wine-dark);
  color: var(--cream-text);
  font-weight: var(--heading-weight);
}

.guest-flower {
  position: absolute;
  left: -40px;
  bottom: -26px;
  width: 152px;
  transform: rotate(-10deg);
  animation: guest-flower-float 4.4s ease-in-out infinite;
  will-change: transform;
}

.wish-form .wish-status {
  margin: 0;
  color: inherit;
  font: inherit;
  font-size: 14px;
  line-height: 1.45;
}

.wishes-list {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-content: start;
  gap: 14px;
  width: min(100%, 580px);
  max-height: 480px;
  margin: 0 auto;
  overflow-x: hidden;
  overflow-y: auto;
  padding-right: 10px;
  scrollbar-width: thin;
  scrollbar-color: #bca09b transparent;
}

.wishes-list::-webkit-scrollbar {
  width: 9px;
}

.wishes-list::-webkit-scrollbar-track {
  background: transparent;
}

.wishes-list::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: #bca09b;
}

.wishes-list article {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: baseline;
  gap: 12px 8px;
  min-width: 0;
  border: 1px solid rgba(109, 32, 39, 0.30);
  border-radius: 7px;
  background: rgba(255, 248, 239, 0.64);
  padding: 16px;
  text-align: left;
}

.wishes-list strong {
  overflow-wrap: anywhere;
  color: var(--wine-dark);
  font-weight: var(--heading-weight);
}

.wishes-list time {
  text-align: right;
  color: #9b686a;
  font-size: 12px;
  font-weight: var(--body-weight);
}

.wishes-list p {
  grid-column: 1 / -1;
  margin: 0;
  overflow-wrap: anywhere;
  font-size: 15px;
  font-weight: var(--body-weight);
}

.gift-section {
  min-height: 640px;
}

.gift-envelope-trigger {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: fit-content;
  margin: 42px auto 22px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #865052;
  cursor: pointer;
  font-family: var(--font-wedding);
  font-size: 15px;
  font-weight: var(--body-weight);
}

.gift-envelope-image {
  display: block;
  width: min(70vw, 360px);
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 14px 24px rgba(50, 10, 14, 0.18));
  animation: gift-envelope-shake 3.2s ease-in-out infinite;
  transform-origin: 50% 64%;
  transition: transform 180ms ease;
}

.gift-envelope-trigger:hover .gift-envelope-image {
  transform: scale(1.03);
}

.gift-envelope-trigger:active .gift-envelope-image {
  transform: scale(0.98);
}

.gift-envelope-trigger span {
  margin-top: 14px;
}

.gift-hint,
.gift-note {
  color: #865052;
  font-size: 15px;
}

.gift-modal {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  place-items: center;
  padding: 18px;
}

.gift-modal[hidden] {
  display: none;
}

.gift-modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(35, 5, 9, 0.48);
}

.gift-modal__panel {
  position: relative;
  z-index: 1;
  width: min(100%, 460px);
  max-height: 88vh;
  overflow-y: auto;
  border-radius: 14px;
  background: #fff8ef;
  color: var(--wine-text);
  box-shadow: 0 22px 60px rgba(28, 5, 8, 0.34);
  animation: gift-modal-enter 260ms ease-out;
}

.gift-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  background: var(--wine-card);
  color: var(--cream-text);
}

.gift-modal__header h2 {
  margin: 0;
  font-size: 22px;
  font-weight: var(--heading-weight);
}

.gift-modal__close {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 248, 239, 0.14);
  color: var(--cream-text);
  cursor: pointer;
  font-size: 28px;
  line-height: 1;
}

.gift-modal__body {
  display: grid;
  gap: 18px;
  padding: 22px;
}

.gift-qr-card {
  padding: 18px;
  border: 1px solid rgba(78, 19, 24, 0.16);
  border-radius: 12px;
  text-align: center;
}

.gift-qr-role {
  margin: 0 0 5px;
  color: var(--wine-dark);
  font-size: 15px;
  font-weight: var(--heading-weight);
  letter-spacing: 1.4px;
}

.gift-qr-card h3 {
  margin: 0 0 14px;
  color: var(--wine-dark);
  font-size: 17px;
  font-weight: var(--heading-weight);
  line-height: 1.25;
}

.gift-qr-image {
  display: block;
  width: min(100%, 240px);
  max-width: 85%;
  height: auto;
  margin: 0 auto 14px;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 6px 16px rgba(77, 40, 27, 0.14);
  object-fit: contain;
}

.qr-download-btn {
  margin-top: 12px;
  padding: 8px 20px;
  border: 0;
  border-radius: 999px;
  background: #f1e5d6;
  color: var(--wine-dark);
  font-weight: var(--heading-weight);
}

.music-float {
  position: fixed;
  right: 18px;
  bottom: 24px;
  z-index: 20;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 2px solid rgba(255, 248, 239, 0.35);
  border-radius: 50%;
  background: var(--wine-light);
  color: #fff8ef;
  box-shadow: 0 7px 18px rgba(58, 6, 12, 0.30);
  cursor: pointer;
  font-size: 24px;
}

.music-note {
  display: block;
  line-height: 1;
}

.music-bars {
  display: none;
  align-items: end;
  justify-content: center;
  gap: 3px;
  height: 18px;
}

.music-bars i {
  display: block;
  width: 3px;
  height: 16px;
  border-radius: 999px;
  background: var(--cream-text);
  transform-origin: bottom;
  animation: music-bar-bounce 0.78s ease-in-out infinite;
}

.music-bars i:nth-child(2) {
  height: 12px;
  animation-delay: 0.14s;
}

.music-bars i:nth-child(3) {
  height: 17px;
  animation-delay: 0.28s;
}

.music-bars i:nth-child(4) {
  height: 10px;
  animation-delay: 0.42s;
}

.music-float.is-playing {
  animation: music-pulse 2.2s ease-in-out infinite;
}

.music-float.is-playing .music-note {
  display: none;
}

.music-float.is-playing .music-bars {
  display: flex;
}

@media (max-width: 700px) {
  .page-shell {
    width: 100%;
  }

  .paper-section {
    padding-inline: 16px;
  }

  .save-section {
    min-height: 700px;
    padding-top: 54px;
    padding-bottom: 46px;
  }

  .save-title {
    font-size: 17px;
    letter-spacing: 4.8px;
  }

  .envelope-scene {
    width: min(100%, 430px);
    height: auto;
    margin-top: 54px;
    transform-origin: top center;
  }

  .weding-composite {
    width: 88vw;
    max-width: 430px;
  }

  .save-section .photo-layout {
    left: 35%;
    top: -14px;
    width: 206px;
    height: 272px;
    transform: rotate(9deg);
  }

  .save-section .flower-layout {
    left: 2px;
    top: -78px;
    z-index: 3;
    width: 240px;
    height: 350px;
    transform: rotate(-3deg);
  }

  .save-section .flower-layout .envelope-flower {
    top: 0;
    clip-path: none;
  }

  .envelope {
    bottom: 54px;
    width: 320px;
    height: 214px;
  }

  .envelope-image {
    bottom: 0;
    width: 390px;
    height: 390px;
  }

  .envelope-image.envelope-front {
    bottom: 0;
    width: 390px;
    height: 390px;
    clip-path: polygon(0 43%, 27% 43%, 50% 62%, 73% 43%, 100% 43%, 100% 100%, 0 100%);
  }

  .envelope::before {
    height: 160px;
  }

  .envelope::after {
    border-left-width: 160px;
    border-right-width: 160px;
    border-top-width: 116px;
  }

  .envelope-flap {
    bottom: 54px;
    border-left-width: 160px;
    border-right-width: 160px;
    border-bottom-width: 110px;
  }

  .envelope-front {
    height: 130px;
  }

  .wax-seal {
    top: 82px;
    width: 52px;
    height: 52px;
    font-size: 30px;
  }

  .main-couple {
    margin-top: 26px;
    font-size: 48px;
  }

  .save-date-composition {
    width: 390px;
    height: 390px;
  }

  .ceremony-card,
  .party-card,
  .timeline-card {
    width: min(100%, 520px);
    padding: 34px 22px 48px;
  }

  .timeline-card {
    width: calc(100% - 28px);
    padding: 32px 22px 34px;
    border-radius: 12px;
  }

  .timeline-card h2 {
    margin-bottom: 26px;
    font-size: 23px;
    line-height: 1.12;
  }

  .party-card {
    width: calc(100% - 24px);
    padding: 30px 20px 32px;
    border-radius: 12px;
  }

  .party-card h2 {
    margin-bottom: 30px;
    font-size: 20px;
    line-height: 1.1;
  }

  .party-card h3 {
    margin-bottom: 24px;
    font-size: clamp(16px, 4.5vw, 19px);
    line-height: 1.1;
    white-space: nowrap;
  }

  .party-card .panel-flower-left {
    left: -42px;
    top: 215px;
    width: 116px;
  }

  .party-date {
    width: min(100%, 270px);
    margin-bottom: 28px;
  }

  .party-date-top {
    gap: 24px;
    margin-bottom: 14px;
  }

  .party-date-main {
    gap: 14px;
  }

  .party-date-main strong {
    padding-right: 14px;
    font-size: 42px;
  }

  .party-times {
    gap: 34px;
    margin-bottom: 32px;
  }

  .party-times strong {
    font-size: 20px;
  }

  .calendar-box {
    width: 100%;
    max-width: 325px;
    padding: 16px 16px 18px;
  }

  .calendar-box p {
    font-size: 22px;
  }

  .calendar-grid {
    gap: 8px 6px;
    font-size: 13px;
  }

  .calendar-link {
    margin-bottom: 22px;
    font-size: 14px;
    padding: 10px 22px;
  }

  .confirm-button {
    min-height: 38px;
    padding: 10px 25px;
    font-size: 15px;
  }

  .ceremony-card {
    width: calc(100% - 24px);
    min-height: auto;
    padding: 30px 20px 40px;
    overflow: hidden;
  }

  .ceremony-card h2 {
    margin-bottom: 24px;
    font-size: 20px;
  }

  .ceremony-card .family-row {
    gap: 14px;
    max-width: 100%;
    margin-bottom: 24px;
  }

  .ceremony-card .family-row span,
  .ceremony-card .role,
  .ceremony-card .ceremony-date span {
    font-size: 12px;
  }

  .ceremony-card .family-row strong {
    font-size: 14px;
  }

  .ceremony-card .family-side small {
    font-size: 11px;
  }

  .ceremony-card .announce,
  .ceremony-card .ceremony-note,
  .ceremony-card .lunar-date {
    font-size: 13px;
  }

  .panel-flower-right {
    right: -72px;
    top: auto;
    bottom: 120px;
    width: 165px;
  }

  .panel-flower-left {
    left: -74px;
    width: 160px;
  }

  .ceremony-card h3 {
    max-width: 100%;
    font-size: clamp(28px, 7.6vw, 40px);
    line-height: 1.05;
    overflow-wrap: normal;
    white-space: nowrap;
  }

  .ceremony-card .couple-role-row {
    gap: clamp(14px, 4.5vw, 24px);
    margin: 8px auto 10px;
  }

  .ceremony-card .couple-role-row .role {
    font-size: clamp(18px, 4.8vw, 22px);
  }

  .ceremony-card .role-ornament-amp {
    font-size: clamp(54px, 14vw, 64px);
  }

  .ceremony-card .panel-amp {
    margin: 8px auto 2px;
    font-size: clamp(64px, 17vw, 76px);
  }

  .ceremony-card .ceremony-note {
    margin-top: 28px;
  }

  .ceremony-card .ceremony-time {
    font-size: 30px;
  }

  .ceremony-card .ceremony-date {
    width: min(100%, 270px);
    gap: 14px;
    margin-top: 22px;
  }

  .ceremony-card .ceremony-date strong {
    padding-right: 14px;
    font-size: 42px;
  }

  .ceremony-card .ceremony-flower-bottom-right {
    right: -24px;
    top: auto;
    bottom: -8px;
    width: 92px;
    max-width: 24%;
  }

  .ceremony-card .ceremony-flower-top-left {
    left: -28px;
    top: 10px;
    width: 78px;
    max-width: 22%;
  }

  .timeline-list {
    --timeline-gap: 20px;
    --timeline-axis: 115px;
    width: 100%;
    gap: var(--timeline-gap);
  }

  .timeline-list div {
    grid-template-columns: 30px 55px 24px 1fr;
    column-gap: 9px;
    min-height: 48px;
  }

  .timeline-icon {
    width: 34px;
    height: 34px;
  }

  .timeline-icon img {
    width: 34px;
    height: 34px;
  }

  .timeline-list time,
  .timeline-list p {
    font-size: 16px;
  }

  .timeline-flower {
    right: -42px;
    top: 68px;
    width: 116px;
  }

  .gift-envelope-image {
    width: min(82vw, 300px);
  }

  .gift-modal {
    padding: 12px;
  }

  .gift-modal__panel {
    width: calc(100% - 0px);
  }

  .gift-modal__body {
    padding: 18px;
  }

  .gift-qr-image {
    width: min(85%, 220px);
  }

  .guestbook-card {
    padding: 42px 22px 62px;
  }
}

@media (min-width: 701px) and (max-width: 899px) {
  .timeline-card {
    width: min(100%, 540px);
    padding: 36px 38px 40px;
  }

  .timeline-list {
    --timeline-axis: 135px;
    width: min(100%, 410px);
  }

  .timeline-list div {
    grid-template-columns: 38px 60px 26px minmax(120px, 1fr);
    column-gap: 12px;
  }

  .timeline-icon {
    width: 42px;
    height: 42px;
  }

  .timeline-icon img {
    width: 40px;
    height: 40px;
  }

  .timeline-flower {
    right: -62px;
    top: 76px;
    width: 145px;
  }
}

@media (max-width: 390px) {
  .ceremony-card .family-row {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .ceremony-card .family-row > div + div {
    border-left: 0;
    border-top: 1px solid rgba(255, 248, 239, 0.32);
    padding-top: 18px;
  }

  .ceremony-card .ceremony-flower-bottom-right {
    width: 76px;
    right: -26px;
    bottom: -8px;
  }

  .ceremony-card .ceremony-flower-top-left {
    width: 66px;
    left: -26px;
    top: 10px;
  }
}


/* Accessibility and small-screen polish */
:focus-visible {
  outline: 2px solid var(--soft-gold);
  outline-offset: 4px;
}

img,
video {
  max-width: 100%;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto !important;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
