:root {
  --sage: #687f5b;
  --sage-deep: #42563a;
  --sage-soft: #dfe7d7;
  --rose: #d98994;
  --rose-soft: #f7d6d9;
  --ivory: #fffaf2;
  --paper: #f8efe4;
  --ink: #2f2924;
  --muted: #76695f;
  --line: rgba(66, 86, 58, 0.18);
  --shadow: 0 24px 70px rgba(60, 46, 37, 0.16);
  --radius: 8px;
  --font-heading: "Great Vibes", "Marck Script", cursive;
  --font-body: Georgia, "Times New Roman", serif;
  --font-script: "Great Vibes", "Marck Script", cursive;
  --font-serif: Georgia, "Times New Roman", serif;
  --font-sans: "Montserrat", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--ivory);
  line-height: 1.6;
}

body:not(.invite-open) {
  overflow: hidden;
}

body.invite-open .intro {
  transform: translateY(-100%);
  opacity: 0;
  pointer-events: none;
}

img {
  display: block;
  max-width: 100%;
}
button,
input,
textarea {
  font: inherit;
}
button,
a {
  -webkit-tap-highlight-color: transparent;
}
a {
  color: inherit;
  text-decoration: none;
}

.site-shell {
  min-height: 100vh;
}

.intro {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 28px;
  color: var(--ivory);
  overflow: hidden;
  background: #2f2924;
  transition:
    transform 900ms cubic-bezier(0.8, 0, 0.2, 1),
    opacity 700ms ease;
}

.intro__media {
  position: absolute;
  inset: 0;
}
.intro__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(47, 41, 36, 0.48),
    rgba(47, 41, 36, 0.82)
  );
}
.intro__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  animation: introDrift 16s ease-in-out infinite alternate;
}

.intro__content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 760px;
  padding-bottom: 150px;
  animation: floatIn 900ms ease both 180ms;
  text-shadow: 0 4px 28px rgba(0, 0, 0, 0.42);
}

.eyebrow {
  margin: 0 0 28px;
  font-family: var(--font-sans);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
  color: var(--sage-deep);
}
.intro .eyebrow {
  color: var(--rose-soft);
}

h1,
h2,
p {
  margin-top: 0;
}
h1 {
  margin-bottom: 12px;
  font-family: var(--font-heading);
  font-size: clamp(4rem, 13vw, 9rem);
  line-height: 1.1;
  font-weight: 400;
}
h1 span {
  color: var(--rose-soft);
}
h2 {
  font-family: var(--font-heading);
  font-size: clamp(3.4rem, 6vw, 5.6rem);
  line-height: 0.98;
  font-weight: 400;
}
.intro__date {
  margin-bottom: 30px;
  font-family: var(--font-sans);
  font-size: clamp(1rem, 2.5vw, 1.35rem);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 13px 22px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  cursor: pointer;
  font-family: var(--font-sans);
  font-weight: 700;
  transition:
    transform 180ms ease,
    background 180ms ease,
    border-color 180ms ease,
    opacity 180ms ease;
}
.button:hover {
  transform: translateY(-1px);
}
.button:disabled {
  cursor: not-allowed;
  opacity: 0.58;
}
.button--primary {
  background: var(--sage-deep);
  color: var(--ivory);
  box-shadow: 0 12px 28px rgba(66, 86, 58, 0.18);
}
.button--ghost {
  border-color: var(--line);
  color: var(--sage-deep);
  background: rgba(255, 250, 242, 0.7);
}

.envelope {
  position: absolute;
  bottom: 52px;
  left: 50%;
  width: min(360px, 76vw);
  aspect-ratio: 1.55 / 1;
  transform: translateX(-50%);
  perspective: 1000px;
  animation: envelopePulse 3.8s ease-in-out infinite;
}
.envelope__back,
.envelope__front,
.envelope__flap,
.envelope__card {
  position: absolute;
  inset: 0;
  border-radius: var(--radius);
}
.envelope__back {
  background: #b08061;
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.32);
}
.envelope__card {
  inset: 10% 9% 18%;
  display: grid;
  place-items: center;
  color: var(--sage-deep);
  background: var(--paper);
  transform: translateY(15%);
  transition: transform 900ms ease 180ms;
}
.envelope__front {
  background: linear-gradient(145deg, #b98767 0 50%, #a87355 50%);
  clip-path: polygon(0 32%, 50% 68%, 100% 32%, 100% 100%, 0 100%);
}
.envelope__flap {
  transform-origin: top;
  background: #c19373;
  clip-path: polygon(0 0, 100% 0, 50% 68%);
  transition: transform 900ms ease;
}
body.invite-open .envelope__flap {
  transform: rotateX(180deg);
}
body.invite-open .envelope__card {
  transform: translateY(-38%);
}

.music-toggle {
  position: fixed;
  top: 14px;
  right: 18px;
  z-index: 30;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 8px 13px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--sage-deep);
  background: rgba(255, 250, 242, 0.92);
  backdrop-filter: blur(16px);
  cursor: pointer;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  box-shadow: 0 10px 30px rgba(60, 46, 37, 0.12);
}
.music-toggle__icon {
  width: 12px;
  height: 12px;
  border-radius: 999px;
  background: var(--rose);
  box-shadow: 0 0 0 5px rgba(217, 137, 148, 0.2);
}
.music-toggle[aria-pressed="true"] .music-toggle__icon {
  background: var(--sage);
  box-shadow: 0 0 0 5px rgba(104, 127, 91, 0.22);
  animation: pulseDot 1.8s ease-in-out infinite;
}

