/* Shared styles for form-field and destination-field custom selects */
.custom-select-wrapper select,
.custom-select-wrapper select.form-select,
.custom-select-wrapper select#id_origin,
.custom-select-wrapper select#id_destination {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  position: absolute !important;
  width: 0 !important;
  height: 0 !important;
  overflow: hidden !important;
}

.custom-select-button {
  width: 100%;
  text-align: left;
  background-color: transparent;
  border: none;
  outline: none;
  color: #2b2e4a;
  font-size: 14px;
  font-weight: 400;
  padding: 0;
  padding-right: 28px;
  cursor: pointer;
  position: relative;
  flex: 1;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%232b2e4a' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 8px center;
  background-size: 12px;
}

.custom-select-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background-color: #FFFFFF;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  z-index: 1000;
  max-height: 300px;
  overflow-y: auto;
  display: none;
  padding: 8px 0;
}

.custom-select-dropdown.show {
  display: block;
}

.custom-select-dropdown-item {
  padding: 10px 16px;
  color: #2b2e4a;
  font-size: 14px;
  line-height: 1.5;
  cursor: pointer;
  transition: background-color 0.2s ease;
  -webkit-transition: background-color 0.2s ease;
  -moz-transition: background-color 0.2s ease;
  -o-transition: background-color 0.2s ease;
}

.custom-select-dropdown-item:hover,
.custom-select-dropdown-item.selected {
  background-color: #dcffe6;
  color: #2b2e4a;
}

.custom-select-dropdown::-webkit-scrollbar {
  width: 8px;
}

.custom-select-dropdown::-webkit-scrollbar-track {
  background: #E6ECF7;
  border-radius: 4px;
}

.custom-select-dropdown::-webkit-scrollbar-thumb {
  background: #8C96A9;
  border-radius: 4px;
}

.custom-select-dropdown::-webkit-scrollbar-thumb:hover {
  background: #6B7A99;
}

.custom-select-dropdown {
  scrollbar-width: thin;
  scrollbar-color: #8C96A9 #E6ECF7;
}
