:root {
  --rd-booking-bg: #f8f5ef;
  --rd-booking-card: #ffffff;
  --rd-booking-soft: #f1eadf;
  --rd-booking-text: #2f2a24;
  --rd-booking-muted: #766f66;
  --rd-booking-primary: #408491;
  --rd-booking-primary-hover: #337482;
  --rd-booking-border: #e4ded3;
  --rd-booking-success: #4f8a5b;
  --rd-booking-warning: #b9852d;
  --rd-booking-danger: #b94b4b;
  --rd-booking-radius: 16px;
  --rd-booking-shadow: 0 12px 30px rgba(47, 42, 36, .08);
}

body.rd-booking-body {
  margin: 0;
  background: var(--rd-booking-bg);
  color: var(--rd-booking-text);
  overflow-x: hidden;
}

.rd-booking-page,
.rd-booking-page * {
  box-sizing: border-box;
}

.rd-booking-page {
  min-height: 100vh;
  padding: 24px 16px;
  font-size: 15px;
}

.reservation-embed .rd-booking-page {
  min-height: auto;
  padding: 0;
  background: transparent;
}

.rd-booking-shell {
  width: min(1080px, 100%);
  margin: 0 auto;
  display: grid;
  gap: 14px;
}

.rd-booking-top,
.rd-booking-card,
.rd-client-card {
  border: 1px solid var(--rd-booking-border);
  border-radius: var(--rd-booking-radius);
  background: var(--rd-booking-card);
  box-shadow: var(--rd-booking-shadow);
}

.reservation-embed .rd-booking-top {
  display: none;
}

.reservation-embed .rd-booking-card,
.reservation-embed .rd-client-card {
  border-radius: 0;
  box-shadow: none;
}

.rd-booking-top {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 18px 20px;
}

.rd-booking-top h1,
.rd-client-top h1 {
  margin: 2px 0 0;
  color: #22606d;
  font-size: 24px;
  line-height: 1.15;
  letter-spacing: 0;
}

.rd-kicker,
.service-kicker {
  margin: 0;
  color: var(--rd-booking-primary);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.rd-back-link,
.rd-text-button {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-height: 34px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #22606d;
  cursor: pointer;
  font: inherit;
  font-size: 14px;
  font-weight: 800;
  text-decoration: none;
}

.rd-booking-stepper {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
  margin: 0;
  padding: 0;
  list-style: none;
}

.rd-booking-stepper li {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 30px;
  padding: 4px 9px;
  border: 1px solid var(--rd-booking-border);
  border-radius: 999px;
  background: #fff;
  color: var(--rd-booking-muted);
  font-size: 13px;
  font-weight: 700;
}

.rd-booking-stepper span {
  display: grid;
  width: 19px;
  height: 19px;
  place-items: center;
  border-radius: 50%;
  background: var(--rd-booking-soft);
  color: #22606d;
  font-size: 11px;
}

.rd-booking-stepper .is-active {
  border-color: rgba(64, 132, 145, .35);
  background: #eef6f7;
  color: #22606d;
}

.rd-booking-card,
.rd-client-card {
  padding: 20px;
}

.rd-step-panel[hidden] {
  display: none !important;
}

.rd-panel-title {
  display: grid;
  gap: 5px;
  margin-bottom: 16px;
}

.rd-panel-title[hidden] {
  display: none !important;
}

.rd-panel-title h2,
.rd-booking-summary h2,
.rd-booking-slots h2,
.rd-client-card h2 {
  margin: 0;
  color: #22606d;
  font-size: 18px;
  line-height: 1.2;
  letter-spacing: 0;
}

.rd-service-list {
  display: grid;
  gap: 9px;
}

.rd-service-list[hidden] {
  display: none !important;
}

.rd-hierarchy-picker {
  display: grid;
  gap: 14px;
}

.rd-hierarchy-picker[hidden] {
  display: none !important;
}

.rd-hierarchy-picker > .rd-text-button {
  justify-self: start;
}

.rd-hierarchy-picker [data-rd-hierarchy-path] {
  margin: 0;
  color: var(--rd-booking-muted);
  font-weight: 700;
}

.rd-hierarchy-row {
  min-height: 76px;
}

.rd-service-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 13px 14px;
  border: 1px solid var(--rd-booking-border);
  border-radius: 14px;
  background: #fffdf8;
  width: 100%;
  color: inherit;
  cursor: pointer;
  font: inherit;
  text-align: left;
}

