/*
 * HTML5 Boilerplate
 *
 * 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,
button,
input,
select,
textarea {
    color: #222;
}
body {
    font-size: 1em;
    line-height: 1.4;
}
::-moz-selection {
    background: #ddd;
    color: #fff;
    text-shadow: none;
}
::selection {
    background: #ddd;
    color: #fff;
    text-shadow: none;
}
hr {
    display: block;
    height: 1px;
    border: 0;
    border-top: 1px solid #ccc;
    margin: 1em 0;
    padding: 0;
}
img {
    vertical-align: middle;
}
fieldset {
    border: 0;
    margin: 0;
    padding: 0;
}
textarea {
    resize: vertical;
}
textarea:focus {
    outline: 0;
}

/* ==========================================================================
   Chrome Frame prompt
   ========================================================================== */
.chromeframe {
    margin: 0.2em 0;
    background: #ccc;
    color: #000;
    padding: 0.2em 0;
}

/* ==========================================================================
   Web fonts
   ========================================================================== */
@font-face {
    font-family: 'janeaustennosecret';
    src: url('../fonts/janeaust-webfont.eot');
    src: url('../fonts/janeaust-webfont.eot?#iefix') format('embedded-opentype'),
         url('../fonts/janeaust-webfont.woff') format('woff'),
         url('../fonts/janeaust-webfont.ttf') format('truetype'),
         url('../fonts/janeaust-webfont.svg#janeaustennosecret') format('svg');
    font-weight: normal;
    font-style: normal;
}
/* fonts.com
font-family:'Adobe Caslon W01 It';
font-family:'AdobeCaslonW01-Regular';
*/

/* ==========================================================================
   Author's custom styles
   ========================================================================== */
html { 
    height: 100%; 
}
body { 
    min-height: 100%; 
}
html, body {
    overflow: hidden !important;
}
textarea {
    width: 410px;
    height: 100px;
    overflow: hidden;
    padding: 12px 10px;
    color: #aaa;
    font: normal 15px / 1.3em 'AdobeCaslonW01-Regular', Courier; 
    border: 0;
    resize: none;
    background: #fff;
}
a:focus {
    outline: 0;
}

.abs {
    position: absolute;
    margin: 0 0 0 0;
}
.abs-mid {
    left: 50%;
    top: 50%;
}

#safestyle-logo {
    position: absolute;
    bottom: 20px;
    right: 20px;
    z-index: 9;
} 

#location-layer {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 83px;
    z-index: 1;
    border: 0;
    overflow: hidden;
}

/* APP BAR */
#nav-bar {
    width: 83px;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 5;
    background: #F3F3F3 url(../img/bar-bg-right.png) no-repeat 103% center;
}
.js #nav-bar {
    visibility: hidden;
}
#nav-bar:after {
    content: "";
    width: 12px;
    height: 100%;
    position: absolute;
    right: -12px;
    top: 0;
    background: url(../img/bar-shadow.png) no-repeat right center;
    z-index: -1;
}
#inner-nav-bar-wrap {
    position: relative;
}
#inner-nav-bar-wrap.animate {
    -webkit-transition: .5s ease-out;
    -moz-transition: .5s ease-out;
    -ms-transition: .5s ease-out;
    -o-transition: .5s ease-out;
    transition: .5s ease-out;
}
#nav-bar nav {
    position: relative;
}

#nav-bar h1 {
    width: 100%;
    margin: 0;
    padding: 0;
    cursor: pointer;
    background: url(../img/bar-logo.gif) no-repeat center center;
}
.bar-knocker {
    display: block;
    margin-left: 5px;
}
.somewhere-else {
    width: 90px;
    margin: 0 0 0 6px;
    padding-bottom: 3px;
    background: url(../img/ir-take-me-somewhere-else_.png) no-repeat center -220px;
    border-bottom: 1px solid #fff;
}
/*.somewhere-else:hover {
    background-position: center -220px;
}*/
.somewhere-else:active {
    background-position: center top;
}
.somewhere-else-2 {
    width: 90px;
    top: 0;
    background: url(../img/ir-take-me-somewhere-else_.png) no-repeat center top;
}
.embed-link {
    width: 100%;
    height: 50px;
    display: block;
    background: url(../img/ir-embed-this-link.png) no-repeat 43% center;
    border-top: 1px solid #D8D8D8 !important;
    border-bottom: 1px solid #D8D8D8 !important;
    box-shadow: inset 0px 1px 0px #fff;
}
.return-to-door {
    width: 100%;
    padding-top: 10px;
    background: url(../img/ir-return-to-the-door.png) no-repeat center center;
    border-top: 1px solid #fff !important;
    box-shadow: inset 0px -1px 0px #ccc;
}

