/* Szikra Szalon: booking widget styles. TOKEN-DRIVEN: every colour, font and radius below
   comes from a --szb-* custom property. The defaults live in :where(:root), which has ZERO
   specificity, so the real site design overrides any of them with a plain `:root { --szb-accent: … }`
   regardless of stylesheet order. Token list + meaning: BOOKING-MOUNT.md. Upright only, no italics. */

:where(:root) {
  --szb-bg: #fdfbf7;             /* dialog background */
  --szb-surface: #ffffff;        /* cards, inputs */
  --szb-sand: #f5f0e6;           /* header strip, summary boxes, hover */
  --szb-ink: #3d2c1f;            /* main text */
  --szb-ink-soft: #7a6250;       /* secondary text */
  --szb-accent: #8c6546;         /* primary buttons, selected state */
  --szb-accent-deep: #6b4c33;    /* hover on primary */
  --szb-on-accent: #fdfbf7;      /* text on accent */
  --szb-highlight: #d4a373;      /* focus ring, add-on callout edge */
  --szb-highlight-soft: #f7efe5; /* add-on callout background */
  --szb-hairline: rgba(61, 44, 31, 0.14);
  --szb-danger-bg: #f7e2dc;
  --szb-danger-ink: #8a2b1e;
  --szb-backdrop: rgba(40, 28, 20, 0.5);
  --szb-radius: 12px;
  --szb-radius-sm: 8px;
  --szb-radius-pill: 9999px;
  --szb-font-display: Georgia, 'Times New Roman', serif;
  --szb-font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  --szb-font-label: var(--szb-font-body);
  /* Label case + tracking. Default: sentence case, no tracking (Szikra's site has no ALL-CAPS
     labels). A site that wants tracked capitals sets e.g. uppercase / 0.12em on :root. */
  --szb-label-case: none;
  --szb-label-tracking: normal;
  /* Emphasis weight. 500 because the site self-hosts Jost 400/500 only; 600/700 would be faux bold. */
  --szb-weight-strong: 500;
  /* CTA on the page (outside the dialog) */
  --szb-cta-bg: var(--szb-accent);
  --szb-cta-ink: var(--szb-on-accent);
  --szb-cta-note-ink: var(--szb-ink-soft);
  /* The spark on the success screen and the loading star (2026-09-26). */
  --szb-spark: var(--szb-highlight);          /* the gold of the spark and its dots */
  --szb-spark-deep: var(--szb-accent);        /* the flare's edge, the three tiny stars, the loading star */
  --szb-spark-light: var(--szb-surface);      /* the flare's bright centre */
}

.szb-dialog, .szb-dialog * { font-style: normal; box-sizing: border-box; }

/* ---- the CTA injected into the page's booking slot ---- */
.booking-mount { margin-bottom: 1.5rem; }
.szb-open {
  font-family: var(--szb-font-label); font-size: 1rem; font-weight: 500; line-height: 1.2;
  letter-spacing: var(--szb-label-tracking); text-transform: var(--szb-label-case);
  background: var(--szb-cta-bg); color: var(--szb-cta-ink); border: 1px solid transparent;
  border-radius: var(--szb-radius-pill); padding: 0.95rem 1.9rem; cursor: pointer;
}
.szb-open:hover { filter: brightness(0.94); }
.szb-open:focus-visible { outline: 2px solid var(--szb-highlight); outline-offset: 3px; }
.szb-open-note { margin: 0.8rem 0 0; font-size: 0.88rem; color: var(--szb-cta-note-ink); max-width: 40ch; font-family: var(--szb-font-body); }
.szb-off-notice { margin: 0 0 1.2rem; color: var(--szb-cta-note-ink); font-size: 0.95rem; line-height: 1.5; }
@media (max-width: 640px) { .szb-open { width: 100%; } }

