div.d-media-canvas-image {
  position: relative;
  z-index: 0;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

div.d-media-canvas-image svg.canvas {
  max-width: 100%;
  max-height: 100%;
  height: 100%;
}

div.d-media-canvas-image > img,
div.d-media-canvas-image > picture,
div.d-media-canvas-image > svg:not(.canvas) {
  width: auto;
  height: auto;
  max-height: 100%;
  max-width: 100%;
  position: absolute;
  z-index: 0;
  left: 0;
  right: 0;
  margin-left: auto;
  margin-right: auto;
}
