body {
    font-family: 'Open Sans', sans-serif;
    color: #3c3c3c;
    background-image: url(/src/images/vattenyta.jpg);
    background-repeat: no-repeat;
    background-size: contain;
    background-position: 0px 85px;
}

header {
    height: 100px;
    position: fixed;
    width: 100%;
    background-color: rgba(255, 255, 255, 0.90);
    z-index: 200;
    box-shadow: 0 5px 10px #00000020;
}

.menu {
    display: flex;
    justify-content: space-between;
    max-width: 1024px;
    margin: 0px auto;
    align-items: baseline;
    padding: 20px;
}

.allButFooter {
    min-height: calc(100vh - 170px);
}

p {
    font-weight: 300;
    font-size: 0.9em;
    line-height: 1.6em;
    padding-bottom: 1.2em;
}

h1 {
    color: #00547C;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1em;
    line-height: 1.6em;
}

a {
    color: #3c3c3c;
}


/* Navigation styles */

nav ul {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
}

#burgermenu {
    display: none;
}

nav a {
    text-decoration: none;
    color: #707070;
    font-size: 0.9em;
    font-weight: 500;
    padding: 5px;
}

nav li {
    padding-left: 30px;
}

nav a:link, nav a:visited {
    color: #3c3c3c;
}

nav a:hover, nav a:active {
    color: #FD9C00;
}

.thisPage {
    border-bottom-color: #FD9C00;
    border-bottom-width: 2px;
    border-bottom-style: solid;
}

/* Main styles */

main {
    width: 100%;
    padding: 350px 20px 50px 20px;
}

.content {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    justify-content: space-between;
    align-items: flex-start;
    max-width: 1024px;
    margin: 0 auto;
}

.contentImg {
    max-width: 400px;
    height: auto;
    margin-right: 4em;
}

.historyImg {
    width: 31%;
    margin-top: 30px;
}

#contentLogo {
    width: 50px;
    margin-right: 20px;
}

.thermiaContainer {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
}

.contactImg {
    display: flex;
    justify-content: space-between;
    margin-right: 50px;
}

.contactImg img, .contactImg p {
    margin-left: 20px;
    max-width: 220px;
}

i {
    color: #FD9C00;
    margin-right: 10px;
}

.refGrid {
    max-width: 1024px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-start;
}

.refItem img {
    width: 100%;
}

.refItem {
    position: relative;
    width: 32%;
    margin-bottom: 18px;
}

.refItem h1 {
    font-size: 1em;
    color: #fff;
    margin-bottom: 8px;
}

.refItem p {
    font-size: 0.9em;
    line-height: 1.4em;
    padding-bottom: 0px;
    color: #fff;
}

.refTxt {
    position: absolute;
    width: 100%;
    bottom: 0px;
    background-color: #00557cc9;
    padding: 10px;
    display: none;
}

.refItem img:hover + .refTxt {
    display: block;
}


/* Footer styles */

footer {
    background-color: #00547C;
    width: 100%;
    height: 170px;
}

.footerContainer {
    max-width: 1024px;
    margin: 0 auto;
    padding: 20px;
    text-align: right;
}

footer a, footer p {
    color: #fff;
    text-decoration: none;
    font-size: 0.9em;
    line-height: 2em;
    font-weight: 500;
    padding-bottom: 0;
}

footer img {
    width: 100px;
    margin-left: 10px;
    margin-top: 40px;
}

#wm {
    padding-right: 0px;
}

/* Media queries */

@media (max-width: 1200px) {
    main {
        padding-top: 300px;
    }
}

@media (max-width: 1024px) {

    main {
        padding-top: 250px;
    }

    .contentImg {
        max-width: 400px;
        margin-right: 2em;
    }
}

@media (max-width: 800px) {

    main {
        padding-top: 240px;
    }

    body {
        background-position: 0px 110px;
    }

    .contactImg {
        display: block;
    }

    .content-start {
        flex-direction: column-reverse;
    }

    .contentImg {
        align-self: flex-end;
        margin: 50px 0 0 0;
        max-width: 300px;
    }

}

@media (max-width: 740px) {

    #burgermenu {
        display: inline-block;
    }

    nav ul {
        display: none; 
        position: absolute;
        padding: 1rem;
        top: 80px;
        right: 0px;
        background-color: #ffffffe3;
        box-shadow: -5px 5px 8px #00000020;
    }
    
    nav a {
        text-decoration: none;
        color: #707070;
        padding: 0px;
    }
    
    nav li {
        padding: 20px;
        text-align: right;    }

    main {
        padding-top: 250px;
    }

    body {
        background-position: 0px 100px;
    }

    .refItem {
        position: relative;
        width: 48%;
        margin-bottom: 18px;
    }

    .historyImg {
        width: 48%;
        margin-top: 30px;
    }

    .historyImgCont {
        flex-wrap: wrap;

    }
}

@media (max-width: 575px) {

    main {
        padding-top: 200px;
    }

    .contactImg {
        display: flex;
        margin: 0px;
        padding: 0px;
    }

    .contactContent {
        flex-direction: column-reverse;
    }
    
    .contactImg img, .contactImg p {
        margin: 20px 10px 0 0;
        max-width: 220px;
    }

}

@media (max-width: 500px) {
    .historyImg {
        width: 100%;
    }

    main {
        padding-top: 200px;
    }

    .contentImg {
        align-self: center;
        margin: 30px 0 0 0;
        min-width: 100%;
    }

    .refItem {
        width: 100%;
    }

    .contactImg {
        display: block;
    }

    .contactImg img, .contactImg p {
        margin: 0;
        max-width: 100%;
    }
}

@media (max-width: 325px) {
    
    header {
        height: 140px;
        width: 100%;
    }

    .menu {
        flex-direction: column;
        align-items: center;
    }

    .logobox img {
        max-width: 100%;
        margin-bottom: 25px;
    }

    main {
        padding-top: 230px;
    }

    body {
        background-position: 0px 160px;
    }
}
