/* Enlarge images inside text (assets/js/image-zoom.js). */

img.is-zoomable {
  cursor: zoom-in;
  transition: filter 0.2s ease;
}
img.is-zoomable:hover {
  filter: brightness(1.04);
}

.arbo-zoom {
  width: auto;
  max-width: 96vw;
  max-height: 94vh;
  padding: 0;
  border: 0;
  background: transparent;
  overflow: visible;
  cursor: zoom-out;

  &::backdrop {
    background: rgb(10 20 30 / 0.92);
  }
  &[open] {
    animation: arbo-zoom-in 0.22s ease-out;
  }
}
@keyframes arbo-zoom-in {
  from {
    opacity: 0;
    transform: scale(0.96);
  }
}
@media (prefers-reduced-motion: reduce) {
  .arbo-zoom[open] {
    animation: none;
  }
}

.arbo-zoom__image {
  display: block;
  max-width: 96vw;
  max-height: 90vh;
  width: auto;
  height: auto;
  border-radius: var(--wp--custom--radius--small);
  background: var(--wp--preset--color--white);
}

.arbo-zoom__close {
  position: fixed;
  top: 1rem;
  right: 1rem;
  width: 2.75rem;
  height: 2.75rem;
  border: 0;
  border-radius: 50%;
  background: rgb(255 255 255 / 0.15);
  color: var(--wp--preset--color--white);
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
}
.arbo-zoom__close:hover,
.arbo-zoom__close:focus-visible {
  background: rgb(255 255 255 / 0.3);
}
