#scene-root {
  position: fixed;
  inset: 0;
  z-index: 99999;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 28%, rgba(255, 209, 116, 0.16), transparent 32%),
    linear-gradient(180deg, #140905, #050202 72%);
  color: #fff8e9;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  transition:
    opacity 900ms ease,
    visibility 900ms ease;
}

#scene-root.is-complete {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

#scene-root::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  background:
    radial-gradient(circle at 50% 42%, rgba(255, 219, 119, 0.28), transparent 34%),
    linear-gradient(90deg, #9d5a0d, #f5c85f 28%, #d69524 49.8%, #c47e14 50.2%, #f5c85f 72%, #9d5a0d);
  opacity: 1;
  transition: opacity 90ms ease;
}

#scene-root.scene-ready::before {
  opacity: 0;
}

#curtain-scene {
  display: block;
  width: 100%;
  height: 100%;
  transform-origin: 50% 50%;
  transition:
    filter 1400ms cubic-bezier(0.22, 1, 0.36, 1),
    transform 1800ms cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal-copy {
  position: fixed;
  left: 50%;
  top: 50%;
  z-index: 2;
  width: min(1180px, calc(100vw - 48px));
  transform: translate(-50%, -44%);
  pointer-events: none;
  text-align: center;
  text-wrap: balance;
}

.reveal-copy p {
  margin: 0;
  opacity: 0;
  transform: translateY(14px);
  color: #fff4d5;
  text-shadow:
    0 3px 18px rgba(0, 0, 0, 0.66),
    0 0 42px rgba(255, 199, 104, 0.22);
  transition:
    opacity 900ms ease,
    transform 900ms ease;
}

.reveal-copy-line-welcome {
  font-weight: 760;
  line-height: 0.94;
  letter-spacing: 0;
}

.reveal-copy-visual {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  min-height: 1.18em;
}

[data-event-title] {
  color: #fff7df;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(40px, 5.3vw, 82px);
  font-style: italic;
  font-weight: 500;
  letter-spacing: 0;
  line-height: 1.02;
  white-space: nowrap;
  text-shadow:
    0 8px 28px rgba(0, 0, 0, 0.70),
    0 0 62px rgba(255, 219, 137, 0.31);
}

[data-final-event],
[data-non-event-prefix] {
  display: inline-block;
  vertical-align: baseline;
  max-width: 0;
  opacity: 0;
  overflow: hidden;
  color: inherit !important;
  transform: translateY(0.24em);
  filter: blur(5px);
  transition:
    max-width 1150ms cubic-bezier(0.16, 1, 0.3, 1),
    margin-left 1150ms cubic-bezier(0.16, 1, 0.3, 1),
    opacity 850ms ease,
    transform 1150ms cubic-bezier(0.16, 1, 0.3, 1),
    filter 1150ms ease;
}

[data-non-event-prefix] {
  transition-delay: 80ms;
}

.reveal-copy-line-welcome.is-non-event [data-final-event],
.reveal-copy-line-welcome.is-non-event [data-non-event-prefix] {
  max-width: 4.8em;
  opacity: 1;
  transform: translateY(0.14em);
  filter: blur(0);
}

.reveal-copy-line-welcome.is-non-event [data-final-event] {
  margin-left: 0.16em;
  transition-delay: 260ms;
}

.reveal-copy-line-anniversary {
  color: #fff5dc;
  font-size: clamp(21px, 2.4vw, 38px);
  font-weight: 640;
  line-height: 1.18;
}

.reveal-copy-line-campaign,
.reveal-copy-line-invitation {
  color: #ffd889;
  font-size: clamp(24px, 3.3vw, 48px);
  font-weight: 720;
  line-height: 1.1;
}

.reveal-copy-line-invitation {
  color: #fff7df;
  font-family: Georgia, "Times New Roman", serif !important;
  font-size: clamp(38px, 6vw, 88px);
  font-style: italic !important;
  font-weight: 500 !important;
  line-height: 0.98;
  letter-spacing: 0;
  text-shadow:
    0 10px 34px rgba(0, 0, 0, 0.74),
    0 0 76px rgba(255, 219, 137, 0.34);
}

.reveal-copy p + p {
  margin-top: clamp(8px, 1.2vh, 15px);
}

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

.reveal-copy p.is-dismissed {
  opacity: 0;
  transform: translateY(-12px);
  max-height: 0;
  margin-top: 0;
  overflow: hidden;
  transition-duration: 620ms;
}

.reveal-copy-line-invitation.is-visible {
  margin-top: 0;
}

.ellipsis {
  display: inline-grid;
  grid-auto-flow: column;
  width: 0.88em;
  justify-content: start;
  color: inherit;
  font: inherit;
  text-shadow: inherit;
}

