.case-study-template__intro {
  max-width: $max-width;
  margin-left: auto;
  margin-right: auto;
  padding-top: 22px;
  padding-bottom: 50px;
  padding-left: 20px;
  padding-right: 20px;
  margin-bottom: 30px;

  h1 {
    font-size: 3.4rem;
    line-height: 3.8rem;
  }

  p {
    font-size: 1.8rem;
  }

  @include sm {
    padding-left: 15px;
    padding-right: 15px;
    margin-bottom: 0;
    padding-bottom: 20px;
  }
}

.case-study-template__intro-wrapper {
  width: 79.16666667%;
  margin-left: 12.5%;
  padding-left: 5px;
  padding-right: 5px;
  color: $primary-color;

  @include sm {
    margin-left: 8.33333333%;
    width: 83.33333333%;
  }

  @include xs {
    width: 100%;
    margin-left: 0;
  }
}

.case-study-template__body {
  background: linear-gradient(180deg, rgba(238, 240, 242, 0.5), rgba(238, 240, 242, 0));
  padding-top: 50px;
  min-height: 600px;
}

.case-study-template__filters {
  max-width: $max-width;
  margin: 0 auto;

  > div {
    width: 91.66666667%;
    margin-left: 4.16666667%;
    padding-left: 10px;
    padding-right: 10px;

    @include sm {
      margin-left: 0;
      width: 100%;
    }
  }
}

.case-study-template__filter-container {
  margin: 10px 0;
}

.case-study-template__filter {
  display: inline-block;
  padding-left: 32px;
  font-size: 16px;
  line-height: 30px;
  font-weight: 700;
  position: relative;

  a {
    font-weight: 700;
  }

  &.active {
    &::before {
      content: '';
      background-image: url(../img/svg/Check.svg);
      background-repeat: no-repeat;
      display: block;
      position: absolute;
      top: 8px;
      left: 14px;
      width: 11px;
      height: 11px;
    }
  }
}

.case-study-template__results {
  max-width: $max-width;
  margin-left: auto;
  margin-right: auto;
}

.case-study-template__results-wrapper {
  display: flex;
  flex-wrap: wrap;

  > div {
    padding: 25px;
    width: 25%;

    @include md {
      width: calc(100% / 3);
    }

    @include sm {
      width: calc(100% / 2);
    }

    @include xs {
      width: 100%;
    }
  }
}

.case-study-card__wrapper {
  padding-top: 100%;
  position: relative;
  overflow: hidden;

  h3 {
    font-family: var(--font-default);;
    padding: 0 15px;
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-style: normal;
    font-size: 1.8rem;
    line-height: 2.7rem;
    transition: color .2s linear;
  }

  &:hover {
    a {
      opacity: 1;
    }

    img {
      transform: scale(.97);
    }

    h3 {
      color: $medium-color;
    }
  }
}

.case-study-card__img {
  position: absolute;
  top: 0;
  right: 0;
  text-align: right;

  img {
    width: 100%;
    transition: transform .3s ease-in-out;
    transform-origin: top right;
  }
}

.case-study-card__buttons {
  width: 100%;
  position: absolute;
  top: 0;
  padding-top: 100%;

  a {
    position: absolute;
    top: 50%;
    width: 60px;
    height: 60px;
    left: 50%;
    margin: -38px 0 0 -24px;
    background-color: $white;
    border-radius: 50%;
    opacity: 0;
    transition: opacity .2s linear;
    border-color: $primary-color;

    &::after,
    &::before {
      display: none;
    }

    &:hover {
      .dl-icon {
        opacity: 0;
      }

      .hover-icon {
        opacity: 1;
      }
    }
  }

  .dl-icon,
  .hover-icon {
    content: '';
    width: 18px;
    height: 18px;
    background-image: url(../img/svg/Page.svg);
    display: block;
    background-repeat: no-repeat;
    position: absolute;
    left: 21px;
    top: 22px;
    transition: opacity .15s linear;
  }

  .hover-icon {
    opacity: 0;
    background-image: url(../img/svg/Download_lb.svg);
  }
}

.case-study-tile-wrapper {
  position: relative;
  color: $primary-color;
}

.case-study-sector-teaser-tile {
  padding: 24px 20px;
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;

  .tagline {
    padding: 26px 5px 15px;
    font-size: 2.1rem;
    font-style: italic;
  }

  .sector-link {
    padding: 0 5px;
    font-size: 1.6rem;
    font-weight: 700;

    a {
      font-weight: 400;
      color: $medium-color;
      text-decoration: underline;
    }
  }
}
