/* ============================================================
   Funkey Monkey — public pages (landing, party booking, waiver,
   checkout). Mobile-first; one design system for every page a
   parent sees. No external fonts or CDNs: the demo must work offline.
   ============================================================ */

:root {
  --fm-ink: #1a2230;
  --fm-ink-2: #4a5568;
  --fm-muted: #7b8597;
  --fm-line: #e7e3da;
  --fm-bg: #fffaf1;
  --fm-surface: #ffffff;
  --fm-sunk: #f7f2e8;

  --fm-brand: #0e7c66;
  --fm-brand-ink: #0a5c4c;
  --fm-brand-soft: #e2f3ee;
  --fm-banana: #f5b301;
  --fm-banana-soft: #fff3cc;
  --fm-coral: #d9472f;
  --fm-coral-soft: #fde7e2;
  --fm-sky: #2f6fde;
  --fm-sky-soft: #e6eefc;

  --fm-radius: 14px;
  --fm-radius-sm: 10px;
  --fm-shadow: 0 1px 2px rgba(26, 34, 48, .06), 0 8px 24px rgba(26, 34, 48, .06);
  --fm-shadow-lg: 0 2px 4px rgba(26, 34, 48, .06), 0 18px 48px rgba(26, 34, 48, .12);
  --fm-font: "Segoe UI", Inter, system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  --fm-gutter: 16px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body.fm-public {
  margin: 0;
  font-family: var(--fm-font);
  font-size: 16px;
  line-height: 1.55;
  color: var(--fm-ink);
  background: var(--fm-bg);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.fm-public main { flex: 1; }
.fm-public a { color: var(--fm-brand); }
.fm-public img { max-width: 100%; }
.fm-public h1, .fm-public h2, .fm-public h3, .fm-public h4 {
  margin: 0 0 .4em; line-height: 1.15; letter-spacing: -.02em; font-weight: 800;
}
.fm-public h1 { font-size: clamp(2rem, 6vw, 3.4rem); }
.fm-public h2 { font-size: clamp(1.5rem, 4vw, 2.1rem); }
.fm-public h3 { font-size: 1.2rem; }
.fm-public p { margin: 0 0 1em; }
:focus-visible { outline: 3px solid var(--fm-banana); outline-offset: 2px; }

.fm-container { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 var(--fm-gutter); }
.fm-container-narrow { max-width: 760px; }
.fm-section { padding: 48px 0; }
.fm-eyebrow {
  display: inline-block; font-size: .78rem; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; color: var(--fm-brand); margin-bottom: 8px;
}
.fm-lead { font-size: 1.12rem; color: var(--fm-ink-2); }
.fm-muted { color: var(--fm-muted); }
.fm-small { font-size: .88rem; }
.fm-center { text-align: center; }
.fm-hidden { display: none !important; }
.fm-visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

/* ── Header / footer ─────────────────────────────────────── */
.fm-header {
  position: sticky; top: 0; z-index: 20;
  background: rgba(255, 250, 241, .92);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--fm-line);
}
.fm-header-inner { display: flex; align-items: center; gap: 16px; min-height: 64px; }
.fm-brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--fm-ink) !important; }
.fm-brand img { width: 38px; height: 38px; }
.fm-brand-name { font-weight: 800; font-size: 1.15rem; letter-spacing: -.02em; line-height: 1; }
.fm-brand-name span { color: var(--fm-brand); }
.fm-nav { margin-left: auto; display: flex; gap: 4px; align-items: center; }
.fm-nav a {
  text-decoration: none; color: var(--fm-ink-2); font-weight: 600; font-size: .95rem;
  padding: 8px 12px; border-radius: 999px;
}
.fm-nav a:hover, .fm-nav a.is-active { color: var(--fm-ink); background: var(--fm-sunk); }
.fm-nav .fm-btn { margin-left: 6px; }
@media (max-width: 680px) {
  .fm-nav a:not(.fm-btn) { display: none; }
}

