/* ============================================================
   M5 RENTALS — booking section (lives inside index.html as #book)
   Palette and type inherited from the site: deep navy, white,
   Cormorant Garamond headings, Manrope body. No new colors.
   Every class is bk- prefixed so nothing collides with the page.
   ============================================================ */

#book { scroll-margin-top: 96px; }
#book .bk-head { text-align: center; }
#book .bk-head .lead { margin: 0 auto; }

#book .bk-shell { max-width: 720px; margin: 34px auto 0; }

/* ---------- progress ---------- */
#book .bk-progress { margin: 0 0 14px; }
#book .bk-bar { height: 5px; background: rgba(255,255,255,.16); border-radius: 999px; overflow: hidden; }
#book .bk-fill { height: 100%; width: 20%; background: var(--white); border-radius: 999px; transition: width .35s ease; }
#book .bk-steplbl { color: var(--dim); font-size: .85rem; margin-top: 9px; letter-spacing: .04em; text-transform: uppercase; font-weight: 700; }

/* ---------- card ---------- */
#book .bk-card { background: var(--white); color: #0f1b33; border-radius: 16px; padding: 32px 30px 26px; }
@media (max-width: 560px) { #book .bk-card { padding: 24px 18px 20px; } }

/* the page gives every <section> 72px of padding — the step panes opt out */
#book .bk-step { display: none; padding: 0; border: 0; }
#book .bk-step.bk-on { display: block; animation: bkfade .25s ease both; }
@keyframes bkfade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { #book .bk-step.bk-on { animation: none; } }

#book .bk-step h3 { font-family: var(--serif); font-weight: 600; font-size: 1.9rem; line-height: 1.15; color: var(--navy); margin: 0 0 .15em; }
#book .bk-sub { color: #5b6573; font-size: .97rem; margin: 0 0 22px; }

/* ---------- fields ---------- */
#book .bk-field { display: block; margin-bottom: 20px; }
#book .bk-lbl { display: block; font-weight: 700; color: var(--navy); margin-bottom: 7px; font-size: .97rem; }
#book .bk-req { color: #b42318; }
#book .bk-row { display: flex; gap: 14px; }
#book .bk-row .bk-field { flex: 1; }
@media (max-width: 560px) { #book .bk-row { flex-direction: column; gap: 0; } }

#book input[type=text], #book input[type=email], #book input[type=tel], #book select {
  width: 100%; padding: 13px 14px; font: inherit; font-size: 1rem; color: #0f1b33;
  border: 1.5px solid #cfd6e4; border-radius: 10px; background: #fff;
  appearance: none; -webkit-appearance: none;
}
#book select {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23012359' stroke-width='2.4'><path d='M6 9l6 6 6-6'/></svg>");
  background-repeat: no-repeat; background-position: right 14px center; padding-right: 40px;
}
#book input:focus, #book select:focus { border-color: var(--navy); outline: none; box-shadow: 0 0 0 3px rgba(1,35,89,.12); }
#book input::placeholder { color: #98a3b5; }

#book .bk-err { display: block; color: #b42318; font-size: .85rem; margin-top: 6px; font-weight: 600; }
#book .bk-field.bk-bad input, #book .bk-field.bk-bad select, #book .bk-field.bk-bad .bk-calbtn { border-color: #b42318; }
#book .bk-note { background: #eef3fb; border: 1px solid #d3e0f3; border-radius: 10px; padding: 12px 14px; font-size: .9rem; color: #1d3a68; margin-top: 10px; }
#book .bk-hide { display: none !important; }

/* ---------- street address suggestions ---------- */
#book .bk-ac-wrap { position: relative; }
#book .bk-ac {
  position: absolute; z-index: 45; left: 0; right: 0; top: 100%; margin-top: 6px;
  background: #fff; border: 1.5px solid #dbe2ee; border-radius: 12px;
  box-shadow: 0 18px 48px rgba(1,12,35,.22); overflow: hidden;
}
#book .bk-ac[hidden] { display: none; }
#book .bk-ac-opt {
  display: block; padding: 11px 14px; cursor: pointer; color: #0f1b33;
  border-bottom: 1px solid #eef1f6; min-height: 48px;
}
#book .bk-ac-opt:hover, #book .bk-ac-opt[aria-selected="true"] { background: #eef3fb; }
#book .bk-ac-main { display: block; font-weight: 700; }
#book .bk-ac-sub { display: block; font-size: .86rem; color: #5b6579; }
#book .bk-ac-attr { padding: 6px 14px; text-align: right; font-size: .72rem; color: #5b6579; letter-spacing: .02em; }

