/* =====================================================================
   Public Booking application
   Mobile-first: single column with a sticky selection bar; ≥992px shows a
   sticky summary card beside the steps.
   ===================================================================== */

.rp-booking { background: var(--rp-bg-booking); min-height: 100vh; display: flex; flex-direction: column; }

/* ---------- Header / footer ---------- */
.rp-bk-header { background: var(--rp-surface); border-bottom: 1px solid var(--rp-border); }
.rp-bk-header__inner { display: flex; align-items: center; justify-content: space-between; gap: var(--rp-space-4); min-height: var(--rp-header-h); }
.rp-bk-vendor { display: flex; align-items: center; gap: var(--rp-space-3); min-width: 0; }
.rp-bk-vendor__logo {
  display: inline-grid;
  place-items: center;
  flex-shrink: 0;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--rp-radius);
  background: var(--rp-slate-900);
  color: #fff;
  font-weight: var(--rp-fw-bold);
}
.rp-bk-vendor__name { font-weight: var(--rp-fw-semibold); margin: 0; font-size: var(--rp-fs-base); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rp-bk-help { font-size: var(--rp-fs-sm); font-weight: var(--rp-fw-semibold); display: inline-flex; align-items: center; gap: var(--rp-space-1); min-height: var(--rp-target-touch); }

.rp-bk-main { flex: 1 0 auto; padding-block: var(--rp-space-6) var(--rp-space-8); }
.rp-bk-footer { border-top: 1px solid var(--rp-border); background: var(--rp-surface); font-size: var(--rp-fs-sm); color: var(--rp-text-muted); }
.rp-bk-footer__inner { display: flex; flex-wrap: wrap; gap: var(--rp-space-2) var(--rp-space-5); justify-content: space-between; align-items: center; padding-block: var(--rp-space-4); }
.rp-bk-footer a { color: var(--rp-text-muted); }
.rp-bk-footer nav ul { display: flex; gap: var(--rp-space-4); list-style: none; margin: 0; padding: 0; }

/* ---------- Layout ---------- */
.rp-bk-layout { display: grid; grid-template-columns: minmax(0, 1fr) 22rem; gap: var(--rp-space-6); align-items: start; }
.rp-bk-steps { min-width: 0; }

/* ---------- Event header ---------- */
.rp-event-card { padding: var(--rp-space-5) var(--rp-space-6); margin-bottom: var(--rp-space-5); }
.rp-event-card h1 { font-size: var(--rp-fs-3xl); margin-bottom: var(--rp-space-2); }
.rp-event-card__desc { color: var(--rp-text-muted); margin-bottom: var(--rp-space-4); max-width: 42rem; }
.rp-event-facts { display: flex; flex-wrap: wrap; gap: var(--rp-space-3) var(--rp-space-6); list-style: none; margin: 0; padding: 0; font-size: var(--rp-fs-sm); }
.rp-event-facts li { display: flex; align-items: flex-start; gap: var(--rp-space-2); color: var(--rp-text); }
.rp-event-facts .bi { color: var(--rp-primary); font-size: 1rem; line-height: 1.4; }
.rp-event-facts span { color: var(--rp-text-muted); display: block; font-size: var(--rp-fs-xs); font-weight: var(--rp-fw-semibold); letter-spacing: 0.02em; }

/* ---------- Progress ---------- */
.rp-progress { margin-bottom: var(--rp-space-4); }
.rp-progress__text { font-size: var(--rp-fs-sm); color: var(--rp-text-muted); font-weight: var(--rp-fw-medium); margin-bottom: var(--rp-space-2); }
.rp-progress__track { display: grid; grid-template-columns: repeat(var(--rp-steps, 6), 1fr); gap: 4px; }
.rp-progress__seg { height: 4px; border-radius: var(--rp-radius-pill); background: var(--rp-slate-200); transition: background-color var(--rp-dur-slow) var(--rp-ease-out); }
.rp-progress__seg.is-done { background: var(--rp-primary); }

/* ---------- Step panel ---------- */
.rp-step { padding: var(--rp-space-5) var(--rp-space-6) var(--rp-space-6); }
.rp-step__head { margin-bottom: var(--rp-space-5); }
.rp-step__head h2 { font-size: var(--rp-fs-xl); margin-bottom: var(--rp-space-1); }
.rp-step__head p { color: var(--rp-text-muted); margin: 0; }
.rp-step__head h2:focus { outline: none; }
.rp-step__actions { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--rp-space-3); margin-top: var(--rp-space-6); padding-top: var(--rp-space-5); border-top: 1px solid var(--rp-border); }
.rp-tz-note { display: inline-flex; align-items: center; gap: var(--rp-space-2); font-size: var(--rp-fs-sm); color: var(--rp-text-muted); margin-bottom: var(--rp-space-4); }

