/* TBC Booking Widget — Luxury Bridal Aesthetic */
/* Matches the new site palette: champagne, ivory, espresso, gold */

:root {
  --tbc-espresso:    #1C1612;
  --tbc-gold:        #B8965A;
  --tbc-gold-light:  #D4AE78;
  --tbc-champagne:   #F5EFE0;
  --tbc-ivory:       #FDFAF5;
  --tbc-muted:       #7A6A5A;
  --tbc-border:      #E0D8CC;
  --tbc-error:       #9B1D1D;
  --tbc-success:     #1A5C35;
  --tbc-radius:      2px;
  --tbc-font-body:   'Jost', system-ui, sans-serif;
  --tbc-font-serif:  'Cormorant Garamond', Georgia, serif;
}

.tbc-booking * {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

.tbc-booking {
  font-family: var(--tbc-font-body);
  color: var(--tbc-espresso);
  max-width: 680px;
  margin: 0 auto;
}

/* ── Progress Bar ──────────────────────────────────────────────────────────── */

.tbc-progress {
  display: flex;
  align-items: center;
  margin-bottom: 2.5rem;
  gap: 0;
}

.tbc-progress-step {
  flex: 1;
  text-align: center;
  position: relative;
}

.tbc-progress-step::after {
  content: '';
  position: absolute;
  top: 14px;
  left: 50%;
  width: 100%;
  height: 1px;
  background: var(--tbc-border);
}

.tbc-progress-step:last-child::after { display: none; }

.tbc-progress-dot {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1.5px solid var(--tbc-border);
  background: var(--tbc-ivory);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 6px;
  font-size: 0.65rem;
  font-weight: 500;
  color: var(--tbc-muted);
  position: relative;
  z-index: 1;
  transition: all 0.25s;
}

.tbc-progress-step.active .tbc-progress-dot {
  background: var(--tbc-espresso);
  border-color: var(--tbc-espresso);
  color: #fff;
}

.tbc-progress-step.complete .tbc-progress-dot {
  background: var(--tbc-gold);
  border-color: var(--tbc-gold);
  color: #fff;
}

.tbc-progress-step.complete::after { background: var(--tbc-gold); opacity: 0.4; }

.tbc-progress-label {
  font-size: 0.6rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--tbc-muted);
}

.tbc-progress-step.active .tbc-progress-label { color: var(--tbc-espresso); font-weight: 500; }
.tbc-progress-step.complete .tbc-progress-label { color: var(--tbc-gold); }

/* ── Step Container ────────────────────────────────────────────────────────── */

.tbc-step { display: none; animation: tbcFadeUp 0.3s ease; }
.tbc-step.active { display: block; }

@keyframes tbcFadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

.tbc-step-heading {
  font-family: var(--tbc-font-serif);
  font-size: 1.75rem;
  font-weight: 300;
  line-height: 1.2;
  margin-bottom: 0.35rem;
  color: var(--tbc-espresso);
}

.tbc-step-sub {
  font-size: 0.82rem;
  font-weight: 300;
  color: var(--tbc-muted);
  margin-bottom: 1.75rem;
  line-height: 1.6;
}

/* ── Appointment Type Cards (Step 1) ───────────────────────────────────────── */

.tbc-type-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

@media (max-width: 520px) { .tbc-type-grid { grid-template-columns: 1fr; } }

.tbc-type-card {
  border: 1.5px solid var(--tbc-border);
  background: var(--tbc-ivory);
  padding: 1.5rem 1.25rem;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  text-align: left;
  border-radius: var(--tbc-radius);
  position: relative;
}

.tbc-type-card:hover {
  border-color: var(--tbc-gold-light);
  background: var(--tbc-champagne);
}

.tbc-type-card.selected {
  border-color: var(--tbc-gold);
  background: var(--tbc-champagne);
}

.tbc-type-card.selected::before {
  content: '✓';
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  width: 20px;
  height: 20px;
  background: var(--tbc-gold);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  line-height: 20px;
  text-align: center;
}

