@font-face {
  font-family: "Felidae";
  src: url("../fonts/Felidae.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #ebe9e4;
  --paper: #fffefb;
  --paper-warm: #fbf6ef;
  --ink: #56524d;
  --ink-strong: #3f3d39;
  --muted: #8a837a;
  --gold: #b8a068;
  --gold-soft: #ded3bd;
  --burgundy: #6f1f2e;
  --line: rgba(184, 160, 104, 0.32);
  --shadow: 0 18px 52px rgba(67, 58, 47, 0.09);
  --radius: 8px;
  --font-heading: "Oranienbaum", "Cormorant Garamond", Georgia, serif;
  --font-latin-script: "Felidae", "Parisienne", "Marck Script", cursive;
  --font-script: "Felidae", "Marck Script", "Cormorant Garamond", Georgia, serif;
  --font-body: "Cormorant Garamond", Georgia, serif;
  --font-ui: "Montserrat", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(90deg, rgba(202, 199, 191, 0.72) 0, rgba(202, 199, 191, 0.72) calc((100% - min(100vw, 760px)) / 2), transparent calc((100% - min(100vw, 760px)) / 2), transparent calc(100% - ((100% - min(100vw, 760px)) / 2)), rgba(202, 199, 191, 0.72) calc(100% - ((100% - min(100vw, 760px)) / 2)), rgba(202, 199, 191, 0.72) 100%),
    var(--bg);
  font-family: var(--font-body);
  line-height: 1.75;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.78), transparent 30rem);
}

.page {
  position: relative;
  width: min(100%, 760px);
  margin: 0 auto;
  overflow: hidden;
  background: var(--paper);
  box-shadow: 0 0 50px rgba(53, 45, 35, 0.08);
}

.page::before {
  content: "";
  position: fixed;
  top: 0;
  bottom: 0;
  left: max(14px, calc((100vw - 760px) / 2 + 42px));
  right: max(14px, calc((100vw - 760px) / 2 + 42px));
  max-width: 676px;
  margin: 0 auto;
  border-left: 1px solid rgba(184, 160, 104, 0.22);
  border-right: 1px solid rgba(184, 160, 104, 0.22);
  pointer-events: none;
  z-index: 2;
}

.section {
  position: relative;
  min-height: 100svh;
  display: grid;
  align-content: center;
  padding: 142px 32px;
  text-align: center;
  isolation: isolate;
}

.section > * {
  position: relative;
  z-index: 1;
}

.section + .section {
  border-top: 1px solid rgba(184, 160, 104, 0.16);
}

.section::before,
.section::after {
  content: "";
  position: absolute;
  left: 50%;
  z-index: 0;
  width: min(72%, 520px);
  min-height: 54px;
  aspect-ratio: 6 / 1;
  pointer-events: none;
  background: url("../images/ornament.svg") center / contain no-repeat;
  filter: grayscale(1) sepia(0.18);
  opacity: 0.28;
  transform: translateX(-50%);
}

.section::before {
  top: 44px;
}

.section::after {
  bottom: 44px;
  transform: translateX(-50%) rotate(180deg);
}

h1,
h2,
h3 {
  margin: 0;
  color: var(--ink-strong);
  font-family: var(--font-heading);
  font-weight: 400;
  line-height: 1.08;
  overflow-wrap: anywhere;
}

h1 {
  color: var(--gold);
  font-family: var(--font-latin-script);
  font-size: 82px;
  font-weight: 400;
  letter-spacing: 0;
  text-transform: none;
}

h2 {
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 44px;
  font-weight: 300;
  letter-spacing: 0;
  line-height: 1.18;
  text-transform: uppercase;
}

p {
  margin: 0;
}

.section-label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: fit-content;
  margin: 0 auto 20px;
  color: var(--gold);
  font-family: var(--font-heading);
  font-size: 17px;
  font-weight: 400;
  letter-spacing: 0.08em;
  letter-spacing: 0;
  line-height: 1.4;
  text-transform: uppercase;
}

.section-label::before,
.section-label::after {
  content: "";
  width: 36px;
  height: 1px;
  background: currentColor;
  opacity: 0.72;
}

.hero {
  min-height: 100svh;
  padding-top: 146px;
  padding-bottom: 146px;
}

.hero__content {
  position: relative;
  z-index: 1;
}

