:root {
  --ink: #101827;
  --ink-soft: #1d2b3c;
  --plum: #5a1734;
  --plum-deep: #381023;
  --gold: #caa45b;
  --gold-light: #e5cc8d;
  --ivory: #f8f3e8;
  --paper: #fffdf7;
  --lake: #688797;
  --mist: #dce8e8;
  --rose: #b85d6d;
  --shadow: 0 24px 80px rgba(8, 15, 26, 0.2);
  --serif: "Iowan Old Style", "Baskerville", "Times New Roman", "Noto Serif Devanagari", Georgia, serif;
  --sans: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans Devanagari", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  background: var(--ink);
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--ivory);
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.6;
  overflow-x: hidden;
}

body.is-locked {
  overflow: hidden;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button,
input,
textarea,
select {
  font: inherit;
}

button:focus-visible,
a:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--gold-light);
  outline-offset: 4px;
}

img {
  display: block;
  max-width: 100%;
}

.skip-link {
  position: fixed;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 100;
  transform: translateY(-150%);
  padding: 0.75rem 1rem;
  color: var(--ink);
  background: var(--paper);
  border-radius: 999px;
  text-decoration: none;
  transition: transform 180ms ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.invitation-gate {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  min-height: 100svh;
  padding: 1.25rem;
  overflow: hidden;
  color: var(--ivory);
  background:
    linear-gradient(135deg, rgba(16, 24, 39, 0.9), rgba(78, 28, 48, 0.72)),
    url("./assets/01-niagara-meet.webp") center 34% / cover;
  transition: opacity 750ms ease, visibility 750ms ease;
}

.invitation-gate::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 20%, rgba(226, 188, 103, 0.25), transparent 42%);
  backdrop-filter: blur(8px);
}

.invitation-gate.is-opened {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.gate-glow {
  position: absolute;
  width: 28rem;
  height: 28rem;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.24;
  animation: drift 8s ease-in-out infinite alternate;
}

.gate-glow--one {
  top: -10rem;
  left: -8rem;
  background: #d18a4e;
}

.gate-glow--two {
  right: -10rem;
  bottom: -12rem;
  background: #6d8ca2;
  animation-delay: -3s;
}

.gate-stage {
  position: relative;
  z-index: 2;
  width: min(31rem, 100%);
  text-align: center;
}

.gate-language {
  position: absolute;
  z-index: 3;
  top: max(1.25rem, env(safe-area-inset-top));
  right: max(1.25rem, env(safe-area-inset-right));
  display: flex;
  align-items: center;
  gap: 0.35rem;
  color: rgba(255, 255, 255, 0.78);
}

.lang-button {
  padding: 0.25rem 0.35rem;
  color: inherit;
  background: transparent;
  border: 0;
  cursor: pointer;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  opacity: 0.58;
}

.lang-button.is-active {
  opacity: 1;
}

.gate-eyebrow,
.gate-note {
  margin: 0.7rem 0;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.gate-note {
  letter-spacing: 0.08em;
  text-transform: none;
  opacity: 0.75;
}

.invitation-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: min(68svh, 43rem);
  padding: clamp(2rem, 7vw, 4.5rem) 2rem;
  overflow: hidden;
  color: var(--ink);
  background:
    radial-gradient(circle at 50% 35%, rgba(255,255,255,0.95), rgba(248,243,232,0.8)),
    repeating-linear-gradient(45deg, rgba(202,164,91,0.025) 0 1px, transparent 1px 6px),
    var(--ivory);
  border: 1px solid rgba(255,255,255,0.75);
  border-radius: 1.5rem;
  box-shadow: 0 35px 100px rgba(0, 0, 0, 0.38);
}

.invitation-card::after {
  content: "";
  position: absolute;
  inset: 0.85rem;
  border: 1px solid rgba(202, 164, 91, 0.35);
  border-radius: 1rem;
  pointer-events: none;
}

.emboss {
  position: absolute;
  width: 9rem;
  height: 9rem;
  border: 1px solid rgba(202, 164, 91, 0.18);
  border-radius: 50%;
  box-shadow: inset 0 0 0 12px rgba(255,255,255,0.24), 0 1px 0 rgba(255,255,255,0.7);
}

.emboss--top {
  top: -5rem;
  right: -3rem;
}

.emboss--bottom {
  bottom: -5.2rem;
  left: -3rem;
}

.monogram {
  display: grid;
  place-items: center;
  width: 5.25rem;
  height: 5.25rem;
  margin-bottom: 1.8rem;
  border: 1px solid var(--gold);
  border-radius: 50%;
  font-family: var(--serif);
  font-size: 1.6rem;
  letter-spacing: -0.08em;
}

.monogram span {
  margin: 0 -0.15em;
  color: var(--gold);
  font-size: 0.78em;
  font-style: italic;
}

.card-kicker,
.card-line {
  max-width: 18rem;
  margin: 0.45rem auto;
  color: #5f5d58;
  font-family: var(--serif);
  font-size: 1rem;
}

.invitation-card h1 {
  margin: 0.25rem 0;
  font-family: var(--serif);
  font-size: clamp(2.7rem, 10vw, 5.4rem);
  font-weight: 400;
  line-height: 0.94;
  letter-spacing: -0.055em;
}

.invitation-card h1 i {
  color: var(--gold);
  font-weight: 400;
}

.wax-seal {
  position: relative;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 7rem;
  height: 7rem;
  margin-top: 2.2rem;
  color: #fff3e9;
  background:
    radial-gradient(circle at 35% 28%, #8c3553, transparent 28%),
    radial-gradient(circle, #6b1f3d 0 57%, #4f152e 58% 67%, #6b1f3d 68%);
  border: 0;
  border-radius: 50%;
  box-shadow: 0 14px 26px rgba(71, 18, 42, 0.26), inset 0 2px 3px rgba(255,255,255,0.2);
  cursor: pointer;
  transition: transform 200ms ease, box-shadow 200ms ease;
}

.wax-seal::before,
.wax-seal::after {
  content: "";
  position: absolute;
  inset: 0.7rem;
  border: 1px solid rgba(255, 226, 206, 0.45);
  border-radius: 50%;
}

.wax-seal::after {
  inset: -0.25rem;
  border-color: rgba(107, 31, 61, 0.3);
  animation: sealPulse 2.4s ease-out infinite;
}

.wax-seal:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 18px 32px rgba(71, 18, 42, 0.32), inset 0 2px 3px rgba(255,255,255,0.2);
}

.wax-initials {
  font-family: var(--serif);
  font-size: 1.45rem;
  letter-spacing: 0.08em;
}

.seal-action {
  position: absolute;
  top: calc(100% + 0.7rem);
  width: 12rem;
  color: var(--plum);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.site-shell {
  opacity: 0;
  transition: opacity 650ms ease 220ms;
}

.site-shell.is-visible {
  opacity: 1;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 4.75rem;
  padding: 0.75rem clamp(1rem, 4vw, 4rem);
  color: var(--ink);
  background: rgba(248, 243, 232, 0.9);
  border-bottom: 1px solid rgba(16, 24, 39, 0.08);
  backdrop-filter: blur(18px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  color: inherit;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  color: var(--ivory);
  background: var(--ink);
  border-radius: 0.75rem;
  font-family: var(--serif);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
}

.brand-copy {
  font-family: var(--serif);
  font-size: 1.05rem;
}

.brand-copy i {
  color: var(--gold);
}

.header-actions,
.language-switch {
  display: flex;
  align-items: center;
}

.header-actions {
  gap: 1rem;
}

.language-switch {
  gap: 0.15rem;
  color: var(--ink);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  min-height: 3.25rem;
  padding: 0.8rem 1.35rem;
  color: var(--ivory);
  background: var(--plum);
  border: 1px solid transparent;
  border-radius: 999px;
  box-shadow: 0 10px 24px rgba(90, 23, 52, 0.15);
  font-size: 0.84rem;
  font-weight: 750;
  letter-spacing: 0.06em;
  text-decoration: none;
  text-transform: uppercase;
  transition: transform 180ms ease, background 180ms ease, box-shadow 180ms ease;
}

.button:hover {
  transform: translateY(-2px);
  background: #6d1b40;
  box-shadow: 0 15px 30px rgba(90, 23, 52, 0.22);
}

.button--small {
  min-height: 2.6rem;
  padding: 0.55rem 1rem;
  font-size: 0.74rem;
}

.button--gold {
  color: var(--ink);
  background: linear-gradient(135deg, #edd7a2, var(--gold));
  box-shadow: 0 14px 30px rgba(202, 164, 91, 0.22);
}

.button--gold:hover {
  color: var(--ink);
  background: linear-gradient(135deg, #f4e4ba, #d3ac5e);
}

.hero {
  position: relative;
  min-height: calc(100svh - 4.75rem);
  overflow: hidden;
  color: var(--ivory);
  background: var(--ink);
}

.hero-image,
.hero-shade {
  position: absolute;
  inset: 0;
}

.hero-image {
  background: url("./assets/09-lakeside.webp") center 32% / cover;
  transform: scale(1.02);
  animation: slowZoom 18s ease-out both;
}

.hero-shade {
  background:
    linear-gradient(90deg, rgba(8, 15, 28, 0.94) 0%, rgba(8, 15, 28, 0.68) 42%, rgba(8, 15, 28, 0.08) 74%),
    linear-gradient(0deg, rgba(8, 15, 28, 0.8) 0%, transparent 44%);
}

.hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: min(52rem, 92%);
  min-height: calc(100svh - 4.75rem);
  padding: clamp(4rem, 10vw, 8rem) clamp(1.25rem, 8vw, 8rem);
}

.eyebrow {
  margin: 0 0 1rem;
  font-size: 0.72rem;
  font-weight: 750;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.eyebrow--gold {
  color: #9b6e28;
}

.hero h2,
.section-heading h2,
.rsvp-panel h2 {
  margin: 0;
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -0.055em;
}

.hero h2 {
  max-width: 10ch;
  font-size: clamp(3.6rem, 9.4vw, 8.8rem);
  line-height: 0.82;
}

.hero h2 span,
.hero h2 em {
  display: block;
}

.hero h2 em {
  margin-top: 0.18em;
  color: var(--gold-light);
  font-weight: 400;
}

.hero-intro {
  max-width: 35rem;
  margin: 2rem 0 1.5rem;
  color: rgba(255,255,255,0.8);
  font-family: var(--serif);
  font-size: clamp(1.1rem, 2vw, 1.35rem);
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  width: max-content;
  color: var(--ivory);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-decoration: none;
  text-transform: uppercase;
}

.text-link span:last-child {
  color: var(--gold);
  font-size: 1.2rem;
}

.hero-location {
  position: absolute;
  z-index: 2;
  right: clamp(1.25rem, 4vw, 4rem);
  bottom: clamp(1.5rem, 4vw, 3rem);
  display: flex;
  align-items: center;
  gap: 0.85rem;
  color: rgba(255,255,255,0.72);
  font-size: 0.76rem;
  letter-spacing: 0.08em;
}

.location-number {
  display: grid;
  place-items: center;
  width: 2.8rem;
  height: 2.8rem;
  border: 1px solid rgba(255,255,255,0.5);
  border-radius: 50%;
  color: var(--gold-light);
}

.reveal-section,
.story-section,
.gallery-section {
  padding: clamp(5rem, 10vw, 9rem) clamp(1rem, 6vw, 6rem);
}

.reveal-section {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 8% 18%, rgba(104, 135, 151, 0.22), transparent 28%),
    radial-gradient(circle at 92% 82%, rgba(184, 93, 109, 0.16), transparent 25%),
    var(--ivory);
}

.reveal-section::before {
  content: "15";
  position: absolute;
  top: -5rem;
  left: -1.5rem;
  color: rgba(202, 164, 91, 0.06);
  font-family: var(--serif);
  font-size: clamp(16rem, 38vw, 34rem);
  line-height: 1;
  pointer-events: none;
}

.section-heading {
  position: relative;
  z-index: 2;
  max-width: 46rem;
}

.section-heading--centered {
  margin: 0 auto 2.5rem;
  text-align: center;
}

.section-heading h2,
.rsvp-panel h2 {
  font-size: clamp(2.6rem, 6vw, 5.7rem);
  line-height: 0.96;
}

.section-heading > p:last-child {
  margin: 1.2rem 0 0;
  color: #5e6671;
}

.scratch-wrap {
  position: relative;
  z-index: 2;
  width: min(46rem, 100%);
  margin: 0 auto;
  text-align: center;
}

.scratch-card {
  position: relative;
  aspect-ratio: 1.65 / 1;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(248,243,232,0.94), rgba(255,255,255,0.82)),
    url("./assets/floral-vine.webp") right -4rem bottom -5rem / 18rem no-repeat;
  border: 1px solid rgba(202, 164, 91, 0.5);
  border-radius: clamp(1rem, 3vw, 2rem);
  box-shadow: var(--shadow);
}

.date-reveal {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  color: var(--ink);
  background: rgba(248, 243, 232, 0.86);
  backdrop-filter: blur(1px);
}

.date-reveal p {
  margin: 0;
  color: var(--plum);
  font-size: clamp(0.7rem, 2vw, 0.9rem);
  font-weight: 750;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.date-reveal strong {
  display: block;
  margin: 0.25rem 0;
  font-family: var(--serif);
  font-size: clamp(2.3rem, 9vw, 6rem);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.04em;
}

.date-reveal span {
  color: #69542d;
  font-family: var(--serif);
  font-size: clamp(1rem, 3vw, 1.45rem);
}

.date-reveal small {
  margin-top: 1rem;
  color: #67655f;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
}

#scratchCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  cursor: grab;
  touch-action: none;
  transition: opacity 650ms ease;
}

#scratchCanvas:active {
  cursor: grabbing;
}

#scratchCanvas.is-cleared {
  opacity: 0;
  pointer-events: none;
}

.reveal-fallback {
  margin-top: 1rem;
  padding: 0.55rem;
  color: var(--plum);
  background: transparent;
  border: 0;
  border-bottom: 1px solid currentColor;
  cursor: pointer;
  font-size: 0.78rem;
  font-weight: 700;
}

.story-section {
  color: var(--ivory);
  background:
    linear-gradient(rgba(16,24,39,0.96), rgba(16,24,39,0.96)),
    url("./assets/09-lakeside.webp") center / cover fixed;
}

.story-section .section-heading {
  margin-bottom: 3rem;
}

.story-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.story-card {
  overflow: hidden;
  background: rgba(255,255,255,0.055);
  border: 1px solid rgba(255,255,255,0.13);
  border-radius: 1.25rem;
}

.story-card-image {
  aspect-ratio: 4 / 3;
  background-position: center 28%;
  background-size: cover;
  filter: saturate(0.86);
  transition: transform 650ms ease, filter 650ms ease;
}

.story-card:hover .story-card-image {
  transform: scale(1.035);
  filter: saturate(1);
}

.story-card--niagara .story-card-image {
  background-image: url("./assets/05-niagara-together.webp");
}

.story-card--calgary .story-card-image {
  background-image: url("./assets/story-proposal.webp");
}

.story-card--udaipur .story-card-image {
  background-image: url("./assets/nr-story-monogram.webp");
}

.story-card-copy {
  padding: 1.5rem;
}

.story-card-copy > span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.45rem;
  height: 2.45rem;
  color: var(--gold-light);
  border: 1px solid rgba(202,164,91,0.5);
  border-radius: 50%;
  font-size: 0.68rem;
}

.story-place {
  margin: 1.1rem 0 0;
  color: var(--gold-light);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.story-card h3 {
  margin: 0.25rem 0 0.65rem;
  font-family: var(--serif);
  font-size: clamp(1.8rem, 3vw, 2.5rem);
  font-weight: 400;
}

.story-card-copy > p:last-child {
  margin: 0;
  color: rgba(255,255,255,0.68);
  font-size: 0.94rem;
}

.gallery-section {
  background: var(--paper);
}

.gallery-heading-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
  margin-bottom: 2.5rem;
}

.gallery-controls {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  flex: 0 0 auto;
}

.gallery-arrow {
  display: grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  color: var(--ink);
  background: transparent;
  border: 1px solid rgba(16,24,39,0.24);
  border-radius: 50%;
  cursor: pointer;
  transition: color 180ms ease, background 180ms ease;
}

.gallery-arrow:hover {
  color: var(--ivory);
  background: var(--ink);
}

.gallery-arrow:disabled {
  opacity: 0.35;
  cursor: default;
}

.gallery-status {
  min-width: 5.5rem;
  margin: 0;
  text-align: center;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.gallery-viewport {
  overflow-x: auto;
  scrollbar-width: none;
  scroll-snap-type: x mandatory;
  overscroll-behavior-inline: contain;
}

.gallery-viewport::-webkit-scrollbar {
  display: none;
}

.gallery-track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: calc((100% - 1.4rem) / 3);
  gap: 0.7rem;
}

.gallery-card {
  position: relative;
  aspect-ratio: 0.76;
  margin: 0;
  overflow: hidden;
  background: #d9d4ca;
  border-radius: clamp(0.65rem, 2vw, 1.25rem);
  scroll-snap-align: start;
}

.gallery-card::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 1px solid rgba(255,255,255,0.35);
  border-radius: inherit;
  pointer-events: none;
}

