/* Case Studies hub: client stories under the hero (inc/case-hub-stories.php).
 * Loaded after testimonials.css: the video stories on the video band, as on
 * the Awards page, in the site's blue. */

.bpo-case-stories {
  position: relative;
}

.bpo-case-stories .bpo-tsl {
  margin-top: 0;
}

/* The video band: an even frame round the cards; as many across as there are
 * stories, up to three (testimonials.css). The slider shows its controls only
 * when there are more cards than fit: the arrows then sit on the band's left
 * and right edges, level with the cards' middle, and the dots go underneath. */
.bpo-case-stories .bpo-tsl__carousel--videos {
  position: relative;
  padding: 22px;
}

.bpo-case-stories .bpo-tsl__arrows {
  display: contents;
}

.bpo-case-stories .bpo-tsl__carousel--videos .bpo-tsl__viewport {
  margin-bottom: 0;
  padding-bottom: 2px;
}

.bpo-case-stories .bpo-tsl__controls {
  order: 2;
  justify-content: center;
  margin-top: 18px;
}

/* Centred on the cards: half the band's height less the dots row under them. */
body.bpo-innovature-theme .bpo-case-stories .bpo-tsl .bpo-tsl__arrow {
  position: absolute;
  top: calc((100% - 26px) / 2);
  z-index: 2;
  border-radius: 50%;
  translate: 0 -50%;
}

body.bpo-innovature-theme .bpo-case-stories .bpo-tsl .bpo-tsl__arrow[data-bpo-tsl-prev] {
  left: -21px;
}

body.bpo-innovature-theme .bpo-case-stories .bpo-tsl .bpo-tsl__arrow[data-bpo-tsl-next] {
  right: -21px;
}

/* Phones swipe: the dots alone. */
@media (max-width: 767px) {
  .bpo-case-stories .bpo-tsl__carousel--videos {
    padding: 14px;
  }

  body.bpo-innovature-theme .bpo-case-stories .bpo-tsl .bpo-tsl__arrow {
    display: none;
  }

  .bpo-case-stories .bpo-tsl__controls {
    margin-top: 14px;
  }
}

/* On Case Studies the slider takes the site's blue and gradient in place of
 * the shared slider's cyan: links, "View case study", the filling dot and
 * the arrows. */
.bpo-case-stories .bpo-tsl {
  --tsl-cta: #155dcc;
  --tsl-cta-hover: #0035a2;
  --tsl-cta-ink: #155dcc;
}

body.bpo-innovature-theme .bpo-case-stories .bpo-tsl .bpo-tsl__case {
  border-color: transparent;
  background: linear-gradient(135deg, #0035a2 0%, #155dcc 100%);
}

body.bpo-innovature-theme .bpo-case-stories .bpo-tsl .bpo-tsl__case:is(:hover, :focus-visible) {
  border-color: transparent;
  background: linear-gradient(135deg, #0b4ab6 0%, #4a9dff 100%);
}

.bpo-case-stories .bpo-tsl__dot span {
  background: linear-gradient(90deg, #0035a2 0%, #155dcc 100%);
}

body.bpo-innovature-theme .bpo-case-stories .bpo-tsl .bpo-tsl__arrow {
  border: 0;
  background: linear-gradient(135deg, #0035a2 0%, #155dcc 100%);
  box-shadow: 0 10px 22px rgba(0, 53, 162, 0.22);
  color: #ffffff;
}

body.bpo-innovature-theme .bpo-case-stories .bpo-tsl .bpo-tsl__arrow:is(:hover, :focus-visible):not(:disabled) {
  background: linear-gradient(135deg, #0b4ab6 0%, #4a9dff 100%);
  box-shadow: 0 14px 28px rgba(0, 53, 162, 0.28);
  color: #ffffff;
}

body.bpo-innovature-theme .bpo-case-stories .bpo-tsl .bpo-tsl__arrow:disabled {
  box-shadow: none;
  opacity: 0.32;
}
