/* Modern 8-Page Booking Flow */
:root {
  --primary-color: #6366f1;
  --primary-hover: #4f46e5;
  --secondary-color: #8b5cf6;
  --success-color: #10b981;
  --danger-color: #ef4444;
  --text-primary: #111827;
  --text-secondary: #6b7280;
  --text-muted: #9ca3af;
  --border-color: #e5e7eb;
  --bg-white: #ffffff;
  --bg-gray: #f9fafb;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  height: 100%;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--text-primary);
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  font-size: 16px;
  line-height: 1.6;
}

#app-scroll {
  min-height: 100vh;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
}

/* Booking Flow Container */
.booking-flow-container {
  max-width: 600px;
  margin: 0 auto;
  padding: 20px;
  min-height: calc(100vh - 80px);
}

/* Booking Pages */
.booking-page {
  display: none;
  animation: fadeIn 0.4s ease;
}

.booking-page.active {
  display: block;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Page 1: Welcome Page */
.welcome-page {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 70vh;
  text-align: center;
  padding: 40px 20px;
}

.welcome-title {
  font-size: 2.5rem;
  font-weight: 700;
  color: white;
  margin-bottom: 16px;
  line-height: 1.2;
}

.welcome-subtitle {
  font-size: 1.25rem;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 48px;
}

.btn-start-booking {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: white;
  color: var(--primary-color);
  padding: 18px 36px;
  border: none;
  border-radius: 50px;
  font-size: 1.125rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: var(--shadow-lg);
}

.btn-start-booking:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.2);
}

.btn-start-booking i {
  transition: transform 0.3s ease;
  animation: arrowSlide 3s ease-in-out infinite;
}

.btn-start-booking:hover i {
  transform: translateX(4px);
}

@keyframes arrowSlide {
  0%, 100% {
    transform: translateX(0);
  }
  50% {
    transform: translateX(6px);
  }
}

/* Page Content */
.page-content {
  background: white;
  border-radius: 20px;
  padding: 40px 32px;
  box-shadow: var(--shadow-lg);
  min-height: 60vh;
}

.page-title {
  font-size: 2rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 12px;
  text-align: center;
}

.page-subtitle {
  font-size: 1rem;
  color: var(--text-secondary);
  margin-bottom: 32px;
  text-align: center;
}

.page-subtitle-tight {
  margin-bottom: 8px;
}

/* "Times shown in your timezone" note on the Available Times page */
.slot-tz-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 0.875rem;
  color: var(--text-secondary);
  background: var(--bg-gray);
  border: 1px solid var(--border-color);
  border-radius: 999px;
  padding: 8px 16px;
  width: fit-content;
  max-width: 100%;
  margin: 0 auto 24px;
  text-align: center;
}

.slot-tz-note i {
  color: var(--primary-color);
}

/* Compact Calendar */
.calendar-compact {
  max-width: 400px;
  width: 100%;
  margin: 0 auto;
  border: 1px solid var(--border-color);
  border-radius: 16px;
  overflow: hidden;
  background: white;
}

.cal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  background: var(--bg-gray);
  border-bottom: 1px solid var(--border-color);
}

.cal-month {
  font-weight: 600;
  font-size: 1rem;
  color: var(--text-primary);
}

.cal-nav-btn {
  background: none;
  border: none;
  padding: 8px;
  cursor: pointer;
  color: var(--text-secondary);
  border-radius: 8px;
  transition: all 0.2s ease;
  font-size: 1.25rem;
}

.cal-nav-btn:hover:not(:disabled) {
  background-color: var(--border-color);
  color: var(--text-primary);
}

.cal-nav-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  padding: 16px;
}

.cal-dow {
  text-align: center;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  padding: 8px 0;
  text-transform: uppercase;
}

.cal-day {
  aspect-ratio: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 8px;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  font-weight: 500;
  min-width: 0;
}

.cal-day:hover:not(.disabled):not(.other-month) {
  background-color: var(--bg-gray);
}

