/* ══════════════════════════════════════════════════
   Rental storefront — built on the shared default.css
   design system (tokens, .sf-offer-card, .sf-filters).
   ══════════════════════════════════════════════════ */

/* ── Hero (shorter than the subscription landing hero) ── */
.variant-rental .sf-hero {
  min-height: clamp(340px, 48vh, 440px);
  align-items: center;
}

.variant-rental .sf-hero__content {
  padding-top: 40px;
  padding-bottom: 40px;
}

.variant-rental .sf-hero__title {
  font-size: clamp(30px, 4vw, 48px);
  max-width: 22ch;
}

/* ── Search strip (hero + catalog share the field styling) ── */
.rental-search {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
  align-items: end;
  width: 100%;
  margin-top: 24px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.97);
  border-radius: 16px;
  box-shadow: 0 12px 40px rgba(8, 14, 20, 0.22);
}

.rental-field {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.rental-field label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--sf-text-faint);
}

.rental-field input,
.rental-field select {
  height: 44px;
  width: 100%;
  padding: 0 12px;
  border: 1px solid #d7dee6;
  border-radius: 10px;
  background: #fff;
  font: inherit;
  font-size: 14px;
  color: var(--sf-text);
}

/* Native-select dropdown arrow so selects match the date inputs */
.rental-field select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 34px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23526373' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
}

.rental-field input:focus,
.rental-field select:focus {
  outline: none;
  border-color: var(--tenant-primary);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--tenant-primary) 22%, transparent);
}

.rental-field--submit { align-self: end; }
.rental-field--submit .sf-btn { width: 100%; height: 44px; }

/* One-way indicator */
.sf-badge--accent { background: var(--tenant-primary); color: #fff; }

.rental-oneway-note {
  margin: 16px 0 0;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.95);
}

.rental-catalog .rental-oneway-note { color: var(--sf-text-muted); }

/* ── Catalog filter bar (replaces the old vertical sidebar) ── */
.rental-catalog { max-width: 1280px; margin: 0 auto; padding: 32px 24px 80px; }

.rental-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 12px;
  margin-top: 20px;
  padding: 16px;
  border-radius: var(--sf-radius);
  background: var(--sf-surface);
  border: 1px solid var(--sf-border);
}

.rental-filters .rental-field { flex: 1 1 160px; }
.rental-filters .rental-field--search { flex: 2 1 220px; }
.rental-filters .rental-field input,
.rental-filters .rental-field select { height: 40px; background: var(--sf-bg); }
.rental-filters .rental-field select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23526373' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
}
.rental-filters__actions { display: flex; gap: 8px; align-self: end; }

/* ── Offer cards (rental specifics on top of .sf-offer-card) ── */
.variant-rental .sf-offer-card,
.rental-catalog .sf-offer-card {
  display: flex;
  flex-direction: column;
}

.variant-rental .sf-offer-card__body,
.rental-catalog .sf-offer-card__body {
  flex: 1;
}

.rental-card__similar {
  font-size: 12px;
  color: var(--sf-text-faint);
  margin-top: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rental-card__foot {
  margin-top: auto;
  padding-top: 14px;
}

.rental-card__pricerow {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.rental-card__from { font-size: 12px; font-weight: 600; color: var(--sf-text-faint); }
.rental-card__deposit { font-size: 12px; color: var(--sf-text-faint); }

.rental-card__book { width: 100%; }

/* ── Booking modal (native <dialog>) ── */
.rental-modal {
  /* margin:auto restores native centering (the global `* { margin:0 }`
     reset would otherwise pin the modal to the top-left corner). */
  margin: auto;
  width: min(460px, 92vw);
  max-height: 88vh;
  border: none;
  border-radius: var(--sf-radius);
  padding: 0;
  background: var(--sf-surface);
  color: var(--sf-text);
  box-shadow: var(--sf-shadow-lg);
}

.rental-modal::backdrop {
  background: rgba(8, 14, 20, 0.55);
  backdrop-filter: blur(2px);
}

.rental-modal__form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 20px;
}

.rental-modal__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.rental-modal__title {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin-top: 2px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.rental-modal__code {
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 6px;
  background: var(--tenant-secondary);
  color: #fff;
}

.rental-modal__close {
  flex: none;
  background: none;
  border: none;
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  color: var(--sf-text-faint);
  padding: 0 4px;
}
.rental-modal__close:hover { color: var(--sf-text); }

.rental-modal__price { font-size: 14px; color: var(--sf-text-muted); }

.rental-extras__included { font-size: 13px; color: var(--sf-text-muted); }

.rental-modal__extras {
  display: flex;
  flex-direction: column;
  gap: 2px;
  max-height: 46vh;
  overflow-y: auto;
  border-top: 1px solid var(--sf-border);
  border-bottom: 1px solid var(--sf-border);
  padding: 8px 0;
}

.rental-modal__extra {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 9px 8px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
}
.rental-modal__extra:hover { background: var(--sf-bg); }
.rental-modal__extra-price { font-size: 12px; color: var(--sf-text-faint); white-space: nowrap; }

.rental-modal__foot {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

/* ── Selected branch details (booking flow) ── */
.rental-location-details {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin: 16px 0 4px;
}

.rental-location-card {
  flex: 1 1 260px;
  border: 1px solid var(--sf-border);
  border-radius: var(--sf-radius);
  padding: 16px 18px;
  background: var(--sf-surface);
  box-shadow: var(--sf-shadow);
}

.rental-location-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
  font-size: 15px;
}

.rental-location-card__meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 13px;
  color: var(--sf-text-muted);
  margin-bottom: 10px;
}

.rental-location-card__hours { width: 100%; border-collapse: collapse; font-size: 12px; }
.rental-location-card__hours th { text-align: left; font-weight: 600; padding: 2px 8px 2px 0; color: var(--sf-text-muted); }
.rental-location-card__hours td { text-align: right; padding: 2px 0; color: var(--sf-text); }
.rental-location-card__hours td.is-closed { color: var(--sf-text-faint); }

/* ── How rental works ── */
.rental-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 24px;
  margin-top: 8px;
}

.rental-step { text-align: center; padding: 8px; }

.rental-step__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--tenant-primary) 14%, transparent);
  color: var(--tenant-primary);
  font-size: 1.1rem;
  font-weight: 800;
  margin-bottom: 12px;
}

.rental-step h3 { font-size: 1.05rem; margin: 0 0 0.4rem; color: var(--sf-text); }
.rental-step p { font-size: 0.9rem; color: var(--sf-text-muted); margin: 0; line-height: 1.5; }

@media (max-width: 768px) {
  .rental-filters .rental-field,
  .rental-filters .rental-field--search { flex: 1 1 100%; }
}