.tbc-type-name {
  font-family: var(--tbc-font-serif);
  font-size: 1.1rem;
  font-weight: 400;
  color: var(--tbc-espresso);
  margin-bottom: 0.4rem;
  line-height: 1.3;
}

.tbc-type-duration {
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--tbc-gold);
  margin-bottom: 0.5rem;
}

.tbc-type-desc {
  font-size: 0.78rem;
  font-weight: 300;
  color: var(--tbc-muted);
  line-height: 1.6;
}

/* ── Calendar (Step 2) ─────────────────────────────────────────────────────── */

.tbc-calendar-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.tbc-cal-month {
  font-family: var(--tbc-font-serif);
  font-size: 1.2rem;
  font-weight: 300;
  color: var(--tbc-espresso);
}

.tbc-cal-btn {
  background: none;
  border: 1.5px solid var(--tbc-border);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1rem;
  color: var(--tbc-muted);
  transition: border-color 0.2s, color 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.tbc-cal-btn:hover { border-color: var(--tbc-gold); color: var(--tbc-gold); }
.tbc-cal-btn:disabled { opacity: 0.3; cursor: not-allowed; }

.tbc-calendar {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1.5rem;
}

.tbc-calendar th {
  font-size: 0.6rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--tbc-muted);
  padding: 0.4rem 0;
  text-align: center;
  font-weight: 400;
}

.tbc-calendar td {
  text-align: center;
  padding: 3px;
}

.tbc-cal-day {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: none;
  background: none;
  font-size: 0.82rem;
  cursor: pointer;
  font-family: var(--tbc-font-body);
  color: var(--tbc-espresso);
  transition: background 0.15s, color 0.15s;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.tbc-cal-day:hover:not(:disabled) { background: var(--tbc-champagne); }
.tbc-cal-day.selected { background: var(--tbc-espresso); color: #fff; }
.tbc-cal-day:disabled { color: var(--tbc-border); cursor: not-allowed; }
.tbc-cal-day.today { border: 1px solid var(--tbc-gold-light); }

/* ── Time Slots (Step 3) ───────────────────────────────────────────────────── */

.tbc-slots-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: 0.6rem;
  margin-bottom: 1.5rem;
}

.tbc-slot-btn {
  border: 1.5px solid var(--tbc-border);
  background: var(--tbc-ivory);
  padding: 0.6rem 0.5rem;
  font-size: 0.8rem;
  font-family: var(--tbc-font-body);
  color: var(--tbc-espresso);
  cursor: pointer;
  border-radius: var(--tbc-radius);
  transition: border-color 0.2s, background 0.2s;
  text-align: center;
}

.tbc-slot-btn:hover { border-color: var(--tbc-gold-light); background: var(--tbc-champagne); }
.tbc-slot-btn.selected { border-color: var(--tbc-gold); background: var(--tbc-champagne); font-weight: 500; }

.tbc-no-slots {
  font-size: 0.85rem;
  color: var(--tbc-muted);
  font-style: italic;
  text-align: center;
  padding: 2rem;
  background: var(--tbc-champagne);
  border-radius: var(--tbc-radius);
}

/* ── Form Fields (Step 4) ──────────────────────────────────────────────────── */

.tbc-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}

@media (max-width: 520px) { .tbc-form-grid { grid-template-columns: 1fr; } }

.tbc-form-field { display: flex; flex-direction: column; }
.tbc-form-field.full { grid-column: 1 / -1; }

.tbc-label {
  font-size: 0.65rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--tbc-muted);
  margin-bottom: 0.4rem;
  font-weight: 400;
}

.tbc-label span { color: var(--tbc-gold); }

.tbc-input,
.tbc-select,
.tbc-textarea {
  border: 1px solid var(--tbc-border);
  background: var(--tbc-ivory);
  padding: 0.7rem 0.85rem;
  font-size: 0.88rem;
  font-family: var(--tbc-font-body);
  color: var(--tbc-espresso);
  border-radius: var(--tbc-radius);
  width: 100%;
  transition: border-color 0.2s;
  -webkit-appearance: none;
  appearance: none;
}