.embed-this {
    width: 436px;
    position: absolute;
    left: -500px;
    z-index: 4;
    padding: 10px 20px 14px 30px;
    background: #f3f3f3;
    border-radius: 0 4px 4px 0;
    -webkit-transition: left .2s ease-out;
    -moz-transition: left .2s ease-out;
    -ms-transition: left .2s ease-out;
    -o-transition: left .2s ease-out;
    transition: left .2s ease-out;
}
.embed-this.open {
    left: 83px;
}
.embed-this * {
    opacity: 0;
}
.embed-this.open * {
    opacity: 1;
}
.embed-this p {
    margin: 0.4em 0;
    color: #B4B4B4;
    font-weight: normal;
    font-size: 1.4em;
    line-height: 1.2em;
    font-family: 'Adobe Caslon W01 It';
}
.embed-this p span {
    color: #878787;
    font-family: 'janeaustennosecret';
}

#tooltip {
    width: 187px;
    position: absolute;
    left: -320px;
    top: 100px;
    z-index: 4;
    padding: 10px 20px 14px;
    cursor: pointer;
    background: #f3f3f3;
    border-radius: 4px;
    z-index: 4;
    -webkit-transition: left .3s ease-out;
    -moz-transition: left .3s ease-out;
    -ms-transition: left .3s ease-out;
    -o-transition: left .3s ease-out;
    transition: left .3s ease-out;
}
#tooltip.open {
    left: 100px;
}
#tooltip:before {
    content: "";
    width: 0px;
    height: 0px;
    position: absolute;
    top: 50%;
    left: -16px;
    margin-top: -8px;
    border: 8px solid transparent;
    border-right: 8px solid #f3f3f3;
}
#tooltip p {
    margin: 10px 0 0px;
    color: #B4B4B4;
    font: normal 1.2em / 1.2em 'Adobe Caslon W01 It';
}
#tooltip p span {
    color: #878787;
    font-family: 'janeaustennosecret';
}

#nav-bar h1,
.somewhere-else,
.return-to-door,
.somewhere-else-2 {
    display: block;
    height: 0;
    position: relative;
    -webkit-transition: left .5s ease-out, opacity .3s;
    -moz-transition: left .5s ease-out, opacity .3s;
    -ms-transition: left .5s ease-out, opacity .3s;
    -o-transition: left .5s ease-out, opacity .3s;
    transition: left .5s ease-out, opacity .3s;
}
.somewhere-else-2 {
    -webkit-transition: left .5s ease-out, opacity .45s;
}

.embed-link:hover,
.return-to-door:hover {
    background-color: #fff;
}

/* Door view */
.door-view #nav-bar h1,
.door-view .somewhere-else,
.door-view .return-to-door,
.door-view .somewhere-else-2 {
    left: -100px;
    opacity: 0;
}
.door-view .return-to-door {
    padding: 0;
    border: 0 !important;
}

/* Location view */
.location-view #nav-bar h1,
.location-view .somewhere-else,
.location-view .return-to-door,
.location-view .somewhere-else-2 {
    display: block;
    left: 0px;
    opacity: 1;
}
.location-view #nav-bar h1 {
    height: 60px;
}
.location-view .somewhere-else {
    height: 150px;
}
.location-view .somewhere-else-2 {
    position: absolute;
    margin-left: 6px;
    height: 90px;
    opacity: 1;
}
.somewhere-else-2:hover {
    opacity: 0;
}
.location-view .return-to-door {
    height: 110px;
}