.invite {
  position: relative;
  outline: none;
  background:
    radial-gradient(
      circle at 5% 8%,
      rgba(247, 214, 217, 0.46),
      transparent 24rem
    ),
    linear-gradient(180deg, var(--ivory), #f7f0e9 45%, var(--ivory));
}

.section-band,
.section-grid,
.journey-section {
  position: relative;
  z-index: 2;
  width: min(100%, 1440px);
  margin-inline: auto;
  padding: clamp(64px, 9vw, 122px) clamp(18px, 5vw, 72px);
}
.hero,
.venue,
.dresscode,
.rsvp,
.flower-fund,
.photo-share,
.seating,
.finale {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.85fr);
  gap: clamp(28px, 6vw, 80px);
  align-items: center;
}
.hero {
  min-height: 100vh;
}
.hero__copy,
.venue__copy,
.finale__copy,
.section-heading {
  max-width: 760px;
}
.hero__copy p,
.venue__copy p,
.finale__copy p,
.section-heading p {
  color: var(--muted);
  font-size: 1.08rem;
}
.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}
.hero__image,
.venue__image,
.finale__image {
  overflow: hidden;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  background: var(--paper);
}
.hero__image img,
.venue__image img,
.finale__image img {
  width: 100%;
  height: min(660px, 72vh);
  object-fit: cover;
  transform: translateY(calc(var(--parallax, 0) * -18px)) scale(1.035);
}
.parallax-card {
  transition: transform 500ms ease;
}

.details,
.timeline,
.wishlist {
  display: grid;
  grid-template-columns: minmax(260px, 0.75fr) minmax(0, 1fr);
  gap: clamp(28px, 6vw, 72px);
}
.detail-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.detail-card {
  min-height: 190px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.58);
  box-shadow: 0 12px 30px rgba(60, 46, 37, 0.06);
}
.detail-card__label {
  display: block;
  margin-bottom: 18px;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  color: var(--rose);
  text-transform: uppercase;
}
.detail-card strong {
  display: block;
  margin-bottom: 10px;
  font-size: 1.45rem;
  line-height: 1.1;
  color: var(--sage-deep);
}
.detail-card p {
  margin-bottom: 0;
  color: var(--muted);
}
.countdown {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 14px;
}
.countdown span {
  display: grid;
  place-items: center;
  min-height: 72px;
  border-radius: var(--radius);
  background: rgba(255, 250, 242, 0.82);
}
.countdown strong {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 1.35rem;
}
.countdown small {
  font-family: var(--font-sans);
  color: var(--muted);
}

.venue {
  grid-template-columns: minmax(280px, 0.9fr) minmax(0, 1fr);
  background: var(--sage-soft);
}

.journey-section {
  background: linear-gradient(
    180deg,
    rgba(255, 250, 242, 0.8),
    rgba(247, 214, 217, 0.42)
  );
}
.timeline-road {
  position: relative;
  display: grid;
  gap: 26px;
  margin: 0;
  padding: 18px 0;
  list-style: none;
}
.timeline-road::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 54px;
  border-radius: 999px;
  background: repeating-linear-gradient(
    to bottom,
    rgba(66, 86, 58, 0.2) 0 22px,
    rgba(66, 86, 58, 0.06) 22px 42px
  );
  transform: translateX(-50%);
}
.timeline-road li {
  position: relative;
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  align-items: center;
  width: min(520px, calc(50% - 42px));
  min-height: 112px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 250, 242, 0.86);
  box-shadow: var(--shadow);
  transform: translateY(28px);
  opacity: 0;
  transition:
    opacity 600ms ease,
    transform 600ms ease;
}
.timeline-road li:nth-child(odd) {
  justify-self: start;
}
.timeline-road li:nth-child(even) {
  justify-self: end;
}
.timeline-road li::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 18px;
  height: 18px;
  border: 4px solid var(--ivory);
  border-radius: 50%;
  background: var(--rose);
  box-shadow: 0 0 0 9px rgba(217, 137, 148, 0.14);
}
.timeline-road li:nth-child(odd)::after {
  right: -60px;
}
.timeline-road li:nth-child(even)::after {
  left: -60px;
}
.timeline-road time {
  font-family: var(--font-sans);
  font-weight: 800;
  color: var(--sage-deep);
}
.timeline-road strong {
  display: block;
  margin-bottom: 4px;
  color: var(--ink);
}
.timeline-road span {
  color: var(--muted);
}
.timeline-road li.is-visible {
  transform: translateY(0);
  opacity: 1;
}