.tbc-input:focus,
.tbc-select:focus,
.tbc-textarea:focus {
  outline: none;
  border-color: var(--tbc-gold);
}

.tbc-textarea { resize: vertical; min-height: 80px; }

.tbc-honeypot { display: none !important; visibility: hidden; }

/* ── Booking Summary (Step 5) ──────────────────────────────────────────────── */

.tbc-summary {
  background: var(--tbc-champagne);
  border: 1px solid rgba(184,150,90,0.25);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  border-radius: var(--tbc-radius);
}

.tbc-summary-title {
  font-size: 0.62rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--tbc-gold);
  margin-bottom: 1rem;
}

.tbc-summary-row {
  display: flex;
  justify-content: space-between;
  padding: 0.4rem 0;
  border-bottom: 1px solid rgba(184,150,90,0.15);
  font-size: 0.85rem;
}

.tbc-summary-row:last-child { border-bottom: none; }
.tbc-summary-key { color: var(--tbc-muted); font-weight: 300; }
.tbc-summary-val { color: var(--tbc-espresso); font-weight: 400; }

.tbc-consent {
  font-size: 0.75rem;
  color: var(--tbc-muted);
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

/* ── Confirmation Screen ───────────────────────────────────────────────────── */

.tbc-confirmation {
  text-align: center;
  padding: 2rem 1rem;
}

.tbc-confirm-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--tbc-gold);
  color: #fff;
  font-size: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
}

.tbc-confirm-heading {
  font-family: var(--tbc-font-serif);
  font-size: 2rem;
  font-weight: 300;
  color: var(--tbc-espresso);
  margin-bottom: 0.75rem;
}

.tbc-confirm-body {
  font-size: 0.88rem;
  font-weight: 300;
  color: var(--tbc-muted);
  line-height: 1.8;
  max-width: 420px;
  margin: 0 auto 1.5rem;
}

/* ── Buttons ───────────────────────────────────────────────────────────────── */

.tbc-btn-row {
  display: flex;
  gap: 1rem;
  align-items: center;
  flex-wrap: wrap;
}

.tbc-btn-primary {
  font-family: var(--tbc-font-body);
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #fff;
  background: var(--tbc-espresso);
  border: none;
  padding: 0.85rem 2rem;
  cursor: pointer;
  transition: background 0.2s;
  border-radius: var(--tbc-radius);
}

.tbc-btn-primary:hover:not(:disabled) { background: var(--tbc-gold); }
.tbc-btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }

.tbc-btn-ghost {
  font-family: var(--tbc-font-body);
  font-size: 0.65rem;
  font-weight: 400;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--tbc-muted);
  background: none;
  border: none;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.tbc-btn-ghost:hover { color: var(--tbc-espresso); }

/* ── Loading / Error ───────────────────────────────────────────────────────── */

.tbc-loading {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--tbc-muted);
  font-size: 0.82rem;
  padding: 1.5rem 0;
}

.tbc-spinner {
  width: 18px;
  height: 18px;
  border: 2px solid var(--tbc-border);
  border-top-color: var(--tbc-gold);
  border-radius: 50%;
  animation: tbcSpin 0.7s linear infinite;
  flex-shrink: 0;
}

@keyframes tbcSpin { to { transform: rotate(360deg); } }

.tbc-error-msg {
  background: #fff8f8;
  border: 1px solid #f5c4c4;
  color: var(--tbc-error);
  font-size: 0.82rem;
  padding: 0.85rem 1rem;
  border-radius: var(--tbc-radius);
  margin-bottom: 1rem;
}

.tbc-fallback-phone {
  font-size: 0.82rem;
  color: var(--tbc-muted);
  margin-top: 0.5rem;
}

.tbc-fallback-phone a { color: var(--tbc-gold); text-decoration: none; }
