:root{
  --bg-color1:rgb(3, 103, 73);
  --bg-color2:rgb(2, 72, 64);
  --aqi-1: #d4e157;
  --aqi-2: #ffee58;
  --aqi-3: #ffca28;
  --aqi-4: #ff7043;
  --aqi-5: #ef5350;
}
*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
body{
    min-height: 100vh;
    background-color: var(--bg-color1); 
    color: #fff;
    font-family: sans-serif;
    padding: 0 15px;

}
hr{
  margin-bottom: 10px;
}
.header{
position: sticky;
top: 0;
background-color: var(--bg-color1);
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 10px;
padding: 15px 0;
   & #city_input{
background-color: var(--bg-color2);
border: none;
padding: 12px;
font-size: 16px;
border-radius:  25px;
color: #fff;
&:focus{
    outline: none;
}
}
}
& #searchBtn{
border: none;
font-size:  16px;
padding: 12px;
border-radius: 25px;
background-color: #fff;
cursor: pointer;
}
& #locationBtn{
    border: none;
    font-size:  16px;
    padding: 12px;
    border-radius: 25px;
    background-color:rgb(75, 234, 171);
    cursor: pointer;
}
.card{
background-color: var(--bg-color2);
padding: 15px;
border-radius: 15px;
margin-bottom: 15px;
  & p{
    font-size: 14px;
color:#999;
  }
& h2{
font-size: 32px;
font-weight:  500;
}
}

.weather-data{
display: grid;
grid-template-columns:  repeat(4, 1fr);
gap: 12px;
& .weather-left{
grid-column: span 1;
& .current-weather{
display: flex;
justify-content: space-between;
align-items: center;
& h2{
    margin: 7px 0;
}
& p{
    color: #fff;
}
}
& .card-footer p{
    font-size: 14px;
    margin-bottom: 12px;
}
& .forecast-item{
display: grid;
grid-template-columns: repeat(3, 1fr);
place-items: center;
margin-bottom:  15px;
    & .icon-wrapper{
display: flex;
align-items: center;
}
}
}
  & .weather-right{
    grid-column: span 3;
     & h2{
        margin-bottom: 10px;       
    }
& .highlights{
  display: grid;
    grid-template-columns: repeat(4, 1fr);
  column-gap: 15px;
& .card:nth-of-type(1),
& .card:nth-of-type(2){
    grid-column: span 2;
}
& .card-head{
       display: flex;
       justify-content: space-between;
       margin-bottom:  10px;
       & .air-index{
         color: #000;
        padding: 5px 10px;
        border-radius: 15px;
         &.aqi-1{
            background-color: var(--aqi-1);
         }
            &.aqi-2{
                background-color: var(--aqi-2);
            }
            &.aqi-3{
                background-color: var(--aqi-3);
            }
            &.aqi-4{
                background-color: var(--aqi-4);
            }
            &.aqi-5{
                background-color: var(--aqi-5);
            }


        }

       }
       & .air-indices{
display: grid;
grid-template-columns: repeat(4, 1fr);
place-items: center;
& p{
     text-align: center;
}
       }  
       & .sunrise-sunset{
display: grid;
grid-template-columns: repeat(2, 1fr);
      & .item{

        display: flex;
        align-items: center;
        gap: 10px;
            & h2{
              margin-top: 15px;
            }
      }
       }
       & .card-item{
        display: flex;
        justify-content:  space-between;

       }

}
          & .hourly-forecast{
            display: grid;
            grid-template-columns:  repeat(8, 1fr);
            column-gap:  10px;
            & .card{
              text-align: center;
            }
          }

}
  }
@media(max-width: 1100px){
  .weather-data{
    grid-template-columns: repeat(3, 1fr);
    & .weather-right{
      grid-column: span 2;
      & .highlights{
        grid-template-columns: repeat(3, 1fr);
        & .card:nth-of-type(1){
          grid-column:span 3;
        }
      }
      & .hourly-forecast{
        grid-template-columns: repeat(6, 1fr);
      }
    }
  }
}
@media(max-width: 1040px){
   .weather-data{
    grid-template-columns: repeat(2, 1fr);
     & .weather-right{
      grid-column:  span 1;
      & .highlights{
        grid-template-columns: repeat(2, 1fr);
        & .card:nth-of-type(1){
          grid-column: span 2;
        }
      }
      & .hourly-forecast{
        grid-template-columns:  repeat(4, 1fr);
      }
     }
   }
}
@media(max-width: 992px){
   .weather-data .weather-right .highlights{
      & .card{
        grid-column: span 2;
      }
      & .air-indices{
        grid-template-columns: repeat(3, 1fr);
      }
   }
}
@media(max-width: 850px){
   .weather-data{
    grid-template-columns: 1fr;
    & .weather-right .highlights{
      & .card:nth-of-type(3),
      & .card:nth-of-type(4),
      & .card:nth-of-type(5),
      & .card:nth-of-type(6),
      & .card:nth-of-type(7){
        grid-column: span 1;
      }
      & .air-indices{
        grid-template-columns: repeat(5, 1fr);
      }
    }
   }
}
@media(max-width: 660px){
   .header{
    flex-direction: column;
    & h2{
      margin-bottom: 8px; 
    }
    & #city_input, #searchBtn, #locationBtn{
      width: 100%;
      margin-bottom: 10px;
    }
   }
}
@media(max-width: 580px){
  .weather-data .weather-right .highlights .air-indices{
    grid-template-columns: repeat(4, 1fr);
  }
}
@media(max-width: 520px){
  .weather-data .weather-right .highlights{
    & .card:nth-of-type(3),
    & .card:nth-of-type(4),
    & .card:nth-of-type(5),
    & .card:nth-of-type(6),
    & .card:nth-of-type(7){
      grid-column: span 1;
    }
    & .air-indices{
      grid-template-columns: repeat(3, 1fr);
    }
  }
}
@media(max-width: 480px){
  .weather-data .weather-right .highlights .sunrise-sunset{
    grid-template-columns: 1fr;
  }
}
@media(max-width: 450px){
  .weather-data .weather-right .hourly-forecast{
    grid-template-columns: repeat(3, 1fr);
  }
}
@media(max-width: 380px){
.weather-data .weather-right .highlights .air-indices{
  grid-template-columns: repeat(7, 1fr);
}
}


header {
  /* background-color: rgba(6, 33,6,0.9);  */
  padding: 15px 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

.logo {
  display: flex;
  align-items: center;
  color: white;
  font-size: 1.8rem;
  font-weight: bold;
}

.logo img {
  height: 40px;
  margin-right: 10px;
}

nav {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  align-items: center;
}

nav a {
  color: white;
  text-decoration: none;
  position: relative;
}

nav a:hover {
  color: #ffe600;
}

.dropdown {
  position: relative;
}

.dropdown-content {
  display: none;
  position: absolute;
  top: 30px;
  left: 0;
  background-color: seagreen;
  padding: 10px;
  border-radius: 5px;
  z-index: 100;
  width: 250px;
}

.dropdown-content a {
  display: block;
  padding: 5px 10px;
  color: white;
  text-decoration: none;
}

.dropdown-content a:hover {
  background-color: #2eaa2e;
}

.dropdown:hover .dropdown-content {
  display: block;
}
.see{
  text-align: center;
  display: flex;
margin-right: 45px;
padding-right: 50px;
gap: 30px;
}




















