/**
 * Image gallery
 */

@use "../settings" as *;
@use "../tools" as *;

.gallery {
  .carousel-control-next,
  .carousel-control-prev {
    align-items: flex-end;
  }

  .carousel-control-next-icon,
  .carousel-control-prev-icon {
    width: $gallery-indicator-height;
    height: $gallery-indicator-height;
  }
}

.gallery-media {
  display: block;
  width: auto;
  max-width: 100%;
  max-height: $gallery-image-height;
  margin: auto;
}

.gallery-indicators {
  display: flex;
  flex-wrap: nowrap;
  @include transition($carousel-transition);

  [data-bs-target] {
    box-sizing: content-box;
    padding: 0;
    border: 0;
  }
}

.gallery-indicator {
  width: auto;
  height: $gallery-indicator-height;
}

.gallery-caption {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  padding: space(3);
  color: $white;
  background-color: rgba(0, 0, 0, .5);

  > :last-child {
    margin-bottom: 0;
  }
}

.gallery-heading {
  @include font-size($h5-font-size);
}
