/*! HTML5 Boilerplate v6.0.1 | MIT License | https://html5boilerplate.com/ */

/*
 * What follows is the result of much research on cross-browser styling.
 * Credit left inline and big thanks to Nicolas Gallagher, Jonathan Neal,
 * Kroc Camen, and the H5BP dev community and team.
 */

/* ==========================================================================
   Base styles: opinionated defaults
   ========================================================================== */

html {
    color: #222;
    font-size: 1em;
    line-height: 1.4;
}

/*
 * Remove text-shadow in selection highlight:
 * https://twitter.com/miketaylr/status/12228805301
 *
 * Vendor-prefixed and regular ::selection selectors cannot be combined:
 * https://stackoverflow.com/a/16982510/7133471
 *
 * Customize the background color to match your design.
 */

::-moz-selection {
    background: #b3d4fc;
    text-shadow: none;
}

::selection {
    background: #b3d4fc;
    text-shadow: none;
}

/*
 * A better looking default horizontal rule
 */

hr {
    display: block;
    height: 1px;
    border: 0;
    border-top: 1px solid #ccc;
    margin: 1em 0;
    padding: 0;
}

/*
 * Remove the gap between audio, canvas, iframes,
 * images, videos and the bottom of their containers:
 * https://github.com/h5bp/html5-boilerplate/issues/440
 */

audio,
canvas,
iframe,
img,
svg,
video {
    vertical-align: middle;
}

/*
 * Remove default fieldset styles.
 */

fieldset {
    border: 0;
    margin: 0;
    padding: 0;
}

/*
 * Allow only vertical resizing of textareas.
 */

textarea {
    resize: vertical;
}

/* ==========================================================================
   Browser Upgrade Prompt
   ========================================================================== */

.browserupgrade {
    margin: 0.2em 0;
    background: #ccc;
    color: #0f2136;
    padding: 0.2em 0;
}

/* ==========================================================================
   Rdy Creative - Thomas Ling
   ========================================================================== */
.sprite{
    background-image:url('../img/sprite.png');
    background-size:350px 350px;
}

.centerer{
    width:100%;
    text-align:center;
    float:left;
}

.videoWrapper {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 */
    padding-top: 25px;
    height: 0;
}
.videoWrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

@font-face {
    font-family: 'gotham_mediumregular';
    src: url('../fonts/gotham-medium-webfont.eot');
    src: url('../fonts/gotham-medium-webfont.eot?#iefix') format('embedded-opentype'),
         url('../fonts/gotham-medium-webfont.ttf') format('truetype'),
         url('../fonts/gotham-medium-webfont.svg#gotham_mediumregular') format('svg');
    font-weight: normal;
    font-style: normal;

}

body,html{
    height:100%;
    min-width:360px;
    min-height:480px;
}



h1{
    font-family: 'Open Sans', sans-serif;
    font-weight:800;
    font-style:italic;
    color:#f8fae4;
    font-size:100px;
    letter-spacing:-5px;
    line-height:100px;
    padding:0px;
    margin-bottom:60px;
}

h2{
    font-family: 'Roboto Condensed', sans-serif;
    font-size:25px;
    color:#0f2136;
    letter-spacing:4px;
    margin-bottom:40px;
    font-style:italic;
}

h3{
    font-family: 'Roboto Condensed', sans-serif;
    font-size:25px;
    letter-spacing:4px;
    font-style:italic;
    padding-top:0px;
    margin-top:0px;
}

p, input, select, textarea{
    font-family:'Roboto', sans-serif;
    color:#0f2136;
    font-size:18px;
    line-height:30px;
}

p.small-text{
    font-size: 14px;
    text-align: center;
    color: #898989;
    
    margin-top: 1px;
    padding: 10px;
}

.mobile-only{
    display:none!important;
}

.divider{
    width: 100%;
    border-top: 1px solid #e6e6e6;
    position: relative;
    float: left;
}

/*////////////TRANSITION Elements////*/

.loading-sprite{
    width:200px;
    height:75px;
    overflow:hidden;
    position:absolute;
    top:100%;
    left:100%;
    margin-left:-100px;
    margin-top:-50px;
    background-image:url('../img/loading-sprite.png');
    background-size:200px auto;
    background-position-y:0;
    z-index:100;
}