.hero__content::before {
  content: "A";
  position: absolute;
  top: 56%;
  left: 50%;
  z-index: -1;
  color: rgba(184, 160, 104, 0.08);
  font-family: var(--font-heading);
  font-size: 230px;
  line-height: 1;
  transform: translate(-50%, -50%);
}

.hero__text {
  max-width: 560px;
  margin: 28px auto 0;
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 29px;
  font-weight: 300;
  line-height: 1.36;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}

.bride-card {
  position: relative;
  width: min(86vw, 520px);
  aspect-ratio: 4 / 3;
  margin: 36px auto 18px;
  padding: 8px;
  border: 1px solid var(--gold);
  border-radius: 140px 140px 8px 8px;
  background: rgba(255, 254, 251, 0.76);
  box-shadow: var(--shadow);
}

.bride-card::before {
  content: "";
  position: absolute;
  inset: -12px -14px 12px;
  border: 1px solid rgba(184, 160, 104, 0.48);
  border-radius: 150px 150px 10px 10px;
  pointer-events: none;
}

.bride-card::after {
  content: "";
  position: absolute;
  right: -18px;
  bottom: 23%;
  width: 24px;
  height: 24px;
  background: var(--gold);
  clip-path: polygon(50% 0, 61% 39%, 100% 50%, 61% 61%, 50% 100%, 39% 61%, 0 50%, 39% 39%);
}

.bride-card img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  border-radius: 132px 132px 5px 5px;
}

.bride-name {
  color: var(--gold);
  font-family: var(--font-latin-script);
  font-size: 78px;
  font-weight: 400;
  line-height: 0.95;
  text-transform: uppercase;
}

.intro {
  background: linear-gradient(180deg, var(--paper) 0%, #fffaf4 100%);
}

.poem {
  max-width: 560px;
  margin: 30px auto 36px;
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 28px;
  font-weight: 300;
  line-height: 1.62;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}

.parents {
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 48px;
  font-weight: 300;
  line-height: 1.18;
  letter-spacing: 0;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}

.details {
  background: var(--paper);
}

.event-meta {
  max-width: 620px;
  margin: 0 auto;
  color: var(--ink);
  font-family: var(--font-heading);
  line-height: 1.35;
}

.event-meta p:first-child {
  font-size: 46px;
  font-weight: 400;
  letter-spacing: 0;
}

.event-meta p:last-child {
  margin-top: 10px;
  color: var(--muted);
  font-family: var(--font-body);
  font-size: 29px;
  font-weight: 400;
  letter-spacing: 0;
}

.calendar-card {
  width: min(100%, 470px);
  margin: 38px auto 20px;
  padding: 0 4px;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.calendar-card__month {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 18px;
  color: var(--gold);
  font-family: var(--font-latin-script);
  font-size: 60px;
  line-height: 1;
}

.calendar-card__month::before,
.calendar-card__month::after {
  content: "";
  width: 54px;
  height: 1px;
  background: var(--gold-soft);
}

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  column-gap: clamp(8px, 2.5vw, 18px);
  row-gap: 9px;
}

.calendar-grid span,
.calendar-grid time {
  min-height: 32px;
  display: grid;
  place-items: center;
  color: var(--ink);
  font-family: var(--font-heading);
  font-size: 31px;
  font-weight: 400;
  line-height: 1;
}

.calendar-grid--weekdays {
  margin-bottom: 13px;
  padding-bottom: 11px;
  border-bottom: 1px solid rgba(184, 160, 104, 0.18);
}

.calendar-grid--weekdays span {
  min-height: 24px;
  color: var(--gold);
  font-family: var(--font-heading);
  font-size: 28px;
  font-weight: 400;
  text-transform: uppercase;
}

.calendar-date--event {
  position: relative;
  z-index: 0;
  color: var(--burgundy) !important;
}

.calendar-date--event::before {
  content: "";
  position: absolute;
  width: 54px;
  height: 54px;
  border: 3px solid var(--burgundy);
  border-radius: 52% 48% 55% 45% / 50% 54% 46% 50%;
  transform: rotate(-11deg);
  box-shadow: 0 9px 20px rgba(111, 31, 46, 0.08);
  z-index: -1;
}

.venue-feature {
  max-width: 620px;
  margin: 50px auto 0;
  padding: 42px 0 0;
  border-top: 1px solid rgba(184, 160, 104, 0.18);
}

.venue-feature__label {
  margin-bottom: 22px;
  color: var(--gold);
}

.venue-feature h3 {
  color: var(--ink);
  font-family: var(--font-body);
  font-weight: 300;
  line-height: 1.18;
  letter-spacing: 0;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}

.venue-feature__name,
.venue-feature__type {
  display: block;
}

.venue-feature__name {
  font-size: 66px;
}

.venue-feature__type {
  margin-top: 6px;
  font-size: 38px;
}

.venue-feature p:not(.section-label) {
  max-width: 560px;
  margin: 22px auto 30px;
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 24px;
  letter-spacing: 0;
  line-height: 1.6;
  text-transform: uppercase;
}

.countdown-section {
  background: linear-gradient(180deg, #fffefb 0%, #fbf6ef 100%);
}

.countdown {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  max-width: 520px;
  margin: 36px auto 0;
}

.countdown__box {
  min-height: 112px;
  display: grid;
  place-items: center;
  padding: 18px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 254, 251, 0.76);
  color: var(--ink-strong);
  box-shadow: 0 12px 28px rgba(67, 58, 47, 0.08);
}

.countdown__box strong {
  color: var(--gold);
  font-family: var(--font-heading);
  font-size: 56px;
  font-weight: 400;
  line-height: 1;
}

.countdown__box span {
  color: var(--muted);
  font-family: var(--font-ui);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: uppercase;
}

.button {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 15px 26px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font: 600 13px/1 var(--font-ui);
  letter-spacing: 0;
  text-decoration: none;
  cursor: pointer;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease, color 180ms ease;
}

.button--primary {
  color: #fffefb;
  background: var(--burgundy);
  box-shadow: 0 16px 34px rgba(111, 31, 46, 0.18);
}

.button--primary:hover,
.button--primary:focus-visible {
  transform: translateY(-2px);
  background: #85283b;
}

.button--full {
  width: 100%;
}

.rsvp {
  min-height: 92svh;
  background: var(--paper);
}

.rsvp h2 {
  max-width: 620px;
  margin: 0 auto;
}

.rsvp-form {
  max-width: 620px;
  margin: 34px auto 0;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 254, 251, 0.9);
  box-shadow: var(--shadow);
  text-align: left;
}

