@font-face {
  font-family: "Orpheus Pro";
  src: url("assets/fonts/Orpheus-Pro.otf?v=ef3f16eb06bf") format("opentype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: Gabriola;
  src: url("assets/fonts/Gabriola.ttf?v=ef3f16eb06bf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Cinzel Decorative";
  src: url("assets/fonts/CinzelDecorative-Regular.ttf?v=ef3f16eb06bf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: Poppins;
  src: url("assets/fonts/Poppins-Light.ttf?v=ef3f16eb06bf") format("truetype");
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: Poppins;
  src: url("assets/fonts/Poppins-SemiBold.ttf?v=ef3f16eb06bf") format("truetype");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: Poppins;
  src: url("assets/fonts/Poppins-Regular.ttf?v=ef3f16eb06bf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light;
  font-family: Poppins, sans-serif;
  font-synthesis: none;
  --navy: #20365b;
  --ink: #061739;
  --blue: #16477a;
  --paper: #fff;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--navy); }
button, a { -webkit-tap-highlight-color: transparent; }
button { font: inherit; }
button, a { touch-action: manipulation; }
a { color: inherit; }
p, h1, h2 { margin: 0; font-weight: 400; }
button:focus-visible, a:focus-visible { outline: 3px solid #8cbceb; outline-offset: 5px; }
h2:focus { outline: none; }
[hidden] { display: none !important; }

.invitation {
  height: 100vh;
  height: 100svh;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior-y: contain;
  scroll-snap-type: y mandatory;
  scrollbar-width: none;
}
.invitation::-webkit-scrollbar { display: none; }
.invitation.is-locked { overflow-y: hidden; }
.invitation.is-moving { scroll-snap-type: none; }
.slide {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  scroll-snap-align: start;
  scroll-snap-stop: always;
  isolation: isolate;
}
.section-content { position: relative; }
.js .section-content { opacity: 0; }
.js .is-visible .section-content { opacity: 1; animation: fade-in 1.1s ease both; }
.js .invitation.is-scrolling .section-content { opacity: 0; animation: none; }
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }

.cover {
  display: flex;
  justify-content: center;
  background: #e9f0f8 url("assets/background-white.jpg?v=ef3f16eb06bf") center / cover;
  color: var(--ink);
}
.cover-frame {
  position: relative;
  width: 100%;
  max-width: 56.25vh;
  max-width: 56.25svh;
  height: 100vh;
  height: 100svh;
  --u: .5625svh; /* 1% of the cover image width: the image always fills the frame by height */
  background: #cfe4fa url("assets/cover-poster.jpg?v=ef3f16eb06bf") center / cover;
}
.cover-copy { height: 100%; text-align: center; }
.cover-heading { position: absolute; top: 14.2%; width: 100%; padding: 0 3%; }
.cover-kicker, .cover-date, .salutation { font-weight: 300; }
.cover-kicker { font-size: calc(calc(var(--u) * 3.4) + .5px); text-transform: uppercase; letter-spacing: .06em; }
h1 { margin-top: calc(var(--u) * 2.2); font-family: "Cinzel Decorative", Georgia, serif; font-size: calc(min(calc(var(--u) * 7.4), 9.8vw) + .5px); line-height: 1.2; white-space: nowrap; }
h1 .ampersand { margin: 0 .12em; }
.cover-date { margin-top: calc(var(--u) * 1.2); font-size: calc(calc(var(--u) * 3.8) + .5px); letter-spacing: .16em; }
.guest-block { position: absolute; top: 75%; width: 100%; padding: 0 6%; }
.salutation { font-size: calc(calc(var(--u) * 3.4) + .5px); line-height: 1.3; letter-spacing: .04em; }
.guest-name { margin: calc(var(--u) * .3) auto calc(var(--u) * 1.6); max-width: 100%; font-family: Gabriola, "Segoe Script", cursive; font-size: calc(calc(var(--u) * 7.4) + .5px); line-height: 1.1; overflow-wrap: anywhere; }
.guest-name.is-long { font-size: calc(calc(var(--u) * 5) + .5px); }
.open-button { display: inline-block; width: calc(var(--u) * 40.5); min-width: 44px; line-height: 0; }
.open-button img { width: 100%; height: auto; }
.js .open-button { animation: pulse 1.8s ease-in-out infinite; }
@keyframes pulse { 50% { transform: scale(1.07); } }
/* Hold the whole cover (image + text) until the poster is decoded, then fade everything in together. */
.js:not(.cover-ready) .cover-frame { visibility: hidden; }
.js:not(.cover-ready) .cover .section-content { animation: none; }

.blue-slide { position: relative; background: var(--navy) url("assets/background-blue.jpg?v=ef3f16eb06bf") center / cover; color: var(--paper); }
.page-title { font-family: "Cinzel Decorative", Georgia, serif; font-size: calc(clamp(31px, 4.7vw, 57px) + .5px); text-align: center; line-height: 1.18; }
.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: .4em 1.7em;
  border: 3px solid transparent;
  border-radius: 999px;
  color: var(--paper);
  background: linear-gradient(#0f2557, #0f2557) padding-box, linear-gradient(135deg, #8a6a3a, #e2cb9c 50%, #8a6a3a) border-box;
  box-shadow: 0 6px 14px #0006;
  font: inherit;
  font-size: clamp(13px, 3.5vw, 17px);
  text-decoration: none;
  cursor: pointer;
}
.pill:hover { filter: brightness(1.2); }
.couple-content, .reception-content, .gallery-content, .gift-content {
  display: flex;
  min-height: 100vh;
  min-height: 100svh;
  padding: 6svh 18px 8svh;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}
.couple-photo { width: min(92vw, 42svh); height: auto; margin: 1.5svh 0 2svh; }
.person h3 { margin: 0; font-family: "Cinzel Decorative", Georgia, serif; font-weight: 400; font-size: calc(clamp(22px, 3.5vw, 40px) + .5px); line-height: 1.35; }
.person p { margin-top: .8svh; font-size: calc(clamp(11px, 1.4vw, 16px) + .5px); line-height: 1.7; font-style: italic; font-synthesis: style; }
.groom { margin-top: 2.6svh; max-width: 100%; }
em { font-synthesis: style; }

.reception-content { gap: 2.6svh; }
.event-date { margin-top: 1svh; font-size: calc(clamp(13px, 1.7vw, 20px) + .5px); }
.countdown { display: flex; justify-content: center; gap: clamp(18px, 5vw, 44px); }
.countdown div { display: grid; min-width: 2.2em; font-size: calc(clamp(14px, 3.4vw, 20px) + .5px); }
.countdown b { font-family: "Palatino Linotype", "Book Antiqua", Palatino, Georgia, serif; font-weight: 400; font-size: 2.6em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.event-row { display: flex; flex-direction: column; align-items: center; gap: 1.2svh; }
.event-icon { width: clamp(30px, 4.5svh, 42px); height: clamp(30px, 4.5svh, 42px); stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.event-row p { font-size: calc(clamp(13px, 1.7vw, 20px) + .5px); line-height: 1.6; }
.reception-content .pill { margin-top: 1svh; animation: pulse 1.8s ease-in-out infinite; }
sup { font-size: .65em; line-height: 0; }

.gallery { width: min(82vw, 42svh); margin-top: 3svh; }
.gallery-frame { position: relative; padding: 5px; border-radius: 12% / 9%; background: linear-gradient(135deg, #8a6a3a, #e2cb9c 50%, #8a6a3a); }
.gallery-track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; border-radius: 11% / 8.2%; aspect-ratio: 894 / 1098; }
.gallery-track::-webkit-scrollbar { display: none; }
.gallery-track img { flex: 0 0 100%; width: 100%; height: 100%; object-fit: cover; scroll-snap-align: center; scroll-snap-stop: always; }
.gallery-nav { position: absolute; top: 50%; width: 44px; height: 44px; margin-top: -22px; border: 0; border-radius: 50%; color: #fff; background: #ffffff55; display: grid; place-items: center; cursor: pointer; }
.gallery-nav.prev { left: 5%; }
.gallery-nav.next { right: 5%; }
.gallery-nav svg { width: 22px; height: 22px; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.gallery-caption { margin-top: 2svh; font-style: italic; font-size: calc(clamp(13px, 1.7vw, 20px) + .5px); }
.gallery-count { margin-top: 1svh; font-size: calc(clamp(14px, 2vw, 22px) + .5px); }

.gift-content { gap: 3svh; }
.gift-content .page-title { font-size: calc(clamp(31px, 4.7vw, 57px) + 1px); }
#copy-account { margin: -1.5svh 0 -.3svh; min-height: 38px; padding: .35em 1.6em; font-size: 14px; }
.gift-text { font-size: calc(clamp(13px, 3.52vw, 19px) + .5px); line-height: 1.7; }
.account strong { font-weight: 600; }
.account { font-size: calc(clamp(14px, 3.6vw, 20px) + 1.5px); line-height: 1.7; }
.see-you { font-family: "Cinzel Decorative", Georgia, serif; font-size: calc(clamp(29px, 7vw, 43px) + .5px); line-height: 1.3; }


.music-toggle { position: fixed; right: max(18px, env(safe-area-inset-right)); bottom: max(20px, env(safe-area-inset-bottom)); z-index: 5; width: 44px; height: 44px; border: 1px solid #ffffff70; border-radius: 50%; color: white; background: #1a305c; display: grid; place-items: center; cursor: pointer; }
.music-toggle svg { width: 21px; height: 21px; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.music-toggle[aria-pressed="true"] .music-off { display: none; }
.music-toggle:disabled { opacity: .5; cursor: default; }
.music-status { position: fixed; right: max(18px, env(safe-area-inset-right)); top: max(20px, env(safe-area-inset-top)); z-index: 5; max-width: calc(100vw - 36px); padding: 8px 12px; border-radius: 16px; color: white; background: #1a305c; font-size: 12px; pointer-events: none; }

@media (max-width: 600px) {
  .js .is-visible .section-content { animation-duration: 2s; }
  .page-title { font-size: calc(7.7vw + .5px); }
  .gift-content .page-title { font-size: calc(7.7vw + 1px); }
  .person h3 { font-size: calc(clamp(21px, 6.4vw, 32px) + .5px); }
  .person p { font-size: calc(clamp(12px, 3.05vw, 16px) + .5px); }
  .couple-content, .reception-content, .gallery-content, .gift-content { padding-left: 12px; padding-right: 12px; }
}
@media (max-height: 550px) and (min-width: 600px) {
  .couple-content, .reception-content, .gallery-content, .gift-content { justify-content: flex-start; padding-top: 25px; padding-bottom: 60px; }
}
@media (prefers-reduced-motion: reduce) {
  .js .is-visible .section-content, .js .open-button, .reception-content .pill { animation: none; }
  .invitation { scroll-behavior: auto; }
}


/* Cinzel Decorative's "H" is open on the right and merges into "E"; add a gap after it. */
.he { margin-right: .05em; }