.gallery-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 28%;
  transition: transform 650ms ease;
}

.gallery-card:hover img {
  transform: scale(1.035);
}

.swipe-note {
  margin: 1rem 0 0;
  color: #6e6b64;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-align: right;
}

.rsvp-section {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(22rem, 0.95fr);
  min-height: 48rem;
  color: var(--ivory);
  background: var(--plum-deep);
}

.rsvp-photo {
  min-height: 34rem;
  background:
    linear-gradient(90deg, transparent 65%, rgba(56,16,35,0.5)),
    url("./assets/05-niagara-together.webp") center 30% / cover;
}

.rsvp-panel {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(3.5rem, 7vw, 7rem);
}

.rsvp-panel h2 {
  max-width: 10ch;
}

.rsvp-panel > p:not(.eyebrow):not(.rsvp-note) {
  max-width: 35rem;
  margin: 1.5rem 0 2rem;
  color: rgba(255,255,255,0.72);
}

.rsvp-panel .button {
  align-self: flex-start;
}

.rsvp-note {
  margin: 0.85rem 0 0;
  color: rgba(255,255,255,0.52);
  font-size: 0.72rem;
}

.site-footer {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 18rem;
  padding: 3rem 1rem;
  color: var(--ink);
  background:
    radial-gradient(circle at 50% 0, rgba(202,164,91,0.13), transparent 50%),
    var(--ivory);
  text-align: center;
}

.footer-monogram {
  display: grid;
  place-items: center;
  width: 4.25rem;
  height: 4.25rem;
  border: 1px solid var(--gold);
  border-radius: 50%;
  font-family: var(--serif);
  font-size: 1.2rem;
}

.site-footer p {
  margin: 1rem 0 0.25rem;
  font-family: var(--serif);
  font-size: 1.25rem;
}

.site-footer span {
  color: #76716a;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.mobile-rsvp {
  position: fixed;
  z-index: 15;
  right: 1rem;
  bottom: max(1rem, env(safe-area-inset-bottom));
  left: 1rem;
  display: none;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  min-height: 3.5rem;
  color: var(--ink);
  background: linear-gradient(135deg, #efdcae, var(--gold));
  border: 1px solid rgba(255,255,255,0.45);
  border-radius: 999px;
  box-shadow: 0 16px 36px rgba(16,24,39,0.24);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-decoration: none;
  text-transform: uppercase;
}

@keyframes sealPulse {
  0% { transform: scale(0.98); opacity: 0.7; }
  80%, 100% { transform: scale(1.18); opacity: 0; }
}

@keyframes drift {
  from { transform: translate3d(0, 0, 0); }
  to { transform: translate3d(2rem, 1rem, 0); }
}

@keyframes slowZoom {
  from { transform: scale(1.02); }
  to { transform: scale(1.1); }
}

@media (max-width: 860px) {
  .story-grid {
    grid-template-columns: 1fr;
  }

  .story-card {
    display: grid;
    grid-template-columns: minmax(10rem, 0.8fr) minmax(0, 1.2fr);
  }

  .story-card-image {
    height: 100%;
    aspect-ratio: auto;
  }

  .rsvp-section {
    grid-template-columns: 1fr;
  }

  .rsvp-photo {
    min-height: 60svh;
    background-position: center 25%;
  }

  .rsvp-panel {
    min-height: 34rem;
  }
}

@media (max-width: 640px) {
  .site-header {
    min-height: 4.25rem;
    padding: 0.55rem 0.85rem;
  }

  .brand-copy,
  .header-actions .button {
    display: none;
  }

  .brand-mark {
    width: 2.35rem;
    height: 2.35rem;
  }

  .header-actions {
    gap: 0.5rem;
  }

  .hero {
    min-height: calc(100svh - 4.25rem);
  }

  .hero-image {
    background-position: 61% 24%;
  }

  .hero-shade {
    background:
      linear-gradient(0deg, rgba(8,15,28,0.96) 0%, rgba(8,15,28,0.64) 54%, rgba(8,15,28,0.2) 100%),
      linear-gradient(90deg, rgba(8,15,28,0.48), transparent);
  }

  .hero-content {
    justify-content: flex-end;
    min-height: calc(100svh - 4.25rem);
    padding: 6rem 1.2rem 7.5rem;
  }

  .hero h2 {
    max-width: 9ch;
    font-size: clamp(3.7rem, 17vw, 5.5rem);
  }

  .hero-intro {
    font-size: 1.05rem;
  }

  .hero-location {
    right: auto;
    bottom: 1.5rem;
    left: 1.2rem;
  }

  .reveal-section,
  .story-section,
  .gallery-section {
    padding: 4.5rem 1rem;
  }

  .scratch-card {
    aspect-ratio: 1.2 / 1;
  }

  .date-reveal strong {
    font-size: clamp(2.45rem, 13vw, 4rem);
  }

  .story-section {
    background-attachment: scroll;
  }

  .story-card {
    display: block;
  }

  .story-card-image {
    aspect-ratio: 4 / 3;
  }

  .gallery-heading-row {
    display: block;
  }

  .gallery-controls {
    justify-content: space-between;
    margin-top: 1.5rem;
  }

  .gallery-track {
    grid-auto-columns: calc((100% - 0.8rem) / 3);
    gap: 0.4rem;
  }

  .gallery-card {
    aspect-ratio: 0.68;
  }

  .swipe-note {
    text-align: left;
  }

  .rsvp-photo {
    min-height: 60svh;
    background-position: center 24%;
  }

  .rsvp-panel {
    padding: 4rem 1.25rem 6.5rem;
  }

  .rsvp-panel .button {
    width: 100%;
  }

  .mobile-rsvp {
    display: flex;
  }

  .site-footer {
    padding-bottom: 7rem;
  }
}

/* Closed-envelope concealment and full planner RSVP dashboard */
.real-envelope .letter-preview {
  opacity: 0;
  visibility: hidden;
}

.real-envelope.is-envelope-open .letter-preview {
  opacity: 1;
  visibility: visible;
  transition:
    transform 1.05s cubic-bezier(.16,.78,.18,1) 0.26s,
    box-shadow 0.8s ease,
    opacity 0.22s ease 0.12s;
}

.planner-hero {
  min-height: 24rem;
  padding-top: clamp(3rem, 6vw, 5rem);
  padding-bottom: clamp(2.5rem, 5vw, 4rem);
}

.planner-status,
.dashboard-sync {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex: 0 0 auto;
  padding: 0.8rem 1rem;
  background: rgba(255, 250, 240, 0.9);
  border: 1px solid rgba(236, 211, 154, 0.48);
  border-radius: 999px;
  box-shadow: 0 0.8rem 2rem rgba(47, 24, 44, 0.16);
  color: var(--ink);
  backdrop-filter: blur(12px);
}

.planner-status > span,
.dashboard-sync > span {
  width: 0.7rem;
  height: 0.7rem;
  flex: 0 0 auto;
  background: linear-gradient(135deg, var(--amber), var(--coral));
  border: 2px solid #fff8ea;
  border-radius: 50%;
  box-shadow: 0 0 0 0.22rem rgba(213, 143, 61, 0.2);
}

.planner-status > div,
.dashboard-sync > div {
  display: grid;
  line-height: 1.2;
}

.planner-status strong,
.dashboard-sync strong {
  font-size: 0.78rem;
}

.planner-status small,
.dashboard-sync small {
  margin-top: 0.18rem;
  color: #746b68;
  font-size: 0.72rem;
}

.rsvp-dashboard {
  padding: clamp(3.5rem, 7vw, 6rem) clamp(1rem, 7vw, 7rem) clamp(4rem, 8vw, 7rem);
  background:
    linear-gradient(rgba(255, 248, 235, 0.8), rgba(255, 244, 227, 0.86)),
    url("./assets/sunset-floral-paper-v4.webp") center / cover no-repeat,
    #fff5e6;
}

.dashboard-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
  margin-bottom: 2rem;
}

