:root {
  --ink: #12211d;
  --soft-ink: #3e5148;
  --paper: #fbf8f1;
  --mist: #eef5f0;
  --cream: #fff7e7;
  --berry: #d96876;
  --teal: #5ab4aa;
  --gold: #d7a849;
  --shadow: 0 30px 90px rgba(5, 10, 9, 0.35);
  --control-bg: rgba(18, 33, 29, 0.72);
  --control-border: rgba(255, 247, 231, 0.36);
  --control-muted: rgba(255, 247, 231, 0.72);
  --control-text: #fff7e7;
  --gratitude-bg: linear-gradient(135deg, rgba(238, 245, 240, 0.96), rgba(255, 247, 231, 0.98)), #f7f2e8;
  --gratitude-border: rgba(215, 168, 73, 0.26);
  --story-border: rgba(215, 168, 73, 0.3);
  --pointer-x: 50%;
  --pointer-y: 50%;
  --tilt-x: 0;
  --tilt-y: 0;
  --tilt-shift-x: 0px;
  --tilt-shift-y: 0px;
  --vibe-bg-image: url("/assets/story-figurines-bg.jpg");
  --vibe-bg-image-1: var(--vibe-bg-image);
  --vibe-bg-image-2: var(--vibe-bg-image);
  --vibe-bg-image-3: var(--vibe-bg-image);
  --vibe-bg-image-4: var(--vibe-bg-image);
  --band-bg: #f4eee1;
  --panel-bg: rgba(255, 250, 240, 0.86);
  --panel-border: rgba(18, 33, 29, 0.12);
  color-scheme: light;
}

[data-theme="dark"] {
  --ink: #f7efe0;
  --soft-ink: #c9d4cd;
  --paper: #101715;
  --mist: #16231f;
  --cream: #fff7e7;
  --berry: #f08a98;
  --teal: #72d0c6;
  --gold: #e1bb62;
  --shadow: 0 34px 100px rgba(0, 0, 0, 0.54);
  --control-bg: rgba(7, 13, 12, 0.76);
  --control-border: rgba(255, 247, 231, 0.24);
  --control-muted: rgba(255, 247, 231, 0.64);
  --control-text: #fff7e7;
  --gratitude-bg: linear-gradient(135deg, rgba(16, 23, 21, 0.98), rgba(32, 43, 38, 0.98)), #101715;
  --gratitude-border: rgba(225, 187, 98, 0.24);
  --story-border: rgba(225, 187, 98, 0.22);
  --band-bg: #121c19;
  --panel-bg: rgba(20, 31, 28, 0.88);
  --panel-border: rgba(255, 247, 231, 0.12);
  color-scheme: dark;
}

[data-theme="light"] {
  color-scheme: light;
}

[data-vibe="brazil"] {
  --berry: #2fa96b;
  --teal: #2676d3;
  --gold: #f0c94a;
  --control-bg: rgba(11, 72, 46, 0.76);
  --gratitude-border: rgba(47, 169, 107, 0.32);
  --story-border: rgba(240, 201, 74, 0.32);
  --vibe-bg-image: url("/assets/vibes/brazil/christ-the-redeemer.jpg");
  --vibe-bg-image-1: url("/assets/vibes/brazil/christ-the-redeemer.jpg");
  --vibe-bg-image-2: url("/assets/vibes/brazil/sugarloaf-bay.jpg");
  --vibe-bg-image-3: url("/assets/vibes/brazil/morro-da-urca-selfie.jpg");
}

[data-vibe="new-mexico"] {
  --berry: #c75d47;
  --teal: #2d8d98;
  --gold: #d7a443;
  --control-bg: rgba(70, 45, 34, 0.78);
  --gratitude-border: rgba(199, 93, 71, 0.28);
  --story-border: rgba(45, 141, 152, 0.3);
  --vibe-bg-image: url("/assets/vibes/new-mexico/sandia-tram-sunset-selfie.jpg");
  --vibe-bg-image-1: url("/assets/vibes/new-mexico/sandia-tram-sunset-selfie.jpg");
  --vibe-bg-image-2: url("/assets/vibes/new-mexico/roswell-ufo-museum-selfie.jpg");
  --vibe-bg-image-3: url("/assets/vibes/new-mexico/ufo-museum-flying-saucer.jpg");
  --vibe-bg-image-4: url("/assets/vibes/new-mexico/river-of-lights-selfie.jpg");
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background: var(--paper);
  color: var(--ink);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  transition:
    background-color 280ms ease,
    color 280ms ease;
}

body.has-splash {
  overflow: hidden;
}

.site-loader {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 22px;
  padding: 24px;
  background:
    linear-gradient(135deg, rgba(7, 16, 14, 0.96), rgba(19, 31, 27, 0.96)),
    #07120f;
  color: var(--cream);
  transition:
    opacity 520ms ease,
    visibility 520ms ease;
}

.site-loader[hidden] {
  display: none;
}

body.is-ready .site-loader {
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
}

.site-loader__card {
  position: relative;
  width: min(260px, 72vw);
  aspect-ratio: 1.5;
  perspective: 900px;
}

.site-loader__card::before,
.site-loader__flap,
.site-loader__letter {
  position: absolute;
  inset: 0;
  border-radius: 8px;
  content: "";
}

.site-loader__card::before {
  background: linear-gradient(135deg, #fff7e7, #f0dfbf);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.34);
}

.site-loader__flap {
  clip-path: polygon(0 0, 50% 56%, 100% 0);
  background: #ead5ac;
  transform-origin: top;
  animation: loaderEnvelope 1.8s ease-in-out infinite;
}

.site-loader__letter {
  inset: 22% 14% 12%;
  background:
    linear-gradient(90deg, rgba(215, 168, 73, 0.42), transparent 42%),
    #fffaf0;
  transform: translateY(16px);
  animation: loaderLetter 1.8s ease-in-out infinite;
}

.site-loader__message {
  min-height: 1.5em;
  margin: 0;
  color: rgba(255, 247, 231, 0.82);
  font-weight: 800;
  text-align: center;
}

.page-wrap {
  transform-origin: top center;
}

body:not(.is-ready) .page-wrap {
  opacity: 0;
  transform: perspective(1200px) rotateX(18deg) translateY(24px);
}

body.is-ready .page-wrap {
  animation: pageCardOpen 900ms cubic-bezier(0.2, 0.75, 0.2, 1) both;
}

.site-controls {
  position: fixed;
  top: clamp(14px, 2vw, 22px);
  right: clamp(14px, 2vw, 22px);
  z-index: 12;
  display: grid;
  grid-template-columns: auto minmax(166px, 210px) minmax(178px, 230px);
  gap: 8px;
  align-items: stretch;
  max-width: calc(100vw - 28px);
}

.theme-toggle,
.motion-control,
.vibe-control {
  border: 1px solid var(--control-border);
  border-radius: 8px;
  background: var(--control-bg);
  color: var(--control-text);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.24);
  backdrop-filter: blur(14px);
}

.theme-toggle {
  display: grid;
  gap: 2px;
  min-width: 88px;
  padding: 9px 12px;
  cursor: pointer;
  text-align: left;
}

.motion-control {
  display: grid;
  gap: 5px;
  padding: 9px 12px 8px;
}

.vibe-control {
  display: grid;
  gap: 6px;
  padding: 9px 10px 8px;
}

.vibe-control__buttons {
  display: grid;
  grid-template-columns: 1fr 1fr 0.72fr;
  gap: 5px;
}

.vibe-control__buttons button {
  min-width: 0;
  min-height: 30px;
  border: 1px solid rgba(255, 247, 231, 0.22);
  border-radius: 6px;
  background: rgba(255, 247, 231, 0.08);
  color: var(--control-text);
  cursor: pointer;
  font-size: 0.72rem;
  font-weight: 800;
}

.vibe-control__buttons button[aria-pressed="true"] {
  border-color: rgba(255, 247, 231, 0.58);
  background: rgba(255, 247, 231, 0.22);
}

