/* =========================================================================
   Oskar & Emilie — minimal variant
   One page. One font. Paper and ink. Air.
   ========================================================================= */

:root {
  --paper:   oklch(97% 0.008 85);
  --ink:     oklch(22% 0.02 245);
  --ink-50:  oklch(22% 0.02 245 / 0.55);
  --ink-20:  oklch(22% 0.02 245 / 0.18);
  --accent:  oklch(46% 0.14 28); /* terracotta — same hue as invitation's red monster, but restrained */

  --step-0:  1.0625rem;
  --step-1:  1.1875rem;
  --step-2:  clamp(1.375rem, 1rem + 1vw, 1.625rem);
  --step-3:  clamp(2rem, 1.2rem + 2.4vw, 2.75rem);
  --step-hero: clamp(3rem, 1.4rem + 7vw, 6rem);

  --font: "EB Garamond", "Iowan Old Style", Georgia, serif;
  --font-display: "Cardo", "Iowan Old Style", Georgia, serif;

  --gutter: clamp(20px, 4vw, 40px);
  --rhythm: clamp(48px, 6vw, 88px);

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: var(--step-1);
  line-height: 1.6;
  font-feature-settings: "liga", "dlig", "onum";
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

::selection { background: oklch(from var(--accent) l c h / 0.18); color: var(--ink); }

a { color: inherit; text-decoration: none; }

abbr[title] {
  text-decoration: underline dotted;
  text-decoration-thickness: 1px;
  text-underline-offset: 5px;
  text-decoration-color: oklch(from currentColor l c h / 0.5);
  cursor: help;
}
a.thin-link {
  border-bottom: 1px solid var(--ink-20);
  padding-bottom: 1px;
  transition: border-color 200ms var(--ease), color 200ms var(--ease);
}
a.thin-link:hover { color: var(--accent); border-bottom-color: var(--accent); }
a:focus-visible, button:focus-visible, input:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

.page {
  max-width: 520px;
  margin: 0 auto;
  padding: clamp(48px, 8vw, 120px) var(--gutter) var(--rhythm);
}

@media (min-width: 900px) {
  .page { max-width: 600px; }
}

/* ---------- Masthead ---------------------------------------------------- */

.mast {
  display: grid;
  justify-items: center;
  gap: 18px;
  margin-bottom: calc(var(--rhythm) * 1.2);
}

.mark {
  width: clamp(120px, 22vw, 180px);
  margin: 0;
  opacity: 0.7;
}
.mark img {
  width: 100%;
  height: auto;
  object-fit: contain;
  filter: saturate(0.55) contrast(0.92);
}

.mast__date {
  margin: 0;
  font-size: 0.92rem;
  letter-spacing: 0.22em;
  text-transform: lowercase;
  color: var(--ink-50);
}
.mast__date em { font-style: italic; }

/* ---------- Lede -------------------------------------------------------- */

.lede { text-align: center; }

.lede h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: var(--step-hero);
  font-weight: 400;
  line-height: 1.02;
  letter-spacing: -0.005em;
}
.lede h1 em { font-style: italic; font-weight: 400; }
.lede h1 .amp {
  display: inline-block;
  font-style: italic;
  font-weight: 400;
  font-size: 0.6em;
  color: var(--accent);
  transform: translateY(-0.08em);
  margin: 0 0.12em;
}

.lede__line {
  margin: 22px 0 0;
  font-style: italic;
  color: var(--ink-50);
  letter-spacing: 0.02em;
  font-size: var(--step-1);
}

/* ---------- Rule -------------------------------------------------------- */

.divider {
  display: grid;
  place-items: center;
  margin: var(--rhythm) auto;
  color: var(--ink-50);
}
.divider svg {
  width: clamp(72px, 12vw, 96px);
  height: auto;
  opacity: 0.85;
}

/* ---------- Prose ------------------------------------------------------- */

