/* ───────────────────────────────────────────────────────────────────────────
   sbSlots design system — shared by marketing, admin, and booking surfaces.
   Brand: electric indigo + cyan on white. Editorial, calm, premium.
   Per-org booking pages override the --brand-* vars from their saved palette;
   everything that should re-skin reads var(--brand-*), never a hardcoded hex.
   ─────────────────────────────────────────────────────────────────────────── */
:root {
  /* sbSlots brand (product chrome) */
  --c-indigo:      #4f46e5;
  --c-indigo-2:    #6366f1;
  --c-indigo-ink:  #312e81;
  --c-cyan:        #06b6d4;
  --c-cyan-2:      #22d3ee;
  --c-mint:        #10b981;
  --c-coral:       #f43f5e;
  --c-amber:       #f59e0b;

  /* Per-org brand — defaults to sbSlots indigo/cyan, overridden on booking pages */
  --brand-primary:   #4f46e5;
  --brand-accent:    #06b6d4;
  --brand-ink:       #1e1b4b;
  --brand-bg:        #ffffff;
  --brand-on:        #ffffff;   /* text that sits on the primary */

  /* Neutrals */
  --c-bg:        #ffffff;
  --c-bg-soft:   #fafaff;
  --c-bg-section:#f5f6fb;
  --c-bg-dark:   #0e1030;
  --c-ink:       #16182f;
  --c-ink-soft:  #3f4257;
  --c-ink-mute:  #71748a;
  --c-line:      #e6e7f0;
  --c-line-soft: #f0f1f7;
  --c-white:     #ffffff;

  --c-success:   #10b981;
  --c-warn:      #f59e0b;
  --c-danger:    #e11d48;

  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-display: "Sora", "Inter", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --r-sm: 8px; --r-md: 12px; --r-lg: 18px; --r-xl: 26px; --r-pill: 999px;
  --sh-sm: 0 1px 2px rgba(16,18,47,.06), 0 1px 3px rgba(16,18,47,.04);
  --sh-md: 0 4px 14px rgba(16,18,47,.08);
  --sh-lg: 0 18px 50px rgba(16,18,47,.14);
  --sh-glow: 0 10px 30px rgba(79,70,229,.30);
  --maxw: 1180px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; font-family: var(--font-sans); color: var(--c-ink);
  background: var(--c-bg); line-height: 1.6; font-size: 16px;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
h1,h2,h3,h4 { font-family: var(--font-display); font-weight: 700; line-height: 1.12; letter-spacing: -.02em; color: var(--c-ink); margin: 0 0 .4em; }
h1 { font-size: clamp(2.2rem, 5vw, 3.9rem); }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.7rem); }
h3 { font-size: 1.3rem; }
p { margin: 0 0 1rem; }
a { color: var(--c-indigo); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.muted { color: var(--c-ink-mute); }
.center { text-align: center; }
.eyebrow { font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--c-indigo); }