/* ---- dialog ---- */
.szb-dialog {
  border: none; padding: 0; width: min(720px, 94vw); max-height: 92vh;
  background: var(--szb-bg); color: var(--szb-ink); font-family: var(--szb-font-body);
  border-radius: var(--szb-radius); box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28); overflow: hidden;
}
.szb-dialog::backdrop { background: var(--szb-backdrop); backdrop-filter: blur(2px); }
.szb-frame { display: flex; flex-direction: column; max-height: 92vh; }
.szb-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1rem clamp(1rem, 4vw, 2rem); border-bottom: 1px solid var(--szb-hairline); background: var(--szb-sand);
}
.szb-eyebrow { margin: 0; font-family: var(--szb-font-display); font-size: 1.15rem; letter-spacing: var(--szb-label-tracking); text-transform: var(--szb-label-case); color: var(--szb-ink); }
.szb-close { border: none; background: transparent; cursor: pointer; font-size: 1.7rem; line-height: 1; color: var(--szb-ink-soft); padding: 0 0.25rem; }
.szb-close:hover { color: var(--szb-accent); }
/* overflow-x hidden: the success spark's outer dots may pass the edge; they must never make the body scroll sideways */
.szb-body { padding: clamp(1rem, 4vw, 2rem); overflow-y: auto; overflow-x: hidden; }
.szb-dialog p { margin: 0; }

/* ---- steps ---- */
.szb-steps { display: flex; gap: 0.4rem; list-style: none; margin: 0 0 1.3rem; padding: 0; flex-wrap: wrap; }
.szb-step {
  font-family: var(--szb-font-label); font-size: 0.85rem; letter-spacing: var(--szb-label-tracking); text-transform: var(--szb-label-case);
  color: var(--szb-ink-soft); padding: 0.3rem 0.75rem; border-radius: var(--szb-radius-pill); background: var(--szb-sand);
}
.szb-step.is-current { background: var(--szb-accent); color: var(--szb-on-accent); }
.szb-step.is-done { color: var(--szb-accent); cursor: pointer; }
.szb-step.is-done:focus-visible { outline: 2px solid var(--szb-highlight); outline-offset: 2px; }

.szb-h { font-family: var(--szb-font-display); font-weight: 500; font-size: clamp(1.4rem, 3.6vw, 1.9rem); color: var(--szb-ink); margin: 0 0 0.8rem; line-height: 1.2; }
.szb-msg { color: var(--szb-ink-soft); font-size: 0.97rem; line-height: 1.6; margin: 0.4rem 0 !important; }
.szb-group { font-family: var(--szb-font-label); font-size: 0.95rem; font-weight: 500; letter-spacing: var(--szb-label-tracking); text-transform: var(--szb-label-case); color: var(--szb-accent); margin: 1.2rem 0 0.4rem !important; }
.szb-hint { font-size: 0.86rem; color: var(--szb-ink-soft); margin: 0 0 0.6rem !important; }

