/**
 * booking.css — the two-step booking flow (details → bill, then Razorpay),
 * its step rail, the sticky ceremony summary, the success receipt and the
 * payment-failed screen.
 */

/* ================= STEP RAIL ================= */
.step-rail {
  background: var(--maroon-900);
  color: var(--on-dark);
  border-bottom: 1px solid rgba(224, 163, 37, .28);
}
.step-rail__inner {
  max-width: var(--container-narrow);
  margin-inline: auto;
  padding: 12px var(--gutter);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px clamp(10px, 2vw, 20px);
}
.step-rail__back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  font-weight: 600;
  padding: 9px 15px;
  min-height: 42px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 248, 240, .32);
  background: rgba(255, 248, 240, .06);
  color: var(--on-dark);
  text-decoration: none;
  white-space: nowrap;
  transition: all var(--t-fast);
}
.step-rail__back:hover {
  background: rgba(224, 163, 37, .2);
  border-color: var(--gold);
  color: var(--on-dark);
}
.step-rail__back svg { width: 15px; height: 15px; flex-shrink: 0; }

.step-rail__steps { display: flex; flex-wrap: wrap; align-items: center; gap: 6px clamp(8px, 1.6vw, 16px); }
.step-chip {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 13.5px;
  font-weight: 600;
  padding: 8px 12px;
  min-height: 42px;
  border-radius: var(--radius-pill);
  border: 1px solid transparent;
  background: transparent;
  color: rgba(255, 248, 240, .4);
  cursor: not-allowed;
  white-space: nowrap;
  transition: all var(--t);
}
.step-chip[data-reached="true"] { color: rgba(255, 248, 240, .72); cursor: pointer; }
.step-chip[aria-current="step"] {
  color: var(--on-dark);
  background: rgba(224, 163, 37, .14);
  border-color: rgba(224, 163, 37, .5);
}
.step-chip__n {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  background: transparent;
  color: rgba(255, 248, 240, .6);
  border: 1px solid rgba(255, 248, 240, .3);
  transition: all var(--t-slow);
}
.step-chip[data-past="true"] .step-chip__n { background: rgba(224, 163, 37, .22); color: var(--gold); }
.step-chip[aria-current="step"] .step-chip__n {
  background: var(--gold);
  color: var(--gold-ink);
  border-color: var(--gold);
  box-shadow: 0 0 18px -3px rgba(224, 163, 37, .9);
}

/* ================= LAYOUT ================= */
.booking-main {
  max-width: var(--container-narrow);
  margin-inline: auto;
  padding: clamp(24px, 4vw, 44px) var(--gutter) clamp(48px, 7vw, 80px);
}
.booking-layout {
  display: flex;
  flex-wrap: wrap;
  gap: clamp(18px, 2.6vw, 28px);
  align-items: flex-start;
}
.booking-col {
  flex: 1 1 440px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: clamp(16px, 2.2vw, 22px);
}
.booking-step { display: flex; flex-direction: column; gap: clamp(16px, 2.2vw, 22px); }
.booking-step[hidden] { display: none; }
.booking-step--enter { animation: om-expand var(--t-slow) ease-out both; }

.booking-head h1 {
  margin: 12px 0 8px;
  font-size: clamp(27px, 4.6vw, 38px);
  line-height: 1.1;
  letter-spacing: -0.018em;
}
.booking-head p {
  font-size: clamp(14.5px, 1.7vw, 16px);
  line-height: 1.6;
  color: var(--ink-3);
  max-width: 56ch;
}
.booking-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  font-weight: 600;
  border: none;
  background: transparent;
  color: var(--maroon-600);
  padding: 0;
  cursor: pointer;
  text-decoration: none;
}
.booking-back svg { width: 15px; height: 15px; flex-shrink: 0; }

