/* ==========================================================================
   RESERVA DE TURNOS
   Tarjeta central con: pasos arriba, contenido del paso y resumen fijo
   abajo (en celu queda pegado al borde inferior mientras se elige).
   ========================================================================== */

.reservas { background:
  radial-gradient(90% 60% at 50% 0%, rgba(201, 154, 82, 0.1), transparent 70%), var(--bg); }

.booking {
  position: relative;
  max-width: 860px; margin-inline: auto;
  background: var(--surface); border: 1px solid var(--line-strong); border-radius: 22px;
  box-shadow: var(--shadow);
}

/* ---------- Pasos ---------- */
.booking__steps {
  display: grid; grid-template-columns: repeat(4, 1fr);
  padding: 14px 10px 0; gap: 4px;
}
.booking.is-done .booking__steps { display: none; }
.step {
  width: 100%; display: flex; flex-direction: column; align-items: center; gap: 6px;
  padding: 8px 2px 12px; position: relative;
  color: var(--muted); font-size: 0.72rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase;
}
.step::after {
  content: ""; position: absolute; left: 8%; right: 8%; bottom: 0; height: 3px; border-radius: 3px;
  background: var(--line);
}
.step__num {
  display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%;
  border: 1.5px solid var(--line-strong); font-size: 0.85rem;
}
.step.is-done { color: var(--text); }
.step.is-done .step__num { border-color: var(--gold); color: var(--gold); }
.step.is-done::after { background: rgba(201, 154, 82, 0.5); }
.step.is-current { color: var(--gold-light); }
.step.is-current .step__num { background: var(--gold); border-color: var(--gold); color: var(--on-gold); }
.step.is-current::after { background: var(--gold); }
.step:disabled { cursor: default; opacity: 0.55; }
.step__label { text-align: center; line-height: 1.2; }

/* ---------- Cuerpo ---------- */
.booking__body { padding: 22px 16px 24px; min-height: 320px; }
.booking__notice {
  margin-bottom: 16px; padding: 12px 14px; border-radius: var(--radius-sm);
  background: rgba(224, 106, 85, 0.12); border: 1px solid rgba(224, 106, 85, 0.4); color: #f3b3a6; font-weight: 600;
}

.step-head { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 18px; }
.step-head h3 { font-family: var(--font-display); font-weight: 400; font-size: 2.1rem; line-height: 1; outline: none; }
.step-head p { margin-top: 6px; color: var(--muted); font-size: 0.95rem; }
.step-head__back {
  display: grid; place-items: center; flex-shrink: 0;
  width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line-strong); font-size: 1.1rem;
}
.step-head__back:hover { border-color: var(--gold); color: var(--gold); }

/* ---------- Opciones (barbero / servicio) ---------- */
.options { display: grid; gap: 10px; }
.opt {
  width: 100%; display: flex; align-items: center; gap: 14px; text-align: left;
  padding: 14px; border-radius: var(--radius);
  background: var(--bg-2); border: 1.5px solid var(--line);
  transition: border-color 0.2s, background 0.2s, transform 0.15s;
}
.opt:hover { border-color: var(--line-strong); }
.opt:active { transform: scale(0.99); }
.opt.is-selected { border-color: var(--gold); background: var(--gold-soft); }

.opt__avatar {
  width: 58px; height: 58px; border-radius: 50%; overflow: hidden; flex-shrink: 0;
  background: var(--surface-2); border: 2px solid var(--line-strong);
}
.opt__avatar img { width: 100%; height: 100%; object-fit: cover; }
.opt__avatar .foto-respaldo { font-size: 1.4rem; }
.opt__avatar--icon { display: grid; place-items: center; color: var(--gold); font-size: 1.6rem; border-style: dashed; }
.opt__main { display: flex; flex-direction: column; gap: 3px; flex: 1; min-width: 0; }
.opt__title { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; font-weight: 700; font-size: 1.08rem; }
.opt__sub { color: var(--muted); font-size: 0.92rem; line-height: 1.35; }
.opt__meta { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: 0.84rem; font-weight: 600; }
.opt__meta svg { color: var(--gold); }
.opt__check {
  display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; flex-shrink: 0;
  border: 1.5px solid var(--line-strong); color: transparent; font-size: 0.85rem;
}
.opt.is-selected .opt__check { background: var(--gold); border-color: var(--gold); color: var(--on-gold); }
.opt__price { font-family: var(--font-display); font-size: 1.9rem; line-height: 1; color: var(--gold); white-space: nowrap; }
.options--servicios .opt { padding: 16px; }

