/* Emerald-in-the-East: 90th Birthday Celebration. Minimal: ivory page, midnight ink, champagne gold, emerald accent. */
@font-face { font-family: 'Cormorant'; font-weight: 500; font-style: normal; font-display: swap; src: url(fonts/cormorant-garamond-latin-500-normal.woff2) format('woff2'); }
@font-face { font-family: 'Cormorant'; font-weight: 600; font-style: normal; font-display: swap; src: url(fonts/cormorant-garamond-latin-600-normal.woff2) format('woff2'); }
@font-face { font-family: 'Cormorant'; font-weight: 700; font-style: normal; font-display: swap; src: url(fonts/cormorant-garamond-latin-700-normal.woff2) format('woff2'); }
@font-face { font-family: 'Cormorant'; font-weight: 500; font-style: italic; font-display: swap; src: url(fonts/cormorant-garamond-latin-500-italic.woff2) format('woff2'); }
@font-face { font-family: 'Cinzel'; font-weight: 600; font-style: normal; font-display: swap; src: url(fonts/cinzel-latin-600-normal.woff2) format('woff2'); }
@font-face { font-family: 'Cinzel'; font-weight: 700; font-style: normal; font-display: swap; src: url(fonts/cinzel-latin-700-normal.woff2) format('woff2'); }
@font-face { font-family: 'DM Sans'; font-weight: 400; font-style: normal; font-display: swap; src: url(fonts/dm-sans-latin-400-normal.woff2) format('woff2'); }
@font-face { font-family: 'DM Sans'; font-weight: 500; font-style: normal; font-display: swap; src: url(fonts/dm-sans-latin-500-normal.woff2) format('woff2'); }
@font-face { font-family: 'DM Sans'; font-weight: 700; font-style: normal; font-display: swap; src: url(fonts/dm-sans-latin-700-normal.woff2) format('woff2'); }

:root {
  --ink: #0b1630;          /* midnight, from the banner */
  --ink-2: #1c2a4d;
  --bg: #f7f4ec;           /* ivory page */
  --card: #ffffff;
  --text: #18202f;
  --muted: #6b6457;
  --line: #e4dccb;
  --line-2: #d6cbb3;
  --gold: #a9853a;         /* champagne gold, dark enough to read on white */
  --gold-soft: #f3ead4;
  --emerald: #0f7a55;
  --emerald-soft: #e6f3ed;
  --danger: #b3261e;
  --focus: #0f7a55;
  --r: 14px;
  --serif: 'Cormorant', Georgia, 'Times New Roman', serif;
  --caps: 'Cinzel', Georgia, serif;
  --sans: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
  color-scheme: light;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.55 var(--sans); }
[hidden] { display: none !important; }

/* ---------- Banner ---------- */
.hero { background: var(--ink); }
.banner { display: block; width: 100%; max-width: 1400px; height: auto; margin: 0 auto; }

/* ---------- Layout ---------- */
.wrap { max-width: 620px; margin: 0 auto; padding: 36px 20px 24px; }

.event { text-align: center; margin-bottom: 26px; }
.eyebrow { margin: 0 0 8px; font-family: var(--caps); font-weight: 600; font-size: .78rem; letter-spacing: .22em; text-transform: uppercase; color: var(--gold); }
.event h1 { margin: 0; font-family: var(--serif); font-weight: 500; font-style: italic; font-size: clamp(1.55rem, 4.6vw, 2rem); line-height: 1.2; color: var(--ink); }
.event h1 sup { font-size: .55em; }
.event h1 span { display: block; font-family: var(--caps); font-style: normal; font-weight: 700; font-size: .92em; letter-spacing: .02em; margin-top: 4px; }
.facts { list-style: none; margin: 22px 0 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; text-align: left; }
.facts li { background: var(--card); padding: 12px 16px; }
.facts li:last-child { grid-column: 1 / -1; }
.facts .k { display: block; font-size: .72rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); font-weight: 700; }
.facts .v { display: block; font-weight: 500; color: var(--ink); }
.charity { margin: 10px 0 0; color: var(--muted); font-size: .95rem; }
.charity strong { color: var(--ink); }
.badge { display: inline-block; margin: 16px 0 0; padding: 6px 16px; border-radius: 99px; background: var(--emerald-soft); color: var(--emerald); font-weight: 700; font-size: .9rem; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: 30px 28px 32px; box-shadow: 0 1px 2px rgba(11, 22, 48, .04), 0 12px 32px rgba(11, 22, 48, .06); }

