// clipboard.js
//
// JS-based `Copy` buttons for code snippets.

.bd-clipboard {
  position: relative;
  display: none;
  float: $float-end;

  + .highlight {
    margin-block-start: 0;
  }

  @media (min-width: 768px) {
    display: block;
  }
}

.btn-clipboard {
  position: absolute;
  inset-block-start: .75em;
  inset-inline-end: .5em;
  z-index: 10;
  display: block;
  padding: .5em .75em .625em;
  line-height: 1;
  color: #{$gray-900};
  background-color: #{$gray-100};
  border: 0;
  border-radius: .25rem;

  &:hover {
    color: #{$primary};
  }
}