.control-label {
  color: var(--control-muted);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.control-value {
  font-size: 0.92rem;
  font-weight: 800;
}

.motion-control input {
  width: 100%;
  accent-color: var(--gold);
  cursor: pointer;
}

.motion-control__labels {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  color: var(--control-muted);
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.theme-toggle:focus-visible,
.motion-control input:focus-visible,
.vibe-control__buttons button:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 4px;
}

.fun-layer {
  position: fixed;
  inset: 0;
  z-index: 5;
  display: none;
  overflow: hidden;
  pointer-events: none;
}

[data-motion="fun"] .fun-layer:not([hidden]) {
  display: block;
}

.fun-sparkle {
  position: absolute;
  left: var(--x);
  top: var(--y);
  width: var(--size);
  height: var(--size);
  display: grid;
  place-items: center;
  color: var(--gold);
  font-size: var(--font-size);
  font-weight: 900;
  line-height: 1;
  opacity: 0;
  text-shadow: 0 0 18px rgba(215, 168, 73, 0.42);
  transform: translate3d(-50%, -50%, 0);
  animation: funSparkle var(--duration) ease-in-out var(--delay) infinite;
}

.fun-sparkle:nth-child(3n) {
  color: var(--teal);
}

.fun-sparkle:nth-child(4n) {
  color: var(--berry);
}

.fun-confetti,
.fun-ribbon,
.fun-trail,
.fun-burst {
  position: absolute;
  pointer-events: none;
  will-change: opacity, transform;
}

.fun-confetti {
  left: var(--x);
  top: -18vh;
  width: var(--width);
  height: var(--height);
  border-radius: 2px;
  background: var(--piece-color);
  box-shadow: 0 0 16px rgba(255, 247, 231, 0.18);
  opacity: 0;
  animation: funConfetti var(--duration) linear var(--delay) infinite;
}

.fun-ribbon {
  left: var(--x);
  top: -28vh;
  width: 2px;
  height: var(--height);
  border-radius: 999px;
  background: linear-gradient(180deg, transparent, var(--piece-color), transparent);
  opacity: 0;
  transform-origin: top center;
  animation: funRibbon var(--duration) ease-in-out var(--delay) infinite;
}

.fun-trail {
  left: var(--trail-x);
  top: var(--trail-y);
  display: grid;
  place-items: center;
  width: var(--trail-size);
  height: var(--trail-size);
  color: var(--cream);
  font-size: var(--trail-font-size);
  font-weight: 900;
  line-height: 1;
  text-shadow:
    0 0 18px rgba(255, 247, 231, 0.7),
    0 0 28px rgba(90, 180, 170, 0.44);
  transform: translate3d(-50%, -50%, 0) rotate(var(--trail-rotate));
  animation: funTrail 820ms ease-out both;
}

.fun-burst {
  left: var(--burst-x);
  top: var(--burst-y);
  display: grid;
  place-items: center;
  width: var(--burst-size);
  height: var(--burst-size);
  color: var(--gold);
  font-size: var(--burst-font-size);
  font-weight: 900;
  line-height: 1;
  text-shadow:
    0 0 16px rgba(215, 168, 73, 0.66),
    0 0 28px rgba(217, 104, 118, 0.42);
  transform: translate3d(-50%, -50%, 0);
  animation: funBurst 940ms cubic-bezier(0.13, 0.78, 0.24, 1) var(--burst-delay) both;
}

.fun-burst:nth-last-child(3n) {
  color: var(--teal);
}

.fun-burst:nth-last-child(4n) {
  color: var(--berry);
}


[data-motion="fun"] .site-controls {
  animation: controlsBob 5.8s ease-in-out infinite;
}

[data-motion="fun"] .theme-toggle,
[data-motion="fun"] .motion-control,
[data-motion="fun"] .vibe-control {
  transition:
    border-color 180ms ease,
    box-shadow 180ms ease,
    transform 180ms ease;
}

[data-motion="fun"] .theme-toggle:hover,
[data-motion="fun"] .motion-control:hover,
[data-motion="fun"] .vibe-control:hover {
  border-color: rgba(255, 247, 231, 0.62);
  box-shadow:
    0 20px 52px rgba(0, 0, 0, 0.26),
    0 0 0 1px rgba(215, 168, 73, 0.28);
  transform: translateY(-2px) rotate(-0.35deg);
}

[data-motion="fun"] .hero::before {
  animation-duration: 9s;
  filter: saturate(1.18) contrast(1.08);
}

[data-motion="fun"] .hero::after {
  background:
    radial-gradient(circle at var(--pointer-x) var(--pointer-y), rgba(90, 180, 170, 0.34), rgba(90, 180, 170, 0) 18%),
    radial-gradient(circle at 58% 63%, rgba(215, 168, 73, 0.34), rgba(215, 168, 73, 0) 25%),
    linear-gradient(90deg, rgba(3, 9, 8, 0.86) 0%, rgba(5, 15, 13, 0.72) 34%, rgba(6, 11, 10, 0.22) 64%, rgba(4, 7, 7, 0.18) 100%),
    linear-gradient(180deg, rgba(5, 8, 8, 0.08) 0%, rgba(5, 8, 8, 0.82) 100%);
  animation-duration: 7s;
}

[data-motion="fun"] .hero__content {
  transform: translate3d(var(--tilt-shift-x), var(--tilt-shift-y), 0);
  transition: transform 220ms ease-out;
}

[data-motion="fun"] .hero__content::after {
  position: absolute;
  left: 0;
  bottom: clamp(-30px, -3vw, -18px);
  width: min(340px, 52vw);
  height: 2px;
  background: linear-gradient(90deg, var(--teal), var(--gold), var(--berry), transparent);
  content: "";
  opacity: 0.78;
  transform-origin: left;
  animation: funUnderline 2.9s ease-in-out infinite;
}

[data-motion="fun"] h1 {
  transform-origin: left center;
  animation: titleBreathe 4.8s ease-in-out infinite;
}

[data-motion="fun"] .message {
  animation: messageFloat 5.6s ease-in-out infinite;
}

[data-motion="fun"] .eyebrow {
  animation: softWiggle 3.4s ease-in-out infinite;
}

[data-motion="fun"] .signature {
  animation: signatureSway 4.2s ease-in-out infinite;
}

[data-motion="fun"] .scroll-cue {
  animation: superCueFloat 1.35s ease-in-out infinite;
}

[data-motion="fun"] .scroll-cue__mark {
  animation: superRingPulse 1.5s ease-in-out infinite;
}

[data-motion="fun"] .guest-splash.is-visible .guest-splash__card {
  animation: splashFloat 3.4s ease-in-out 300ms infinite;
}

[data-motion="fun"] .guest-splash__card::before {
  animation: tapeFlutter 2.8s ease-in-out infinite;
}

[data-motion="fun"] .story::before {
  animation-duration: 10s;
  filter: saturate(1.22) contrast(1.08);
}

[data-motion="fun"] .story::after {
  background:
    linear-gradient(90deg, rgba(7, 9, 9, 0.1) 0%, rgba(7, 9, 9, 0.48) 38%, rgba(7, 9, 9, 0.9) 62%, rgba(7, 9, 9, 0.98) 100%),
    linear-gradient(180deg, rgba(7, 9, 9, 0.02) 0%, rgba(7, 9, 9, 0.76) 100%);
  animation-duration: 7.5s;
}

[data-motion="fun"] .story__copy p {
  transition:
    color 180ms ease,
    transform 180ms ease;
}

[data-motion="fun"] .story__copy p:hover {
  color: var(--cream);
  transform: translateX(8px);
}

[data-motion="fun"] .story h2 {
  animation: storyHeadlineGlow 4.6s ease-in-out infinite;
}

[data-motion="fun"] .story__copy {
  animation: storyCopyFloat 6.8s ease-in-out infinite;
}

[data-motion="fun"] .gratitude {
  background-size: cover;
  animation: gratitudeWash 7.2s ease-in-out infinite alternate;
}

[data-motion="fun"] .gratitude__inner {
  position: relative;
}

[data-motion="fun"] .gratitude__inner::before {
  position: absolute;
  top: clamp(18px, 4vw, 36px);
  left: 0;
  width: min(280px, 40vw);
  height: 2px;
  background: linear-gradient(90deg, var(--berry), var(--gold), var(--teal), transparent);
  content: "";
  transform-origin: left;
  animation: colorRibbon 4.6s ease-in-out infinite;
}

[data-motion="fun"] .gratitude h2 {
  transform-origin: left center;
  animation: gratitudeNod 5.2s ease-in-out infinite;
}

[data-motion="fun"] .gratitude p:last-child {
  animation: gratitudeTextLift 4.7s ease-in-out infinite;
}

[data-motion="off"] *,
[data-motion="off"] *::before,
[data-motion="off"] *::after {
  animation-duration: 1ms !important;
  animation-iteration-count: 1 !important;
  scroll-behavior: auto !important;
  transition-duration: 1ms !important;
}

[data-motion="off"] .story .section-kicker,
[data-motion="off"] .story h2,
[data-motion="off"] .story__copy {
  opacity: 1;
  transform: none;
}

.guest-splash[hidden] {
  display: none;
}

.guest-splash {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: clamp(18px, 4vw, 48px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 260ms ease;
}

.guest-splash.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.guest-splash__backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background:
    linear-gradient(180deg, rgba(5, 10, 9, 0.66), rgba(5, 10, 9, 0.86)),
    rgba(5, 10, 9, 0.72);
  backdrop-filter: blur(13px);
  cursor: pointer;
}

.guest-splash__card {
  --splash-rotation: -2deg;
  --splash-drag-x: 0px;
  --splash-drag-y: 0px;
  --splash-drag-rotation: 0deg;
  --splash-card-ink: #12211d;
  --splash-card-muted: #53635c;
  --splash-card-accent: #d96876;
  position: relative;
  z-index: 1;
  width: min(980px, calc(100vw - 36px));
  max-height: calc(100svh - 40px);
  margin: 0;
  padding: clamp(8px, 1.4vw, 12px) clamp(8px, 1.4vw, 12px) clamp(14px, 2.2vw, 20px);
  overflow: visible;
  border: 1px solid rgba(255, 247, 231, 0.82);
  border-radius: 8px;
  background: #fffaf0;
  box-shadow:
    0 34px 110px rgba(0, 0, 0, 0.52),
    0 10px 30px rgba(0, 0, 0, 0.22);
  color: var(--splash-card-ink);
  color-scheme: light;
  cursor: grab;
  touch-action: none;
  user-select: none;
  transform: translate3d(var(--splash-drag-x), calc(var(--splash-drag-y) + 24px), 0) scale(0.96) rotate(calc(var(--splash-rotation) - 1.5deg + var(--splash-drag-rotation)));
  transition:
    opacity 340ms ease,
    transform 520ms cubic-bezier(0.2, 0.75, 0.2, 1);
}

.guest-splash.is-visible .guest-splash__card {
  opacity: 1;
  transform: translate3d(var(--splash-drag-x), var(--splash-drag-y), 0) scale(1) rotate(calc(var(--splash-rotation) + var(--splash-drag-rotation)));
  animation: splashFloat 5.4s ease-in-out 700ms infinite;
}

.guest-splash.is-visible .guest-splash__card.is-dragging {
  cursor: grabbing;
  animation: none;
  transition: box-shadow 180ms ease;
  box-shadow:
    0 42px 120px rgba(0, 0, 0, 0.56),
    0 16px 38px rgba(0, 0, 0, 0.28);
}

.guest-splash__card::before {
  position: absolute;
  top: -18px;
  left: 50%;
  width: min(168px, 34vw);
  height: 34px;
  border-radius: 4px;
  background: rgba(255, 247, 231, 0.72);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.18);
  content: "";
  transform: translateX(-50%) rotate(1.5deg);
}

