/* ==========================================================================
   Booking request flow. Ivory throughout (neutral environment). One decision
   per step, named progress line (gold = current), small persistent summary.
   Form frame per Cartier restraint: hairlines, generous heights, no boxes
   inside boxes. Loaded after rentals.css (home.css provides .eyebrow, .h2,
   footer pieces).
   ========================================================================== */
.book {
  padding: calc(var(--chrome-inset) + var(--chrome-h) + clamp(28px, 5vw, 64px)) var(--page-gutter) var(--section-pad);
  width: min(100%, var(--content-max));
  margin-inline: auto;
}
.book__open[hidden] { display: none; }
.book__open {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding-bottom: clamp(2rem, 4vw, 3.5rem);
}
.book__title {
  font-size: clamp(2.6rem, 6.4vw, 6rem);
  font-weight: 600;
  font-variation-settings: var(--display-axes);
  line-height: 0.95;
  letter-spacing: -0.025em;
  max-width: 14ch;
}
.book__lead {
  max-width: 44ch;
  font-size: clamp(1.0625rem, 1.3vw, 1.25rem);
  font-weight: 500;
  color: var(--ink-70);
}

/* ---- Progress: a thin line with named steps ------------------------------ */
.progress {
  position: relative;
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  border-top: 1px solid var(--lilac);
  padding-top: 0;
  margin-bottom: clamp(1.5rem, 3vw, 2.5rem);
}
.progress__step { min-width: 0; }
.progress__btn {
  position: relative;
  width: 100%;
  padding: 1rem 0.5rem 0 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.5rem;
  text-align: left;
  color: var(--ink-45);
  cursor: default;
}
.progress__btn:not([disabled]) { cursor: pointer; color: var(--ink); }
.progress__btn::before {                 /* the segment of the line this step owns */
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: -1px;
  height: 2px;
  background: transparent;
  transition: background-color var(--dur-fast) var(--ease-ambient);
}
.progress__step.is-done .progress__btn::before { background: var(--ink); }
.progress__step.is-current .progress__btn::before { background: var(--gold); }
.progress__step.is-current .progress__btn { color: var(--ink); }
.progress__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.35;
}
.progress__step.is-current .progress__dot { background: var(--gold); opacity: 1; }
.progress__step.is-done .progress__dot { opacity: 1; }
.progress__short { display: none; }
.progress__name {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

/* ---- Layout: steps left, summary right --------------------------------- */
.flow__body {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(260px, 3fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: start;
}
.step {
  border: 0;
  padding: 0;
  margin: 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: clamp(1.25rem, 2.4vw, 1.75rem);
}
.step[hidden] { display: none; }
.step.is-active { animation: stepIn 320ms var(--ease-enter); }
@keyframes stepIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}
.step__head { display: flex; flex-direction: column; gap: 0.5rem; }
.step__title:focus, .done__title:focus { outline: none; }   /* focus moved by script for screen readers; no ring */
.step__title {
  font-size: clamp(1.75rem, 3vw, 2.6rem);
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.05;
}
.step__lead { color: var(--ink-70); }
.step__note { font-size: 0.875rem; }
.step__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  padding-top: 0.5rem;
}
.btn--lg { min-height: 56px; padding: 1rem 2rem; font-size: 1rem; }
.btn--send { min-width: 220px; }

