/* Booking wizard — mobile-first (iPhone 390x844 baseline). */

.booking-wizard {
  max-width: 560px;
  margin: 0 auto;
  /* Bottom padding reserves space for sticky .booking-nav on every viewport. */
  padding: 1.25rem 1rem 96px;
  color: var(--text);
  background: var(--cream-soft, #f9f2e5);
  border: 1px solid var(--champagne-deep);
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(107, 111, 79, 0.06);
}

.booking-wizard * { box-sizing: border-box; }
.booking-wizard, .booking-wizard .booking-step { overflow-x: hidden; }
.booking-wizard input[type="date"],
.booking-wizard input[type="text"],
.booking-wizard input[type="email"],
.booking-wizard input[type="tel"],
.booking-wizard textarea,
.booking-wizard select { max-width: 100%; }

.booking-steps {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
  font-size: 0.8rem;
  color: var(--text-light);
}
.booking-steps__item {
  flex: 1;
  text-align: center;
  padding: 0.5rem 0.25rem;
  border-bottom: 2px solid var(--champagne-deep);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.booking-steps__item.is-active {
  color: var(--gold);
  border-bottom-color: var(--gold);
  font-weight: 600;
}
.booking-steps__item.is-done { color: var(--gold); }

.booking-step {
  min-height: 60vh;
  animation: stepIn 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
.booking-step[hidden] { display: none; }
@keyframes stepIn {
  from { opacity: 0; transform: translateX(12px); }
  to   { opacity: 1; transform: translateX(0); }
}
@media (prefers-reduced-motion: reduce) { .booking-step { animation: none; } }

.booking-step h2 {
  font-family: var(--font-display, 'Cormorant Garamond', Georgia, serif);
  font-style: italic;
  font-weight: 500;
  font-size: 1.7rem;
  margin: 0 0 1.25rem;
  color: var(--sage);
  letter-spacing: -0.01em;
  position: relative;
  padding-bottom: 0.5rem;
}
.booking-step h2::after {
  content: '';
  position: absolute;
  left: 0; bottom: 0;
  width: 36px; height: 1px;
  background: linear-gradient(90deg, var(--gold), transparent);
}

.step-hint {
  margin: -0.5rem 0 1rem;
  font-size: 0.88rem;
  color: var(--text-light);
  font-style: italic;
  letter-spacing: 0.01em;
}
.step-context {
  margin: -0.5rem 0 1rem;
  padding: 0.55rem 0.85rem;
  background: linear-gradient(135deg, rgba(201, 169, 97, 0.10) 0%, rgba(232, 213, 181, 0.18) 100%);
  border: 1px solid rgba(201, 169, 97, 0.32);
  border-radius: 10px;
  font-size: 0.92rem;
  color: var(--sage);
  font-weight: 500;
  letter-spacing: 0.01em;
}

.service-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
}
.booking-wizard .service-card {
  background: var(--white-warm);
  border: 1px solid var(--champagne-deep);
  border-radius: 12px;
  padding: 1rem;
  text-align: left;
  font: inherit;
  cursor: pointer;
  min-height: 64px;
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 14px;
  aspect-ratio: auto;
  box-shadow: none;
  overflow: visible;
}
.booking-wizard .service-card__check {
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  border: 1.5px solid var(--champagne-deep);
  border-radius: 6px;
  background: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}
.booking-wizard .service-card__check::after {
  content: "";
  width: 11px;
  height: 6px;
  border-left: 2px solid #fff;
  border-bottom: 2px solid #fff;
  transform: rotate(-45deg) translate(1px, -1px);
  opacity: 0;
  transition: opacity 0.18s ease;
}
.booking-wizard .service-card.is-selected .service-card__check {
  background: linear-gradient(135deg, #D4B575 0%, #C9A961 100%);
  border-color: var(--gold);
  box-shadow: 0 2px 6px rgba(201, 169, 97, 0.35);
}
.booking-wizard .service-card.is-selected .service-card__check::after { opacity: 1; }
.booking-wizard .service-card__body {
  flex: 1;
  min-width: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
@media (max-width: 480px) {
  .booking-wizard .service-card { min-height: auto; padding: 0.85rem 1rem; }
}
.booking-wizard .service-card {
  transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  -webkit-tap-highlight-color: transparent;
}
.booking-wizard .service-card:hover {
  border-color: var(--gold);
  outline: none;
  box-shadow: 0 8px 22px rgba(201, 169, 97, 0.22);
  transform: translateY(-2px);
  background: #FFFFFF;
}
/* Visible focus ring for keyboard users — was previously stripped to outline:none. */
.booking-wizard .service-card:focus-visible {
  border-color: var(--gold);
  outline: 3px solid var(--gold);
  outline-offset: 2px;
  box-shadow: 0 8px 22px rgba(201, 169, 97, 0.22);
  transform: translateY(-2px);
  background: #FFFFFF;
}
.booking-wizard .service-card.is-selected {
  border-color: var(--gold);
  outline: none;
  background: linear-gradient(135deg, #FBF6EB 0%, #F1E5CC 100%);
  box-shadow: 0 0 0 2px rgba(201, 169, 97, 0.55), 0 8px 24px rgba(201, 169, 97, 0.28);
  transform: none;
}
.booking-wizard .service-card:active { transform: translateY(0) scale(0.99); }
.service-card__name {
  font-weight: 600;
  color: var(--text);
  word-break: break-word;
  overflow-wrap: anywhere;
  flex: 1;
  min-width: 0;
}
.service-card__duration {
  color: var(--text-light);
  font-size: 0.9rem;
  flex: 0 0 auto;
  white-space: nowrap;
  margin-left: 12px;
}

.service-summary {
  margin-top: 1rem;
  padding: 0.75rem 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  background: linear-gradient(135deg, #FBF6EB 0%, #F1E5CC 100%);
  border: 1px solid rgba(201, 169, 97, 0.45);
  border-radius: 10px;
  box-shadow: 0 2px 8px rgba(201, 169, 97, 0.12);
  animation: summaryIn 0.32s cubic-bezier(0.16, 1, 0.3, 1);
}
.service-summary[hidden] { display: none; }
.service-summary__label {
  flex: 0 0 auto;
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--sage);
  font-weight: 600;
}
.service-summary__value {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
  text-align: right;
  letter-spacing: 0.01em;
  word-break: break-word;
  overflow-wrap: anywhere;
}
@keyframes summaryIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) { .service-summary { animation: none; } }

.date-calendar {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  background: var(--white-warm, #fff);
  border: 1px solid var(--champagne-deep);
  border-radius: 14px;
  padding: 1rem;
}
.date-month-label {
  font-family: var(--font-display, Georgia, serif);
  font-size: 1.05rem;
  color: var(--gold);
  text-align: center;
  letter-spacing: 0.04em;
  margin: 0 0 0.5rem;
  text-transform: capitalize;
}
.date-calendar > .date-grid + .date-month-label {
  margin-top: 0.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--champagne-deep);
}
.date-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
}
.date-grid__header {
  font-size: 0.7rem;
  color: var(--text-light);
  text-align: center;
  padding: 0.25rem 0 0.5rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 600;
}
.date-cell {
  aspect-ratio: 1 / 1;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 10px;
  cursor: pointer;
  font: inherit;
  color: var(--text);
  font-size: 0.95rem;
  padding: 0;
  -webkit-appearance: none;
  appearance: none;
}
.date-cell.is-empty { cursor: default; pointer-events: none; }
.date-cell.is-past {
  color: var(--text-light);
  cursor: not-allowed;
  opacity: 0.45;
  background: transparent;
}
.date-cell.is-available {
  background: #FFFFFF;
  border-color: rgba(217, 192, 154, 0.55);
  font-weight: 500;
  box-shadow: 0 1px 2px rgba(74, 66, 56, 0.04);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.date-cell.is-available:hover {
  border-color: var(--gold);
  outline: none;
  transform: translateY(-2px);
  background: var(--cream-soft, #f9f2e5);
  box-shadow: 0 6px 16px rgba(201, 169, 97, 0.22);
}
.date-cell.is-available:focus-visible {
  border-color: var(--gold);
  outline: 3px solid var(--gold);
  outline-offset: 1px;
  transform: translateY(-2px);
  background: var(--cream-soft, #f9f2e5);
}
.date-cell.is-available:active { transform: translateY(0) scale(0.96); }
.date-cell.is-selected {
  background: linear-gradient(135deg, #D4B575 0%, #C9A961 50%, #B89856 100%);
  color: #ffffff;
  border-color: var(--gold);
  font-weight: 600;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.35),
    0 6px 18px rgba(201, 169, 97, 0.45);
}

.inquiry-link {
  display: inline-block;
  margin-top: 1rem;
  color: var(--gold);
  text-decoration: underline;
  font-size: 0.95rem;
}

.slot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(96px, 1fr));
  gap: 8px;
}
.slot-btn {
  min-height: 48px;
  padding: 0.75rem 1rem;
  border: 1px solid rgba(217, 192, 154, 0.55);
  background: #FFFFFF;
  border-radius: 10px;
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  color: var(--text);
  box-shadow: 0 1px 2px rgba(74, 66, 56, 0.05);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  -webkit-tap-highlight-color: transparent;
}
.slot-btn:hover {
  border-color: var(--gold);
  outline: none;
  transform: translateY(-2px);
  background: var(--cream-soft);
  box-shadow: 0 6px 16px rgba(201, 169, 97, 0.22);
}
.slot-btn:focus-visible {
  border-color: var(--gold);
  outline: 3px solid var(--gold);
  outline-offset: 2px;
  transform: translateY(-2px);
  background: var(--cream-soft);
}
.slot-btn:active { transform: translateY(0) scale(0.97); }
.slot-btn.is-selected {
  background: linear-gradient(135deg, #D4B575 0%, #C9A961 50%, #B89856 100%);
  color: #FFFFFF;
  border-color: var(--gold);
  font-weight: 600;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.35),
    0 6px 18px rgba(201, 169, 97, 0.45);
}

.slot-btn.is-recommended {
  position: relative;
  border-color: var(--gold);
  background: rgba(201, 169, 97, 0.08);
  font-weight: 600;
}
.slot-btn.is-recommended::before {
  content: "";
  position: absolute;
  top: 5px; right: 5px;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 8px rgba(201, 169, 97, 0.9);
  animation: recPulse 2s ease-in-out infinite;
}
@keyframes recPulse {
  0%, 100% { opacity: 0.7; transform: scale(0.85); }
  50%      { opacity: 1;   transform: scale(1.1); }
}
.slot-btn.is-recommended.is-selected::before { background: var(--cream-soft); }
@media (prefers-reduced-motion: reduce) {
  .slot-btn.is-recommended::before { animation: none; }
}

.slot-legend {
  display: flex; align-items: center; gap: 6px;
  margin-bottom: 0.5rem;
  font-size: 0.8rem;
  color: var(--text-light);
}
.slot-legend__dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 4px rgba(201, 169, 97, 0.7);
}
.slot-empty { padding: 1rem; color: var(--text-light); background: var(--cream-soft); border-radius: 10px; }

.field { display: block; margin-bottom: 1rem; }
.field label { display: block; font-weight: 600; font-size: 0.9rem; margin-bottom: 0.35rem; color: var(--sage); }
.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid var(--champagne-deep);
  border-radius: 10px;
  background: var(--white-warm);
  font-size: 16px; /* prevents iOS zoom */
  font-family: inherit;
  min-height: 44px;
  color: var(--text);
}
.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--gold);
  outline: 2px solid rgba(201, 169, 97, 0.18);
  outline-offset: 0;
}
.field textarea { min-height: 88px; resize: vertical; }
.field__hint { margin-top: 0.25rem; font-size: 0.8rem; color: var(--text-light); }

