@font-face {
  font-family: Cormorant;
  src: url("/assets/cormorant-garamond-latin-600-normal.woff2") format("woff2");
  font-style: normal;
  font-weight: 600;
  font-display: swap;
}

@font-face {
  font-family: Cormorant;
  src: url("/assets/cormorant-garamond-latin-600-italic.woff2") format("woff2");
  font-style: italic;
  font-weight: 600;
  font-display: swap;
}

@font-face {
  font-family: "DM Sans";
  src: url("/assets/dm-sans-latin-500-normal.woff2") format("woff2");
  font-style: normal;
  font-weight: 500;
  font-display: swap;
}

:root {
  color-scheme: light;
  --ivory: #f8f3e8;
  --cypress: #37493d;
  --ink: #25372d;
  --sage: #becab5;
  --line: #d3ccba;
  --aged-gold: #805c2f;
  --serif: Cormorant, Baskerville, Georgia, serif;
  font-family: "DM Sans", system-ui, sans-serif;
  background: var(--ivory);
  color: var(--ink);
}

* {
  box-sizing: border-box;
}

body {
  width: min(100% - 2.5rem, 86rem);
  margin: 0 auto;
}

.invitation {
  display: grid;
  min-height: calc(100svh - 6.5rem);
  align-items: center;
  gap: clamp(2.5rem, 6vw, 7rem);
  padding-block: clamp(3rem, 7vw, 6.5rem);
}

.announcement {
  min-width: 0;
  padding-inline: clamp(0rem, 2vw, 2rem);
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 1.1rem;
  margin: 0 0 1.9rem;
  color: var(--aged-gold);
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.eyebrow::before {
  width: 1.6rem;
  height: 1px;
  content: "";
  background: currentColor;
}

h1 {
  margin: 0;
  font: 600 clamp(4.5rem, 11vw, 10.1rem) / 0.77 var(--serif);
  letter-spacing: -0.07em;
}

h1 span:last-child {
  display: block;
  margin-left: clamp(2rem, 7.5vw, 6.8rem);
}

h1 em {
  color: var(--aged-gold);
  font-size: 0.63em;
  vertical-align: 0.18em;
}

time {
  display: block;
  margin-top: clamp(2rem, 4vw, 3.25rem);
  font: 600 clamp(1.7rem, 2.8vw, 2.45rem) / 1 var(--serif);
}

.welcome {
  max-width: 26rem;
  margin: 1.15rem 0 0;
  color: var(--cypress);
  font-size: clamp(0.94rem, 1.4vw, 1.1rem);
  line-height: 1.65;
  text-wrap: pretty;
}

.calendar {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: space-between;
  gap: 1.6rem;
  margin-top: 1.8rem;
  padding: 0.8rem 1rem;
  border: 1px solid var(--cypress);
  color: var(--cypress);
  font-size: 0.88rem;
  text-decoration: none;
  transition: background-color 150ms ease, color 150ms ease;
}

.calendar:hover {
  background: var(--cypress);
  color: var(--ivory);
}

.calendar:focus-visible {
  outline: 2px solid var(--aged-gold);
  outline-offset: 4px;
}

.cover {
  display: grid;
  min-height: 20rem;
  aspect-ratio: 1 / 1.08;
  align-items: center;
  justify-items: center;
  padding: clamp(1.1rem, 3vw, 2.5rem);
  border: 1px solid #809079;
  background: #dce5d5;
  box-shadow: inset 0 0 0 0.5rem #edf0e7, 0 1rem 2rem #25372d12;
}

.cover-frame {
  position: relative;
  display: grid;
  width: min(80%, 24rem);
  aspect-ratio: 0.78;
  place-items: center;
  isolation: isolate;
  border: 1px solid #748771;
  border-radius: 50% 50% 43% 43%;
  background: #405742;
  box-shadow: 0 0 0 0.42rem #dce5d5, 0 0 0 0.48rem #82927b;
}

.cover-frame::before {
  position: absolute;
  z-index: -1;
  inset: 0.65rem;
  border: 1px solid #bdc9b0;
  border-radius: inherit;
  content: "";
}

.cover-frame img {
  display: block;
  width: 68%;
  height: auto;
}

footer {
  padding: 1.35rem 0 1.65rem;
  border-top: 1px solid var(--line);
  color: var(--cypress);
  text-align: center;
}

footer p {
  margin: 0;
  font-size: 0.8rem;
  line-height: 1.5;
  text-wrap: pretty;
}

@media (min-width: 47rem) {
  body {
    width: min(100% - 5.5rem, 86rem);
  }

  .invitation {
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  }

  h1 {
    font-size: clamp(4.8rem, 10.55vw, 10.1rem);
  }

  .cover {
    min-height: 25rem;
  }
}

@media (max-width: 22rem) {
  h1 {
    font-size: 4rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .calendar {
    transition: none;
  }
}
