:root {
  --parchment: #f1ead9;
  --parchment-warm: #e8dcc2;
  --ink: #24211b;
  --ink-soft: #58513f;
  --rose: #b3654a;
  --rose-soft: #ce9179;
  --sage: #a9b48c;
  --line: rgba(36, 33, 27, 0.14);

  --display: "Fraunces", Georgia, serif;
  --script: "Homemade Apple", "Brush Script MT", cursive;
  --body: "Public Sans", -apple-system, BlinkMacSystemFont, sans-serif;

  --max-w: 1080px;
  --gutter: clamp(20px, 5vw, 64px);

  --radius: 18px;
  --radius-sm: 10px;
  --shadow: 0 14px 34px rgba(36, 33, 27, 0.10);

  --flower: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cg fill='%23fff'%3E%3Cellipse cx='12' cy='6.3' rx='3.5' ry='5.4'/%3E%3Cellipse cx='12' cy='6.3' rx='3.5' ry='5.4' transform='rotate(72 12 12)'/%3E%3Cellipse cx='12' cy='6.3' rx='3.5' ry='5.4' transform='rotate(144 12 12)'/%3E%3Cellipse cx='12' cy='6.3' rx='3.5' ry='5.4' transform='rotate(216 12 12)'/%3E%3Cellipse cx='12' cy='6.3' rx='3.5' ry='5.4' transform='rotate(288 12 12)'/%3E%3Ccircle cx='12' cy='12' r='2.6'/%3E%3C/g%3E%3C/svg%3E");
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

body {
  margin: 0;
  background: var(--parchment);
  color: var(--ink);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }
h1, h2, h3 { font-family: var(--display); font-weight: 500; letter-spacing: -0.01em; margin: 0; }
:focus-visible { outline: 2px solid var(--rose); outline-offset: 3px; }

.wrap { max-width: var(--max-w); margin: 0 auto; padding: 0 var(--gutter); }
section { padding: clamp(48px, 9vw, 108px) 0; }

/* ---------- Nav ---------- */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(241, 234, 217, 0.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--line);
}
.site-nav .wrap { display: flex; align-items: center; justify-content: space-between; padding: 16px var(--gutter); }
.site-nav .mark { font-family: var(--script); font-size: 1.3rem; color: var(--rose); }
.site-nav ul {
  list-style: none; display: flex; gap: clamp(14px, 2.5vw, 26px); margin: 0; padding: 0;
  font-family: "Marcellus", var(--display); font-size: 0.8rem; letter-spacing: 0.06em; text-transform: uppercase;
}
.site-nav a { text-decoration: none; border-bottom: 1px solid transparent; transition: color 0.15s ease, border-color 0.15s ease; }
.site-nav a:hover { color: var(--rose); border-bottom-color: var(--rose-soft); }
.nav-toggle { display: none; }

@media (max-width: 640px) {
  .site-nav ul {
    position: fixed;
    inset: 58px 0 auto 0;
    background: var(--parchment);
    flex-direction: column;
    padding: 16px var(--gutter) 22px;
    border-bottom: 1px solid var(--line);
    display: none;
  }
  .site-nav ul.open { display: flex; }
  .nav-toggle {
    display: block;
    background: none;
    border: 1px solid var(--line);
    border-radius: 999px;
    font-family: var(--body);
    font-size: 0.82rem;
    padding: 6px 14px;
  }
}

/* ---------- Hero ---------- */
.hero { padding: 0 0 clamp(32px, 6vw, 64px); }

.hero-photo {
  position: relative;
  isolation: isolate;
}
.hero-photo img {
  display: block;
  width: 100%;
  height: auto;              /* no crop — full frame stays visible */
  /* fade the photo's top and bottom edges into the page background */
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 3%, #000 96%, transparent 100%);
  mask-image: linear-gradient(to bottom, transparent 0%, #000 3%, #000 96%, transparent 100%);
}
/* soft scrim so the names stay legible over any part of the photo */
.hero-scrim {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to bottom,
      rgba(241, 234, 217, 0.55) 0%,
      rgba(36, 33, 27, 0.26) 34%,
      rgba(36, 33, 27, 0.34) 62%,
      rgba(241, 234, 217, 0.95) 100%);
  pointer-events: none;
}
.hero-copy {
  position: absolute;
  inset: 0;
  will-change: transform, opacity;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  /* nudge the names below centre so they sit over the lower half */
  padding: 18vh var(--gutter) 0;
}
.hero-names {
  font-family: var(--script);
  font-weight: 400;
  font-size: clamp(2.3rem, 7vw, 5.2rem);
  line-height: 1.15;
  color: var(--parchment);
  text-shadow: 0 2px 28px rgba(20, 18, 14, 0.45);
}
.hero-names .amp { color: var(--rose-soft); font-style: normal; }
.hero-sub {
  margin: 16px 0 0;
  font-size: clamp(0.9rem, 1.6vw, 1.05rem);
  letter-spacing: 0.08em;
  color: var(--parchment);
  text-shadow: 0 1px 16px rgba(20, 18, 14, 0.5);
}

/* Mobile: a landscape photo at natural height is too short for an
   overlay hero, so set a minimum height and crop toward the rotunda.
   Scoped to portrait only — in landscape the viewport itself is short,
   so 62vh isn't tall enough to hold the names and clips them. */