.field-label,
.radio-group legend {
  display: block;
  margin-bottom: 10px;
  color: var(--ink-strong);
  font-family: var(--font-ui);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0;
}

input[type="text"] {
  width: 100%;
  min-height: 52px;
  margin-bottom: 20px;
  padding: 14px 15px;
  border: 1px solid rgba(184, 160, 104, 0.34);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink-strong);
  font: 500 16px/1.4 var(--font-ui);
}

input[type="text"]:focus,
.radio-card:has(input:focus-visible) {
  outline: 3px solid rgba(184, 160, 104, 0.22);
  border-color: var(--gold);
}

input[aria-invalid="true"] {
  border-color: rgba(157, 47, 37, 0.62);
  outline: 3px solid rgba(157, 47, 37, 0.12);
}

.radio-group {
  display: grid;
  gap: 10px;
  margin: 0 0 22px;
  padding: 0;
  border: 0;
}

.radio-card {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 54px;
  padding: 13px 14px;
  border: 1px solid rgba(184, 160, 104, 0.28);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  font-family: var(--font-ui);
  cursor: pointer;
}

.radio-card input {
  width: 18px;
  height: 18px;
  accent-color: var(--burgundy);
}

.radio-card:has(input:checked) {
  border-color: var(--gold);
  background: #fff8ec;
}

.radio-card:has(input[aria-invalid="true"]) {
  border-color: rgba(157, 47, 37, 0.42);
}

.form-message {
  min-height: 28px;
  margin-top: 14px;
  text-align: center;
  font-weight: 600;
}

.form-message.is-success {
  color: #315c42;
}

.form-message.is-error {
  color: #9d2f25;
}

.notification {
  position: fixed;
  top: 18px;
  left: 50%;
  z-index: 40;
  width: min(calc(100vw - 28px), 430px);
  padding: 14px 18px;
  border: 1px solid rgba(184, 160, 104, 0.42);
  border-radius: var(--radius);
  background: rgba(255, 254, 251, 0.96);
  box-shadow: 0 18px 48px rgba(67, 58, 47, 0.16);
  color: var(--ink);
  font: 600 14px/1.45 var(--font-ui);
  text-align: center;
  pointer-events: none;
  opacity: 0;
  transform: translate(-50%, -14px);
  transition: opacity 220ms ease, transform 220ms ease;
}