.loading-animation{
    width:75%;
    height:100%;
    position:fixed;
    z-index:100;
    pointer-events:none;
    opacity:0;
    -webkit-transition: opacity 0.3s; /* Safari */
    transition: opacity 0.3s;
}

.loading-animation.active{
    opacity:1;
    -webkit-transition: opacity 0.3s; /* Safari */
    transition: opacity 0.3s;
}

.loading-centerer{
    position:absolute;
    height:50%;
    width:50%;
    left:0;
    top:0;
}

.loading-sprite.project{
    width:100px;
    height:40px;
    margin-left:-50px;
    margin-top:-20px;
    background-size:100px;
    opacity:0;
    -webkit-transition: opacity 0.3s; /* Safari */
    transition: opacity 0.3s;
    pointer-events:none;
    background-image:url('../img/loading-sprite-projects.png');
}

.loading-sprite.project.active{
    opacity:1;
    -webkit-transition: opacity 0.3s; /* Safari */
    transition: opacity 0.3s;
}

#transition-elements-container{
    display:none;
    position:fixed;
    width:75%;
    height:100%;
    z-index:5;
    overflow:hidden;
    top:0;
}

#pattern-preload{
    background-image:url('../img/trans-1.png');
    position:absolute;
    bottom:0;
    left:0;
}

#bg-preload-1{
    background-image:url('../img/bg-abstract.png');
}

#bg-preload-2{
    background-image:url('../img/bg-abstract-2.png');
}

#bg-preload-3{
    background-image:url('../img/bg-abstract-3.png');
}

#bg-preload-4{
    background-image:url('../img/bg-abstract-4.png');
}

#t-black{
    background-color:#0f2136;
    width:100%;
    height:100%;
    position:absolute;
    top:0;
    left:-100%;
}

#t-white-1{
    /*background-color:#ed4871;*/
    background-color:#fdfdfd;
    width:100%;
    height:26%;
    position:absolute;
    top:0;
    left:-100%;
    background-image:url('../img/trans-1.png');
}

#t-white-2{
    /*background-color:#e7b645;*/
    background-color:#fdfdfd;
    width:100%;
    height:26%;
    position:absolute;
    top:25%;
    left:-100%;
    background-image:url('../img/trans-1.png');
    background-position:25% auto;
}

#t-white-3{
    /*background-color:#48bd98;*/
    background-color:#fdfdfd;
    width:100%;
    height:26%;
    position:absolute;
    top:50%;
    left:-100%;
    background-image:url('../img/trans-1.png');
}

#t-white-4{
    /*background-color:#4ab1df;*/
    background-color:#fdfdfd;
    width:100%;
    height:25%;
    position:absolute;
    top:75%;
    left:-100%;
    background-image:url('../img/trans-1.png');
}

.t-block{
    width:100%;
    height:100%;
    display:block;
    position:absolute;
    top:0;
    left:-100%;
    background-color:#fdfdfd;
    z-index:5;
    background-image:url('../img/trans-1.png');
}


/*/////////////////////////////Columns*/

.column{
    position:relative;
    display: table-cell;
    vertical-align: middle;
}

.forty{
    width:40%;
}

.fifty{
    width:45%;
}

.fifty.services{
    padding-right:5%;
    float:left;
}


.services .what-container{
    width:35%;
    position:relative;
    float:left;
    margin-right:5%;
    margin-top:20px;
}

.services .what-text{
    width:60%;
    position:relative;
    float:right;
}

.services img{
    width:100%;
}

.project-text{
    width:30%;
    float:left;
}

.project-image{
    width:65%;
    float:right;
    margin-top:25px;
}

.sixty{
    width:55%;
    padding-right:5%;
}

.sixty.alt{
    padding-right:0%;
    padding-left:5%;
}

.hundred{
    width:100%;
    display:block;
    float:left;
}


/*///////////////////////////Buttons*/

button:active, button:focus{
    outline:none;
}