/* ---- Fields: labels always visible, 48px inputs, hairline borders --------- */
.fields { display: grid; gap: 1rem clamp(1rem, 2vw, 1.5rem); }
.fields--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.fields--3 { grid-template-columns: minmax(0, 2fr) minmax(0, 2fr) minmax(0, 1fr); }
.field { display: flex; flex-direction: column; gap: 0.45rem; min-width: 0; }
.field__label {
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}
.field__opt { font-weight: 500; color: var(--ink-45); margin-left: 0.35rem; }
.field__input {
  width: 100%;
  min-height: 48px;
  padding: 0.6rem 0.9rem;
  border: 1.5px solid var(--lilac);
  border-radius: var(--radius-btn);
  background: rgba(251, 244, 223, 0.6);
  color: var(--ink);
  font: inherit;
  font-size: 1rem;
  transition: border-color var(--dur-fast) var(--ease-ambient);
}
.field__input::placeholder { color: var(--ink-45); }
.field__input:hover { border-color: var(--ink-45); }
.field__input:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 3px rgba(184, 148, 77, 0.35); }
.field__input--area { resize: vertical; min-height: 96px; line-height: 1.5; }
select.field__input {
  appearance: none;
  padding-right: 2.5rem;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'><path d='M2 4l4 4 4-4' fill='none' stroke='%2316161F' stroke-width='1.5'/></svg>");
  background-repeat: no-repeat;
  background-position: right 0.9rem center;
}
.field.is-invalid .field__input { border-color: var(--ink); }
.field.is-valid .field__input { border-color: var(--forest); }
.field__error {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--ink);
}
.field__error[hidden] { display: none; }
.no-js-only { display: none; }
.no-js .no-js-only { display: flex; }
.no-js .cal__bar, .no-js .cal__grid { display: none; }

/* ---- Calendar: a big, typographic month --------------------------------- */
.cal { display: flex; flex-direction: column; gap: 0.75rem; }
.cal__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.cal__month {
  font-family: var(--font-display);
  font-variation-settings: var(--display-axes);
  font-size: clamp(1.5rem, 2.4vw, 2rem);
  font-weight: 600;
  letter-spacing: -0.01em;
}
.cal__nav {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 1.5px solid var(--ink);
  border-radius: var(--radius-btn);
  transition: background-color var(--dur-fast) var(--ease-ambient), border-color var(--dur-fast) var(--ease-ambient);
}
.cal__nav:hover { background: var(--gold); border-color: var(--gold); }
.cal__nav[disabled] { opacity: 0.3; pointer-events: none; }
.cal__grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
}
.cal__row { display: contents; }   /* role="row" wrapper: the weeks stay on the 7-column grid */
.cal__dow {
  padding: 0.5rem 0;
  text-align: center;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-45);
}
.cal__day {
  min-height: clamp(48px, 6vw, 76px);
  display: grid;
  place-items: center;
  font-size: clamp(0.9375rem, 1.2vw, 1.0625rem);
  font-weight: 600;
  border-radius: var(--radius-btn);
  border: 1.5px solid transparent;
  transition: background-color var(--dur-fast) var(--ease-ambient), border-color var(--dur-fast) var(--ease-ambient), color var(--dur-fast) var(--ease-ambient);
}
.cal__day:hover:not([disabled]) { background: var(--deep-ivory); }
.cal__day:focus-visible { outline: 2px solid var(--gold); outline-offset: 0; }
.cal__day[disabled] { color: var(--ink-45); opacity: 0.45; cursor: default; }
.cal__day.is-today { border-color: var(--lilac); }
.cal__day[aria-selected="true"] { background: var(--ink); color: var(--ivory); border-color: var(--ink); }
.cal__day.is-empty { visibility: hidden; }

/* ---- Zone check ----------------------------------------------------------- */
.zone { font-size: 0.9375rem; font-weight: 600; color: var(--forest); }
.zone.is-outside { color: var(--ink); }
.zone[hidden] { display: none; }

/* ---- Rental picker -------------------------------------------------------- */
.chosen { display: flex; flex-direction: column; gap: 0.75rem; }
.chosen[hidden] { display: none; }
.chosen__title, .pick-group__title {
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
}
.chosen__list { display: flex; flex-direction: column; border-top: 1px solid var(--lilac); }
.chosen__item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--lilac);
}
.chosen__name { flex: 1; font-weight: 600; }
.chosen__meta { font-size: 0.875rem; color: var(--ink-70); }
.chosen__price { font-weight: 600; white-space: nowrap; }
.chosen__remove {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border: 1.5px solid var(--ink);
  border-radius: var(--radius-btn);
}
.chosen__remove:hover { background: var(--gold); border-color: var(--gold); }
.qty { display: inline-flex; align-items: center; border: 1.5px solid var(--ink); border-radius: var(--radius-btn); }
.qty button { width: 32px; height: 32px; display: grid; place-items: center; }
.qty button:hover { background: var(--gold); }
.qty output { min-width: 28px; text-align: center; font-weight: 700; font-size: 0.9375rem; }