/* ---- item cards (toggle buttons; aria-pressed carries the state) ---- */
.szb-items { display: grid; gap: 0.5rem; }
.szb-items--compact { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.szb-item {
  display: grid; gap: 0.25rem; width: 100%; text-align: left; cursor: pointer; font-family: inherit; color: var(--szb-ink);
  background: var(--szb-surface); border: 1px solid var(--szb-hairline); border-radius: var(--szb-radius-sm);
  padding: 0.8rem 1rem; transition: border-color 0.16s ease, background 0.16s ease, box-shadow 0.16s ease;
}
.szb-item:hover { border-color: var(--szb-highlight); }
.szb-item:focus-visible { outline: 2px solid var(--szb-highlight); outline-offset: 2px; }
.szb-item.is-on { border-color: var(--szb-accent); background: var(--szb-sand); box-shadow: inset 0 0 0 1px var(--szb-accent); }
.szb-item-top { display: flex; align-items: baseline; gap: 0.6rem; }
.szb-tick {
  flex: none; width: 1.05rem; height: 1.05rem; border: 1.5px solid var(--szb-hairline); background: var(--szb-surface);
  align-self: center; display: inline-flex; align-items: center; justify-content: center; font-size: 0.72rem; line-height: 1;
}
.szb-item--main .szb-tick { border-radius: 50%; }
.szb-item--extra .szb-tick { border-radius: 4px; }
.szb-item.is-on .szb-tick { background: var(--szb-accent); border-color: var(--szb-accent); color: var(--szb-on-accent); }
.szb-item.is-on .szb-tick::after { content: '\2713'; }
.szb-iname { font-family: var(--szb-font-display); font-size: 1.12rem; flex: 1 1 auto; }
.szb-items--compact .szb-iname { font-family: var(--szb-font-body); font-size: 0.97rem; }
.szb-imeta { font-size: 0.84rem; color: var(--szb-ink-soft); white-space: nowrap; }
.szb-idesc { font-size: 0.86rem; color: var(--szb-ink-soft); line-height: 1.45; padding-left: 1.65rem; }

/* ---- the extras section: becomes a highlighted "add to your facial?" callout once a facial is picked ---- */
.szb-extras { margin-top: 1.4rem; padding: 1rem 1.1rem 1.1rem; border: 1px dashed var(--szb-hairline); border-radius: var(--szb-radius); transition: background 0.2s ease, border-color 0.2s ease; }
.szb-extras.is-addon { background: var(--szb-highlight-soft); border: 1px solid var(--szb-highlight); }
.szb-extras-h { margin: 0; font-family: var(--szb-font-display); font-weight: 500; font-size: 1.3rem; color: var(--szb-ink); }
.szb-extras-sub { font-size: 0.88rem; color: var(--szb-ink-soft); margin: 0.2rem 0 0 !important; }

/* ---- sticky running total ---- */
.szb-bar {
  position: sticky; bottom: calc(-1 * clamp(1rem, 4vw, 2rem)); margin: 1.2rem calc(-1 * clamp(1rem, 4vw, 2rem)) calc(-1 * clamp(1rem, 4vw, 2rem));
  padding: 0.85rem clamp(1rem, 4vw, 2rem); background: var(--szb-bg); border-top: 1px solid var(--szb-hairline);
  display: flex; gap: 0.8rem; align-items: center; justify-content: space-between; flex-wrap: wrap;
}
.szb-bar-text { font-size: 0.95rem; font-weight: var(--szb-weight-strong); color: var(--szb-ink); }

/* ---- calendar ---- */
.szb-nowrap { white-space: nowrap; }
.szb-basketline { font-size: 0.92rem; color: var(--szb-ink-soft); margin: -0.3rem 0 1rem !important; }
.szb-calnav { display: flex; align-items: center; justify-content: space-between; margin-bottom: 0.8rem; max-width: 24rem; }
.szb-calmonth { font-family: var(--szb-font-display); font-size: 1.25rem; color: var(--szb-ink); }
.szb-navbtn { border: 1px solid var(--szb-hairline); background: var(--szb-surface); color: var(--szb-accent); width: 2.3rem; height: 2.3rem; border-radius: 50%; cursor: pointer; font-size: 1.2rem; line-height: 1; }
.szb-navbtn:disabled { opacity: 0.35; cursor: not-allowed; }
/* capped width: full-width square cells were ~90px tall in the 720px dialog */
.szb-cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 0.3rem; max-width: 24rem; }
.szb-cal-wd { text-align: center; font-family: var(--szb-font-label); font-size: 0.8rem; letter-spacing: var(--szb-label-tracking); text-transform: var(--szb-label-case); color: var(--szb-ink-soft); padding-bottom: 0.35rem; }
.szb-cal-empty { aspect-ratio: 1; }
.szb-cal-day { aspect-ratio: 1; display: flex; align-items: center; justify-content: center; border-radius: var(--szb-radius-sm); font-size: 0.95rem; font-family: var(--szb-font-body); border: 1px solid transparent; }
.szb-cal-day.is-off { color: var(--szb-ink-soft); opacity: 0.4; }
.szb-cal-day.is-open { background: var(--szb-sand); color: var(--szb-ink); border-color: var(--szb-hairline); cursor: pointer; font-weight: var(--szb-weight-strong); }
.szb-cal-day.is-open:hover, .szb-cal-day.is-selected { background: var(--szb-accent); color: var(--szb-on-accent); border-color: var(--szb-accent); }
.szb-cal-day:focus-visible { outline: 2px solid var(--szb-highlight); outline-offset: 2px; }
.szb-slotwrap { margin-top: 1.2rem; }
.szb-slotlabel { font-family: var(--szb-font-label); font-size: 0.95rem; font-weight: 500; letter-spacing: var(--szb-label-tracking); text-transform: var(--szb-label-case); color: var(--szb-accent); margin-bottom: 0.6rem !important; }
.szb-slots { display: flex; flex-wrap: wrap; gap: 0.45rem; }
.szb-slot { border: 1px solid var(--szb-hairline); background: var(--szb-surface); color: var(--szb-ink); border-radius: var(--szb-radius-pill); padding: 0.5rem 0.95rem; font-size: 0.92rem; cursor: pointer; font-family: var(--szb-font-body); }
.szb-slot:hover, .szb-slot.is-selected { background: var(--szb-accent); color: var(--szb-on-accent); }
.szb-slot.is-selected { border-color: var(--szb-accent); }
.szb-slot:focus-visible { outline: 2px solid var(--szb-highlight); outline-offset: 2px; }
/* one-shot notice above the calendar: a chosen time that no longer fits the changed basket, or a refused start */
.szb-notice { background: var(--szb-highlight-soft); border: 1px solid var(--szb-highlight); color: var(--szb-ink); border-radius: var(--szb-radius-sm); padding: 0.6rem 0.85rem; font-size: 0.92rem; line-height: 1.5; margin: 0 0 1rem !important; max-width: 32rem; }