.btn-interactive{
    font-family:'gotham_mediumregular';
    font-weight:700;
    font-size:14px;
    color:#f8fae4;
    background-color:#0f2136;
    padding:18px 22px 18px 22px;
    letter-spacing:1px;
    border:none;
    text-decoration:none;
    -webkit-transition: all 0.2s; /* Safari */
    transition: all 0.2s;
}

.btn-interactive:hover{
    cursor:pointer;
    background-color:#f8fae4;
    color:#0f2136;
    -webkit-transition: all 0.2s; /* Safari */
    transition: all 0.2s;
}

.btn-interactive.internal-link, a.btn-interactive{
    line-height:50px;
}


/*/////////////////////////Content areas*/

.cover h1, .cover h2, .cover p{
    width:800px;
    margin-top:0px;
}

h2 .highlight{
    background-color:#0f2136;
    padding:5px 8px;
    color:#f8fae4;
}

.content-area #rdy-logo{
    width:338px;
    height:30px;
    position:absolute;
    background-position:0 -31px;
    top:90px;
    left:5%;
    z-index:2;
    cursor:pointer;
    -webkit-transition: all 0.2s; /* Safari */
    transition: all 0.2s;
}

.scroll-1{
    position:absolute;
    left:5%;
    bottom:50px;
}

.full-height{
    height:100%;
}

.outer {
  display: table;
  position: absolute;
  height: 100%;
  width: 90%;
  margin-left:5%;
}

.middle {
  display: table-cell;
  vertical-align: middle;
}

.inner {
  margin-left: auto;
  margin-right: auto;
  /*whatever width you want*/
}

.content-area{
    background-color:#fdfdfd;
    width:75%;
    display:block;
    position:relative;
    float:left;
}

.spacer{
    width:100%;
    position:relative;
    float:left;
    height:60px;
}

.spacer.half{
    height:30px;
}

.content-area .container{
    width:90%;
    position:relative;
    display:block;
    float:left;
    /*padding-top:80px;*/
    margin-left:5%;
}

/*/////////////////////////Colour styles*/

.pink .highlight, .pink h3, .pink .highlight{
    color:#ed4871;
}

.pink .btn-interactive:hover{
    background-color:#ed4871;
}

.pink-bg{
    background-color:#ed4871;
    background-image:url('../img/bg-abstract.png');
    background-size:cover;
}

.pink-bg p{
    color:#fff;
}

.yellow .highlight, .yellow h3, .yellow .highlight{
    color:#e7b645;
}

.yellow .btn-interactive:hover{
    background-color:#e7b645;
}

.yellow-bg{
    background-color:#e7b645;
    background-image:url('../img/bg-abstract-2.png');
    background-size:auto 100%;
}

.yellow-bg p{
    color:#fff;
}

.green .highlight, .green h3, .green .highlight{
    color:#48bd98;
}

.green .btn-interactive:hover{
    background-color:#48bd98;
}

.green-bg{
    background-color:#48bd98;
    background-image:url('../img/bg-abstract-3.png');
    background-size:auto 100%;
}

.green-bg p{
    color:#fff;
}

.blue .highlight, .blue h3, .blue .highlight{
    color:#4ab1df;
}

.blue .btn-interactive:hover{
    background-color:#4ab1df;
}

.blue-bg{
    background-color:#4ab1df;
    background-image:url('../img/bg-abstract-4.png');
    background-size:auto 100%;
}

.blue-bg p{
    color:#fff;
}




/*/////////////////////////NAVIGATION*/


#main-nav{
    background-color:#0f2136;
    width:25%;
    height:100%;
    display:block;
    position:fixed;
    right:0px;
    top:0px;
}

#main-nav ul{
    list-style:none;
    padding:0px;
    font-family:'gotham_mediumregular', sans-serif;
    letter-spacing:1px;
    text-align:right;
    font-weight:700;
}

#main-nav a{
    text-decoration: none;
    color:#adaf9f;
    display: block;     
    position: relative;   
    float:right; 
    clear:both;
    z-index: 1;     
    padding: 5px;     
    margin: -5px; 
    -webkit-transition: opacity 0.2s; /* Safari */
    transition: opacity 0.2s;
}

#main-nav a:hover{
    color:#f8fae4;
    -webkit-transition: opacity 0.2s; /* Safari */
    transition: opacity 0.2s;
}


