@font-face {
  font-family: Distrela;
  src: url("/fonts/Distrela.ttf") format("truetype");
  font-display: swap;
}

:root {
  --cream: #fdfbf7;
  --cream-2: #faf5f0;
  --cream-3: #f2eae1;
  --sage: #e2b4b1;
  --sage-dark: #ba7a76;
  --sage-deep: #8a4f4c;
  --sage-light: #f7dcda;
  --gold: #d4af37;
  --gold-light: #e8ce73;
  --text-dark: #2c2a29;
  --text-mid: #5a5552;
  --border: #f0e5db;
  --white: #fff;
  --shadow: 0 24px 64px -12px rgba(138, 79, 76, .12);
  --shadow-sm: 0 8px 24px rgba(138, 79, 76, .08);
  --font-display: "Distrela", "Italianno", cursive;
  --font-body: "Cormorant Garamond", Georgia, serif;
  --font-sans: "Tenor Sans", sans-serif;
  --font-script: "Italianno", cursive;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; overflow-x: clip; }
body {
  background: var(--cream);
  color: var(--text-dark);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
body.no-scroll {
  position: fixed;
  width: 100%;
  height: 100dvh;
  overflow: hidden;
  touch-action: none;
}
img, video { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; }
button { border: 0; background: transparent; cursor: pointer; }
a { color: inherit; text-decoration: none; }

.hidden { display: none !important; }

.entry-gate {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: #0a0506;
  cursor: pointer;
}
.entry-gate__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.entry-gate__overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    radial-gradient(circle at 50% 58%, transparent 24%, rgba(10, 5, 6, .48) 72%),
    linear-gradient(to bottom, rgba(0,0,0,.18), rgba(0,0,0,.52));
}
.entry-gate__particles {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
}
.particle {
  position: absolute;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--gold-light);
  opacity: 0;
  animation: twinkle var(--dur, 3s) var(--delay, 0s) infinite ease-in-out;
}
.entry-gate__content {
  position: relative;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.3rem;
  text-align: center;
}
.entry-gate__icon,
.hero-icon {
  width: 78px;
  height: 78px;
  object-fit: contain;
  filter: drop-shadow(0 8px 24px rgba(212,175,55,.42));
  animation: float 4s ease-in-out infinite;
}
.entry-gate__names {
  color: var(--gold-light);
  font-family: var(--font-display);
  font-size: clamp(3rem, 10vw, 5rem);
  line-height: 1.12;
  text-shadow: 0 2px 20px rgba(212,175,55,.5), 0 0 60px rgba(212,175,55,.15);
}
.entry-gate__amp {
  color: var(--sage-light);
  font-family: Tangerine, cursive;
  font-size: .78em;
  font-weight: 700;
}
.entry-gate__date {
  color: rgba(255,255,255,.72);
  font-family: var(--font-sans);
  font-size: .82rem;
  letter-spacing: .34em;
  text-transform: uppercase;
}
.entry-gate__hint {
  position: absolute;
  bottom: 12%;
  left: 50%;
  z-index: 4;
  transform: translateX(-50%);
  color: rgba(244, 227, 196, .9);
  font-family: var(--font-script);
  font-size: clamp(1.55rem, 5vw, 2.2rem);
  text-shadow: 0 2px 14px rgba(0,0,0,.45);
  white-space: nowrap;
  animation: hint-breathe 3.6s ease-in-out infinite;
}

.video-intro {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000;
  cursor: pointer;
}
.video-intro video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity .5s ease;
}
.video-intro.is-playing video {
  opacity: 1;
}
.video-intro__cover {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity .5s ease;
}
.video-intro.is-playing .video-intro__cover {
  opacity: 0;
}
.video-intro__overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,.5);
  transition: opacity .5s ease;
}
.video-intro__overlay.is-hidden {
  opacity: 0;
  pointer-events: none;
}
.video-intro__overlay span {
  color: #fff;
  font-family: var(--font-sans);
  font-size: 1.2rem;
  letter-spacing: .24em;
  text-transform: uppercase;
  animation: pulse 2s infinite;
}
.bright-flash {
  position: fixed;
  inset: 0;
  z-index: 10001;
  pointer-events: none;
  background: #fff;
  opacity: 0;
}
.bright-flash.active {
  animation: flashOut .7s ease forwards;
}

