:root {
  --bg: #fbf7ef;
  --paper: #fffdf8;
  --cream: #f4ead8;
  --sage: #94aa62;
  --olive: #617a36;
  --forest: #174633;
  --forest-soft: #28634a;
  --gold: #b49352;
  --brown: #7a4f35;
  --blue: #386a83;
  --purple: #6f5688;
  --heather: #7d6f83;
  --ink: #1f3228;
  --muted: #64746a;
  --line: #ded2bd;
  --shadow: 0 18px 44px rgba(31, 50, 40, 0.13);
  --soft-shadow: 0 10px 28px rgba(31, 50, 40, 0.09);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(90deg, rgba(56, 106, 131, 0.04) 1px, transparent 1px),
    linear-gradient(180deg, rgba(111, 86, 136, 0.035) 1px, transparent 1px),
    var(--bg);
  background-size: 44px 44px;
  font-family: "DM Sans", "Segoe UI", sans-serif;
  line-height: 1.6;
}

body.nav-open {
  overflow: hidden;
}

h1,
h2,
h3,
.brand {
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  line-height: 1.05;
  font-weight: 700;
}

h1 {
  font-size: clamp(4rem, 14vw, 8.8rem);
  letter-spacing: 0;
}

h2 {
  font-size: clamp(2.25rem, 6vw, 4rem);
}

h3 {
  font-size: 1.45rem;
}

p {
  margin: 0;
}

a {
  color: inherit;
}

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

.wrap {
  width: min(1160px, calc(100% - 32px));
  margin: 0 auto;
}

.section {
  padding: clamp(4rem, 9vw, 7rem) 0;
}

.section-anchor {
  scroll-margin-top: 92px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid rgba(222, 210, 189, 0.82);
  background: rgba(251, 247, 239, 0.9);
  backdrop-filter: blur(18px);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 76px;
}

.brand {
  display: inline-flex;
  align-items: baseline;
  gap: 0.28rem;
  color: var(--forest);
  font-size: clamp(1.65rem, 4vw, 2.15rem);
  text-decoration: none;
  white-space: nowrap;
}

.nav ul {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: clamp(0.55rem, 1.4vw, 1.05rem);
  padding: 0;
  margin: 0;
  list-style: none;
}

.nav a {
  text-decoration: none;
}

.nav ul a:not(.button) {
  color: var(--forest);
  font-size: 0.91rem;
  font-weight: 700;
}

.nav ul a:not(.button):hover,
.nav ul a:not(.button):focus-visible {
  color: var(--blue);
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  cursor: pointer;
}

.nav-toggle span:not(.sr-only) {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  background: var(--forest);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  border: 1px solid var(--forest);
  border-radius: 999px;
  padding: 0.78rem 1.25rem;
  background: var(--forest);
  color: #fffdf8;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition:
    transform 160ms ease,
    box-shadow 160ms ease,
    background 160ms ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-2px);
  background: #0f3526;
  box-shadow: var(--soft-shadow);
}

.button-small {
  min-height: 38px;
  padding: 0.52rem 0.9rem;
  font-size: 0.86rem;
}

.button-ghost {
  background: rgba(255, 253, 248, 0.2);
  color: #fffdf8;
  border-color: rgba(255, 253, 248, 0.8);
}

.button-ghost:hover,
.button-ghost:focus-visible {
  background: rgba(255, 253, 248, 0.96);
  color: var(--forest);
}

.hero {
  position: relative;
  display: grid;
  min-height: calc(100vh - 76px);
  overflow: hidden;
  color: #fffdf8;
}

.hero-media {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(15, 53, 38, 0.82), rgba(40, 99, 74, 0.34)),
    linear-gradient(180deg, rgba(56, 106, 131, 0.24), rgba(111, 86, 136, 0.18), rgba(15, 53, 38, 0.74)),
    url("https://images.unsplash.com/photo-1519167758481-83f29c8f23e6?auto=format&fit=crop&w=2200&q=80");
  background-position: center;
  background-size: cover;
  transform: scale(1.02);
}

.hero::after {
  position: absolute;
  right: clamp(1rem, 5vw, 4rem);
  bottom: clamp(1rem, 5vw, 4rem);
  width: min(340px, 46vw);
  height: min(340px, 46vw);
  border: 1px solid rgba(245, 216, 145, 0.42);
  border-radius: 50%;
  content: "";
}