#main-nav li span{
    position:relative;
    clear:both;
    float:right;
}

#main-nav .primary{
    font-size:14px;
    margin-right:15%;
    margin-top:80px;
    line-height:50px;
}

.primary a{
    height:50px;
    overflow:hidden;
}

.primary a li.active{
    margin-top:-50px;
    -webkit-transition: all 0.2s; /* Safari */
    transition: all 0.2s;
}

#main-nav .secondary{
    font-size:11px;
    right:15%;
    bottom:30px;
    line-height:40px;
    position:absolute;
}

.secondary a{
    height:40px;
    overflow:hidden;
}

.secondary a li.active{
    margin-top:-40px;
    -webkit-transition: all 0.2s; /* Safari */
    transition: all 0.2s;
}

.primary a li, .secondary a li{
    -webkit-transition: all 0.2s; /* Safari */
    transition: all 0.2s;
}

.secondary .copyright{
    font-size:10px;
    color:#3f5165;
    float:right;
    clear:both;
}




/*/////////////////////////////////Projects*/

.bottom-sticky-button{
    width: 75%;
    background-color: #4ab1df;
    /*background-image:url('../img/bg-abstract.png');*/
    background-size:200px auto;
    z-index: 4;
    position: fixed;
    bottom: -80px;
    text-align: center;
    vertical-align: middle;
    padding-top: 18px;
    padding-bottom: 18px;
    font-family: 'Roboto Condensed', sans-serif;
    font-size: 18px;
    color: #f8fae4;
    font-style: italic;
    font-size: 25px;
    letter-spacing: 4px;
    -webkit-transition: all 0.2s; /* Safari */
    transition: all 0.2s;
    cursor:pointer;

}

.bottom-sticky-button.active{
    bottom: 0px;
    border-top:2px solid #d5d7c4;
    -webkit-transition: all 0.2s; /* Safari */
    transition: all 0.2s;
}

.bottom-sticky-button:hover{
    border-top:2px solid #d5d7c4;
    background-color:#f8fae4;
    color:#4ab1df;
    -webkit-transition: all 0.2s; /* Safari */
    transition: all 0.2s; 
}

.btn-sticky.pink{
    background-color:#ed4871;
}

.btn-sticky.pink:hover{
    color:#ed4871;
    background-color:#f8fae4;
}

.btn-sticky.yellow{
    background-color:#e7b645;
}

.btn-sticky.yellow:hover{
    color:#e7b645;
    background-color:#f8fae4;
}

.btn-sticky.green{
    background-color:#48bd98;
}

.btn-sticky.green:hover{
    color:#48bd98;
    background-color:#f8fae4;
}


.project-tile{
    position:relative;
    float:left;
    text-align:center;
    overflow:hidden;
    background-color:#f8fae4;
}

.project-tile.half{
    width:100%;
    height:50%;
    display:table;
}

.project-tile.quarter{
    width:50%;
    height:50%;
    display:table;
}


.helper{
    height:100%;
    display:table-cell;
    vertical-align:middle;
}

.project-tile img{
    vertical-align:middle;
    height:60%;
    max-height:300px;
    opacity:0.8;
    pointer-events:none;
    transition: opacity 0.2s;
}

.project-thumb{
    display:table;
    width:100%;
    height:100%;
    opacity:1;
    -webkit-transition: all 0.2s; /* Safari */
    background-blend-mode: screen;
    pointer-events:none;
}

.project-thumb h3{
    color:#fff;
    margin-bottom:10px;
}

.project-thumb h4{
    margin-top:0;
    margin-bottom:0;
    color:#fff;
    font-family: 'Roboto Condensed', sans-serif;
    font-style:italic;
}

.project-tile:hover .project-thumb{
    background-color:#000!important;
    transition: all 0.2s;
}

.project-tile:hover img{
    opacity:1;
    transition: opacity 0.2s;
}

.project-title{
    background-size:cover;
}


.project-title img {
    max-width: 350px;
    width: 90%;
    height: auto;
}


.project-title .forty{
    text-align:center;
}

.project-title h3{
    font-size:40px;
    margin:0px;
    padding:0px;
    line-height:50px;
}

.project-description p{
    color:#adaf9f;
}





