/* ══════════════════════════════════════════════════════════
   Guest Checkout — scoped styles
   Theme: black & white, Bootstrap 5, mobile-first
   ══════════════════════════════════════════════════════════ */

/* ─── Page wrapper ─────────────────────────────────────────────────────────── */
.guest-checkout-page {
  background: #f5f5f7;
  min-height: 100vh;
  padding-top: 1.5rem;
}

/* ─── Card primitives ─────────────────────────────────────────────────────── */
.gc-card {
  background: #fff;
  border-radius: 12px;
  border: 1px solid rgba(0, 0, 0, 0.07);
  /* overflow must stay visible so the absolutely-positioned calendar
     popup is not clipped — border-radius works without it */
  overflow: visible;
  transition: opacity 0.25s ease;
}

.gc-card--muted {
  background: #fafafa;
}

.gc-card__header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px 20px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.07);
  background: #fff;
  /* round the top corners since the card no longer clips them via overflow */
  border-top-left-radius: 12px;
  border-top-right-radius: 12px;
}

.gc-card--muted .gc-card__header {
  background: #fafafa;
}

.gc-card__body {
  padding: 20px;
}

/* ─── Step numbering ──────────────────────────────────────────────────────── */
.gc-step-header {
  padding: 14px 20px;
}

.gc-step-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #212529;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  flex-shrink: 0;
}

/* ─── Locked section ──────────────────────────────────────────────────────── */
.section-locked {
  opacity: 0.55;
  pointer-events: none;
  user-select: none;
}

.section-lock-msg {
  font-size: 0.8rem;
  color: #888;
}

/* ─── Sticky summary (desktop) ────────────────────────────────────────────── */
@media (min-width: 992px) {
  .gc-sticky-summary {
    position: sticky;
    top: 80px;
  }
}

/* ─── Treatment rows ──────────────────────────────────────────────────────── */
.treatment-row {
  font-size: 0.92rem;
}

.treatment-row:last-child {
  border-bottom: none !important;
}

.remove-treatment:hover {
  color: #e8542a !important;
}

/* ─── Coupon input ────────────────────────────────────────────────────────── */
#couponCode {
  font-size: 0.875rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

#couponCode:disabled {
  background-color: #f0fdf4;
  color: #166534;
}

/* ─── Order totals ────────────────────────────────────────────────────────── */
#order-total {
  font-size: 1.1rem;
}

/* ─── Form floating overrides ─────────────────────────────────────────────── */
.gc-card .form-floating > .form-control {
  border-radius: 8px;
  border: 1.5px solid #dee2e6;
  transition: border-color 0.15s ease;
}

.gc-card .form-floating > .form-control:focus {
  border-color: #212529;
  box-shadow: 0 0 0 0.15rem rgba(33, 37, 41, 0.12);
}

/* Phone group alignment */
.gc-card .input-group {
  border-radius: 8px;
  overflow: hidden;
}

.gc-card .input-group .form-floating:first-child .form-control {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}

.gc-card .input-group .form-floating:last-child .form-control {
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
  border-left: 0;
}

/* ─── Check availability button ───────────────────────────────────────────── */
#check-availability-btn {
  border-radius: 8px;
  padding: 14px;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  transition:
    background 0.2s ease,
    transform 0.1s ease;
}

#check-availability-btn:not(:disabled):active {
  transform: scale(0.99);
}

/* ─── Calendar overrides ──────────────────────────────────────────────────── */
.gc-card .small-calendar-container {
  margin: 0;
  max-width: 100%;
}

.gc-card .small-calendar {
  box-shadow: none;
  border-radius: 0;
  border: 1px solid #eee;
  border-radius: 10px;
}

.small-calendar--keys {
  font-size: 0.82rem;
  color: #555;
  padding-bottom: 4px;
}

/* Time slots — tighter on mobile */
@media (max-width: 480px) {
  .small-calendar--times {
    grid-template-columns: repeat(4, 1fr);
    padding: 0 12px 16px;
  }
}

/* ─── Payment buttons ─────────────────────────────────────────────────────── */
#payment-section .btn {
  border-radius: 8px;
  padding: 14px 20px;
  font-size: 0.95rem;
  transition:
    background 0.2s ease,
    transform 0.1s ease;
}

#payment-section .btn:active {
  transform: scale(0.99);
}

#payment-section .btn-dark {
  background: #212529;
}

#payment-section .btn-outline-dark {
  border-width: 1.5px;
}

/* ─── Secure-now highlight ────────────────────────────────────────────────── */
#secure-now-btn {
  background: #212529;
  border: none;
  color: #fff;
  position: relative;
  overflow: hidden;
}

#secure-now-btn::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.05) 0%,
    transparent 60%
  );
  pointer-events: none;
}

/* ─── Loading overlay (re-uses existing #loader) ────────────────────────── */
#loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(255, 255, 255, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  color: #333;
  backdrop-filter: blur(2px);
}

#loader::before {
  content: attr(data-wordLoad);
  margin-right: 10px;
}

#loader::after {
  content: "";
  width: 20px;
  height: 20px;
  border: 2px solid #212529;
  border-top-color: transparent;
  border-radius: 50%;
  animation: gc-spin 0.8s linear infinite;
}

@keyframes gc-spin {
  to {
    transform: rotate(360deg);
  }
}

/* ─── Notification / error badge ──────────────────────────────────────────── */
.gc-inline-error {
  font-size: 0.82rem;
  color: #dc3545;
}

/* ─── Mobile polish ───────────────────────────────────────────────────────── */
@media (max-width: 576px) {
  .gc-card__body {
    padding: 16px;
  }

  .gc-card__header {
    padding: 12px 16px;
  }

  .guest-checkout-page {
    padding-top: 1rem;
  }
}

/* ─── Calendar popup — ensure it floats above all other page content ────────── */
#availability-section {
  /* Create a stacking context so the calendar popup z-index is relative
     to this card, not the whole page */
  position: relative;
  z-index: 10;
}

#availability-section .gc-card__body {
  /* Extra bottom padding so the calendar popup has visual room below */
  padding-bottom: 280px;
  margin-bottom: -260px;
}

.date-selection-list {
  z-index: 100 !important;
}

.iti {
  width: 100%;
}

.payment-option-card {
  background: #f8f9fa;
  border: 2px solid #dee2e6;
  border-radius: 8px;
  padding: 15px;
  transition: all 0.2s ease;
  cursor: pointer;
  padding-left: 1.5em !important;
  z-index: 999;
  display: block;
  position: relative;
}

.payment-option-card:hover {
  background: #e9ecef;
  border-color: #adb5bd;
}

.payment-option-card:has(input:checked) {
  background: #fff;
  border-color: #212529;
  box-shadow: 0 0 0 3px rgba(33, 37, 41, 0.1);
}

.payment-option-card .form-check-input {
  margin-top: 0.25rem;
}

.payment-option-card label {
  cursor: pointer;
  margin-bottom: 0;
  padding-left: 10px;
}

.payment-option-card .form-check-input {
  margin-left: -2em !important;
  z-index: 999;
  display: block;
  position: relative;
}

.payment-option-card .form-check-input:checked {
  background-color: black !important;
  border-color: black !important;
}