.hero-polaroid {
  position: absolute;
  right: clamp(1rem, 7vw, 5.5rem);
  bottom: clamp(1.2rem, 8vw, 5rem);
  z-index: 2;
  width: min(290px, 24vw);
  padding: 0.72rem 0.72rem 0.95rem;
  margin: 0;
  border: 1px solid rgba(245, 216, 145, 0.48);
  border-radius: 8px;
  background: rgba(255, 253, 248, 0.9);
  box-shadow: 0 22px 50px rgba(8, 26, 18, 0.28);
  color: var(--forest);
  transform: rotate(2deg);
}

.hero-polaroid img,
.story-photos img,
.photo-card img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-polaroid img {
  aspect-ratio: 4 / 5;
  border-radius: 6px;
}

.hero-polaroid figcaption,
.story-photos figcaption,
.photo-card figcaption {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-polaroid figcaption {
  padding-top: 0.62rem;
  text-align: center;
}

.hero-content {
  position: relative;
  z-index: 1;
  display: grid;
  align-content: center;
  gap: 1.1rem;
  min-height: calc(100vh - 76px);
  padding: clamp(4rem, 9vw, 7rem) 0;
}

.eyebrow {
  color: var(--gold);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: #f5d891;
}

.hero-subtitle {
  font-size: clamp(1.3rem, 3vw, 2rem);
  font-weight: 700;
}

.hero-copy {
  max-width: 560px;
  font-size: clamp(1.05rem, 2.4vw, 1.28rem);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 0.4rem;
}

.countdown {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 120px));
  gap: 0.7rem;
  max-width: 560px;
  margin-top: 1.3rem;
}

.countdown div {
  padding: 0.9rem 0.75rem;
  border: 1px solid rgba(245, 216, 145, 0.34);
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(255, 253, 248, 0.16), rgba(56, 106, 131, 0.16));
  backdrop-filter: blur(8px);
}

.countdown strong,
.countdown span {
  display: block;
}

.countdown strong {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(2rem, 6vw, 3.3rem);
  line-height: 0.95;
}

.countdown span {
  color: rgba(255, 253, 248, 0.82);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.welcome {
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}

.message-stack {
  position: fixed;
  top: 92px;
  right: 0;
  left: 0;
  z-index: 30;
  pointer-events: none;
}

.message {
  width: min(680px, 100%);
  margin-left: auto;
  padding: 0.85rem 1rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  box-shadow: var(--shadow);
  color: var(--forest);
  font-weight: 700;
  pointer-events: auto;
}

.message-error {
  color: #7a2f21;
}

.intro-grid,
.feature-grid,
.split-section,
.rsvp-wrap {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: clamp(2rem, 6vw, 5rem);
  align-items: start;
}

.intro-copy,
.story-card,
.rsvp-copy {
  display: grid;
  gap: 1rem;
}

.section-head {
  display: grid;
  max-width: 780px;
  gap: 0.65rem;
  margin-bottom: 1.5rem;
}

.section-head.centered {
  margin-right: auto;
  margin-left: auto;
  text-align: center;
}

.section-head p:not(.eyebrow),
.split-section > div > p,
.intro-copy,
.rsvp-copy p {
  color: var(--muted);
  font-size: 1.02rem;
}

.section-soft {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(90deg, rgba(122, 79, 53, 0.06) 1px, transparent 1px),
    linear-gradient(180deg, rgba(56, 106, 131, 0.06) 1px, transparent 1px),
    linear-gradient(135deg, rgba(148, 170, 98, 0.16), rgba(111, 86, 136, 0.1), rgba(180, 147, 82, 0.1)),
    var(--paper);
  background-size: 38px 38px, 38px 38px, auto;
}

.story-card,
.info-card,
.stay-card,
.qa-list details,
.rsvp-form {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 253, 248, 0.92);
  box-shadow: var(--soft-shadow);
}

.story-card {
  padding: clamp(1.2rem, 3vw, 2rem);
}

.story-photos {
  display: grid;
  grid-template-columns: 1fr 0.86fr;
  gap: 0.85rem;
}

.story-photos figure,
.photo-card {
  position: relative;
  min-width: 0;
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  box-shadow: var(--soft-shadow);
}