/* ---------- Días ---------- */
.days-wrap { display: flex; align-items: center; gap: 8px; margin-inline: -16px; }
.days {
  display: flex; gap: 8px; overflow-x: auto; scroll-snap-type: x proximity;
  padding: 4px 16px 10px; scrollbar-width: none; flex: 1; min-width: 0;
}
.days::-webkit-scrollbar { display: none; }
.days-nav { display: none; }
.day {
  scroll-snap-align: start; flex: 0 0 auto;
  width: 70px; padding: 10px 4px 9px; border-radius: var(--radius);
  display: flex; flex-direction: column; align-items: center; gap: 1px;
  background: var(--bg-2); border: 1.5px solid var(--line);
  transition: border-color 0.2s, background 0.2s;
}
.day:hover { border-color: var(--line-strong); }
.day__wd { font-size: 0.72rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.day__num { font-family: var(--font-display); font-size: 2rem; line-height: 1; margin-top: 2px; }
.day__mon { font-size: 0.75rem; color: var(--muted); }
.day__state { margin-top: 5px; font-size: 0.66rem; font-weight: 700; color: var(--ok); white-space: nowrap; }
.day.is-selected { background: var(--gold); border-color: var(--gold); color: var(--on-gold); }
.day.is-selected .day__wd, .day.is-selected .day__mon, .day.is-selected .day__state { color: var(--on-gold); }
.day:disabled { opacity: 0.38; cursor: not-allowed; }
.day:disabled .day__state { color: var(--muted); }

/* ---------- Horarios ---------- */
.slots__date {
  display: flex; align-items: center; gap: 8px; margin: 14px 0 4px;
  font-weight: 700;
}
.slots__date svg { color: var(--gold); }
.slots__group { margin-top: 14px; }
.slots__group h4 {
  margin-bottom: 10px; color: var(--muted);
  font-size: 0.75rem; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase;
}
.slots__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: 8px; }
.slot {
  min-height: 48px; border-radius: var(--radius-sm);
  border: 1.5px solid var(--line-strong); background: var(--bg-2);
  font-weight: 700; font-size: 1rem; font-variant-numeric: tabular-nums;
  transition: border-color 0.2s, background 0.2s, color 0.2s;
}
.slot:hover { border-color: var(--gold); color: var(--gold-light); }
.slot.is-selected { background: var(--gold); border-color: var(--gold); color: var(--on-gold); }
.slot:disabled {
  border-color: var(--line); color: rgba(168, 160, 147, 0.45);
  text-decoration: line-through; cursor: not-allowed; background: transparent;
}
.slots__empty { margin-top: 18px; color: var(--muted); }

/* ---------- Resumen del turno + formulario ---------- */
.recap {
  padding: 4px 16px; border-radius: var(--radius);
  background: var(--bg-2); border: 1px solid var(--line);
}
.recap__row, .recap__total {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  padding: 11px 0; border-bottom: 1px solid var(--line);
}
.recap__row span { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-size: 0.92rem; }
.recap__row span svg { color: var(--gold); }
.recap__row strong { text-align: right; font-weight: 600; }
.recap__total { border-bottom: 0; }
.recap__total span { font-weight: 600; }
.recap__total strong { font-family: var(--font-display); font-size: 1.9rem; font-weight: 400; color: var(--gold); line-height: 1; }

.booking .form { margin-top: 20px; }
.form__policy { color: var(--muted); font-size: 0.88rem; padding-left: 12px; border-left: 2px solid var(--gold); }
.form__submit { min-height: 56px; font-size: 1.05rem; }

/* ---------- Confirmación ---------- */
.done { text-align: center; max-width: 440px; margin-inline: auto; padding-top: 10px; }
.done__icon {
  display: inline-grid; place-items: center; width: 74px; height: 74px; border-radius: 50%;
  background: var(--gold); color: var(--on-gold); font-size: 2.1rem;
  box-shadow: 0 0 0 10px var(--gold-soft);
  animation: pop 0.5s var(--ease) both;
}
@keyframes pop { from { transform: scale(0.4); opacity: 0; } to { transform: none; opacity: 1; } }
.done h3 { margin-top: 22px; font-family: var(--font-display); font-weight: 400; font-size: 2.8rem; line-height: 1; outline: none; }
.done__lead { margin-top: 12px; font-size: 1.08rem; color: rgba(243, 237, 228, 0.88); }
.done__lead strong { color: var(--text); }
.done__code {
  display: inline-block; margin-top: 16px; padding: 8px 16px; border-radius: 999px;
  border: 1px dashed var(--gold); color: var(--muted); font-size: 0.9rem;
}
.done__code strong { color: var(--gold-light); letter-spacing: 0.08em; margin-left: 4px; }
.done__actions { margin-top: 24px; display: grid; gap: 10px; }
.done__link { display: inline-flex; align-items: center; justify-content: center; gap: 6px; color: var(--muted); font-size: 0.9rem; padding: 6px; }
.done__link:hover { color: var(--gold-light); }
.done__policy { margin-top: 18px; color: var(--muted); font-size: 0.88rem; }
.done__again {
  margin-top: 18px; display: inline-flex; align-items: center; gap: 8px;
  color: var(--gold-light); font-weight: 700; padding: 10px;
}

/* ---------- Resumen fijo abajo ---------- */
.booking__summary {
  position: sticky; bottom: 10px; z-index: 5;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin: 0 10px 10px; padding: 12px 14px; border-radius: var(--radius);
  background: rgba(36, 32, 27, 0.96); border: 1px solid var(--line-strong);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}
.summary__items { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 0.88rem; font-weight: 600; min-width: 0; }
.summary__items li { display: inline-flex; align-items: center; gap: 6px; }
.summary__items svg { color: var(--gold); }
.summary__total { display: flex; flex-direction: column; align-items: flex-end; font-family: var(--font-display); font-size: 1.7rem; line-height: 1; color: var(--gold); }
.summary__total span { font-family: var(--font-body); font-size: 0.68rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }

@media (min-width: 760px) {
  .booking__steps { padding: 20px 28px 0; }
  .step { flex-direction: row; justify-content: center; gap: 10px; font-size: 0.8rem; }
  .booking__body { padding: 32px 36px 36px; }
  .step-head h3 { font-size: 2.6rem; }
  .options:not(.options--servicios) { grid-template-columns: repeat(2, 1fr); }
  .opt--any { grid-column: 1 / -1; }
  .days-wrap { margin-inline: 0; }
  .days { padding-inline: 2px; }
  .days-nav {
    display: grid; place-items: center; flex-shrink: 0;
    width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line-strong);
  }
  .days-nav:hover { border-color: var(--gold); color: var(--gold); }
  .booking__summary { margin: 0 20px 20px; }
}