/* Social */
.social {
    margin: 0;
    padding: 0;
    list-style: none;
    border-top: 1px solid #D8D8D8;
    box-shadow: 0px -1px 0px #fff;
}
.social li {
    width: 58px;
    height: 60px;
    margin: 0 12px;
    padding: 12px 0;
    display: block;
    border-top: 1px solid #D8D8D8;
}
.social li:first-child  {
    border-top: 0;
}
.social .twitter {
    height: 62px;
}
.social .gplus {
    height: 67px;
}
.social .stumble {
    height: 55px;
}
.wrap {
    width: 59px;
    margin: 0 auto;
}
.facebook .wrap {
    width: 44px;
}
.gplus .wrap {
    width: 50px;
} 
.stumble .wrap {
    width: 50px;
} 

/* DOOR LAYER */
#the-door-layer {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 3;
    overflow: hidden;
    background: #E3E3E3 url(../img/door-layer-bg.jpg) no-repeat 50% 50%;
    -webkit-background-size: 1729px 2075px;
    -webkit-transition: -webkit-transform 1.2s ease-in;
    -moz-transition: -moz-transform 1.2s ease-in;
    -ms-transition: -ms-transform 1.2s ease-in;
    -o-transition: -o-transform 1.2s ease-in;
    transition: transform 1.2s ease-in;
}
.logo {
    width: 325px;
    z-index: 2;
    margin: -310px 0 0 -119px;
    color: #eee;
    font-weight: normal;
    font-size: 55px;
    line-height: 55px;
    font-family: 'janeaustennosecret', Arial, sans-serif;
    letter-spacing: -1px;
}
.logo span {
    display: block;
}
.logo .the {
    font-size: 22px;
    position: absolute;
    top: -20px;
    left: 97px;
}
.logo .r {
    width: 50px;
    position: absolute;
    top: 10px;
    left: 270px;
    font-size: 40px;
    text-transform: uppercase;
}
.the-door-wrap {
    width: 407px;
    height: 549px;
    z-index: 1;
    margin: -226px 0 0 -158px;
    cursor: pointer;
    -webkit-transition: 1s;
    -moz-transition: 1s;
    -ms-transition: 1s;
    -o-transition: 1s;
    transition: 1s;
}
.the-door {
    width: 239px;
    height: 456px;
    top: 56px;
    left: 82px;
    display: block;
    background: url(../img/the-door.jpg) no-repeat center bottom;
}
.door-2 {
    width: 239px;
    height: 456px;
    position: absolute;
    top: 56px;
    left: 82px;
    display: block;
    background: url(../img/the-door.jpg) no-repeat center top;
    opacity: 1;
    -webkit-transition: .7s;
    -moz-transition: .7s;
    -ms-transition: .7s;
    -o-transition: .7s;
    transition: .7s;
}
.door-frame {
    top: 0;
    left: 0;
    pointer-events: none;
}
.door-top-beam {
    top: -288px;
    left: -69px;
}
.light-beam {
    top: 314px;
    right: 76px;
    opacity: 0;
    -webkit-transition: .5s .3s;
    -moz-transition: .5s .3s;
    -ms-transition: .5s .3s;
    -o-transition: .5s .3s;
    transition: .5s .3s;
}
.frame-inner-beam {
    right: 66px;
    top: 29px;
    opacity: 0;
    -webkit-transition: .5s .3s;
    -moz-transition: .5s .3s;
    -ms-transition: .5s .3s;
    -o-transition: .5s .3s;
    transition: .5s .3s;
}
#the-door-layer:before {
    content: "";
    width: 421px;
    height: 421px;
    position: absolute;
    left: 83px;
    bottom: 0;
    background: url(../img/vignette-left.png) no-repeat left bottom; 
}
#the-door-layer:after {
    content: "";
    width: 421px;
    height: 421px;
    position: absolute;
    right: 0;
    bottom: 0;
    background: url(../img/vignette-right.png) no-repeat left bottom; 
}
.hover-hand {
    position: absolute;
    left: -90px;
    top: 20%;
    width: 250px;
    height: 250px;
    opacity: 0;
    pointer-events: none;
    border: 6px solid #3C2117;
    border-radius: 50%;
    background: url(../img/hover-hand.jpg) no-repeat center top;
    -webkit-transition: .5s;
    -moz-transition: .5s;
    -ms-transition: .5s;
    -o-transition: .5s;
    transition: .5s;
}
.hover-hand-2 {
    position: absolute;
    left: -90px;
    top: 20%;
    width: 250px;
    height: 250px;
    opacity: 0;
    pointer-events: none;
    border: 6px solid #3C2117;
    border-radius: 50%;
    background: url(../img/hover-hand.jpg) no-repeat center bottom;
    -webkit-transition: .5s;
    -moz-transition: .5s;
    -ms-transition: .5s;
    -o-transition: .5s;
    transition: .5s;
}