.cal-day.disabled {
  color: var(--text-muted);
  cursor: not-allowed;
  opacity: 0.3;
}

.cal-day.other-month {
  color: var(--text-muted);
  opacity: 0.3;
}

.cal-day.selected {
  background-color: var(--primary-color);
  color: white;
  font-weight: 600;
}

.cal-day .slot-dot {
  position: absolute;
  bottom: 4px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--primary-color);
}

.cal-day.selected .slot-dot {
  background: white;
}

/* Time Slots */
.time-slot-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 12px;
  max-height: 400px;
  overflow-y: auto;
  padding: 4px;
}

.time-slot-list::-webkit-scrollbar {
  width: 6px;
}

.time-slot-list::-webkit-scrollbar-track {
  background: var(--bg-gray);
  border-radius: 3px;
}

.time-slot-list::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 3px;
}

.slot-button {
  padding: 16px 20px;
  border: 2px solid var(--border-color);
  border-radius: 12px;
  background: white;
  color: var(--text-primary);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
}

.slot-mode-badge {
  font-size: 0.6rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 4px;
  letter-spacing: 0.4px;
  text-transform: uppercase;
}

.slot-online {
  background: #e0f2fe;
  color: #0369a1;
}

.slot-offline {
  background: #f0fdf4;
  color: #15803d;
}

.slot-button.selected .slot-online {
  background: rgba(255,255,255,0.25);
  color: white;
}

.slot-button.selected .slot-offline {
  background: rgba(255,255,255,0.25);
  color: white;
}

.slot-button:hover {
  border-color: var(--primary-color);
  background: var(--bg-gray);
  transform: translateY(-2px);
}

.slot-button.selected {
  border-color: var(--primary-color);
  background: var(--primary-color);
  color: white;
}

.slot-empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-muted);
}

/* Session Mode Cards */
.session-mode-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-top: 32px;
}

.mode-card {
  padding: 20px;
  border: 3px solid var(--border-color);
  border-radius: 20px;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
  background: white;
}

.mode-card:hover {
  border-color: var(--primary-color);
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.mode-card.selected {
  border-color: var(--primary-color);
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
  color: white;
}

.mode-card i {
  font-size: 3rem;
  margin-bottom: 16px;
  color: var(--primary-color);
  transition: all 0.3s ease;
}

.mode-card.selected i {
  color: white;
}

.mode-card h3 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 8px;
}

.mode-card p {
  font-size: 0.875rem;
  opacity: 0.8;
  margin: 0;
}

/* Therapy Grid */
.therapy-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
}

/* ===== Charge chip row (Package / Individual / Sessions) ===== */
.charge-chip-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 0.6rem;
}

.charge-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.2rem 0.65rem;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.chip-package {
  background: linear-gradient(135deg, rgba(108, 99, 255, 0.15), rgba(108, 99, 255, 0.3));
  color: #7c6ff7;
  border: 1px solid rgba(108, 99, 255, 0.4);
}

.chip-individual {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.12), rgba(16, 185, 129, 0.28));
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.35);
}

.chip-sessions {
  background: rgba(0, 0, 0, 0.06);
  color: #555;
  border: 1px solid rgba(0, 0, 0, 0.1);
  font-weight: 500;
  text-transform: none;
  letter-spacing: 0;
}

.therapy-card {
  border: 2px solid var(--border-color);
  border-radius: 16px;
  padding: 24px;
  cursor: pointer;
  transition: all 0.3s ease;
  background: white;
}

.therapy-card:hover {
  border-color: var(--primary-color);
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.therapy-card.selected {
  border-color: var(--primary-color);
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.1) 0%, rgba(139, 92, 246, 0.1) 100%);
}

.therapy-card h4 {
  font-size: 1.125rem;
  font-weight: 600;
  margin-bottom: 12px;
  color: var(--text-primary);
}

.therapy-card .price {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: 8px;
}

.therapy-card .description {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin: 0;
}

/* No-charge price */
.therapy-card .price.price-free {
  font-size: 1.4rem;
}

