:root {
  --yellow: #c0ae35;
  --yellow-light: #c8b940;
  --ink: #0e171a;
  --paper: #f6f1df;
  --field: #fffaf0;
  --muted: #776b2a;
  --shadow: 0 28px 80px rgba(14, 23, 26, 0.16);
  --hand: "Kalam", "Segoe Print", "Bradley Hand", cursive;
  --sans: "Montserrat", Arial, sans-serif;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 20% 10%, rgba(255,255,255,.58), transparent 34%),
    var(--paper);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
}

button, input, select, textarea { font: inherit; }
a { color: inherit; }

.skip-link {
  position: fixed;
  top: 1rem;
  left: 1rem;
  z-index: 100;
  transform: translateY(-180%);
  padding: .75rem 1rem;
  color: var(--yellow);
  background: var(--ink);
  border-radius: 999px;
}
.skip-link:focus { transform: none; }

.invitation-panel {
  width: min(1120px, calc(100% - 32px));
  min-height: calc(100svh - 32px);
  margin: 16px auto 0;
  padding: 15rem 2rem 12rem;
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
  isolation: isolate;
  text-align: center;
  background:
    radial-gradient(circle at 52% 42%, rgba(255,255,255,.07), transparent 42%),
    linear-gradient(145deg, var(--yellow-light), var(--yellow));
  border-radius: clamp(34px, 6vw, 64px);
  box-shadow: var(--shadow);
}
.invitation-panel::after,
.rsvp-card::after {
  content: "";
  position: absolute;
  pointer-events: none;
  inset: 12px;
  border: 2px solid rgba(14, 23, 26, .23);
  border-radius: inherit;
  transform: rotate(-.12deg);
}