/* ── Wordmark ───────────────────────────────────────────────────────────── */
.wordmark { font-family: var(--font-display); font-weight: 800; letter-spacing: -.03em; font-size: 1.4rem; color: var(--c-ink); display: inline-flex; align-items: baseline; }
.wordmark .sb { color: var(--c-ink); }
.wordmark .rest { background: linear-gradient(120deg, var(--c-indigo), var(--c-cyan)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.wordmark .dot { width: .42em; height: .42em; border-radius: 50%; background: var(--c-cyan); margin-left: .12em; display: inline-block; }
.on-dark .wordmark .sb { color: #fff; }

/* ── Buttons ────────────────────────────────────────────────────────────── */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5em; font-family: var(--font-sans); font-weight: 600; font-size: .98rem; padding: .8em 1.5em; border-radius: var(--r-pill); border: 1.5px solid transparent; cursor: pointer; transition: transform .12s ease, box-shadow .2s ease, background .2s ease; text-decoration: none; line-height: 1; white-space: nowrap; }
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn-primary { background: var(--brand-primary); color: var(--brand-on); box-shadow: var(--sh-glow); }
.btn-primary:hover { box-shadow: 0 14px 38px rgba(79,70,229,.4); }
.btn-grad { background: linear-gradient(120deg, var(--c-indigo), var(--c-cyan)); color: #fff; box-shadow: var(--sh-glow); }
.btn-ghost { background: transparent; color: var(--c-ink); border-color: var(--c-line); }
.btn-ghost:hover { border-color: var(--c-indigo); color: var(--c-indigo); }
.btn-light { background: #fff; color: var(--c-indigo); }
.btn-sm { padding: .55em 1em; font-size: .88rem; }
.btn-lg { padding: 1em 1.9em; font-size: 1.05rem; }
.btn-block { width: 100%; }
.btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }

/* ── Cards / surfaces ───────────────────────────────────────────────────── */
.card { background: #fff; border: 1px solid var(--c-line); border-radius: var(--r-lg); box-shadow: var(--sh-sm); }
.panel { background: #fff; border: 1px solid var(--c-line); border-radius: var(--r-md); padding: 18px; }
.chip { display: inline-flex; align-items: center; gap: .4em; font-size: .76rem; font-weight: 600; padding: .3em .7em; border-radius: var(--r-pill); background: var(--c-bg-section); color: var(--c-ink-soft); }
.chip-on { background: color-mix(in srgb, var(--c-mint) 16%, transparent); color: #047857; }
.chip-warn { background: color-mix(in srgb, var(--c-amber) 18%, transparent); color: #92600a; }
.chip-off { background: color-mix(in srgb, var(--c-danger) 14%, transparent); color: #be123c; }

/* ── Forms ──────────────────────────────────────────────────────────────── */
label { font-size: .86rem; font-weight: 600; color: var(--c-ink-soft); display: block; margin-bottom: .35em; }
input[type=text], input[type=email], input[type=tel], input[type=password], input[type=number], input[type=date], input[type=time], input[type=url], select, textarea {
  width: 100%; font-family: var(--font-sans); font-size: .98rem; color: var(--c-ink);
  padding: .72em .9em; border: 1.5px solid var(--c-line); border-radius: var(--r-sm);
  background: #fff; transition: border-color .15s ease, box-shadow .15s ease;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand-primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand-primary) 16%, transparent); }
textarea { resize: vertical; min-height: 84px; }
.field { margin-bottom: 16px; }
.row { display: flex; gap: 14px; flex-wrap: wrap; }
.row > * { flex: 1; min-width: 0; }

/* color picker pair — native swatch + hex + live preview (standing rule) */
.colorpick { display: flex; align-items: center; gap: 8px; }
.colorpick input[type=color] { width: 44px; height: 38px; padding: 2px; border-radius: var(--r-sm); border: 1.5px solid var(--c-line); cursor: pointer; flex: 0 0 auto; }
.colorpick input[type=text] { font-family: var(--font-mono); text-transform: uppercase; max-width: 130px; flex: 0 0 auto; }
.colorpick .swatch-prev { width: 38px; height: 38px; border-radius: var(--r-sm); border: 1px solid var(--c-line); flex: 0 0 auto; }

/* ── Tables ─────────────────────────────────────────────────────────────── */
.table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.table th { text-align: left; font-weight: 600; color: var(--c-ink-mute); font-size: .76rem; text-transform: uppercase; letter-spacing: .05em; padding: 8px 10px; border-bottom: 1px solid var(--c-line); }
.table td { padding: 11px 10px; border-bottom: 1px solid var(--c-line-soft); vertical-align: middle; }
.table tr:hover td { background: var(--c-bg-soft); }

/* ── Utility ────────────────────────────────────────────────────────────── */
.grid { display: grid; gap: 22px; }
.flex { display: flex; }
.between { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.gap8 { gap: 8px; } .gap12 { gap: 12px; } .gap16 { gap: 16px; }
.mt0{margin-top:0}.mt8{margin-top:8px}.mt16{margin-top:16px}.mt24{margin-top:24px}.mt32{margin-top:32px}
.mb0{margin-bottom:0}.mb8{margin-bottom:8px}.mb16{margin-bottom:16px}.mb24{margin-bottom:24px}
.hidden { display: none !important; }
.spin { width: 18px; height: 18px; border: 2px solid color-mix(in srgb, var(--brand-primary) 30%, transparent); border-top-color: var(--brand-primary); border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(120%); background: var(--c-bg-dark); color: #fff; padding: 12px 20px; border-radius: var(--r-pill); font-weight: 600; font-size: .92rem; box-shadow: var(--sh-lg); z-index: 9999; transition: transform .35s cubic-bezier(.2,.9,.3,1.2); }
.toast.show { transform: translateX(-50%) translateY(0); }
.toast.err { background: var(--c-danger); }

@media (max-width: 720px) {
  .row { flex-direction: column; }
  .hide-sm { display: none !important; }
}