.prose {
  max-width: 36ch;
  margin: 0 auto;
  text-align: center;
}
.prose p { margin: 0 0 1em; }
.prose p:last-child { margin-bottom: 0; color: var(--ink-50); }

/* ---------- Meta -------------------------------------------------------- */

.meta dl {
  margin: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px 24px;
  max-width: 420px;
  margin-inline: auto;
  text-align: center;
}
.meta div { display: grid; gap: 6px; }
.meta dt {
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-50);
  font-style: italic;
}
.meta dd {
  margin: 0;
  font-style: italic;
  font-size: var(--step-1);
  line-height: 1.4;
}
.meta__map {
  display: inline-block;
  margin-top: 2px;
  font-size: 0.9rem;
  color: var(--accent);
  border-bottom: 1px solid oklch(from var(--accent) l c h / 0.35);
  padding-bottom: 1px;
  font-style: italic;
  transition: border-color 160ms var(--ease);
}
.meta__map:hover { border-bottom-color: currentColor; }
.meta__hint {
  display: block;
  margin-top: 4px;
  font-size: 0.85rem;
  font-style: italic;
  color: var(--ink-50);
}

/* ---------- RSVP -------------------------------------------------------- */

.rsvp, .gift, .speech {
  max-width: 380px;
  margin-inline: auto;
}

h2 {
  margin: 0 0 28px;
  font-size: var(--step-2);
  font-weight: 400;
  text-align: center;
  letter-spacing: 0.01em;
}
h2 em { font-style: italic; font-weight: 500; }

.rsvp form { display: grid; gap: 22px; }

.line { display: grid; gap: 6px; }
.line > span,
.line legend {
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-50);
  font-style: italic;
  padding: 0;
}

.line input[type="text"],
.line input[type="email"],
.line input[type="tel"] {
  width: 100%;
  padding: 6px 0 8px;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--ink-20);
  color: var(--ink);
  font: inherit;
  font-style: italic;
  font-size: var(--step-1);
  transition: border-color 160ms var(--ease);
}
.line input:focus { outline: none; border-bottom-color: var(--accent); }

.line > span small {
  display: inline-block;
  margin-left: 6px;
  letter-spacing: 0;
  text-transform: none;
  font-size: 0.85em;
  font-style: italic;
  opacity: 0.75;
}

.line--check {
  display: flex !important;
  align-items: center;
  gap: 10px;
  cursor: pointer;
}
.line--check input[type="checkbox"] {
  accent-color: var(--accent);
  width: 1.05em;
  height: 1.05em;
  margin: 0;
}
.line--check > span {
  font-size: var(--step-1);
  font-style: italic;
  text-transform: none;
  letter-spacing: 0;
  color: var(--ink);
  padding: 0;
}

.line--choice {
  border: 0;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 10px;
}
.line--choice > label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-style: italic;
  font-size: var(--step-1);
  letter-spacing: 0;
  text-transform: none;
  color: var(--ink);
  cursor: pointer;
}
.line--choice legend { margin-bottom: 4px; }
.line--choice input[type="radio"] { accent-color: var(--accent); width: 1em; height: 1em; }

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

.rsvp button {
  justify-self: center;
  margin-top: 16px;
  padding: 10px 4px;
  background: transparent;
  color: var(--ink);
  border: 0;
  border-bottom: 1px solid var(--ink);
  font: inherit;
  font-size: var(--step-1);
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: color 200ms var(--ease), border-color 200ms var(--ease);
}
.rsvp button em { font-style: italic; }
.rsvp button:hover { color: var(--accent); border-bottom-color: var(--accent); }
.rsvp button:disabled { opacity: 0.5; cursor: default; }

/* ---------- Gift / speech / foot --------------------------------------- */

.gift { text-align: center; }
.gift p { margin: 0 0 1em; }

