/* --- Travel Search Box Main Styles --- */

.search-box {
  background: #ffffff;
  border-radius: 20px;
  box-shadow: 0 10px 40px rgba(9, 53, 58, 0.1);
  margin-top: -60px;
  position: relative;
  z-index: 100;
}

/* Tabs */
.search-box .tabs {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 24px 32px 0 32px;
  background: transparent;
  border-bottom: none;
}

.tab {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: 50px;
  color: #495b5d;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  background: transparent;
  user-select: none;
}

.tab i {
  font-size: 16px;
  color: #0f6b68;
}

.tab.active {
  background: #0f6b68;
  color: #ffffff;
  box-shadow: 0 4px 15px rgba(15, 107, 104, 0.3);
}

.tab.active i {
  color: #ffffff;
}

/* Tab panes — JS controls display, but provide safe defaults */
.tab-pane {
  display: none;
}

.tab-pane.active {
  display: block;
}

.customize {
  margin-left: auto;
  color: #0f6b68;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: opacity 0.2s;
  user-select: none;
}

.customize:hover {
  opacity: 0.8;
}

/* Form Area */
.search-box .tab-content {
  padding: 32px;
  background: #fff;
  border-radius: 0 0 20px 20px;
}

.search-box .form {
  display: flex;
  align-items: flex-end;
  gap: 20px;
  padding: 0;
}

.field {
  flex: 1;
  position: relative;
}

.field-wrapp {
  display: flex;
  gap: 20px;
  flex: 2;
}

.search-box .label {
  color: #6d7a7b;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 8px;
}

.search-box .input {
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 2px solid #eaeeef;
  padding-bottom: 10px;
  transition: border-color 0.3s;
}

.search-box .input:focus-within {
  border-color: #0f6b68;
}

.search-box .input .icon {
  color: #94a3a5;
  font-size: 18px;
  flex-shrink: 0;
}

.search-box .input input,
.search-box .input select {
  border: none !important;
  outline: none !important;
  width: 100%;
  font-size: 12px;
  font-weight: 600;
  color: #17383b;
  padding: 0;
  background: transparent;
  cursor: pointer;
}

.search-box .input select {
  appearance: auto; /* Standard dropdown arrow */
}

/* Select2 Skinning */
.search-box .select2-container--default .select2-selection--single {
  background-color: transparent;
  border: none !important;
  height: auto;
  outline: none !important;
}

.search-box
  .select2-container--default
  .select2-selection--single
  .select2-selection__rendered {
  padding-left: 0;
  font-size: 16px;
  font-weight: 600;
  color: #17383b;
  line-height: 1.2;
}

.search-box
  .select2-container--default
  .select2-selection--single
  .select2-selection__placeholder {
  color: #94a3a5;
  font-weight: 500;
}

.search-box
  .select2-container--default
  .select2-selection--single
  .select2-selection__arrow {
  height: 26px;
  top: -5px;
  right: -5px;
}

.search-box
  .select2-container--default
  .select2-selection--single
  .select2-selection__arrow
  b {
  border-color: #94a3a5 transparent transparent transparent;
}

.search-box
  .select2-container--default.select2-container--open
  .select2-selection--single
  .select2-selection__arrow
  b {
  border-color: transparent transparent #94a3a5 transparent;
}

/* Dropdown styling */
.select2-dropdown {
  border: none !important;
  border-radius: 12px !important;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1) !important;
  overflow: hidden;
  margin-top: 10px;
}

.select2-search--dropdown {
  padding: 12px;
}

.select2-search--dropdown .select2-search__field {
  border: 1px solid #eaeeef !important;
  border-radius: 8px !important;
  padding: 8px 12px !important;
  outline: none !important;
}

.select2-results__option {
  padding: 10px 16px !important;
  font-size: 14px !important;
  font-weight: 500 !important;
}

.select2-results__option--highlighted[aria-selected] {
  background-color: #0f6b68 !important;
}

.search-box .input input::placeholder {
  color: #94a3a5;
  font-weight: 500;
}

/* Search / Enquire Button */
.search-btn {
  background: #0f6b68;
  color: #ffffff;
  border: none;
  border-radius: 50px;
  padding: 16px 32px;
  font-size: 18px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: all 0.3s;
  box-shadow: 0 8px 20px rgba(15, 107, 104, 0.2);
  white-space: nowrap;
  flex-shrink: 0;
}

.search-btn:hover {
  background: #0c5c59;
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(15, 107, 104, 0.3);
}

/* --- Travelers Picker Popover --- */
.travelers-field {
  cursor: pointer;
}

.travelers-popover {
  position: absolute;
  top: calc(100% + 14px);
  left: 0;
  min-width: 320px;
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
  padding: 24px;
  display: none;
  z-index: 1000;
}