.booking-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
}
.booking-actions .btn { flex: 1 1 250px; }
.booking-actions__note {
  font-size: 13px;
  color: var(--ink-5);
  line-height: 1.5;
  flex: 1 1 200px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.booking-actions__note svg { width: 15px; height: 15px; flex-shrink: 0; color: var(--green-800); }

/* ================= SLOTS / PRESETS ================= */
.slot-row { margin-top: 14px; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.slot-row__label { font-size: 12.5px; color: var(--ink-5); }

/* ================= MAP ================= */
.pin-head {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.pin-head span {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: var(--ink-4);
}
.pin-map {
  position: relative;
  height: clamp(170px, 26vw, 220px);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line-strong);
  background-color: #eef1e9;
  background-image:
    linear-gradient(rgba(107, 30, 47, .07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(107, 30, 47, .07) 1px, transparent 1px);
  background-size: 34px 34px;
}
.pin-map[data-map-ready="true"] { background-image: none; }
/* The badge lives on a wrapper rather than inside .pin-map, because the
   Google Maps SDK replaces everything inside the container it mounts on. */
.pin-map-wrap { position: relative; }
.pin-map__badge {
  position: absolute;
  left: 12px;
  bottom: 10px;
  z-index: 2;
  font-size: 11.5px;
  font-family: var(--font-mono);
  padding: 5px 9px;
  border-radius: var(--radius-pill);
  background: rgba(255, 253, 248, .9);
  color: var(--ink-3);
  pointer-events: none;
}
.pin-map__status { display: block; margin-top: 8px; font-size: 12.5px; color: var(--green-800); }

/* ================= BILL ================= */
.bill { overflow: hidden; }
.bill__head {
  padding: 16px clamp(18px, 3vw, 26px);
  background: var(--surface-warm);
  border-bottom: 1px solid #ece2cf;
  display: flex;
  align-items: center;
  gap: 10px;
}
.bill__head svg { width: 18px; height: 18px; flex-shrink: 0; color: var(--amber); }
.bill__head strong {
  font-size: 13px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--ink-4);
}
.bill__line {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  justify-content: space-between;
  padding: 15px clamp(18px, 3vw, 26px);
  border-bottom: 1px solid #f3ece0;
}
.bill__line b { display: block; font-size: 15px; font-weight: 600; line-height: 1.35; }
.bill__line small { display: block; margin-top: 4px; font-size: 12.5px; color: var(--ink-5); line-height: 1.5; }
.bill__line .price { font-size: 14.5px; }
.bill__total {
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
  padding: 18px clamp(18px, 3vw, 26px);
  background: var(--maroon-800);
  color: var(--on-dark);
}
.bill__total span {
  font-family: var(--font-display);
  font-size: clamp(18px, 2.4vw, 21px);
  font-weight: 600;
}
.bill__total b {
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: clamp(18px, 2.4vw, 21px);
  color: var(--gold);
  text-shadow: 0 0 18px rgba(224, 163, 37, .6);
}

.summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 14px;
}
.summary-grid span {
  display: block;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--ink-5);
}
.summary-grid strong { display: block; margin-top: 5px; font-size: 14.5px; font-weight: 600; line-height: 1.45; }

/* ================= PAYMENT ================= */
.btn__spinner[hidden] { display: none; }

.gateway-note {
  padding: 14px 16px;
  border-radius: 14px;
  background: var(--green-tint);
  border: 1px solid #b9d5cc;
  color: #22453f;
  font-size: 13.5px;
  line-height: 1.55;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}
.gateway-note svg { width: 17px; height: 17px; flex-shrink: 0; margin-top: 2px; }
.gateway-note[data-mode="mock"] {
  background: var(--gold-wash);
  border-color: var(--line-gold);
  color: #5c3a06;
}

/* Not every payment message is an error — closing checkout is the
   customer's own choice, so those read as a notice instead. */
.form-error[data-tone="notice"] {
  background: var(--gold-wash);
  border-color: var(--line-gold);
  color: #5c3a06;
}