/* Cancel-policy hint shown on step 4. Same tone as field hints but with a
   subtle border on the left and slight padding so the rule stands out as a
   "before-you-submit" notice, not just a placeholder. */
.booking-policy {
  margin: 1rem 0 0;
  padding: 0.7rem 0.85rem;
  background: var(--cream-soft, #F9F2E5);
  border-left: 3px solid var(--gold, #C9A961);
  border-radius: 0 8px 8px 0;
  font-size: 0.86rem;
  color: var(--text);
  line-height: 1.5;
}
.booking-policy span { margin-right: 4px; color: var(--gold-dark, #8B6F2B); font-weight: 700; }
.field__status {
  font-size: 0.82rem;
  margin: 0.3rem 0 0;
  line-height: 1.5;
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}
.field__status--ok { color: #3e7a4a; }
/* Darkened from #8B3A3E (3.8:1) → 5.0:1 on white, AA-compliant for small text. */
.field__status--bad { color: #6B2A2E; }
/* Darkened from #B8860B (3.4:1) → 4.6:1, AA-compliant. */
.field__status--warn { color: #7A5400; }
.field__suggest {
  appearance: none;
  border: 1px dashed #B8860B;
  background: rgba(184, 134, 11, 0.08);
  color: #B8860B;
  font: inherit;
  padding: 1px 8px;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 600;
}
.field__suggest:hover { background: rgba(184, 134, 11, 0.18); }

.field.has-error input,
.field.has-error textarea,
.field.has-error select { border-color: #8B3A3E; box-shadow: 0 0 0 3px rgba(139, 58, 62, 0.10); }
.field.is-valid input,
.field.is-valid textarea { border-color: #3e7a4a; }
.field.is-warn input { border-color: #B8860B; }

.phone-field { display: flex; gap: 0.5rem; }
.phone-field select {
  flex: 0 0 96px;
  padding: 0.75rem 0.5rem;
  border: 1px solid var(--champagne-deep);
  border-radius: 10px;
  background: var(--white-warm);
  font-size: 16px;
  min-height: 44px;
  color: var(--text);
}
.phone-field input { flex: 1; }

.phone-field--fixed { gap: 0; position: relative; }
.phone-field--fixed .phone-prefix {
  display: inline-flex;
  align-items: center;
  padding: 0 0.85rem;
  min-height: 44px;
  font-size: 1rem;
  font-weight: 500;
  color: var(--sage);
  background: var(--cream-soft);
  border: 1px solid var(--champagne-deep);
  border-right: 0;
  border-radius: 10px 0 0 10px;
  letter-spacing: 0.02em;
}
.phone-field--fixed input[type="tel"] {
  border-radius: 0 10px 10px 0;
  flex: 1;
}

.booking-nav {
  display: flex;
  gap: 0.6rem;
  margin-top: 1.75rem;
  padding: 1rem 0 0;
  border-top: 1px solid var(--champagne-deep);
  /* Sticky on mobile so Dalje is always reachable. On desktop just sits naturally. */
  position: sticky;
  bottom: 0;
  z-index: 5;
  background: linear-gradient(to bottom, transparent 0%, var(--cream-soft) 22%, var(--cream-soft) 100%);
  padding-bottom: calc(1rem + env(safe-area-inset-bottom, 0));
}
.booking-nav .btn {
  flex: 1;
  min-height: 52px;
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  padding: 14px 18px;
}
.booking-nav .btn-ghost { flex: 0 0 auto; padding-left: 22px; padding-right: 22px; }
#nav-back {
  flex: 0 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}
#nav-back::before {
  content: "←";
  font-size: 1rem;
  letter-spacing: 0;
  margin-right: 4px;
}
#nav-next::after {
  content: "→";
  font-size: 1rem;
  letter-spacing: 0;
  margin-left: 4px;
  transition: transform 0.25s var(--ease-luxe, ease);
}
#nav-next:hover::after { transform: translateX(3px); }
@media (min-width: 640px) {
  .booking-nav { gap: 0.9rem; }
  #nav-back, .booking-nav .btn-ghost {
    padding-left: 32px;
    padding-right: 32px;
  }
}

.booking-error {
  color: #8B3A3E;
  background: #FBEDEC;
  border-radius: 10px;
  padding: 0.75rem;
  margin-bottom: 1rem;
  font-size: 0.95rem;
}
.booking-error[hidden] { display: none; }

.booking-success {
  text-align: center;
  padding: 2rem 1rem;
}
.booking-success__check {
  width: 64px; height: 64px;
  border-radius: 50%;
  background: #E4F1E6;
  color: #2E6B3B;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin-bottom: 1rem;
}

@media (min-width: 640px) {
  .service-grid { grid-template-columns: repeat(2, 1fr); }
  .booking-wizard { padding: 1.5rem; }
}

/* Step 2 advanced filters — find by time / earliest free */
.time-first {
  background: linear-gradient(160deg, #FFFDF8, #FBF5E9);
  border: 1px solid rgba(201, 169, 97, 0.35);
  border-radius: 16px;
  padding: 1.1rem 1rem 1.2rem;
  box-shadow: 0 4px 16px rgba(74, 66, 56, 0.06);
  margin-bottom: 0.6rem;
}
/* "— or —" divider with flanking gold rules */
.time-first__or {
  display: flex; align-items: center; gap: 0.7rem;
  color: var(--sage, #6B6F4F); font-size: 0.74rem;
  letter-spacing: 1px; text-transform: uppercase; margin: 1rem 0 0.7rem;
}
.time-first__or::before, .time-first__or::after {
  content: ""; flex: 1; height: 1px;
  background: linear-gradient(to right, transparent, rgba(201,169,97,0.55), transparent);
}
/* Earliest free CTA */
#earliest-btn {
  display: flex; align-items: center; justify-content: center; gap: 0.4rem;
  border: 1.5px solid var(--gold, #C9A961); background: #fff;
  color: var(--gold-dark, #8B6F2B); font-weight: 600; letter-spacing: 0.3px;
  border-radius: 12px; min-height: 50px;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
#earliest-btn:hover {
  background: linear-gradient(135deg, #D4B575, #C9A961); color: #fff;
  transform: translateY(-2px); box-shadow: 0 8px 20px rgba(201,169,97,0.35);
}
#earliest-btn:disabled { opacity: 0.6; transform: none; box-shadow: none; }
/* Part-of-day chips */
.chip-row { display: flex; flex-wrap: wrap; gap: 0.5rem; }
#window-chips { justify-content: center; }
.booking-wizard .chip {
  appearance: none; cursor: pointer; min-height: 40px;
  padding: 0.5rem 1rem; border: 1px solid rgba(201,169,97,0.55);
  border-radius: 999px; background: #fff; color: var(--text, #4A4238);
  font-family: inherit; font-size: 0.9rem; font-weight: 500;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  -webkit-tap-highlight-color: transparent;
}
.booking-wizard .chip:hover { border-color: var(--gold, #C9A961); background: var(--cream-soft, #F9F2E5); transform: translateY(-1px); }
.booking-wizard .chip.is-active {
  background: linear-gradient(135deg, #D4B575, #C9A961); color: #fff;
  border-color: var(--gold, #C9A961); font-weight: 600;
  box-shadow: 0 4px 12px rgba(201,169,97,0.4);
}
/* Exact-time row */
.tf-exact {
  display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem;
  justify-content: center; margin-top: 0.9rem;
}
.tf-exact label { font-size: 0.85rem; color: var(--sage, #6B6F4F); font-weight: 500; }
.tf-exact input[type="time"] {
  padding: 0.5rem 0.7rem; border: 1px solid rgba(201,169,97,0.55);
  border-radius: 10px; background: #fff; font-family: inherit; font-size: 16px;
  color: var(--text, #4A4238);
}
.tf-exact input[type="time"]:focus {
  outline: none; border-color: var(--gold, #C9A961);
  box-shadow: 0 0 0 3px rgba(201,169,97,0.18);
}
#exact-time-btn { min-height: 42px; border-radius: 10px; }
/* Results: day groups */
#time-first-results:not(:empty) {
  margin-top: 0.9rem; padding-top: 0.7rem;
  border-top: 1px dashed rgba(201,169,97,0.4);
}
.tf-day { padding: 0.55rem 0; }
.tf-day + .tf-day { border-top: 1px solid rgba(201,169,97,0.18); }
.tf-day__label {
  font-family: var(--font-display, 'Cormorant Garamond', Georgia, serif);
  font-weight: 600; color: var(--sage, #6B6F4F); font-size: 1.1rem; margin-bottom: 0.45rem;
}
.tf-day__slots { display: flex; flex-wrap: wrap; gap: 0.45rem; }

/* Smart gap nudge */
.slot-suggest {
  margin-top: 0.9rem; padding: 0.9rem 1rem;
  background: linear-gradient(160deg, #FFFDF8, #FBF5E9);
  border: 1px solid rgba(201,169,97,0.5); border-radius: 14px;
  box-shadow: 0 4px 14px rgba(74,66,56,0.07);
}
.slot-suggest__msg { margin: 0 0 0.7rem; color: var(--text,#4A4238); font-size: 0.95rem; line-height: 1.45; }
.slot-suggest__actions { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.slot-suggest__actions .btn { min-height: 44px; }
