* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Body Styling */
body {
  font-family: Arial, Helvetica, sans-serif;
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  background-color: whitesmoke;
}

/* Search Bar Styling */
.search-container {
  display: flex;
  align-items: center;
  position: absolute;
  margin-left: 530px;
  margin-top: 20px;
  top: 10px;
  left: 10px;
  border-radius: 5px;
  z-index: 10;
  cursor: pointer;
  transition: all 0.3s ease;
  width: 40px;
  overflow: hidden;
}

#cityInput {
  width: 0;
  padding: 0;
  font-size: 14px;
  outline: none;
  opacity: 0;
  transition: width 0.3s ease, opacity 0.3s ease;
}

#searchIcon {
  color: white;
  font-size: 24px;
  cursor: pointer;
  transition: transform 0.3s ease;
}

.search-container.active {
  width: 200px;
}

.search-container.active #cityInput {
  width: 150px;
  opacity: 1;
  padding: 8px;
  background-color: rgba(255, 255, 255, 0.5);
  border: 1px solid gray;
}

.search-container.active #searchIcon {
  transform: rotate(90deg);
}

/* Current weather section */
.currentWeather {
  color: white;
  padding: 30px;
  width: 100%;
  max-width: 400px;
  position: relative;
  overflow: hidden;
  background-color: lightblue;
  border-bottom-left-radius: 180% 200px;
  border-bottom-right-radius: 180% 200px;
  margin-bottom: -65px;
  z-index: 1;
}


/* Temperature */
.currentWeather .temperature {
  font-size: 7rem;
  font-weight: bold;
  margin-bottom: 10px;
  margin-top: 15px;
  text-shadow: -1px -1px 0px grey, 1px -1px 0px grey, -1px 1px 0px grey, 1px 1px 0px grey;
}

/* City Name  */
.currentWeather .location {
  font-size: 2.5rem;
  font-weight: 200;
  margin-bottom: 10px;
  text-shadow: -1px -1px 0px grey, 1px -1px 0px grey, -1px 1px 0px grey, 1px 1px 0px grey;
}

/* Time  */
.currentWeather .time {
  font-size: 1.2rem;
  margin-bottom: 20px;
  text-shadow: -1px -1px 0px grey, 1px -1px 0px grey, -1px 1px 0px grey, 1px 1px 0px grey;
}

/* Description of weather */
.currentWeather .description {
  font-size: 1.2rem;
  font-weight: 200;
  margin-bottom: 40px;
  text-shadow: -1px -1px 0px grey, 1px -1px 0px grey, -1px 1px 0px grey, 1px 1px 0px grey;
}

/* Sunrise and Sunset  */
.currentWeather .sun-info {
  display: flex;
  justify-content: space-around;
  font-size: 1.2rem;
  color: white;
  margin-bottom: 20px;
  text-shadow: -1px -1px 0px grey, 1px -1px 0px grey, -1px 1px 0px grey, 1px 1px 0px grey;
}

/* Forecast Section */
#forecast {
  background-color: rgb(244, 235, 235);
  padding: 20px;
  width: 100%;
  max-width: 400px;
  text-align: left;
  z-index: 0;
  position: relative;
}

/* Forecast items */
#forecast div {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  margin-top: 20px;
}

#forecast div:last-child {
  border-bottom: none;
  margin-bottom: 40px;
}

#forecast div:first-child {
  margin-top: 70px;
}

/* Day and Weather in forecast */
#forecast .day {
  font-weight: bold;
  font-size: 1.1rem;
  width: 100px;
}

#forecast .temp {
  font-size: 1.1rem;
}

#forecast .wind {
  font-size: 0.9rem;
  color: #666;
}



/* Responsive Design for Smartphones */
@media screen and (max-width: 480px) {
  body {
    padding: 5px;
  }

  .currentWeather {
    padding: 15px;
    max-width: 100%;
  }

  #forecast {
    padding: 10px;
    max-width: 100%;
  }

  .search-container {
    margin-left: 10px;
    margin-top: 5px;
  }

  .currentWeather .temperature {
    font-size: 5rem;
  }

  .currentWeather .location {
    font-size: 1.5rem;
  }

  .currentWeather .description,
  .currentWeather .time,
  .currentWeather .sun-info {
    font-size: 1rem;
  }

  #forecast .day {
    font-size: 1rem;
  }

  #forecast .temp {
    font-size: 1rem;
  }

  #forecast .wind {
    font-size: 0.8rem;
  }
}

@media screen and (min-width: 481px) and (max-width: 1118px) {

  /* Responsive design for ipad air */
  .search-container {
    margin-left: 210px;
    margin-top: 230px;
    margin-bottom: 20px;
    width: 40px;
  }

}