.invitation-copy {
  position: relative;
  z-index: 3;
  width: min(660px, 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
}
.names-art {
  margin: 0 auto 4.1rem;
  width: min(520px, 78vw);
  line-height: 0;
}
.names-art img { display: block; width: 100%; height: auto; }

.invitation-line {
  margin: 0 0 3.4rem;
  font-size: clamp(1rem, 2vw, 1.45rem);
  font-weight: 500;
  line-height: 1.7;
  letter-spacing: .025em;
  text-transform: uppercase;
}
.event-details {
  margin-bottom: 2.35rem;
  font-size: clamp(1.05rem, 2.1vw, 1.55rem);
  line-height: 1.48;
  letter-spacing: .015em;
  text-transform: uppercase;
}
.event-details p { margin: 0; }
.event-details__venue { margin-top: 1.75rem !important; font-weight: 500; }

.button {
  min-height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: .82rem 1.55rem;
  border: 2px solid var(--ink);
  border-radius: 999px;
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .13em;
  line-height: 1;
  text-decoration: none;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}
.button:hover { transform: translateY(-2px) rotate(-.3deg); box-shadow: 0 8px 0 rgba(14,23,26,.18); }
.button:focus-visible { outline: 4px solid var(--field); outline-offset: 3px; }
.button--dark { color: var(--yellow); background: var(--ink); }
.hero-actions {
  position: relative;
  z-index: 4;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .9rem;
}
.button--hero {
  min-height: 66px;
  padding: 1.05rem 2.8rem;
  color: var(--paper);
  background: var(--ink);
  border: 3px solid rgba(246,241,223,.92);
  font-size: .96rem;
  font-weight: 700;
  letter-spacing: .18em;
  box-shadow: 0 10px 0 rgba(14,23,26,.22), 0 0 0 8px rgba(246,241,223,.24);
}
.button--hero:hover { transform: translateY(-3px) rotate(-.3deg); }
.button--hero:focus-visible { outline-color: rgba(255,250,240,.95); }
.button--secondary {
  min-height: 44px;
  padding: .72rem 1.2rem;
  color: var(--ink);
  background: rgba(246, 241, 223, .54);
  border-color: rgba(14, 23, 26, .76);
  font-size: .72rem;
  letter-spacing: .12em;
  box-shadow: 0 4px 0 rgba(14,23,26,.12);
}
.button:disabled { opacity: .65; cursor: wait; transform: none; }


/* Thank-you page */
.thank-you-copy {
  width: min(700px, 100%);
}
.thank-you-kicker {
  margin: 0 0 .2rem;
}
.thank-you-heading {
  margin: 0 0 1.35rem;
  font-size: clamp(5rem, 12vw, 9rem);
  font-weight: 600;
  letter-spacing: -.055em;
  line-height: .9;
}
.thank-you-heading--pending {
  visibility: hidden;
}
.thank-you-name {
  display: block;
  font: inherit;
}
.thank-you-message {
  margin: 0 0 2.6rem;
}
.thank-you-button {
  margin-top: 0;
}

.ornament {
  position: absolute;
  z-index: 1;
  pointer-events: none;
  user-select: none;
}
.ornament--fan-top { top: 2.8rem; left: 50%; width: min(38vw, 430px); transform: translateX(-50%); }
.ornament--fan-bottom { bottom: 2.3rem; left: 50%; width: min(39vw, 450px); transform: translateX(-50%); }
.ornament--daisy { width: clamp(110px, 17vw, 205px); }
.ornament--daisy-tl { top: 2.2rem; left: 2.3rem; transform: rotate(-8deg); }
.ornament--daisy-tr { top: 2rem; right: 2.3rem; transform: scaleX(-1) rotate(-8deg); }
.ornament--daisy-bl { bottom: 1.8rem; left: 2.2rem; transform: rotate(7deg); }
.ornament--daisy-br { bottom: 1.7rem; right: 2.2rem; transform: scaleX(-1) rotate(7deg); }
.ornament--sprig { top: 17%; height: 63%; width: auto; }
.ornament--sprig-left { left: 2.1rem; }
.ornament--sprig-right { right: 2.1rem; transform: scaleX(-1); }

.rsvp-section { padding: 7rem 1rem; }
.rsvp-card {
  width: min(960px, 100%);
  margin: 0 auto;
  padding: 6rem clamp(1.25rem, 5vw, 4.5rem) 4.5rem;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  background:
    radial-gradient(circle at 50% 0%, rgba(255,255,255,.08), transparent 38%),
    var(--yellow);
  border: 3px solid var(--ink);
  border-radius: clamp(32px, 5vw, 54px);
  box-shadow: var(--shadow);
}
.rsvp-decoration {
  position: absolute;
  top: 1.7rem;
  z-index: -1;
  width: clamp(90px, 14vw, 150px);
  opacity: .96;
}
.rsvp-decoration--left { left: 1.5rem; transform: rotate(-10deg); }
.rsvp-decoration--right { right: 1.5rem; transform: scaleX(-1) rotate(-10deg); }

.rsvp-intro {
  width: min(620px, 100%);
  margin: 0 auto 3.5rem;
  text-align: center;
}
.kicker {
  margin: 0 0 .3rem;
  font-size: .74rem;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
}
.rsvp-intro h2,
.closing h2 {
  margin: 0;
  font-family: var(--sans);
  font-weight: 600;
  letter-spacing: -.035em;
}
.rsvp-intro h2 { font-size: clamp(3.7rem, 8vw, 6rem); line-height: 1; }
.rsvp-intro > p:not(.kicker):not(.deadline) { margin: 1.2rem auto 0; max-width: 580px; }
.deadline { margin: .8rem 0 0; font-weight: 600; }

.rsvp-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
}
.field { min-width: 0; }
.field--full { grid-column: 1 / -1; }
.field-group {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
  padding-top: .25rem;
}
label, legend {
  display: block;
  margin: 0 0 .45rem;
  font-size: .74rem;
  font-weight: 600;
  letter-spacing: .085em;
  text-transform: uppercase;
}
.field-note {
  max-width: 620px;
  margin: -.15rem 0 .75rem;
  font-size: .86rem;
  font-weight: 500;
}
fieldset { min-width: 0; margin: 0; padding: 0; border: 0; }
input, select, textarea {
  width: 100%;
  color: var(--ink);
  background: var(--field);
  border: 2px solid var(--ink);
  box-shadow: 0 4px 0 rgba(14,23,26,.12);
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}
input, select { min-height: 52px; padding: .75rem 1rem; border-radius: 999px; }
textarea { resize: vertical; padding: .9rem 1rem; border-radius: 22px; }
input:focus, select:focus, textarea:focus {
  outline: 3px solid rgba(255,250,240,.92);
  outline-offset: 2px;
  transform: translateY(-1px);
  box-shadow: 0 6px 0 rgba(14,23,26,.16);
}

.choice-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.choice-card {
  min-height: 92px;
  margin: 0;
  padding: 1rem;
  display: flex;
  align-items: center;
  gap: .9rem;
  position: relative;
  color: var(--ink);
  background: var(--field);
  border: 2px solid var(--ink);
  border-radius: 24px;
  box-shadow: 0 4px 0 rgba(14,23,26,.12);
  cursor: pointer;
  text-transform: none;
  letter-spacing: 0;
  transition: transform .15s ease, background .15s ease, color .15s ease;
}
.choice-card:hover { transform: translateY(-2px) rotate(-.15deg); }
.choice-card input { position: absolute; opacity: 0; pointer-events: none; }
.choice-card:has(input:checked) { color: var(--yellow); background: var(--ink); }
.choice-card:has(input:focus-visible) { outline: 4px solid var(--field); outline-offset: 3px; }
.choice-card__symbol {
  width: 2.15rem;
  height: 2.15rem;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border: 2px solid currentColor;
  border-radius: 50%;
  font-family: var(--hand);
  font-size: 1.35rem;
  line-height: 1;
}
.choice-card strong, .choice-card small { display: block; }
.choice-card strong { font-size: .82rem; letter-spacing: .035em; text-transform: uppercase; }
.choice-card small { margin-top: .12rem; font-size: .76rem; font-weight: 400; opacity: .72; }

