.eterna {
  background: #eee8dc;
}
.eterna .invitation-content {
  background: var(--paper);
}
.wedding-gate {
  background:
    radial-gradient(ellipse at 25% 20%, #fffdf8, transparent 60%), #f2eadb;
}
.wedding-gate:before {
  content: "";
  position: absolute;
  inset: 22px;
  border: 1px solid #c9b78988;
  pointer-events: none;
}
.wedding-gate .gate-title {
  color: #77644c;
  font-style: italic;
  font-size: clamp(27px, 5vw, 40px);
  max-width: 340px;
  line-height: 1.3;
}
.envelope {
  position: relative;
  width: min(340px, 90vw);
  height: 220px;
  perspective: 800px;
  margin-top: 15px;
  filter: drop-shadow(0 15px 20px #927c4b33);
}
.envelope-back {
  position: absolute;
  inset: 0;
  background: #ddcba8;
  border-radius: 3px;
  z-index: 0;
}
.envelope-face {
  position: absolute;
  inset: 0;
  z-index: 3;
  background:
    linear-gradient(32deg, #efdfbf 49.7%, transparent 50.3%),
    linear-gradient(-32deg, #eddbb7 49.7%, transparent 50.3%);
  border-radius: 3px;
  pointer-events: none;
}
.envelope-face:after {
  content: "";
  position: absolute;
  inset: 0;
  clip-path: polygon(0 100%, 50% 42%, 100% 100%);
  background: linear-gradient(#f4e6c9, #ecd8b0);
  border-bottom: 1px solid #b99a61;
}
.envelope-flap {
  position: absolute;
  inset: 0;
  background: linear-gradient(#e5d2af, #efddbc);
  clip-path: polygon(0 0, 100% 0, 50% 62%);
  z-index: 4;
  transform-origin: top;
  transition:
    transform 0.75s ease,
    z-index 0s 0.4s;
  backface-visibility: hidden;
}
.wax-seal {
  position: absolute;
  z-index: 5;
  left: calc(50% - 34px);
  top: 95px;
  width: 68px;
  height: 66px;
  border-radius: 44% 52% 47% 48%;
  border: 3px solid #b99458;
  background: radial-gradient(circle at 35% 25%, #e0c082, #b89352 65%, #93713e);
  box-shadow:
    inset 0 0 0 3px #dcba7977,
    0 4px 8px #5b422d33;
  color: #7d5a2d;
  transition:
    opacity 0.3s,
    transform 0.4s;
  animation: seal-breathe 3.6s ease-in-out infinite;
}
.wax-seal span {
  font-family: var(--serif);
  font-size: 24px;
  letter-spacing: -4px;
  border: 1px solid #8e6c37;
  border-radius: 50%;
  padding: 7px 12px 7px 8px;
  text-shadow: 0 1px #f4d99d;
}
.envelope-letter {
  position: absolute;
  left: 6%;
  top: 5%;
  width: 88%;
  height: 90%;
  background: #fcf8ed;
  z-index: 1;
  text-align: center;
  padding: 23px 8px;
  border: 1px solid #d8c598;
  transition: transform 1s 0.65s;
}
.envelope-letter small {
  font-size: 7px;
  letter-spacing: 2px;
  display: block;
}
.envelope-letter > span {
  font-family: var(--serif);
  font-size: 23px;
  line-height: 1.2;
  display: block;
  margin: 10px 0;
}
.envelope-letter i {
  font-size: 20px;
  display: block;
  color: #ab8d51;
}
.envelope-letter b {
  font-size: 8px;
  font-weight: 400;
  letter-spacing: 2px;
}
.gate-instruction {
  font-size: 10px;
  letter-spacing: 1px;
  margin-top: 33px;
  color: #9a8766;
}
.opening .wax-seal {
  animation: none;
  transform: scale(0.5);
  opacity: 0;
}
.opening .envelope-flap {
  transform: rotateX(180deg);
  z-index: 0;
}
.opening .envelope-letter {
  transform: translateY(-145px) scale(1.08);
  z-index: 2;
}
.opening.wedding-gate {
  animation: gate-dissolve 0.5s 1.45s forwards;
}
.gate-flower {
  position: absolute;
  color: #b5ad8470;
  line-height: 1;
  font-size: 210px;
  z-index: -1;
}
.gate-flower.f1 {
  left: -70px;
  bottom: 65px;
  transform: rotate(18deg);
}
.gate-flower.f2 {
  right: -65px;
  top: 45px;
  font-size: 170px;
}
.wedding-hero {
  padding-top: 75px;
}
.wedding-hero:before,
.wedding-hero:after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: 1px;
  background: linear-gradient(transparent, #d1bea14d, transparent);
  pointer-events: none;
  z-index: -1;
}
.wedding-hero:before {
  left: 18px;
}
.wedding-hero:after {
  right: 18px;
}
.wedding-hero h1 {
  font-size: clamp(53px, 8vw, 83px);
  margin: 10px 0 36px;
  letter-spacing: -2px;
}
.ampersand {
  font-style: italic;
  color: #b49a67;
  font-size: 0.52em;
  display: block;
  margin: 5px 0;
  line-height: 0.9;
}
.wedding-hero .hero-photo-frame {
  width: 80%;
  max-width: 370px;
  height: 420px;
  border-radius: 180px 180px 3px 3px;
  position: relative;
  outline: 1px solid #bda471;
  outline-offset: 8px;
  margin: 8px auto 17px;
  background: #e5d9c5;
}
.wedding-hero .hero-photo {
  transform: scale(1.04);
  animation: kenburns 18s ease-in-out infinite alternate;
  animation-play-state: paused;
}
.wedding-hero.in-view .hero-photo {
  animation-play-state: running;
}
.photo-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 33px 10px 18px;
  background: linear-gradient(transparent, #4d493675);
  color: #fff3dc;
  font: italic 21px var(--serif);
  text-align: center;
}
.petals {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 4;
  overflow: hidden;
}
.petals i {
  position: absolute;
  top: -40px;
  width: 7px;
  height: 13px;
  border-radius: 80% 10% 80% 20%;
  background: #e5c6a07d;
  animation: petal-fall 16s linear infinite;
  animation-play-state: paused;
  opacity: 0.7;
}
.in-view .petals i {
  animation-play-state: running;
}
.personal-note {
  font-family: var(--serif);
  font-style: italic;
  font-size: 22px;
  margin: 5px 0 0;
}
.scroll-note {
  font-size: 8px;
  letter-spacing: 3px;
  color: var(--accent);
  margin-top: 24px;
}
.scroll-note span {
  display: block;
  font-size: 20px;
  margin-top: 12px;
  animation: arrow 2s ease-in-out infinite;
}
.eterna .countdown-scene {
  background: #f0e8d8;
  border-top: 1px solid #e0d4bd;
  border-bottom: 1px solid #e0d4bd;
}
.eterna .location-scene {
  padding-top: 95px;
  padding-bottom: 65px;
}
.eterna .location-arch {
  background: radial-gradient(ellipse at 50% 5%, #f1e7d2, transparent 70%);
}
.eterna .reception-scene {
  padding-top: 45px;
}
.eterna .story-scene {
  background: #f5efdf;
}
.eterna .story-moment p,
.eterna .story-moment h3,
.eterna .story-moment small,
.eterna .story-dot {
  background: #f5efdf;
}
.eterna .family-scene {
  background: #e9e7d8;
  --accent: #7c8161;
}
.eterna .schedule-scene:after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 25%;
  right: 25%;
  height: 1px;
  background: var(--line);
}
.eterna .gallery-scene {
  background: #f0e8d8;
}
.eterna .dress-scene {
  padding-bottom: 50px;
}
.eterna .gifts-scene {
  padding-top: 50px;
}
.eterna .rsvp-scene {
  background: #ece7d7;
  border-top: 1px solid var(--line);
}
.eterna .story-line:before {
  transform: scaleY(0.1);
  transform-origin: top;
  transition: transform 1.8s;
}
.eterna .story-scene.seen .story-line:before {
  transform: scaleY(1);
}
.eterna .schedule.seen article {
}
.eterna .schedule-scene.seen .schedule-mark {
  animation: golden-pulse 1.2s calc(var(--order) * 0.3s) both;
}
.eterna .gallery-scene.seen .gallery-photo {
  animation: photo-deal 0.8s both;
}
.eterna .scene h2 {
  position: relative;
}
.eterna .scene h2:after {
  content: "";
  display: block;
  width: 0;
  height: 1px;
  background: var(--accent);
  margin: 22px auto 0;
  transition: width 1s 0.1s;
  opacity: 0.5;
}
.eterna .scene.seen h2:after {
  width: 40px;
}
@keyframes seal-breathe {
  50% {
    box-shadow:
      inset 0 0 0 3px #dcba7977,
      0 4px 8px #5b422d33,
      0 0 0 7px #c09c6122;
  }
}
@keyframes gate-dissolve {
  to {
    opacity: 0;
    transform: scale(1.04);
  }
}
@keyframes kenburns {
  to {
    transform: scale(1.13) translateY(-4px);
  }
}
@keyframes petal-fall {
  to {
    transform: translate(80px, 1300px) rotate(340deg);
  }
}
@keyframes arrow {
  50% {
    transform: translateY(6px);
  }
}
@keyframes golden-pulse {
  50% {
    transform: scale(1.5);
    color: #c5a46b;
  }
}
@keyframes photo-deal {
  from {
    transform: rotate(0) scale(0.96);
    filter: sepia(0.3);
  }
  to {
    transform: rotate(var(--rotation)) scale(1);
    filter: sepia(0);
  }
}
@media (max-width: 400px) {
  .wedding-hero .hero-photo-frame {
    height: 340px;
    width: 82%;
    margin-top: 4px;
  }
  .wedding-hero h1 {
    font-size: 53px;
    margin-bottom: 27px;
  }
  .wedding-hero {
    padding-top: 70px;
    padding-bottom: 40px;
  }
  .envelope {
    width: 290px;
    height: 195px;
  }
  .wax-seal {
    top: 83px;
  }
  .gate-title {
    margin-bottom: 35px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .petals {
    display: none;
  }
  .story-line:before {
    transform: scaleY(1) !important;
  }
  .opening.wedding-gate {
    opacity: 0;
  }
}