.travelers-popover.active {
  display: block;
  animation: fadeInDown 0.2s ease-out;
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.popover-title {
  font-size: 16px;
  font-weight: 700;
  color: #17383b;
  margin-bottom: 16px;
}

.traveler-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.traveler-row:last-child {
  margin-bottom: 0;
}

.traveler-info .type {
  font-size: 15px;
  font-weight: 700;
  color: #17383b;
  display: block;
}

.traveler-info .desc {
  font-size: 12px;
  color: #6d7a7b;
}

.counter-btns {
  display: flex;
  align-items: center;
  gap: 15px;
}

.counter-btn {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid #0f6b68;
  background: transparent;
  color: #0f6b68;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
  transition: all 0.2s;
}

.counter-btn:hover:not(:disabled) {
  background: #0f6b68;
  color: #ffffff;
}

.counter-btn:disabled {
  border-color: #eaeeef;
  color: #c5cfd0;
  cursor: not-allowed;
}

.counter-value {
  font-size: 16px;
  font-weight: 700;
  color: #17383b;
  min-width: 20px;
  text-align: center;
}

/* Rooms select inside popover */
.room-select {
  width: 100%;
  padding: 10px 14px;
  border-radius: 8px;
  border: 1px solid #eaeeef;
  font-size: 15px;
  font-weight: 600;
  color: #17383b;
  margin-bottom: 20px;
  outline: none;
  cursor: pointer;
  background: #f8fafb;
  appearance: auto;
}

.room-select:focus {
  border-color: #0f6b68;
}

/* --- Flatpickr Customization --- */
.flatpickr-calendar {
  border-radius: 16px !important;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1) !important;
  border: none !important;
  padding: 10px;
}

.flatpickr-day.selected,
.flatpickr-day.startRange,
.flatpickr-day.endRange {
  background: #0f6b68 !important;
  border-color: #0f6b68 !important;
}

.flatpickr-day.inRange {
  background: #f0f7f7 !important;
  box-shadow:
    -5px 0 0 #f0f7f7,
    5px 0 0 #f0f7f7 !important;
}

/* --- Modal Styles --- */
.ate-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(5px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  padding: 20px;
}

.ate-modal.active {
  display: flex;
}

.modal-content {
  background: #ffffff;
  width: 100%;
  max-width: 500px;
  border-radius: 24px;
  padding: 40px;
  position: relative;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
}

.modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: none;
  border: none;
  font-size: 24px;
  color: #94a3a5;
  cursor: pointer;
  line-height: 1;
  transition: color 0.2s;
}

.modal-close:hover {
  color: #17383b;
}

.modal-content h2 {
  font-size: 28px;
  font-weight: 800;
  color: #17383b;
  margin-bottom: 10px;
}

.modal-content p {
  color: #6d7a7b;
  margin-bottom: 30px;
}

.ate-form .form-group {
  margin-bottom: 20px;
}

.ate-form label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  color: #6d7a7b;
  margin-bottom: 8px;
  letter-spacing: 0.5px;
}

.ate-form input,
.ate-form textarea {
  width: 100%;
  padding: 14px 20px !important;
  border-radius: 12px;
  border: 1px solid #eaeeef !important;
  background: #f8fafb;
  font-size: 16px;
  outline: none;
  transition: all 0.3s;
  box-sizing: border-box;
}

.ate-form input:focus,
.ate-form textarea:focus {
  border-color: #0f6b68;
  background: #ffffff;
}

.ate-form textarea {
  resize: vertical;
}

.ate-form .submit-btn {
  width: 100%;
  background: #0f6b68;
  color: #ffffff;
  border: none;
  padding: 16px;
  border-radius: 12px;
  font-size: 18px;
  font-weight: 700;
  cursor: pointer;
  margin-top: 10px;
  transition: background 0.2s;
}

.ate-form .submit-btn:hover {
  background: #0c5c59;
}

.ate-form .submit-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

/* --- Responsive --- */
@media (max-width: 1024px) {
  .search-box .form {
    flex-direction: column;
    align-items: stretch;
  }

  .field-wrapp {
    flex-direction: column;
  }

  .search-btn {
    width: 100%;
    justify-content: center;
  }

  .travelers-popover {
    min-width: 280px;
  }
}

@media (max-width: 768px) {
  .search-box .tabs {
    padding: 16px 16px 0 16px;
    flex-wrap: wrap;
    gap: 8px;
  }

  .search-box .tab-content {
    padding: 20px 16px;
  }

  .customize {
    margin-left: 0;
    width: 100%;
    justify-content: center;
    padding: 8px 0;
  }
}
.search-box ul li {
  list-style: none !important;
}

.msg-label label {
  font-size: 14px !important;
  font-weight: 600 !important;
}
.bf-group.msg-label p {
    margin-bottom: 0px !important;
}


/* Flatpickr Desktop Width */
.flatpickr-calendar {
  width: 718px !important;
  max-width: 95vw !important;
}

/* Two month layout desktop */
.flatpickr-calendar.multiMonth .flatpickr-days {
  width: 700px !important;
}

.flatpickr-calendar.multiMonth .dayContainer {
  width: 350px !important;
  min-width: 350px !important;
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .flatpickr-calendar,
  .flatpickr-calendar.multiMonth .flatpickr-days {
    width: 84% !important;
    left: 10% !important;
    max-width: 100vw !important;
  }

  .flatpickr-calendar.multiMonth .dayContainer {
    width: 100% !important;
    min-width: 100% !important;
  }

  /* Stack months vertically on mobile */
  .flatpickr-calendar.multiMonth {
    display: flex !important;
    flex-direction: column !important;
  }

  .flatpickr-months {
    flex-wrap: wrap;
  }
}

