:root {
  color-scheme: light;
  --ink: #292b24;
  --paper: #e8dcc0;
  --ribbon: #93adba;
  --ribbon-dark: #526f78;
  --red: #d64a35;
  --shadow: rgba(44, 39, 29, 0.26);
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background: #c8bfa9;
}

body {
  min-height: 100vh;
  min-height: 100svh;
  margin: 0;
  display: grid;
  place-items: center;
  overflow-x: hidden;
  color: var(--ink);
  background:
    radial-gradient(circle at 18% 14%, rgba(255, 255, 255, 0.4), transparent 32%),
    linear-gradient(145deg, #bab09b, #d8cfba 58%, #b7ad98);
  font-family: Georgia, "Times New Roman", serif;
}

button {
  font: inherit;
}

.invitation {
  position: relative;
  width: min(100%, 76rem);
  min-height: 100vh;
  min-height: 100svh;
  overflow: hidden;
  isolation: isolate;
  background: var(--paper);
}

.invitation__art {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  filter: saturate(0.92) contrast(0.98);
}

.invitation::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: linear-gradient(
    to bottom,
    rgba(244, 234, 208, 0.08),
    rgba(244, 234, 208, 0.3) 12%,
    rgba(244, 234, 208, 0.72) 25%,
    rgba(244, 234, 208, 0.54) 44%,
    transparent 62%
  );
}

.announcement {
  width: min(88vw, 50rem);
  margin: 0 auto;
  padding: clamp(7.5rem, 14vh, 10.5rem) 1rem 22rem;
  text-align: center;
  text-wrap: balance;
}

.eyebrow,
.occasion,
.follow-up {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.18em;
}

.eyebrow {
  display: inline-block;
  padding: 0.5rem 1.5rem;
  color: #243a40;
  background: rgba(151, 177, 188, 0.78);
  clip-path: polygon(4% 8%, 96% 0, 100% 88%, 6% 100%, 0 47%);
  font-family: "Trebuchet MS", sans-serif;
  font-size: clamp(0.72rem, 2vw, 0.9rem);
  font-weight: 700;
}

h1 {
  margin: clamp(0.75rem, 2vh, 1.4rem) 0 0.3rem;
  font-size: clamp(3.15rem, 11vw, 6.2rem);
  font-weight: 400;
  line-height: 0.78;
  letter-spacing: -0.07em;
  white-space: nowrap;
}

h1 span {
  display: inline-block;
}

.ampersand {
  margin: 0 0.03em;
  color: var(--red);
  font-size: 0.66em;
  font-style: italic;
  transform: rotate(-8deg) translateY(-0.08em);
}

.occasion {
  font-family: "Trebuchet MS", sans-serif;
  font-size: clamp(0.67rem, 1.8vw, 0.84rem);
  font-weight: 700;
}

.date {
  display: grid;
  justify-items: center;
  gap: 0.08rem;
  margin: clamp(1.5rem, 3vh, 2rem) auto 1.15rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-family: "Trebuchet MS", sans-serif;
  font-size: clamp(0.7rem, 1.8vw, 0.82rem);
}

.date strong {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.5rem, 5vw, 2.2rem);
  font-weight: 400;
  letter-spacing: 0.03em;
}

.calendar-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-height: 2.9rem;
  padding: 0.7rem 1.15rem;
  border: 1px solid var(--ink);
  border-radius: 999px;
  color: var(--ink);
  background: rgba(244, 234, 208, 0.72);
  box-shadow: 2px 3px 0 rgba(41, 43, 36, 0.18);
  cursor: pointer;
  font-family: "Trebuchet MS", sans-serif;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transition: transform 160ms ease, background-color 160ms ease, box-shadow 160ms ease;
}

.calendar-button svg {
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.calendar-button:hover {
  background: #f3e8ca;
  box-shadow: 3px 4px 0 rgba(41, 43, 36, 0.22);
  transform: translate(-1px, -1px) rotate(-0.4deg);
}

.calendar-button:focus-visible {
  outline: 3px solid var(--red);
  outline-offset: 4px;
}

.calendar-button:active {
  box-shadow: 1px 1px 0 rgba(41, 43, 36, 0.2);
  transform: translate(1px, 1px);
}

.follow-up {
  margin-top: 1rem;
  font-family: "Trebuchet MS", sans-serif;
  font-size: 0.62rem;
  font-weight: 700;
}

.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.09;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.3'/%3E%3C/svg%3E");
  mix-blend-mode: multiply;
}

.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;
}

@media (min-width: 50rem) {
  body {
    padding: 2rem;
  }

  .invitation {
    min-height: min(56rem, calc(100svh - 4rem));
    border: 1px solid rgba(51, 48, 38, 0.34);
    box-shadow: 0 1.6rem 4rem var(--shadow), 0 0.2rem 0.3rem rgba(44, 39, 29, 0.24);
  }

  .invitation__art {
    object-position: center 49%;
  }

  .announcement {
    padding-top: clamp(5rem, 11vh, 8rem);
  }
}

@media (max-height: 43rem) and (orientation: landscape) {
  .announcement {
    margin-left: 8%;
    padding-top: 3.5rem;
  }

  h1 {
    font-size: clamp(3.4rem, 10vw, 5.5rem);
  }

  .invitation__art {
    object-position: center 62%;
  }
}

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