.pay {
  list-style: none;
  margin: 24px auto 12px;
  padding: 0;
  max-width: 320px;
  text-align: left;
  border-top: 1px solid var(--ink-20);
}
.pay li {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: baseline;
  gap: 16px;
  padding: 12px 2px;
  border-bottom: 1px solid var(--ink-20);
}
.pay__label {
  font-size: 0.75rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-50);
  font-style: italic;
}
.pay__value {
  font-variant-numeric: tabular-nums;
  font-style: italic;
  font-size: var(--step-1);
  color: var(--ink);
}

.gift__note { margin: 14px auto 0; opacity: 0.55; font-size: 0.82rem; max-width: 38ch; }

.speech { text-align: center; max-width: 440px; margin-inline: auto; }

.speech-card {
  display: grid;
  gap: 12px;
  padding: 28px 24px;
  border: 1px solid var(--ink-20);
  color: var(--ink);
  text-decoration: none;
  text-align: center;
  transition: border-color 200ms var(--ease), transform 200ms var(--ease), box-shadow 200ms var(--ease);
}
.speech-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px) rotate(-0.15deg);
  box-shadow: 0 8px 20px oklch(from var(--accent) l c h / 0.15);
}
.speech-card__title {
  display: block;
  font-size: var(--step-2);
  color: var(--accent);
  line-height: 1.1;
}
.speech-card__title em { font-style: italic; font-weight: 500; }
.speech-card__body {
  display: block;
  font-style: italic;
  color: var(--ink-50);
  font-size: var(--step-0);
  line-height: 1.45;
}
.speech-card__cta {
  display: block;
  margin-top: 4px;
  color: var(--accent);
  font-size: var(--step-1);
}
.speech-card__cta em { font-style: italic; font-weight: 500; }

footer {
  margin-top: calc(var(--rhythm) * 1.5);
  text-align: center;
  color: var(--ink-50);
  font-size: 0.9rem;
}
footer em { font-style: italic; }

/* ---------- FAQ -------------------------------------------------------- */

.faq { max-width: 460px; margin-inline: auto; }
.faq h2 { margin-bottom: 32px; }
.faq dl { margin: 0; display: grid; gap: 28px; }
.faq div { display: grid; gap: 6px; }
.faq dt {
  font-style: italic;
  font-size: var(--step-1);
  color: var(--ink);
  line-height: 1.35;
}
.faq dd {
  margin: 0;
  color: var(--ink-50);
  line-height: 1.55;
  font-size: var(--step-0);
}
.faq__note {
  margin: 32px auto 0;
  text-align: center;
  color: var(--ink-50);
  font-size: 0.85rem;
  opacity: 0.7;
}

@media (min-width: 900px) {
  .meta dl { grid-template-columns: repeat(4, 1fr); max-width: 100%; gap: 32px 20px; }
  .meta dd { font-size: var(--step-0); }
  .faq { max-width: 540px; }
}

/* ---------- Motion ------------------------------------------------------ */

@media (prefers-reduced-motion: no-preference) {
  .page > * { opacity: 0; transform: translateY(8px); animation: rise 900ms var(--ease) forwards; }
  .page > *:nth-child(1) { animation-delay: 60ms; }
  .page > *:nth-child(2) { animation-delay: 180ms; }
  .page > *:nth-child(3) { animation-delay: 260ms; }
  .page > *:nth-child(4) { animation-delay: 340ms; }
  .page > *:nth-child(5) { animation-delay: 420ms; }
  .page > *:nth-child(6) { animation-delay: 500ms; }
  .page > *:nth-child(7) { animation-delay: 580ms; }
  .page > *:nth-child(8) { animation-delay: 660ms; }
  .page > *:nth-child(9) { animation-delay: 740ms; }
  .page > *:nth-child(10) { animation-delay: 820ms; }
  .page > *:nth-child(11) { animation-delay: 900ms; }
  .page > *:nth-child(n+12) { animation-delay: 980ms; }
}
@keyframes rise { to { opacity: 1; transform: none; } }