/*/////////////////////////////////Contact form*/
.contact{
    /*background-color:#ebedda;*/
    background-color:#09131e;
    color:#fff;
    /*background-image:url("../img/tic-tac-toe.png");*/
}


.form-block{
    position:relative;
    float:left;
    width:75%;
}



.contact p{
    color:#909090;
}

.contact a{
    text-decoration:none;
    -webkit-transition: color 0.2s; /* Safari */
    transition: color 0.2s;

}

.contact a:hover{
    text-decoration:underline;
    color:#fff;
    -webkit-transition: color 0.2s; /* Safari */
    transition: color 0.2s;

}

#error_message h4, #success_message h4{
    font-family: 'Roboto Condensed', sans-serif;
    margin-bottom:0px;
}


#error_message{
    padding:5px 20px;
    margin-bottom:40px;
}

.pink #error_message{
    background-color:#ed4871;
}

.yellow #error_message{
    background-color:#e7b645;
}

.green #error_message{
    background-color:#48bd98;
}

.blue #error_message{
    background-color:#4ab1df;
}

#error_message ul{
    font-family: 'Roboto Condensed', sans-serif;
    display:none!important;
}

#error_message p{
    font-size:12px;
    color:#fff;
}

label{
    position:relative;
    float:left;
    clear:both;
    font-family:'Roboto',sans-serif;
    font-weight:700;
    font-size:18px;
    margin-bottom:10px;
}

input[type="text"], textarea, select{
    position:relative;
    float:left;
    clear:both;
    width:100%;
    margin-bottom:45px;
    background:none;
    border-style:none;
    border-bottom:2px solid #2b3440 ;
    outline:none;
    padding-bottom:5px;
    font-size:16px;
    -webkit-transition: all 0.2s; /* Safari */
    transition: all 0.2s;
    color:#909090!important;
}

select{
    background:none;
    -webkit-appearance: none; /* add this */
}

input[type="text"]:focus, textarea:focus{
    border-bottom:2px solid #d6d8c2;
    -webkit-transition: all 0.2s; /* Safari */
    transition: all 0.2s;
}

textarea{
    height:200px;
}

.submit{
    position:relative;
    float:right;
    display:block;
    width:49px;
    height:40px;
    border-style:none;
    background:none;
    background-image:url('../img/sprite.png');
    -webkit-transition: all 0.2s; /* Safari */
    transition: all 0.2s;
}

.form-block h3{
    margin-top:0px;
}

.pink .submit{
    background-position:0 -90px;
    background-size:350px 350px;
}

.yellow .submit{
    background-position:-50px -90px;
    background-size:350px 350px;
}

.green .submit{
    background-position:-100px -90px;
    background-size:350px 350px;
}

.blue .submit{
    background-position:-150px -90px;
    background-size:350px 350px;
    -webkit-appearance: none; /* add this */
}



.contact .submit:hover{
    filter:brightness(3);
    cursor:pointer;
    -webkit-transition: all 0.2s; /* Safari */
    transition: all 0.2s;
}


