html {
    /*background: #ffffff url('../img/primary-bg.png') repeat center top;*/
    overflow-x:hidden;
}

/** {*/
    /*-webkit-tap-highlight-color: rgba(0, 0, 0, 0);*/
/*}*/

html.ie8 {
    overflow-x: visible;
}

html > * {
    overflow: visible;
}


html.is-preview body {
/*    margin-top:60px;*/
}

html.is-preview div#preview-bar {
    background: black;
    height: 60px;
    margin-left: -2000px;
    margin-right: -2000px;
}


/* Body */

html.touch body {
    overflow: hidden;
}

body {
    color: #313337;
    font-family: 'Segoe UI', "Helvetica Neue", Helvetica, 'Arial', sans-serif;
    font-size: 12px;
    line-height: 20px;
    background:  white;
    width: 100%;
    max-width: 1024px;
    margin: 0 auto;
    -moz-box-shadow: 0px 1px 50px rgba(0, 0, 0, 0.5);
    -webkit-box-shadow: 0px 1px 50px rgba(0, 0, 0, 0.5);
    box-shadow: 0px 10px 50px rgba(0, 0, 0, 0.5);
    zoom: 1;
    -webkit-font-smoothing: antialiased;
}

.no-js body {
    display: block;
}

/* WP Core Styling*/

.alignnone {
    margin: 5px 20px 20px 0;
}

.aligncenter, div.aligncenter {
    display:block;
    margin: 5px auto 5px auto;
}

.alignright {
    float:right;
    margin: 5px 0 20px 20px;
}

.alignleft {
    float:left;
    margin: 5px 20px 20px 0;
}

.aligncenter {
    display: block;
    margin: 5px auto 5px auto;
}

a img.alignright {
    float:right;
    margin: 5px 0 20px 20px;
}

a img.alignnone {
    margin: 5px 20px 20px 0;
}

a img.alignleft {
    float:left;
    margin: 5px 20px 20px 0;
}

a img.aligncenter {
    display: block;
    margin-left: auto;
    margin-right: auto
}

.wp-caption {
    /*background: #fff;*/
    /*border: 1px solid #f0f0f0;*/
    max-width: 96%;
    /* Image does not overflow the content area */
    padding: 5px 3px 10px;
    text-align: center;
}

.wp-caption.alignnone {
    margin: 5px 20px 20px 0;
}

.wp-caption.alignleft {
    margin: 5px 20px 20px 0;
}

.wp-caption.alignright {
    margin: 5px 0 20px 20px;
}

.wp-caption img {
    border: 0 none;
    height: auto;
    margin:0;
    max-width: 98.5%;
    padding:0;
    width: auto;
}

.wp-caption p.wp-caption-text {
    font-size:11px;
    line-height:17px;
    margin:0;
    padding:0 4px 5px;
}


/* Fallback shadow image for body. Paddings are set dynamically in script.js. */
.ie8 body, .ie7 body {
    max-width: 1024px;
    background: transparent url(../img/ie-body-bg.png) top center repeat-y;
}

@media only screen and (min-width: 768px) and (max-width: 959px) {
    
    body {
        width: 768px;
    }
}

@media screen and (max-width: 767px) {
    
    body {
        width: 100%;
    }
}

body > div#top-bar {
    overflow: visible;
    position: relative;
    background: #313337 url(../img/top-bar-bg.png) left top repeat;
    width: 100%;
    height: 7px;
}

body a, body a:visited {
    text-decoration: none;
    color: #f48a00;
    -webkit-transition: color 0.3s ease;
    -ms-transition: color ease 0.3s;
    -moz-transition: color 0.3s ease;
    -o-transition: color 0.3s ease;
    transition: color 0.3s ease;
}

body a:hover {
    text-decoration: underline;
    color: #f48a00;
}

body .divider {
    margin-top: 0;
    margin-bottom: 0;
}

img.styled-image {
    background: white;
    overflow: hidden;
    border: 1px solid white;
    box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.25);
    -moz-box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.25);
    -webkit-box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.25);
}

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

    .one_half, .one_third, .two_third, .three_fourth, .one_fourth, .one_fifth, .two_fifth, .three_fifth, .four_fifth, .one_sixth, .five_sixth {
        margin-left: 0;
    }
}

/* Page Styling */

.main {
    background: white;
}

.main.darker {
    background: #f2f2f4;
}

.main.has-sidebar {
    background: #ffffff url(../img/page-with-sidebar-bg.png) center top repeat-y;
    position: relative;
    overflow: hidden;
}

.main div.divider {
    width: 1024px;
    height: 1px;
    background: #e8e8e8;
/*    background: url(../img/divider-bg.png) top left repeat-x;*/
    margin-left: -42px;
    margin-top: 0;
    margin-bottom:0;
    display: inline-block;
}

.main.has-sidebar div.divider {
    width: 730px;
}