.guest-splash__card img {
  display: block;
  width: 100%;
  height: auto;
  max-height: min(66svh, 620px);
  border-radius: 5px;
  background: #0b1110;
  filter: none;
  mix-blend-mode: normal;
  opacity: 1;
  object-fit: contain;
  pointer-events: none;
  -webkit-user-drag: none;
}

.guest-splash__close {
  position: absolute;
  top: 18px;
  right: 18px;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(255, 247, 231, 0.5);
  border-radius: 999px;
  background: rgba(18, 33, 29, 0.82);
  color: var(--cream);
  cursor: pointer;
  font-size: 1.7rem;
  line-height: 1;
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(8px);
}

.guest-splash__close:hover,
.guest-splash__close:focus-visible {
  background: #12211d;
  color: #fff7e7;
}

.guest-splash__close:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 4px;
}

.guest-splash__caption {
  display: grid;
  gap: 5px;
  padding: clamp(12px, 2vw, 18px) clamp(4px, 1vw, 8px) 0;
}

.guest-splash__kicker {
  color: var(--splash-card-accent);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.guest-splash__caption strong {
  color: var(--splash-card-ink);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.35rem, 2.5vw, 2.2rem);
  font-weight: 500;
  line-height: 1.05;
}

.guest-splash__caption span:last-child {
  color: var(--splash-card-muted);
  font-size: clamp(0.95rem, 1.3vw, 1.08rem);
  line-height: 1.45;
}

.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  align-items: center;
  overflow: hidden;
  padding: clamp(28px, 6vw, 84px);
  isolation: isolate;
  background: #07120f;
}

.hero::before,
.hero::after {
  position: absolute;
  inset: 0;
  content: "";
}

.hero::before {
  z-index: -2;
  inset: -5%;
  background: url("/assets/rings-bible-bg.jpg") 62% 58% / cover no-repeat;
  filter: saturate(1.06) contrast(1.05);
  transform: scale(1.035);
  animation: photoDrift 18s ease-in-out infinite alternate;
}

.hero::after {
  z-index: -1;
  background:
    radial-gradient(circle at 58% 63%, rgba(215, 168, 73, 0.26), rgba(215, 168, 73, 0) 24%),
    linear-gradient(90deg, rgba(3, 9, 8, 0.88) 0%, rgba(5, 15, 13, 0.78) 34%, rgba(6, 11, 10, 0.34) 64%, rgba(4, 7, 7, 0.22) 100%),
    linear-gradient(180deg, rgba(5, 8, 8, 0.18) 0%, rgba(5, 8, 8, 0.86) 100%);
  animation: lightDrift 14s ease-in-out infinite alternate;
}


[data-theme="dark"] .hero::after {
  background:
    radial-gradient(circle at 58% 63%, rgba(225, 187, 98, 0.24), rgba(225, 187, 98, 0) 24%),
    linear-gradient(90deg, rgba(2, 7, 6, 0.92) 0%, rgba(4, 12, 11, 0.84) 34%, rgba(4, 9, 8, 0.42) 64%, rgba(3, 6, 6, 0.32) 100%),
    linear-gradient(180deg, rgba(5, 8, 8, 0.24) 0%, rgba(3, 6, 6, 0.9) 100%);
}

[data-theme="light"] .hero::after {
  background:
    radial-gradient(circle at 58% 63%, rgba(215, 168, 73, 0.3), rgba(215, 168, 73, 0) 24%),
    linear-gradient(90deg, rgba(3, 9, 8, 0.82) 0%, rgba(5, 15, 13, 0.68) 34%, rgba(6, 11, 10, 0.26) 64%, rgba(4, 7, 7, 0.16) 100%),
    linear-gradient(180deg, rgba(5, 8, 8, 0.12) 0%, rgba(5, 8, 8, 0.78) 100%);
}

[data-theme="dark"] .gratitude h2 {
  color: var(--cream);
}

[data-theme="dark"] .gratitude p:last-child {
  color: rgba(255, 247, 231, 0.78);
}

