/*
 Theme Name:     Divi Policy Exchange Child Theme
 Theme URI:      
 Description:    Custom Divi theme for Policy Exchange
 Author:         Heritage Arts Company
 Author URI:     http://www.heritagearts.co.uk
 Template:       Divi
 Version:        0.0.1
*/
 
@import url("../Divi/style.css");
 
/* =Theme customization starts here
------------------------------------------------------- */

/**** General ****/

/*a:link,a:visited {
    color:#e15c16;
}*/

.et_pb_blog_publications_0 .et_pb_post h2 { 
    line-height: 1.2em !important; 
    }

@media (min-width: 981px){
    .footer-widget {
    width: 17%;
    margin: 0 8% 8% 0;
    }
    
}

/**** Sidebar Widgets ****/

    h4.widgettitle {
        color: #e15c16;
    }

.et_pb_gutters4 .et_pb_column_1_4 .et_pb_widget {
    margin-bottom: 20px;
    }

/**** Tigthen Meta ****/
    #left-area .post-meta {
        padding-bottom: 0px;
        }


/**** Padding for mobile *****/
/**** TODO: Find another way to do this to help fullwidth modules look nicer ****/

    @media (max-width: 981px) {
        .entry-content {
            padding-left: 5px;
            padding-right: 5px;
        }
    }

/**** Fullwidth blog module edits ****/
@media (min-width: 981px){

    .et_pb_image_container img, .et_pb_post a img {
        max-width: 200px !important;
        float:left;
        margin: 0px 20px 50px 0px;
    }
}

.et_pb_post {
    min-height: 150px;
}

.frontpage.et_pb_image_container img, .frontpage.et_pb_post a img {
    max-width: 100% !important;
    float: none;
}

.et_pb_slide_content, .et_pb_slide_title, .et_pb_slide_content p {
    opacity: 0.8;
}

.et_pb_slide_title, {
    color: #000000 !important;
}

/****** Archive Page ******/
.px-archive-postlist img {
    float:left;
    margin: 0px 20px 50px 0px;
}

.et_pb_post p {
    text-align: justify;
}

.px-archive-postlist  h2 {
     font-size: 26px !important;
}

/****** Author Page ******/

    .px-author-row {
        width: 100%;
        margin-bottom: 20px;
        display: block;
        min-height: 200px;
        clear: both;
    }

    @media (min-width: 981px) {
        /* Desktop View: Title & Bio Left, Image right */
        .px-author-column-info {
            float: left;
            width: 48%;
            margin-right: 2%;
            margin-bottom: 20px;
        }

        .px-author-column-avatar {
            float: left;
            width: 48%;
            margin-left: 2%;
            text-align: right;
        }

        /* Desktop View: Featured Images Float left, small */
        a.px-author-image {
            display: block;
            float: left;
            margin: 0px 20px 30px 0px;
            min-height: 125px;
        }
    }

    @media (max-width: 981px) {
        /* Mobile View: Title & Bio Stacked, Centered, Padded Vertically */
        .px-author-column-info {
            float: left;
            width: 100%;
            margin-bottom: 20px;
        }

        .px-author-column-avatar {
            float: left;
            width: 100%;
            margin-bottom: 20px;
            text-align: center;
        }
        /* Mobile View: Title & Bio Stacked, Centered, Padded Vertically, and increased to full-width image */
        a.px-author-image {
            display: block;
            margin: 0px 0px 30px 0px;
            width: 100%;
            clear: both;
        }
        
        a.px-author-image img {
            width: 100%;
            
        }
    }

    h2.px-author-name  {
        font-size: 28px;
        color: #e15c16;

    }
    h3.px-author-jobtitle {
        font-size: 22px;
        color: #666;
    }
    p.px-author-bio {
        text-align: justify;
    }

    h2.px-author-posts {
        font-size: 26px;
        color: #e15c16;
        border-bottom: 1px solid #e15c16;
        margin-bottom: 20px;
    }

    .px-author-postlist {
        display: block;
        clear: both;
    }

    h2.px-author-entry-title {
        font-size: 22px;

    }

/* Single Page Visual Alterations */

#px-download-button {
margin-top: -20px;
margin-bottom: 5px !important;
}


/* Author Spotlight CSS */

#author-profile img {
    float:left;
    margin-right: 10px; 
}

#author-profile h2 {
    font-size: 21px;
}

#author-description {
    min-height: 96px;
    display: block;
    text-align: justify;
}

#author-link {
    text-align: right;
    margin-bottom: 10px;
}

#authorspotlight-2 {
    margin-bottom: 5px;
    width: 100%;
}

/* Library Page Visual Edits */

.et_pb_toggle {
    border-color: #e15c16;
}

/* Blog Module Grid View Changes */

.et_pb_blog_grid .et_pb_post {
    padding: 0px;
    border: none;
    min-height: 125px;
}

@media (min-width: 981px) {
    
   .et_pb_post .et_pb_image_container { 
        max-width: 245px !important; 
        max-height: 145px !important;
        overflow: hidden;
        float: left !important; 
        margin: 0px 20px 5px 0px; !important;
    } 
    
    
}

@media (max-width: 981px) {
     .et_pb_post .et_pb_image_container {
        max-width: 100%; 
        overflow: hidden;
        margin: 0px 0px 5px 0px; !important;
    }
}