/* ---------- Calendar (custom accessible date grid) ---------- */
.rp-cal { max-width: 26rem; }
.rp-cal__header { display: flex; align-items: center; justify-content: space-between; margin-bottom: var(--rp-space-3); }
.rp-cal__title { font-size: var(--rp-fs-md); font-weight: var(--rp-fw-semibold); margin: 0; }
.rp-cal__grid { width: 100%; border-collapse: separate; border-spacing: 4px; table-layout: fixed; }
.rp-cal__grid abbr[title] { text-decoration: none; cursor: default; }
.rp-cal__grid th { font-size: var(--rp-fs-xs); font-weight: var(--rp-fw-semibold); color: var(--rp-text-muted); text-align: center; padding-bottom: var(--rp-space-1); }
.rp-cal__grid td { padding: 0; text-align: center; }
.rp-day {
  width: 100%;
  aspect-ratio: 1;
  min-height: var(--rp-target-touch);
  border-radius: var(--rp-radius);
  border: 1px solid transparent;
  background: transparent;
  color: var(--rp-text);
  font-weight: var(--rp-fw-medium);
  font-variant-numeric: tabular-nums;
  position: relative;
  transition: background-color var(--rp-dur-fast) var(--rp-ease-out), border-color var(--rp-dur-fast), color var(--rp-dur-fast);
}
.rp-day.is-available { background: var(--rp-primary-subtle); border-color: var(--rp-primary-subtle-border); color: var(--rp-brand-900); font-weight: var(--rp-fw-semibold); }
.rp-day.is-available:hover { background: var(--rp-brand-100); border-color: var(--rp-primary); }
.rp-day.is-available::after { /* availability dot: shape cue in addition to colour */
  content: "";
  position: absolute;
  left: 50%;
  bottom: 18%;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: currentColor;
  transform: translateX(-50%);
}
.rp-day[aria-disabled="true"] { color: var(--rp-text-subtle); text-decoration: line-through; text-decoration-color: var(--rp-slate-300); cursor: not-allowed; }
.rp-day.is-today { border-color: var(--rp-slate-400); }
.rp-day[aria-pressed="true"] { background: var(--rp-primary); border-color: var(--rp-primary); color: #fff; }
.rp-day[aria-pressed="true"]::after { background: #fff; }
.rp-day.is-outside { visibility: hidden; }
.rp-cal__legend { display: flex; flex-wrap: wrap; gap: var(--rp-space-4); margin-top: var(--rp-space-3); font-size: var(--rp-fs-sm); color: var(--rp-text-muted); list-style: none; padding: 0; }
.rp-cal__legend li { display: inline-flex; align-items: center; gap: var(--rp-space-2); }
.rp-cal__swatch { width: 1rem; height: 1rem; border-radius: 4px; border: 1px solid var(--rp-primary-subtle-border); background: var(--rp-primary-subtle); display: inline-block; }
.rp-cal__swatch--off { background: transparent; border-color: var(--rp-border-strong); }

/* ---------- Time slots (native radio group styled as cards) ---------- */
.rp-slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr)); gap: var(--rp-space-3); margin: 0; padding: 0; border: 0; }
.rp-slots legend { font-size: var(--rp-fs-base); font-weight: var(--rp-fw-semibold); margin-bottom: var(--rp-space-3); grid-column: 1 / -1; float: none; }
.rp-slot { position: relative; }
.rp-slot input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.rp-slot label {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-height: 4.25rem;
  padding: var(--rp-space-3) var(--rp-space-4);
  border: 1.5px solid var(--rp-border-strong);
  border-radius: var(--rp-radius-lg);
  background: var(--rp-surface);
  cursor: pointer;
  transition: border-color var(--rp-dur-fast) var(--rp-ease-out), background-color var(--rp-dur-fast) var(--rp-ease-out), box-shadow var(--rp-dur-fast), transform var(--rp-dur-fast);
}
.rp-slot__time { font-weight: var(--rp-fw-semibold); font-variant-numeric: tabular-nums; font-size: var(--rp-fs-md); white-space: nowrap; }
.rp-slot__state { display: inline-flex; align-items: center; gap: 0.3rem; font-size: var(--rp-fs-sm); color: var(--rp-success-emphasis); font-weight: var(--rp-fw-medium); }
.rp-slot label:hover { border-color: var(--rp-primary); box-shadow: var(--rp-shadow-sm); }
.rp-slot input:checked + label { border-color: var(--rp-primary); background: var(--rp-primary-subtle); box-shadow: inset 0 0 0 1px var(--rp-primary); }
.rp-slot input:checked + label .rp-slot__state { color: var(--rp-brand-900); }
.rp-slot input:focus-visible + label { outline: var(--rp-focus-width) solid var(--rp-focus); outline-offset: var(--rp-focus-offset); }
.rp-slot input:disabled + label { cursor: not-allowed; background: var(--rp-surface-muted); border-style: dashed; border-color: var(--rp-border-strong); color: var(--rp-text-subtle); box-shadow: none; }
.rp-slot input:disabled + label .rp-slot__time { text-decoration: line-through; }
.rp-slot input:disabled + label .rp-slot__state { color: var(--rp-text-muted); }

