h4 {
  line-height: 1.5;
}

/* Mapbox Geocoder Styling */
.mapboxgl-ctrl-geocoder {
  box-shadow: none;
  width: 100%;
  max-width: 100%;
  min-width: 100%;
  position: relative;
  z-index: 1;
}

#commute-start-container,
#commute-end-container {
  position: relative;
  z-index: 2;
}

#commute-start-container:focus-within {
  z-index: 10;
}

#commute-end-container:focus-within {
  z-index: 10;
}

.mapboxgl-ctrl-geocoder input[type="text"] {
  padding: 6px 35px;
  font-size: 1rem;
  line-height: 1.5;
  border-radius: 0.25rem;
  border: 1px solid #ced4da;
  height: calc(1.5em + 0.75rem + 2px);
}

.mapboxgl-ctrl-geocoder input[type="text"]:focus {
  border-color: #80bdff;
  outline: 0;
  box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.mapboxgl-ctrl-geocoder--input:focus {
  outline: none;
}

.mapboxgl-ctrl-geocoder .mapboxgl-ctrl-geocoder--icon-search {
  top: 11px;
  left: 11px;
}

.mapboxgl-ctrl-geocoder .suggestions {
  border-radius: 0.25rem;
  margin-top: 4px;
  z-index: 100;
  position: absolute;
}

/* Validation styling */
.mapboxgl-ctrl-geocoder input.is-invalid {
  border-color: #dc3545;
  padding-right: calc(1.5em + 0.75rem);
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='%23dc3545'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23dc3545' stroke='none'/%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right calc(0.375em + 0.1875rem) center;
  background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

.mapboxgl-ctrl-geocoder input.is-invalid:focus {
  border-color: #dc3545;
  box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25);
}

.result-sentence {
  font-size: 20px;
  padding: 15px 0;
  line-height: 1.7;
}

.rangeslider-wrap {
  padding: 60px 0;
}

.rangeslider {
  position: relative;
  height: 4px;
  border-radius: 5px;
  width: 100%;
  background-color: gray;
}

.rangeslider__handle {
  transition: background-color 0.2s;
  box-sizing: border-box;
  width: 20px;
  height: 20px;
  border-radius: 100%;
  background-color: #0047ba;
  touch-action: pan-y;
  cursor: pointer;
  display: inline-block;
  position: absolute;
  z-index: 3;
  top: -8px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.5), inset 0 0 0 2px white;
}

.rangeslider__handle__value {
  transition: background-color 0.2s, box-shadow 0.1s, transform 0.1s;
  box-sizing: border-box;
  width: 112px;
  text-align: center;
  padding: 10px;
  background-color: #0047ba;
  border-radius: 5px;
  color: white;
  left: -41px;
  top: -55px;
  position: absolute;
  white-space: nowrap;
  border-top: 1px solid #007acc;
  box-shadow: 0 -4px 1px rgba(0, 0, 0, 0.07), 0 -5px 20px rgba(0, 0, 0, 0.3);
}

.rangeslider__handle__value:before {
  transition: border-top-color 0.2s;
  position: absolute;
  bottom: -10px;
  left: calc(50% - 10px);
  content: "";
  width: 0;
  height: 0;
  border-left: 10px solid transparent;
  border-right: 10px solid transparent;
  border-top: 10px solid;
  border-top-color: #0047ba;
}

.rangeslider__fill {
  position: absolute;
  top: 0;
  z-index: 1;
  height: 100%;
  background-color: #0047ba;
  border-radius: 5px;
}

.rangeslider__labels {
  position: absolute;
  width: 100%;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  padding: 0 8px;
}

.rangeslider__labels__label {
  font-size: 1.5em;
  position: relative;
  padding-top: 15px;
  color: gray;
}

.rangeslider__labels__label:before {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  content: "";
  width: 1px;
  height: 9px;
  border-radius: 1px;
  background-color: rgba(128, 128, 128, 0.5);
}

.rangeslider__labels__label:first-child:before,
.rangeslider__labels__label:last-child:before {
  height: 12px;
  width: 2px;
}

.rangeslider__labels__label:first-child:before {
  background-color: gray;
}

.rangeslider__labels__label:last-child:before {
  background-color: gray;
}

.rangeslider__labels__label:first-child {
  transform: translateX(-48%);
}

.rangeslider__labels__label:last-child {
  transform: translateX(48%);
}

.rangeslider.rangeslider--active .rangeslider__handle,
.rangeslider.rangeslider--active .rangeslider__handle * {
  background-color: #33adff;
}

.rangeslider.rangeslider--active .rangeslider__handle *:before {
  border-top-color: #33adff;
}

.rangeslider.rangeslider--active .rangeslider__handle__value {
  transform: translateY(-5px);
  box-shadow: 0 -3px 2px rgba(0, 0, 0, 0.04), 0 -9px 25px rgba(0, 0, 0, 0.15);
}

@media (min-width: 768px) {
  .rangeslider-wrap {
    padding: 60px 40px;
  }
}

.driving-expenses {
  font-family: 'Lato', sans-serif;
}

.driving-expense {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0 6px;
  font-weight: bold;
  position: relative;
  height: 20px;
  font-size: 12px;
  white-space: nowrap;
}

.driving-expense:after {
  content: " ";
  position: absolute;
  right: -5px;
  top: 0;
  border-top: 10px solid transparent;
  border-right: none;
  border-left: 5px solid black;
  border-bottom: 10px solid transparent;
  z-index: 1;
}

.driving-expense-yellow {
  background: #F7D22B;
}

.driving-expense-yellow:after {
  border-left-color: #F7D22B;
}

.driving-expense-orange {
  background: #F1AE21;
}

.driving-expense-orange:after {
  border-left-color: #F1AE21;
}

.driving-expense-green {
  background: #B1CB38;
}

.driving-expense-green:after {
  border-left-color: #B1CB38;
}

.driving-expense-dark-green {
  background: #97AD3A;
}

.driving-expense-dark-green:after {
  border-left-color: #97AD3A;
}

.driving-expense-blue {
  background: #8BD5ED;
}

.driving-expense-blue:after {
  border-left-color: #8BD5ED;
}

.driving-expense-pink {
  background: #E9526D;
}

.driving-expense-pink:after {
  border-left-color: #E9526D;
}

@media (min-width: 1200px) {
  .driving-expenses {
    display: flex;
    align-items: stretch;
    margin-right: 30px;
  }

  .driving-expenses-list {
    display: flex;
    align-items: stretch;
  }

  .driving-expense {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0 0 0 36px;
    font-weight: bold;
    position: relative;
    height: 90px;
    font-size: 12px;
    white-space: inherit;
  }

  .driving-expense:after {
    right: -30px;
    border-top-width: 45px;
    border-left-width: 30px;
    border-bottom-width: 45px;
  }
}