[data-theme="dark"] .section-kicker {
  color: var(--berry);
}

.hero__content {
  position: relative;
  z-index: 1;
  width: min(100%, 690px);
  padding: clamp(8px, 1vw, 14px) 0;
  color: var(--cream);
  animation: contentRise 900ms cubic-bezier(0.2, 0.75, 0.2, 1) 120ms both;
}

.hero__content::before {
  display: block;
  width: min(180px, 42vw);
  height: 1px;
  margin-bottom: clamp(26px, 5vw, 44px);
  background: linear-gradient(90deg, var(--gold), rgba(255, 247, 231, 0));
  content: "";
  transform-origin: left;
  animation:
    detailSweep 1.1s ease-out 450ms both,
    lineGlow 3.8s ease-in-out 1.7s infinite;
}

.eyebrow,
.section-kicker {
  margin: 0 0 18px;
  color: var(--berry);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
p {
  overflow-wrap: anywhere;
}

h1 {
  max-width: 10.6ch;
  margin: 0;
  color: var(--cream);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(3.15rem, 8vw, 7.15rem);
  font-weight: 500;
  line-height: 0.92;
  text-wrap: balance;
  text-shadow: 0 18px 48px rgba(0, 0, 0, 0.42);
}

.message {
  max-width: 42rem;
  margin: clamp(24px, 4vw, 38px) 0 0;
  color: rgba(255, 247, 231, 0.91);
  font-size: clamp(1.12rem, 2vw, 1.42rem);
  line-height: 1.65;
  text-shadow: 0 10px 32px rgba(0, 0, 0, 0.42);
}

.memory {
  max-width: 38rem;
  margin: 22px 0 0;
  padding-left: 18px;
  border-left: 4px solid var(--gold);
  color: rgba(255, 247, 231, 0.76);
  font-size: clamp(1rem, 1.5vw, 1.16rem);
  line-height: 1.6;
  animation: contentRise 900ms cubic-bezier(0.2, 0.75, 0.2, 1) 320ms both;
}

.signature {
  margin: clamp(28px, 5vw, 46px) 0 0;
  color: var(--teal);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.55rem, 3vw, 2.25rem);
  font-style: italic;
  text-shadow: 0 12px 38px rgba(0, 0, 0, 0.45);
  animation: contentRise 900ms cubic-bezier(0.2, 0.75, 0.2, 1) 440ms both;
}

.scroll-cue {
  position: absolute;
  right: clamp(22px, 5vw, 72px);
  bottom: clamp(20px, 4vw, 46px);
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  padding: 0;
  border: 0;
  color: rgba(255, 247, 231, 0.9);
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0;
  text-decoration: none;
  text-transform: uppercase;
  text-shadow: 0 10px 30px rgba(0, 0, 0, 0.55);
  animation: cueFloat 1.9s ease-in-out infinite;
}

.scroll-cue__mark {
  width: 34px;
  height: 34px;
  border: 1px solid rgba(255, 247, 231, 0.58);
  border-radius: 999px;
  position: relative;
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.28);
  animation: ringPulse 2.4s ease-in-out infinite;
}

.scroll-cue__mark::before {
  position: absolute;
  left: 50%;
  top: 46%;
  width: 8px;
  height: 8px;
  border-right: 2px solid var(--gold);
  border-bottom: 2px solid var(--gold);
  content: "";
  transform: translate(-50%, -50%) rotate(45deg);
}

.scroll-cue:hover,
.scroll-cue:focus-visible {
  color: var(--cream);
}

.scroll-cue:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 8px;
}

.story {
  position: relative;
  min-height: 100svh;
  display: grid;
  align-items: center;
  overflow: hidden;
  isolation: isolate;
  color: var(--cream);
  background: #090c0c;
  border-top: 1px solid var(--story-border);
}

.story::before,
.story::after {
  position: absolute;
  inset: 0;
  content: "";
}

.story::before {
  z-index: -2;
  inset: -5%;
  background: url("/assets/story-figurines-bg.jpg") 64% 51% / cover no-repeat;
  filter: saturate(1.08) contrast(1.03);
  animation: storyPhotoDrift 22s ease-in-out infinite alternate;
}

.story::after {
  z-index: -1;
  background:
    linear-gradient(90deg, rgba(7, 9, 9, 0.16) 0%, rgba(7, 9, 9, 0.58) 40%, rgba(7, 9, 9, 0.92) 62%, rgba(7, 9, 9, 0.98) 100%),
    linear-gradient(180deg, rgba(7, 9, 9, 0.1) 0%, rgba(7, 9, 9, 0.78) 100%);
  animation: storyShadeDrift 13s ease-in-out infinite alternate;
}

.story__inner {
  width: min(1120px, calc(100% - 48px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(260px, 0.95fr) minmax(320px, 0.86fr);
  gap: clamp(34px, 6vw, 96px);
  align-items: start;
  padding: clamp(70px, 10vw, 130px) 0;
}

.story .section-kicker,
.story h2,
.story__copy {
  grid-column: 2;
}

.story h2 {
  max-width: 9ch;
  margin: 0;
  color: var(--cream);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(3.2rem, 7vw, 7rem);
  font-weight: 500;
  line-height: 0.92;
  text-shadow: 0 22px 62px rgba(0, 0, 0, 0.52);
}

.story__copy {
  display: grid;
  gap: 22px;
  max-width: 690px;
  color: rgba(255, 247, 231, 0.88);
  font-size: clamp(1.12rem, 1.8vw, 1.38rem);
  line-height: 1.75;
  text-shadow: 0 14px 36px rgba(0, 0, 0, 0.55);
}

.story__copy p {
  margin: 0;
}

.story .section-kicker,
.story h2,
.story__copy {
  opacity: 0;
  transform: translateY(22px);
  transition:
    opacity 750ms ease,
    transform 750ms cubic-bezier(0.2, 0.75, 0.2, 1);
}

.story.is-visible .section-kicker,
.story.is-visible h2,
.story.is-visible .story__copy {
  opacity: 1;
  transform: translateY(0);
}

.story.is-visible h2 {
  transition-delay: 120ms;
}

.story.is-visible .story__copy {
  transition-delay: 240ms;
}

.story.is-visible .story__copy p {
  animation: storyLineLift 800ms cubic-bezier(0.2, 0.75, 0.2, 1) both;
}

.story.is-visible .story__copy p:nth-child(2) {
  animation-delay: 120ms;
}

.story.is-visible .story__copy p:nth-child(3) {
  animation-delay: 240ms;
}

.celebration,
.gallery,
.photo-upload,
.closing-signature {
  position: relative;
  overflow: hidden;
  background: var(--band-bg);
  color: var(--ink);
  border-top: 1px solid var(--panel-border);
}

.celebration__inner,
.gallery__inner,
.photo-upload__inner {
  position: relative;
  z-index: 1;
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
  padding: clamp(58px, 8vw, 108px) 0;
}

.celebration__inner {
  display: grid;
  grid-template-columns: minmax(260px, 0.9fr) minmax(260px, 0.78fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: center;
}

.celebration__copy h2,
.gallery h2,
.photo-upload h2 {
  max-width: 11ch;
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.4rem, 5.8vw, 5.8rem);
  font-weight: 500;
  line-height: 0.96;
}

.celebration__copy > p:last-child,
.photo-upload p:last-child {
  max-width: 42rem;
  color: var(--soft-ink);
  font-size: clamp(1.05rem, 1.6vw, 1.28rem);
  line-height: 1.7;
}

.celebration {
  background:
    linear-gradient(90deg, rgba(244, 238, 225, 0.98) 0%, rgba(244, 238, 225, 0.9) 42%, rgba(244, 238, 225, 0.56) 100%),
    url("/assets/gallery/couple-toast.jpg") 52% 58% / cover no-repeat;
}

[data-theme="dark"] .celebration {
  background:
    linear-gradient(90deg, rgba(18, 28, 25, 0.98) 0%, rgba(18, 28, 25, 0.91) 42%, rgba(18, 28, 25, 0.6) 100%),
    url("/assets/gallery/couple-toast.jpg") 52% 58% / cover no-repeat;
}

.married-counter {
  width: fit-content;
  margin: 26px 0 18px;
  padding: 14px 16px;
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  background: var(--panel-bg);
  color: var(--ink);
  font-size: clamp(1.08rem, 1.6vw, 1.28rem);
  font-weight: 900;
  box-shadow: 0 18px 46px rgba(5, 10, 9, 0.1);
}

.envelope-card {
  display: grid;
  justify-items: center;
  gap: 14px;
  min-height: 360px;
  padding: clamp(24px, 4vw, 42px);
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 247, 231, 0.72), rgba(238, 245, 240, 0.76)),
    var(--panel-bg);
  color: var(--ink);
  cursor: pointer;
  text-align: center;
  box-shadow: 0 26px 80px rgba(5, 10, 9, 0.16);
}

