/* Homepage booking widget — isolated from legacy .calender / .input styles */

.home-booking-section {
  position: relative;
  z-index: 100;
  margin-top: -40px;
  padding: 0 0 52px;
  background: transparent;
}

.home-booking-section__inner {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Kill legacy form flex from .calender form if any parent still matches */
.home-booking-section .home-booking-form {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0;
}

.home-booking-bar {
  display: grid;
  grid-template-columns:
    minmax(0, 1.15fr)
    1px
    minmax(0, 1fr)
    1px
    minmax(0, 1fr)
    1px
    minmax(0, 1fr)
    auto;
  align-items: stretch;
  width: 100%;
  background: #fff;
  border-radius: 16px;
  border: 1px solid rgba(54, 81, 64, 0.12);
  box-shadow:
    0 18px 50px rgba(54, 81, 64, 0.12),
    0 4px 14px rgba(0, 0, 0, 0.05);
  overflow: visible;
  isolation: isolate;
}

.home-booking-field--guests {
  z-index: 2;
}

.home-booking-field--guests.is-dropdown-open {
  z-index: 250;
}

.home-booking-field {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  padding: 18px 22px;
  position: relative;
  background: #fff;
  transition: background 0.2s ease;
}

.home-booking-field:hover,
.home-booking-field:focus-within {
  background: #f8f6f2;
}

.home-booking-field.is-invalid {
  background: #fff8f6;
  box-shadow: inset 0 0 0 2px rgba(209, 109, 86, 0.35);
}

.home-booking-field__label {
  display: block;
  font-family: "Raleway", sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #365140;
  margin: 0 0 8px;
  line-height: 1;
}

.home-booking-field__input,
.home-booking-field__trigger {
  display: block;
  width: 100%;
  max-width: 100%;
  border: none;
  background: transparent;
  padding: 0;
  margin: 0;
  font-family: "Raleway", sans-serif;
  font-size: 15px;
  font-weight: 500;
  color: #1c1c1c;
  letter-spacing: 0;
  text-transform: none;
  text-align: left;
  cursor: pointer;
  outline: none;
  height: 22px;
  line-height: 22px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  box-sizing: border-box;
}

.home-booking-field__trigger {
  appearance: none;
  -webkit-appearance: none;
}

.home-booking-field__input::placeholder {
  color: #9a9a9a;
  font-weight: 400;
}

.home-booking-field__text.is-placeholder {
  color: #9a9a9a;
  font-weight: 400;
}

.home-booking-field__text:not(.is-placeholder) {
  color: #1c1c1c;
  font-weight: 500;
}

.home-booking-divider {
  width: 1px;
  background: rgba(54, 81, 64, 0.14);
  align-self: stretch;
  margin: 14px 0;
}

.home-booking-submit {
  grid-column: -1;
  align-self: center;
  justify-self: stretch;
  margin: 10px 12px 10px 8px;
  padding: 0 28px;
  min-width: 170px;
  height: 52px;
  border: none;
  border-radius: 12px;
  background-color: #d16d56;
  color: #fff;
  font-family: "Raleway", sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(209, 109, 86, 0.38);
  transition: background 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
}

.home-booking-submit:hover {
  background-color: #c05f49;
  transform: translateY(-1px);
  box-shadow: 0 6px 22px rgba(209, 109, 86, 0.45);
}

/* Guest dropdown */
.home-booking-guest-wrap {
  position: relative;
}

.home-guest-dropdown {
  display: none;
  position: absolute;
  left: 0;
  right: auto;
  top: 100%;
  margin-top: 10px;
  width: min(300px, calc(100vw - 40px));
  z-index: 260;
  padding: 18px;
  background: #fff;
  border: 1px solid rgba(54, 81, 64, 0.12);
  border-radius: 14px;
  box-shadow: 0 20px 48px rgba(54, 81, 64, 0.22);
}

.home-guest-dropdown.is-open {
  display: block;
}

.home-guest-dropdown__label {
  font-size: 12px;
  font-weight: 700;
  color: #365140;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 14px;
}

.home-guest-stepper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.home-guest-stepper button {
  width: 38px;
  height: 38px;
  border: 1px solid #d7cdba;
  border-radius: 50%;
  background: #faf9f7;
  color: #365140;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}

.home-guest-stepper button:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.home-guest-stepper__count {
  font-size: 20px;
  font-weight: 600;
  color: #365140;
}

.home-guest-done {
  display: block;
  width: 100%;
  padding: 12px 16px;
  border: none;
  border-radius: 10px;
  background-color: #d16d56;
  color: #fff;
  font-family: "Raleway", sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
}

/* Flatpickr */
.home-booking-field__input.flatpickr-input {
  height: 22px;
  padding: 0;
  margin: 0;
  border: none;
  background: transparent;
}

.flatpickr-calendar {
  font-family: "Raleway", sans-serif;
  border-radius: 14px;
  box-shadow: 0 20px 48px rgba(54, 81, 64, 0.16);
}

.flatpickr-months .flatpickr-month,
.flatpickr-weekdays,
span.flatpickr-weekday {
  background: #365140;
}

span.flatpickr-weekday {
  color: rgba(255, 255, 255, 0.9);
}

.flatpickr-day.selected,
.flatpickr-day.startRange,
.flatpickr-day.endRange {
  background: #d16d56;
  border-color: #d16d56;
}

/* Tablet: 2 columns + full-width CTA */
@media (max-width: 991px) {
  .home-booking-section {
    margin-top: -24px;
    padding-bottom: 40px;
  }

  .home-booking-bar {
    grid-template-columns: 1fr 1fr;
    gap: 0;
    padding: 10px;
    border-radius: 14px;
  }

  .home-booking-divider {
    display: none;
  }

  .home-booking-field {
    margin: 4px;
    border-radius: 12px;
    border: 1px solid rgba(54, 81, 64, 0.08);
  }

  .home-booking-submit {
    grid-column: 1 / -1;
    margin: 8px 4px 4px;
    width: calc(100% - 8px);
    min-width: 0;
  }
}

/* Mobile: stack */
@media (max-width: 575px) {
  .home-booking-section__inner {
    padding: 0 12px;
  }

  .home-booking-bar {
    grid-template-columns: 1fr;
  }

  .home-booking-field {
    padding: 16px 18px;
  }
}