/* Fix strange mobile view bug on blog module */
@media only screen and (max-width: 980px) {
    .et_pb_post {
        font-size: 14px !important;
        line-height: normal !important;
    }
    .et_pb_post .post-meta {
        font-size: 14px !important;
        line-height: normal !important;
    }
    
    .et_pb_post .et_pb_blog_grid h2 {
        line-height: 1.2em; !important;
        padding-bottom: 5px; !important;
    }
    
    .et_pb_post h2 {
        line-height: 1.2em !important;
        font-size: 16px !important;
    }
    
    .et_pb_post p {
    line-height: 1.2em !important;
    }
    
    .et_pb_blog_publications_0 .et_pb_post h2 {
    line-height: 1.2em !important;
    }
}

.single-event .published {
    display: none;
}

/* YARPP Related Posts Widget CSS */

#yarpp_blogs-2, #yarpp_events-2, #yarpp_publications-2, #yarpp_news-2, #yarpp-press-2 {
    margin-bottom: 20px;
}
    
    #yarpp_blogs-2.et_pb_widget.widget_yarpp_blogs {
        width: 100%;
    }

.yarpp-px-related-container {
    display: block;
    padding-top: 0px;
    padding-bottom: 5px;
    margin-bottom: 20px;
    background-color: #fff;
    word-wrap: break-word;
    min-height: 135px;
    text-align: justify;
}

@media (min-width: 981px) {
    .yarpp-px-img-container {
    max-width: 200px !important; 
    max-height: 125px !important;
    overflow: hidden;
    float: left !important; 
    margin: 0px 20px 5px 0px; !important;
    }
}

@media (max-width: 981px) {
    .yarpp-px-img-container {
    max-width: 100%; 
    overflow: hidden;
    margin: 0px 0px 5px 0px; !important;
    }
}

h2.yarpp-px-title  {
    margin-top: 5px !important;
    font-size: 21px !important;
}

.et_pb_gutters4 .et_pb_column_3_4 .et_pb_widget {
    width: 100% !important; /* Stops it squishing to the left */
    margin-right: 0px;
}

/* Hardcoded YARP CSS (Redundant) */

.yarpp-related h3 {
    font-size: 22px !important;
    color: #ffffff !important;
    line-height: 1.4em;
    background-color: #387b8b;
    padding-left: 10px !important;
    margin-bottom: 10px !important;
    font-weight: normal !important;
    background-image: url('http://pxtest.xyz/wp-content/uploads/2016/08/bluex.jpg');
    background-position: right;
    background-repeat: no-repeat;
    min-height: 32px;
}

/* Blog Post Grid View: Left aligned images, full width. */

@media (min-width: 981px){
.et_pb_gutters4 .et_pb_column_3_4 .et_pb_blog_grid .column.size-1of2 {
		width: 100%;
		margin-right: 0%;
	}

.et_pb_gutters4 .et_pb_column_3_4 .et_pb_blog_grid .column.size-1of2 .et_pb_post {
    padding-top: 0px;
    padding-bottom: 5px;
    margin-bottom: 20px;
    }
}

/* Sidebar menu spacing reduction */
@media (min-width: 981px){
.et_pb_widget.widget_nav_menu {margin-bottom: 15px !important;}
}

/* Publication Page Button Margin removal */
@media (min-width: 981px) {
    .et_pb_gutters4 .et_pb_column_4_4 .et_pb_module, .et_pb_gutters4.et_pb_row .et_pb_column_4_4 .et_pb_module {
        margin-bottom: 0px;
    }
    
}

/*Enable Divi builder for custom post types
___________________________________________________________*/
 
.et_pb_pagebuilder_layout.single-publication #page-container .et_pb_row {
width: 100%;
}
.et_pb_pagebuilder_layout.single-publication #page-container .et_pb_with_background .et_pb_row {
width: 80%;
}

 a:link {color: #000000; }

@media only screen and ( min-width:981px ) {
    /* Set the slider height v1*/
    .tall_slider,     .tall_slider .et_pb_container { 
        height: 425px !important; 
    }
    .tall_slider,     .tall_slider .et_pb_slide { 
        max-height: 450px; 
    }
    .tall_slider .et_pb_slide_description { 
        position: relative; 
        top: 10%; 
        padding-top: 0 !important; 
        padding-bottom:0 !important; 
        height:auto !important; 
    }
}


@media only screen and ( min-width:981px ) {
    /* Set the slider height short v1 */
    .short_slider,     .short_slider .et_pb_container { 
        height: 204px !important; 
    }
    .shot_slider,     .short_slider .et_pb_slide { 
        max-height: 204px; 
    }
    .short_slider .et_pb_slide_description { 
        position: relative; 
        top: 10%; 
        padding-top: 0 !important; 
        padding-bottom:0 !important; 
        height:auto !important; 
    }
}

@media only screen and ( min-width:981px ) {
    /* Set the slider height v2*/
    .tall_slider2,     .tall_slider2 .et_pb_container { 
        height: 509px !important; 
    }
    .tall_slider2,     .tall_slider2 .et_pb_slide { 
        max-height: 509px; 
    }
    .tall_slider2 .et_pb_slide_description { 
        position: relative; 
        top: 10%; 
        padding-top: 0 !important; 
        padding-bottom:0 !important; 
        height:auto !important; 
    }
}