.petals-canvas {
  position: fixed;
  inset: 0;
  z-index: 9000;
  width: 100%;
  height: 100dvh;
  pointer-events: none;
  opacity: 0;
  transition: opacity 1.4s ease;
}
.petals-canvas.active {
  opacity: .72;
}

.audio-btn {
  position: fixed;
  right: 28px;
  bottom: 28px;
  z-index: 9500;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: var(--white);
  box-shadow: var(--shadow-sm);
  color: var(--sage-dark);
  transition: transform .35s ease;
}
.audio-btn:hover { transform: scale(1.08); }
.audio-icon {
  width: 22px;
  height: 22px;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill='black' d='M11 5 6 9H2v6h4l5 4V5Zm6 4.2 2.3-2.3 1.4 1.4-2.3 2.3 2.3 2.3-1.4 1.4L17 12l-2.3 2.3-1.4-1.4 2.3-2.3-2.3-2.3 1.4-1.4L17 9.2Z'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill='black' d='M11 5 6 9H2v6h4l5 4V5Zm6 4.2 2.3-2.3 1.4 1.4-2.3 2.3 2.3 2.3-1.4 1.4L17 12l-2.3 2.3-1.4-1.4 2.3-2.3-2.3-2.3 1.4-1.4L17 9.2Z'/%3E%3C/svg%3E") center / contain no-repeat;
}
.audio-btn.is-playing .audio-icon {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill='black' d='M11 5 6 9H2v6h4l5 4V5Zm4.54 3.46a5 5 0 0 1 0 7.08l1.41 1.41a7 7 0 0 0 0-9.9l-1.41 1.41Zm3.53-3.53a10 10 0 0 1 0 14.14l1.41 1.41a12 12 0 0 0 0-16.96l-1.41 1.41Z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill='black' d='M11 5 6 9H2v6h4l5 4V5Zm4.54 3.46a5 5 0 0 1 0 7.08l1.41 1.41a7 7 0 0 0 0-9.9l-1.41 1.41Zm3.53-3.53a10 10 0 0 1 0 14.14l1.41 1.41a12 12 0 0 0 0-16.96l-1.41 1.41Z'/%3E%3C/svg%3E");
}

#mainContent {
  visibility: hidden;
  opacity: 0;
  transition: opacity .8s ease;
}
#mainContent.visible {
  visibility: visible;
  opacity: 1;
}

