/* ============================================================
   Tina Thai Therapy — Booking Widget Styles
   Prefixed bk- to avoid collisions with site CSS
   ============================================================ */

/* ---------- Overlay & Modal Shell ---------- */
.bk-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(26, 14, 6, 0.55);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}
.bk-overlay.bk-open {
  opacity: 1;
  visibility: visible;
}

.bk-modal {
  background: var(--cream, #FEFAF4);
  border-radius: 18px;
  width: 94vw;
  max-width: 460px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(26, 14, 6, 0.25);
  position: relative;
  transform: translateY(20px);
  transition: transform 0.3s ease;
}
.bk-overlay.bk-open .bk-modal {
  transform: translateY(0);
}

/* ---------- Header ---------- */
.bk-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px 16px;
  border-bottom: 1px solid var(--bg-warm, #ECE0D0);
}
.bk-title {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.25rem;
  color: var(--primary-dark, #1A0E06);
  margin: 0;
}
.bk-close {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-light, #6B5540);
  padding: 4px;
  line-height: 1;
  font-size: 1.5rem;
  transition: color 0.2s;
}
.bk-close:hover { color: var(--primary-dark, #1A0E06); }

/* ---------- Body ---------- */
.bk-body {
  padding: 20px 24px 24px;
}

/* ---------- Steps indicator ---------- */
.bk-steps {
  display: flex;
  gap: 6px;
  margin-bottom: 20px;
}
.bk-step-dot {
  flex: 1;
  height: 4px;
  border-radius: 2px;
  background: var(--bg-warm, #ECE0D0);
  transition: background 0.3s;
}
.bk-step-dot.bk-active {
  background: var(--gold, #E2A82E);
}
.bk-step-dot.bk-done {
  background: var(--primary, #B87520);
}

/* ---------- Step title ---------- */
.bk-step-title {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.1rem;
  margin-bottom: 16px;
  color: var(--primary-dark, #1A0E06);
}

/* ---------- Service cards ---------- */
.bk-services {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 18px;
}
.bk-svc {
  padding: 12px 10px;
  border: 2px solid var(--bg-warm, #ECE0D0);
  border-radius: 10px;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text, #1E1108);
  background: var(--white, #fff);
}
.bk-svc:hover {
  border-color: var(--primary-light, #D09030);
}
.bk-svc.bk-selected {
  border-color: var(--gold, #E2A82E);
  background: rgba(226, 168, 46, 0.08);
}

/* ---------- Duration pills ---------- */
.bk-durations {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.bk-dur {
  flex: 1;
  min-width: 80px;
  padding: 10px 6px;
  border: 2px solid var(--bg-warm, #ECE0D0);
  border-radius: 10px;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  background: var(--white, #fff);
}
.bk-dur:hover {
  border-color: var(--primary-light, #D09030);
}
.bk-dur.bk-selected {
  border-color: var(--gold, #E2A82E);
  background: rgba(226, 168, 46, 0.08);
}
.bk-dur-time {
  display: block;
  font-size: 0.8rem;
  color: var(--text-light, #6B5540);
  margin-bottom: 2px;
}
.bk-dur-price {
  display: block;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--primary-dark, #1A0E06);
}

/* ---------- Calendar grid ---------- */
.bk-cal-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.bk-cal-nav button {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 1.3rem;
  color: var(--text-light, #6B5540);
  padding: 4px 8px;
  border-radius: 6px;
  transition: background 0.2s;
}
.bk-cal-nav button:hover {
  background: var(--bg-light, #F5EDE2);
}
.bk-cal-nav button:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}
.bk-cal-month {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1rem;
  color: var(--primary-dark, #1A0E06);
}

.bk-cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  margin-bottom: 16px;
}
.bk-cal-dow {
  text-align: center;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--text-light, #6B5540);
  padding: 4px 0;
  text-transform: uppercase;
}
.bk-cal-day {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  font-size: 0.85rem;
  cursor: pointer;
  border: none;
  background: none;
  color: var(--text, #1E1108);
  transition: background 0.2s, color 0.2s;
}
.bk-cal-day:hover:not(.bk-disabled):not(.bk-empty) {
  background: var(--bg-light, #F5EDE2);
}
.bk-cal-day.bk-today {
  font-weight: 700;
  box-shadow: inset 0 0 0 1.5px var(--gold, #E2A82E);
}
.bk-cal-day.bk-selected {
  background: var(--gold, #E2A82E);
  color: var(--white, #fff);
  font-weight: 700;
}
.bk-cal-day.bk-disabled {
  color: var(--bg-warm, #ECE0D0);
  cursor: not-allowed;
}
.bk-cal-day.bk-empty {
  cursor: default;
}

/* ---------- Time slots ---------- */
.bk-slots {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
  max-height: 200px;
  overflow-y: auto;
}
.bk-slot {
  padding: 8px 14px;
  border: 2px solid var(--bg-warm, #ECE0D0);
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 600;
  background: var(--white, #fff);
  color: var(--text, #1E1108);
  transition: border-color 0.2s, background 0.2s;
}
.bk-slot:hover {
  border-color: var(--primary-light, #D09030);
}
.bk-slot.bk-selected {
  border-color: var(--gold, #E2A82E);
  background: var(--gold, #E2A82E);
  color: var(--white, #fff);
}

/* ---------- Form inputs ---------- */
.bk-field {
  margin-bottom: 14px;
}
.bk-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-light, #6B5540);
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.bk-input {
  width: 100%;
  padding: 10px 14px;
  border: 2px solid var(--bg-warm, #ECE0D0);
  border-radius: 10px;
  font-size: 0.95rem;
  font-family: inherit;
  color: var(--text, #1E1108);
  background: var(--white, #fff);
  transition: border-color 0.2s;
  outline: none;
}
.bk-input:focus {
  border-color: var(--gold, #E2A82E);
}
.bk-input.bk-error {
  border-color: #c0392b;
}

/* ---------- Summary card ---------- */
.bk-summary {
  background: var(--bg-light, #F5EDE2);
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 18px;
}
.bk-summary-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.88rem;
  padding: 4px 0;
}
.bk-summary-label {
  color: var(--text-light, #6B5540);
}
.bk-summary-value {
  font-weight: 700;
  color: var(--primary-dark, #1A0E06);
}

/* ---------- Buttons ---------- */
.bk-btn {
  display: block;
  width: 100%;
  padding: 14px;
  border: none;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
  text-align: center;
}
.bk-btn:active {
  transform: scale(0.98);
}
.bk-btn-gold {
  background: var(--gold, #E2A82E);
  color: var(--white, #fff);
}
.bk-btn-gold:hover {
  background: var(--gold-light, #F0C850);
}
.bk-btn-gold:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.bk-btn-outline {
  background: none;
  border: 2px solid var(--bg-warm, #ECE0D0);
  color: var(--text, #1E1108);
}
.bk-btn-outline:hover {
  border-color: var(--primary-light, #D09030);
}
.bk-btn + .bk-btn {
  margin-top: 10px;
}

/* ---------- Back link ---------- */
.bk-back {
  display: inline-block;
  font-size: 0.85rem;
  color: var(--text-light, #6B5540);
  cursor: pointer;
  margin-bottom: 14px;
  background: none;
  border: none;
  font-family: inherit;
  padding: 0;
  transition: color 0.2s;
}
.bk-back:hover {
  color: var(--primary-dark, #1A0E06);
}

/* ---------- Loading spinner ---------- */
.bk-loading {
  text-align: center;
  padding: 30px 0;
  color: var(--text-light, #6B5540);
}
.bk-spinner {
  width: 32px;
  height: 32px;
  border: 3px solid var(--bg-warm, #ECE0D0);
  border-top-color: var(--gold, #E2A82E);
  border-radius: 50%;
  animation: bk-spin 0.7s linear infinite;
  margin: 0 auto 10px;
}
@keyframes bk-spin {
  to { transform: rotate(360deg); }
}

/* ---------- Confirmation ---------- */
.bk-confirm-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: rgba(46, 204, 113, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
}
.bk-confirm-icon svg {
  width: 32px;
  height: 32px;
  stroke: #2ecc71;
  stroke-width: 3;
  fill: none;
}
.bk-confirm-heading {
  text-align: center;
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.2rem;
  margin-bottom: 18px;
  color: var(--primary-dark, #1A0E06);
}

.bk-gcal-link {
  display: block;
  text-align: center;
  color: var(--primary, #B87520);
  font-size: 0.88rem;
  margin-top: 12px;
  text-decoration: underline;
}

/* ---------- Error/message ---------- */
.bk-msg {
  text-align: center;
  padding: 16px;
  border-radius: 10px;
  font-size: 0.9rem;
  margin-bottom: 14px;
}
.bk-msg-error {
  background: rgba(192, 57, 43, 0.08);
  color: #c0392b;
}
.bk-msg-info {
  background: rgba(226, 168, 46, 0.1);
  color: var(--gold-dark, #96700E);
}

/* ---------- Manage booking list ---------- */
.bk-booking-item {
  border: 2px solid var(--bg-warm, #ECE0D0);
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 10px;
  background: var(--white, #fff);
}
.bk-booking-date {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--primary-dark, #1A0E06);
  margin-bottom: 2px;
}
.bk-booking-detail {
  font-size: 0.82rem;
  color: var(--text-light, #6B5540);
  margin-bottom: 8px;
}
.bk-booking-actions {
  display: flex;
  gap: 8px;
}
.bk-booking-actions button {
  flex: 1;
  padding: 8px;
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  border: 2px solid var(--bg-warm, #ECE0D0);
  background: var(--white, #fff);
  color: var(--text, #1E1108);
  transition: border-color 0.2s, background 0.2s;
}
.bk-booking-actions button:hover {
  border-color: var(--primary-light, #D09030);
}
.bk-booking-actions .bk-cancel-btn {
  color: #c0392b;
  border-color: rgba(192, 57, 43, 0.3);
}
.bk-booking-actions .bk-cancel-btn:hover {
  background: rgba(192, 57, 43, 0.06);
  border-color: #c0392b;
}

/* ---------- Cancel confirm dialog ---------- */
.bk-cancel-dialog {
  text-align: center;
  padding: 10px 0;
}
.bk-cancel-dialog p {
  margin-bottom: 16px;
  color: var(--text, #1E1108);
}
.bk-cancel-dialog .bk-btn-danger {
  background: #c0392b;
  color: #fff;
}
.bk-cancel-dialog .bk-btn-danger:hover {
  background: #a93226;
}

/* ---------- Professional Service Notice (Step 5) ---------- */
.bk-notice {
  background: linear-gradient(135deg, #2A1508 0%, #5C3A18 30%, #A07828 65%, #B8923C 100%);
  border: 2px solid rgba(226, 190, 100, 0.5);
  border-radius: 14px;
  padding: 28px 24px;
  text-align: center;
  position: relative;
}
.bk-notice-heading {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.3rem;
  font-weight: 700;
  color: #F5D060;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 6px;
  text-shadow: 0 1px 3px rgba(0,0,0,0.3);
}
.bk-notice-divider {
  width: 60px;
  height: 2px;
  background: linear-gradient(90deg, transparent, #F0D070, transparent);
  margin: 10px auto 18px;
}
.bk-notice-text {
  font-family: 'Lato', sans-serif;
  font-size: 0.92rem;
  font-weight: 300;
  color: #FFF8EC;
  line-height: 1.65;
  margin-bottom: 14px;
  padding: 0 8px;
  text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}
.bk-notice-text strong {
  font-weight: 600;
  color: #F5D060;
}
.bk-notice-highlight {
  background: rgba(26, 14, 6, 0.5);
  border: 2px solid rgba(240, 210, 100, 0.5);
  border-radius: 10px;
  padding: 18px 20px;
  margin: 16px 0;
}
.bk-notice-highlight p {
  font-family: 'Lato', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  color: #FFFFFF;
  line-height: 1.5;
  text-shadow: 0 2px 4px rgba(0,0,0,0.3);
  margin: 0;
}
.bk-notice-highlight strong {
  color: #F5D060;
  font-weight: 700;
  font-size: 1.1rem;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.bk-notice-closing {
  font-family: 'Lato', sans-serif;
  font-size: 0.88rem;
  font-weight: 300;
  color: #F0D070;
  line-height: 1.5;
  margin-top: 14px;
  margin-bottom: 0;
  font-style: italic;
  text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

/* ---------- Hidden ---------- */
.bk-hidden { display: none !important; }

/* ---------- Mobile tweaks ---------- */
@media (max-width: 480px) {
  .bk-modal {
    width: 100vw;
    max-width: 100vw;
    border-radius: 18px 18px 0 0;
    max-height: 95vh;
  }
  .bk-overlay {
    align-items: flex-end;
  }
  .bk-overlay.bk-open .bk-modal {
    transform: translateY(0);
  }
  .bk-services {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }
  .bk-svc {
    font-size: 0.76rem;
    padding: 10px 6px;
  }
}
