@import url("https://fonts.googleapis.com/css2?family=Allura&family=Cormorant+Garamond:wght@400;500;600&family=Montserrat:wght@300;400;500;600&display=swap");

:root {
  --ink: #2f3528;
  --sage: #78866b;
  --cream: #f6f1e8;
  --paper: #fffaf2;
  --gold: #c8a05b;
  --rose: #d8b8a6;
  --shadow: 0 22px 70px rgba(47, 53, 40, 0.18);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  overflow-x: hidden;
  margin: 0;
  color: var(--ink);
  background: linear-gradient(180deg, #fbf8f1 0%, #f1eadf 100%);
  font-family: "Montserrat", system-ui, sans-serif;
}

body.cover-locked {
  overflow: hidden;
}

a {
  color: inherit;
}

.opening-cover {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  background: transparent;
  transition: opacity 320ms ease, visibility 0s linear 320ms;
}

.opening-cover.is-open {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

.opening-cover__poster {
  position: relative;
  z-index: 4;
  width: 100%;
  height: 100%;
  display: grid;
  grid-template-rows: 1fr auto auto auto 1fr;
  align-items: center;
  justify-items: center;
  gap: 18px;
  border: 0;
  border-radius: 0;
  padding: clamp(28px, 7dvh, 72px) 22px;
  background: linear-gradient(
    180deg,
    rgba(12, 14, 11, 0.44),
    rgba(12, 14, 11, 0.1) 42%,
    rgba(12, 14, 11, 0.48)
  );
  color: #fffaf2;
  text-shadow: 0 3px 28px rgba(0, 0, 0, 0.42);
  cursor: pointer;
  appearance: none;
  overflow: hidden;
}

.opening-cover__poster::before,
.opening-cover__poster::after {
  display: none;
}

.opening-cover__names {
  grid-row: 2;
  display: block;
  font-family: "Allura", cursive;
  font-size: clamp(4.2rem, 12vw, 8rem);
  line-height: 1;
  white-space: nowrap;
}

.opening-cover__photo {
  display: none;
}

.opening-cover__date {
  grid-row: 3;
  display: block;
  color: #fffaf2;
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(2.3rem, 7vw, 4.4rem);
  font-weight: 400;
  letter-spacing: 0.02em;
}

.opening-cover__hint {
  grid-row: 4;
  display: inline-grid;
  justify-self: center;
  min-height: 46px;
  align-items: center;
  border: 1px solid rgba(255, 250, 242, 0.72);
  border-radius: 999px;
  padding: 0 24px;
  background: rgba(255, 250, 242, 0.18);
  color: #fffaf2;
  backdrop-filter: blur(8px);
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  animation: hintPulse 1400ms ease-in-out infinite;
}

.opening-cover__curtain {
  position: absolute;
  inset: 0 auto 0 0;
  z-index: 2;
  width: 50%;
  transform: translateX(0);
  pointer-events: none;
  overflow: hidden;
  will-change: transform;
}

.opening-cover__curtain--right {
  right: 0;
  left: auto;
  transform: translateX(0);
}

.opening-cover__curtain img {
  position: absolute;
  inset: 0 auto 0 0;
  width: 100vw;
  height: 100vh;
  display: block;
  object-fit: cover;
  object-position: 50% 38%;
  filter: saturate(1.03) contrast(1.02);
}

.opening-cover__curtain::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(12, 14, 11, 0.24), rgba(12, 14, 11, 0.04));
}

.opening-cover__curtain--right img {
  right: 0;
  left: auto;
}

.opening-cover__curtain--right::after {
  background: linear-gradient(270deg, rgba(12, 14, 11, 0.24), rgba(12, 14, 11, 0.04));
}

.opening-cover.is-opening .opening-cover__poster {
  opacity: 0;
  transition: opacity 260ms ease;
}

.opening-cover.is-opening .opening-cover__curtain {
  animation: curtainLeft 980ms cubic-bezier(0.77, 0, 0.175, 1) forwards;
}

.opening-cover.is-opening .opening-cover__curtain--right {
  animation-name: curtainRight;
}

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

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

@keyframes curtainLeft {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(-102%);
  }
}

@keyframes curtainRight {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(102%);
  }
}

.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  place-items: center;
  overflow: hidden;
  isolation: isolate;
}