.foot { text-align: center; padding: 8px 20px calc(36px + env(safe-area-inset-bottom)); color: var(--muted); font-size: .85rem; }
.foot img { display: block; margin: 0 auto 8px; opacity: .9; }
.foot p { margin: 0; }

@media (max-width: 560px) {
  .wrap { padding: 26px 16px 20px; }
  .card { padding: 24px 18px 26px; border-radius: 18px; }
  .facts { grid-template-columns: 1fr; }
}

/* ---------- Content ---------- */
h2 { margin: 0 0 6px; font-family: var(--serif); font-weight: 600; font-size: 1.85rem; line-height: 1.15; color: var(--ink); }
.stepno { margin: 0 0 4px; font-size: .74rem; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); font-weight: 700; }
.sub { margin: 0 0 22px; color: var(--muted); }
.center { text-align: center; }

.field { margin-top: 18px; }
label, .label, legend { display: block; font-weight: 600; font-size: .95rem; margin-bottom: 7px; padding: 0; color: var(--text); }
input, select {
  width: 100%; font: inherit; font-size: 16px; color: var(--text);
  background: var(--card); border: 1.5px solid var(--line-2); border-radius: 12px;
  padding: 12px 14px; min-height: 50px; transition: border-color .15s, box-shadow .15s;
}
input::placeholder { color: #a39b8b; }
select { appearance: none; -webkit-appearance: none; padding-right: 42px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9'%3E%3Cpath d='M1 1.5l6 6 6-6' fill='none' stroke='%236b6457' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 16px center; }
select:invalid { color: #a39b8b; }
select option { color: var(--text); }
input:focus, select:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 3px rgba(11, 22, 48, .12); }
[aria-invalid="true"] { border-color: var(--danger); }

.readonly { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 50px; padding: 8px 8px 8px 14px; background: var(--bg); border: 1.5px solid var(--line); border-radius: 12px; word-break: break-all; }
.hint { margin: 6px 0 0; color: var(--muted); font-size: .85rem; }
.error { color: var(--danger); font-size: .88rem; margin: 6px 0 0; }
.notice { margin: 0 0 6px; padding: 11px 14px; background: var(--gold-soft); border-radius: 10px; font-size: .92rem; color: #5b4a22; }
.notice.soft { background: var(--bg); color: var(--muted); }

fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.choice { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; position: relative; }
.choice.four { grid-template-columns: repeat(4, 1fr); }
.choice.num { grid-template-columns: repeat(6, 1fr); }
.choice input { position: absolute; opacity: 0; pointer-events: none; width: 1px; min-height: 0; }
.choice label {
  margin: 0; display: flex; align-items: center; justify-content: center; text-align: center;
  min-height: 48px; padding: 6px 8px; border: 1.5px solid var(--line-2); border-radius: 12px; background: var(--card);
  font-weight: 600; font-size: .95rem; cursor: pointer; transition: border-color .15s, background .15s, color .15s;
}
.choice label:hover { border-color: var(--ink-2); }
.choice input:checked + label { background: var(--ink); border-color: var(--ink); color: #fff; }
.choice input:focus-visible + label { outline: 3px solid var(--focus); outline-offset: 2px; }
.invalid .choice label { border-color: var(--danger); }
@media (max-width: 420px) { .choice.four { grid-template-columns: repeat(2, 1fr); } }

/* sections */
.sect { margin-top: 30px; padding-top: 24px; border-top: 1px solid var(--line); }
.sect-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.sect h3 { margin: 0; font-family: var(--serif); font-weight: 700; font-size: 1.5rem; color: var(--ink); }
.tag { flex: none; padding: 3px 12px; border-radius: 99px; background: var(--emerald-soft); color: var(--emerald); font-size: .8rem; font-weight: 700; }
.tag.soft { background: var(--bg); color: var(--muted); }
.when { margin: 2px 0 0; color: var(--muted); font-size: .92rem; }
.lead { margin: 8px 0 0; color: var(--text); }

/* a follow-up question that belongs to the one above it */
.nested { padding-left: 14px; border-left: 2px solid var(--gold-soft); }
.guest { margin-top: 14px; }
.guest .who { font-size: .85rem; font-weight: 700; color: var(--muted); margin-bottom: 6px; letter-spacing: .02em; }

/* donation */
.money { display: flex; align-items: stretch; border: 1.5px solid var(--line-2); border-radius: 12px; overflow: hidden; background: var(--card); transition: border-color .15s, box-shadow .15s; }
.money:focus-within { border-color: var(--ink); box-shadow: 0 0 0 3px rgba(11, 22, 48, .12); }
.money span { display: flex; align-items: center; padding: 0 14px; background: var(--bg); color: var(--muted); font-weight: 700; border-right: 1px solid var(--line); }
.money input { border: 0; border-radius: 0; box-shadow: none !important; font-size: 1.1rem; font-weight: 600; }
.money.bad { border-color: var(--danger); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.chip { font: inherit; font-size: .9rem; font-weight: 600; padding: 7px 14px; border-radius: 99px; border: 1.5px solid var(--line-2); background: var(--card); color: var(--ink); cursor: pointer; }
.chip:hover { border-color: var(--ink); }
.chip.on { background: var(--gold-soft); border-color: var(--gold); }
.chip:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }

/* summary before the button */
.total { margin-top: 28px; padding: 14px 16px; background: var(--bg); border: 1px solid var(--line); border-radius: var(--r); }
.total .row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 4px 0; }
.total .row small { display: block; color: var(--muted); font-size: .85rem; }
.total .amt { font-weight: 600; white-space: nowrap; }
.total .amt.free { color: var(--emerald); }
.total .grand { margin-top: 6px; padding-top: 10px; border-top: 1px solid var(--line); font-weight: 700; font-size: 1.08rem; color: var(--ink); }

/* buttons */
.btn {
  display: block; width: 100%; min-height: 54px; margin-top: 24px; padding: 0 20px;
  font: inherit; font-weight: 700; letter-spacing: .01em; color: #fff; background: var(--ink);
  border: 0; border-radius: 12px; cursor: pointer; transition: background .15s, transform .05s;
}
.btn:hover { background: var(--ink-2); }
.btn:active { transform: scale(.995); }
.btn:disabled { opacity: .6; cursor: default; }
.btn.ghost { background: transparent; color: var(--ink); border: 1.5px solid var(--ink); }
.btn.ghost:hover { background: var(--bg); }
.btn:focus-visible, .link:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.link { flex: none; background: none; border: 0; padding: 6px 8px; font: inherit; font-size: .92rem; font-weight: 700; color: var(--ink); text-decoration: underline; cursor: pointer; }

/* done */
.icon-ok { width: 64px; height: 64px; margin: 0 auto 14px; display: flex; align-items: center; justify-content: center; border-radius: 50%; background: var(--emerald-soft); color: var(--emerald); }
.summary { margin: 0; text-align: left; border: 1px solid var(--line); border-radius: var(--r); background: var(--bg); padding: 2px 16px; }
.summary div { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.summary div:last-child { border-bottom: 0; }
.summary dt { color: var(--muted); font-size: .9rem; flex: none; }
.summary dd { margin: 0; font-weight: 600; text-align: right; word-break: break-word; white-space: pre-line; }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
