* {
    box-sizing: border-box;
}

/* Set the background color for the entire page */
body {
    background-image: url(../images/background.webp);
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    font-family: 'Roboto Condensed', sans-serif;
    height: 100vh;
}

/* Style the header */
h1 {
    text-align: center;
    margin: 1em auto;
    font-size: 4rem;
    text-shadow: 0 0 5px rgba(255, 255, 255, 0.3), 0 0 10px rgba(255, 255, 255, 0.3), 0 0 15px rgba(255, 255, 255, 0.3);
    color: rgba(255, 255, 255, 0.7);
    padding: 10px;
    border-radius: 10px;
}

/* Style the location search bar */

.search-bar {
    position: relative;
    display: flex;
    min-width: 100px;
    justify-content: center;
}

.search-bar input {
    border: 1px solid grey;
    border-radius: 5px;
    width: 100%;
    max-width: 400px;
    padding: 2px 23px 2px 30px;
    outline: 0;
    background-color: #f5f5f5;
    text-align: center;
    font-size: 1.5em;
}

/*Style the location search button*/

.search-buttons {
    position: relative;
    display: flex;
    min-width: 100px;
    max-width: 400px;
    align-items: center;
    justify-content: center;
    margin: 10px auto;
}

.search-buttons button {
    border: none;
    background-color: transparent;
    font-family: inherit;
    font-size: 1.5em;
    margin: 0 auto;
    padding: 0;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    align-self: start;

    background-color: #fff;
    color: rgb(63, 63, 63);
    border-radius: 8px;

    min-width: 15ch;
    min-height: 45px;

    text-align: center;
    line-height: 1.1;

    transition: 220ms all ease-in-out;
}

.search-buttons button:hover {
    background-color: rgb(218, 218, 218);
}

.search-buttons button:focus {
    outline-style: solid;
    outline-color: transparent;
    box-shadow: 0 0 0 1px rgb(26, 26, 26);
}



/* Style the location name */
#location-name {
    text-align: center;
    font-size: 2em;
    margin-top: 1em;
}

/* Style forecast blocks */

.current-weather {
    background-color: rgba(255, 255, 255, 0.3);
    padding: 10px;
    border-radius: 10px;
    text-align: center;
    margin: 20px auto;
    width: 50%;
}

#sunrise-icon {
    display: none;
    width: 50px;
}

#four-day-forecast {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
}

.forecast-block {
    background-color: rgba(255, 255, 255, 0.3);
    padding: 10px;
    border-radius: 10px;
    flex-basis: auto;
    text-align: center;
    margin: 10px;
}

#forecastDay1,
#forecastDay2,
#forecastDay3,
#forecastDay4 {
    font-weight: bold;
}

@media (min-width: 530px) {

    #four-day-forecast {
        display: flex;
        justify-content: center;
    }

    .forecast-block {
        background-color: rgba(255, 255, 255, 0.3);
        padding: 10px;
        border-radius: 10px;
        flex-basis: auto;
        text-align: center;
        margin: 10px;
        width: 40%;
    }

}

@media (min-width: 700px) {
    .current-weather {
        display: flex;
        align-items: center;
        width: -moz-fit-content;
        width: fit-content;
        font-size: 1.2em;
    }

    #sunrise-icon {
        display: inline;
    }

    #location-name {
        margin: 1em auto;
    }

    .column1,
    .column2 {
        margin: 0 10px;
    }

    .column2 {
        padding-bottom: 1.2em;
    }

    #four-day-forecast {
        display: flex;
        justify-content: center;
    }

    .forecast-block {
        background-color: rgba(255, 255, 255, 0.3);
        padding: 10px;
        border-radius: 10px;
        flex-basis: auto;
        text-align: center;
        margin: 20px;
        width: 40%;
        font-size: 1.2em;
    }
}

@media (min-width: 800px) {
    #four-day-forecast {
        padding: 0 20%;
    }

}

@media (min-width: 1200px) {
    body {
        font-size: 1.3em;
    }

    .search-buttons button {
        margin: 0 10px;
    }

    #four-day-forecast {
        padding: 0;
    }

    .forecast-block {
        margin: 10px;
        width: -moz-fit-content;
        width: fit-content;
        max-width: 20%;
    }
}

/* Error message */

#error-message {
    background-color: red;
    color: white;
    padding: 10px;
    max-width: 50%;
    text-align: center;
    margin: auto;
}

.hidden {
    display: none;
}