@font-face {
  font-family: "Latin Modern Roman";
  src: url("/fonts/latin-modern-roman.otf") format("opentype");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "Latin Modern Roman";
  src: url("/fonts/latin-modern-roman-italic.otf") format("opentype");
  font-style: italic;
  font-weight: 400;
  font-display: swap;
}

:root {
  color-scheme: light;
  --green: #343b26;
  --paper: #fff9ef;
  --gold: #777344;
  font-family: "Latin Modern Roman", Georgia, serif;
  background: #151414;
  color: var(--green);
}

*, *::before, *::after { box-sizing: border-box; }

body {
  min-height: 100vh;
  margin: 0;
  padding: clamp(1rem, 5vw, 4rem);
  display: grid;
  place-items: center;
}

main { width: min(100%, 68rem); }

.invitation {
  border: 3px double var(--gold);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  padding: clamp(.45rem, 1.4vw, .8rem);
  background: var(--paper);
  box-shadow: 0 1.4rem 4rem #343b2633;
}

.frame {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: clamp(2.6rem, 7vw, 5rem) clamp(.8rem, 4vw, 3rem);
  background: radial-gradient(ellipse at 50% 10%, #fffdf7, var(--paper) 85%);
}

summary {
  font: 600 .875rem/1.4 system-ui, sans-serif;
  letter-spacing: .19em;
  text-transform: uppercase;
}

.eyebrow {
  margin: 0 0 1.7rem;
  font: 400 1rem/1.35 "Latin Modern Roman", Georgia, serif;
  letter-spacing: .2em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-size: clamp(2.6rem, 7vw, 6.35rem);
  font-weight: 400;
  line-height: .94;
  letter-spacing: -.04em;
}

h1 span { display: block; }

.ampersand {
  margin: .12em 0 .16em;
  color: #68643b;
  font-family: "Latin Modern Roman", Georgia, serif;
  font-size: .49em;
  font-style: italic;
  letter-spacing: 0;
}

.divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .75rem;
  align-self: stretch;
  margin: 1.7rem 0 1.25rem;
}

.divider::before, .divider::after {
  content: "";
  width: 2.5rem;
  height: 1px;
  background: var(--gold);
}

.divider span {
  width: .36rem;
  height: .36rem;
  border: 1px solid var(--gold);
  transform: rotate(45deg);
}

.date { margin: 0; font-size: clamp(1.12rem, 4vw, 1.65rem); }
.location { margin: .55rem 0 0; font-size: 1.125rem; }
.festivities { margin: 1rem 0 0; }
.note { margin: .7rem 0 1.65rem; font-size: 1rem; font-style: italic; }