/* ================= STICKY SUMMARY ================= */
.booking-aside {
  flex: 1 1 300px;
  max-width: min(360px, 100%);
  min-width: 0;
  position: sticky;
  top: 20px;
}
.ceremony-card {
  background: var(--maroon-800);
  color: var(--on-dark);
  border: 1px solid rgba(224, 163, 37, .3);
  border-radius: var(--radius-xl);
  padding: clamp(20px, 2.6vw, 26px);
  box-shadow: 0 24px 56px -38px rgba(74, 21, 33, .9);
}
.ceremony-card__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--gold);
}
.ceremony-card__eyebrow svg { width: 13px; height: 13px; flex-shrink: 0; }
.ceremony-card h2 {
  margin: 12px 0 6px;
  font-size: clamp(20px, 2.6vw, 24px);
  line-height: 1.18;
  letter-spacing: -0.012em;
}
.ceremony-card__duration {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  color: rgba(255, 248, 240, .78);
  margin-bottom: 14px;
}
.ceremony-card__duration svg { width: 14px; height: 14px; flex-shrink: 0; }
.ceremony-card__rule { height: 1px; background: rgba(224, 163, 37, .28); margin-bottom: 14px; }
.ceremony-card__line {
  display: flex;
  gap: 12px;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 9px;
  font-size: 13.5px;
  color: rgba(255, 248, 240, .82);
}
.ceremony-card__line b { font-family: var(--font-mono); font-weight: 500; white-space: nowrap; }
.ceremony-card__total {
  display: flex;
  gap: 12px;
  justify-content: space-between;
  align-items: baseline;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(224, 163, 37, .28);
}
.ceremony-card__total strong:first-child { font-size: 14px; }
.ceremony-card__total strong:last-child {
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: 18px;
  color: var(--gold);
  text-shadow: 0 0 16px rgba(224, 163, 37, .55);
}
.ceremony-card__assurances { margin-top: 16px; display: flex; flex-direction: column; gap: 9px; }

.swap-card {
  margin-top: 14px;
  background: var(--surface);
  border: 1px solid #ece2cf;
  border-radius: 18px;
  padding: 18px;
  overflow: hidden;
}
.swap-card label {
  display: block;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--ink-5);
  margin-bottom: 9px;
}
.swap-card select { background: var(--surface-warm); font-size: 14.5px; min-height: 46px; text-overflow: ellipsis; }

/* ================= SUCCESS ================= */
.receipt {
  max-width: 640px;
  margin-inline: auto;
  text-align: center;
  background: var(--surface);
  border: 1px solid #ece2cf;
  border-radius: var(--radius-2xl);
  padding: clamp(30px, 5vw, 52px);
  box-shadow: 0 26px 60px -40px rgba(74, 21, 33, .6);
  animation: om-pop 420ms ease-out both;
}
.receipt__mark {
  width: 66px;
  height: 66px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--green-tint);
  color: var(--green-800);
  box-shadow: 0 0 30px -6px rgba(47, 93, 86, .5);
}
.receipt__mark svg { width: 32px; height: 32px; }
.receipt h1 { margin: 20px 0 10px; font-size: clamp(26px, 4.4vw, 36px); line-height: 1.14; }
.receipt > p {
  margin: 0 auto 22px;
  font-size: clamp(15px, 1.7vw, 16.5px);
  line-height: 1.62;
  color: var(--ink-3);
  max-width: 46ch;
}
.receipt__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
  text-align: left;
  margin-bottom: 26px;
}
.receipt__grid > div {
  padding: 14px 16px;
  border-radius: 14px;
  background: var(--surface-warm);
  border: 1px solid #ece2cf;
}
.receipt__grid span {
  display: block;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--ink-5);
}
.receipt__grid strong { display: block; margin-top: 5px; font-size: 15px; font-weight: 700; line-height: 1.35; }
.receipt__actions { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.receipt__actions .btn { flex: 0 1 auto; }

/* ================= PAYMENT FAILED ================= */
.receipt--failed .receipt__mark {
  background: var(--error-bg);
  color: var(--error);
  box-shadow: 0 0 30px -6px rgba(166, 58, 42, .45);
}
.receipt h1:focus { outline: none; }
.receipt > .receipt__note { font-size: 13.5px; color: var(--ink-4); margin-bottom: 20px; }
.receipt > .form-error { text-align: left; margin: 0 0 16px; max-width: none; }
.receipt > .receipt__help { margin: 20px auto 0; font-size: 13px; color: var(--ink-5); }
.receipt__help a { color: var(--maroon-600); font-weight: 600; }

@media (max-width: 820px) {
  .booking-aside { position: static; max-width: none; order: -1; }
}
