/**
 * @file
 * This file is used to style the banner block.
 */

.block-type-banner-block {
  background-size: 0 0;
}

.block-type-banner-block .summary {
  margin: 1em;
}

.block-type-banner-block .field--name-field-title {
  margin: 0 0 0.5em 0;
  font-family: "Scope One", Georgia, serif;
  font-size: 1.777em;
  font-weight: 400;
  line-height: 1.2em;
}

.block-type-banner-block .field--name-field-summary {
  margin-bottom: 1.28em;
  font-size: 1.188em;
}

.block-type-banner-block .field--name-field-content-link a {
  display: inline-block;
  padding: 0.7em 1.3em;
  cursor: pointer;
  transition: background-color 0.5s ease;
  text-align: center;
  text-decoration: none;
  color: #fff;
  border: 2px solid #d93760;
  border-radius: 3px;
  background-color: #d93760;
  font-family: "Scope One", Georgia, serif;
  font-size: 1.2rem;
  font-weight: 400;
}

.block-type-banner-block .field--name-field-content-link a:focus,
.block-type-banner-block .field--name-field-content-link a:hover {
  color: #000;
  border-color: #d93760;
  outline-color: #fff;
  outline-offset: 2px;
  background-color: #fcece7;
}

@media screen and (min-width: 48rem) { /* 768px */
  .block-type-banner-block {
    background-color: #464646;
    background-repeat: no-repeat;
    background-position: left center;
    background-size: cover;
    /* Image ratio 7:3 */
  }

  .block-type-banner-block .block-inner {
    display: flex;
    align-items: center;
    max-width: 1200px;
    height: 0; /* Required for flexbox vertical centering in IE11. Min-height will take precedence. */
    min-height: 54vw;
    margin: 0 auto;
    padding: 0 1em;
  }

  .block-type-banner-block .summary {
    flex: 0 0 50%;
    margin: 0;
    padding: 1.777em;
    color: #fff;
    border: 1px solid #464646;
    background: rgba(0, 0, 0, 0.42);
  }

  .block-type-banner-block .field--name-field-media-image {
    /**
     * We need to ensure that the alt text on the image is accessible to
     * screenreaders, so, when on large screens, let's give this the same CSS
     * as the .visually-hidden class has.
     */
    position: absolute !important;
    overflow: hidden;
    clip: rect(1px, 1px, 1px, 1px);
    width: 1px;
    height: 1px;
    word-wrap: normal;
  }
}

@media screen and (min-width: 60rem) { /* 960px */
  .block-type-banner-block .summary {
    flex: 0 0 41%;
  }
  .block-type-banner-block .block-inner {
    min-height: 43vw;
  }
}

/* 77em == the max width of .container + 1em either side */
@media screen and (min-width: 77rem) {
  .block-type-banner-block .summary {
    margin-left: -1em;
  }
}