.picker { display: flex; flex-direction: column; gap: clamp(1.25rem, 2.4vw, 2rem); }
.pick-group { display: flex; flex-direction: column; gap: 0.5rem; }
.pick-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.5rem 1.5rem; }
.pick {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(192, 180, 204, 0.55);
  min-width: 0;
}
.pick__thumb {
  position: relative;
  flex: 0 0 64px;
  width: 64px;
  aspect-ratio: 1 / 1;                     /* thumbnails are squares */
  overflow: hidden;
  background: var(--deep-ivory);
}
.pick__thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: var(--pos, 50% 50%); }
.pick__info { flex: 1; display: flex; flex-direction: column; gap: 0.1rem; min-width: 0; }
.pick__name { font-size: 0.9375rem; font-weight: 600; }
.pick__price { font-size: 0.8125rem; color: var(--ink-70); }
.pick__add {
  position: relative;
  min-width: 40px;
  height: 40px;
  padding: 0 0.6rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  border: 1.5px solid var(--ink);
  border-radius: var(--radius-btn);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  transition: background-color var(--dur-fast) var(--ease-ambient), color var(--dur-fast) var(--ease-ambient);
}
.pick__add svg { width: 14px; height: 14px; }
.pick__add .pick__added { display: none; }
.pick__add:hover { background: var(--gold); border-color: var(--gold); }
.pick__add[aria-pressed="true"] { background: var(--forest); border-color: var(--forest); color: var(--ivory); }
.pick__add[aria-pressed="true"] svg { display: none; }
.pick__add[aria-pressed="true"] .pick__added { display: inline; }

/* ---- Review --------------------------------------------------------------- */
.rv { display: flex; flex-direction: column; margin: 0; border-top: 1px solid var(--lilac); }
.rv__row {
  display: grid;
  grid-template-columns: 9rem minmax(0, 1fr) auto;
  gap: 0.5rem 1.5rem;
  padding: 1rem 0;
  border-bottom: 1px solid var(--lilac);
  align-items: start;
}
.rv__row dt { font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-70); padding-top: 0.15rem; }
.rv__row dd { margin: 0; line-height: 1.5; }
.rv__row dd ul { display: flex; flex-direction: column; gap: 0.2rem; }
.rv__edit .link { padding: 0; }
.rv__row--total dd:first-of-type { font-family: var(--font-display); font-variation-settings: var(--display-axes); font-size: 1.75rem; font-weight: 600; line-height: 1; }
.rv__note { font-size: 0.875rem; color: var(--ink-70); align-self: center; }

.check { display: flex; align-items: flex-start; gap: 0.875rem; cursor: pointer; max-width: 60ch; }
.check input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.check__box {
  flex: 0 0 24px;
  width: 24px;
  height: 24px;
  margin-top: 0.1rem;
  display: grid;
  place-items: center;
  border: 1.5px solid var(--ink);
  border-radius: var(--radius-btn);
  color: var(--ivory);
  background: transparent;
}
.check__box svg { width: 14px; height: 14px; }
.check input:checked + .check__box { background: var(--forest); border-color: var(--forest); }
.check input:focus-visible + .check__box { outline: 2px solid var(--gold); outline-offset: 2px; }
.check__text { font-size: 0.9375rem; line-height: 1.5; }

/* ---- Summary panel -------------------------------------------------------- */
.summary { position: sticky; top: calc(var(--chrome-inset) + var(--chrome-h) + 16px); }
.summary__sheet { border-top: 2px solid var(--ink); padding-top: 1rem; }
.summary__toggle { list-style: none; display: flex; flex-direction: column; gap: 0.25rem; cursor: default; pointer-events: none; }
.summary__toggle::-webkit-details-marker { display: none; }
.summary__brief { display: none; }
.summary__list { display: flex; flex-direction: column; margin-top: 1rem; }
.summary__list > div { display: flex; flex-direction: column; gap: 0.2rem; padding: 0.75rem 0; border-bottom: 1px solid var(--lilac); }
.summary__list dt { font-size: 0.75rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-45); }
.summary__list dd { margin: 0; font-weight: 600; line-height: 1.4; }
.summary__list dd.is-empty { font-weight: 500; color: var(--ink-45); }
.summary__list dd ul { display: flex; flex-direction: column; gap: 0.15rem; }
.summary__total dd { font-family: var(--font-display); font-variation-settings: var(--display-axes); font-size: 1.75rem; font-weight: 600; line-height: 1; }
.summary__note { margin-top: 0.75rem; font-size: 0.8125rem; color: var(--ink-70); }