/* ---- summary + form ---- */
.szb-summary { background: var(--szb-sand); border-radius: var(--szb-radius-sm); padding: 0.9rem 1.1rem; margin-bottom: 1.2rem; }
.szb-sum-when { font-weight: var(--szb-weight-strong); margin-bottom: 0.4rem !important; }
.szb-sumlist { list-style: none; margin: 0; padding: 0; }
.szb-sumlist li { display: flex; justify-content: space-between; gap: 1rem; padding: 0.2rem 0; font-size: 0.95rem; }
.szb-summeta { color: var(--szb-ink-soft); white-space: nowrap; }
.szb-sumlist .szb-sumtotal { border-top: 1px solid var(--szb-hairline); margin-top: 0.3rem; padding-top: 0.45rem; font-weight: var(--szb-weight-strong); }
.szb-form { display: grid; gap: 0.85rem; }
.szb-label { display: grid; gap: 0.3rem; }
.szb-labeltext { font-family: var(--szb-font-label); font-size: 0.9rem; font-weight: 500; letter-spacing: var(--szb-label-tracking); text-transform: var(--szb-label-case); color: var(--szb-ink-soft); }
.szb-input { width: 100%; font-family: var(--szb-font-body); font-size: 1rem; color: var(--szb-ink); background: var(--szb-surface); border: 1px solid var(--szb-hairline); border-radius: var(--szb-radius-sm); padding: 0.7rem 0.85rem; }
.szb-input:focus { outline: 2px solid var(--szb-highlight); outline-offset: 1px; }
textarea.szb-input { resize: vertical; min-height: 3.4rem; }
.szb-check { display: flex; align-items: flex-start; gap: 0.6rem; font-size: 0.93rem; line-height: 1.5; }
.szb-check input { margin-top: 0.2rem; width: 1.05rem; height: 1.05rem; accent-color: var(--szb-accent); }
.szb-consent a { color: var(--szb-accent); }
.szb-fieldset { border: 1px solid var(--szb-hairline); border-radius: var(--szb-radius-sm); padding: 0.6rem 0.9rem; display: flex; gap: 1.2rem; align-items: center; flex-wrap: wrap; margin: 0; }
.szb-fieldset legend { font-family: var(--szb-font-label); font-size: 0.9rem; font-weight: 500; letter-spacing: var(--szb-label-tracking); text-transform: var(--szb-label-case); color: var(--szb-ink-soft); padding: 0 0.4rem; }
.szb-radio { display: inline-flex; align-items: center; gap: 0.4rem; font-size: 0.93rem; }
.szb-radio input { accent-color: var(--szb-accent); }
.szb-policy { font-size: 0.84rem; color: var(--szb-ink-soft); line-height: 1.55; }
.szb-formerr { background: var(--szb-danger-bg); color: var(--szb-danger-ink); border-radius: var(--szb-radius-sm); padding: 0.65rem 0.85rem; font-size: 0.9rem; }
.szb-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.szb-cf { margin: 0.4rem 0; }

/* ---- buttons ---- */
.szb-actions { display: flex; gap: 0.7rem; margin-top: 0.6rem; flex-wrap: wrap; }
.szb-btn { font-family: var(--szb-font-label); font-size: 0.97rem; font-weight: 500; line-height: 1.2; letter-spacing: var(--szb-label-tracking); text-transform: var(--szb-label-case); border-radius: var(--szb-radius-pill); padding: 0.85rem 1.6rem; cursor: pointer; border: 1px solid transparent; }
.szb-btn--primary { background: var(--szb-accent); color: var(--szb-on-accent); }
.szb-btn--primary:hover:not(:disabled) { background: var(--szb-accent-deep); }
.szb-btn--primary:disabled { opacity: 0.45; cursor: not-allowed; }
.szb-btn--ghost { background: transparent; color: var(--szb-accent); border-color: var(--szb-hairline); }
.szb-btn--ghost:hover { background: var(--szb-sand); }
.szb-btn:focus-visible { outline: 2px solid var(--szb-highlight); outline-offset: 2px; }