[data-theme="dark"] .envelope-card {
  background:
    linear-gradient(135deg, rgba(255, 247, 231, 0.08), rgba(90, 180, 170, 0.08)),
    var(--panel-bg);
}

.envelope-card:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 6px;
}

.envelope-card__art {
  position: relative;
  display: block;
  width: min(280px, 68vw);
  aspect-ratio: 1.42;
  margin: 18px 0 8px;
  perspective: 900px;
}

.envelope-card__back,
.envelope-card__front,
.envelope-card__flap,
.envelope-card__letter {
  position: absolute;
  inset: 0;
  border-radius: 8px;
}

.envelope-card__back {
  background: #ead5ac;
  box-shadow: 0 24px 58px rgba(5, 10, 9, 0.22);
}

.envelope-card__letter {
  inset: 12% 10% 24%;
  background:
    linear-gradient(90deg, rgba(215, 168, 73, 0.38), transparent 44%),
    #fffaf0;
  transform: translateY(42px);
  transition: transform 520ms cubic-bezier(0.2, 0.75, 0.2, 1);
}

.envelope-card__front {
  clip-path: polygon(0 100%, 0 34%, 50% 68%, 100% 34%, 100% 100%);
  background: linear-gradient(135deg, #f5e5c4, #dcbf83);
}

.envelope-card__flap {
  clip-path: polygon(0 0, 50% 56%, 100% 0);
  background: #e6c88d;
  transform-origin: top;
  transition: transform 520ms cubic-bezier(0.2, 0.75, 0.2, 1);
}

.envelope-card.is-open .envelope-card__flap {
  transform: rotateX(156deg);
}

.envelope-card.is-open .envelope-card__letter {
  transform: translateY(-18px);
}

.envelope-card__title {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.45rem, 2.6vw, 2.35rem);
  line-height: 1.05;
}

.envelope-card__copy {
  max-width: 29rem;
  color: var(--soft-ink);
  font-size: 1rem;
  line-height: 1.6;
}

.celebration-actions {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.action-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  background: var(--ink);
  color: var(--paper);
  cursor: pointer;
  font-weight: 900;
  text-decoration: none;
  box-shadow: 0 14px 36px rgba(5, 10, 9, 0.16);
}

.action-button:hover,
.action-button:focus-visible {
  background: var(--soft-ink);
}

.action-button:disabled {
  cursor: wait;
  opacity: 0.64;
}

.action-button:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 4px;
}

.action-button--super {
  background: var(--gold);
  color: #12211d;
}

.action-button--danger {
  background: var(--berry);
  color: #fff7e7;
}

.super-only {
  display: none;
}

[data-motion="fun"] .super-only {
  display: inline-flex;
}

.gallery {
  background:
    linear-gradient(180deg, rgba(255, 247, 231, 0.5), transparent 48%),
    var(--paper);
}

[data-theme="dark"] .gallery {
  background:
    linear-gradient(180deg, rgba(90, 180, 170, 0.08), transparent 48%),
    var(--paper);
}

.gallery__inner {
  display: grid;
  gap: clamp(28px, 4vw, 48px);
}

.polaroid-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(16px, 2vw, 28px);
  align-items: start;
}

.polaroid-card {
  margin: 0;
  padding: 10px 10px 18px;
  border: 1px solid rgba(18, 33, 29, 0.08);
  border-radius: 6px;
  background: #fffaf0;
  color: #12211d;
  box-shadow: 0 20px 52px rgba(5, 10, 9, 0.18);
  transform: rotate(var(--polaroid-rotation));
  transition:
    box-shadow 180ms ease,
    transform 180ms ease;
}

.polaroid-card:hover {
  box-shadow: 0 28px 70px rgba(5, 10, 9, 0.24);
  transform: rotate(0deg) translateY(-5px);
}

.polaroid-card img {
  display: block;
  width: 100%;
  aspect-ratio: 1.08;
  border-radius: 4px;
  background: #101715;
  object-fit: cover;
}

.polaroid-card figcaption {
  padding-top: 12px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.08rem;
  line-height: 1.25;
  text-align: center;
}

.photo-upload-form {
  display: grid;
  gap: 14px;
  padding: clamp(18px, 3vw, 28px);
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  background: var(--panel-bg);
  box-shadow: 0 22px 60px rgba(5, 10, 9, 0.12);
}

.photo-upload-form label {
  display: grid;
  gap: 7px;
  color: var(--soft-ink);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.photo-upload-form input {
  width: 100%;
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  background: rgba(255, 250, 240, 0.92);
  color: #12211d;
  font: inherit;
  font-size: 1rem;
  padding: 12px 13px;
}

.file-drop {
  min-height: 96px;
  place-content: center;
  border: 1px dashed var(--gold);
  border-radius: 8px;
  background: rgba(215, 168, 73, 0.08);
  color: var(--ink);
  cursor: pointer;
  text-align: center;
}

.file-drop input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.form-status {
  min-height: 1.5em;
  margin: 0;
  color: var(--soft-ink);
  font-size: 0.94rem;
  font-weight: 800;
}

.photo-upload {
  isolation: isolate;
  background: var(--paper);
}

.photo-upload::before {
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    linear-gradient(90deg, rgba(251, 248, 241, 0.74), rgba(251, 248, 241, 0.92) 52%, rgba(251, 248, 241, 0.76)),
    url("/assets/gallery/ceremony-party-outside.jpg") center 46% / cover no-repeat;
  content: "";
  pointer-events: none;
}

[data-theme="dark"] .photo-upload::before {
  background:
    linear-gradient(90deg, rgba(16, 23, 21, 0.82), rgba(16, 23, 21, 0.94) 52%, rgba(16, 23, 21, 0.8)),
    url("/assets/gallery/ceremony-party-outside.jpg") center 46% / cover no-repeat;
}

.photo-upload__inner {
  display: grid;
  grid-template-columns: minmax(260px, 0.9fr) minmax(280px, 0.7fr);
  gap: clamp(26px, 5vw, 68px);
  align-items: start;
}

.gratitude {
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(8, 16, 14, 0.9), rgba(8, 16, 14, 0.7)),
    url("/assets/gallery/whole-room-group-photo.jpg") center 42% / cover no-repeat;
  border-top: 1px solid var(--gratitude-border);
  color: #fff7e7;
}

.gratitude__inner {
  position: relative;
  z-index: 1;
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(180px, 0.42fr) minmax(280px, 0.82fr) minmax(280px, 1fr);
  gap: clamp(26px, 5vw, 78px);
  align-items: start;
  padding: clamp(44px, 7vw, 86px) 0;
}

.gratitude h2 {
  max-width: 12ch;
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2rem, 4vw, 4.2rem);
  font-weight: 500;
  line-height: 1;
}

.gratitude p:last-child {
  margin: 0;
  color: rgba(255, 247, 231, 0.84);
  font-size: clamp(1.08rem, 1.7vw, 1.32rem);
  line-height: 1.75;
}

@keyframes loaderEnvelope {
  0%,
  100% {
    transform: rotateX(0deg);
  }

  48%,
  70% {
    transform: rotateX(150deg);
  }
}