.hero__bg,
.hero__shade {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.hero__bg {
  background:
    radial-gradient(circle at 82% 24%, rgba(255, 255, 255, 0.14), transparent 24%),
    url("assets/boho-arch.png") center / cover no-repeat;
  filter: saturate(1.04) contrast(0.98);
  transform: scale(1.02);
}

.hero__shade {
  z-index: -1;
  background:
    linear-gradient(180deg, rgba(31, 35, 26, 0.2), rgba(31, 35, 26, 0.45)),
    radial-gradient(circle at center, rgba(255, 250, 242, 0.38), rgba(42, 36, 28, 0.42));
}

.hero__content {
  width: min(92vw, 760px);
  text-align: center;
  color: #fffaf2;
  padding: 44px 22px 96px;
  text-shadow: 0 2px 26px rgba(0, 0, 0, 0.32);
}

.eyebrow {
  margin: 0 0 24px;
  font-family: "Allura", cursive;
  font-size: clamp(2rem, 6vw, 3.9rem);
  line-height: 1;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 18px;
  font-family: "Allura", cursive;
  font-size: clamp(4.4rem, 15vw, 8.9rem);
  font-weight: 400;
  line-height: 0.82;
}

h1 span {
  display: block;
  margin: 10px 0 6px;
  color: #f1d28b;
  font-size: 0.55em;
}

.families {
  margin-bottom: 36px;
  font-size: clamp(0.78rem, 2.5vw, 0.96rem);
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.countdown {
  display: grid;
  grid-template-columns: repeat(4, minmax(64px, 92px));
  justify-content: center;
  gap: 12px;
  margin: 0 auto 34px;
}

.countdown div {
  aspect-ratio: 1;
  display: grid;
  align-content: center;
  border: 1px solid rgba(255, 250, 242, 0.42);
  border-radius: 14px;
  background: rgba(255, 250, 242, 0.08);
  backdrop-filter: blur(7px);
}

.countdown strong {
  font-size: clamp(1.35rem, 4vw, 2rem);
  line-height: 1;
}

.countdown span {
  margin-top: 8px;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.hero__actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.button {
  border: 1px solid rgba(255, 250, 242, 0.72);
  border-radius: 999px;
  padding: 14px 22px;
  background: rgba(255, 250, 242, 0.92);
  color: var(--ink);
  font: 600 0.9rem "Montserrat", sans-serif;
  text-decoration: none;
  cursor: pointer;
}

.button--ghost {
  background: rgba(255, 250, 242, 0.1);
  color: #fffaf2;
}

.scroll-cue {
  position: absolute;
  bottom: 26px;
  left: 50%;
  transform: translateX(-50%);
  display: grid;
  justify-items: center;
  gap: 10px;
  color: #fffaf2;
  font-size: 0.78rem;
  text-decoration: none;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.38);
}

.scroll-cue span {
  width: 22px;
  height: 42px;
  border: 1px solid rgba(255, 250, 242, 0.7);
  border-radius: 999px;
}

.details,
.gallery-section {
  padding: 86px max(22px, calc((100vw - 1120px) / 2));
}

.section-title {
  text-align: center;
  margin-bottom: 44px;
}

.section-title p,
.label {
  color: var(--gold);
  font-family: "Allura", cursive;
  font-size: 2.3rem;
  line-height: 1;
}

.section-title h2 {
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(2.6rem, 7vw, 4.8rem);
  font-weight: 500;
}

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

.event-card {
  display: grid;
  grid-template-columns: 118px 1fr;
  gap: 24px;
  min-height: 320px;
  padding: 28px;
  border: 1px solid rgba(200, 160, 91, 0.42);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(255, 250, 242, 0.94), rgba(246, 241, 232, 0.82)),
    radial-gradient(circle at right top, rgba(216, 184, 166, 0.28), transparent 42%);
  box-shadow: var(--shadow);
}

.event-card--warm {
  background:
    linear-gradient(145deg, rgba(255, 250, 242, 0.94), rgba(246, 241, 232, 0.86)),
    radial-gradient(circle at left bottom, rgba(120, 134, 107, 0.2), transparent 44%);
}

.event-card__date {
  min-height: 190px;
  display: grid;
  align-content: center;
  justify-items: center;
  border-right: 1px solid rgba(47, 53, 40, 0.18);
}

.event-card__date span {
  font-family: "Cormorant Garamond", serif;
  font-size: 5.4rem;
  line-height: 0.82;
}

.event-card__date p {
  margin: 12px 0 0;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.event-card h3 {
  margin-bottom: 18px;
  font-family: "Allura", cursive;
  font-size: 4.2rem;
  font-weight: 400;
  line-height: 0.9;
}

.event-time {
  margin: -6px 0 12px;
  color: var(--gold);
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.event-card__body > p:not(.label) {
  font-size: 1rem;
  line-height: 1.65;
}

.address {
  color: rgba(47, 53, 40, 0.72);
}

.text-link {
  display: inline-block;
  margin-top: 8px;
  color: var(--gold);
  font-weight: 600;
  text-decoration-thickness: 1px;
  text-underline-offset: 5px;
}

.couple-section {
  min-height: 620px;
  display: grid;
  grid-template-columns: minmax(260px, 0.88fr) minmax(300px, 420px);
  align-items: center;
  gap: 26px;
  padding: 60px max(22px, calc((100vw - 1120px) / 2));
  background:
    linear-gradient(90deg, rgba(47, 53, 40, 0.9), rgba(47, 53, 40, 0.66)),
    url("assets/boho-arch.png") center / cover no-repeat;
  color: var(--paper);
  overflow: hidden;
}

.couple-copy {
  align-self: center;
  max-width: 520px;
}

.eyebrow--dark {
  margin-bottom: 12px;
  color: #e8c77f;
  font-size: clamp(1.9rem, 4vw, 3rem);
}

.couple-copy h2 {
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(2.4rem, 4.8vw, 4.1rem);
  font-weight: 500;
  line-height: 1.02;
}

.parents {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 30px;
}

.parents p {
  padding-top: 18px;
  border-top: 1px solid rgba(255, 250, 242, 0.25);
  font-size: 0.92rem;
  line-height: 1.45;
}

.parents strong {
  display: block;
  margin-bottom: 8px;
  color: #e8c77f;
  font-size: 0.9rem;
}

.couple-section > img {
  justify-self: center;
  align-self: end;
  width: min(100%, 420px);
  max-height: 560px;
  object-fit: contain;
  border-radius: 8px 8px 0 0;
  filter: drop-shadow(0 28px 38px rgba(0, 0, 0, 0.28));
}

.gallery-section {
  position: relative;
  background: var(--paper);
  overflow: hidden;
}

.gallery-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 10% 0%, rgba(200, 160, 91, 0.16), transparent 34%),
    radial-gradient(circle at 90% 22%, rgba(120, 134, 107, 0.15), transparent 30%);
  pointer-events: none;
}

.gallery-section > * {
  position: relative;
}

.gallery {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-auto-rows: 210px;
  gap: 16px;
  margin: 0 auto;
  width: min(100%, 1120px);
}

.gallery__item {
  position: relative;
  display: block;
  border: 0;
  border-radius: 8px;
  padding: 0;
  overflow: hidden;
  background: #e8dfd0;
  box-shadow: 0 18px 46px rgba(47, 53, 40, 0.16);
  cursor: zoom-in;
  appearance: none;
}

.gallery__item--wide {
  grid-column: span 2;
}

.gallery__item--tall {
  grid-row: span 2;
}

.gallery__item img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition: transform 260ms ease, filter 260ms ease;
}

