* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    outline: none;
    user-select: none;
    scrollbar-width: none;
    -webkit-tap-highlight-color: transparent;
    font-family: 'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS', sans-serif;
}

:root {
    --primary-color: #e7eff3;
    --secondary-color: white;
    --text-color: black;
}

body {
    width: 100%;
    min-height: 100vh;
    padding: 0.5em;
    background-color: var(--primary-color);
    color: var(--text-color);
    display: flex;
    flex-direction: column;
    align-items: center;
}

header {
    width: 100%;
    padding: 1em;
    background-color: var(--secondary-color);
    box-shadow: 0 1px 5px rgba(0, 0, 0, 0.2);
    border-radius: 15px;
    text-align: center;
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    gap: 1em;
}

form {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
}

input {
    width: 15em;
    padding: 9.4px 15px;
    border-radius: 100px 0px 0px 100px;
    border: none;
    outline: none;
    background-color: var(--primary-color);
    color: var(--text-color);
    font-size: 1em;
}

button {
    cursor: pointer;
    padding: 0 15px;
    border-radius: 0px 100px 100px 0px;
    border: none;
    outline: none;
    background-color: var(--primary-color);
    color: var(--text-color);
    font-size: 30px;
    text-align: center;
    transition: opacity 0.3s ease;
}

button:hover {
    opacity: 0.7;
}

#error_weather, #error_astronomy {
    width: 100%;
    color: red;
    text-align: center;
}

main {
    flex-grow: 1;
    width: 100%;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 0.5em;
}

.part-1 {
    margin-top: 1em;
    width: 100%;
    padding: 1.5em;
    background-color: var(--secondary-color);
    border-radius: 15px;
    box-shadow: 0 1px 5px rgba(0, 0, 0, 0.2);
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 0.5em;
}

#country {
    font-size: 0.7em;
}

.location,
.time-info {
    display: flex;
    flex-direction: row;
    gap: 1em;
}

.part-2 {
    width: 100%;
    padding: 2em 1em;
    background-color: var(--secondary-color);
    border-radius: 15px;
    box-shadow: 0 1px 5px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: row;
    justify-content: space-evenly;
    align-items: center;
    gap: 3em;
}

.weather-summary {
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.weather-details {
    display: flex;
    flex-direction: column;
    gap: 0.7em;
}

.weather-details div {
    display: flex;
    flex-direction: row;
    justify-content: left;
    align-items: center;
    gap: 0.2em;
}

.part-3 {
    margin-top: 0.5em;
    width: 100%;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 0.3em;
}

.wind-details {
    width: 100%;
    display: flex;
    flex-direction: row;
    justify-content: space-evenly;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5em;
}

.wind-details div {
    flex: 0 0 49%;
    height: 220px;
    padding: 1.5em;
    background-color: var(--secondary-color);
    border-radius: 15px;
    box-shadow: 0 1px 5px rgba(0, 0, 0, 0.2);
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.part-4 {
    margin-top: 0.5em;
    width: 100%;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 0.5em;
}

.air-quality {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: row;
    justify-content: space-evenly;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5em;
}

.air-quality div {
    flex: 0 0 49%;
    height: 200px;
    padding: 1.5em;
    background-color: var(--secondary-color);
    border-radius: 15px;
    box-shadow: 0 1px 5px rgba(0, 0, 0, 0.2);
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.air-molecules {
    width: 100%;
    padding: 1.2em;
    background-color: var(--secondary-color);
    border-radius: 15px;
    box-shadow: 0 1px 5px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: row;
    justify-content: space-evenly;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5em;
    line-height: 2.5em;
}

.air-molecules div {
    flex: 0 0 32%;
    text-align: center;
}

.part-5 {
    margin-top: 0.5em;
    width: 100%;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 0.5em;
}

.astronomy-details {
    width: 100%;
    display: flex;
    flex-direction: row;
    justify-content: space-evenly;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5em;
}

.astronomy-details div {
    flex: 0 0 49%;
    height: 220px;
    padding: 1em;
    background-color: var(--secondary-color);
    border-radius: 15px;
    box-shadow: 0 1px 5px rgba(0, 0, 0, 0.2);
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.part-6 {
    margin-top: 0.5em;
    width: 100%;
    padding: 0 0.5em;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 0.5em;
}

.forecast-details {
    overflow-x: auto;
    scrollbar-width: auto;
    scroll-snap-type: x mandatory;
    width: 100%;
    display: flex;
    flex-direction: row;
    justify-content: flex-start;
    align-items: center;
    gap: 0.5em;
}

.forecast-day {
    flex: 0 0 60%;
    margin-bottom: 0.5em;
    padding: 1.5em;
    background-color: var(--secondary-color);
    border-radius: 15px;
    box-shadow: 0 1px 5px rgba(0, 0, 0, 0.2);
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    scroll-snap-align: center;
}

.forecast-day div {
    margin-top: 1em;
    line-height: 25px;
}

footer {
    margin-top: 1.2em;
    width: 100%;
    padding: 1em 1em;
    background-color: var(--secondary-color);
    border-radius: 15px;
    box-shadow: 0 1px 5px rgba(0, 0, 0, 0.2);
    color: var(--text-color);
    text-align: center;
}

footer a {
    text-decoration: underline;
    color: var(--text-color);
    cursor: pointer;
}


::-webkit-scrollbar {
    height: 9px;
}

::-webkit-scrollbar-track {
    background-color: transparent;
}

::-webkit-scrollbar-thumb {
    cursor: grabbing;
    background-color: transparent;
    border-radius: 20px;
    border: 3px solid var(--secondary-color);
}

::-webkit-scrollbar-thumb:hover {
    background-color: var(--secondary-color);
}

::-webkit-scrollbar-button {
    display: block;
    width: 10px;
}

.big-icon {
    font-size: 55px !important;
}

.title {
    font-weight: bold;
}

.value {
    margin-top: 0.5em;
    font-size: 2em;
}


@media (max-width: 720px) {
    header {
        flex-direction: column;
    }

    input {
        width: 100%;
    }

    .part-2 {
        flex-direction: column;
        align-items: center;
        justify-content: center;
    }

    .wind-details div {
        flex: 0 0 100%;
        height: auto;
    }

    .air-quality div {
        flex: 0 0 100%;
        height: auto;
    }

    .air-molecules div {
        flex: 0 0 49%;
    }

    .astronomy-details div {
        flex: 0 0 100%;
        height: auto;
    }
}