/* ---------- vehicle tiles ---------- */
#book .bk-tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
@media (max-width: 560px) { #book .bk-tiles { grid-template-columns: 1fr; } }
#book .bk-tile { position: relative; display: block; cursor: pointer; }
#book .bk-tile input { position: absolute; opacity: 0; width: 0; height: 0; }
#book .bk-tile .bk-tilebox {
  border: 1.5px solid #cfd6e4; border-radius: 12px; overflow: hidden; text-align: center;
  transition: border-color .15s, background .15s, box-shadow .15s; height: 100%;
  display: flex; flex-direction: column;
}
#book .bk-tile:hover .bk-tilebox { border-color: var(--navy-mid); }
#book .bk-tile input:focus-visible + .bk-tilebox { box-shadow: 0 0 0 3px rgba(1,35,89,.18); }
#book .bk-tile input:checked + .bk-tilebox { border-color: var(--navy); background: #f2f6fd; box-shadow: inset 0 0 0 1px var(--navy); }
#book .bk-tile .bk-tilephoto { aspect-ratio: 4 / 3; background: #eceef2; }
#book .bk-tile .bk-tilephoto img { width: 100%; height: 100%; object-fit: cover; display: block; }
#book .bk-tile .bk-tiletext { padding: 12px 10px 14px; }
#book .bk-tile .bk-tilename { display: block; font-weight: 700; font-size: 1rem; color: var(--navy); line-height: 1.25; }
#book .bk-tile .bk-tilesub { display: block; font-size: .82rem; color: #5b6573; margin-top: 3px; }
@media (max-width: 560px) { #book .bk-tile .bk-tilephoto { aspect-ratio: 16 / 9; } }

/* ---------- calendar ---------- */
#book .bk-cal { position: relative; }
#book .bk-calbtn {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 15px 16px; font: inherit; font-size: 1.05rem; font-weight: 600; text-align: left;
  color: #0f1b33; background: #fff; border: 1.5px solid #cfd6e4; border-radius: 12px; cursor: pointer;
}
#book .bk-calbtn:hover { border-color: var(--navy-mid); }
#book .bk-calbtn[aria-expanded="true"] { border-color: var(--navy); box-shadow: 0 0 0 3px rgba(1,35,89,.12); }
#book .bk-calbtn .bk-calval.bk-empty { color: #98a3b5; font-weight: 500; }
#book .bk-calbtn svg { width: 22px; height: 22px; flex: none; color: var(--navy); }

#book .bk-panel {
  position: absolute; z-index: 40; top: calc(100% + 8px); left: 0;
  width: 340px; max-width: calc(100vw - 44px);
  border: 1.5px solid #dbe2ee; border-radius: 14px; background: #fff;
  padding: 16px 14px 14px; box-shadow: 0 18px 48px rgba(1,12,35,.26);
}
#book .bk-panel.bk-flip { left: auto; right: 0; }
#book .bk-panel[hidden] { display: none; }
#book .bk-calnav { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
#book .bk-calnav button {
  width: 42px; height: 42px; flex: none; border-radius: 10px; border: 1.5px solid #cfd6e4;
  background: #fff; color: var(--navy); font-size: 1.1rem; cursor: pointer; font-family: var(--sans); line-height: 1;
}
#book .bk-calnav button:hover:not(:disabled) { border-color: var(--navy); background: #f2f6fd; }
#book .bk-calnav button:disabled { opacity: .35; cursor: default; }
#book .bk-calsel { display: flex; gap: 8px; flex: 1; min-width: 0; }
#book .bk-calsel select { font-weight: 700; color: var(--navy); padding: 10px 6px; font-size: .88rem;
  background-position: right 6px center; padding-right: 22px; min-width: 0; text-overflow: ellipsis; }
#book .bk-calsel select[data-sel="m"] { flex: 2; }
#book .bk-calsel select[data-sel="y"] { flex: 1; min-width: 64px; }

/* minmax(0,1fr) matters: a plain 1fr track can't shrink below the day
   button's min-content width, so the seven columns pushed wider than the
   panel and the numbers drifted out of the box, row by row. */
#book .bk-dow { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; margin-bottom: 6px; }
#book .bk-dow span { text-align: center; font-size: .75rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: #8792a5; padding: 6px 0; }
#book .bk-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
#book .bk-day {
  aspect-ratio: 1 / 1; min-width: 0; min-height: 40px; border: 0; background: transparent; border-radius: 10px;
  font: inherit; font-size: 1rem; font-weight: 600; color: #0f1b33; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}
