/**
 * Formatting and positioning of the individual content sections and blocks (including views blocks)
 * Content formatting is specified in nodes.css, views.css, tables.css and media.css, as appropriate
 * Note however that nodes.css will very likely go into other css files
 *
 * LAYER 0: Formatting of content containers, i.e. blocks in this case
 * - Covers the positioning of different types of block within the content region
 * - blocks within header and footer regions are covered in their own css file
 * - Whilst many blocks are specific to certain types of page, region etc., this covers the different use cases, which may
 **/

/* Content background for all unpublished nodes */
.node--unpublished {
  background-color: #fff4f4;
}

/* Default main block positioning - this is the block that holds all the content */
.region-content  {
  margin: 0.5rem 0;
}

/* Set padding of .node__content wrapper for specific content types */
.page-node-type-ccnm-sermon-series .node__content,
.page-node-type-ccnm-podcast .node__content,
.page-node-type-ccnm-sermon .node__content {
  padding: 0.5rem;
}

/* Formatting specific for smaller screens (smartphone and tablet held in portrait) */
@media all and (max-width: 959px) { 

/* Formatting where h1.page-title is used - top margin at 1.5rem is too great so we take it back */
/* Begs question why we can't adjust h1.page-title instead */
/* Similarly setting region-content to have margin-top of 0.5rem or 0.75rem (TBD) */
.path-search .block-page-title-block,
.page-node-type-article .block-system-main-block,
.page-node-type-ccnm-sermon-series .block-page-title-block,
.page-node-type-ccnm-podcast .block-page-title-block,
.page-node-type-ccnm-sermon .block-page-title-block,
.page-node-type-page .block-system-main-block  {
  margin-top: -1rem;
}

/* Views that have no tabs */
.sermons-by-year.view,						/* What is this? */
.path-books-by-stephen-kuhrt .block-system-main-block,
.page-node-type-event-icons .block-system-main-block,
.path-look-whos-talking .block-system-main-block,
.path-whyiamachristian .block-system-main-block,
.path-past-events .block-system-main-block,
.path-action .block-system-main-block,
.path-whats-on .block-system-main-block,
.path-news .block-system-main-block  {
  margin-top: 0.5rem;
}

/* Positioning for views with tabs, also if logged in (View, Edit tab) */
/* This gives us space of 12px (0.75rem) between the search bar and the tabs ahead of the content */
/* Focusing on region-content would obviate the need for this (or give an extra 0.25rem?) */
.user-logged-in #block-ccnm10-local-tasks,
.path-preaching .block-local-tasks-block,
.path-sermons .block-local-tasks-block  {
	margin-top: 0.75rem;
}

}

/* Formatting for larger screens */
@media all and (min-width: 960px) { 
 
/* Regular pages where the content begins with h2 format - this cancels out the 1.5rem top margin */
/* Begging the question of whether h2 should have that margin in the first place */
/* Where is it used other than as the block header? */
.user-logged-in #block-shema-local-tasks,
.path-preaching .block-local-tasks-block,
.path-sermons .block-local-tasks-block  {
	margin-top: 1.5rem;
}

/* For individual non-page nodes */
.path-search .block-page-title-block,
.page-node-type-ccnm-sermon-series .block-page-title-block,
.page-node-type-ccnm-podcast .block-page-title-block,
.page-node-type-ccnm-sermon .block-page-title-block  {
  margin-top: 0;
}

}

/* End of tablet (landscape) and desktop */