/* ---- Confirmation --------------------------------------------------------- */
.done[hidden] { display: none; }
.done__card {
  position: relative;
  width: min(100%, 720px);
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  padding: clamp(2rem, 4vw, 3.5rem) 0 clamp(3rem, 6vw, 5rem);
  border-top: 2px solid var(--ink);
}
.done__title {
  font-size: clamp(2.4rem, 5.4vw, 4.8rem);
  font-weight: 600;
  font-variation-settings: var(--display-axes);
  line-height: 0.98;
  letter-spacing: -0.02em;
  max-width: 12ch;
}
.done__lead { font-size: clamp(1.0625rem, 1.3vw, 1.25rem); font-weight: 500; max-width: 46ch; }
.done__summary { display: flex; flex-direction: column; border-top: 1px solid var(--lilac); margin-top: 0.5rem; }
.done__summary > div { display: grid; grid-template-columns: 9rem minmax(0, 1fr); gap: 1rem; padding: 0.75rem 0; border-bottom: 1px solid var(--lilac); }
.done__summary dt { font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-70); }
.done__summary dd { margin: 0; font-weight: 600; }
.done__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.5rem; padding-top: 0.5rem; }
.done__dog {
  position: absolute;
  right: 0;
  top: 0;
  width: 118px;                             /* Rule 17: small, one corner, leaping over the card's top rule */
  transform: translateY(-58%);
  pointer-events: none;
}
.done__dog img { width: 100%; height: auto; }

/* ---- Minimal footer ------------------------------------------------------- */
.footer--min {
  border-top: 1px solid var(--lilac);
  color: var(--ink);
  padding: 2rem var(--page-gutter) 2.5rem;
  gap: 1rem;
}
.footer--min .footer__meta { color: var(--ink-70); }
.footer--min .footer__meta a, .footer--min .link { color: var(--ink); }
.footer--min .footer__legal { color: var(--ink-70); }
.footer--min .footer__legal a { color: var(--ink); }

