:root {
  --bg-color: #f3f3f3;
  --text-color: #121212;
  --orange: #ffa95f;
  --grey: #7b7b7b;
  --gradient: linear-gradient(#f3f3f388, #f3f3f3);
  --input: #fff;
  --icon: url("assets/img/moon-solid.svg");
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Inter", sans-serif;
}

.error {
  color: red;
}

.hidden {
  display: none !important;
}

#wait {
  margin-top: 30px;
  color: var(--text-color);
}

body {
  background: var(--bg-color);
  color: var(--text-color);
}

/* HEADER IMAGE */
.background-img {
  position: absolute;
  height: 400px;
  overflow: hidden;
  z-index: -1;
  width: 100%;
}

.background-img img {
  object-fit: cover;
  object-position: bottom;
}

.background-img-overlay {
  background: var(--gradient);
  position: absolute;
  top: 0px;
  right: 0px;
  bottom: 0px;
  left: 0px;
}

/* CONTAINER */
.wrapper {
  max-width: 32rem;
  margin: 0 auto;
  padding: 10px;
  min-height: 100vh;
}

/* LOGO AND DARK MODE HEADER */
.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

#header-image {
  min-width: 100%;
}

.logo {
  font-size: 1.56rem;
}

.logo-subtext {
  font-size: 0.7rem;
}

.icon svg {
  cursor: pointer;
}

/* USER INPUTS */
.inputs {
  display: flex;
  flex-direction: column;
  margin-top: 10rem;
}

label {
  font-size: 1.2rem;
  font-weight: 600;
  margin: 15px 0;
  opacity: 80%;
}

.place-input {
  border: none;
  outline: none;
  border-radius: 50px;
  background: var(--input);
  padding: 10px 25px;
  font-size: 1.2rem;
  border: 1px solid rgba(230, 230, 230, 0.05);
  color: inherit;
}

.place-input:hover {
  filter: brightness(110%);
}

/* PLACES AUTOCOMPLETE */
.pac-container {
  background: var(--input);
  filter: brightness(120%);
  border-radius: 15px;
  padding: 10px;
  border: 1px solid rgba(230, 230, 230, 0.05);
}

.pac-icon {
  margin-right: 10px;
}

.pac-item {
  border-radius: 30px;
  margin-bottom: 5px;
  padding: 4px 15px;
  border: none;
  cursor: pointer;
  color: var(--text-color);
}

.pac-item:hover {
  background: var(--input);
  filter: brightness(110%);
}

.pac-item-query {
  color: var(--text-color);
}

.pac-matched {
  color: var(--text-color);
}

.pac-container:after {
  /* Disclaimer: not needed to show 'powered by Google' if also a Google Map is shown */
  opacity: 70%;
}

button {
  border: none;
  border-radius: 50px;
  background: var(--orange);
  padding: 10px 15px;
  color: var(--bg-color);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  margin-top: 30px;
}

button:hover {
  background: #ffb575;
}

/* SLIDERS */

.sliderContainer {
  width: 100%;
  text-align: left;
  margin-top: 30px;
}

.innerContainer {
  margin-top: 15px;
  padding: 10px 30px 30px;
  background: var(--input);
  border: 1px solid rgba(230, 230, 230, 0.05);
  border-radius: 15px;
  color: var(--grey);
}

.innerContainer:hover {
  filter: brightness(110%);
}

.innerContainer p {
  font-size: 1.2rem;
}

.rangeWrapper {
  display: flex;
  justify-content: space-between;
  font-weight: bold;
}

.innerContainer input {
  margin: 20px 0;
}

.rangeWrapper {
  display: flex;
  justify-content: space-between;
}

/* RECENT ITINERARIES */
.saved-places {
  display: flex;
  flex-direction: column;
  font-size: 1.2rem;
  font-weight: 600;
  margin: 40px 0;
}

.saved-places h3 {
  margin: 10px 0;
}

.saved-place-button {
  width: 100%;
  background: var(--input);
  margin: 5px 0;
  border: 1px solid rgba(230, 230, 230, 0.05);
  border-radius: 30px;
  color: var(--grey);
}

.saved-place-button:hover {
  background: var(--input);
  filter: brightness(110%);
}

#back {
  width: 100%;
  margin: 40px 0;
  border-radius: 30px;
}

#itinerary-container {
  margin-top: 50px;
}

#itinerary-container h2 {
  margin-top: 20px;
  color: var(--orange);
}

#itinerary-plan {
  transform: translateY(-20px);
  padding-top: 30px;
}

#itinerary-plan p{
  margin-top: 30px;
}

/* all images */
.i-image {
  border-radius: 15px;
  background-color: #ccc;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

/* itinerary-3-images */
#itinerary-3-images {
  margin-top: 20px;
  height: 330px;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  column-gap: 15px;
  row-gap: 15px;
}

#img-one {
  grid-area: 1 / 1 / 3 / 3;
  background-image: url("https://api.lorem.space/image/drink");
}

#img-two {
  background-image: url("https://api.lorem.space/image/burger");
}

#img-three {
  background-image: url("https://api.lorem.space/image/pizza");
}

#img-4 {
  width: 100%;
  height: 160px;
  margin-top: 20px;
  background-image: url("https://api.lorem.space/image/house");
}

/* itinerary-2-images */
#itinerary-2-images {
  margin-top: 20px;
  height: 160px;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  column-gap: 15px;
  row-gap: 15px;
}

#img-5 {
  background-image: url("https://api.lorem.space/image/drink");
  grid-area: 1 / 1 / 2 / 3;
}

#img-6 {
  background-image: url("https://api.lorem.space/image/burger");
}

p {
  font-size: 1.3rem;
  margin-top: 20px;
}

#new-itinerary-button {
  width: 100%;
  margin: 40px 0;
  height: 50px;
  font-size: 1.5em;
  cursor: pointer;
}

footer {
  max-width: 32rem;
  margin: 0 auto;
  padding: 10px;
}

footer p {
  font-size: 0.8rem;
  text-align: center;
}

@media only screen and (max-width: 600px) {
  .wrapper {
    padding: 15px;
  }

  #itinerary-3-images {
    height: 238px;
  }

  #img-4,
  #itinerary-2-images {
    height: 106px;
  }
}

@media screen and (-webkit-min-device-pixel-ratio: 0) {
  input[type="range"] {
    overflow: visible;
    width: 100%;
    -webkit-appearance: none;
    background-color: var(--grey);
    border-radius: 5px;
    height: 10px;
  }

  input[type="range"]::-webkit-slider-thumb {
    width: 16px;
    -webkit-appearance: none;
    height: 16px;
    cursor: ew-resize;
    background: #ffffff;
    box-shadow: #ffffff 0 80px #43e5f7;
    border-radius: 8px;
    cursor: pointer;
    border: 0.5px solid var(--grey);
  }
}
