html{
    --green: #459260;
    --orange: #FA6646;
    --grey: #646464;
    --font-title: 'Alegreya';
    --font-text: 'DIN Pro';
}

body{
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    width: 94%;
}

h1, h2{
    font-family: var(--font-title);
    font-weight: 800;
    font-size: 4em;
    margin: 0;
    color: var(--green);
}

h2{
    font-size: 2.5em;
    margin: 0.5em 0;
    text-align: center;
}

h3{
    font-family: var(--font-text);
    font-size: 2em;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 500;
    align-self: flex-start;
}

p.headline{
    font-family: var(--font-text);
    font-size: 1.3em;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 500;
    margin: 0.1em 0;
}

p{
    font-family: var(--font-text);
    font-size: 1.1em;
    margin: 0.5em 0;
}

header{
    width: 100%;
    margin-top: 5em;
    display: grid;
    align-items: stretch;
    grid-gap: 20px;
    grid-template-columns: 1fr 0.5fr 0.8fr;
    grid-template-rows: 0.5fr 1fr 0.4fr;
    grid-template-areas: 
        " headerA headerB headerB "
        " headerA headerD headerE "
        " headerC headerD headerE ";
    img:not(.img-logo){
        width: 100%;
        height: 100%;
        object-fit: cover;
    }
}

#headerA{
    grid-area: headerA;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    height: 100%;
    width: 100%;
    a{
        position: absolute;
        top: -55px;
    }
}

#headerB{
    grid-area: headerB;
    p{
        font-size: 1.8em;
        font-weight: 500;
        margin: 0;
    }
}

#headerC{
    grid-area: headerC;
    img{object-fit: cover;}
}

#headerD{
    grid-area: headerD;
}

#headerE{
    grid-area: headerE;
    position: relative;
    .newsletter-cta{
        position: absolute;
        bottom: 10px;
    }
}

section{
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 1.8em;
    width: 100%;
}

p.region-text{
    width: 90%;
    text-align: center;
    font-size: 1em;
}

.unit-housing{
    display: flex;
    flex-direction: row;
    margin: 1em;
    gap: 30px;
}

.housing-img{
    min-width: 400px;
}

.housing-img img{
    width: 100%;
}

.unit-housing p.localisation{
    font-family: var(--font-title);
    color: var(--green);
    font-weight: 800;
    font-size: 1.5em;
    margin: 0 0 0.5em 0;
}

.unit-housing .type{
    font-family: var(--font-text);
    font-weight: 600;
    font-size: 1.1em;
    text-transform: uppercase;
}

.star_unit-housing{
    box-shadow: 5px 5px 5px #efefef;
    border-radius: 25px;
    background: url('/star-housing-bg.jpg'), #FBFBFB;
    background-repeat: no-repeat;
    background-size: 62%;
    background-position: right;
}

select, input{
    border: 1px solid #efefef;
    background-color:white;
    color: var(--green);
    font-family: var(--font-text);
    font-weight: 500;
    border-radius: 25px;
}

#region-dropdown select{
    font-size: 1.1em;
    padding: 0.5em 1.5em;
    box-shadow: 5px 5px 5px #efefef;
}

.newsletter-cta{
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 20px;
    font-size: 1.1em;
    background: var(--green);
    padding: 0.5em 1em 0.5em 2em;
    margin: 0.5em;
    p{
        text-align: center;
        width: 85%;
        color: white;
        font-size: 0.95em;
        margin: 0.1em;
    }
}

.newsletter-cta select, .newsletter-cta input{
    padding: 5px 8px;
    font-size: 0.9em;
    width: 300px;
}

.newsletter-cta input{
    outline: #459260;
}

fieldset{
    border: none;
}

.stay-options{
    font-family: var(--font-text);
    list-style: none;
    text-transform: uppercase;
    font-weight: 500;
    font-size: 1.1em;
    color: var(--grey);
    padding: 0;
    li{
        margin: 0.7em 0;
        display: grid;
        grid-template-columns: 60px 210px 150px 80px;
        align-items: center;
        column-gap: 5px;
        a{
            justify-content: center;
            text-align: center;
        }
    }
}

span.sold{
    color: white;
    padding: 0.2em 0.3em;
    background-color: var(--orange);
    margin-right: 0.3em;
    border-radius: 5px;
    text-align: center;
}

span.price{
    color: var(--orange);
}

footer{
    display: grid;
    grid-gap: 1em;
    grid-template-columns: 1fr 0.5fr 0.8fr;
    align-items: end;
    background-color: var(--green);
    width: 100%;
    margin-top: 2em;
    color: white;
    font-family: var(--font-text);
    img:not(.logo){
        width: 100%;
    }
    .newsletter-cta{
        position: relative;
    }
}

.footer-logo{
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-around;
    position: relative;
    a{
        transform: translateY(-30px);
    }
}

.cta{
    text-transform: uppercase;
    font-size: 0.8em;
    padding: 0.2em 0.5em;
    background-color: transparent;
    border-radius: 5px;
    font-family: var(--font-text);
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
}

.cta.cta-white{
    border: solid 1px white;
    color: white;
}

.cta.cta-orange{
    border: solid 1px var(--orange);
    color: var(--orange);
}


@media (max-width: 1115px) {
    header{
        grid-template-columns: 1fr 0.8fr;
        grid-template-areas: 
        " headerA headerB "
        " headerA headerE "
        " headerC headerE ";
        #headerB{
            h1{
                font-size: 2.4em;
            }
            p{
                font-size: 1.5em;
            }
        }
        #headerD{
            display: none;
        }
    }
    .newsletter-cta select, .newsletter-cta input{
        width: auto;
    }
}

@media (max-width: 900px) {
    .unit-housing{
        flex-direction: column;
        align-items: center;
    }
    footer{
        grid-template-columns: 1fr 0.5fr;
    }
    .footer-img{
        display: none;
    }
}

@media (max-width: 717px) {
    header{
        grid-template-columns: 0.8fr 1fr;
    }
    #headerE img{
        display: none;
    }
    #headerE .newsletter-cta{
        padding: 0;
        margin: 0;
        height: 100%;
        bottom: 0;
        position: relative;
    }
}

@media (max-width: 500px) {
    h2{
        font-size: 2em;
    }
    header{
        grid-template-columns: 1fr;
        grid-template-rows: 0.6fr 15% 290px;
        grid-template-areas: 
        " headerA "
        " headerB "
        " headerE ";
        #headerB{
            h1{
                font-size: 2em;
            }
            p{
                font-size: 1.5em;
            }
        }
        #headerC{
            display: none;
        }
    }
    .housing-img{
        min-width: auto;
    }
    .stay-options li{
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-content: center;
        width: auto;
        text-align: center;
    }
    footer{
        grid-template-columns: 1fr;
        grid-template-rows: 1fr 0.2fr;
        padding: 0 0.5em;
    }
}