/* Sliding-scale price: editable amount box + slider */
.therapy-card .price.price-sliding {
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 1rem;
}

.therapy-card .price.price-sliding .sliding-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
}

/* Amount box — currency sits inside the field, so it reads as one control */
.therapy-card .price.price-sliding .sliding-field {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 10px 14px;
  background: white;
  border: 2px solid var(--border-color);
  border-radius: 12px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.therapy-card .price.price-sliding .sliding-field:focus-within {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.12);
}

.therapy-card .price.price-sliding .sliding-currency {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-secondary);
  line-height: 1;
  flex-shrink: 0;
}

.therapy-card .price.price-sliding .sliding-amount-input {
  flex: 1;
  min-width: 0;
  border: 0;
  padding: 0;
  background: transparent;
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--primary-color);
  line-height: 1.2;
  font-family: inherit;
  /* 16px+ keeps iOS Safari from zooming the viewport on focus */
}

.therapy-card .price.price-sliding .sliding-amount-input:focus {
  outline: none;
}

/* Strip the number spinners — the slider is the stepper */
.therapy-card .price.price-sliding .sliding-amount-input::-webkit-outer-spin-button,
.therapy-card .price.price-sliding .sliding-amount-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.therapy-card .price.price-sliding .sliding-amount-input {
  -moz-appearance: textfield;
  appearance: textfield;
}

.therapy-card .price.price-sliding .sliding-range {
  width: 100%;
  accent-color: var(--primary-color);
  cursor: pointer;
  /* Comfortable drag target on touch without inflating the card */
  height: 24px;
  margin: 0;
}

.therapy-card .price.price-sliding .sliding-bounds {
  display: flex;
  justify-content: space-between;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-secondary);
}

@media (max-width: 480px) {
  .therapy-card .price.price-sliding .sliding-amount-input {
    font-size: 1.4rem;
  }
}

/* Form Inputs */
.form-group {
  margin-bottom: 24px;
}

.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.form-control,
.form-select {
  width: 100%;
  padding: 14px 16px;
  border: 2px solid var(--border-color);
  border-radius: 12px;
  font-size: 1rem;
  transition: all 0.2s ease;
  background: white;
}

.form-control:focus,
.form-select:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.form-control.is-invalid {
  border-color: var(--danger-color);
}

.invalid-feedback {
  font-size: 0.875rem;
  color: var(--danger-color);
  margin-top: 6px;
}

/* intl-tel-input Customization */
.iti {
  width: 100%;
  display: block;
}

.iti__flag-container {
  padding: 0;
}

.iti__selected-flag {
  padding: 0 12px 0 16px;
  border-radius: 12px 0 0 12px;
  transition: all 0.2s ease;
  height: 100%;
  display: flex;
  align-items: center;
}

.iti__selected-flag:hover {
  background: var(--bg-gray);
}

.iti__country-list {
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-color);
  margin-top: 4px;
  max-height: 300px;
  z-index: 1000;
}

.iti__country {
  padding: 12px 16px;
  transition: background 0.2s ease;
}

.iti__country:hover {
  background: var(--bg-gray);
}

.iti__country.iti__highlight {
  background: var(--bg-gray);
}

.iti__search-input {
  padding: 12px 16px;
  border: none;
  border-bottom: 1px solid var(--border-color);
  border-radius: 12px 12px 0 0;
  font-size: 0.875rem;
}

.iti__search-input:focus {
  outline: none;
  border-bottom-color: var(--primary-color);
}

.iti input[type="tel"],
.iti input[type="tel"].form-control {
  width: 100%;
  padding: 14px 16px 14px 80px !important;
  border: 2px solid var(--border-color);
  border-radius: 12px;
  font-size: 1rem;
  transition: all 0.2s ease;
  background: white;
}

.iti input[type="tel"]:focus,
.iti input[type="tel"].form-control:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.iti input[type="tel"].is-invalid,
.iti input[type="tel"].form-control.is-invalid {
  border-color: var(--danger-color) !important;
}

.iti__arrow {
  border-left-color: var(--text-secondary);
  border-right-color: var(--text-secondary);
}