.ellipsis span {
  color: currentColor;
  font: inherit;
  text-shadow: inherit;
  opacity: 0;
  transform: translateY(0.16em);
  transition:
    opacity 320ms ease,
    transform 320ms ease;
}

.ellipsis span.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.page-transition {
  position: fixed;
  inset: 0;
  z-index: 5;
  pointer-events: none;
  opacity: 0;
  transform: scale(0.86);
  background:
    radial-gradient(circle at 50% 49%, rgba(255, 246, 216, 0.92), rgba(255, 206, 112, 0.52) 18%, rgba(35, 15, 6, 0.2) 42%, rgba(4, 2, 1, 0.86) 78%),
    linear-gradient(180deg, rgba(255, 238, 190, 0.28), rgba(5, 2, 1, 0.92));
  transition:
    opacity 1150ms ease,
    transform 1500ms cubic-bezier(0.16, 1, 0.3, 1);
}

#scene-root.is-transitioning #curtain-scene {
  filter: brightness(1.22) saturate(1.05) blur(1.5px);
  transform: scale(1.12);
}

#scene-root.is-transitioning .reveal-copy {
  opacity: 0;
  transform: translate(-50%, -44%) scale(1.08);
  transition:
    opacity 760ms ease,
    transform 1200ms cubic-bezier(0.16, 1, 0.3, 1);
}

#scene-root.is-transitioning .page-transition {
  opacity: 1;
  transform: scale(1);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.replay-button {
  position: fixed;
  right: clamp(18px, 3vw, 34px);
  bottom: clamp(18px, 3vw, 34px);
  z-index: 4;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid rgba(255, 214, 137, 0.42);
  border-radius: 999px;
  background: rgba(15, 8, 4, 0.48);
  color: #fff3d0;
  font-size: 13px;
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  box-shadow: 0 16px 44px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(14px);
  cursor: pointer;
  transition:
    background-color 180ms ease,
    border-color 180ms ease,
    transform 180ms ease;
}

.enter-event-button {
  position: fixed;
  left: clamp(18px, 3vw, 34px);
  bottom: clamp(18px, 3vw, 34px);
  z-index: 4;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid rgba(255, 214, 137, 0.42);
  border-radius: 999px;
  background: rgba(15, 8, 4, 0.48);
  color: #fff3d0;
  font-size: 13px;
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  box-shadow: 0 16px 44px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(14px);
  cursor: pointer;
  transition:
    background-color 180ms ease,
    border-color 180ms ease,
    transform 180ms ease;
}

.enter-event-button:hover,
.enter-event-button:focus-visible {
  border-color: rgba(255, 227, 172, 0.74);
  background: rgba(57, 33, 13, 0.58);
  outline: none;
  transform: translateY(-1px);
}

.replay-button:hover,
.replay-button:focus-visible {
  border-color: rgba(255, 227, 172, 0.74);
  background: rgba(57, 33, 13, 0.58);
  outline: none;
  transform: translateY(-1px);
}

.fallback {
  position: fixed;
  inset: 0;
  display: none;
  place-content: center;
  gap: 12px;
  padding: 28px;
  text-align: center;
  background:
    radial-gradient(circle at 50% 22%, rgba(255, 222, 151, 0.28), transparent 36%),
    linear-gradient(180deg, #3b210a, #080302);
}

.fallback strong,
.fallback span {
  display: block;
}

.fallback strong {
  font-size: clamp(34px, 8vw, 86px);
  line-height: 0.95;
}

.fallback span {
  max-width: 560px;
  margin-top: 12px;
  color: rgba(255, 248, 233, 0.78);
  font-size: 17px;
  line-height: 1.5;
}

.no-webgl .fallback {
  display: grid;
}

.no-webgl #curtain-scene,
.no-webgl .enter-event-button,
.no-webgl .replay-button,
.no-webgl #scene-root::before {
  display: none;
}

@media (max-width: 720px) {
  .reveal-copy {
    top: 52%;
    width: min(92vw, 520px);
  }

  .reveal-copy-line-welcome,
  .reveal-copy-line-invitation {
    font-size: clamp(31px, 11vw, 54px);
  }

  .reveal-copy-line-anniversary,
  .reveal-copy-line-campaign {
    font-size: clamp(18px, 5.8vw, 28px);
  }

  .reveal-copy-visual {
    max-width: min(96vw, 620px);
  }

  [data-event-title] {
    font-size: clamp(20px, 5.8vw, 36px);
    white-space: nowrap;
  }

  .enter-event-button,
  .replay-button {
    bottom: 16px;
    min-height: 40px;
    padding: 0 14px;
    font-size: 12px;
  }

  .enter-event-button {
    left: 16px;
  }

  .replay-button {
    right: 16px;
  }
}