/* ---- Responsive ----------------------------------------------------------- */
@media (max-width: 1023px) {
  .flow__body { grid-template-columns: minmax(0, 1fr); gap: 1.5rem; }
  .summary { order: -1; position: sticky; top: calc(var(--chrome-inset) + var(--chrome-h) + 8px); z-index: 5; background: var(--ivory); }
  .summary__sheet { border-top: 0; border-bottom: 1px solid var(--lilac); padding: 0.5rem 0; }
  .summary__toggle { flex-direction: row; align-items: baseline; justify-content: space-between; gap: 1rem; cursor: pointer; min-height: 44px; pointer-events: auto; }
  .summary__brief { display: block; font-size: 0.875rem; font-weight: 600; text-align: right; }
  .summary__list { margin-top: 0.5rem; }
  .summary__sheet:not([open]) .summary__list, .summary__sheet:not([open]) .summary__note { display: none; }
  .pick-list { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 767px) {
  .fields--2, .fields--3 { grid-template-columns: minmax(0, 1fr); }   /* one field per row */
  .progress { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .progress__name { font-size: 0.6875rem; letter-spacing: 0.04em; }
  .progress__long { display: none; }
  .progress__short { display: inline; }
  .progress__btn { padding-right: 0.25rem; }
  .rv__row { grid-template-columns: minmax(0, 1fr) auto; }
  .rv__row dt { grid-column: 1 / -1; }
  .done__summary > div { grid-template-columns: minmax(0, 1fr); gap: 0.25rem; }
  .done__dog { width: 96px; transform: translateY(-62%); }
  .step__actions .btn { flex: 1 1 auto; }
}
@media (prefers-reduced-motion: reduce) {
  .step.is-active { animation: none; }
  .field__input, .cal__day, .cal__nav, .pick__add, .progress__btn::before { transition: none; }
}


/* ---- Availability (placeholder data until the live calendar is wired) ----- */
.avail { display: flex; flex-direction: column; gap: 1.25rem; border-top: 1px solid var(--lilac); padding-top: 1.25rem; }
.avail[hidden] { display: none; }
.avail__item {                              /* same tile size as the alternatives below */
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  width: calc((100% - 2.5rem) / 3);
  min-width: 0;
}
.avail__thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: var(--deep-ivory);
}
.avail__thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: var(--pos, 50% 50%); }
.avail__info { display: flex; flex-direction: column; gap: 0.3rem; min-width: 0; }
.avail__name { font-family: var(--font-display); font-variation-settings: var(--display-axes); font-size: clamp(1.25rem, 1.8vw, 1.5rem); font-weight: 600; letter-spacing: -0.01em; line-height: 1.05; }
.avail__status { display: inline-flex; align-items: flex-start; gap: 0.45rem; font-weight: 600; color: var(--forest); line-height: 1.35; }
.avail__status svg { margin-top: 0.2em; }
.avail__status svg { width: 16px; height: 16px; flex: none; }
/* booked: greyed out and struck through */
.is-booked .avail__thumb img, .pick.is-booked .pick__thumb img, .alt.is-booked img { filter: grayscale(1); opacity: 0.45; }
.is-booked .avail__name, .pick.is-booked .pick__name, .chosen__item.is-booked .chosen__name { text-decoration: line-through; text-decoration-thickness: 2px; text-decoration-color: var(--ink); color: var(--ink-45); }
.is-booked .avail__status { color: var(--ink-70); }
.avail__alts { display: flex; flex-direction: column; gap: 0.75rem; }
.avail__alts[hidden] { display: none; }
.avail__alts-title, .avail__hint { font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--gold); }
.avail__hint { color: var(--ink-45); font-weight: 600; letter-spacing: 0.04em; text-transform: none; font-size: 0.875rem; }
.alts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem 1.25rem; }
.alt { display: flex; flex-direction: column; gap: 0.5rem; min-width: 0; }
.alt__thumb { position: relative; aspect-ratio: 1 / 1; overflow: hidden; background: var(--deep-ivory); }   /* squares */
.alt__thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: var(--pos, 50% 50%); }
.alt__name { font-size: 0.9375rem; font-weight: 600; }
.alt__price { font-size: 0.8125rem; color: var(--ink-70); }
.alt .btn { align-self: flex-start; margin-top: 0.25rem; }

/* picker items booked on the chosen date */
.pick.is-booked .pick__add { opacity: 0.35; pointer-events: none; }
.pick.is-booked .pick__price { color: var(--ink-45); }
.chosen__item.is-booked .chosen__price { text-decoration: line-through; color: var(--ink-45); }
.chosen__flag { font-size: 0.8125rem; font-weight: 600; color: var(--ink); }

/* calendar: days the chosen product is booked (still clickable, so the alternatives show) */
.cal__day.is-booked { color: var(--ink-45); text-decoration: line-through; text-decoration-thickness: 2px; }
.cal__day.is-booked[aria-selected="true"] { color: var(--ivory); }

@media (max-width: 767px) {
  .alts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .avail__item { width: calc((100% - 1rem) / 2); }
}

/* Fix 2026-10-15: the quiet character counter on the notes boxes, and the length-vs-times notice on the time step. */
.field__count { margin: 4px 0 0; font-size: 0.75rem; color: rgba(22, 22, 31, 0.6); text-align: right; }
.field__count[hidden] { display: none; }
.length-warn { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; margin: 12px 0 0; }
.length-warn[hidden] { display: none; }
.length-warn .field__error { margin: 0; flex: 1 1 240px; }
.length-warn .btn { white-space: nowrap; }
@media (max-width: 767px) { .length-warn { justify-content: center; text-align: center; } .length-warn .field__error { flex-basis: 100%; } }