/* ---- loading: the four-point star turning slowly, a soft glow breathing behind it ---- */
.szb-loading { display: flex; align-items: center; gap: 0.75rem; }
.szb-loader { position: relative; flex: none; width: 22px; height: 22px; color: var(--szb-spark-deep); }
.szb-loader svg { position: absolute; inset: 0; width: 100%; height: 100%; fill: currentColor; overflow: visible; }
.szb-loader-glow { position: absolute; inset: -9px; border-radius: 50%; opacity: 0; background: radial-gradient(closest-side, color-mix(in srgb, var(--szb-spark) 50%, transparent), transparent); }
@media (prefers-reduced-motion: no-preference) {
  .szb-loader svg { animation: szb-turn 2.4s cubic-bezier(.65, 0, .35, 1) infinite; }
  .szb-loader-glow { animation: szb-breathe 2.4s ease-in-out infinite; }
}
@keyframes szb-turn {
  0%   { transform: rotate(0deg) scale(.82); }
  50%  { transform: rotate(45deg) scale(1.06); }
  100% { transform: rotate(90deg) scale(.82); }
}
@keyframes szb-breathe { 0%, 100% { opacity: 0; } 50% { opacity: 1; } }

/* ---- success ---- */
.szb-success { text-align: center; }
.szb-success.is-in { animation: szb-rise .55s cubic-bezier(.2, .7, .2, 1) both; }
@keyframes szb-rise { from { opacity: 0; transform: translate3d(0, 8px, 0); } to { opacity: 1; transform: none; } }
.szb-check-badge { position: relative; z-index: 2; width: 3.2rem; height: 3.2rem; border-radius: 50%; margin: 0 auto 1rem; display: flex; align-items: center; justify-content: center; background: var(--szb-accent); color: var(--szb-on-accent); font-size: 1.6rem; }
.szb-success .szb-summary { text-align: left; margin-top: 1.1rem; }
.szb-success .szb-actions { justify-content: center; }

/* The spark (booking.js sparkBurst): its origin is 0.9rem above the heading box, in the gap under the check,
   so the flare sits behind the check and the top of the title but never washes out a letter. The check sits
   above it (z-index 2), the title above it too. Every part is moved by transform and opacity only. */
.szb-success-head { position: relative; isolation: isolate; }
.szb-success-head .szb-h { position: relative; z-index: 1; }
.szb-burst { position: absolute; left: 50%; top: -0.9rem; width: 0; height: 0; z-index: 0; pointer-events: none; }
.szb-burst > * { position: absolute; left: 0; top: 0; opacity: 0; will-change: transform, opacity; }
.szb-burst-glow {
  width: 260px; height: 260px; margin: -130px 0 0 -130px; border-radius: 50%;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--szb-spark) 34%, transparent), color-mix(in srgb, var(--szb-spark) 12%, transparent) 50%, transparent);
}
/* the flare is wider than tall (a lens glint), so its lower ray stops short of the letters */
.szb-burst-star { width: 104px; height: 50px; margin: -25px 0 0 -52px; }
.szb-burst-star--small { width: 42px; height: 42px; margin: -21px 0 0 -21px; }
.szb-burst-star svg, .szb-burst-mini svg { display: block; width: 100%; height: 100%; overflow: visible; }
.szb-burst-star--small svg { fill: var(--szb-spark-light); }
.szb-burst .szb-stop-light { stop-color: var(--szb-spark-light); }
.szb-burst .szb-stop-gold { stop-color: var(--szb-spark); }
.szb-burst .szb-stop-deep { stop-color: var(--szb-spark-deep); }
.szb-burst-dot { width: 4px; height: 4px; margin: -2px 0 0 -2px; border-radius: 50%; background: var(--szb-spark); box-shadow: 0 0 6px 1px color-mix(in srgb, var(--szb-spark) 60%, transparent); }
.szb-burst-mini { width: 12px; height: 12px; margin: -6px 0 0 -6px; }
.szb-burst-mini svg { fill: var(--szb-spark-deep); }

@media (max-width: 560px) {
  .szb-dialog { width: 100vw; max-width: 100vw; height: 100dvh; max-height: 100dvh; border-radius: 0; }
  .szb-frame { max-height: 100dvh; height: 100dvh; }
  .szb-item-top { flex-wrap: wrap; }
  .szb-imeta { width: 100%; padding-left: 1.65rem; white-space: normal; }
  .szb-bar .szb-btn { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .szb-item, .szb-extras { transition: none; }
  .szb-success.is-in { animation: none; }
}
