* {
    margin: 0;
    padding: 0;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    box-sizing: border-box;
}

body {
    background-image: url('https://images.unsplash.com/photo-1519681393784-d120267933ba');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 40px;
}

.title {
    font-size: 50px;
    font-weight: 900;
    color: #000000e3;
    margin-bottom: 20px;
    text-align: center;
}

.temp {
    font-size: 50px;
    font-weight: 900;
    margin-bottom: 20px;
    text-align: center;
}

.card {
    width: 90%;
    max-width: 600px;
    color: #ffffff;
    border-radius: 10px;
    padding: 40px 35px;
    text-align: center;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

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

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

.search button {
    border: 0;
    outline: 0;
    background: #ffffffd8;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    cursor: pointer;
}

.search button img {
    width: 20px;
}

.weather-icon {
    width: 150px;
    margin-top: 20px;
}

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

.weather h2 {
    font-size: 40px;
    font-weight: 400;
    margin-top: -10px;
}

.details {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    margin-top: 40px;
    font-weight: 900;
    font-size: 18px;
}

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

.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;
}

/* Media query per dispositivi mobili */
@media (max-width: 768px) {
    .card {
        margin: 50px auto;
        padding: 20px 15px;
        max-width: 90%;
    }

    .search input {
        padding: 8px 20px;
        height: 45px;
        font-size: 16px;
    }

    .search button {
        width: 45px;
        height: 45px;
    }

    .weather-icon {
        width: 130px;
        margin-top: 20px;
    }

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

    .weather h2 {
        font-size: 35px;
    }

    .details {
        flex-direction: column;
        align-items: center;
        padding: 0 10px;
        margin-top: 30px;
    }

    .col {
        margin-bottom: 10px;
    }

    .humidity,
    .wind {
        font-size: 24px;
    }
}

/* Media query per dispositivi molto piccoli */
@media (max-width: 480px) {
    .search input {
        padding: 6px 15px;
        height: 40px;
        font-size: 14px;
    }

    .search button {
        width: 40px;
        height: 40px;
    }

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

    .weather h2 {
        font-size: 25px;
    }

    .humidity,
    .wind {
        font-size: 20px;
    }
}