.fm-footer { border-top: 1px solid var(--fm-line); padding: 28px 0; color: var(--fm-muted); font-size: .9rem; }
.fm-footer-inner { display: flex; flex-wrap: wrap; gap: 12px 24px; justify-content: space-between; align-items: center; }
.fm-footer a { color: var(--fm-ink-2); text-decoration: none; }
.fm-footer-links { display: flex; gap: 16px; flex-wrap: wrap; }

/* ── Buttons ─────────────────────────────────────────────── */
.fm-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 10px 20px; border-radius: 999px;
  border: 2px solid transparent; font: inherit; font-weight: 700; font-size: .98rem;
  text-decoration: none; cursor: pointer; transition: background .15s, border-color .15s, transform .05s;
  -webkit-tap-highlight-color: transparent; white-space: nowrap;
}
.fm-btn:active { transform: translateY(1px); }
.fm-btn[disabled], .fm-btn.is-disabled { opacity: .5; cursor: not-allowed; pointer-events: none; }
.fm-btn-primary { background: var(--fm-brand); color: #fff !important; }
.fm-btn-primary:hover { background: var(--fm-brand-ink); }
.fm-btn-banana { background: var(--fm-banana); color: var(--fm-ink) !important; }
.fm-btn-banana:hover { background: #e3a500; }
.fm-btn-outline { background: transparent; border-color: var(--fm-ink); color: var(--fm-ink) !important; }
.fm-btn-outline:hover { background: var(--fm-ink); color: #fff !important; }
.fm-btn-ghost { background: transparent; color: var(--fm-ink-2) !important; }
.fm-btn-ghost:hover { background: var(--fm-sunk); }
.fm-btn-danger { background: var(--fm-coral); color: #fff !important; }
.fm-btn-lg { min-height: 54px; padding: 14px 28px; font-size: 1.05rem; }
.fm-btn-sm { min-height: 36px; padding: 6px 14px; font-size: .88rem; }
.fm-btn-block { display: flex; width: 100%; }

/* ── Cards ───────────────────────────────────────────────── */
.fm-card {
  background: var(--fm-surface); border: 1px solid var(--fm-line); border-radius: var(--fm-radius);
  box-shadow: var(--fm-shadow); padding: 20px;
}
.fm-card-flat { box-shadow: none; }
.fm-card-title { font-weight: 800; font-size: 1.05rem; margin: 0 0 10px; }
.fm-grid { display: grid; gap: 16px; }
.fm-grid-2 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.fm-grid-3 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.fm-grid-4 { grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); }

/* Selectable option card: wrap an <input type=radio|checkbox> + content. */
.fm-option {
  position: relative; display: block; cursor: pointer;
  background: var(--fm-surface); border: 2px solid var(--fm-line); border-radius: var(--fm-radius);
  padding: 16px; transition: border-color .15s, box-shadow .15s, background .15s;
}
.fm-option:hover { border-color: #cfc8b8; }
.fm-option input { position: absolute; opacity: 0; pointer-events: none; }
.fm-option.is-selected, .fm-option:has(input:checked) {
  border-color: var(--fm-brand); background: var(--fm-brand-soft);
  box-shadow: 0 0 0 3px rgba(14, 124, 102, .12);
}
.fm-option:has(input:focus-visible) { outline: 3px solid var(--fm-banana); outline-offset: 2px; }
.fm-option.is-disabled { opacity: .45; cursor: not-allowed; background: var(--fm-sunk); }
.fm-option-check {
  position: absolute; top: 12px; right: 12px; width: 24px; height: 24px; border-radius: 50%;
  border: 2px solid var(--fm-line); background: #fff; display: grid; place-items: center;
  color: transparent; font-size: 14px; font-weight: 900;
}
.fm-option.is-selected .fm-option-check, .fm-option:has(input:checked) .fm-option-check {
  background: var(--fm-brand); border-color: var(--fm-brand); color: #fff;
}
.fm-option-price { font-weight: 800; font-size: 1.1rem; }
.fm-option-emoji { font-size: 1.8rem; line-height: 1; margin-bottom: 6px; display: block; }

/* ── Forms ───────────────────────────────────────────────── */
.fm-field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.fm-label { font-weight: 700; font-size: .92rem; }
.fm-label .fm-optional { font-weight: 500; color: var(--fm-muted); }
.fm-input, .fm-select, .fm-textarea {
  width: 100%; min-height: 48px; padding: 10px 14px; font: inherit; color: var(--fm-ink);
  background: #fff; border: 1.5px solid #d9d3c5; border-radius: var(--fm-radius-sm);
}
.fm-textarea { min-height: 96px; resize: vertical; }
.fm-input:focus, .fm-select:focus, .fm-textarea:focus {
  outline: none; border-color: var(--fm-brand); box-shadow: 0 0 0 3px rgba(14, 124, 102, .15);
}
.fm-input[aria-invalid="true"] { border-color: var(--fm-coral); }
.fm-help { font-size: .84rem; color: var(--fm-muted); }
.fm-error { font-size: .88rem; color: var(--fm-coral); font-weight: 600; min-height: 1.2em; }
.fm-row { display: grid; gap: 12px; grid-template-columns: 1fr; }
@media (min-width: 560px) { .fm-row-2 { grid-template-columns: 1fr 1fr; } }
.fm-checkline { display: flex; gap: 10px; align-items: flex-start; font-size: .95rem; cursor: pointer; }
.fm-checkline input { width: 22px; height: 22px; margin-top: 2px; accent-color: var(--fm-brand); flex: none; }

.fm-stepper-input { display: inline-flex; align-items: center; border: 1.5px solid #d9d3c5; border-radius: 999px; background: #fff; }
.fm-stepper-input button {
  width: 44px; height: 44px; border: 0; background: transparent; font-size: 1.3rem; font-weight: 700;
  color: var(--fm-brand); cursor: pointer; border-radius: 999px;
}
.fm-stepper-input button:disabled { color: #c9c3b6; cursor: not-allowed; }
.fm-stepper-input output { min-width: 40px; text-align: center; font-weight: 800; font-size: 1.1rem; }

/* ── Progress steps ──────────────────────────────────────── */
.fm-progress { display: flex; gap: 6px; margin: 4px 0 20px; }
.fm-progress span { flex: 1; height: 6px; border-radius: 99px; background: #ebe5d8; }
.fm-progress span.is-done { background: var(--fm-brand); }
.fm-progress span.is-current { background: var(--fm-banana); }
.fm-step-label { font-size: .85rem; color: var(--fm-muted); font-weight: 600; }

/* ── Chips, badges, alerts ───────────────────────────────── */
.fm-chip {
  display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 999px;
  border: 1.5px solid var(--fm-line); background: #fff; font-weight: 700; font-size: .92rem;
  cursor: pointer; color: var(--fm-ink);
}
.fm-chip.is-selected { background: var(--fm-ink); border-color: var(--fm-ink); color: #fff; }
.fm-chip.is-disabled { opacity: .45; cursor: not-allowed; text-decoration: line-through; }
.fm-badge {
  display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px; border-radius: 999px;
  font-size: .76rem; font-weight: 800; letter-spacing: .02em; background: var(--fm-sunk); color: var(--fm-ink-2);
}
.fm-badge-brand { background: var(--fm-brand-soft); color: var(--fm-brand-ink); }
.fm-badge-banana { background: var(--fm-banana-soft); color: #7a5600; }
.fm-badge-coral { background: var(--fm-coral-soft); color: #9a2d1b; }
.fm-alert {
  border-radius: var(--fm-radius-sm); padding: 12px 14px; font-size: .95rem;
  background: var(--fm-sky-soft); color: #1d4a99; border: 1px solid #cbdaf7;
}
.fm-alert-warn { background: var(--fm-banana-soft); color: #6b4c00; border-color: #f3dc8f; }
.fm-alert-error { background: var(--fm-coral-soft); color: #8d2715; border-color: #f5c3b8; }
.fm-alert-success { background: var(--fm-brand-soft); color: var(--fm-brand-ink); border-color: #b8e2d6; }
.fm-test-banner {
  background: repeating-linear-gradient(-45deg, #fff3cc, #fff3cc 12px, #ffeaa8 12px, #ffeaa8 24px);
  color: #6b4c00; text-align: center; font-weight: 800; font-size: .82rem; padding: 6px 12px;
  letter-spacing: .04em; border-bottom: 1px solid #f3dc8f;
}

/* ── Summary / receipt list ─────────────────────────────── */
.fm-summary { list-style: none; margin: 0; padding: 0; }
.fm-summary li { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px dashed var(--fm-line); }
.fm-summary li:last-child { border-bottom: 0; }
.fm-summary .fm-summary-total { font-weight: 800; font-size: 1.15rem; border-top: 2px solid var(--fm-ink); border-bottom: 0; padding-top: 12px; margin-top: 4px; }
.fm-summary .fm-summary-sub { color: var(--fm-muted); font-size: .88rem; }

/* ── Landing ────────────────────────────────────────────── */
.fm-hero { padding: 40px 0 24px; }
.fm-hero-grid { display: grid; gap: 28px; align-items: center; }
@media (min-width: 900px) { .fm-hero-grid { grid-template-columns: 1.1fr .9fr; } .fm-hero { padding: 72px 0 48px; } }
.fm-hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 20px; }
.fm-hero-art {
  position: relative; aspect-ratio: 1 / 1; max-width: 440px; margin: 0 auto; width: 100%;
  border-radius: 32px; background: var(--fm-brand); overflow: hidden; box-shadow: var(--fm-shadow-lg);
}
.fm-hero-art .fm-blob { position: absolute; border-radius: 50%; }
.fm-hero-art img { position: absolute; inset: 18% 18%; width: 64%; height: 64%; }
.fm-stat-row { display: flex; flex-wrap: wrap; gap: 24px; margin-top: 28px; }
.fm-stat-row strong { display: block; font-size: 1.6rem; font-weight: 800; }
.fm-stat-row span { color: var(--fm-muted); font-size: .9rem; }
.fm-feature-icon {
  width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center;
  font-size: 1.5rem; background: var(--fm-banana-soft); margin-bottom: 12px;
}
.fm-price-tag { font-size: 1.6rem; font-weight: 800; }
.fm-price-tag small { font-size: .85rem; color: var(--fm-muted); font-weight: 600; }
.fm-band {
  background: var(--fm-ink); color: #fff; border-radius: 24px; padding: 32px 24px;
  display: grid; gap: 16px; align-items: center;
}
@media (min-width: 760px) { .fm-band { grid-template-columns: 1fr auto; padding: 40px; } }
.fm-band p { color: #c9d1dd; margin: 0; }
.fm-list-check { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.fm-list-check li { display: flex; gap: 8px; font-size: .95rem; color: var(--fm-ink-2); }
.fm-list-check li::before { content: "✓"; color: var(--fm-brand); font-weight: 900; }

/* ── Simple page shell (waiver, confirmation, checkout) ─── */
.fm-page-head { padding: 28px 0 8px; }
.fm-sheet { background: var(--fm-surface); border-radius: 20px; box-shadow: var(--fm-shadow-lg); padding: 24px; border: 1px solid var(--fm-line); }
@media (max-width: 520px) { .fm-sheet { padding: 18px; border-radius: 16px; } }
.fm-sticky-bar {
  position: sticky; bottom: 0; z-index: 10; background: rgba(255, 255, 255, .96);
  border-top: 1px solid var(--fm-line); padding: 12px var(--fm-gutter);
  backdrop-filter: blur(8px);
}
.fm-sticky-inner { max-width: 1120px; margin: 0 auto; display: flex; align-items: center; gap: 12px; justify-content: space-between; }
.fm-spinner {
  width: 22px; height: 22px; border-radius: 50%; border: 3px solid rgba(255, 255, 255, .4);
  border-top-color: #fff; animation: fm-spin .8s linear infinite; display: inline-block;
}
.fm-spinner-dark { border-color: rgba(26, 34, 48, .15); border-top-color: var(--fm-brand); }
@keyframes fm-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .fm-spinner { animation-duration: 2s; } }
.fm-empty { text-align: center; padding: 28px 12px; color: var(--fm-muted); }