@keyframes loaderLetter {
  0%,
  100% {
    transform: translateY(18px);
  }

  48%,
  70% {
    transform: translateY(-18px);
  }
}

@keyframes pageCardOpen {
  from {
    opacity: 0;
    transform: perspective(1200px) rotateX(18deg) translateY(24px);
  }

  to {
    opacity: 1;
    transform: perspective(1200px) rotateX(0deg) translateY(0);
  }
}

.closing-signature {
  display: grid;
  place-items: center;
  gap: 12px;
  min-height: 42svh;
  padding: clamp(48px, 8vw, 96px) 20px;
  text-align: center;
}

.closing-signature__text {
  min-height: 1.16em;
  margin: 0;
  color: var(--ink);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.6rem, 7vw, 6.4rem);
  line-height: 1;
}

.closing-signature__vibe {
  max-width: 42rem;
  margin: 0;
  color: var(--soft-ink);
  font-size: clamp(1.04rem, 1.6vw, 1.28rem);
  line-height: 1.6;
}

.panic-note {
  position: fixed;
  left: 50%;
  bottom: clamp(18px, 4vw, 38px);
  z-index: 30;
  width: min(520px, calc(100vw - 32px));
  padding: 15px 18px;
  border: 1px solid rgba(255, 247, 231, 0.36);
  border-radius: 8px;
  background: rgba(18, 33, 29, 0.88);
  color: var(--cream);
  font-weight: 900;
  text-align: center;
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.32);
  transform: translateX(-50%);
  backdrop-filter: blur(14px);
}

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

.note-modal {
  position: fixed;
  inset: 0;
  z-index: 32;
  display: grid;
  place-items: center;
  padding: 22px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 220ms ease;
}

.note-modal.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.note-modal__backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(5, 10, 9, 0.66);
  backdrop-filter: blur(10px);
  cursor: pointer;
}

.note-modal__card {
  position: relative;
  z-index: 1;
  width: min(620px, calc(100vw - 36px));
  margin: 0;
  padding: clamp(26px, 5vw, 46px);
  border: 1px solid rgba(255, 247, 231, 0.76);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 250, 240, 0.96), rgba(245, 229, 196, 0.98)),
    #fffaf0;
  color: #12211d;
  box-shadow: 0 34px 110px rgba(0, 0, 0, 0.42);
  transform: translateY(18px) scale(0.96) rotate(-0.6deg);
  transition: transform 260ms cubic-bezier(0.2, 0.75, 0.2, 1);
}

.note-modal.is-visible .note-modal__card {
  transform: translateY(0) scale(1) rotate(-0.6deg);
}

.note-modal__close {
  position: absolute;
  top: 14px;
  right: 14px;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(18, 33, 29, 0.18);
  border-radius: 999px;
  background: #12211d;
  color: #fff7e7;
  cursor: pointer;
  font-size: 1.6rem;
  line-height: 1;
}

.note-modal__card h2 {
  max-width: 9ch;
  margin: 0 0 18px;
  color: #12211d;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.4rem, 6vw, 5.4rem);
  font-weight: 500;
  line-height: 0.94;
}

.note-modal__card p:last-child {
  margin: 0;
  color: #53635c;
  font-size: clamp(1.08rem, 1.8vw, 1.35rem);
  line-height: 1.72;
}

.not-found-page {
  min-height: 100svh;
  background:
    linear-gradient(135deg, rgba(18, 33, 29, 0.84), rgba(18, 33, 29, 0.38)),
    url("/assets/rings-bible-bg.jpg") center / cover no-repeat;
}

.not-found {
  width: min(760px, calc(100% - 40px));
  min-height: 100svh;
  display: grid;
  align-content: center;
  gap: 20px;
  margin: 0 auto;
  color: var(--cream);
}

.not-found h1 {
  max-width: 11ch;
}

.not-found p:not(.section-kicker) {
  max-width: 34rem;
  margin: 0;
  color: rgba(255, 247, 231, 0.82);
  font-size: clamp(1.08rem, 1.8vw, 1.34rem);
  line-height: 1.65;
}

.not-found .action-button {
  width: fit-content;
  background: var(--cream);
  color: #12211d;
}

.celebration,
.gallery,
.photo-upload,
.gratitude,
.closing-signature {
  opacity: 0;
  transform: translateY(22px);
  transition:
    opacity 720ms ease,
    transform 720ms cubic-bezier(0.2, 0.75, 0.2, 1);
}

.celebration.is-visible,
.gallery.is-visible,
.photo-upload.is-visible,
.gratitude.is-visible,
.closing-signature.is-visible {
  opacity: 1;
  transform: translateY(0);
}

[data-vibe="brazil"] .celebration {
  background:
    radial-gradient(circle at 86% 20%, rgba(240, 201, 74, 0.22), transparent 28%),
    linear-gradient(135deg, rgba(47, 169, 107, 0.16), rgba(240, 201, 74, 0.14)),
    var(--band-bg);
}

[data-vibe="brazil"] .celebration::before {
  position: absolute;
  right: max(18px, 5vw);
  top: clamp(32px, 8vw, 86px);
  z-index: 0;
  width: min(330px, 34vw);
  aspect-ratio: 0.55;
  border: 1px solid rgba(255, 247, 231, 0.42);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(5, 10, 9, 0.04), rgba(5, 10, 9, 0.26)),
    var(--vibe-bg-image-1) 52% 38% / cover no-repeat;
  box-shadow: 0 28px 90px rgba(5, 10, 9, 0.14);
  content: "";
  opacity: 0.22;
  pointer-events: none;
  transform: rotate(2.5deg);
}

[data-vibe="brazil"] .story::before {
  background:
    linear-gradient(90deg, rgba(4, 14, 11, 0.08), rgba(4, 14, 11, 0.18)),
    var(--vibe-bg-image-1) 44% 61% / cover no-repeat;
}

[data-vibe="new-mexico"] .story::before {
  background:
    linear-gradient(90deg, rgba(16, 9, 5, 0.1), rgba(16, 9, 5, 0.18)),
    var(--vibe-bg-image-1) center / cover no-repeat;
}

[data-vibe="new-mexico"] .gallery {
  background:
    linear-gradient(180deg, rgba(255, 247, 231, 0.8), rgba(255, 247, 231, 0.48)),
    var(--paper);
}

[data-theme="dark"][data-vibe="new-mexico"] .gallery {
  background:
    linear-gradient(180deg, rgba(16, 23, 21, 0.86), rgba(16, 23, 21, 0.64)),
    var(--paper);
}

[data-vibe="new-mexico"] .gallery::before {
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    linear-gradient(90deg, rgba(255, 247, 231, 0.86), rgba(255, 247, 231, 0.44) 45%, rgba(255, 247, 231, 0.82)),
    var(--vibe-bg-image-3) center / cover fixed no-repeat;
  content: "";
  opacity: 0.48;
  pointer-events: none;
}

[data-theme="dark"][data-vibe="new-mexico"] .gallery::before {
  background:
    linear-gradient(90deg, rgba(16, 23, 21, 0.9), rgba(16, 23, 21, 0.46) 45%, rgba(16, 23, 21, 0.88)),
    var(--vibe-bg-image-3) center / cover fixed no-repeat;
  opacity: 0.44;
}

[data-vibe="brazil"] .gallery {
  background:
    linear-gradient(180deg, rgba(255, 247, 231, 0.88), rgba(255, 247, 231, 0.58)),
    var(--paper);
}

[data-theme="dark"][data-vibe="brazil"] .gallery {
  background:
    linear-gradient(180deg, rgba(16, 23, 21, 0.86), rgba(16, 23, 21, 0.66)),
    var(--paper);
}

[data-vibe="brazil"] .gallery::before {
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    linear-gradient(90deg, rgba(255, 247, 231, 0.88), rgba(255, 247, 231, 0.42) 45%, rgba(255, 247, 231, 0.84)),
    var(--vibe-bg-image-2) center / cover fixed no-repeat;
  content: "";
  opacity: 0.5;
  pointer-events: none;
}