.dresscode {
  grid-template-columns: minmax(260px, 0.7fr) minmax(0, 1fr);
  background: #f8e7e7;
}
.swatches {
  display: grid;
  grid-template-columns: repeat(5, minmax(84px, 1fr));
  gap: 14px;
  align-items: center;
}
.swatches span {
  display: grid;
  place-items: center;
  justify-self: center;
  width: min(100%, 168px);
  aspect-ratio: 1;
  padding: 14px;
  border-radius: 50%;
  color: #fff;
  background: var(--swatch);
  box-shadow: 0 12px 26px rgba(60, 46, 37, 0.12);
  font-family: var(--font-sans);
  font-weight: 700;
  text-align: center;
}
.swatches span:last-child {
  color: var(--ink);
  border: 1px solid var(--line);
}

.flower-fund {
  background: var(--sage-soft);
}
.flower-card {
  padding: clamp(22px, 4vw, 38px);
  border-radius: var(--radius);
  background: var(--ivory);
  box-shadow: var(--shadow);
}
.flower-card__mark {
  display: inline-grid;
  place-items: center;
  width: 70px;
  height: 70px;
  margin-bottom: 20px;
  border-radius: 50%;
  color: var(--ivory);
  background: linear-gradient(145deg, var(--sage), var(--rose));
  font-family: var(--font-sans);
  font-weight: 800;
}
.flower-card strong {
  display: block;
  margin-bottom: 10px;
  font-size: 1.8rem;
  color: var(--sage-deep);
}
.flower-card p {
  color: var(--muted);
}
.location-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.photo-share {
  background: linear-gradient(180deg, var(--ivory), #f8e7e7);
}

.seating {
  background: var(--sage-soft);
}

.info-card {
  display: grid;
  gap: 14px;
  padding: clamp(22px, 4vw, 38px);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 250, 242, 0.88);
  box-shadow: var(--shadow);
}

.info-card strong {
  font-family: var(--font-heading);
  font-size: clamp(2.2rem, 5vw, 3.8rem);
  font-weight: 500;
  color: var(--sage-deep);
}

.info-card p {
  margin: 0;
  color: var(--muted);
}

.seating-card {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  min-height: 280px;
  align-content: center;
  background:
    radial-gradient(
      circle at center,
      rgba(217, 137, 148, 0.16),
      transparent 46%
    ),
    rgba(255, 250, 242, 0.9);
}

.seating-card span {
  display: grid;
  place-items: center;
  min-height: 86px;
  border: 1px dashed rgba(66, 86, 58, 0.28);
  border-radius: 999px;
  color: var(--sage-deep);
  font-family: var(--font-sans);
  font-weight: 700;
  background: rgba(255, 255, 255, 0.58);
}