.form-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 1rem 1.5rem; margin-top: .6rem; }
.form-status { margin: 0; font-size: .82rem; font-weight: 500; }
.honeypot { position: absolute; overflow: hidden; clip: rect(0 0 0 0); width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; }

.faq-section {
  padding: 0 1rem 6rem;
}
.faq-inner {
  width: min(960px, 100%);
  margin: 0 auto;
}
.faq-intro {
  margin: 0 auto 2.4rem;
  text-align: center;
}
.faq-intro h2 {
  margin: 0;
  font-size: clamp(3.5rem, 8vw, 5.5rem);
  font-weight: 600;
  letter-spacing: -.035em;
  line-height: 1;
}
.faq-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}
.faq-item {
  min-width: 0;
  padding: 1.25rem 1.35rem;
  background: rgba(255, 250, 240, .72);
  border: 2px solid rgba(14, 23, 26, .78);
  border-radius: 24px;
  box-shadow: 0 4px 0 rgba(14,23,26,.09);
}
.faq-item h3 {
  margin: 0 0 .55rem;
  font-size: .86rem;
  font-weight: 700;
  letter-spacing: .075em;
  line-height: 1.35;
  text-transform: uppercase;
}
.faq-item p {
  margin: 0;
  font-size: .95rem;
}
.faq-item a {
  font-weight: 700;
}

.closing {
  width: min(820px, calc(100% - 32px));
  margin: 0 auto 5rem;
  padding: 2rem 1rem 3rem;
  text-align: center;
}
.closing img { width: min(270px, 62vw); }
.closing-names { display: block; width: min(285px, 65vw) !important; margin: 1.4rem auto .8rem; }
.closing h2 { font-size: clamp(1.8rem, 4.7vw, 3.1rem); line-height: 1.08; }
.closing #contact-line { margin: 1rem 0 0; }
footer { padding: 1.5rem 1rem 2rem; text-align: center; font-size: .72rem; letter-spacing: .11em; text-transform: uppercase; }

@media (max-width: 880px) {
  .invitation-panel { padding-top: 12rem; padding-bottom: 10rem; }
  .ornament--sprig { display: none; }
  .ornament--daisy { width: 125px; }
  .ornament--daisy-tl, .ornament--daisy-tr { top: 2rem; }
  .ornament--fan-top { width: 330px; }
  .ornament--fan-bottom { width: 340px; }
}

@media (max-width: 680px) {
  .button--hero {
    min-height: 60px;
    padding: .95rem 1.9rem;
    font-size: .85rem;
  }
  .button--secondary {
    min-height: 42px;
    padding: .68rem 1rem;
    font-size: .68rem;
  }
  .hero-actions {
    gap: .75rem;
    margin-bottom: 2.35rem;
  }

  .invitation-panel {
    width: calc(100% - 16px);
    min-height: calc(100svh - 16px);
    margin-top: 8px;
    padding: 10.5rem 1rem 9.5rem;
    border-radius: 34px;
  }
  .invitation-panel::after, .rsvp-card::after { inset: 8px; }
  .ornament--fan-top { top: 2.1rem; width: 250px; }
  .ornament--fan-bottom { bottom: 2rem; width: 250px; }
  .ornament--daisy { width: 88px; }
  .ornament--daisy-tl { top: 1.7rem; left: 1.3rem; }
  .ornament--daisy-tr { top: 1.6rem; right: 1.3rem; }
  .ornament--daisy-bl { bottom: 1.3rem; left: 1.2rem; }
  .ornament--daisy-br { bottom: 1.2rem; right: 1.2rem; }
  .names-art { margin-bottom: 3rem; width: min(410px, 82vw); }
  .thank-you-kicker { margin-bottom: .1rem; }
  .thank-you-heading { margin-bottom: 1.1rem; }
  .thank-you-message { margin-bottom: 2.2rem; }
  .invitation-line { margin-bottom: 2.5rem; font-size: .88rem; }
  .event-details { font-size: 1rem; }
  .event-details__venue { margin-top: 1.2rem !important; }

  .rsvp-section { padding: 4rem .5rem; }
  .rsvp-card { padding: 5.5rem 1rem 3rem; border-radius: 34px; }
  .rsvp-decoration { width: 90px; top: 1.3rem; }
  .rsvp-decoration--left { left: .8rem; }
  .rsvp-decoration--right { right: .8rem; }
  .rsvp-form, .field-group, .choice-grid { grid-template-columns: 1fr; }
  .field, .field--full { grid-column: 1; }
  .form-actions { align-items: stretch; }
  .form-actions .button { width: 100%; }
  .faq-section { padding: 0 .5rem 4rem; }
  .faq-list { grid-template-columns: 1fr; }
  .faq-item { border-radius: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}