.rd-service-row.is-selected,
.rd-service-row:focus-visible {
  border-color: rgba(64, 132, 145, .55);
  background: #eef6f7;
  outline: 3px solid #ffbf47;
  outline-offset: 2px;
}

.rd-service-row:disabled {
  cursor: not-allowed;
  opacity: .58;
}

.rd-service-row strong {
  color: var(--rd-booking-text);
  font-size: 16px;
}

.rd-service-row p {
  margin: 4px 0 0;
  color: var(--rd-booking-muted);
  line-height: 1.4;
}

.rd-service-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.rd-service-meta span,
.rd-booking-badge,
.rd-status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--rd-booking-soft);
  color: #22606d;
  font-size: 12px;
  font-weight: 800;
}

.rd-small-button,
.rd-primary-button,
.rd-secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 8px 14px;
  border: 1px solid transparent;
  border-radius: 11px;
  cursor: pointer;
  font: inherit;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.1;
  text-decoration: none;
}

.rd-small-button {
  min-height: 36px;
  padding-inline: 12px;
  background: #eef6f7;
  color: #22606d;
}

.rd-primary-button {
  background: var(--rd-booking-primary);
  color: #fff;
}

.rd-primary-button:hover,
.rd-small-button:hover {
  background: var(--rd-booking-primary-hover);
  color: #fff;
}

.rd-primary-button:disabled,
.rd-small-button:disabled {
  cursor: not-allowed;
  opacity: .48;
}

.rd-booking-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 14px;
}

.rd-booking-layout {
  display: grid;
  grid-template-columns: minmax(220px, .75fr) minmax(340px, 1fr) minmax(230px, .85fr);
  gap: 0;
  overflow: hidden;
  border: 1px solid var(--rd-booking-border);
  border-radius: var(--rd-booking-radius);
}

.rd-booking-summary,
.rd-booking-calendar,
.rd-booking-slots {
  padding: 18px;
  background: #fff;
}

.rd-booking-summary {
  display: grid;
  align-content: start;
  gap: 12px;
  border-right: 1px solid var(--rd-booking-border);
  background: #fffdf8;
}

.rd-booking-summary p {
  margin: 0;
  color: var(--rd-booking-muted);
  line-height: 1.45;
}

.rd-mini-details {
  display: grid;
  gap: 8px;
  margin: 0;
}

.rd-mini-details div {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  gap: 8px;
}

.rd-mini-details dt {
  color: var(--rd-booking-muted);
  font-size: 13px;
  font-weight: 700;
}

.rd-mini-details dd {
  margin: 0;
  color: var(--rd-booking-text);
  font-weight: 800;
}

.rd-mode-switch {
  display: grid;
  grid-template-columns: 1fr;
  gap: 7px;
}

.rd-mode-switch button {
  min-height: 36px;
  border: 1px solid var(--rd-booking-border);
  border-radius: 10px;
  background: #fff;
  color: #22606d;
  cursor: pointer;
  font: inherit;
  font-weight: 800;
}

.rd-mode-switch button.is-active {
  border-color: var(--rd-booking-primary);
  background: #eef6f7;
}

.rd-booking-calendar {
  border-right: 1px solid var(--rd-booking-border);
}

.rd-calendar-toolbar {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) 34px;
  gap: 8px;
  align-items: center;
  margin-bottom: 12px;
}

.rd-calendar-toolbar strong {
  color: #22606d;
  font-size: 16px;
  font-weight: 900;
  text-align: center;
  text-transform: capitalize;
}

.rd-icon-button {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid var(--rd-booking-border);
  border-radius: 10px;
  background: #fff;
  color: #22606d;
  cursor: pointer;
  font: inherit;
  font-size: 18px;
  font-weight: 900;
}

.rd-calendar-weekdays,
.rd-calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 5px;
}

.rd-calendar-weekdays {
  margin-bottom: 6px;
  color: var(--rd-booking-muted);
  font-size: 11px;
  font-weight: 900;
  text-align: center;
  text-transform: uppercase;
}