@media only screen and (max-width:1600px){
    .project-text{
        width:100%;
    }

    .project-image{
        width:100%;
}

@media only screen and (max-width: 1180px) {
    .cover h1, .cover h2, .cover p{
        width:680px;
    }

    h1{
        font-size:80px;
        line-height:80px;
    }

    .secondary .copyright{
        font-size:8px;
    }

    h3, .bottom-sticky-button{
        font-size:22px;
    }

    .bottom-sticky-button{
        padding-top:12px;
        padding-bottom:12px;
    }

    .project-title h3{
        font-size:30px;
        line-height:40px;
    }


    .column p{
        font-size:15px;
        line-height:20px;
    }

    .spacer{
        height:60px;
    }

    .form-block{
        width:100%;
    }
}

@media only screen and (max-width: 1000px) {

    .content-area #rdy-logo{
        top:50px;
        width:158px;
        height:30px;
        background-position:0 0;
    }

    #transition-elements-container{
        width:100%;
    }


    .scroll-1{
        bottom:30px;
    }

    .hamburger{
        position:fixed;
        right:30px;
        top:50px;
        z-index:6;
        padding:0!important;
    }



    #main-nav{
        width:300px;
        right:-300px;
        -webkit-transition: all 0.2s; /* Safari */
        transition: all 0.2s;
        z-index:5;
    }

    .primary a{
        height:60px;
    }

    .secondary a{
        
    }

    .primary a li.active{
        margin-top:-60px;
        -webkit-transition: all 0.2s; /* Safari */
        transition: all 0.2s;
    }

    .secondary a li.active{
        margin-top:-25px;
        -webkit-transition: all 0.2s; /* Safari */
        transition: all 0.2s;
    }

    #main-nav.is-active{
        right:0px;
        -webkit-transition: all 0.2s; /* Safari */
        transition: all 0.2s;
    }

    #main-nav .primary{
        font-size:20px;
        margin-top:100px;
        line-height:60px;
        margin-right:30px;
    }

    #main-nav .secondary{
        font-size:16px;
        right:30px;
        bottom:20px;
        line-height:25px;
        position:absolute;
    }

    .secondary .copyright{
        font-size:10px;
        color:#6d6d6d;
        display:none;
    }

    .content-area, .bottom-sticky-button{
        width:100%;
    }

    .loading-animation{
        width:100%;
    }

    .project-tile.half{
        width:100%;
        height:34%;
    }

    .project-tile.quarter{
        width:100%;
        height:25%;
    }




}

@media only screen and (max-width: 800px) {
    .cover h1, .cover h2, .cover p{
        width:100%;
    }

    h1{
        font-size:80px;
        line-height:80px; 
        letter-spacing:-2px;
        margin-bottom:35px;
    } 

    .what-text h3{
        text-align:left;
    }


}

@media only screen and (max-width: 800px) {

    h1{
        font-size:60px;
        line-height:60px; 
        letter-spacing:-2px;
        margin-bottom:40px;
    }

    h2{
        font-size:18px;
        margin-bottom:20px;
    }

    p{
        font-size:15px;
    }

    .contact p{
        line-height:25px;
    }

    .column p{
        font-size:13px;
    }
}

@media only screen and (max-width: 480px) {
    .desktop-only{
        display:none!important;
    }

    .mobile-only{
        display:block!important;
    }

    .pink-bg, .yellow-bg, .green-bg, .blue-bg{
        
    }

    h1{
        font-size:50px!important;
        line-height:50px!important; 
        letter-spacing:-2px;
        margin-bottom:25px;
    }

    h2{
        letter-spacing:2px;
    }

    h3{
        text-align:center;
        margin-top:10px;
    }

    .spacer{
        height:30px;
    }

    .spacer.half{
    height:15px;
}

    .column, .column.alt{
        width:100%;
        padding:0;
        display:block;
        position:relative;
        float:left;
    }

    .project-title img{
        width:80%;
        padding-bottom:20px;
        padding-top:20px;
    }

}

@media only screen and (max-height: 730px) {
    h1{
        font-size:70px;
        line-height:70px; 
        letter-spacing:-2px;
        margin-bottom:35px;
        margin-top:40px!important;
    }

    h2{
        margin-bottom:20px;
    }

    textarea{
        height:100px;
    }

    
}

@media only screen and (max-height: 480px) {
    

    #main-nav .primary{
    font-size:14px;
    margin-right:30px;
    margin-top:100px;
    line-height:30px;
    }

    .primary a{
        height:30px;
        overflow:hidden;
    }

    .primary a li.active{
        margin-top:-30px;
        -webkit-transition: all 0.2s; /* Safari */
        transition: all 0.2s;
    }

    #main-nav .secondary{
        font-size:11px;
        right:30px;
        bottom:10px;
        line-height:40px;
        position:absolute;
    }

    .secondary a{
        height:30px;
        overflow:hidden;
    }

    .content-area{
        width:100%;
    }

    .cover h1, .cover h2, .cover p{
        width:100%;
    }

    .form-block{
        width:100%;
    }

    h1{
        font-size:50px;
        line-height:50px; 
        letter-spacing:-2px;
        margin-bottom:30px;
        margin-top:40px!important;
    }

    h2{
        font-size:20px;
        margin-bottom:20px;
    }

    p{
        font-size:15px!important;
    }
    .column p{
        font-size:13px!important;
    }

    .scroll-1{
        display:none;
    }

    #rdy-logo{
        top:50px!important;
    }

    .spacer{
        height:30px;
    }

    label{
        font-size:15px;
        margin-bottom:15px;
    }

    input[type="text"], textarea, select{
        margin-bottom:15px;
        padding-bottom:5px;
        font-size:13px;
    }

    .project-title .forty{
        text-align:left;
    }

}