.the-door-wrap:hover .door-2 {
    opacity: 0;
}
.the-door-wrap:hover .hover-hand {
    opacity: 1;
    top: 15%;
}
.the-door-wrap:hover .hover-hand-2 {
    top: 15%;
}
.the-door-wrap:hover .light-beam,
.the-door-wrap:hover .frame-inner-beam {
    opacity: 1;
}

#the-door-layer.grow {
    -webkit-transform: scale(1.1);
    -moz-transform: scale(1.1);
    -ms-transform: scale(1.1);
    -o-transform: scale(1.1);
    transform: scale(1.1);
}
.push .hover-hand {
    opacity: 0;
}
.push .hover-hand-2 {
    opacity: 1;
}

#white-fade-layer {
    width: 100%;
    height: 100%;
    position: absolute;
    left: 83px;
    top: 0;
    background: #fff url(../img/ajax-loader.gif) no-repeat center center;
    z-index: 3;
    pointer-events: none;
}

#toggle-mute {
    width: 15px;
    height: 15px;
    display: block;
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 9999;
    background: url(../img/toggle-audio.png) no-repeat center top;
    opacity: .7;
    -webkit-transition: opacity .6s;
    -moz-transition: opacity .6s;
    -ms-transition: opacity .6s;
    -o-transition: opacity .6s;
    transition: opacity .6s;
}
#toggle-mute.muted {
    background-position: center bottom;
    opacity: .3;
}
#toggle-mute:hover {
    opacity: .9;
}


.guide {
    width: 100%;
    height: 1px;
    left: 0;
    background: red;
    z-index: 99999;
    pointer-events: none;
}

/* ==========================================================================
   BOTTOM BANNER (Visible only to UK Audience)
   ========================================================================== */
#safestyle-bottom-link {
    opacity: 0;
    position: absolute;
    bottom: 22px;
    right: -520px;
    width: 511px;
    height: 59px;
    margin: auto;
    z-index: 2;
    background: url(../img/ssukdoorpanel.png);
    -webkit-transition: opacity .4s .4s;
    transition: opacity .4s .4s;
}

#safestyle-bottom-link.show-banner {
    right: 10px;
    opacity: 1;
}

/* ==========================================================================
   FALLBACKS
   ========================================================================== */
.no-opacity .hover-hand,
.no-opacity .hover-hand-2,
.no-opacity .light-beam,
.no-opacity .frame-inner-beam {
    display: none;
}
.no-opacity .the-door-wrap:hover .hover-hand,
.no-opacity .the-door-wrap:hover .hover-hand-2,
.no-opacity .the-door-wrap:hover .light-beam,
.no-opacity .the-door-wrap:hover .frame-inner-beam {
    display: block;
}

.no-opacity .door-2 {
    display: block;
}
.no-opacity .the-door-wrap:hover .door-2 {
    display: none;
}

.lt-ie9 textarea {
    height: 140px !important;
}
.lt-ie9 .somewhere-else-2:hover {
    background-position: center -220px;
}

.lt-ie8 .gplus {
    display: none !important;
}
.lt-ie8 .twitter .wrap {
   padding-left: 7px;
}
.lt-ie8 .embed-this p {
    padding-top: 20px;
    line-height: 1em;
}

/* touch devices */
.touch #the-door-layer {
    background-image: none;
}
.touch .the-door-wrap {
    width: 90%;
    height: auto;
    position: absolute;
    margin: auto 0 auto 59px;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
}
.touch #the-door-touch-fallback {
    width: 85%;
    max-width: 426px;
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    margin: auto;
}
.touch #the-door-layer:before,
.touch #the-door-layer:after {
    background-image: none;
}

