div.demo_canvas {
  width: 300px;
  max-width: 100%;
  aspect-ratio: 300 / 430;
  background-repeat: no-repeat;
  background-position: top left;
  position: relative;
  overflow: hidden;
  z-index: 2;
  margin: 0 auto;
}

div.demo_canvas canvas {
  position: absolute;
  top: 6.0465116279%;
  left: 5.3333333333%;
  /* Override the demo's inline pixel sizes when the frame shrinks. */
  width: 89.3333333333% !important;
  height: 83.2558139535% !important;
  background: white;
  z-index: 1;
  border-radius: 5px;
}

div.demo_canvas img {
  display: block;
  width: 100%;
  height: auto;
  margin: 0;
}