/* ---------- Persons ---------- */
.rp-persons { display: flex; flex-wrap: wrap; align-items: center; gap: var(--rp-space-5); }
.rp-persons__hint { color: var(--rp-text-muted); font-size: var(--rp-fs-sm); margin: 0; }

/* ---------- Summary ---------- */
.rp-summary { position: sticky; top: var(--rp-space-5); }
.rp-summary__head { padding: var(--rp-space-4) var(--rp-space-5); border-bottom: 1px solid var(--rp-border); }
.rp-summary__head h2 { font-size: var(--rp-fs-md); margin: 0; }
.rp-summary__body { padding: var(--rp-space-4) var(--rp-space-5); }
.rp-summary__list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: var(--rp-space-3); }
.rp-summary__list li { display: flex; gap: var(--rp-space-3); align-items: flex-start; font-size: var(--rp-fs-sm); }
.rp-summary__list .bi { color: var(--rp-text-muted); font-size: 1rem; line-height: 1.4; }
.rp-summary__list .is-empty { color: var(--rp-text-subtle); }
.rp-summary__total { display: flex; justify-content: space-between; align-items: baseline; padding: var(--rp-space-4) var(--rp-space-5); border-top: 1px solid var(--rp-border); font-weight: var(--rp-fw-semibold); }
.rp-summary__total strong { font-size: var(--rp-fs-lg); font-variant-numeric: tabular-nums; }
.rp-summary__foot { padding: 0 var(--rp-space-5) var(--rp-space-5); }

.rp-price-lines { list-style: none; margin: 0; padding: 0; font-size: var(--rp-fs-sm); }
.rp-price-lines.rp-card { padding: var(--rp-space-3) var(--rp-space-4); }
.rp-price-lines li { display: flex; justify-content: space-between; gap: var(--rp-space-3); padding: 0.35rem 0; }

/* Hold timer */
.rp-hold {
  display: flex;
  align-items: center;
  gap: var(--rp-space-3);
  padding: var(--rp-space-3) var(--rp-space-4);
  border-radius: var(--rp-radius);
  background: var(--rp-info-subtle);
  border: 1px solid var(--rp-info-border);
  color: var(--rp-info-emphasis);
  font-size: var(--rp-fs-sm);
  font-weight: var(--rp-fw-medium);
}
.rp-hold .bi { font-size: 1.15rem; }
.rp-hold__time { font-variant-numeric: tabular-nums; font-weight: var(--rp-fw-bold); font-size: var(--rp-fs-base); }
.rp-hold.is-warning { background: var(--rp-warning-subtle); border-color: var(--rp-warning-border); color: var(--rp-warning-emphasis); }
.rp-hold.is-expired { background: var(--rp-neutral-subtle); border-color: var(--rp-neutral-border); color: var(--rp-neutral-emphasis); }

