.cx-creation-reference-viewer:not([hidden]) {
  display: flex;
  flex-direction: column;
  width: min(610px, 46vw);
  height: min(520px, 72vh);
  min-width: min(320px, calc(100vw - 20px));
  min-height: 220px;
  max-width: calc(100vw - 12px);
  max-height: calc(100vh - 12px);
  overflow: hidden;
  box-sizing: border-box;
}

.cx-creation-reference-viewer .cx-creation-reference-viewer-image {
  flex: 1 1 auto;
  height: 100%;
  overflow: hidden;
}

.cx-creation-reference-viewer .cx-creation-reference-viewer-image img {
  width: 100%;
  height: 100%;
  max-height: none;
  object-fit: contain;
}

.cx-creation-reference-viewer-resize {
  position: absolute !important;
  right: 0;
  bottom: 0;
  z-index: 4;
  display: block !important;
  width: 24px !important;
  height: 24px !important;
  min-height: 24px !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background:
    linear-gradient(135deg,
      transparent 0 48%,
      rgba(85, 222, 248, .35) 49% 56%,
      transparent 57% 66%,
      #55def8 67% 74%,
      transparent 75%) !important;
  box-shadow: none !important;
  clip-path: none !important;
  cursor: nwse-resize !important;
  touch-action: none;
}

@media (max-width: 780px) {
  .cx-creation-reference-viewer:not([hidden]) {
    min-width: 0;
    max-width: calc(100vw - 20px);
    max-height: calc(100vh - 80px);
  }
}
