*{
    margin: 0;
    padding: 0;
    font-family: 'Poppins',sans-serif;
    box-sizing: border-box;
}
body{
    background: #222;
}
.card-navbar{
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 25px;
}

.card-navbar .logo{
    font-size: 22px;
    font-weight: 600;
    color: #fff;
}

.card-navbar .menu{
    display: flex;
    gap: 15px;
}

.card-navbar .menu a{
    color: #fff;
    text-decoration: none;
    font-size: 16px;
    transition: 0.3s;
}
.card-navbar .menu a:hover{
    text-decoration: underline;
}

.card-navbar .hamburger{
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 4px;
}
.card-navbar .hamburger span{
    height: 3px;
    width: 20px;
    background: #fff;
    border-radius: 2px;
}

/* Responsive for Card Navbar */
@media (max-width: 500px){
    .card-navbar .menu{
        position: absolute;
        top: 65px; /* adjust according to card padding */
        right: 20px;
        background: linear-gradient(135deg, #ff7e5f, #feb47b);
        flex-direction: column;
        width: 150px;
        display: none;
        padding: 10px;
        border-radius: 10px;
        z-index: 10;
    }
    .card-navbar .menu.show{
        display: flex;
    }
    .card-navbar .hamburger{
        display: flex;
    }
}


.card {
    width: 90%;
    max-width: 470px;
    background: linear-gradient(135deg, #ff7e5f, #feb47b); /* Orange to yellowish */
    color: #fff;
    margin: 50px auto; /* reduce top margin for mobile */
    border-radius: 20px;
    padding: 40px 35px;
    text-align: center;
    position: relative; /* for suggestions */
}

.search{
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative; /* suggestions positioning */
}
.search input{
    border: 0;
    outline:0;
    background: #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: #ebfffc;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    cursor: pointer;
}
.search button img{
    width:16px;
}
.weather-icon{
    width: 170px;
    margin-top: 30px;
}
.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: center;
}
.col img{
    width: 40px;
    margin-right: 10px;
}
.humidity, .wind{
    font-size: 28px;
    margin-top:-6px ;
}
.weather{
    display: none;
}
.error{
    text-align: left;
    margin-left: 10px;
    font-size: 14px;
    margin-top: 10px;
    display: none;
}

/* Autocomplete suggestions */
.suggestions{
    position: absolute;
    top: 65px; /* slightly below input */
    left: 0;
    background: #fff;
    color: #000;
    width: 100%;
    max-height: 200px;
    overflow-y: auto;
    border-radius: 10px;
    z-index: 10;
    box-shadow: 0 5px 10px rgba(0,0,0,0.2);
}
.suggestions div{
    padding: 10px;
    cursor: pointer;
}
.suggestions div:hover{
    background: #eee;
}

/* Responsive Styles */
@media (max-width: 500px) {
    .card {
        padding: 25px 15px;
        margin: 30px auto;
    }
    .weather h1 {
        font-size: 55px;
    }
    .weather h2 {
        font-size: 30px;
    }
    .details {
        flex-direction: column;
        gap: 20px;
        padding: 0 10px;
    }
    .search input {
        font-size: 16px;
        height: 50px;
        padding: 8px 20px;
    }
    .search button {
        width: 50px;
        height: 50px;
    }
    .weather-icon {
        width: 130px;
        margin-top: 20px;
    }
}