#book .bk-day:hover:not(:disabled) { background: #eef3fb; }
#book .bk-day:disabled { color: #c4ccd9; cursor: default; }
#book .bk-day.bk-empty { visibility: hidden; }
#book .bk-day.bk-today { box-shadow: inset 0 0 0 1.5px #cfd6e4; }
#book .bk-day.bk-sel { background: var(--navy); color: #fff; box-shadow: none; }
#book .bk-day.bk-sel:hover { background: var(--navy-mid); }
@media (max-width: 400px) { #book .bk-day { min-height: 36px; font-size: .95rem; } }

/* ---------- uploads ---------- */
#book .bk-drop {
  border: 1.6px dashed #cfd6e4; border-radius: 12px; padding: 22px 16px; text-align: center;
  cursor: pointer; background: #fafbfe; transition: border-color .15s, background .15s;
}
#book .bk-drop:hover { border-color: var(--navy); background: #f2f6fd; }
#book .bk-drop svg { width: 26px; height: 26px; color: var(--navy); }
#book .bk-drop .bk-cap { display: block; font-size: .9rem; color: #5b6573; margin-top: 8px; }
#book .bk-drop input[type=file] { display: none; }
#book .bk-file { display: none; align-items: center; gap: 10px; margin-top: 10px; font-size: .92rem;
  background: #eef3fb; border-radius: 10px; padding: 11px 13px; color: #0f1b33; }
#book .bk-file.bk-show { display: flex; }
#book .bk-file .bk-x { margin-left: auto; color: #5b6573; cursor: pointer; font-weight: 800; padding: 0 4px; }

/* ---------- checkbox ---------- */
#book .bk-check { display: flex; align-items: flex-start; gap: 11px; font-size: .9rem; color: #0f1b33;
  background: #f4f7fc; border-radius: 10px; padding: 14px; cursor: pointer; margin-top: 4px; }
#book .bk-check input { width: 19px; height: 19px; accent-color: var(--navy); flex: none; margin-top: 1px; }
#book .bk-checks { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 16px; margin-top: 4px; }
@media (max-width: 480px) { #book .bk-checks { grid-template-columns: 1fr; } }
#book .bk-cbx { display: flex; align-items: center; gap: 10px; font-size: .95rem; cursor: pointer; padding: 5px 0; }
#book .bk-cbx input { width: 19px; height: 19px; accent-color: var(--navy); flex: none; }

/* ---------- nav buttons ---------- */
#book .bk-nav { display: flex; gap: 12px; margin-top: 26px; }
#book .bk-btn {
  font: inherit; font-weight: 800; font-size: 1rem; border-radius: 999px; padding: .95rem 1.6rem;
  cursor: pointer; border: 2px solid transparent; line-height: 1.2; transition: background-color .15s, border-color .15s;
}
#book .bk-btn:active { transform: translateY(1px); }
#book .bk-primary { background: var(--navy); color: #fff; border-color: var(--navy); flex: 1; }
#book .bk-primary:hover { background: var(--navy-mid); border-color: var(--navy-mid); }
#book .bk-primary:disabled { opacity: .6; cursor: default; }
#book .bk-back { background: #fff; color: var(--navy); border-color: #cfd6e4; }
#book .bk-back:hover { border-color: var(--navy); }

#book .bk-legal { font-size: .82rem; color: #5b6573; margin: 16px 0 0; text-align: center; }
#book .bk-legal a { color: var(--navy); }

/* ---------- success ---------- */
#book .bk-done { display: none; text-align: center; padding: 16px 6px 10px; }
#book .bk-done.bk-show { display: block; animation: bkfade .3s ease both; }
#book .bk-done .bk-mark { width: 62px; height: 62px; border-radius: 50%; background: rgba(1,35,89,.08);
  color: var(--navy); display: flex; align-items: center; justify-content: center; font-size: 30px; margin: 0 auto 16px; }
#book .bk-done h3 { font-family: var(--serif); font-weight: 600; font-size: 1.9rem; color: var(--navy); margin: 0 0 .3em; }
#book .bk-done p { color: #5b6573; margin: 0 auto 22px; max-width: 40ch; }

/* honeypot */
#book .bk-hp { position: absolute; left: -9999px; top: -9999px; height: 0; width: 0; overflow: hidden; }