.notification.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

.notification.is-success {
  border-color: rgba(49, 92, 66, 0.34);
  color: #315c42;
}

.notification.is-error {
  border-color: rgba(157, 47, 37, 0.34);
  color: #9d2f25;
}

.notification.is-info {
  border-color: rgba(184, 160, 104, 0.42);
  color: var(--ink);
}

.hp-field {
  position: absolute;
  left: -9999px;
}

.music-toggle {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 20;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 46px;
  max-width: calc(100vw - 32px);
  padding: 12px 14px;
  border: 1px solid rgba(184, 160, 104, 0.46);
  border-radius: 999px;
  background: rgba(255, 254, 251, 0.94);
  color: var(--burgundy);
  box-shadow: 0 14px 34px rgba(67, 58, 47, 0.14);
  font: 600 12px/1 var(--font-ui);
  cursor: pointer;
}

.music-toggle__icon {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--burgundy);
  color: #fffefb;
}

.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 700ms ease, transform 700ms ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 430px) {
  .section {
    min-height: auto;
    padding: 104px 28px;
  }

  .section::before {
    top: 28px;
  }

  .section::after {
    bottom: 28px;
  }

  .page::before {
    left: 18px;
    right: 18px;
  }

  h1 {
    font-size: 54px;
    line-height: 0.95;
  }

  h2 {
    font-size: 28px;
    line-height: 1.28;
  }

  .hero__content::before {
    font-size: 142px;
  }

  .hero__text {
    font-size: 19px;
    line-height: 1.45;
  }

  .bride-card {
    width: min(78vw, 340px);
    margin-top: 26px;
  }

  .bride-name {
    font-size: 46px;
  }

  .poem {
    font-size: 18px;
    line-height: 1.75;
  }

  .parents {
    font-size: 30px;
    line-height: 1.25;
  }

  .event-meta p:first-child {
    font-size: 30px;
  }

  .event-meta p:last-child {
    font-size: 21px;
  }

  .calendar-card__month {
    font-size: 42px;
  }

  .calendar-grid span,
  .calendar-grid time {
    font-size: 20px;
  }

  .calendar-grid--weekdays span {
    font-size: 18px;
  }

  .venue-feature h3 {
    font-size: inherit;
  }

  .venue-feature__name {
    font-size: 36px;
  }

  .venue-feature__type {
    font-size: 23px;
  }

  .venue-feature p:not(.section-label) {
    font-size: 17px;
  }

  .countdown__box strong {
    font-size: 38px;
  }

  .rsvp h2 {
    font-size: 28px;
  }

  .rsvp-form {
    margin-top: 26px;
    padding: 18px;
  }

  .field-label,
  .radio-card {
    font-size: 15px;
  }

  .radio-card {
    min-height: 58px;
    padding: 12px;
  }

  .button {
    min-height: 50px;
  }

  .music-toggle {
    right: 12px;
    bottom: 12px;
    min-height: 44px;
    padding: 10px;
  }

  .music-toggle [data-music-label] {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
  }

  .section-label::before,
  .section-label::after {
    width: 24px;
  }

  .calendar-grid {
    column-gap: 5px;
  }
}

@media (min-width: 720px) {
  .section {
    padding: 158px 64px;
  }

  .section::before {
    top: 54px;
  }

  .section::after {
    bottom: 54px;
  }

  h1 {
    font-size: 126px;
  }

  h2 {
    font-size: 64px;
  }

  .hero__content::before {
    font-size: 330px;
  }

  .hero__text {
    font-size: 34px;
  }

  .bride-name {
    font-size: 94px;
  }

  .poem {
    font-size: 30px;
  }

  .parents {
    font-size: 62px;
  }

  .event-meta p:first-child {
    font-size: 52px;
  }

  .event-meta p:last-child {
    font-size: 30px;
  }

  .venue-feature h3 {
    font-size: inherit;
  }

  .venue-feature__name {
    font-size: 78px;
  }

  .venue-feature__type {
    font-size: 44px;
  }

  .countdown {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .rsvp-form {
    padding: 30px;
  }
}

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

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
