/* FONTS */
@font-face {
  font-family: 'Cerebri';
  font-weight: 300;
  font-display: fallback;
  src: url('../fonts/CerebriSans-Light.ttf') format('truetype');
}

@font-face {
  font-family: 'Cerebri';
  font-weight: 400;
  font-display: fallback;
  src: url('../fonts/CerebriSans-Book.otf') format('opentype');
}

@font-face {
  font-family: 'Cerebri';
  font-weight: 500;
  font-display: fallback;
  src: url('../fonts/CerebriSans-Medium.ttf') format('truetype');
}

@font-face {
  font-family: 'Cerebri';
  font-weight: 700;
  font-display: fallback;
  src: url('../fonts/CerebriSans-Bold.ttf') format('truetype');
}

/* GENERAL */
body{
    font-family: 'Cerebri', sans-serif;
    font-size: 22px;
    font-weight: 300;
    box-sizing: border-box;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

section{overflow: hidden;}

body, a{
    color: #8A91A1;
}

a{text-decoration: none;}

a:hover{color: #262626;}

img{max-width: 100%;}

h1, h2, h3, h4, h5, .heading{
    color: #262626;
}

h2, h3, h4, .heading{
    margin: 15px 0;
}

h1{
    font-weight: 700;
    font-size: 55px;
    margin-top: 0;
}

h2{font-size: 46px; margin-bottom: 20px;}
h3{font-size: 36px; margin-bottom: 30px;}
h4{font-size: 32px;}
h5{font-size: 22px; margin: 30px 0;}

p{
    line-height: 1.4;
    margin-top: 0;
}

.center{
    text-align: center;
    margin-left: auto;
    margin-right: auto;
}

.content{
    box-sizing: border-box;
    padding: 15px 30px;
    width: 100%;
    max-width: 1300px;
    margin: 0 auto;
}

.text--white,
.text--white h1,
.text--white h3,
a.text--white:hover{color: #fff;}

.text--white svg{fill: #fff;}

.flex{display: flex;}
.flex-row{flex-direction: row;}
.flex-wrap{flex-wrap: wrap;}
.flex-nowrap{flex-wrap: nowrap;}
.flex-align--center{align-items: center;}
.space-between{justify-content: space-between;}
.justify-center{justify-content: center;}
.flex-grow{flex-grow: 1;}

.flex-block--forty{
    width: calc(40% - 20px);
    flex-basis: calc(40% - 20px);
}

.flex-block--sixty{
    width: calc(60% - 20px);
    flex-basis: calc(60% - 20px);
}

.flex-block--half{
    width: calc(50% - 20px);
    flex-basis: calc(50% - 20px);
}

.flex-block--half--auto{
    width: auto;
    flex-basis: auto;
    max-width: calc(50% - 20px);
}

.flex-block--third{
    width: 33.333%;
    flex-basis: 33.333%;
}

.flex-block--third--auto{
    width: auto;
    flex-basis-auto;
    max-width: calc(33.333% - 20px);
}

/* HEADER */
nav{
    font-size: 15px;
    font-weight: 500;
}
nav ul{
    display: flex;
    flex-flow: row wrap;
    list-style: none;
    padding: 0;
    margin: 0;
}

nav a{
    display: inline-block;
    letter-spacing: .5px;
}

nav a:after{
    background-color: #fff;
    content: "";
    display: block;
    height: 2px;
    margin-top: 3px;
}

nav a:hover:after{background-color: #1ECCC8;}

/* CONTENT */
.smaller-font{font-size: 18px;}

.content--experience{
    font-size: 18px;
    padding-bottom: 70px;
}

.content--experience .heading{
    font-size: 16px;
    font-weight: 500;
    border-bottom: 1px solid #edeeef;
    padding-bottom: 15px;
    margin: 20px 0 50px;
}
.content--experience p:not(.heading){
    width: 215px;
    margin-left: auto;
    margin-right: auto;
}

.content--experience img{
    max-height: 38px;
}

.content--services{
    font-size: 20px;
    width: 900px;
    max-width: 100%;
    margin: 0 auto 170px;
}
.header-with-image img{margin-right: 20px;}

.content--work{
    position: relative;
}
.overlay-link{
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}
.content--work:nth-child(odd){
    padding-top: 30px;
}
.content--work:nth-child(even){
    padding-top: 55px;
    padding-bottom: 55px;
}

.content--work h3{
    margin-bottom: 20px;
    margin-top: 0;
}

.content--work p{
    font-size: 18px;
    width: 260px;
    max-width: 100%;
}

.content--work p:last-child{
    margin-top: 30px;
    margin-bottom: 0;
}
.content--work:nth-child(even) a{
    color: #262626;
    font-weight: 500;
}

.content--work a svg{
    width: 12px;
    height: 12px;
}

.accordion-block:not(.accordion){
    border-top: 1px solid #edeeef;
    margin-top: 50px;
}

.accordion-block{
    align-items: flex-start;
    border-bottom: 1px solid #edeeef;
    display: flex;
    flex-flow: row nowrap;
    padding: 50px 0;
}

a.highlight{
    color: #19B5B0;
    text-decoration: underline;
}
.highlight{color: #19B5B0;}

.accordion-block h3{
    flex: 0 0 250px;
    font-size: 30px;
    margin: 0;
}

.summary,
.accordion-content{
    flex: 1 1 auto;
}

.summary,
.accordion-content,
.accordion-close{
    position: relative;
    top: 2px;
}

.accordion:not(.is-open) .accordion-close svg{
    transform: rotate(45deg);
}

.accordion-close{
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 55px;
    cursor: pointer;
    text-align: center;
}

.accordion-close svg{
    width: 25px;
    height: 25px;
    transition: all .2s ease-in-out;
}

.accordion h3,
.accordion .summary{cursor: pointer;}

.accordion-block .summary p:last-child,
.accordion-block .accordion-content p:last-child{margin: 0;}

.accordion:not(.is-open) .accordion-content{display: none;}
.accordion.is-open .summary{display: none;}

form{
    font-size: 18px;
}

.fsError{margin-bottom: 20px;}

.fsRow{margin-bottom: 24px;}

.fsRowHalf{
    display: flex;
    flex-flow: row wrap;
    justify-content: space-between;
}

.fsRowHalf > div{
    flex: 0 1 calc(50% - 12px);
}
form input,
form textarea,
form select,
form fieldset{
    width: 100%;
    padding: 13px 15px;
    box-sizing: border-box;
    border: 1px solid #b2bfbc;
    border-radius: 5px;
}

form input,
form textarea{
    color: #8A91A1;
}

.fsSubmit{text-align: center;}
form .fsSubmitButton{
    cursor: pointer;
    width: auto;
    border: 0;
}

form .fsSubmitButton:hover{
    background: #16a19c;
    transform: translateY(-1.5px);
}

form select{
    color: #262626;
    cursor: pointer;
    text-indent: 8px;
    background: transparent;
    height: 80px;
    font-size: 26px;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

.fsRow svg{
    width: 20px;
    height: 20px;
    position: absolute;
    right: 23px;
    top: 50%;
    margin-top: -10px;
    transform: rotate(90deg);
    z-index: -1;
}
.fsRow svg path{
    fill: #262626;
}

form .fsSubmitButton{
    background: #19B5B0;
    color: #fff;
    padding: 15px 77px;
}

fieldset legend{padding: 0 10px;}
.fieldset-content label{
    display: block;
}
.fieldset-content label:not(:last-child){
    margin-bottom: 10px;
}

fieldset input{
    width: auto;
    margin-right: 10px;
}

.fsValidationError input,
.fsValidationError textarea,
.fsValidationError fieldset{
    border-color: #ff6262;
}

.fsError + #requiredFieldsError{display: block !important;}
.fsError{display: none;}

#requiredFieldsError{
    background: #ffe9e9;
    border-top: 3px solid #ff6262;
    color: #262626;
    padding: 10px 15px;
    margin-bottom: 10px;
}

.validationRequired{
    display: none;
    color: #ff6262;
    padding-top: 10px;
}

.fsValidationError .validationRequired{display: block;}

footer{
    background: #20223e;
    font-size: 16px;
    margin-top: auto;
}

footer img{display: block;}

main ul{
    margin: 0;
    list-style-position: inside;
    padding: 0;
}

.content--support{
    font-size: 18px;
    width: 950px;
    max-width: 100%;
    margin: 0 auto 50px;
    line-height: 1.5;
}

.padded-section{
    padding-top: 60px;
    padding-bottom: 60px;
}

/* case study block*/
.case-study-banner{max-width: 1450px;}

.case-study-banner--text{
    padding: 30px;
    align-self: center;
    overflow: hidden;
}

/* MEDIA QUERIES */
@media only screen and (min-width: 1300px) {
    .left-bound, .right-bound{
        position: relative;
        margin: auto;
    }
    
    .left-bound .content,
    .right-bound .content{
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        width: 100%;
        display: flex;
        flex-flow: row nowrap;
    }
    
    .left-bound .content{justify-content: flex-end;}
    
    .right-bound > .flex-block--half:not(.content){margin-left: auto;}
}
@media only screen and (max-width: 1299px) {
    .left-bound,
    .right-bound{
        display: flex;
        flex-flow: row wrap;
        justify-content: space-between;
        align-items: center;
    }
    .left-bound .flex-block--half .flex-block--half,
    .right-bound .flex-block--half .flex-block--half{
        width: 100%;
    }
}

@media only screen and (min-width: 1000px){
    .case-study-banner--img{left: -120px;}
    .case-study-banner > div{
        border-width:60px 0 0 120px;
    }
}

@media only screen and (min-width: 801px) and (max-width: 999px){
    .case-study-banner--img{left: -60px;}
    .case-study-banner > div{
        border-width:60px 0 0 60px;
    }
}

@media only screen and (min-width: 900px) and (max-width: 1100px){
    h1{font-size: 45px;}
}

@media only screen and (min-width: 768px) and (max-width: 899px){
    h1{font-size: 35px;}
}

@media only screen and (min-width: 801px) {
    .hide-size-desktop{display: none;}
    .hero-block p{max-width: 320px;}

    /* header */
    nav li:not(:first-child){
        margin-left: 30px;
    }

    nav a{
        padding: 10px 5px;
    }
    
    /* body */
    .case-study-banner > div{
        border-style:solid;
        border-color:#fff;
    }
    .case-study-banner .flex-block--half{
        width: calc(50% - 30px);
        flex-basis: calc(50% - 30px);
    }
    
    .case-study-banner--img{
        position: relative;
        top:-60px;
    }
    
    /* case study page */
    .desktop-left-aligned{padding-left: 0;}
    .desktop-right-aligned{padding-right: 0;}

}
@media only screen and (max-width: 800px) {
    .hide-size-tablet{display: none;}
    
    .tablet-center{
        margin-left: auto;
        margin-right: auto;
        text-align: center;
    }
    
    /* header */
    #nav-toggle{cursor: pointer;}
    #nav-wrap:not(.is-open) nav{display: none;}
    #nav-wrap li{flex: 1 1 100%;}
    
    .is-open nav{
        background: rgba(0,0,0,.3);
        bottom: 0;
        top: 0;
        left: 0;
        right: 0;
        position: absolute;
    }
    nav ul{
        background: #fff;
        display: inline-block;
        bottom: 0;
        top: 0;
        right: 0;
        padding: 20px;
        position: absolute;
    }
    
    nav:before{
        content: "X";
        position: absolute;
        right: 150px;
        color: #262626;
        top: 15px;
        border: 2px solid #262626;
        border-radius: 50px;
        height: 20px;
        width: 20px;
        text-align: center;
        line-height: 20px;
        cursor: pointer;
        background: #fff;
    }
    
    nav ul a{padding: 3px 10px;}

    /* general */
    h1{font-size: 36px;}
    
    main .flex-row:not(.flex-nowrap){
        flex-wrap: wrap;
    }
    
    main .flex-row:not(.flex-nowrap) > *:not(#nav-wrap){
        width: 100%;
        flex-basis: 100%;
    }
    
    .hero-block{text-align: center;}
    
    .content--work{text-align: center;}
    .content--work div p{
        margin-left: auto;
        margin-right: auto;
    }
    
    .content--work .flex-block--forty{
        margin-bottom: 40px;
        order: 1;
    }
    .content--work .flex-block--sixty{order: 2;}
    
    /* experience */
    .content--experience .flex-block--third:not(:last-child){margin-bottom: 20px;}
    
    /* footer */
    footer .content{
        flex-wrap: wrap;
    }
    footer .content > div{
        flex: 0 1 47%;
    }
    
    /* contact */
    .accordion-block{
        flex-wrap: wrap;
        justify-content: space-between;
    }
    
    .summary,
    .accordion-content{
        flex: 1 1 100%;
        order: 3;
    }
    
    .accordion-block h3{padding-bottom: 30px;}
}

@media only screen and (max-width: 650px) {
    .flex-block--half--auto,
    .flex-block--third--auto{
        max-width: 100%;
    }
    
    .flex-block--third--auto + .flex-block--third--auto{
        margin-top: 50px;
    }
}