.iti__arrow--up {
  border-bottom-color: var(--text-secondary);
}

/* Show error message for phone */
.form-group .iti + .invalid-feedback {
  display: none;
}

.form-group .iti + .invalid-feedback.d-block {
  display: block !important;
}

/* Summary Card */
.summary-card {
  background: var(--bg-gray);
  border-radius: 16px;
  padding: 8px;
}

.summary-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px;
  background: white;
  border-radius: 12px;
  margin-bottom: 8px;
}

.summary-item:last-child {
  margin-bottom: 0;
}

.summary-item i {
  font-size: 1.5rem;
  color: var(--primary-color);
  width: 32px;
  text-align: center;
}

.summary-item > div {
  flex: 1;
}

.summary-label {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

.summary-value {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-primary);
}

.btn-edit {
  background: none;
  border: none;
  color: var(--primary-color);
  cursor: pointer;
  padding: 8px;
  border-radius: 8px;
  transition: all 0.2s ease;
}

.btn-edit:hover {
  background: var(--bg-gray);
}

/* Payment Box */
.payment-box {
  background: var(--bg-gray);
  border-radius: 16px;
  padding: 24px;
  margin-top: 24px;
}

.payment-box h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.payment-box ul {
  margin: 0 0 20px 20px;
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.payment-box li {
  margin-bottom: 8px;
}

#paymentImageWrapper img {
  max-width: 260px;
  width: 100%;
  border-radius: 12px;
}

.upi-box {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border: 1px solid var(--border-color);
  border-radius: 12px;
  background: white;
  cursor: pointer;
  transition: all 0.2s ease;
}

.upi-box:hover {
  border-color: var(--primary-color);
}

.upi-id {
  font-family: monospace;
  font-weight: 600;
  font-size: 0.875rem;
}

.copy-btn {
  padding: 6px 12px;
  border: none;
  border-radius: 8px;
  background: var(--primary-color);
  color: white;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.copy-btn:hover {
  background: var(--primary-hover);
}

/* Navigation */
.booking-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  background: white;
  border-radius: 20px;
  margin-top: 20px;
  box-shadow: var(--shadow-lg);
}

.booking-nav.hidden {
  display: none;
}

.nav-right {
  display: flex;
  gap: 12px;
}

.btn {
  padding: 14px 28px;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn-back {
  background: white;
  border: 2px solid var(--border-color);
  color: var(--text-primary);
}

.btn-back:hover:not(:disabled) {
  border-color: var(--text-primary);
}

.btn-back:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-next {
  background: var(--primary-color);
  color: white;
}

.btn-next:hover:not(:disabled) {
  background: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn-next:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-confirm {
  background: var(--success-color);
  color: white;
}

.btn-confirm:hover:not(:disabled) {
  background: #059669;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* Footer */
.site-footer {
  text-align: center;
  padding: 24px;
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.875rem;
}

.site-footer a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
}

.brand-logo {
  width: 80px;
  vertical-align: middle;
  filter: brightness(0) invert(1);
}

/* Loading Overlay */
.loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.95);
  z-index: 9999;
}

.loading-content {
  text-align: center;
}

.spinner-border {
  width: 3rem;
  height: 3rem;
  border-width: 0.3em;
  border-color: var(--primary-color);
  border-right-color: transparent;
}

/* Modals */
.modal-content {
  border-radius: 16px;
  border: none;
  box-shadow: var(--shadow-lg);
}

.modal-header {
  border-bottom: 1px solid var(--border-color);
  padding: 20px 24px;
}

.modal-body {
  padding: 24px;
}

.modal-footer {
  border-top: 1px solid var(--border-color);
  padding: 16px 24px;
}

/* Utility Classes */
.d-none {
  display: none !important;
}

.text-center {
  text-align: center;
}

.text-muted {
  color: var(--text-muted) !important;
}

.mt-2 {
  margin-top: 8px !important;
}

.mt-3 {
  margin-top: 16px !important;
}