.rd-calendar-day {
  display: grid;
  min-height: 34px;
  place-items: center;
  border: 1px solid transparent;
  border-radius: 10px;
  background: #f6f4ee;
  color: var(--rd-booking-muted);
  cursor: pointer;
  font: inherit;
  font-size: 14px;
  font-weight: 800;
}

.rd-calendar-day.is-empty {
  visibility: hidden;
}

.rd-calendar-day.is-available {
  background: #eef6f7;
  color: #22606d;
}

.rd-calendar-day.is-today {
  border-color: rgba(240, 133, 46, .5);
}

.rd-calendar-day.is-selected {
  border-color: #22606d;
  background: var(--rd-booking-primary);
  color: #fff;
}

.rd-calendar-day:disabled {
  cursor: not-allowed;
  opacity: .42;
}

.rd-booking-slots {
  display: grid;
  align-content: start;
  gap: 10px;
}

.rd-slot-list,
.rd-event-list {
  display: grid;
  gap: 8px;
}

.rd-booking-slot,
.rd-booking-event-row {
  min-height: 38px;
  border: 1px solid var(--rd-booking-border);
  border-radius: 11px;
  background: #fff;
  color: #22606d;
  cursor: pointer;
  font: inherit;
  font-weight: 800;
  text-align: left;
}

.rd-booking-slot {
  text-align: center;
}

.rd-booking-slot.is-selected,
.rd-booking-event-row.is-selected,
.rd-booking-slot:hover,
.rd-booking-event-row:hover {
  border-color: var(--rd-booking-primary);
  background: #eef6f7;
}

.rd-booking-event-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 10px;
}

.rd-booking-event-row small {
  display: block;
  margin-top: 3px;
  color: var(--rd-booking-muted);
  font-weight: 600;
  line-height: 1.35;
}

.rd-booking-badge.success {
  background: #e8f6eb;
  color: #1f6b3a;
}

.rd-booking-badge.warning {
  background: #fff3db;
  color: #8a5a0e;
}

.rd-booking-badge.danger {
  background: #fdebea;
  color: #8a1f1f;
}

.rd-empty-state,
.rd-booking-alert {
  margin: 0;
  padding: 10px 12px;
  border: 1px solid rgba(185, 133, 45, .25);
  border-radius: 12px;
  background: #fff6df;
  color: #745100;
  font-size: 14px;
  font-weight: 700;
}

.rd-booking-alert.bad {
  border-color: rgba(185, 75, 75, .25);
  background: #fdebea;
  color: #8a1f1f;
}

.rd-booking-alert.ok {
  border-color: rgba(79, 138, 91, .25);
  background: #e9f7ec;
  color: #1f6b3a;
}

.rd-booking-form {
  display: grid;
  gap: 10px;
}

.rd-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 12px;
}

.rd-booking-form label,
.rd-question-field {
  display: grid;
  gap: 5px;
  color: #22606d;
  font-size: 13px;
  font-weight: 800;
}

.rd-booking-form input,
.rd-booking-form select,
.rd-booking-form textarea {
  width: 100%;
  min-height: 44px;
  padding: 7px 9px;
  border: 1px solid #cfc8bb;
  border-radius: 10px;
  background: #fff;
  color: var(--rd-booking-text);
  font: inherit;
  font-size: 14px;
}

.rd-booking-form textarea {
  min-height: 82px;
  resize: vertical;
}

.rd-booking-form input:focus-visible,
.rd-booking-form select:focus-visible,
.rd-booking-form textarea:focus-visible {
  border-color: var(--rd-booking-primary);
  outline: 3px solid rgba(64, 132, 145, .22);
  outline-offset: 2px;
}

.rd-question-builder {
  display: grid;
  gap: 10px;
  padding-top: 4px;
}

.rd-question-builder h3 {
  margin: 0;
  color: #22606d;
  font-size: 16px;
}

.rd-question-field small {
  color: var(--rd-booking-muted);
  font-weight: 600;
}

.rd-choice-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-width: 0;
}

.rd-choice {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  box-sizing: border-box;
  min-width: min(170px, 100%);
  max-width: 100%;
  min-height: 34px;
  padding: 6px 9px;
  border: 1px solid var(--rd-booking-border);
  border-radius: 999px;
  background: #fffdf8;
  color: var(--rd-booking-text);
  cursor: pointer;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.25;
}