.hero {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100dvh;
  padding: 3rem 1rem 6rem;
  overflow: hidden;
  background:
    radial-gradient(ellipse 120% 80% at 50% 0%, rgba(226, 180, 177, .18), transparent 65%),
    var(--cream-2);
}
.hero-corner {
  position: absolute;
  inset: 1.25rem;
  z-index: 1;
  pointer-events: none;
}
.hero-corner::before,
.hero-corner::after,
.hero-corner span::before,
.hero-corner span::after {
  content: "";
  position: absolute;
  width: 54px;
  height: 54px;
  border-style: solid;
  border-color: var(--gold);
  opacity: .68;
}
.hero-corner::before { top: 0; left: 0; border-width: 2px 0 0 2px; }
.hero-corner::after { top: 0; right: 0; border-width: 2px 2px 0 0; }
.hero-corner span::before { bottom: 0; left: 0; border-width: 0 0 2px 2px; }
.hero-corner span::after { right: 0; bottom: 0; border-width: 0 2px 2px 0; }
.hero-card {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.15rem;
  width: 100%;
  max-width: 620px;
  padding: clamp(1.5rem, 3vw, 2rem) clamp(1.75rem, 5vw, 2.5rem);
  text-align: center;
  background: rgba(253,251,247,.93);
  border: 1px solid rgba(212,175,55,.32);
  border-radius: 2.2rem;
  box-shadow: var(--shadow), 0 0 0 4px rgba(226,180,177,.15) inset;
  backdrop-filter: blur(18px);
}
.god-quote,
.intro-text,
.parent-sub {
  color: var(--sage-deep);
  font-size: 1.05rem;
  font-style: italic;
  line-height: 1.55;
}
.intro-text { color: var(--sage-dark); font-size: 1.12rem; }
.parent-sub { max-width: 92%; color: var(--text-mid); font-weight: 500; }
h1 { display: contents; }
.couple-name {
  display: block;
  width: 100%;
  color: var(--sage-deep);
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 12vw, 5.2rem);
  font-weight: 400;
  line-height: 1.2;
}
.shimmer {
  background: linear-gradient(105deg, var(--sage-deep) 15%, var(--sage-dark) 30%, var(--sage) 45%, var(--sage-light) 55%, var(--sage-dark) 70%, var(--sage-deep) 85%);
  background-size: 200%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: shimmer 4.5s linear infinite;
}
.amp-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  width: 100%;
}
.amp-row i {
  width: 44px;
  height: 1px;
  background: var(--border);
}
.amp-row b {
  color: var(--gold);
  font-family: Tangerine, cursive;
  font-size: 2.6rem;
  line-height: 1;
}
.scroll-indicator {
  position: absolute;
  bottom: 2.5rem;
  left: 50%;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: var(--sage-dark);
  transform: translateX(-50%);
  animation: fadeIn 1.5s 1.5s forwards;
  opacity: 0;
}
.scroll-indicator span {
  font-family: var(--font-sans);
  font-size: .7rem;
  letter-spacing: .25em;
  text-transform: uppercase;
}
.scroll-indicator svg {
  width: 20px;
  height: 20px;
  animation: bounce 2s infinite;
}

.scratch-section {
  display: flex;
  min-height: 100vh;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 5rem 1rem;
  text-align: center;
  background: var(--cream);
}
.scratch-title-sub,
.sec-label {
  display: block;
  margin-bottom: .6rem;
  color: var(--gold);
  font-family: var(--font-sans);
  font-size: .78rem;
  letter-spacing: .35em;
  text-align: center;
  text-transform: uppercase;
}
.scratch-title,
.sec-heading {
  color: var(--sage-deep);
  font-family: var(--font-display);
  font-size: clamp(3.2rem, 12vw, 4.8rem);
  font-weight: 400;
  line-height: 1.05;
  text-align: center;
}
.scratch-desc {
  margin: .6rem auto 3.5rem;
  max-width: 420px;
  color: var(--text-mid);
  font-size: 1.15rem;
  font-style: italic;
  line-height: 1.6;
  text-align: center;
}
.scratch-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.5rem;
}
.scratch-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}
.scratch-label {
  color: var(--sage-dark);
  font-family: var(--font-sans);
  font-size: .85rem;
  letter-spacing: .3em;
  text-transform: uppercase;
}
.scratch-card-wrapper {
  position: relative;
  display: flex;
  width: 140px;
  height: 190px;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 15px 35px rgba(138,79,76,.15);
  animation: floatCard 4s ease-in-out infinite;
}
.scratch-item:nth-child(2) .scratch-card-wrapper { animation-delay: .5s; }
.scratch-item:nth-child(3) .scratch-card-wrapper { animation-delay: 1s; }
.scratch-card-wrapper.wiggling { animation: wiggle 1.8s ease-in-out infinite; }
.scratch-value {
  color: var(--sage-deep);
  font-family: var(--font-body);
  font-size: 3rem;
  font-weight: 500;
}
.scratch-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  cursor: crosshair;
  touch-action: none;
}
.scratch-hint {
  color: var(--sage-dark);
  font-family: var(--font-sans);
  font-size: .65rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  transition: opacity .4s ease;
}
.scratch-hint.hidden { opacity: 0; }