@media screen and (max-width: 767px) {
    div.main {
        overflow: hidden;
    }
    
    .main.has-sidebar div.divider {
        width: 3000px;
    }

    .main.has-sidebar {
        background: white;
    }
    
    .main .container_12 {
        width: 100%;
        margin-left: 0;
        margin-right: 0;
    }

    .main .container_12.page-container > div {
        margin-left: 0;
        margin-right: 0;
        border-left: none;
        border-right: none;
    }
}

@media only screen and (min-width: 768px) and (max-width: 959px) {

    .main div.divider {
        margin-left: -34px;
        width: 768px;
    }
    
    .main.has-sidebar div.divider {
        width: 488px;
    }

    div.main > div.container_12 > div.grid_9 {
        width: 460px;
    }

    div.main > div.container_12 > div#sidebar.grid_3 {
        width: 220px;
    }

}

.ie8 .main {
    border-top: 1px solid #fbfbfb;
}

.prime-page, .prime-post, .comments {
    padding: 10px 30px 10px 0;
    margin-right: 14px;
    margin-bottom: 30px;
}

.prime-post {
    padding-top: 0;
}

.prime-single-portfolio {
    padding-top: 29px;
    padding-bottom: 0;
}

.prime-full-width {
    margin-right: 0;
    padding-right: 0;
}

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

    .prime-page, .post-header, .post-content, .prime-post, .comments, .prime-blog, #sidebar, footer, .comment-form-wrapper {
        margin-right: 0;
        margin-bottom: 0;
        padding-left: 4%;
        padding-right: 4%;
        width: 93%;

        padding-top: 5px;
        padding-bottom: 20px;
    }
    
    .page-container > .grid_9 {
        width: 100%;
    }
    
    .page-container > .grid_12 {
        width: 100%;
    }
}

/* Page Content Styles */

figcaption {
    margin-top: 1em;
    margin-bottom: 1em;
}

img#intro-image {
    margin-top:15px;
    margin-bottom: 5px;
}

img.full-width-image {
    width: 100%;
    margin-right: 6px;
}

p.large-intro {
    font-size: 15px;
    line-height: 23px;
    font-family: 'Segoe UI', 'Droid Sans', "Helvetica Neue", Helvetica, Arial, sans-serif;
    color: #656971;
    margin-top: 1.2em;
    margin-bottom: 20px;
}

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

    div.mobile-divider {
        width: 1024px;
        height: 1px;
        background: url(../img/divider-bg.png) top left repeat-x;
        margin-left: -43px;
        margin-top: 0;
        margin-bottom:0;
        display: inline-block;
    }
}

/* WordPress Gallery Shortcode */
section.gallery figure.gallery-item {
    float: left;
    margin-right: 20px;
    margin-bottom: 20px;

}

section.gallery figure.gallery-item > a > img {
    border: 1px solid white;
    box-shadow: 0px 1px 1px rgba(0, 0, 0, 0.25);
    -moz-box-shadow: 0px 1px 1px rgba(0, 0, 0, 0.25);
    -webkit-box-shadow: 0px 1px 1px rgba(0, 0, 0, 0.25);
}
.entry-content img,
.comment-content img,
.widget img {
	max-width: 97.5%; /* Fluid images for posts, comments, and widgets */
}
img[class*="align"],
img[class*="wp-image-"],
img[class*="attachment-"] {
	height: auto; /* Make sure images with WordPress-added height and width attributes are scaled correctly */
}
img.size-full,
img.size-large {
	max-width: 97.5%;
	width: auto; /* Prevent stretching of full-size and large-size images with height and width attributes in IE8 */
	height: auto; /* Make sure images with WordPress-added height and width attributes are scaled correctly */
}
.entry-content img.wp-smiley {
	border: none;
	margin-bottom: 0;
	margin-top: 0;
	padding: 0;
}
img.alignleft,
img.alignright,
img.aligncenter {
	margin-bottom: 1.625em;
}
p img,
.wp-caption {
	margin-top: 0.4em;
}
.wp-caption {
	background: #eee;
	margin-bottom: 1.625em;
	max-width: 96%;
	padding: 9px;
}
.wp-caption img {
	display: block;
	margin: 0 auto;
	max-width: 98%;
}
.wp-caption .wp-caption-text,
.gallery-caption {
	color: #666;
	font-family: Georgia, serif;
	font-size: 12px;
}
.wp-caption .wp-caption-text {
	margin-bottom: 0.6em;
	padding: 10px 0 5px 40px;
	position: relative;
}
.wp-caption .wp-caption-text:before {
	color: #666;
	content: '\2014';
	font-size: 14px;
	font-style: normal;
	font-weight: bold;
	margin-right: 5px;
	position: absolute;
	left: 10px;
	top: 7px;
}
#content .gallery {
	margin: 0 auto 1.625em;
}
#content .gallery a img {
	border: none;
}
img#wpstats {
	display: block;
	margin: 0 auto 1.625em;
}
#content .gallery-columns-4 .gallery-item {
	width: 23%;
	padding-right: 2%;
}
#content .gallery-columns-4 .gallery-item img {
	width: 100%;
	height: auto;
}

