@import url('https://fonts.googleapis.com/css2?family=Didact+Gothic&family=Poppins:wght@400;500;600&family=Press+Start+2P&family=Quicksand:wght@300;400&family=Roboto:wght@100&display=swap');

*{
    padding: 0;
    margin:0;
    box-sizing: border-box;
    font-family: 'Poppins';
}

.card{
    width: 90%;
    max-width: 470px;
    background: linear-gradient(135deg, #00feba, #5b548a);
    color:white;
    margin: 30px auto 0;
    border-radius: 20px;
    padding: 40px 35px;
    text-align: center;
}

.search{
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.search input{
    border:0;
    outline:0;
    background-color: #ebfffc;
    color:#555;
    padding: 10px 25px;
    height: 60px;
    border-radius: 30px;
    flex:1;
    margin-right: 16px;
    font-size: 18px;
}

.search button{
    border:0;
    outline:0;
    background-color: #ebfffc;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    cursor:pointer;
    font-size: 1.5rem;
    text-align: center;
}

.search button:active{
    transform: scale(0.9);
}

.weather-icon{
    width: 170px;
    margin-top: 30px;
}

.weather{
    display: none;
}

.weather h1{
    font-size: 80px;
    font-weight: 500;
    
}
.weather h2{
    font-size: 45px;
    font-weight: 400;
    margin-top: -10px;
}

.details{
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    margin-top: 50px;
}

.col{
    display: flex;
    align-items: center;
    text-align: left;
}

.col img{
    width: 40px;
    margin-right: 10px;
}

.humidity, .wind{
    font-size: 28px;
    margin-top: -6px;
}

#error{
    /* background-color: rgba(255,255,255,0.5); */
    display: none;
    border-radius: 50px;
    margin: 0 auto;
    margin-top: 2rem;
    color:white;
}

.error{
    /* background-color: rgba(255,255,255,0.5); */
    display: block;
    border-radius: 50px;
    margin: 0 auto;
    margin-top: 2rem;
    color:white;
    animation: shake .6s cubic-bezier(.36,.07,.19,.97) both;
    transform: translate3d(0, 0, 0);
    backface-visibility: hidden;
    perspective: 1000px;
}

@keyframes shake {
    10%, 90% {
      transform: translate3d(-1px, 0, 0);

    }
    
    20%, 80% {
      transform: translate3d(2px, 0, 0);

    }
  
    30%, 50%, 70% {
      transform: translate3d(-4px, 0, 0);

    }
  
    40%, 60% {
      transform: translate3d(4px, 0, 0);

    }
  }

  @media (width < 470px){
    .search input{
        width: 13rem;
        position: absolute;

    }
    
    .search button{
        position: absolute;
        right: 50px;
    }

    .details{
        display: flex;
        flex-direction: column;
        place-self: center;
        align-items: center;
        text-align: center;
        gap:2rem;
        margin:0 auto;
        margin-top: 1rem;
    }

    .weather h1 {
        font-size: 60px;
    }

    .weather-icon {
        width: 140px;
    }

    .search{
        padding-top:2rem;
        padding-bottom:2rem;
    }
  }