.mb-0 {
  margin-bottom: 0 !important;
}

.fw-semibold {
  font-weight: 600 !important;
}

/* Scroll lock for modals */
.app-scroll-locked {
  overflow: hidden !important;
  -webkit-overflow-scrolling: auto !important;
  touch-action: none !important;
}

/* Responsive */
@media (max-width: 768px) {
  .booking-flow-container {
    padding: 16px;
  }

  .welcome-title {
    font-size: 1.75rem;
  }

  .welcome-subtitle {
    font-size: 1rem;
  }

  .page-content {
    padding: 32px 24px;
  }

  .page-title {
    font-size: 1.5rem;
  }

  .session-mode-cards {
    grid-template-columns: 1fr;
  }

  .therapy-grid {
    grid-template-columns: 1fr;
  }

  .booking-nav {
    flex-direction: column;
    gap: 12px;
  }

  .btn-back,
  .btn-next,
  .btn-confirm {
    width: 100%;
    justify-content: center;
  }

  .nav-right {
    width: 100%;
  }

  .nav-right button {
    flex: 1;
  }

  .time-slot-list {
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  }
}

@media (max-width: 480px) {
  .page-content {
    padding: 24px 16px;
  }

  .cal-header {
    padding: 12px 14px;
  }

  .cal-grid {
    padding: 8px;
    gap: 2px;
  }

  .cal-dow {
    font-size: 0.6rem;
    padding: 4px 0;
  }

  .cal-day {
    padding: 4px 2px;
    font-size: 0.8rem;
    border-radius: 8px;
  }
}

/* Package info box (therapy page) */
.pkg-info-box {
  background: #f0fdf4;
  border: 1.5px solid #86efac;
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 16px;
}

.pkg-info-title {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px;
  font-size: 1rem;
  color: #166534;
  margin-bottom: 12px;
}

.pkg-stat-value {
  font-size: 1.1rem;
  font-weight: 700;
  color: #166534;
}

.pkg-stat-label {
  font-size: 0.75rem;
  color: #4b5563;
}

.pkg-covered-note {
  font-size: 0.85rem;
  color: #16a34a;
  margin-top: 8px;
}

/* Package selection hint message */
.package-select-msg {
  margin-top: 16px;
  padding: 12px 16px;
  background: #eff6ff;
  border: 1.5px solid #bfdbfe;
  border-radius: 8px;
  font-size: 0.875rem;
  color: #1d4ed8;
  line-height: 1.5;
}

/* Booking Confirmation Terminal Page */
.booking-confirm-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 70vh;
  animation: fadeIn 0.4s ease;
}

.confirm-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 40px 20px;
  background: #fff;
  border-radius: 20px;
}

.confirm-check-icon {
  font-size: 5rem;
  color: #16a34a;
  margin-bottom: 24px;
}

.confirm-title {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.confirm-subtitle {
  font-size: 1rem;
  color: var(--text-secondary);
}

/* ==================================================================== */
/* Clinic Booking App: clinic landing + choose-a-therapist              */
/* ==================================================================== */

/* Clinic landing */
.clinic-welcome-screen {
  max-width: 600px;
  margin: 0 auto;
  padding: 20px;
  min-height: calc(100vh - 80px);
  display: flex;
  align-items: center;
  justify-content: center;
}

.clinic-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 40px 20px;
}

.clinic-photo-wrap {
  width: 148px;
  height: 148px;
  border-radius: 50%;
  overflow: hidden;
  margin-bottom: 30px;
  background: #fff;
  border: 4px solid rgba(255, 255, 255, 0.65);
  box-shadow: var(--shadow-lg);
}

.clinic-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.clinic-photo-fallback {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3.5rem;
  color: var(--primary-color);
  background: linear-gradient(135deg, #eef2ff, #f5f3ff);
}

.clinic-welcome-title {
  margin-bottom: 40px;
}

/* Choose a Therapist */
.therapist-select-screen {
  max-width: 760px;
  margin: 0 auto;
  padding: 20px;
  min-height: calc(100vh - 80px);
}

.ts-inner {
  background: #fff;
  border-radius: 20px;
  padding: 32px 28px;
  box-shadow: var(--shadow-lg);
}

.ts-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: none;
  border: none;
  color: var(--primary-color);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  padding: 6px 4px;
  margin-bottom: 10px;
}