.rd-choice input[type="radio"],
.rd-choice input[type="checkbox"] {
  flex: 0 0 18px;
  width: 18px;
  min-width: 18px;
  max-width: 18px;
  height: 18px;
  min-height: 18px;
  max-height: 18px;
  margin: 0;
  padding: 0;
  accent-color: var(--rd-booking-primary);
  box-sizing: border-box;
}

.rd-choice > span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.rd-choice:focus-within {
  border-color: var(--rd-booking-primary);
  outline: 2px solid rgba(64, 132, 145, .22);
  outline-offset: 2px;
}

.rd-review-box dl,
.rd-token-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
  margin: 0;
}

.rd-review-box div,
.rd-token-summary div {
  padding: 10px;
  border: 1px solid var(--rd-booking-border);
  border-radius: 12px;
  background: #fffdf8;
}

.rd-review-box dt,
.rd-token-summary span {
  color: var(--rd-booking-muted);
  font-size: 12px;
  font-weight: 800;
}

.rd-review-box dd,
.rd-token-summary strong {
  margin: 3px 0 0;
  color: var(--rd-booking-text);
  font-weight: 800;
  overflow-wrap: anywhere;
}

.rd-success-box {
  display: grid;
  gap: 10px;
  text-align: left;
}

.rd-client-page {
  display: grid;
  place-items: center;
}

.rd-client-card {
  width: min(760px, 100%);
  display: grid;
  gap: 14px;
}

.rd-client-top {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: flex-start;
  justify-content: space-between;
}

.rd-status-pill[data-status="requested"] {
  background: #fff4dc;
  color: #80540d;
}

.rd-status-pill[data-status="confirmed"] {
  background: #e8f6eb;
  color: #1f6b3a;
}

.rd-status-pill[data-status="cancelled"],
.rd-status-pill[data-status="refused"],
.rd-status-pill[data-status="expired"] {
  background: #fdebea;
  color: #8a1f1f;
}

.rd-status-pill[data-status="reschedule_requested"] {
  background: #eef6f7;
  color: #22606d;
}

.rd-client-actions {
  display: grid;
  gap: 12px;
}

.rd-client-action-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.rd-client-action-grid form {
  margin: 0;
}

.cta-btn.rd-primary-action,
.cta-btn.rd-secondary-action {
  min-height: 40px;
  padding: 8px 14px;
  border-radius: 11px;
  box-shadow: none;
  font-size: 14px;
}

.cta-btn.rd-primary-action {
  background: var(--rd-booking-primary);
}

.cta-btn.rd-secondary-action {
  border: 1px solid var(--rd-booking-border);
  background: #fff;
  color: #22606d;
}

@media (max-width: 980px) {
  .rd-booking-top,
  .rd-booking-layout {
    grid-template-columns: 1fr;
  }

  .rd-booking-stepper {
    justify-content: flex-start;
  }

  .rd-booking-summary,
  .rd-booking-calendar {
    border-right: 0;
    border-bottom: 1px solid var(--rd-booking-border);
  }
}

@media (max-width: 640px) {
  .rd-booking-page {
    padding: 10px;
    font-size: 14px;
  }

  .rd-booking-top,
  .rd-booking-card,
  .rd-client-card,
  .rd-booking-summary,
  .rd-booking-calendar,
  .rd-booking-slots {
    padding: 14px;
  }

  .rd-booking-top h1,
  .rd-client-top h1 {
    font-size: 20px;
  }

  .rd-booking-stepper {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .rd-service-row,
  .rd-form-grid,
  .rd-review-box dl,
  .rd-token-summary {
    grid-template-columns: 1fr;
  }

  .rd-choice-group {
    display: grid;
    grid-template-columns: 1fr;
  }

  .rd-choice {
    width: 100%;
    border-radius: 12px;
  }

  .rd-small-button,
  .rd-primary-button,
  .rd-secondary-button,
  .rd-booking-actions,
  .rd-booking-actions .rd-primary-button {
    width: 100%;
  }

  .rd-booking-actions,
  .rd-client-action-grid {
    display: grid;
  }

  .rd-calendar-day {
    min-height: 32px;
    font-size: 13px;
  }
}

.rd-compact-service-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 12px;
  padding: 9px 12px;
  border: 1px solid var(--rd-booking-border);
  border-radius: 12px;
  background: #fffdf8;
  font-size: 14px;
}

