/* =============================================================================
   DRIMBOT — Tunnel de pré-réservation 2027
   ============================================================================= */

.booking {
  max-width: 880px;
  margin-inline: auto;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
  padding: clamp(1.5rem, 4vw, 2.75rem);
  margin-bottom: var(--section-y);
}

/* ---------------------------------------------------------------------------
   Indicateur d'étapes
--------------------------------------------------------------------------- */
.booking-steps {
  display: flex;
  justify-content: space-between;
  gap: .5rem;
  margin-bottom: 2.2rem;
}
.booking-step {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .5rem;
  position: relative;
  text-align: center;
}
.booking-step:not(:last-child)::after {
  content: '';
  position: absolute;
  top: 16px;
  left: calc(50% + 24px);
  right: calc(-50% + 24px);
  height: 1px;
  background: var(--line-2);
}
.booking-step__dot {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid var(--line-2);
  background: var(--paper);
  display: grid;
  place-items: center;
  font-family: var(--font-mono);
  font-size: .8rem;
  font-weight: 600;
  color: var(--ink-3);
  transition: background var(--t-fast), color var(--t-fast), border-color var(--t-fast);
}
.booking-step.is-active .booking-step__dot {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff;
}
.booking-step.is-done .booking-step__dot {
  background: var(--ok-tint);
  border-color: var(--ok);
  color: var(--ok);
}
.booking-step__label {
  font-size: .75rem;
  font-weight: 600;
  color: var(--ink-3);
}
.booking-step.is-active .booking-step__label { color: var(--ink); }
@media (max-width: 560px) { .booking-step__label { display: none; } }

/* ---------------------------------------------------------------------------
   Étape 1 — segments
--------------------------------------------------------------------------- */
.seg-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: .75rem;
  margin: 1.2rem 0 1.8rem;
}
.seg-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .6rem;
  padding: 1.2rem .8rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  cursor: pointer;
  font-family: var(--font-body);
  font-size: .88rem;
  font-weight: 600;
  color: var(--ink);
  text-align: center;
  transition: border-color var(--t-fast), transform var(--t-fast), box-shadow var(--t-fast);
}
.seg-card:hover { transform: translateY(-2px); border-color: var(--line-2); }
.seg-card.is-selected {
  border-color: var(--ink);
  box-shadow: 0 0 0 1px var(--ink);
  background: var(--surface);
}
.seg-card svg { width: 26px; height: 26px; color: var(--accent); }

/* ---------------------------------------------------------------------------
   Étape 2 — calendrier
--------------------------------------------------------------------------- */
.cal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}
.cal-head__label {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
}
.cal-nav {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid var(--line-2);
  background: var(--surface);
  cursor: pointer;
  font-size: 1rem;
  transition: background var(--t-fast), color var(--t-fast);
}
.cal-nav:hover:not(:disabled) { background: var(--ink); color: #fff; }
.cal-nav:disabled { opacity: .35; cursor: default; }

.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: .3rem;
}
.cal-grid__head {
  font-family: var(--font-mono);
  font-size: .68rem;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-3);
  text-align: center;
  padding-bottom: .4rem;
}
.cal-day {
  aspect-ratio: 1;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--surface);
  font-family: var(--font-mono);
  font-size: .85rem;
  color: var(--ink);
  cursor: pointer;
  transition: background var(--t-fast), color var(--t-fast), border-color var(--t-fast);
}
.cal-day:hover:not(:disabled) { border-color: var(--ink); }
.cal-day.is-booked {
  background: var(--paper);
  color: var(--ink-3);
  text-decoration: line-through;
  text-decoration-color: var(--accent);
  cursor: not-allowed;
}
.cal-day.is-start, .cal-day.is-end {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff;
  font-weight: 600;
}
.cal-day.is-range {
  background: var(--cobalt-tint);
  border-color: color-mix(in srgb, var(--cobalt) 25%, var(--line));
}

.cal-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 1.2rem;
  margin-top: 1rem;
  font-size: .78rem;
  color: var(--ink-2);
}
.cal-legend span { display: inline-flex; align-items: center; gap: .45em; }
.cal-legend i {
  width: 14px;
  height: 14px;
  border-radius: 4px;
  border: 1px solid var(--line-2);
  display: inline-block;
}
.cal-legend .l-free i { background: var(--surface); }
.cal-legend .l-booked i { background: var(--paper); position: relative; }
.cal-legend .l-sel i { background: var(--ink); border-color: var(--ink); }

.booking-datesum {
  margin-top: 1.2rem;
  padding: 1rem 1.2rem;
  border-radius: var(--r-md);
  border: 1px dashed var(--line-2);
  background: var(--paper);
  font-size: .95rem;
  color: var(--ink-2);
}
.booking-datesum.is-set {
  border-style: solid;
  border-color: color-mix(in srgb, var(--ok) 35%, var(--line));
  background: var(--ok-tint);
  color: var(--ink);
}

/* ---------------------------------------------------------------------------
   Étape 3 — récap config + prix
--------------------------------------------------------------------------- */
.booking-recap {
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 1.2rem 1.4rem;
  background: var(--paper);
  margin-bottom: 1.5rem;
}
.booking-recap__row {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 1rem;
  padding: .45rem 0;
  border-bottom: 1px dashed var(--line);
  font-size: .92rem;
}
.booking-recap__row:last-child { border-bottom: 0; }

.booking-total {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding-top: 1rem;
  margin-top: .6rem;
  border-top: 1px solid var(--line);
}
.booking-deposit {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  background: var(--accent-tint);
  border: 1px solid color-mix(in srgb, var(--accent) 30%, var(--line));
  border-radius: var(--r-md);
  padding: .9rem 1.2rem;
  margin-top: 1rem;
}

/* ---------------------------------------------------------------------------
   Navigation + divers
--------------------------------------------------------------------------- */
.booking-nav {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
}

.pay-badges {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  margin-top: 1rem;
  justify-content: center;
}

.booking-success { text-align: center; padding: 1.5rem 0; }
.booking-success__check {
  width: 76px;
  height: 76px;
  margin: 0 auto 1.5rem;
  border-radius: 50%;
  background: var(--ok-tint);
  color: var(--ok);
  font-size: 2rem;
  display: grid;
  place-items: center;
  border: 1px solid color-mix(in srgb, var(--ok) 35%, var(--line));
}
.booking-success .check-list { text-align: left; max-width: 480px; margin: 1.5rem auto; }