/* Mobile selection bar (hidden ≥992px) */
.rp-selection-bar {
  position: sticky;
  bottom: 0;
  z-index: 1010;
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: var(--rp-space-3);
  padding: var(--rp-space-3) var(--rp-space-4);
  background: var(--rp-surface);
  border-top: 1px solid var(--rp-border);
  box-shadow: 0 -4px 16px rgba(15, 23, 42, 0.06);
}
.rp-selection-bar__text { font-size: var(--rp-fs-sm); line-height: 1.3; min-width: 0; }
.rp-selection-bar__text strong { display: block; font-size: var(--rp-fs-base); }

/* ---------- Result pages ---------- */
.rp-result { max-width: 40rem; margin: 0 auto; }
.rp-result__card { padding: var(--rp-space-7) var(--rp-space-6); text-align: center; }
.rp-result__icon { width: 4.5rem; height: 4.5rem; margin: 0 auto var(--rp-space-4); display: grid; place-items: center; border-radius: 50%; font-size: 2rem; }
.rp-result__icon--success { background: var(--rp-success-subtle); color: var(--rp-success); }
.rp-result__icon--info { background: var(--rp-info-subtle); color: var(--rp-info); }
.rp-result__icon--warning { background: var(--rp-warning-subtle); color: var(--rp-warning-emphasis); }
.rp-result__icon--danger { background: var(--rp-danger-subtle); color: var(--rp-danger); }
.rp-result__icon--neutral { background: var(--rp-neutral-subtle); color: var(--rp-neutral-emphasis); }
.rp-result__icon svg { width: 2.5rem; height: 2.5rem; }
.rp-result h1 { font-size: var(--rp-fs-2xl); margin-bottom: var(--rp-space-2); }
.rp-result h1:focus { outline: none; }
.rp-result__lead { color: var(--rp-text-muted); margin: 0 auto var(--rp-space-5); max-width: 30rem; }
.rp-reference {
  display: inline-flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: var(--rp-space-3) var(--rp-space-5);
  border: 1px dashed var(--rp-border-strong);
  border-radius: var(--rp-radius-lg);
  background: var(--rp-surface-muted);
  margin-bottom: var(--rp-space-5);
}
.rp-reference span { font-size: var(--rp-fs-xs); font-weight: var(--rp-fw-semibold); color: var(--rp-text-muted); letter-spacing: 0.06em; text-transform: uppercase; }
.rp-reference strong { font-family: var(--rp-font-mono); font-size: var(--rp-fs-lg); letter-spacing: 0.08em; }
.rp-result__details { text-align: left; margin-top: var(--rp-space-5); }
.rp-result__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--rp-space-3); margin-top: var(--rp-space-5); }

.rp-processing { display: flex; flex-direction: column; align-items: center; gap: var(--rp-space-4); }
.rp-processing .spinner-border { width: 3rem; height: 3rem; border-width: 0.25em; color: var(--rp-primary); }

/* Status tracker (booking status page) */
.rp-tracker { list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--rp-space-2); margin: 0 0 var(--rp-space-5); padding: 0; }
.rp-tracker li { display: flex; flex-direction: column; gap: var(--rp-space-2); font-size: var(--rp-fs-sm); color: var(--rp-text-muted); text-align: left; }
.rp-tracker li::before { content: ""; height: 4px; border-radius: var(--rp-radius-pill); background: var(--rp-slate-200); }
.rp-tracker li.is-done { color: var(--rp-text); font-weight: var(--rp-fw-medium); }
.rp-tracker li.is-done::before { background: var(--rp-success); }
.rp-tracker li[aria-current="step"] { color: var(--rp-text); font-weight: var(--rp-fw-semibold); }
.rp-tracker li[aria-current="step"]::before { background: var(--rp-primary); }