.ts-back:hover {
  text-decoration: underline;
}

.ts-title {
  text-align: left;
  margin-bottom: 6px;
}

.ts-subtitle {
  text-align: left;
  margin-bottom: 22px;
}

.section-eyebrow {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--primary-color);
  margin-bottom: 12px;
}

.section-eyebrow-muted {
  color: var(--text-secondary);
  margin-top: 28px;
}

.scroll-hint {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0;
  color: var(--text-muted);
}

#firstAvailableCard {
  display: flex;
}

#firstAvailableCard .therapist-card {
  flex: 1;
  max-width: 360px;
  margin: 0 auto;
}

/* Horizontal, manually scrollable card strip */
.therapist-card-strip {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding: 4px 4px 14px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}

.therapist-card-strip .therapist-card {
  flex: 0 0 240px;
  scroll-snap-align: start;
}

.therapist-card-strip::-webkit-scrollbar {
  height: 8px;
}

.therapist-card-strip::-webkit-scrollbar-track {
  background: var(--bg-gray);
  border-radius: 4px;
}

.therapist-card-strip::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 4px;
}

/* Therapist card */
.therapist-card {
  position: relative;
  border: 2px solid var(--border-color);
  border-radius: 16px;
  padding: 22px 20px;
  background: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  transition: all 0.25s ease;
}

.therapist-card:hover {
  border-color: var(--primary-color);
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}

.therapist-card-featured {
  border: 2px solid transparent;
  background:
    linear-gradient(#fff, #fff) padding-box,
    linear-gradient(135deg, var(--primary-color), var(--secondary-color)) border-box;
  box-shadow: 0 12px 30px -8px rgba(99, 102, 241, 0.35);
}

.therapist-ribbon {
  position: absolute;
  top: 14px;
  right: 14px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  color: #fff;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 999px;
}

.therapist-photo-wrap {
  width: 84px;
  height: 84px;
  border-radius: 50%;
  overflow: hidden;
  margin-bottom: 14px;
  box-shadow: var(--shadow-sm);
  flex-shrink: 0;
}

.therapist-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.therapist-photo-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.7rem;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
}

.therapist-name {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 2px;
  color: var(--text-primary);
}

.therapist-role {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 12px;
}

.therapist-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
  margin-bottom: 14px;
}

.therapist-chip {
  font-size: 0.68rem;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(99, 102, 241, 0.1);
  color: var(--primary-hover);
  border: 1px solid rgba(99, 102, 241, 0.2);
  white-space: nowrap;
}

.therapist-languages {
  display: flex;
  align-items: center;
  gap: 6px;
  justify-content: center;
  flex-wrap: wrap;
  font-size: 0.78rem;
  color: var(--text-secondary);
  margin-bottom: 14px;
}

.therapist-languages i {
  color: var(--primary-color);
}

.therapist-availability {
  display: flex;
  align-items: center;
  gap: 6px;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--success-color);
  margin-top: auto;
  margin-bottom: 16px;
}

.therapist-availability-none {
  color: var(--text-muted);
  font-weight: 500;
}

.btn-book-now {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--primary-color);
  color: #fff;
  border: none;
  border-radius: 12px;
  padding: 12px 18px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-book-now:hover:not(:disabled) {
  background: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn-book-now-disabled {
  background: var(--border-color);
  color: var(--text-muted);
  cursor: not-allowed;
}

@media (max-width: 768px) {
  .ts-inner {
    padding: 24px 18px;
  }

  .clinic-photo-wrap {
    width: 120px;
    height: 120px;
  }

  .therapist-card-strip .therapist-card {
    flex-basis: 78%;
    max-width: 260px;
  }

  #firstAvailableCard .therapist-card {
    max-width: none;
  }
}