/* Image borders */
img[class*="align"],
img[class*="wp-image-"],
#content .gallery .gallery-icon img {/* Add fancy borders to all WordPress-added images but not things like badges and icons and the like */
	/*border: 1px solid #ddd;*/
	/*padding: 6px;*/
}
.wp-caption img {
	/*border-color: #eee;*/
}
a:focus img[class*="align"],
a:hover img[class*="align"],
a:active img[class*="align"],
a:focus img[class*="wp-image-"],
a:hover img[class*="wp-image-"],
a:active img[class*="wp-image-"],
#content .gallery .gallery-icon a:focus img,
#content .gallery .gallery-icon a:hover img,
#content .gallery .gallery-icon a:active img {/* Add some useful style to those fancy borders for linked images ... */
	/*background: #eee;*/
	/*border-color: #bbb;*/
}
.wp-caption a:focus img,
.wp-caption a:active img,
.wp-caption a:hover img {/* ... including captioned images! */
	background: #fff;
	border-color: #ddd;
}



/* Sidebar */

#sidebar {
    padding-top: 30px;
    padding-bottom: 30px;
}

.sidebar-bg {
    background: transparent;
    width:294px;
    height:100%;
    position:absolute;
    right:0;
    top:0;
    opacity:1;
    background: #f2f2f4;
}

html.boxed-layout #sidebar .sidebar-bg {
    display: none;
    visibility: collapse;
}

html.full-width-layout div.main > .sidebar-bg {
    display: none;
    visibility: collapse;
}



@media only screen and (max-width: 767px) {
    .sidebar-bg {
        display: none;
        visibility: collapse;
    }
}

.ie8 .sidebar-bg {
    top:-1px;
    padding-bottom:1px;
}

#sidebar a, #sidebar a:visited {
    color: #313337;
    -webkit-transition: color 0.3s ease;
    -ms-transition: color ease 0.3s;
    -moz-transition: color 0.3s ease;
    -o-transition: color 0.3s ease;
    transition: color 0.3s ease;
    
}

#sidebar a:hover, #sidebar a:visited:hover {
    color: #ff8400;
    text-decoration: none;
}

.sidebar-widget {
    position: relative;
}

#sidebar article.widget-first > .sidebar-widget {
    margin-top: 0;
}

#sidebar article > .sidebar-widget {
    margin-top: 2.5em;
}

#sidebar article > .sidebar-widget > h3 {
    font-size: 1em;
}

#sidebar div.divider {
    display: none;
    width: 3000px;
    margin-left: -1000px;
    float: left;
}

.prime-blog .sidebar-widget {
    margin-top: 1em;
}


@media only screen and (min-width: 768px) and (max-width: 959px) {
    
    .main.has-sidebar {
        background: #f4f4f6 url(../img/page-with-sidebar-bg.png) -244px 0px repeat-y;
    }
    
    .sidebar-bg {
        width:282px;
    }
}


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

    .sidebar-bg {
        width:0;
        height:0;
        position:absolute;
        right:0;
        top:0;
    }

    #sidebar {
        overflow: hidden;
        background: #f2f2f4;
        border-top: 1px solid #d5d5d7;
        padding-top: 4px;
        padding-bottom: 4px;
    }

    #sidebar div.divider {
        display: block;
        padding: 0;
        background: #d5d5d7;
    }

    #sidebar div.widget-first.divider{
        display:none;
    }

    .sidebar-widget, #sidebar article > .sidebar-widget, #sidebar article:first-child .sidebar-widget {
        margin-top: 1.5em;
        margin-bottom: 1.5em;
    }
    
    #sidebar h3 {
        margin-top: 0;
    }

    .main .container_12.page-container #sidebar{
        margin-bottom: 0;
        margin-left: 0;
        margin-right: 0;
    }

    .main .container_12.page-container #sidebar .sidebar-widget {
        width: 100%;
    }

    .main .container_12.page-container #sidebar .video-widget {
        width: 100%;
    }
}

/* Headers */

h1, h2, h3, h4, h5, h6 {
    line-height: 1.5em;
    margin: 1em 0 1em;
}
 h4, h5, h6 {
    margin: 1.2em 0 1.2em;
 }

h1 {
    font-size: 24px;
    line-height: 36px;
    margin: 18px 0 18px;
}

h2 {
    font-size: 20px;
    line-height: 30px;
    margin: 16px 0 16px;
}

h3 {
    font-size: 16px;
	line-height: 20px;
}

h4 {
	font-size: 14px;
	line-height: 18px;
}

h5 {
	font-size: 12px;
	line-height: 18px;
	text-transform: uppercase;
	color: #656971;
}

h6 {
    font-size: 10px;
	line-height: 16px;
	text-transform: uppercase;
}


