.copy-panel,
.copy-inline {
  position: relative;
}
.copy-panel > pre {
  padding-right: 3em;
}
.copy-panel > pre[data-filename]:before {
  right: 3em;
}
.copy-inline {
  display: inline-block;
  padding-right: 2em;
}
.copy-button {
  position: absolute;
  top: 7px;
  right: 7px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border: 1px solid #888;
  border-radius: 2px;
  background: #f5f5f5;
  color: #252525;
  cursor: pointer;
  padding: 4px;
}
.copy-inline > .copy-button {
  top: 50%;
  right: 0;
  transform: translateY(-50%);
  width: 24px;
  height: 24px;
}
.copy-button svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
}
.copy-button:hover,
.copy-button:focus-visible {
  background: #ddd;
  outline: 2px solid currentColor;
  outline-offset: 2px;
}
@media (hover: hover) {
  .copy-button {
    opacity: 0;
    pointer-events: none;
  }
  .copy-panel:hover > .copy-button,
  .copy-inline:hover > .copy-button,
  .copy-panel:focus-within > .copy-button,
  .copy-inline:focus-within > .copy-button {
    opacity: 1;
    pointer-events: auto;
  }
}
@media (prefers-color-scheme: dark) {
  .copy-button {
    background: #242424;
    color: #d9d9d9;
  }
  .copy-button:hover,
  .copy-button:focus-visible {
    background: #444;
  }
}
.copy-status:not(:empty) {
  position: fixed;
  bottom: 1em;
  left: 1em;
  right: 1em;
  z-index: 1100;
  width: fit-content;
  max-width: calc(100% - 2em);
  padding: 0.75em 1em;
  background: #252525;
  color: #fff;
  border-radius: 2px;
}