.rd-compact-service-bar strong {
  color: #22606d;
}

.rd-compact-service-bar span {
  color: var(--rd-booking-muted);
}

.reservation-embed .rd-booking-card {
  padding: 10px;
}

.reservation-embed .rd-booking-layout {
  grid-template-columns: minmax(0, 1fr) minmax(240px, .42fr);
}

.reservation-embed .rd-booking-calendar-summary,
.reservation-embed .rd-booking-selected-service-banner,
.reservation-embed .rd-booking-summary,
.rd-booking-embed .rd-booking-summary {
  display: none !important;
}

.reservation-embed .rd-booking-summary {
  display: none;
}

.rd-booking-layout--no-summary,
.reservation-embed .rd-booking-layout--no-summary {
  grid-template-columns: minmax(0, 1fr) minmax(230px, .42fr);
}

.rd-engine-event .rd-booking-layout,
.rd-engine-legacy .rd-booking-layout,
.rd-engine-disabled .rd-booking-layout {
  grid-template-columns: minmax(0, .34fr) minmax(0, 1fr);
}

.rd-engine-event .rd-booking-calendar,
.rd-engine-legacy .rd-booking-calendar,
.rd-engine-disabled .rd-booking-calendar {
  display: none;
}

.reservation-embed .rd-engine-event .rd-booking-layout,
.reservation-embed .rd-engine-legacy .rd-booking-layout,
.reservation-embed .rd-engine-disabled .rd-booking-layout,
.reservation-embed.rd-engine-event .rd-booking-layout,
.reservation-embed.rd-engine-legacy .rd-booking-layout,
.reservation-embed.rd-engine-disabled .rd-booking-layout {
  grid-template-columns: 1fr;
}

.rd-legacy-panel {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px dashed rgba(64, 132, 145, .45);
  border-radius: 12px;
  background: #f8fbfb;
  color: var(--rd-booking-muted);
  font-size: 14px;
}

.rd-cal-embed {
  width: 100%;
  min-height: 620px;
  overflow: hidden;
  border: 1px solid rgba(51, 129, 143, .22);
  border-radius: 14px;
  background: #fff;
}

.rd-cal-embed__frame {
  display: block;
  width: 100%;
  height: min(78vh, 760px);
  min-height: 620px;
  border: 0;
  background: #fff;
}

.rd-cal-embed__fallback {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  align-items: center;
  color: #405159;
  font-size: 13px;
  line-height: 1.35;
}

.rd-cal-embed__fallback p {
  flex: 1 1 260px;
  margin: 0;
}

@media (max-width: 720px) {
  .rd-cal-embed,
  .rd-cal-embed__frame {
    min-height: min(560px, 72vh);
  }
}

.rd-booking-form label,
.rd-question-field {
  font-size: 13px;
}

.rd-booking-form input,
.rd-booking-form textarea,
.rd-booking-form select {
  min-height: 36px;
  padding: 7px 9px;
}

.rd-form-section {
  margin-top: 2px;
}

.rd-form-section h3 {
  margin: 0;
  color: #22606d;
  font-size: 15px;
  line-height: 1.2;
}

.rd-required-star {
  color: var(--rd-booking-danger);
  font-weight: 900;
}

.rd-form-context {
  margin: 0 auto 0 0;
  color: var(--rd-booking-muted);
  font-size: 13px;
  font-weight: 800;
}

.rd-question-field.is-invalid,
.rd-booking-form .is-invalid {
  border-color: var(--rd-booking-danger) !important;
  outline: 2px solid rgba(185, 75, 75, .12);
}

.rd-question-field.is-invalid {
  padding: 8px;
  border: 1px solid var(--rd-booking-danger);
  border-radius: 10px;
  background: #fffafa;
}

@media (max-width: 980px) {
  .reservation-embed .rd-booking-layout,
  .rd-engine-event .rd-booking-layout,
  .rd-engine-legacy .rd-booking-layout,
  .rd-engine-disabled .rd-booking-layout {
    grid-template-columns: 1fr;
  }
}