.calendar { width: min(100%, 19rem); margin: 0 auto; }
summary {
  display: inline-block;
  padding: .85rem 1.15rem;
  border: 1px solid #9a9468;
  color: var(--green);
  background: #eee8d3;
  cursor: pointer;
  list-style: none;
  letter-spacing: .1em;
}
summary::-webkit-details-marker { display: none; }
summary:hover { background: #e5ddc0; }
.calendar-options {
  display: grid;
  margin-top: .6rem;
  border: 1px solid var(--gold);
  background: #fffdf7;
  font: 1rem/1.4 system-ui, sans-serif;
}
.calendar-options a { padding: .7rem .5rem; color: var(--green); }
.calendar-options a + a { border-top: 1px solid #77734466; }
.calendar-options a:hover { background: #f0ead9; }
.calendar-options span:not(.sr-only) { font-size: .875rem; }
:focus-visible { outline: 2px solid #68643b; outline-offset: 3px; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.ceremony {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: cover;
  object-position: 50% 34%;
}

@media (max-width: 47rem) {
  main { width: min(100%, 34rem); }
  .invitation { grid-template-columns: minmax(0, 1fr); }
  h1 { font-size: clamp(2.6rem, 10vw, 5.5rem); }
  .ceremony { height: auto; }
}

@font-face {
  font-family: "Deco Gothic";
  src: url("/fonts/urw-gothic-book.otf") format("opentype");
  font-display: swap;
}
body {
  background:
    radial-gradient(ellipse at 50% 4%, #74604455, transparent 58%),
    repeating-linear-gradient(116deg, transparent 0 13rem, #ceb2880b 13.15rem, transparent 13.5rem 24rem),
    repeating-linear-gradient(67deg, transparent 0 10rem, #ead9a815 10.05rem, transparent 10.25rem 20rem),
    #151414;
}

main {
  --brass: #c29a59;
  --light-brass: #f3d596;
  position: relative;
  width: min(100%, 86rem);
}
.deco-fan {
  display: block;
  width: clamp(7.5rem, 20vw, 15rem);
  height: clamp(3rem, 8vw, 5.75rem);
  margin: 0 auto -.18rem;
  position: relative;
  overflow: hidden;
  border-block-end: 2px solid var(--brass);
}
.deco-fan::before {
  content: "";
  position: absolute;
  inset: 0 4% -102%;
  border: 1px solid var(--brass);
  border-radius: 50%;
  background:
    radial-gradient(circle at center, #f7dfac 0 6%, #8f6939 6.5% 10%, transparent 11%),
    repeating-conic-gradient(from -90deg, #71502e 0deg 7deg, #e7c684 7deg 8deg, #171519 8deg 14deg, #e7c684 14deg 15deg);
  mask-image: radial-gradient(circle at center, #000 0 68%, transparent 69%);
}
.deco-fan::after {
  content: "";
  position: absolute;
  inset: 20% 20% -79%;
  border: 1px solid var(--light-brass);
  border-radius: 50%;
}
.invitation {
  --green: #f5e5c1;
  --paper: #171518;
  --gold: var(--brass);
  position: relative;
  z-index: 1;
  width: 79%;
  margin: auto;
  grid-template-columns: minmax(0, 1.03fr) minmax(0, 1fr);
  background:
    repeating-linear-gradient(120deg, transparent 0 8rem, #d6b4730e 8.15rem, transparent 8.4rem 14rem),
    linear-gradient(155deg, #282321, #131215 62%, #211918);
  border: 6px double var(--brass);
  box-shadow: 0 0 0 3px #171416, 0 0 0 4px #977747, 0 1.35rem 4rem #0008;
  padding: clamp(.45rem, 1.4vw, 1rem);
}
.frame {
  position: relative;
  min-width: 0;
  padding: clamp(2.4rem, 5vw, 4.2rem) clamp(.65rem, 3vw, 2.7rem);
  color: var(--green);
  background: radial-gradient(ellipse at 50% 15%, #342626, #191619 79%);
  border: 1px solid #8c6b43;
  outline: 1px solid #b89460;
  outline-offset: -.55rem;
}
.frame::before,
.frame::after {
  content: "";
  position: absolute;
  height: .58rem;
  width: 29%;
  left: 35.5%;
  background: linear-gradient(90deg, #8f693a, #f5d99d 50%, #8f693a);
  clip-path: polygon(0 0, 100% 0, 100% 29%, 82% 29%, 82% 64%, 65% 64%, 65% 100%, 35% 100%, 35% 64%, 18% 64%, 18% 29%, 0 29%);
}
.frame::before { top: .48rem; }
.frame::after { bottom: .48rem; transform: rotate(180deg); }
.eyebrow {
  font-family: "Deco Gothic", system-ui, sans-serif;
  color: var(--light-brass);
  letter-spacing: .28em;
}
h1 {
  font-family: "Deco Gothic", system-ui, sans-serif;
  font-size: clamp(1.85rem, 4.9vw, 4.55rem);
  letter-spacing: .035em;
  line-height: .96;
  text-transform: uppercase;
}
.ampersand {
  color: var(--light-brass);
  font-size: .59em;
}
.divider { margin-block: 1.35rem 1.15rem; }
.divider::before,
.divider::after {
  width: min(22%, 5.5rem);
  height: 4px;
  border-block: 1px solid var(--brass);
  background: none;
}
.divider span { width: .5rem; height: .5rem; background: var(--brass); }
.ceremony {
  clip-path: polygon(0 14%, 6% 14%, 6% 8%, 13% 8%, 13% 3%, 21% 3%, 21% 0, 79% 0, 79% 3%, 87% 3%, 87% 8%, 94% 8%, 94% 14%, 100% 14%, 100% 100%, 0 100%);
  object-position: 50% 28%;
}
summary {
  color: #251b14;
  background: linear-gradient(112deg, #d5ac6a, #f7dfa8 48%, #d1a56a);
  border-color: #e2c48c;
  box-shadow: inset 0 0 0 2px #6d503747;
}
summary:hover { background: #f8e5b9; }
.calendar-options { background: #261c22; }
.calendar-options a + a { border-color: #866841; }
.calendar-options a:hover { background: #3a2930; }
:focus-visible { outline-color: #f5d69b; }

@keyframes lobby-reveal {
  from { opacity: 0; transform: translateY(.65rem); }
  to { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: no-preference) {
  .deco-fan { animation: lobby-reveal 500ms ease-out both; }
  .invitation { animation: lobby-reveal 660ms 110ms ease-out both; }
}

@media (max-width: 53rem) {
  .invitation { width: 88%; }
  h1 { font-size: clamp(1.9rem, 4.3vw, 3.1rem); }
}
@media (max-width: 47rem) {
  main { width: min(100%, 34rem); }
  .invitation { width: 100%; grid-template-columns: minmax(0, 1fr); }
  .ceremony { height: auto; margin-top: .5rem; }
  h1 { font-size: clamp(2rem, 8vw, 3.7rem); }
}