.locked-content { display: none; }
.locked-content.unlocked { display: block; }
.countdown-section,
.events-section,
.rsvp-section,
.share-section {
  padding: 5rem 1.5rem;
  background: var(--cream);
}
.countdown-section { background: var(--cream); }
.cd-card,
.event-card,
.rsvp-form {
  width: 100%;
  max-width: 460px;
  margin: 0 auto;
}
.cd-card {
  padding: 3rem 2rem;
  text-align: center;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 2.2rem;
  box-shadow: var(--shadow);
}
.cd-quote {
  margin-bottom: .5rem;
  color: var(--text-mid);
  font-size: 1.15rem;
  font-style: italic;
  line-height: 1.65;
}
.cd-script {
  display: block;
  margin-bottom: .25rem;
  color: var(--sage-dark);
  font-family: var(--font-display);
  font-size: 2.2rem;
}
.cd-date {
  display: block;
  margin: 1.25rem 0 2.5rem;
  color: var(--sage-deep);
  font-family: var(--font-sans);
  font-size: .82rem;
  letter-spacing: .22em;
  text-transform: uppercase;
}
.cd-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: .6rem;
}
.cd-grid strong {
  display: block;
  color: var(--text-dark);
  font-size: clamp(2.4rem, 8vw, 3.4rem);
  font-weight: 300;
  line-height: 1;
}
.cd-grid span {
  color: var(--sage-deep);
  font-family: var(--font-sans);
  font-size: .68rem;
  letter-spacing: .16em;
  text-transform: uppercase;
}
.event-card {
  display: grid;
  gap: 1.5rem;
  margin-top: 3rem;
}
.evt-details {
  display: flex;
  min-height: 230px;
  flex-direction: column;
  justify-content: center;
  padding: 2.3rem 2rem;
  text-align: center;
  background: #fff;
  border: 1px solid rgba(200,160,110,.15);
  border-radius: 1rem;
  box-shadow: 0 4px 24px rgba(0,0,0,.04);
}
.evt-label {
  margin-bottom: 1rem;
  color: #c9a270;
  font-family: var(--font-sans);
  font-size: .72rem;
  letter-spacing: .26em;
  text-transform: uppercase;
}
.evt-details h3 {
  margin-bottom: .6rem;
  color: #2c1e16;
  font-size: 1.55rem;
  font-weight: 500;
  line-height: 1.3;
}
.evt-details p {
  color: #635249;
  font-size: 1.05rem;
  font-style: italic;
  line-height: 1.55;
}
.evt-dir-btn,
.venue-btn,
.intro-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: center;
  margin-top: 1.5rem;
  padding: .9rem 1.8rem;
  color: #fff;
  font-family: var(--font-sans);
  font-size: .78rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  background: var(--sage-deep);
  border-radius: 999px;
  box-shadow: 0 4px 15px rgba(138,79,76,.25);
  transition: transform .2s ease, filter .2s ease;
}
.evt-dir-btn:hover,
.venue-btn:hover,
.intro-btn:hover {
  transform: translateY(-2px);
  filter: brightness(1.08);
}
.rsvp-section { text-align: center; }
.rsvp-form {
  display: grid;
  gap: 1rem;
  text-align: left;
}
.rsvp-form .evt-details {
  align-items: stretch;
  gap: 1.2rem;
  min-height: 0;
  text-align: left;
}
label {
  display: grid;
  gap: .45rem;
  color: var(--sage-deep);
  font-family: var(--font-sans);
  font-size: .74rem;
  font-weight: 600;
  letter-spacing: .15em;
  text-transform: uppercase;
}
input,
select,
textarea {
  width: 100%;
  padding: .7rem 0;
  color: #333;
  border: 0;
  border-bottom: 1px solid #dcd1c4;
  background: transparent;
  outline: none;
  font-family: var(--font-body);
  font-size: 1.1rem;
  letter-spacing: 0;
  text-transform: none;
}
textarea {
  min-height: 90px;
  resize: vertical;
  border: 1px solid #dcd1c4;
  border-radius: .6rem;
  padding: .9rem;
}
.intro-btn {
  width: 100%;
  margin-top: .5rem;
  padding: 1.1rem;
  border: 0;
}
.form-status {
  min-height: 24px;
  text-align: center;
  color: var(--sage-deep);
  font-size: 1rem;
}
.share-section {
  text-align: center;
  background: var(--cream-2);
}
.share-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .8rem;
  margin-top: 2rem;
}
.venue-btn { margin-top: 0; border: 0; }
.venue-btn--ghost {
  color: var(--sage-deep);
  background: #fff;
  border: 1px solid var(--sage-deep);
}
footer {
  padding: 5rem 1.5rem 3rem;
  text-align: center;
  background: var(--sage-deep);
}
footer p {
  max-width: 580px;
  margin: 0 auto 2.5rem;
  color: var(--cream-2);
  font-size: 1.2rem;
  font-style: italic;
  line-height: 1.7;
}
footer span {
  display: block;
  margin-bottom: 1rem;
  color: var(--gold-light);
  font-family: var(--font-sans);
  font-size: .75rem;
  letter-spacing: .25em;
  text-transform: uppercase;
}
footer strong {
  display: block;
  color: var(--gold-light);
  font-family: var(--font-display);
  font-size: clamp(3.5rem, 10vw, 5rem);
  font-weight: 400;
  line-height: 1.1;
}

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .8s ease, transform .8s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}
@keyframes twinkle {
  0%, 100% { opacity: 0; transform: scale(.5); }
  50% { opacity: .8; transform: scale(1.2); }
}
@keyframes hint-breathe {
  0%, 100% { opacity: .55; transform: translateX(-50%) translateY(0); }
  50% { opacity: .95; transform: translateX(-50%) translateY(-3px); }
}
@keyframes pulse {
  0%, 100% { opacity: .55; }
  50% { opacity: 1; }
}
@keyframes flashOut {
  0% { opacity: 0; }
  16% { opacity: 1; }
  100% { opacity: 0; }
}
@keyframes shimmer {
  to { background-position: 200%; }
}
@keyframes fadeIn {
  to { opacity: 1; }
}
@keyframes bounce {
  0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
  40% { transform: translateY(-8px); }
  60% { transform: translateY(-4px); }
}
@keyframes floatCard {
  0%, 100% { transform: translateY(0) rotate(0); box-shadow: 0 15px 35px rgba(138,79,76,.15); }
  50% { transform: translateY(-15px) rotate(2deg); box-shadow: 0 25px 45px rgba(138,79,76,.25); }
}
@keyframes wiggle {
  0%, 100% { transform: rotate(0); }
  15% { transform: rotate(-3deg); }
  30% { transform: rotate(2.5deg); }
  45% { transform: rotate(-2deg); }
  60% { transform: rotate(1.5deg); }
  75% { transform: rotate(-1deg); }
  90% { transform: rotate(.5deg); }
}

@media (max-width: 700px) {
  .audio-btn {
    right: 18px;
    bottom: 18px;
  }
  .hero-card {
    border-radius: 1.6rem;
  }
  .scratch-grid {
    gap: 1rem;
  }
  .scratch-card-wrapper {
    width: 104px;
    height: 146px;
  }
  .scratch-value {
    font-size: 2.25rem;
  }
  .cd-grid {
    gap: .35rem;
  }
  .cd-grid span {
    font-size: .55rem;
    letter-spacing: .1em;
  }
}