.wishlist-guest {
  margin-bottom: 16px;
}
.wishlist-guest label {
  display: grid;
  gap: 8px;
}
.wishlist-guest span,
.rsvp-form span,
.rsvp-form legend {
  font-family: var(--font-sans);
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--sage-deep);
}
.wishlist-guest input,
.rsvp-form input[type="text"],
.rsvp-form input[type="number"],
.rsvp-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 13px 14px;
  color: var(--ink);
  background: #fff;
  outline: none;
}
.wishlist-guest input:focus,
.rsvp-form input:focus,
.rsvp-form textarea:focus {
  border-color: var(--sage);
  box-shadow: 0 0 0 4px rgba(104, 127, 91, 0.12);
}
.wishlist-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.wishlist-card {
  display: grid;
  gap: 12px;
  min-height: 210px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.64);
  box-shadow: 0 14px 36px rgba(60, 46, 37, 0.08);
}
.wishlist-card h3 {
  margin: 0;
  font-size: 1.45rem;
  line-height: 1.15;
  font-weight: 400;
}
.wishlist-card p {
  margin: 0;
  color: var(--muted);
}
.status-pill {
  justify-self: start;
  padding: 5px 9px;
  border-radius: 999px;
  background: var(--rose-soft);
  color: #8e4a55;
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 700;
}
.status-pill.is-free {
  background: var(--sage-soft);
  color: var(--sage-deep);
}
.status-pill.is-confirmed {
  background: var(--sage-deep);
  color: var(--ivory);
}
.inline-link {
  display: inline-flex;
  margin-top: 12px;
  color: var(--sage-deep);
  font-family: var(--font-sans);
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.rsvp {
  grid-template-columns: minmax(260px, 0.8fr) minmax(280px, 0.9fr);
  background: var(--sage-soft);
}
.rsvp-form {
  display: grid;
  gap: 16px;
  padding: clamp(20px, 4vw, 34px);
  border-radius: var(--radius);
  background: var(--ivory);
  box-shadow: var(--shadow);
}
.rsvp-form label,
.rsvp-form fieldset {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  border: 0;
}
.radio-row {
  grid-template-columns: 20px minmax(0, 1fr);
  align-items: center;
  min-height: 34px;
}
.radio-row input {
  accent-color: var(--sage-deep);
}
.form-status {
  min-height: 26px;
  margin: 0;
  color: var(--sage-deep);
  font-family: var(--font-sans);
  font-size: 0.94rem;
}
.form-status.is-error {
  color: #9a3f42;
}

.finale {
  background: linear-gradient(180deg, #f8e7e7, var(--ivory));
}
.finale__image img {
  height: min(720px, 78vh);
  object-position: center;
}

[data-reveal] {
  opacity: 0;
  transform: translateY(36px);
  transition:
    opacity 800ms ease,
    transform 800ms ease;
}
[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}
[data-reveal].is-visible .parallax-card {
  animation: softLift 900ms ease both;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

@keyframes introDrift {
  from {
    transform: scale(1);
  }
  to {
    transform: scale(1.06) translateY(-1.5%);
  }
}
@keyframes floatIn {
  from {
    opacity: 0;
    transform: translateY(22px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes envelopePulse {
  0%,
  100% {
    transform: translateX(-50%) translateY(0);
  }
  50% {
    transform: translateX(-50%) translateY(-8px);
  }
}
@keyframes pulseDot {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.28);
  }
}
@keyframes softLift {
  from {
    transform: translateY(18px) scale(0.985);
  }
  to {
    transform: translateY(0) scale(1);
  }
}

@media (max-width: 980px) {
  .hero,
  .venue,
  .dresscode,
  .rsvp,
  .flower-fund,
  .photo-share,
  .seating,
  .finale,
  .details,
  .timeline,
  .wishlist {
    grid-template-columns: 1fr;
  }
  .hero {
    min-height: auto;
  }
  .venue__image {
    order: 2;
  }
  .detail-list,
  .wishlist-grid {
    grid-template-columns: 1fr;
  }
  .swatches {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .timeline-road::before {
    left: 18px;
    transform: none;
    width: 26px;
  }
  .timeline-road li {
    width: calc(100% - 52px);
    margin-left: 52px;
  }
  .timeline-road li:nth-child(even),
  .timeline-road li:nth-child(odd) {
    justify-self: stretch;
  }
  .timeline-road li:nth-child(even)::after,
  .timeline-road li:nth-child(odd)::after {
    left: -44px;
    right: auto;
  }
}

@media (max-width: 560px) {
  .intro {
    padding: 18px;
  }
  .intro__content {
    padding-bottom: 118px;
  }
  .music-toggle {
    top: 10px;
    right: 10px;
  }
  .section-band,
  .section-grid,
  .journey-section {
    padding-inline: 16px;
  }
  h2 {
    font-size: 3.5rem;
    line-height: 1.02;
  }
  .eyebrow {
    font-size: 0.7rem;
  }
  .hero__actions {
    display: grid;
  }
  .button {
    width: 100%;
  }
  .swatches span {
    width: min(100%, 138px);
    min-height: 0;
  }
  .swatches span:last-child {
    grid-column: 1 / -1;
  }
  .countdown {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .timeline-road li {
    grid-template-columns: 74px minmax(0, 1fr);
    width: calc(100% - 38px);
    margin-left: 38px;
    padding: 16px;
  }
  .timeline-road li:nth-child(even)::after,
  .timeline-road li:nth-child(odd)::after {
    left: -36px;
  }
}

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

.info-card .plain-title {
  font-family: var(--font-body);
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 400;
}