@media (max-width: 700px) and (orientation: portrait) {
  .hero-photo img {
    min-height: 62vh;
    object-fit: cover;
    object-position: center center;
  }
}

/* ---------- Section headers ---------- */
.section-head {
  margin: 0 auto clamp(32px, 5vw, 48px);
  text-align: center;
  max-width: 560px;
}
.section-head::before {
  content: "";
  display: block;
  width: 22px;
  height: 22px;
  margin: 0 auto 16px;
  background: var(--rose-soft);
  -webkit-mask-image: var(--flower);
  mask-image: var(--flower);
  -webkit-mask-size: contain;
  mask-size: contain;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
}
.section-head h2 { font-family: var(--script); font-weight: 400; font-size: clamp(1.7rem, 3.6vw, 2.3rem); letter-spacing: 0.04em; }

/* ---------- Panes ---------- */
.pane-green {
  background: var(--sage);
  color: var(--ink);
}
.pane-tan {
  background: var(--parchment-warm);
}

/* ---------- Details (on sage) ---------- */
.details-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(16px, 3vw, 24px);
}
.detail-card {
  background: var(--parchment);
  padding: 28px 28px;
  border-radius: var(--radius);
  border-top: 3px solid var(--rose-soft);
  box-shadow: var(--shadow);
  text-align: center;
}
.detail-card .label { font-size: 0.82rem; color: var(--rose); margin-bottom: 8px; letter-spacing: 0.03em; }
.detail-card h3 { font-size: 1.2rem; margin-bottom: 6px; color: var(--ink); font-style: italic; }
.detail-card p { margin: 0; color: var(--ink-soft); font-size: 0.95rem; }
.detail-card a.map-link {
  display: inline-block; margin-top: 10px; font-size: 0.88rem;
  color: var(--rose); border-bottom: 1px solid var(--rose-soft);
}

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

/* ---------- Travel (on tan) ---------- */
.travel-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: clamp(20px, 4vw, 32px); }
.travel-card {
  background: var(--parchment);
  border-radius: var(--radius);
  padding: 28px 28px;
  border-top: 3px solid var(--rose-soft);
  box-shadow: var(--shadow);
}
.travel-card h3 { font-size: 1.2rem; margin-bottom: 6px; color: var(--ink); font-style: italic; }
.travel-card p { margin: 0; color: var(--ink-soft); font-size: 0.94rem; }
@media (max-width: 640px) { .travel-grid { grid-template-columns: 1fr; } }

/* ---------- Registry (on sage) ---------- */
.registry-soon { color: var(--ink-soft); }

/* ---------- Gallery: one full-height band, scrolling sideways ---------- */
.gallery {
  position: relative;
  padding: 0;
  height: 100vh;
  height: 100svh;
  background: var(--sage);
}
.gallery-track {
  display: flex;
  gap: clamp(8px, 1.4vw, 18px);
  height: 100%;
  /* clears the sticky nav at the top and gives the strip some air */
  padding: clamp(64px, 8vh, 92px) 0 clamp(28px, 5vh, 48px);
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x proximity;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;          /* Firefox */
  -ms-overflow-style: none;
}
.gallery-track::-webkit-scrollbar { display: none; }
.gallery-track:focus-visible { outline: 2px solid var(--rose-soft); outline-offset: -4px; }

/* Each frame is sized by its photo, not the other way round — nothing is
   cropped, so portrait and landscape shots both show in full. */
.gallery .shot {
  margin: 0;
  flex: 0 0 auto;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  scroll-snap-align: center;
}
/* the photo scales down to fit both the band height and the viewport width,
   so the whole frame is always visible whatever its shape */
.gallery .shot img {
  display: block;
  width: auto;
  height: auto;
  max-height: 100%;
  max-width: min(88vw, 1200px);
}

/* arrows */
.gallery-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 46px;
  height: 46px;
  border: 1px solid rgba(241, 234, 217, 0.55);
  background: rgba(36, 33, 27, 0.35);
  color: var(--parchment);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  border-radius: 50%;
  backdrop-filter: blur(4px);
  transition: background 0.15s ease, opacity 0.15s ease;
}
.gallery-nav:hover { background: rgba(36, 33, 27, 0.6); }
.gallery-nav.prev { left: clamp(10px, 2.5vw, 28px); }
.gallery-nav.next { right: clamp(10px, 2.5vw, 28px); }

@media (max-width: 700px) {
  .gallery { height: 72vh; height: 72svh; }
  .gallery-nav { display: none; }   /* swipe instead */
}

@media (prefers-reduced-motion: reduce) {
  .gallery-track { scroll-behavior: auto; }
}

/* ---------- RSVP ---------- */
.rsvp-note { color: var(--ink-soft); }

footer { padding: 40px 0 52px; color: var(--ink-soft); font-size: 0.88rem; border-top: none; text-align: center; position: relative; }
footer::before {
  content: "";
  display: block;
  width: 22px;
  height: 22px;
  margin: 0 auto 20px;
  background: var(--rose-soft);
  -webkit-mask-image: var(--flower);
  mask-image: var(--flower);
  -webkit-mask-size: contain;
  mask-size: contain;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
}
footer p:first-of-type { font-family: var(--display); font-style: italic; font-size: 1.05rem; color: var(--ink); }
