:root {
  --bg: #0a0a0a;
  --surface: #1c1c1e;
  --surface-2: #262628;
  --text: #f5f5f5;
  --muted: #8e8e93;
  --accent: #ffd400;
  --accent-text: #0a0a0a;
  --ok: #8ce99a;
  --bad: #ff6b6b;
  --radius-lg: 28px;
  --radius-md: 24px;
  --radius-sm: 20px;
  --radius-btn: 16px;
  --radius-chip: 12px;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html { color-scheme: dark; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 15px/1.5 'Sora', 'SF Pro Display', 'Helvetica Neue', Arial, sans-serif;
}

.wrap {
  max-width: 720px;
  margin: 0 auto;
  padding: 16px 16px 48px;
}

/* --- hero: the one solid-yellow block on the page --------------------- */
.hero {
  background: var(--accent);
  color: var(--accent-text);
  border-radius: var(--radius-lg);
  padding: 24px 24px 22px;
  margin-bottom: 20px;
}
.hero-eyebrow {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  opacity: .72;
  margin: 0 0 6px;
}
.hero-title {
  font-size: 27px;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 10px;
}
.hero-meta {
  font-size: 15px;
  font-weight: 500;
  color: rgba(10, 10, 10, .72);
  margin: 0;
}

/* --- generic card ------------------------------------------------------ */
.card {
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 20px 20px 18px;
  margin-bottom: 16px;
}

h2.section-title, .section-title {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--muted);
  margin: 0 0 12px;
}

.intro p { margin: 0 0 10px; line-height: 1.6; }
.intro p:last-child { margin-bottom: 0; }

.map-frame {
  width: 100%;
  aspect-ratio: 16 / 10;
  border: 0;
  border-radius: var(--radius-sm);
  display: block;
}

/* --- form ---------------------------------------------------------------*/
.field { margin-bottom: 14px; }
.field label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 6px;
}
.field input[type="text"],
.field input[type="number"] {
  width: 100%;
  background: var(--surface-2);
  border: none;
  border-radius: var(--radius-btn);
  padding: 14px 16px;
  min-height: 48px;
  color: var(--text);
  font: inherit;
  caret-color: var(--accent);
  outline: none;
}
.field input:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.attend-toggle {
  display: flex;
  gap: 10px;
  margin-bottom: 18px;
}
.attend-btn {
  flex: 1;
  min-height: 48px;
  border: none;
  border-radius: var(--radius-btn);
  background: var(--surface-2);
  color: var(--text);
  font: inherit;
  font-weight: 500;
  cursor: pointer;
  transition: background .15s, transform .15s;
}
.attend-btn:active { transform: scale(.96); }
.attend-btn.selected.yes { background: var(--accent); color: var(--accent-text); font-weight: 600; }
.attend-btn.selected.no { background: var(--bad); color: #1a0303; font-weight: 600; }
.attend-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.counters {
  display: flex;
  gap: 12px;
  margin-bottom: 14px;
}
.counter { flex: 1; }
.counter-row {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--surface-2);
  border-radius: var(--radius-btn);
  padding: 6px;
}
.counter-row button {
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 12px;
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-weight: 700;
  font-size: 16px;
  cursor: pointer;
  transition: background .15s, transform .15s;
}
.counter-row button:active { transform: scale(.9); }
.counter-row output {
  flex: 1;
  text-align: center;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
  margin-bottom: 20px;
}
.chip {
  border: none;
  border-radius: var(--radius-chip);
  background: var(--surface-2);
  color: var(--text);
  font: inherit;
  font-size: 13px;
  font-weight: 500;
  padding: 8px 14px;
  cursor: pointer;
  transition: background .15s, transform .15s;
}
.chip:active { transform: scale(.95); }

.hidden { display: none !important; }

.submit-btn {
  width: 100%;
  min-height: 48px;
  border: none;
  border-radius: var(--radius-btn);
  background: var(--accent);
  color: var(--accent-text);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  transition: transform .15s, opacity .15s;
}
.submit-btn:active { transform: scale(.98); }
.submit-btn:disabled { opacity: .5; cursor: default; }
.submit-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.form-msg {
  margin-top: 12px;
  font-size: 13px;
  font-weight: 500;
  border-radius: var(--radius-chip);
  padding: 10px 14px;
}
.form-msg.error { background: rgba(255, 107, 107, .15); color: var(--bad); }
.form-msg.ok { background: rgba(140, 233, 154, .15); color: var(--ok); }

.confirm-box {
  margin-top: 12px;
  background: var(--surface-2);
  border-radius: var(--radius-btn);
  padding: 14px 16px;
}
.confirm-box p { margin: 0 0 10px; font-size: 14px; }
.confirm-actions { display: flex; gap: 10px; }
.confirm-actions button {
  flex: 1;
  min-height: 44px;
  border: none;
  border-radius: 14px;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}
.confirm-yes { background: var(--accent); color: var(--accent-text); }
.confirm-no { background: var(--surface); color: var(--text); }

/* --- guest list ---------------------------------------------------------*/
.totals-line {
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  margin: 0 0 14px;
  font-variant-numeric: tabular-nums;
}
.guest-list { list-style: none; margin: 0; padding: 0; }
.guest-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  padding: 12px 0;
  border-bottom: none;
  opacity: 0;
  animation: rise .3s ease forwards;
  animation-delay: calc(var(--i) * 8ms);
}
.guest-row + .guest-row { box-shadow: inset 0 1px 0 0 var(--surface-2); }
.guest-name { font-weight: 600; }
.guest-tags { color: var(--muted); font-size: 13px; margin-left: 8px; font-weight: 500; }
.guest-brings { color: var(--muted); font-size: 13px; text-align: right; max-width: 55%; }
.empty-state { color: var(--muted); font-size: 14px; padding: 8px 0; }

@keyframes rise {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

.footer {
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  margin-top: 8px;
}
.footer a { color: var(--muted); }

@media (max-width: 480px) {
  .wrap { padding: 12px 16px 40px; }
  .hero-title { font-size: 23px; }
  .counters { flex-direction: column; }
}

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