[data-theme="dark"][data-vibe="brazil"] .gallery::before {
  background:
    linear-gradient(90deg, rgba(16, 23, 21, 0.9), rgba(16, 23, 21, 0.48) 45%, rgba(16, 23, 21, 0.86)),
    var(--vibe-bg-image-2) center / cover fixed no-repeat;
  opacity: 0.46;
}

[data-vibe="brazil"] .closing-signature {
  background:
    linear-gradient(90deg, rgba(47, 169, 107, 0.14), rgba(240, 201, 74, 0.16), rgba(38, 118, 211, 0.12)),
    var(--paper);
}

[data-vibe="brazil"] .closing-signature::after {
  position: absolute;
  inset: clamp(18px, 4vw, 42px);
  z-index: 0;
  border: 1px solid rgba(255, 247, 231, 0.22);
  border-radius: 8px;
  background:
    linear-gradient(90deg, rgba(255, 247, 231, 0.86), rgba(255, 247, 231, 0.48), rgba(255, 247, 231, 0.88)),
    var(--vibe-bg-image-3) 50% 44% / cover no-repeat;
  content: "";
  opacity: 0.34;
  pointer-events: none;
}

[data-theme="dark"][data-vibe="brazil"] .closing-signature::after {
  background:
    linear-gradient(90deg, rgba(16, 23, 21, 0.88), rgba(16, 23, 21, 0.44), rgba(16, 23, 21, 0.9)),
    var(--vibe-bg-image-3) 50% 44% / cover no-repeat;
  opacity: 0.38;
}

[data-vibe="brazil"] .closing-signature > * {
  position: relative;
  z-index: 1;
}

[data-vibe="brazil"] .closing-signature::before {
  position: relative;
  z-index: 1;
  color: var(--berry);
  content: "obrigado / que alegria / vamos celebrar";
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

[data-vibe="new-mexico"] .celebration {
  isolation: isolate;
  background:
    radial-gradient(circle at 84% 20%, rgba(45, 141, 152, 0.18), transparent 28%),
    linear-gradient(180deg, rgba(215, 164, 67, 0.18), rgba(45, 141, 152, 0.1)),
    var(--band-bg);
}

[data-vibe="new-mexico"] .celebration::before {
  position: absolute;
  right: max(18px, 5vw);
  top: clamp(34px, 8vw, 88px);
  z-index: 0;
  width: min(380px, 36vw);
  aspect-ratio: 1.72;
  border: 1px solid rgba(255, 247, 231, 0.34);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(5, 10, 9, 0.04), rgba(5, 10, 9, 0.28)),
    var(--vibe-bg-image-2) 52% 42% / cover no-repeat;
  box-shadow: 0 28px 90px rgba(5, 10, 9, 0.14);
  content: "";
  opacity: 0.22;
  pointer-events: none;
  transform: rotate(-2.4deg);
}

[data-vibe="new-mexico"] .closing-signature {
  background:
    linear-gradient(180deg, rgba(199, 93, 71, 0.16), rgba(215, 164, 67, 0.16)),
    var(--paper);
}

[data-vibe="new-mexico"] .closing-signature::after {
  position: absolute;
  inset: clamp(18px, 4vw, 42px);
  z-index: 0;
  border: 1px solid rgba(255, 247, 231, 0.2);
  border-radius: 8px;
  background:
    linear-gradient(90deg, rgba(255, 247, 231, 0.84), rgba(255, 247, 231, 0.46), rgba(255, 247, 231, 0.88)),
    var(--vibe-bg-image-4) center / cover no-repeat;
  content: "";
  opacity: 0.32;
  pointer-events: none;
}

[data-theme="dark"][data-vibe="new-mexico"] .closing-signature::after {
  background:
    linear-gradient(90deg, rgba(16, 23, 21, 0.9), rgba(16, 23, 21, 0.5), rgba(16, 23, 21, 0.9)),
    var(--vibe-bg-image-4) center / cover no-repeat;
  opacity: 0.36;
}

[data-vibe="new-mexico"] .closing-signature > * {
  position: relative;
  z-index: 1;
}

[data-vibe="new-mexico"] .closing-signature::before {
  position: relative;
  z-index: 1;
  color: var(--berry);
  content: "desert skies / mountain views / green chile optional";
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

[data-motion="fun"] .vibe-control {
  animation: controlsBob 6.4s ease-in-out 300ms infinite;
}

[data-motion="fun"] .envelope-card {
  animation: envelopeHover 4.8s ease-in-out infinite;
}

[data-motion="fun"] .polaroid-card {
  animation: polaroidDance 5.8s ease-in-out infinite;
  animation-delay: var(--polaroid-delay);
}

[data-motion="fun"] .closing-signature__text::after {
  color: var(--gold);
  content: "|";
  animation: cursorBlink 800ms steps(1) infinite;
}

[data-motion="fun"][data-vibe="brazil"] .closing-signature::before,
[data-motion="fun"][data-vibe="new-mexico"] .closing-signature::before {
  animation: phraseSlide 4.8s ease-in-out infinite;
}

body.is-mischief .page-wrap {
  animation: mischiefShake 420ms ease-in-out 2;
}

@keyframes envelopeHover {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }

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

@keyframes polaroidDance {
  0%,
  100% {
    transform: rotate(var(--polaroid-rotation)) translateY(0);
  }

  50% {
    transform: rotate(var(--polaroid-counter-rotation)) translateY(-7px);
  }
}

@keyframes cursorBlink {
  0%,
  49% {
    opacity: 1;
  }

  50%,
  100% {
    opacity: 0;
  }
}

@keyframes phraseSlide {
  0%,
  100% {
    transform: translateX(0);
  }

  50% {
    transform: translateX(12px);
  }
}

@keyframes mischiefShake {
  0%,
  100% {
    transform: translateX(0) rotate(0deg);
  }

  25% {
    transform: translateX(-8px) rotate(-0.25deg);
  }

  75% {
    transform: translateX(8px) rotate(0.25deg);
  }
}


@keyframes funSparkle {
  0% {
    opacity: 0;
    transform: translate3d(-50%, 24px, 0) scale(0.4) rotate(0deg);
  }

  18%,
  72% {
    opacity: 0.82;
  }

  100% {
    opacity: 0;
    transform: translate3d(calc(-50% + var(--drift-distance)), -86px, 0) scale(1.15) rotate(180deg);
  }
}

@keyframes funConfetti {
  0% {
    opacity: 0;
    transform: translate3d(-50%, -18vh, 0) rotate(0deg);
  }

  9%,
  82% {
    opacity: 0.72;
  }

  100% {
    opacity: 0;
    transform: translate3d(calc(-50% + var(--sway-distance)), 124vh, 0) rotate(var(--spin-deg));
  }
}

@keyframes funRibbon {
  0% {
    opacity: 0;
    transform: translate3d(-50%, -24vh, 0) rotate(-10deg) scaleY(0.78);
  }

  16%,
  72% {
    opacity: 0.34;
  }

  100% {
    opacity: 0;
    transform: translate3d(calc(-50% + var(--sway-distance)), 124vh, 0) rotate(16deg) scaleY(1.08);
  }
}

@keyframes funTrail {
  0% {
    opacity: 0.92;
    transform: translate3d(-50%, -50%, 0) scale(1) rotate(var(--trail-rotate));
  }

  100% {
    opacity: 0;
    transform: translate3d(-50%, -50%, 0) translateY(-34px) scale(0.24) rotate(var(--trail-rotate));
  }
}

@keyframes funBurst {
  0% {
    opacity: 0;
    transform: translate3d(-50%, -50%, 0) rotate(var(--burst-angle)) translateX(0) scale(0.2);
  }

  15% {
    opacity: 0.95;
  }

  100% {
    opacity: 0;
    transform: translate3d(-50%, -50%, 0) rotate(var(--burst-angle)) translateX(var(--burst-distance)) scale(1.22);
  }
}

@keyframes funUnderline {
  0%,
  100% {
    opacity: 0.56;
    transform: scaleX(0.46) translateX(0);
  }

  50% {
    opacity: 1;
    transform: scaleX(1) translateX(18px);
  }
}

@keyframes controlsBob {
  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(4px);
  }
}