.gallery__item:hover img {
  filter: saturate(1.05) contrast(1.02);
  transform: scale(1.045);
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: 22px;
  background: rgba(18, 20, 16, 0.82);
  backdrop-filter: blur(8px);
}

.lightbox[hidden] {
  display: none;
}

.lightbox img {
  width: min(100%, 1120px);
  max-height: 92dvh;
  display: block;
  border-radius: 8px;
  object-fit: contain;
  background: #111;
  pointer-events: none;
}

.lightbox__close {
  position: fixed;
  top: 18px;
  right: 18px;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255, 250, 242, 0.54);
  border-radius: 999px;
  background: rgba(255, 250, 242, 0.92);
  color: var(--ink);
  font-size: 30px;
  line-height: 1;
  cursor: pointer;
}

.lightbox__nav {
  position: fixed;
  top: 50%;
  z-index: 21;
  width: 52px;
  height: 52px;
  border: 1px solid rgba(255, 250, 242, 0.54);
  border-radius: 999px;
  background: rgba(255, 250, 242, 0.9);
  color: var(--ink);
  font-size: 44px;
  line-height: 0.9;
  transform: translateY(-50%);
  cursor: pointer;
  display: grid;
  place-items: center;
}

.lightbox__nav--prev {
  left: max(18px, calc((100vw - 1200px) / 2));
}

.lightbox__nav--next {
  right: max(18px, calc((100vw - 1200px) / 2));
}

.lightbox__nav:hover,
.lightbox__close:hover {
  background: #fffaf2;
}

@media (max-width: 760px) {
  .opening-cover__poster {
    gap: 12px;
    padding: 46px 18px;
  }

  .opening-cover__names {
    font-size: clamp(3.2rem, 15vw, 5.4rem);
    white-space: normal;
  }

  .opening-cover__curtain img {
    height: 100dvh;
    object-position: 50% 50%;
  }

  .hero {
    min-height: 100dvh;
  }

  .hero__content {
    padding-top: 28px;
  }

  .countdown {
    grid-template-columns: repeat(4, minmax(58px, 74px));
    gap: 8px;
  }

  .families {
    max-width: 330px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.7;
  }

  .event-grid,
  .couple-section,
  .parents,
  .gallery {
    grid-template-columns: 1fr;
  }

  .gallery {
    grid-auto-rows: 260px;
  }

  .gallery__item--wide,
  .gallery__item--tall {
    grid-column: span 1;
    grid-row: span 1;
  }

  .lightbox {
    padding: 72px 14px;
  }

  .lightbox__nav {
    width: 44px;
    height: 44px;
    font-size: 38px;
  }

  .lightbox__nav--prev {
    left: 10px;
  }

  .lightbox__nav--next {
    right: 10px;
  }

  .event-card {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .event-card__date {
    min-height: 0;
    padding-bottom: 18px;
    border-right: 0;
    border-bottom: 1px solid rgba(47, 53, 40, 0.18);
  }

  .couple-section {
    padding-top: 74px;
    text-align: center;
  }

  .couple-section img {
    justify-self: center;
  }
}