.story-photos figure:first-child {
  min-height: 320px;
}

.story-photos figure:last-child {
  min-height: 260px;
  align-self: end;
}

.story-photos figcaption,
.photo-card figcaption {
  position: absolute;
  right: 0.75rem;
  bottom: 0.75rem;
  left: 0.75rem;
  padding: 0.55rem 0.65rem;
  border: 1px solid rgba(255, 253, 248, 0.36);
  border-radius: 8px;
  background: rgba(23, 70, 51, 0.76);
  color: #fffdf8;
  backdrop-filter: blur(8px);
}

.photo-section {
  background:
    linear-gradient(135deg, rgba(122, 79, 53, 0.09), rgba(56, 106, 131, 0.08), rgba(111, 86, 136, 0.07)),
    var(--bg);
}

.photo-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr 0.9fr;
  grid-auto-rows: minmax(210px, 1fr);
  gap: 1rem;
}

.photo-card {
  min-height: 230px;
}

.photo-card-large {
  grid-row: span 2;
  min-height: 470px;
}

.photo-card::before,
.story-photos figure::before {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(180deg, transparent 45%, rgba(15, 53, 38, 0.38));
  content: "";
  pointer-events: none;
}

.photo-card figcaption,
.story-photos figcaption {
  z-index: 2;
}

.milestones {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.8rem;
  margin-top: 0.4rem;
}

