[class*=#{$imghv-selector}-] {
  position: relative;
  backface-visibility: hidden;
  overflow: hidden;

  img {
    backface-visibility: hidden;
  }

  &::before,
  &::after,
  img,
  figcaption,
  figcaption::before,
  figcaption::after {
    transition-duration: $imghv-duration;
    transition-property: opacity, transform;
    transition-timing-function: $imghv-timing;
  }

  &::before,
  &::after,
  figcaption,
  figcaption::before,
  figcaption::after {
    top: 0;
    left: 0;
    position: absolute;
  }

  figcaption {
    background-color: $imghv-bg;
    padding: $imghv-padding;
    color: $imghv-color;
    font-size: $imghv-fs;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    width: 100%;
    height: 100%;
  }
}