//
// Thumbnails
// --------------------------------------------------

%thumbnail {
  transition: all .2s ease-in-out;

  padding: $thumbnail-padding;

  background-color: $thumbnail-bg;
  border: 1px solid $thumbnail-border;

  line-height: $line-height-base-ratio;
}

.img-thumbnail {
  @extend %thumbnail;

  // Keep them at most 100% wide
  @include img-responsive();

  display: inline-block;
}

.thumbnail {
  @extend %thumbnail;

  display: block;
  margin-bottom: $line-height-base;

  > img,
  a > img {
    @include img-responsive();
    margin-left: auto;
    margin-right: auto;
  }

  // [converter] extracted a&:hover, a&:focus, a&.active to a.thumbnail:hover, a.thumbnail:focus, a.thumbnail.active

  // Image captions
  .caption {
    padding: $thumbnail-caption-padding;
    color: $thumbnail-caption-color;
  }
}

// Add a hover state for linked versions only
// scss-lint:disable QualifyingElement
a.thumbnail {
  &:hover,
  &:focus,
  &.active {
    border-color: $link-color;
  }
}
// scss-lint:enable all