.dashboard-heading > div:first-child {
  max-width: 48rem;
}

.dashboard-heading h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(2.7rem, 5.5vw, 5rem);
  font-weight: 400;
  letter-spacing: -0.05em;
  line-height: 0.98;
}

.dashboard-heading > div:first-child > p:last-child {
  max-width: 42rem;
  margin: 1rem 0 0;
  color: #655d60;
}

.dashboard-sync {
  background: rgba(255, 250, 240, 0.76);
  border-radius: 1rem;
  box-shadow: 0 0.9rem 2.3rem rgba(92, 44, 67, 0.1);
}

.dashboard-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.85rem;
  margin-bottom: 0.85rem;
}

.dashboard-kpis article,
.dashboard-panel {
  background:
    linear-gradient(rgba(255, 251, 243, 0.9), rgba(255, 247, 235, 0.92)),
    url("./assets/sunset-floral-paper-v4.webp") center / cover;
  border: 1px solid rgba(205, 165, 94, 0.34);
  box-shadow: 0 1.15rem 2.8rem rgba(81, 41, 61, 0.1);
}

.dashboard-kpis article {
  display: grid;
  min-height: 10.5rem;
  padding: 1.25rem;
  border-radius: 1rem;
}

.dashboard-kpis article > span {
  color: #756562;
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.dashboard-kpis article > strong {
  align-self: center;
  color: var(--plum);
  font-family: var(--serif);
  font-size: clamp(2.5rem, 5vw, 3.8rem);
  font-weight: 400;
  line-height: 1;
}

.dashboard-kpis article:nth-child(2) > strong { color: var(--sapphire); }
.dashboard-kpis article:nth-child(3) > strong { color: var(--coral); }
.dashboard-kpis article:nth-child(4) > strong { color: #996c2d; }

.dashboard-kpis article > small {
  color: #746d6a;
  font-size: 0.76rem;
}

.dashboard-detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.88fr) minmax(0, 0.72fr) minmax(24rem, 1.4fr);
  gap: 0.85rem;
}

.dashboard-panel {
  min-width: 0;
  padding: 1.4rem;
  border-radius: 1rem;
}

.panel-heading,
.panel-heading > div,
.attendance-row > div:first-child {
  display: flex;
  align-items: center;
}

.panel-heading {
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.35rem;
}

.panel-heading > div {
  gap: 0.7rem;
}

.panel-heading > div > span {
  display: grid;
  place-items: center;
  width: 2.15rem;
  height: 2.15rem;
  flex: 0 0 auto;
  color: var(--plum);
  border: 1px solid rgba(106, 40, 77, 0.28);
  border-radius: 50%;
  font-size: 0.7rem;
  font-weight: 800;
}

.panel-heading h3 {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.45rem;
  font-weight: 500;
}

.panel-heading > small {
  color: #796f6a;
  font-size: 0.74rem;
}

.attendance-row + .attendance-row {
  margin-top: 1.25rem;
}

.attendance-row > div:first-child {
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.45rem;
}

.attendance-row strong {
  font-size: 0.82rem;
}

.attendance-row span {
  color: var(--plum);
  font-family: var(--serif);
  font-size: 1.05rem;
}

.progress-track {
  height: 0.48rem;
  overflow: hidden;
  background: rgba(106, 40, 77, 0.09);
  border-radius: 999px;
}

.progress-track > span {
  display: block;
  width: var(--progress);
  height: 100%;
  background: linear-gradient(90deg, var(--plum), var(--coral), var(--amber));
  border-radius: inherit;
}

.requirements-panel dl {
  margin: 0;
}

.requirements-panel dl > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.68rem 0;
  border-bottom: 1px solid rgba(44, 34, 48, 0.1);
}

.requirements-panel dl > div:last-child {
  border-bottom: 0;
}

.requirements-panel dt {
  color: #5f585b;
  font-size: 0.78rem;
}

.requirements-panel dd {
  margin: 0;
  color: var(--plum);
  font-family: var(--serif);
  font-size: 1.2rem;
}

.response-table-wrap {
  overflow-x: auto;
}

.response-panel table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.78rem;
  text-align: left;
}