.milestones article {
  padding: 1rem;
  border: 1px solid rgba(222, 210, 189, 0.82);
  border-radius: 8px;
  background: linear-gradient(145deg, #fbf4e8, rgba(56, 106, 131, 0.08));
}

.milestones span,
.stay-card span {
  color: var(--blue);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.timeline {
  position: relative;
  display: grid;
  gap: 1rem;
  max-width: 920px;
  padding: 0;
  margin: 2rem auto 0;
  list-style: none;
}

.timeline::before {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 128px;
  width: 1px;
  background: var(--line);
  content: "";
}

.timeline li {
  position: relative;
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 2rem;
  align-items: start;
}

.timeline li::after {
  position: absolute;
  top: 0.7rem;
  left: 122px;
  width: 13px;
  height: 13px;
  border: 3px solid var(--paper);
  border-radius: 50%;
  background: var(--purple);
  box-shadow: 0 0 0 1px var(--line);
  content: "";
}

.timeline div {
  padding: 1rem 1.1rem;
  border: 1px solid var(--line);
  border-left: 4px solid var(--blue);
  border-radius: 8px;
  background: var(--paper);
  box-shadow: var(--soft-shadow);
}

.time {
  padding-top: 0.48rem;
  color: var(--forest);
  font-size: 0.84rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.expect-grid,
.card-grid,
.travel-grid {
  display: grid;
  gap: 1rem;
}

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

.card-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.travel-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.info-card,
.stay-card {
  display: grid;
  gap: 0.55rem;
  padding: 1.15rem;
  border-top: 4px solid var(--sage);
}

.info-card:nth-child(even),
.stay-card:nth-child(even) {
  border-top-color: var(--blue);
}

.info-card:nth-child(3n),
.stay-card:nth-child(3n) {
  border-top-color: var(--purple);
}

.info-card:nth-child(4n),
.stay-card:nth-child(4n) {
  border-top-color: var(--brown);
}

.info-card p,
.stay-card p,
.qa-list p {
  color: var(--muted);
}

.faq-wrap {
  display: grid;
  grid-template-columns: 0.72fr 1.28fr;
  gap: clamp(2rem, 6vw, 4rem);
}

.qa-list {
  display: grid;
  gap: 0.8rem;
}

.qa-list details {
  padding: 0.9rem 1rem;
}

.qa-list summary {
  color: var(--forest);
  font-weight: 700;
  cursor: pointer;
}

.qa-list summary::marker {
  color: var(--purple);
}

.qa-list p {
  margin-top: 0.65rem;
}

.rsvp-section {
  color: #fffdf8;
  background:
    linear-gradient(135deg, rgba(15, 53, 38, 0.94), rgba(40, 99, 74, 0.88), rgba(111, 86, 136, 0.62)),
    url("https://images.unsplash.com/photo-1506744038136-46273834b3fb?auto=format&fit=crop&w=1800&q=80");
  background-position: center;
  background-size: cover;
}

.rsvp-section .eyebrow {
  color: #f5d891;
}

.rsvp-copy p {
  color: rgba(255, 253, 248, 0.82);
}

.rsvp-form {
  display: grid;
  gap: 1rem;
  padding: clamp(1rem, 3vw, 1.5rem);
  color: var(--ink);
}

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

.rsvp-form label,
.rsvp-form fieldset {
  display: grid;
  gap: 0.4rem;
  margin: 0;
  color: var(--forest);
  font-weight: 700;
}

.rsvp-form fieldset {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border: 0;
  padding: 0;
}

.rsvp-form legend {
  grid-column: 1 / -1;
  padding: 0;
}

.radio-card {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 48px;
  padding: 0.72rem;
  border: 1px solid #cad1c5;
  border-radius: 8px;
  background: linear-gradient(135deg, #fbf7ef, rgba(148, 170, 98, 0.09));
}

.rsvp-form input,
.rsvp-form textarea {
  width: 100%;
  border: 1px solid #cad1c5;
  border-radius: 8px;
  padding: 0.74rem 0.8rem;
  background: #fff;
  color: var(--ink);
}

.rsvp-form .errorlist {
  margin: 0.2rem 0 0;
  padding: 0;
  color: #7a2f21;
  font-size: 0.9rem;
  font-weight: 700;
  list-style: none;
}

.form-errors {
  padding: 0.8rem;
  border: 1px solid rgba(122, 47, 33, 0.24);
  border-radius: 8px;
  background: rgba(122, 47, 33, 0.08);
}

.rsvp-form input:focus,
.rsvp-form textarea:focus,
.radio-card:focus-within {
  outline: 3px solid rgba(56, 106, 131, 0.22);
  border-color: var(--blue);
}

.form-note {
  min-height: 1.5rem;
  color: var(--forest);
  font-weight: 700;
}

.footer {
  padding: 1.4rem 1rem;
  border-top: 1px solid var(--line);
  background: var(--paper);
  color: var(--muted);
  text-align: center;
}

@media (max-width: 1080px) {
  .nav ul {
    position: fixed;
    top: 76px;
    right: 16px;
    left: 16px;
    display: none;
    grid-template-columns: 1fr;
    gap: 0;
    padding: 0.65rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--paper);
    box-shadow: var(--shadow);
  }

  .nav ul.is-open {
    display: grid;
  }

  .nav ul li {
    border-bottom: 1px solid rgba(222, 210, 189, 0.72);
  }

  .nav ul li:last-child {
    border-bottom: 0;
  }

  .nav ul a {
    display: flex;
    width: 100%;
    padding: 0.78rem;
  }

  .nav .button {
    margin-top: 0.3rem;
  }

  .nav-toggle {
    display: block;
  }

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

@media (max-width: 820px) {
  .hero,
  .hero-content {
    min-height: calc(92vh - 76px);
  }

  .hero-polaroid {
    position: relative;
    right: auto;
    bottom: auto;
    width: min(360px, calc(100% - 32px));
    margin: -5rem auto 2rem;
  }

  .intro-grid,
  .feature-grid,
  .split-section,
  .rsvp-wrap,
  .faq-wrap {
    grid-template-columns: 1fr;
  }

  .milestones,
  .card-grid,
  .travel-grid,
  .photo-grid,
  .form-grid,
  .rsvp-form fieldset {
    grid-template-columns: 1fr;
  }

  .photo-card-large {
    grid-row: auto;
    min-height: 300px;
  }

  .timeline::before {
    left: 7px;
  }

  .timeline li {
    grid-template-columns: 1fr;
    gap: 0.5rem;
    padding-left: 2rem;
  }

  .timeline li::after {
    left: 0;
  }

  .time {
    padding-top: 0;
  }
}

@media (max-width: 560px) {
  .wrap {
    width: min(100% - 24px, 1160px);
  }

  .section {
    padding: 3.5rem 0;
  }

  .hero-actions {
    display: grid;
  }

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

  .story-photos {
    grid-template-columns: 1fr;
  }

  .story-photos figure:first-child,
  .story-photos figure:last-child {
    min-height: 260px;
  }

  .hero::after {
    width: 190px;
    height: 190px;
  }
}

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