/* ==========================================================================
   Helper classes
   ========================================================================== */

/*
 * Hide visually and from screen readers
 */

.hidden {
    display: none !important;
}

/*
 * Hide only visually, but have it available for screen readers:
 * https://snook.ca/archives/html_and_css/hiding-content-for-accessibility
 *
 * 1. For long content, line feeds are not interpreted as spaces and small width
 *    causes content to wrap 1 word per line:
 *    https://medium.com/@jessebeach/beware-smushed-off-screen-accessible-text-5952a4c2cbfe
 */

.visuallyhidden {
    border: 0;
    clip: rect(0 0 0 0);
    -webkit-clip-path: inset(50%);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
    white-space: nowrap; /* 1 */
}

/*
 * Extends the .visuallyhidden class to allow the element
 * to be focusable when navigated to via the keyboard:
 * https://www.drupal.org/node/897638
 */

.visuallyhidden.focusable:active,
.visuallyhidden.focusable:focus {
    clip: auto;
    -webkit-clip-path: none;
    clip-path: none;
    height: auto;
    margin: 0;
    overflow: visible;
    position: static;
    width: auto;
    white-space: inherit;
}

/*
 * Hide visually and from screen readers, but maintain layout
 */

.invisible {
    visibility: hidden;
}

/*
 * Clearfix: contain floats
 *
 * For modern browsers
 * 1. The space content is one way to avoid an Opera bug when the
 *    `contenteditable` attribute is included anywhere else in the document.
 *    Otherwise it causes space to appear at the top and bottom of elements
 *    that receive the `clearfix` class.
 * 2. The use of `table` rather than `block` is only necessary if using
 *    `:before` to contain the top-margins of child elements.
 */

.clearfix:before,
.clearfix:after {
    content: " "; /* 1 */
    display: table; /* 2 */
}

.clearfix:after {
    clear: both;
}

/* ==========================================================================
   EXAMPLE Media Queries for Responsive Design.
   These examples override the primary ('mobile first') styles.
   Modify as content requires.
   ========================================================================== */

@media only screen and (min-width: 35em) {
    /* Style adjustments for viewports that meet the condition */
}

@media print,
       (-webkit-min-device-pixel-ratio: 1.25),
       (min-resolution: 1.25dppx),
       (min-resolution: 120dpi) {
    /* Style adjustments for high resolution devices */
}

/* ==========================================================================
   Print styles.
   Inlined to avoid the additional HTTP request:
   http://www.phpied.com/delay-loading-your-print-css/
   ========================================================================== */

@media print {
    *,
    *:before,
    *:after {
        background: transparent !important;
        color: #0f2136 !important; /* Black prints faster:
                                   http://www.sanbeiji.com/archives/953 */
        box-shadow: none !important;
        text-shadow: none !important;
    }

    a,
    a:visited {
        text-decoration: underline;
    }

    a[href]:after {
        content: " (" attr(href) ")";
    }

    abbr[title]:after {
        content: " (" attr(title) ")";
    }

    /*
     * Don't show links that are fragment identifiers,
     * or use the `javascript:` pseudo protocol
     */

    a[href^="#"]:after,
    a[href^="javascript:"]:after {
        content: "";
    }

    pre {
        white-space: pre-wrap !important;
    }
    pre,
    blockquote {
        border: 1px solid #999;
        page-break-inside: avoid;
    }

    /*
     * Printing Tables:
     * http://css-discuss.incutio.com/wiki/Printing_Tables
     */

    thead {
        display: table-header-group;
    }

    tr,
    img {
        page-break-inside: avoid;
    }

    p,
    h2,
    h3 {
        orphans: 3;
        widows: 3;
    }

    h2,
    h3 {
        page-break-after: avoid;
    }
}