.response-panel th {
  padding: 0 0.65rem 0.7rem;
  color: #806f68;
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.response-panel td {
  padding: 0.8rem 0.65rem;
  border-top: 1px solid rgba(44, 34, 48, 0.1);
  color: #4e464b;
  white-space: nowrap;
}

.response-panel td:first-child {
  color: var(--ink);
  font-weight: 750;
}

.planner-image-count {
  display: flex;
  align-items: baseline;
  gap: 0.35rem;
  width: max-content;
  margin: 1.2rem 0 0;
  padding: 0.55rem 0.8rem;
  color: #665b5e;
  background: rgba(255, 250, 240, 0.66);
  border: 1px solid rgba(205, 165, 94, 0.28);
  border-radius: 999px;
  font-size: 0.76rem;
}

.planner-image-count strong {
  color: var(--plum);
  font-family: var(--serif);
  font-size: 1.25rem;
  font-weight: 500;
}

@media (max-width: 1120px) {
  .dashboard-detail-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .response-panel {
    grid-column: 1 / -1;
  }
}

@media (max-width: 760px) {
  .planner-hero {
    min-height: 0;
  }

  .planner-status {
    width: max-content;
  }

  .dashboard-heading {
    display: grid;
    align-items: start;
  }

  .dashboard-sync {
    width: max-content;
  }

  .dashboard-kpis,
  .dashboard-detail-grid {
    grid-template-columns: 1fr 1fr;
  }

  .attendance-panel,
  .requirements-panel,
  .response-panel {
    grid-column: 1 / -1;
  }
}

@media (max-width: 520px) {
  .dashboard-kpis {
    grid-template-columns: 1fr 1fr;
  }

  .dashboard-kpis article {
    min-height: 8.8rem;
    padding: 1rem;
  }

  .dashboard-kpis article > strong {
    font-size: 2.5rem;
  }

  .dashboard-detail-grid {
    grid-template-columns: 1fr;
  }

  .dashboard-heading h2 {
    font-size: 2.7rem;
  }

  .dashboard-sync,
  .planner-status {
    max-width: 100%;
    border-radius: 0.9rem;
  }
}

@media (max-height: 700px) and (max-width: 640px) {
  .invitation-card {
    min-height: 76svh;
    padding-top: 1.35rem;
    padding-bottom: 2.2rem;
  }

  .monogram {
    width: 4rem;
    height: 4rem;
    margin-bottom: 0.7rem;
  }

  .invitation-card h1 {
    font-size: 2.8rem;
  }

  .wax-seal {
    width: 5.7rem;
    height: 5.7rem;
    margin-top: 1rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Portfolio edition — floral paper, story crest and opening envelope */
body {
  position: relative;
  isolation: isolate;
  background:
    radial-gradient(circle at 8% 12%, rgba(238, 207, 211, 0.34), transparent 24rem),
    radial-gradient(circle at 94% 42%, rgba(191, 210, 184, 0.3), transparent 26rem),
    var(--ivory);
}

body::before,
body::after {
  content: "";
  position: fixed;
  z-index: -1;
  width: min(34rem, 48vw);
  aspect-ratio: 1;
  background: url("./assets/floral-vine.webp") center / contain no-repeat;
  opacity: 0.105;
  pointer-events: none;
}

body::before {
  top: 9vh;
  left: -11rem;
  transform: rotate(-18deg);
}

body::after {
  right: -11rem;
  bottom: 2vh;
  transform: scaleX(-1) rotate(-10deg);
}

.invitation-gate {
  display: block;
  padding: 0;
  overflow-x: hidden;
  overflow-y: auto;
  background:
    radial-gradient(circle at 50% 18%, rgba(236, 198, 120, 0.28), transparent 28%),
    linear-gradient(150deg, rgba(11, 25, 42, 0.95), rgba(83, 22, 51, 0.88)),
    url("./assets/01-niagara-meet.webp") center 38% / cover;
}

.invitation-gate::before {
  background:
    linear-gradient(rgba(14, 23, 37, 0.2), rgba(14, 23, 37, 0.62)),
    url("./assets/floral-vine.webp") left -10rem top -6rem / 34rem no-repeat;
  opacity: 0.9;
  backdrop-filter: blur(5px);
}

.invitation-gate.is-opening {
  overflow: hidden;
}

.envelope-scene {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 100svh;
  padding: max(4.5rem, env(safe-area-inset-top)) 1rem max(3rem, env(safe-area-inset-bottom));
  text-align: center;
}

.real-envelope {
  position: relative;
  width: min(43rem, calc(100vw - 2rem));
  aspect-ratio: 1.56 / 1;
  margin: 0.85rem auto 1.25rem;
  filter: drop-shadow(0 2rem 3rem rgba(0, 0, 0, 0.32));
  perspective: 1200px;
}

.envelope-back,
.letter-preview,
.envelope-flap,
.satin-ribbon {
  position: absolute;
}

.envelope-back {
  inset: 0;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(255,255,255,0.62), transparent 40%),
    repeating-linear-gradient(45deg, rgba(116,70,83,0.025) 0 1px, transparent 1px 7px),
    #f4eadb;
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 0.75rem;
  box-shadow: inset 0 0 0 0.55rem rgba(255, 253, 247, 0.46);
}

.letter-preview {
  z-index: 2;
  right: 7%;
  bottom: 5%;
  left: 7%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 86%;
  padding: 1rem;
  color: var(--ink);
  background:
    linear-gradient(rgba(255,253,247,0.94), rgba(248,241,226,0.94)),
    url("./assets/floral-vine.webp") right -4rem bottom -5rem / 16rem no-repeat;
  border: 1px solid rgba(202, 164, 91, 0.4);
  border-radius: 0.3rem;
  box-shadow: 0 0.7rem 1.6rem rgba(56, 35, 28, 0.12);
  transform: translateY(10%);
  transition: transform 1s cubic-bezier(.2,.72,.2,1) 0.28s;
}

.letter-preview::before {
  content: "";
  position: absolute;
  inset: 0.55rem;
  border: 1px solid rgba(202,164,91,0.32);
  pointer-events: none;
}

.letter-preview img {
  width: clamp(4.2rem, 13vw, 7.4rem);
  margin-bottom: 0.15rem;
}

.letter-preview p {
  margin: 0;
  color: #7b6441;
  font-family: var(--serif);
  font-size: clamp(0.74rem, 2vw, 1.05rem);
  font-style: italic;
}

.letter-preview strong {
  font-family: var(--serif);
  font-size: clamp(1.65rem, 5vw, 3.3rem);
  font-weight: 400;
  line-height: 1;
}

.letter-preview strong i {
  color: var(--gold);
  font-weight: 400;
}

.envelope-flap {
  inset: 0;
  pointer-events: none;
}

.envelope-flap--top {
  z-index: 6;
  bottom: 41%;
  background:
    linear-gradient(150deg, rgba(255,255,255,0.74), transparent 42%),
    repeating-linear-gradient(30deg, rgba(202,164,91,0.04) 0 2px, transparent 2px 9px),
    #eee1cf;
  border-radius: 0.75rem 0.75rem 0 0;
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  transform-origin: 50% 0;
  transition: transform 0.92s cubic-bezier(.2,.72,.18,1), z-index 0s linear 0.45s;
}

.envelope-flap--left {
  z-index: 4;
  background: linear-gradient(128deg, #f3e8d9 0%, #e9dbc7 100%);
  clip-path: polygon(0 0, 53% 54%, 0 100%);
}

.envelope-flap--right {
  z-index: 4;
  background: linear-gradient(230deg, #f7ecdd 0%, #e5d4bd 100%);
  clip-path: polygon(100% 0, 47% 54%, 100% 100%);
}

.envelope-flap--bottom {
  z-index: 5;
  background:
    linear-gradient(10deg, rgba(255,255,255,0.65), transparent 58%),
    #efe1ce;
  clip-path: polygon(0 100%, 50% 43%, 100% 100%);
}

.lace-trim {
  position: absolute;
  right: 3%;
  left: 3%;
  display: block;
  height: 1.25rem;
  background:
    radial-gradient(circle at 0.62rem 0, transparent 0.46rem, rgba(255,253,247,0.92) 0.48rem 0.61rem, transparent 0.63rem) 0 0 / 1.25rem 1.25rem repeat-x;
  filter: drop-shadow(0 1px 0 rgba(93,56,70,0.14));
}

.lace-trim--top {
  top: 0.32rem;
}

.lace-trim--bottom {
  bottom: 0.28rem;
  transform: rotate(180deg);
}

.satin-ribbon {
  z-index: 7;
  display: block;
  background:
    linear-gradient(90deg, rgba(255,255,255,0.18), transparent 24% 72%, rgba(36,4,21,0.3)),
    #6b1f43;
  box-shadow: 0 0.45rem 0.8rem rgba(59, 10, 35, 0.16);
  transition: opacity 0.35s ease, transform 0.6s ease;
}

.satin-ribbon--horizontal {
  top: 44%;
  right: 0;
  left: 0;
  height: clamp(2.1rem, 7vw, 3.8rem);
}

.satin-ribbon--vertical {
  top: 0;
  bottom: 0;
  left: 50%;
  width: clamp(2.1rem, 7vw, 3.8rem);
  transform: translateX(-50%);
}

.ribbon-seal {
  position: absolute;
  z-index: 9;
  top: 50%;
  left: 50%;
  display: grid;
  place-items: center;
  width: clamp(5rem, 15vw, 7.4rem);
  height: clamp(5rem, 15vw, 7.4rem);
  padding: 0;
  color: #f8e9cd;
  background: transparent;
  border: 0;
  cursor: pointer;
  transform: translate(-50%, -50%);
  transition: transform 0.25s ease, opacity 0.35s ease;
}

.ribbon-seal:hover {
  transform: translate(-50%, -50%) scale(1.04);
}

.seal-medallion {
  position: relative;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 62%;
  height: 62%;
  background:
    radial-gradient(circle at 35% 28%, #9a3c60, transparent 30%),
    radial-gradient(circle, #6c1e42 0 61%, #4f1331 62% 72%, #7a264d 73%);
  border-radius: 50%;
  box-shadow: 0 0.65rem 1.3rem rgba(60,9,34,0.3), inset 0 1px 1px rgba(255,255,255,0.25);
  font-family: var(--serif);
  font-size: clamp(1rem, 4vw, 1.65rem);
  letter-spacing: 0.05em;
}

.bow-loop {
  position: absolute;
  top: 10%;
  width: 56%;
  height: 44%;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.2), transparent 54%),
    #7a264f;
  border-radius: 70% 38% 62% 42%;
  box-shadow: 0 0.55rem 0.9rem rgba(56,6,31,0.24);
}

.bow-loop--left {
  left: -2%;
  transform: rotate(-28deg);
}

.bow-loop--right {
  right: -2%;
  transform: scaleX(-1) rotate(-28deg);
}

.real-envelope.is-opening .envelope-flap--top {
  z-index: 1;
  transform: rotateX(178deg);
}

.real-envelope.is-opening .letter-preview {
  z-index: 8;
  transform: translateY(-52%) scale(0.97);
}

.real-envelope.is-opening .satin-ribbon,
.real-envelope.is-opening .ribbon-seal {
  opacity: 0;
  pointer-events: none;
}

.real-envelope.is-opening .satin-ribbon--horizontal {
  transform: scaleX(1.16);
}

.real-envelope.is-opening .satin-ribbon--vertical {
  transform: translateX(-50%) scaleY(1.16);
}

.gate-title {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(2rem, 6vw, 4rem);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.04em;
}

.gate-title i {
  color: var(--gold-light);
  font-weight: 400;
}

.gate-note {
  margin-top: 0.6rem;
  font-size: 0.8rem;
  letter-spacing: 0.06em;
}

.brand-mark {
  width: 3.3rem;
  height: 3.3rem;
  object-fit: contain;
  background: transparent;
  border-radius: 0;
  filter: drop-shadow(0 5px 10px rgba(16,24,39,0.12));
}

.invite-nav {
  position: absolute;
  left: 50%;
  display: flex;
  align-items: center;
  gap: clamp(1rem, 2.4vw, 2.2rem);
  transform: translateX(-50%);
}

.invite-nav a {
  position: relative;
  color: #4d5561;
  font-size: 0.76rem;
  font-weight: 750;
  letter-spacing: 0.08em;
  text-decoration: none;
  text-transform: uppercase;
}

.invite-nav a::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: -0.35rem;
  left: 0;
  height: 1px;
  background: var(--gold);
  transform: scaleX(0);
  transition: transform 0.2s ease;
}

.invite-nav a:hover::after,
.invite-nav a:focus-visible::after {
  transform: scaleX(1);
}

.hero-image {
  background-image: url("./assets/09-lakeside.webp");
  background-position: center 32%;
}

.hero-shade {
  background:
    linear-gradient(90deg, rgba(8, 15, 28, 0.95) 0%, rgba(8, 15, 28, 0.74) 40%, rgba(8, 15, 28, 0.12) 76%),
    linear-gradient(0deg, rgba(8, 15, 28, 0.78) 0%, transparent 46%);
}

.reveal-section,
.gallery-section {
  background:
    linear-gradient(rgba(255,253,247,0.9), rgba(248,243,232,0.92)),
    url("./assets/floral-vine.webp") right -8rem top -8rem / 30rem no-repeat,
    var(--ivory);
}

.scratch-card {
  aspect-ratio: 1.58 / 1;
  background:
    radial-gradient(circle at 50% 44%, rgba(255,255,255,0.96), rgba(248,239,220,0.91) 68%),
    url("./assets/floral-vine.webp") right -4rem bottom -5rem / 18rem no-repeat,
    #f7efdf;
  border: 2px solid rgba(202,164,91,0.58);
  box-shadow: 0 2rem 5rem rgba(51,37,35,0.18), inset 0 0 0 0.65rem rgba(255,255,255,0.48);
}

.scratch-card::before {
  content: "";
  position: absolute;
  z-index: 1;
  inset: 0.85rem;
  border: 1px solid rgba(202,164,91,0.5);
  border-radius: 1.15rem;
  pointer-events: none;
}

.date-reveal {
  background:
    radial-gradient(circle at 50% 30%, rgba(255,255,255,0.72), transparent 45%),
    linear-gradient(rgba(248,243,232,0.85), rgba(248,243,232,0.94)),
    url("./assets/floral-vine.webp") right -4rem bottom -4rem / 17rem no-repeat;
}

.scratch-logo {
  width: clamp(3.4rem, 10vw, 5.4rem);
  margin-bottom: -0.2rem;
}

.story-card--calgary .story-card-image {
  background-image: url("./assets/story-proposal.webp");
  background-position: center 44%;
}

.story-card--udaipur .story-card-image {
  background-color: #efe1c5;
  background-image:
    url("./assets/nr-story-monogram.webp"),
    radial-gradient(circle, rgba(255,255,255,0.98), rgba(239,225,197,0.86));
  background-position: center, center;
  background-size: 68%, cover;
  background-repeat: no-repeat;
}

.events-section {
  position: relative;
  padding: clamp(5rem, 10vw, 9rem) clamp(1rem, 6vw, 6rem);
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(250,247,240,0.96), rgba(247,235,235,0.92)),
    url("./assets/floral-vine.webp") left -8rem bottom -7rem / 30rem no-repeat;
}

.events-section::after {
  content: "NR";
  position: absolute;
  right: -0.02em;
  bottom: -0.2em;
  color: rgba(202,164,91,0.06);
  font-family: var(--serif);
  font-size: clamp(14rem, 32vw, 32rem);
  line-height: 0.8;
  pointer-events: none;
}

.events-section .section-heading {
  margin-bottom: 2.6rem;
}

.event-grid {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.event-card {
  min-height: 30rem;
  overflow: hidden;
  background: rgba(255,253,247,0.88);
  border: 1px solid rgba(16,24,39,0.1);
  border-radius: 1.25rem;
  box-shadow: 0 1.2rem 3.5rem rgba(30,30,40,0.07);
}

.event-card header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  min-height: 9rem;
  padding: 1.5rem;
  color: white;
}

.event-card header span {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.event-card header strong {
  font-family: var(--serif);
  font-size: 2.15rem;
  font-weight: 400;
}

.event-card--welcome header {
  background: linear-gradient(135deg, #69344d, #4c1733);
}

.event-card--ceremony header {
  color: var(--ink);
  background: linear-gradient(135deg, #f2dfcf, #e7c6cc);
}

.event-card--reception header {
  background: linear-gradient(135deg, #17253b, #0d1728);
}

.event-card-body {
  padding: 1.6rem;
}

.event-card time {
  color: #986f2f;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.1em;
}

.event-card h3 {
  margin: 1.1rem 0 0.4rem;
  font-family: var(--serif);
  font-size: clamp(2rem, 3.4vw, 2.8rem);
  font-weight: 400;
  line-height: 1;
}

.event-card p {
  margin: 0;
  color: #6a6c70;
  font-size: 0.9rem;
}

.dress-note {
  display: grid;
  gap: 0.25rem;
  margin-top: 2rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(16,24,39,0.12);
}

.dress-note span {
  color: #8e6940;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.dress-note strong {
  font-family: var(--serif);
  font-size: 1.15rem;
  font-weight: 500;
}

.concept-note {
  position: relative;
  z-index: 2;
  margin: 1.2rem 0 0;
  color: #74716d;
  font-size: 0.76rem;
  text-align: right;
}

.venue-section {
  display: grid;
  grid-template-columns: minmax(0, 0.86fr) minmax(28rem, 1.14fr);
  min-height: 44rem;
  color: var(--ivory);
  background:
    radial-gradient(circle at 12% 0, rgba(202,164,91,0.14), transparent 28rem),
    var(--ink);
}

.venue-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(4rem, 7vw, 7rem);
}

.venue-copy h2 {
  max-width: 9ch;
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(3rem, 6vw, 5.5rem);
  font-weight: 400;
  letter-spacing: -0.05em;
  line-height: 0.94;
}

.venue-copy > p:not(.eyebrow) {
  max-width: 34rem;
  margin: 1.4rem 0 0;
  color: rgba(255,255,255,0.68);
}

.venue-facts {
  margin: 2rem 0;
}

.venue-facts > div {
  display: grid;
  grid-template-columns: minmax(7rem, 0.8fr) 1.2fr;
  gap: 1rem;
  padding: 0.8rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.14);
}

.venue-facts dt {
  color: rgba(255,255,255,0.48);
  font-size: 0.74rem;
}

.venue-facts dd {
  margin: 0;
  font-size: 0.8rem;
  font-weight: 700;
  text-align: right;
}

.venue-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
}

.venue-airport {
  display: inline-flex;
  gap: 0.5rem;
  color: var(--gold-light);
  border-bottom: 1px solid currentColor;
  font-size: 0.78rem;
  font-weight: 750;
  text-decoration: none;
}

.map-frame {
  position: relative;
  min-height: 44rem;
  overflow: hidden;
  background: #d9d6ce;
}

.map-frame iframe {
  width: 100%;
  height: 100%;
  min-height: 44rem;
  border: 0;
  filter: saturate(0.72) sepia(0.1) contrast(0.96);
}

.map-label {
  position: absolute;
  right: 1.5rem;
  bottom: 1.5rem;
  left: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 1rem 1.2rem;
  color: var(--ivory);
  background: rgba(16,24,39,0.88);
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 1rem;
  backdrop-filter: blur(12px);
}

.map-label span {
  display: grid;
  place-items: center;
  width: 2.7rem;
  height: 2.7rem;
  color: var(--gold-light);
  border: 1px solid rgba(202,164,91,0.6);
  border-radius: 50%;
  font-size: 0.7rem;
}

.map-label strong {
  font-family: var(--serif);
  font-size: 1.25rem;
  font-weight: 400;
}

.rsvp-photo {
  background:
    linear-gradient(90deg, transparent 65%, rgba(56,16,35,0.48)),
    url("./assets/05-niagara-together.webp") center 30% / cover;
}

.footer-monogram {
  width: 7rem;
  height: 7rem;
  object-fit: contain;
  border: 0;
  border-radius: 0;
  filter: drop-shadow(0 0.7rem 1.2rem rgba(16,24,39,0.1));
}

.studio-signature {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(16,24,39,0.12);
  text-align: left;
}

.studio-signature > img {
  width: 4.3rem;
  height: 4.3rem;
  object-fit: contain;
}

.studio-signature > div {
  display: grid;
  line-height: 1.35;
}

.studio-signature small {
  color: #77726a;
  font-size: 0.66rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.studio-signature strong {
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.15rem;
  font-weight: 500;
}

.studio-signature a {
  color: #73664e;
  font-size: 0.72rem;
  text-decoration: none;
}

@media (max-width: 920px) {
  .invite-nav {
    display: none;
  }

  .event-grid {
    grid-template-columns: 1fr;
  }

  .event-card {
    display: grid;
    grid-template-columns: minmax(10rem, 0.68fr) minmax(0, 1.32fr);
    min-height: 0;
  }

  .event-card header {
    min-height: 19rem;
    align-items: flex-start;
    flex-direction: column;
  }

  .venue-section {
    grid-template-columns: 1fr;
  }

  .map-frame,
  .map-frame iframe {
    min-height: 34rem;
  }
}

@media (max-width: 640px) {
  body::before,
  body::after {
    width: 24rem;
    opacity: 0.085;
  }

  .envelope-scene {
    justify-content: flex-start;
    padding-top: max(5.5rem, env(safe-area-inset-top));
    padding-bottom: max(3rem, env(safe-area-inset-bottom));
  }

  .real-envelope {
    width: min(35rem, calc(100vw - 1.5rem));
    margin-top: 1.1rem;
  }

  .gate-eyebrow {
    margin: 0;
  }

  .letter-preview img {
    width: 4.3rem;
  }

  .gate-title {
    font-size: 2.55rem;
  }

  .brand-mark {
    width: 2.9rem;
    height: 2.9rem;
  }

  .hero-image {
    background-position: 60% 30%;
  }

  .events-section {
    padding: 4.5rem 1rem;
  }

  .event-card {
    display: block;
  }

  .event-card header {
    min-height: 8.8rem;
    flex-direction: row;
    align-items: flex-end;
  }

  .concept-note {
    text-align: left;
  }

  .scratch-card {
    aspect-ratio: 1.16 / 1;
  }

  .scratch-logo {
    width: 4.2rem;
  }

  .venue-copy {
    padding: 4.5rem 1.2rem;
  }

  .venue-copy h2 {
    font-size: clamp(3rem, 15vw, 4.6rem);
  }

  .venue-actions,
  .venue-actions .button {
    width: 100%;
  }

  .venue-actions {
    align-items: stretch;
  }

  .venue-airport {
    justify-content: space-between;
    padding: 0.75rem 0;
  }

  .map-frame,
  .map-frame iframe {
    min-height: 29rem;
  }

  .studio-signature {
    width: min(100%, 22rem);
  }
}

@media (max-height: 600px) and (max-width: 760px) {
  .envelope-scene {
    min-height: 42rem;
  }
}

/* Royal celebration edition — two-stage opening, jewel palette and planner hub */
:root {
  --emerald: #123f38;
  --sapphire: #163953;
  --ruby: #7a1f45;
  --amethyst: #573763;
  --champagne: #efdca8;
}

[hidden] {
  display: none !important;
}

body {
  background:
    repeating-linear-gradient(112deg, rgba(87, 55, 99, 0.018) 0 1px, transparent 1px 8px),
    radial-gradient(circle at 6% 14%, rgba(240, 197, 205, 0.42), transparent 22rem),
    radial-gradient(circle at 96% 38%, rgba(189, 214, 195, 0.4), transparent 24rem),
    #fbf7ee;
}

body::before,
body::after {
  opacity: 0.17;
  filter: saturate(0.82);
}

.petal-layer {
  position: fixed;
  z-index: 90;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.petal-layer img {
  position: absolute;
  top: -8vh;
  left: var(--petal-left);
  width: var(--petal-size);
  height: var(--petal-size);
  object-fit: contain;
  opacity: 0;
  filter: drop-shadow(0 4px 5px rgba(71, 11, 35, 0.16));
}

.petal-layer.is-falling img {
  animation: petalFall var(--petal-duration) cubic-bezier(.26,.58,.35,1) var(--petal-delay) forwards;
}

@keyframes petalFall {
  0% { opacity: 0; transform: translate3d(0, -8vh, 0) rotate(0) rotateY(0); }
  8% { opacity: 0.94; }
  48% { transform: translate3d(var(--petal-drift), 48vh, 0) rotate(calc(var(--petal-spin) * 0.48)) rotateY(150deg); }
  100% { opacity: 0.22; transform: translate3d(calc(var(--petal-drift) * -0.35), 112vh, 0) rotate(var(--petal-spin)) rotateY(360deg); }
}

.invitation-gate {
  background:
    radial-gradient(circle at 50% 20%, rgba(239, 210, 142, 0.3), transparent 28%),
    linear-gradient(145deg, rgba(12, 36, 42, 0.96), rgba(82, 27, 63, 0.93)),
    url("./assets/hero-seated-couple.webp") center 48% / cover;
}

.invitation-gate::before {
  background:
    linear-gradient(rgba(9, 26, 33, 0.32), rgba(44, 14, 38, 0.7)),
    url("./assets/floral-vine.webp") left -7rem top -5rem / 30rem no-repeat,
    url("./assets/floral-vine.webp") right -8rem bottom -7rem / 32rem no-repeat;
  opacity: 0.94;
  backdrop-filter: blur(8px);
}

.envelope-scene {
  justify-content: center;
  min-height: 100svh;
  padding-top: max(5.5rem, env(safe-area-inset-top));
  padding-bottom: max(4rem, env(safe-area-inset-bottom));
}

.real-envelope {
  margin-top: 1.4rem;
  margin-bottom: 1.6rem;
}

.letter-preview {
  z-index: 2;
  right: 8%;
  bottom: 4%;
  left: 8%;
  display: block;
  height: 92%;
  padding: 0.55rem;
  overflow: visible;
  background:
    repeating-linear-gradient(45deg, rgba(202,164,91,0.035) 0 1px, transparent 1px 7px),
    #fffaf0;
  border: 1px solid rgba(239, 220, 168, 0.78);
  border-radius: 0.7rem;
  box-shadow: 0 1.2rem 2.8rem rgba(26, 12, 22, 0.28);
  transform: translateY(12%) scale(0.94);
  transition: transform 1.05s cubic-bezier(.16,.78,.18,1) 0.26s, box-shadow 0.8s ease;
}

.letter-preview::before {
  inset: 0.82rem;
  z-index: 3;
  border-color: rgba(239, 220, 168, 0.62);
  border-radius: 0.5rem;
}

.venue-card-image {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: 0.45rem;
}

.venue-card-image > img {
  width: 100%;
  height: 100%;
  margin: 0;
  object-fit: cover;
  object-position: center;
  transform: scale(1.015);
  transition: transform 7s ease-out;
}

.real-envelope.is-envelope-open .venue-card-image > img {
  transform: scale(1.09);
}

.venue-card-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(0deg, rgba(12, 27, 38, 0.94) 0%, rgba(12, 27, 38, 0.18) 63%, rgba(12, 27, 38, 0.03)),
    radial-gradient(circle at 50% 86%, rgba(202, 164, 91, 0.2), transparent 38%);
}

.venue-card-copy {
  position: absolute;
  z-index: 2;
  right: 1rem;
  bottom: 2.6rem;
  left: 1rem;
  color: #fffaf0;
  text-align: center;
}

.venue-card-copy .venue-card-mark {
  width: clamp(3rem, 8vw, 4.8rem);
  margin: 0 auto 0.25rem;
  filter: drop-shadow(0 8px 16px rgba(0,0,0,0.28));
}

.venue-card-copy p {
  margin: 0;
  color: var(--champagne);
  font-family: var(--sans);
  font-size: clamp(0.55rem, 1.45vw, 0.76rem);
  font-style: normal;
  font-weight: 750;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.venue-card-copy strong {
  display: block;
  margin: 0.15rem 0;
  color: #fffdf7;
  font-size: clamp(1.5rem, 4vw, 2.6rem);
  text-shadow: 0 7px 20px rgba(0,0,0,0.38);
}

.venue-card-copy span {
  display: block;
  color: rgba(255,255,255,0.84);
  font-size: clamp(0.58rem, 1.35vw, 0.74rem);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.card-ribbon {
  position: absolute;
  z-index: 5;
  right: -0.7rem;
  bottom: 1.35rem;
  left: -0.7rem;
  height: 1.55rem;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.22), transparent 42% 70%, rgba(42,5,27,0.25)),
    #7a1f45;
  box-shadow: 0 0.35rem 0.8rem rgba(41, 7, 28, 0.28);
  transition: transform 0.8s cubic-bezier(.2,.72,.2,1), opacity 0.5s ease;
}

.venue-bow {
  position: absolute;
  z-index: 7;
  bottom: -0.25rem;
  left: 50%;
  width: 6rem;
  height: 4rem;
  padding: 0;
  background: transparent;
  border: 0;
  cursor: pointer;
  transform: translateX(-50%);
  transition: transform 0.25s ease, opacity 0.45s ease;
}

.venue-bow:disabled {
  cursor: default;
}

.venue-bow:not(:disabled):hover {
  transform: translateX(-50%) scale(1.06);
}

.venue-bow-loop {
  position: absolute;
  top: 0.55rem;
  width: 3rem;
  height: 2.05rem;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.24), transparent 52%),
    #8b2850;
  border-radius: 72% 34% 65% 38%;
  box-shadow: 0 0.45rem 0.8rem rgba(47, 4, 27, 0.32);
  transition: transform 0.85s cubic-bezier(.2,.72,.2,1), opacity 0.5s ease;
}

.venue-bow-loop--left {
  left: 0.05rem;
  transform: rotate(-26deg);
}

.venue-bow-loop--right {
  right: 0.05rem;
  transform: scaleX(-1) rotate(-26deg);
}

.venue-bow-knot {
  position: absolute;
  z-index: 2;
  top: 1.15rem;
  left: 50%;
  width: 1.5rem;
  height: 1.5rem;
  background: radial-gradient(circle at 34% 28%, #bd5479, #761a42 65%, #57112f);
  border-radius: 50%;
  box-shadow: 0 0.45rem 0.8rem rgba(47, 4, 27, 0.35);
  transform: translateX(-50%);
  transition: transform 0.7s ease, opacity 0.5s ease;
}

.venue-bow-note {
  position: absolute;
  z-index: 8;
  top: calc(100% + 0.75rem);
  right: 0;
  left: 0;
  color: rgba(255,255,255,0.88);
  font-size: 0.67rem;
  font-weight: 750;
  letter-spacing: 0.12em;
  text-align: center;
  text-transform: uppercase;
  opacity: 0;
  transform: translateY(0.4rem);
  transition: opacity 0.5s ease 1.1s, transform 0.5s ease 1.1s;
}

.ribbon-seal {
  width: clamp(4.4rem, 13vw, 6.3rem);
  height: clamp(4.4rem, 13vw, 6.3rem);
}

.seal-medallion {
  width: 76%;
  height: 76%;
  border: 2px solid rgba(246, 211, 136, 0.45);
  box-shadow:
    0 0.75rem 1.5rem rgba(60,9,34,0.38),
    inset 0 0 0 0.28rem rgba(75,9,40,0.2),
    inset 0 1px 1px rgba(255,255,255,0.28);
}

.real-envelope.is-envelope-open .envelope-flap--top {
  z-index: 1;
  transform: rotateX(178deg) translateY(-3%);
}

.real-envelope.is-envelope-open .envelope-flap--left {
  transform-origin: 0 50%;
  transform: rotateY(-58deg) translateX(-18%);
  transition: transform 0.9s cubic-bezier(.18,.72,.2,1) 0.12s;
}

.real-envelope.is-envelope-open .envelope-flap--right {
  transform-origin: 100% 50%;
  transform: rotateY(58deg) translateX(18%);
  transition: transform 0.9s cubic-bezier(.18,.72,.2,1) 0.12s;
}

.real-envelope.is-envelope-open .envelope-flap--bottom {
  transform-origin: 50% 100%;
  transform: rotateX(-72deg) translateY(18%);
  transition: transform 0.9s cubic-bezier(.18,.72,.2,1) 0.2s;
}

.real-envelope.is-envelope-open .letter-preview {
  z-index: 10;
  transform: translateY(-48%) scale(1.03);
  box-shadow: 0 2.2rem 4rem rgba(17, 7, 15, 0.38);
}

.real-envelope.is-envelope-open .satin-ribbon,
.real-envelope.is-envelope-open .ribbon-seal {
  opacity: 0;
  pointer-events: none;
}

.real-envelope.is-envelope-open .satin-ribbon--horizontal {
  transform: scaleX(0.35);
}

.real-envelope.is-envelope-open .satin-ribbon--vertical {
  transform: translateX(-50%) scaleY(0.25);
}

.real-envelope.is-envelope-open .venue-bow-note {
  opacity: 1;
  transform: translateY(0);
}

.letter-preview.is-untying .card-ribbon--left {
  opacity: 0;
  transform: translateX(-75%) rotate(-5deg);
}

.letter-preview.is-untying .card-ribbon--right {
  opacity: 0;
  transform: translateX(75%) rotate(5deg);
}

.letter-preview.is-untying .venue-bow-loop--left {
  opacity: 0;
  transform: translate(-4.5rem, 1rem) rotate(-72deg) scale(0.75);
}

.letter-preview.is-untying .venue-bow-loop--right {
  opacity: 0;
  transform: translate(4.5rem, 1rem) scaleX(-1) rotate(-72deg) scale(0.75);
}

.letter-preview.is-untying .venue-bow-knot,
.letter-preview.is-untying .venue-bow-note {
  opacity: 0;
  transform: translateX(-50%) scale(0.35);
}

.invitation-gate.is-opening .letter-preview {
  transform: translateY(-48%) scale(1.09);
}

.invitation-gate.has-open-envelope .gate-eyebrow,
.invitation-gate.has-open-envelope .gate-title {
  opacity: 0.28;
  transition: opacity 0.5s ease;
}

.view-switch {
  display: flex;
  align-items: center;
  gap: 0.15rem;
  padding: 0.2rem;
  background: rgba(255,255,255,0.72);
  border: 1px solid rgba(16,24,39,0.12);
  border-radius: 999px;
  box-shadow: 0 8px 22px rgba(16,24,39,0.07);
}

.view-button {
  min-height: 2.25rem;
  padding: 0.48rem 0.85rem;
  color: #61666a;
  background: transparent;
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  font-size: 0.72rem;
  font-weight: 780;
}

.view-button.is-active {
  color: #fffaf0;
  background: linear-gradient(135deg, var(--sapphire), var(--emerald));
  box-shadow: 0 7px 14px rgba(18,63,56,0.2);
}

.music-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  min-height: 2.5rem;
  padding: 0.5rem 0.75rem;
  color: var(--ruby);
  background: rgba(255,255,255,0.55);
  border: 1px solid rgba(122,31,69,0.16);
  border-radius: 999px;
  cursor: pointer;
  font-size: 0.72rem;
  font-weight: 750;
}

.music-toggle > span:first-child {
  font-size: 1rem;
}

.music-toggle.is-muted {
  color: #74716d;
  opacity: 0.72;
}

.invite-nav {
  display: none;
}

.header-actions {
  flex: 1;
  justify-content: flex-end;
}

.hero-image {
  background-image: url("./assets/hero-seated-couple.webp");
  background-position: center 48%;
}

.hero-shade {
  background:
    linear-gradient(90deg, rgba(8,24,32,0.96) 0%, rgba(26,38,54,0.72) 42%, rgba(65,22,52,0.12) 77%),
    linear-gradient(0deg, rgba(61,17,46,0.82) 0%, transparent 48%);
}

.reveal-section,
.gallery-section {
  background:
    linear-gradient(rgba(255,252,246,0.86), rgba(249,241,231,0.9)),
    url("./assets/floral-vine.webp") right -5rem top -6rem / 27rem no-repeat,
    repeating-linear-gradient(110deg, rgba(87,55,99,0.035) 0 1px, transparent 1px 7px),
    #fbf7ee;
}

.scratch-wrap {
  width: min(34rem, 94vw);
}

.scratch-card {
  aspect-ratio: 1.52 / 1;
  border-color: rgba(202,164,91,0.74);
  box-shadow: 0 1.5rem 3.8rem rgba(58, 28, 47, 0.17), inset 0 0 0 0.55rem rgba(255,255,255,0.48);
}

.story-section {
  background:
    linear-gradient(135deg, rgba(14,58,49,0.96), rgba(29,47,75,0.96) 52%, rgba(78,25,63,0.96)),
    url("./assets/hero-seated-couple.webp") center 48% / cover fixed;
}

.story-card {
  border-color: rgba(239,220,168,0.34);
  box-shadow: 0 1.5rem 3.5rem rgba(0,0,0,0.18);
}

.events-section {
  background:
    linear-gradient(135deg, rgba(255,251,243,0.93), rgba(246,228,232,0.9)),
    url("./assets/floral-vine.webp") left -5rem bottom -5rem / 26rem no-repeat,
    #fbf7ee;
}

.event-card--welcome header {
  background: linear-gradient(135deg, #78234a, #4f183c 58%, #2c3657);
}

.event-card--ceremony header {
  color: #17372f;
  background: linear-gradient(135deg, #f4e9cf, #e9c6ce 64%, #cbdac8);
}

.event-card--reception header {
  background: linear-gradient(135deg, #123f38, #173752 52%, #4f244f);
}

.venue-section {
  background:
    radial-gradient(circle at 12% 0, rgba(239,220,168,0.2), transparent 28rem),
    linear-gradient(145deg, #102f2d, #17344d 56%, #4b193c);
}

.planner-view {
  min-height: calc(100svh - 4.75rem);
  background:
    linear-gradient(rgba(251,247,238,0.9), rgba(251,247,238,0.94)),
    url("./assets/floral-vine.webp") right -8rem top 3rem / 34rem no-repeat,
    repeating-linear-gradient(108deg, rgba(22,57,83,0.028) 0 1px, transparent 1px 8px),
    #fbf7ee;
}

.planner-hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
  padding: clamp(4rem, 8vw, 7rem) clamp(1.25rem, 7vw, 7rem) 3rem;
  color: #fffaf0;
  background:
    linear-gradient(90deg, rgba(11,40,37,0.97), rgba(23,55,82,0.92) 58%, rgba(89,28,67,0.88)),
    url("./assets/leela-palace-udaipur.webp") center 52% / cover;
}

.planner-hero > div {
  max-width: 52rem;
}

.planner-hero h2,
.planner-upload-section h2,
.planner-next-step h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(2.6rem, 6vw, 5.4rem);
  font-weight: 400;
  letter-spacing: -0.05em;
  line-height: 0.95;
}

.planner-hero > div > p:last-child {
  max-width: 40rem;
  margin: 1.3rem 0 0;
  color: rgba(255,255,255,0.78);
}

.planner-hero .button {
  flex: 0 0 auto;
}

.planner-dashboard {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.9rem;
  padding: 1rem clamp(1rem, 7vw, 7rem) clamp(3rem, 7vw, 5rem);
  background: linear-gradient(180deg, rgba(15,47,45,0.98), rgba(15,47,45,0) 55%);
}

.planner-dashboard article {
  display: grid;
  min-height: 10.5rem;
  padding: 1.35rem;
  background: rgba(255,252,246,0.94);
  border: 1px solid rgba(202,164,91,0.28);
  border-radius: 1.1rem;
  box-shadow: 0 1rem 2.4rem rgba(20,35,46,0.09);
}

.planner-dashboard article > span,
.planner-dashboard article > small {
  color: #6f6b65;
  font-size: 0.72rem;
}

.planner-dashboard article > span {
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.planner-dashboard article > strong {
  align-self: center;
  color: var(--ruby);
  font-family: var(--serif);
  font-size: 2.7rem;
  font-weight: 400;
}

.planner-dashboard article:nth-child(2) > strong { color: var(--sapphire); }
.planner-dashboard article:nth-child(3) > strong { color: var(--amethyst); }
.planner-dashboard article:nth-child(4) > strong { color: var(--emerald); }

.planner-upload-section {
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(26rem, 1.18fr);
  gap: clamp(2rem, 6vw, 6rem);
  padding: clamp(4rem, 8vw, 7rem) clamp(1.25rem, 7vw, 7rem);
}

.planner-upload-copy > p:not(.eyebrow) {
  max-width: 36rem;
  margin: 1.4rem 0 0;
  color: #5f625f;
}

.planner-privacy {
  padding-left: 1rem;
  border-left: 2px solid var(--gold);
  font-size: 0.8rem;
}

.planner-uploader {
  padding: clamp(1rem, 3vw, 1.5rem);
  background: rgba(255,255,255,0.72);
  border: 1px solid rgba(202,164,91,0.34);
  border-radius: 1.4rem;
  box-shadow: 0 1.5rem 4rem rgba(43,35,43,0.1);
}

.upload-dropzone {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 13rem;
  padding: 1.5rem;
  color: var(--ink);
  background:
    linear-gradient(rgba(255,252,246,0.86), rgba(255,252,246,0.86)),
    url("./assets/floral-vine.webp") center / 20rem no-repeat;
  border: 1.5px dashed rgba(122,31,69,0.4);
  border-radius: 1rem;
  cursor: pointer;
  text-align: center;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.upload-dropzone:hover {
  border-color: var(--ruby);
  transform: translateY(-2px);
}

.upload-icon {
  display: grid;
  place-items: center;
  width: 3.2rem;
  height: 3.2rem;
  margin-bottom: 0.6rem;
  color: var(--ruby);
  background: rgba(240,215,221,0.62);
  border-radius: 50%;
  font-size: 1.5rem;
}

.upload-dropzone strong {
  font-family: var(--serif);
  font-size: 1.35rem;
  font-weight: 500;
}

.upload-dropzone small {
  margin-top: 0.25rem;
  color: #746f69;
}

.upload-feedback {
  min-height: 1.6rem;
  margin: 0.85rem 0;
  color: #716b63;
  font-size: 0.78rem;
}

.upload-preview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.7rem;
}

.upload-preview {
  display: grid;
  grid-template-columns: 4.2rem minmax(0, 1fr);
  gap: 0.7rem;
  align-items: center;
  min-width: 0;
  padding: 0.5rem;
  background: #f7f0e4;
  border-radius: 0.75rem;
}

.upload-preview img {
  width: 4.2rem;
  height: 4.2rem;
  object-fit: cover;
  border-radius: 0.55rem;
}

.upload-preview > div {
  display: grid;
  min-width: 0;
}

.upload-preview strong {
  overflow: hidden;
  font-size: 0.72rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.upload-preview button,
.clear-uploads {
  width: max-content;
  padding: 0.35rem 0;
  color: var(--ruby);
  background: transparent;
  border: 0;
  cursor: pointer;
  font-size: 0.72rem;
  font-weight: 750;
}

.clear-uploads {
  margin-top: 1rem;
  border-bottom: 1px solid currentColor;
}

.planner-next-step {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 4vw, 3rem);
  padding: clamp(3rem, 6vw, 5rem) clamp(1.25rem, 7vw, 7rem);
  color: #fffaf0;
  background: linear-gradient(120deg, var(--ruby), var(--amethyst) 52%, var(--sapphire));
}

.planner-next-step > img {
  width: clamp(4rem, 8vw, 7rem);
  flex: 0 0 auto;
  filter: drop-shadow(0 10px 20px rgba(0,0,0,0.22));
}

.planner-next-step > div {
  flex: 1;
}

.planner-next-step h2 {
  max-width: 16ch;
  font-size: clamp(2rem, 4vw, 3.8rem);
}

.site-shell.is-planner .site-footer,
.site-shell.is-planner .mobile-rsvp,
.site-shell.is-planner .site-header a[data-rsvp-link] {
  display: none;
}

@media (max-width: 1060px) {
  .language-switch {
    display: none;
  }

  .planner-dashboard {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .site-header {
    flex-wrap: wrap;
    gap: 0.45rem;
    padding: 0.55rem 0.75rem;
  }

  .brand-copy {
    display: none;
  }

  .brand-mark {
    width: 2.65rem;
    height: 2.65rem;
  }

  .header-actions {
    gap: 0.35rem;
  }

  .view-button {
    min-height: 2.1rem;
    padding: 0.42rem 0.65rem;
    font-size: 0.66rem;
  }

  .music-toggle {
    width: 2.45rem;
    padding: 0;
    justify-content: center;
  }

  .music-toggle > span:last-child {
    display: none;
  }

  .header-actions .button--small {
    display: none;
  }

  .hero-image {
    background-position: center 52%;
  }

  .scratch-wrap {
    width: min(28rem, 94vw);
  }

  .scratch-card {
    aspect-ratio: 1.35 / 1;
  }

  .planner-hero {
    display: grid;
    align-items: start;
    padding-top: 4rem;
  }

  .planner-hero .button {
    width: max-content;
  }

  .planner-upload-section {
    grid-template-columns: 1fr;
  }

  .planner-next-step {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .planner-next-step .button {
    width: 100%;
  }
}

@media (max-width: 640px) {
  body::before,
  body::after {
    width: 22rem;
    opacity: 0.15;
  }

  .envelope-scene {
    justify-content: center;
    min-height: 100svh;
    padding: 5.3rem 0.75rem 4rem;
  }

  .real-envelope {
    width: min(36rem, calc(100vw - 1.5rem));
    margin-top: 1rem;
    margin-bottom: 1.2rem;
  }

  .real-envelope.is-envelope-open .letter-preview,
  .invitation-gate.is-opening .letter-preview {
    transform: translateY(-44%) scale(1.04);
  }

  .venue-card-copy {
    bottom: 2.15rem;
  }

  .venue-card-copy .venue-card-mark {
    width: 3.15rem;
  }

  .venue-bow {
    transform: translateX(-50%) scale(0.82);
  }

  .venue-bow:not(:disabled):hover {
    transform: translateX(-50%) scale(0.86);
  }

  .venue-bow-note {
    top: calc(100% + 0.4rem);
    font-size: 0.58rem;
  }

  .gate-title {
    font-size: 2.35rem;
  }

  .gate-note {
    max-width: 21rem;
    padding: 0 1rem;
  }

  .scratch-card {
    aspect-ratio: 1.25 / 1;
  }

  .planner-dashboard {
    grid-template-columns: 1fr 1fr;
    padding-right: 0.8rem;
    padding-left: 0.8rem;
  }

  .planner-dashboard article {
    min-height: 8.8rem;
    padding: 1rem;
  }

  .planner-dashboard article > strong {
    font-size: 2.15rem;
  }

  .upload-preview-grid {
    grid-template-columns: 1fr;
  }
}

/* Sunset stationery edition — embossed envelope and floral paper throughout */
:root {
  --ink: #2c2230;
  --ink-soft: #493343;
  --plum: #6a284d;
  --plum-deep: #35182f;
  --ruby: #872f55;
  --amethyst: #654064;
  --sapphire: #495b78;
  --emerald: #5f6d58;
  --coral: #e47f68;
  --peach: #efaa78;
  --amber: #d58f3d;
  --gold: #cda55e;
  --gold-light: #ecd39a;
  --champagne: #f1dbad;
  --ivory: #fff5e6;
  --paper: #fffaf0;
  --rose: #c56578;
}

html {
  background: #35182f;
}

body {
  color: var(--ink);
  background:
    linear-gradient(rgba(255, 247, 232, 0.78), rgba(255, 243, 226, 0.78)),
    url("./assets/sunset-floral-paper-v4.webp") center top / 112rem auto repeat-y,
    #fff5e6;
}

body::before {
  top: 0;
  left: 0;
  width: 100%;
  height: 100svh;
  background: url("./assets/sunset-floral-paper-v4.webp") center / cover no-repeat;
  opacity: 0.18;
  transform: none;
}

body::after {
  display: none;
}

.invitation-gate {
  background:
    radial-gradient(circle at 15% 18%, rgba(239, 170, 92, 0.78), transparent 31%),
    radial-gradient(circle at 82% 78%, rgba(226, 110, 103, 0.52), transparent 35%),
    linear-gradient(140deg, #5d3e58 0%, #6b2e50 46%, #2f2743 100%);
}

.invitation-gate::before {
  background:
    linear-gradient(145deg, rgba(54, 27, 49, 0.14), rgba(38, 24, 49, 0.56)),
    url("./assets/sunset-floral-paper-v4.webp") center / cover no-repeat;
  background-blend-mode: multiply, soft-light;
  opacity: 0.68;
  backdrop-filter: none;
}

.gate-language {
  background: rgba(255, 247, 232, 0.86);
  border: 1px solid rgba(236, 211, 154, 0.56);
  box-shadow: 0 0.8rem 2rem rgba(47, 23, 43, 0.18);
  backdrop-filter: blur(12px);
}

.gate-language .lang-button,
.gate-language > span {
  color: var(--plum);
}

.gate-eyebrow {
  color: rgba(255, 248, 236, 0.86);
  text-shadow: 0 2px 16px rgba(43, 19, 37, 0.35);
}

.real-envelope {
  aspect-ratio: 1.5 / 1;
  filter: drop-shadow(0 2.2rem 3.5rem rgba(43, 17, 37, 0.38));
}

.envelope-back {
  background:
    linear-gradient(rgba(255, 250, 240, 0.34), rgba(255, 250, 240, 0.34)),
    url("./assets/embossed-envelope-front-v4.webp") center / 100% 100% no-repeat;
  border-color: rgba(255, 255, 255, 0.86);
  box-shadow:
    inset 0 0 0 0.55rem rgba(255, 253, 247, 0.56),
    0 0.7rem 1.8rem rgba(54, 25, 45, 0.14);
}

.envelope-flap--top {
  background: url("./assets/embossed-envelope-front-v4.webp") center top / 100% 169.5% no-repeat;
}

.envelope-flap--left,
.envelope-flap--right,
.envelope-flap--bottom {
  background: url("./assets/embossed-envelope-front-v4.webp") center / 100% 100% no-repeat;
}

.lace-trim {
  display: none;
}

.envelope-front-face {
  position: absolute;
  z-index: 8;
  inset: 0;
  overflow: hidden;
  background: url("./assets/embossed-envelope-front-v4.webp") center / 100% 100% no-repeat;
  border: 1px solid rgba(255, 255, 255, 0.88);
  border-radius: 0.72rem;
  box-shadow:
    inset 0 0 0 1px rgba(205, 165, 94, 0.18),
    inset 0 0 2.4rem rgba(151, 112, 63, 0.06);
  pointer-events: none;
  transform: translateZ(1px);
  transition: opacity 0.28s ease, transform 0.5s cubic-bezier(.2,.72,.2,1);
}

.real-envelope.is-envelope-open .envelope-front-face {
  opacity: 0;
  transform: translateY(2%) scale(0.985);
}

.satin-ribbon {
  display: none;
}

.ribbon-seal {
  z-index: 10;
  width: clamp(5rem, 13vw, 6.6rem);
  height: clamp(5rem, 13vw, 6.6rem);
  color: #a97b32;
  filter: drop-shadow(0 0.75rem 0.85rem rgba(71, 43, 40, 0.2));
}

.seal-medallion {
  width: 88%;
  height: 88%;
  color: #a67a34;
  background:
    radial-gradient(circle at 34% 27%, rgba(255,255,255,0.98), transparent 27%),
    radial-gradient(circle at 50% 56%, #fffdf8 0 55%, #f0e5d3 70%, #fffaf0 78%);
  border: 1px solid rgba(209, 175, 110, 0.62);
  border-radius: 48% 52% 47% 53% / 53% 47% 54% 46%;
  box-shadow:
    0 0.72rem 1.4rem rgba(67, 37, 48, 0.22),
    inset 0 0 0 0.36rem rgba(255,255,255,0.58),
    inset 0 0 0 0.48rem rgba(203,163,88,0.18),
    inset 0 -0.4rem 0.8rem rgba(157,109,53,0.12);
  font-size: clamp(1.2rem, 4vw, 1.85rem);
  font-style: italic;
  letter-spacing: -0.06em;
  text-shadow: 0 1px 0 rgba(255,255,255,0.82);
}

.seal-medallion::after {
  content: "";
  position: absolute;
  inset: 0.56rem;
  border: 1px solid rgba(200, 160, 87, 0.54);
  border-radius: 50%;
  pointer-events: none;
}

.gate-title {
  color: #fff8eb;
  text-shadow: 0 0.7rem 1.8rem rgba(46, 20, 40, 0.28);
}

.gate-title i,
.gate-note {
  color: var(--champagne);
}

.site-header {
  background:
    linear-gradient(rgba(255, 250, 240, 0.91), rgba(255, 248, 236, 0.91)),
    url("./assets/sunset-floral-paper-v4.webp") center 28% / cover;
  border-bottom-color: rgba(205, 165, 94, 0.34);
  box-shadow: 0 0.65rem 2.1rem rgba(80, 38, 61, 0.08);
  backdrop-filter: blur(18px);
}

.view-switch,
.music-toggle {
  background: rgba(255, 250, 240, 0.76);
  border-color: rgba(106, 40, 77, 0.16);
}

.view-button.is-active {
  color: #fffaf0;
  background: linear-gradient(135deg, var(--plum), var(--coral));
  box-shadow: 0 7px 16px rgba(106, 40, 77, 0.22);
}

.hero-shade {
  background:
    linear-gradient(90deg, rgba(47, 32, 58, 0.96) 0%, rgba(91, 43, 74, 0.74) 43%, rgba(226, 114, 94, 0.13) 78%),
    linear-gradient(0deg, rgba(105, 40, 77, 0.82) 0%, rgba(214, 142, 61, 0.08) 52%);
}

.reveal-section,
.gallery-section,
.events-section {
  background:
    linear-gradient(rgba(255, 248, 235, 0.79), rgba(255, 246, 231, 0.83)),
    url("./assets/sunset-floral-paper-v4.webp") center / cover no-repeat,
    #fff5e6;
}

.scratch-card {
  background:
    linear-gradient(rgba(255, 250, 240, 0.74), rgba(255, 246, 232, 0.78)),
    url("./assets/sunset-floral-paper-v4.webp") center / cover;
  border-color: rgba(205, 165, 94, 0.78);
  box-shadow:
    0 1.5rem 3.8rem rgba(106, 40, 77, 0.16),
    inset 0 0 0 0.55rem rgba(255,255,255,0.5);
}

.date-reveal {
  background: rgba(255, 247, 233, 0.72);
}

.story-section {
  background:
    linear-gradient(135deg, rgba(52, 30, 53, 0.94), rgba(84, 42, 69, 0.92) 50%, rgba(67, 75, 105, 0.94)),
    url("./assets/sunset-floral-paper-v4.webp") center / cover no-repeat;
  background-blend-mode: multiply, normal;
}

.story-card {
  background: rgba(255, 247, 234, 0.07);
  border-color: rgba(236, 211, 154, 0.32);
  box-shadow: 0 1.4rem 3rem rgba(28, 17, 34, 0.2);
}

.event-card {
  background:
    linear-gradient(rgba(255, 250, 242, 0.88), rgba(255, 247, 235, 0.9)),
    url("./assets/sunset-floral-paper-v4.webp") center / cover;
  border-color: rgba(205, 165, 94, 0.32);
  box-shadow: 0 1.2rem 3rem rgba(92, 44, 67, 0.12);
}

.event-card--welcome header {
  background: linear-gradient(135deg, #d99041, #df725f 56%, #71304f);
}

.event-card--ceremony header {
  color: #4e2b3d;
  background: linear-gradient(135deg, #f6ddb2, #efa684 58%, #c98173);
}

.event-card--reception header {
  background: linear-gradient(135deg, #4a5774, #632d52 55%, #a24355);
}

.gallery-card {
  box-shadow: 0 1rem 2.4rem rgba(75, 40, 60, 0.16);
}

.gallery-arrow:hover {
  color: #fff8ea;
  background: linear-gradient(135deg, var(--plum), var(--coral));
}

.venue-section {
  background:
    linear-gradient(145deg, rgba(47, 35, 61, 0.96), rgba(93, 42, 73, 0.94) 54%, rgba(151, 68, 65, 0.9)),
    url("./assets/sunset-floral-paper-v4.webp") center / cover no-repeat;
  background-blend-mode: multiply, normal;
}

.rsvp-section {
  background: linear-gradient(135deg, #3c2946, #6a284d 54%, #a04852);
}

.rsvp-panel {
  background:
    linear-gradient(135deg, rgba(53, 24, 47, 0.88), rgba(106, 40, 77, 0.87) 58%, rgba(166, 72, 76, 0.85)),
    url("./assets/sunset-floral-paper-v4.webp") center / cover no-repeat;
  background-blend-mode: multiply, normal;
}

.site-footer {
  background:
    linear-gradient(rgba(255, 248, 235, 0.76), rgba(255, 245, 228, 0.8)),
    url("./assets/sunset-floral-paper-v4.webp") center / cover no-repeat;
}

.button--gold,
.mobile-rsvp {
  color: #3b2333;
  background: linear-gradient(135deg, #f0d69c, #d7a84e 58%, #e99a69);
  box-shadow: 0 0.85rem 2rem rgba(90, 40, 61, 0.2);
}

.planner-view {
  background:
    linear-gradient(rgba(255, 248, 235, 0.82), rgba(255, 244, 227, 0.86)),
    url("./assets/sunset-floral-paper-v4.webp") center top / 112rem auto repeat-y,
    #fff5e6;
}

.planner-hero {
  background:
    linear-gradient(90deg, rgba(49, 33, 60, 0.94), rgba(105, 44, 79, 0.88) 57%, rgba(213, 112, 87, 0.68)),
    url("./assets/leela-palace-udaipur.webp") center 52% / cover;
}

.planner-dashboard {
  background:
    linear-gradient(180deg, rgba(66, 37, 59, 0.96), rgba(66, 37, 59, 0) 62%),
    url("./assets/sunset-floral-paper-v4.webp") center top / cover no-repeat;
}

.planner-dashboard article,
.planner-uploader {
  background:
    linear-gradient(rgba(255, 250, 241, 0.88), rgba(255, 247, 234, 0.9)),
    url("./assets/sunset-floral-paper-v4.webp") center / cover;
  border-color: rgba(205, 165, 94, 0.36);
}

.upload-dropzone {
  background:
    linear-gradient(rgba(255, 249, 237, 0.78), rgba(255, 246, 231, 0.82)),
    url("./assets/sunset-floral-paper-v4.webp") center / cover;
}

.planner-next-step {
  background:
    linear-gradient(120deg, rgba(106, 40, 77, 0.94), rgba(101, 64, 100, 0.92) 50%, rgba(73, 91, 120, 0.94)),
    url("./assets/sunset-floral-paper-v4.webp") center / cover;
  background-blend-mode: multiply, normal;
}

@media (max-width: 640px) {
  .envelope-scene {
    min-height: 100svh;
    padding-top: max(4.7rem, env(safe-area-inset-top));
    padding-bottom: max(2.4rem, env(safe-area-inset-bottom));
  }

  .real-envelope {
    width: min(36rem, calc(100vw - 1.25rem));
    margin-top: 0.75rem;
    margin-bottom: 0.95rem;
  }

  .envelope-front-face {
    border-radius: 0.48rem;
  }

  .ribbon-seal {
    width: clamp(4.4rem, 20vw, 5.4rem);
    height: clamp(4.4rem, 20vw, 5.4rem);
  }

  .gate-title {
    font-size: clamp(2rem, 10vw, 2.5rem);
  }

  .gate-note {
    font-size: 0.7rem;
  }

  .reveal-section,
  .gallery-section,
  .events-section,
  .site-footer,
  .planner-view {
    background-position: center top;
    background-size: auto 62rem;
  }
}

/* Keep the dashboard visible quickly when Planner view opens. */
.planner-hero {
  min-height: 24rem;
  padding-top: clamp(3rem, 6vw, 5rem);
  padding-bottom: clamp(2.5rem, 5vw, 4rem);
}

@media (max-width: 760px) {
  .planner-hero {
    min-height: 0;
    padding-top: 3.5rem;
    padding-bottom: 2.5rem;
  }
}