@keyframes titleBreathe {
  0%,
  100% {
    transform: scale(1) rotate(0deg);
  }

  50% {
    transform: scale(1.018) rotate(-0.35deg);
  }
}

@keyframes messageFloat {
  0%,
  100% {
    transform: translateY(0);
  }

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

@keyframes softWiggle {
  0%,
  100% {
    transform: translateX(0);
  }

  50% {
    transform: translateX(7px);
  }
}

@keyframes signatureSway {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }

  50% {
    transform: translateY(-5px) rotate(-0.6deg);
  }
}

@keyframes tapeFlutter {
  0%,
  100% {
    transform: translateX(-50%) rotate(1.5deg);
  }

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

@keyframes superCueFloat {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }

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

@keyframes superRingPulse {
  0%,
  100% {
    box-shadow: 0 14px 32px rgba(0, 0, 0, 0.28), 0 0 0 0 rgba(90, 180, 170, 0.3);
  }

  50% {
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.32), 0 0 0 13px rgba(90, 180, 170, 0);
  }
}

@keyframes storyHeadlineGlow {
  0%,
  100% {
    text-shadow: 0 22px 62px rgba(0, 0, 0, 0.52), 0 0 0 rgba(215, 168, 73, 0);
  }

  50% {
    text-shadow: 0 26px 68px rgba(0, 0, 0, 0.56), 0 0 28px rgba(215, 168, 73, 0.24);
  }
}

@keyframes storyCopyFloat {
  0%,
  100% {
    translate: 0 0;
  }

  50% {
    translate: 0 -5px;
  }
}

@keyframes gratitudeWash {
  from {
    background-position: 47% 42%;
  }

  to {
    background-position: 53% 42%;
  }
}

@keyframes gratitudeNod {
  0%,
  100% {
    transform: rotate(0deg);
  }

  50% {
    transform: rotate(-0.55deg) translateY(-3px);
  }
}

@keyframes gratitudeTextLift {
  0%,
  100% {
    transform: translateY(0);
  }

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

@keyframes colorRibbon {
  0%,
  100% {
    opacity: 0.58;
    transform: scaleX(0.68);
  }

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

@keyframes photoDrift {
  from {
    transform: scale(1.035) translate3d(-0.8%, -0.45%, 0);
  }

  to {
    transform: scale(1.085) translate3d(1.1%, 0.65%, 0);
  }
}

@keyframes lightDrift {
  from {
    opacity: 0.88;
  }

  to {
    opacity: 1;
  }
}

@keyframes storyPhotoDrift {
  from {
    transform: scale(1.04) translate3d(-0.8%, -0.4%, 0);
  }

  to {
    transform: scale(1.085) translate3d(1.1%, 0.55%, 0);
  }
}

@keyframes storyShadeDrift {
  from {
    opacity: 0.9;
  }

  to {
    opacity: 1;
  }
}

@keyframes contentRise {
  from {
    opacity: 0;
    transform: translateY(18px);
  }

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

@keyframes storyLineLift {
  from {
    opacity: 0;
    transform: translateY(14px);
  }

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

@keyframes detailSweep {
  from {
    opacity: 0;
    transform: scaleX(0);
  }

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

@keyframes cueFloat {
  0%,
  100% {
    transform: translateY(0);
  }

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

@keyframes splashFloat {
  0%,
  100% {
    transform: translate3d(var(--splash-drag-x), var(--splash-drag-y), 0) rotate(calc(var(--splash-rotation) + var(--splash-drag-rotation)));
  }

  50% {
    transform: translate3d(var(--splash-drag-x), calc(var(--splash-drag-y) - 8px), 0) rotate(calc(var(--splash-rotation) + var(--splash-drag-rotation) + 0.45deg));
  }
}

@keyframes ringPulse {
  0%,
  100% {
    box-shadow: 0 14px 32px rgba(0, 0, 0, 0.28), 0 0 0 0 rgba(215, 168, 73, 0.18);
  }

  50% {
    box-shadow: 0 14px 32px rgba(0, 0, 0, 0.28), 0 0 0 9px rgba(215, 168, 73, 0);
  }
}

@keyframes lineGlow {
  0%,
  100% {
    opacity: 0.72;
  }

  50% {
    opacity: 1;
  }
}

@media (max-width: 760px) {
  .site-controls {
    position: absolute;
    left: 12px;
    right: 12px;
    grid-template-columns: 1fr;
  }

  .theme-toggle {
    min-width: 0;
  }

  .guest-splash {
    padding: 16px;
  }

  .guest-splash__card {
    width: min(100%, 560px);
    max-height: calc(100svh - 28px);
    transform: translateY(18px) scale(0.97) rotate(calc(var(--splash-rotation) - 0.5deg));
  }

  .guest-splash__card img {
    max-height: 56svh;
  }

  .guest-splash__close {
    top: 14px;
    right: 14px;
    width: 42px;
    height: 42px;
  }

  .hero {
    min-height: 100svh;
    align-items: end;
    padding: 28px 22px 86px;
  }

  .hero::before {
    background-position: 56% 62%;
  }

  .hero::after {
    background:
      radial-gradient(circle at 55% 56%, rgba(215, 168, 73, 0.2), rgba(215, 168, 73, 0) 26%),
      linear-gradient(180deg, rgba(5, 8, 8, 0.1) 0%, rgba(5, 10, 9, 0.62) 42%, rgba(5, 10, 9, 0.94) 100%);
  }

  h1 {
    max-width: 8.8ch;
  }

  .scroll-cue {
    right: auto;
    left: 22px;
    bottom: 24px;
  }

  .story__inner {
    width: min(100% - 32px, 640px);
    grid-template-columns: 1fr;
    gap: 22px;
    align-content: end;
  }

  .story::before {
    background-position: 44% 50%;
  }

  [data-vibe="brazil"] .celebration::before {
    right: 10px;
    top: 20px;
    width: min(190px, 38vw);
    opacity: 0.14;
  }

  [data-vibe="new-mexico"] .celebration::before {
    right: 10px;
    top: 20px;
    width: min(210px, 44vw);
    opacity: 0.14;
  }

  [data-vibe="brazil"] .story::before {
    background-position: 46% 58%;
  }

  [data-vibe="new-mexico"] .story::before {
    background-position: 48% 50%;
  }

  [data-vibe="brazil"] .gallery::before {
    background-attachment: scroll;
    opacity: 0.36;
  }

  [data-vibe="new-mexico"] .gallery::before {
    background-attachment: scroll;
    opacity: 0.34;
  }

  [data-vibe="brazil"] .closing-signature::after {
    inset: 12px;
    background-position: 42% 45%;
    opacity: 0.24;
  }

  [data-vibe="new-mexico"] .closing-signature::after {
    inset: 12px;
    background-position: 48% 50%;
    opacity: 0.24;
  }

  .story::after {
    background:
      linear-gradient(180deg, rgba(7, 9, 9, 0.5) 0%, rgba(7, 9, 9, 0.66) 42%, rgba(7, 9, 9, 0.95) 100%);
  }

  .story .section-kicker,
  .story h2,
  .story__copy {
    grid-column: 1;
  }

  .gratitude__inner {
    width: min(100% - 32px, 640px);
    grid-template-columns: 1fr;
  }

  .celebration__inner,
  .photo-upload__inner {
    width: min(100% - 32px, 640px);
    grid-template-columns: 1fr;
  }

  .celebration-actions {
    grid-column: 1;
  }

  .celebration-actions {
    display: grid;
  }

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

  .envelope-card {
    min-height: 310px;
  }
}

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