.kp-media-editor-modal .modal-dialog {
  width: min(calc(100% - 2rem), 71.25rem);
  max-width: none;
}

.kp-media-editor-modal .kp-crop-stage {
  min-height: 20rem;
  max-height: calc(100dvh - 15rem);
  overflow: hidden;
  background: var(--ct-tertiary-bg, rgba(152, 166, 173, 0.08));
  border: var(--ct-border-width, 1px) solid var(--ct-border-color, rgba(152, 166, 173, 0.25));
  border-radius: var(--ct-border-radius, 0.25rem);
}

.kp-media-editor-modal .kp-crop-stage img {
  display: block;
  max-width: 100%;
}

.kp-profile-media-item {
  overflow: hidden;
  border-radius: var(--ct-border-radius, 0.25rem);
  background: var(--ct-tertiary-bg, rgba(152, 166, 173, 0.08));
}

.kp-profile-media-item > a {
  display: block;
  line-height: 0;
}

.kp-profile-media-item > a > img {
  display: block;
  width: 100%;
  height: auto;
}

.kp-profile-media-item .kp-profile-media-actions {
  position: absolute;
  inset: 0.5rem 0.5rem auto auto;
  z-index: 3;
}

.kp-profile-media-item .kp-profile-media-handle {
  position: absolute;
  inset: 0.5rem auto auto 0.5rem;
  z-index: 3;
  cursor: grab;
  touch-action: none;
}

@media (max-width: 575.98px) {
  .kp-media-editor-modal .modal-dialog {
    width: calc(100% - 1rem);
    margin: 0.5rem;
  }

  .kp-media-editor-modal .kp-crop-stage {
    min-height: 14rem;
    max-height: calc(100dvh - 16rem);
  }

  .kp-media-editor-modal .modal-footer {
    align-items: stretch;
    gap: 0.5rem;
  }

  .kp-media-editor-modal .modal-footer > * {
    margin: 0;
  }
}