/* ==========================================================================
   Helper classes
   ========================================================================== */
.ir {
    background-color: transparent;
    border: 0;
    overflow: hidden;
    /* IE 6/7 fallback */
    *text-indent: -9999px;
}
.ir:before {
    content: "";
    display: block;
    width: 0;
    height: 100%;
}
.hidden {
    display: none !important;
    visibility: hidden;
}
.visuallyhidden {
    border: 0;
    clip: rect(0 0 0 0);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
}
.visuallyhidden.focusable:active,
.visuallyhidden.focusable:focus {
    clip: auto;
    height: auto;
    margin: 0;
    overflow: visible;
    position: static;
    width: auto;
}
.invisible {
    visibility: hidden;
}

/* ==========================================================================
   EXAMPLE Media Queries for Responsive Design.
   Theses examples override the primary ('mobile first') styles.
   Modify as content requires.
   ========================================================================== */
@media only screen and (max-height: 760px) {
    .location-view #nav-bar h1 {
        display: none;
    }
} 
@media only screen and (max-height: 670px) {
    .location-view .social .gplus {
        display: none;
    }
}  
@media only screen and (max-height: 580px) {
    .location-view .social .stumble {
        display: none;
    }
} 
@media only screen and (max-height: 500px) {
    .location-view #embed-link {
        display: none;
    }
    .location-view .social {
        border-bottom: 1px solid #D8D8D8 !important;
    }
}
@media only screen and (max-height: 440px) {
    .location-view .social .facebook {
        display: none;
    }
} 
@media only screen and (max-height: 400px) {
    .door-view #embed-link {
        display: none;
    }
    .door-view .social {
        border-bottom: 1px solid #D8D8D8 !important;
    }
    .door-view .social:after {
        content: "";
        width: 100%;
        height: 1px;
        position: absolute;
        bottom: -1px;
        background-color: #fff;
    }
}
@media only screen and (max-height: 360px) {
    .location-view .social .twitter {
        display: none;
    }
    .location-view .social {
        border-bottom: 0 !important;
    }
    .location-view #nav-bar .return-to-door {
        border-top: 0 !important;
    }
} 
@media only screen and (max-height: 350px) {
    .door-view .social .gplus {
        display: none;
    }
}
@media only screen and (max-height: 280px) {
    .location-view #nav-bar .somewhere-else {
        height: 49px;
        margin-bottom: 20px;
        background-position: center bottom;
    }
    .location-view #nav-bar .somewhere-else-2 {
        display: none;
    }
}
@media only screen and (max-height: 260px) { 
    .door-view .social .stumble {
        display: none;
    }
}
@media only screen and (max-height: 200px) {
    .location-view #nav-bar .return-to-door {
        display: none;
    }
    .location-view .social {
        border: 0 !important;
    }
}
@media only screen and (max-height: 180px) {
    .door-view .social .facebook {
        display: none;
    }   
} 

@media only screen and (max-width: 620px) {
    #safestyle-bottom-link {display: none}
} 

@media only screen and (-webkit-min-device-pixel-ratio: 1.5),
       only screen and (min-resolution: 144dpi) {
    /* Style adjustments for high resolution devices */
}

/* ==========================================================================
   Print styles.
   Inlined to avoid required HTTP connection: h5bp.com/r
   ========================================================================== */
@media print {
    * {
        background: transparent !important;
        color: #000 !important; /* Black prints faster: h5bp.com/s */
        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 for images, or javascript/internal links
     */

    .ir a:after,
    a[href^="javascript:"]:after,
    a[href^="#"]:after {
        content: "";
    }

    pre,
    blockquote {
        border: 1px solid #999;
        page-break-inside: avoid;
    }

    thead {
        display: table-header-group; /* h5bp.com/t */
    }

    tr,
    img {
        page-break-inside: avoid;
    }

    img {
        max-width: 100% !important;
    }

    @page {
        margin: 0.5cm;
    }

    p,
    h2,
    h3 {
        orphans: 3;
        widows: 3;
    }

    h2,
    h3 {
        page-break-after: avoid;
    }
}