body.simple-editor-open {
  overflow: hidden;
  overscroll-behavior: none;
}

.simple-mobile-editor {
  position: fixed;
  inset: 0 0 0 auto;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  width: min(100%, 480px);
  max-width: 480px;
  height: 100dvh;
  max-height: 100dvh;
  margin: 0;
  overflow: hidden;
  overscroll-behavior: contain;
}

.simple-editor-scroll {
  min-width: 0;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.simple-image-editor,
.simple-text-tools,
.simple-text-tools > label,
.simple-button-editor,
.simple-export {
  min-width: 0;
  max-width: 100%;
}

.simple-image-editor {
  box-sizing: border-box;
  width: 100%;
}

.simple-text-tools input,
.simple-text-tools select,
.simple-button-editor input,
.simple-button-editor select,
.simple-editor-scroll textarea {
  min-width: 0;
  max-width: 100%;
  font-size: 16px;
}

@media (max-width: 767px) {
  .simple-mobile-editor {
    width: 100vw;
    max-width: 100vw;
  }
}

.simple-text-tools {
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  overflow: visible;
}

.simple-text-tools fieldset {
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  min-inline-size: 0;
  max-width: 100%;
  margin: 0;
  padding: 10px;
  overflow: visible;
}

.simple-text-tools .simple-color-list {
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
}

.simple-text-tools > label,
.simple-text-tools .simple-outline {
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.simple-text-tools .simple-outline {
  display: flex !important;
  align-items: center;
  gap: 10px;
  overflow: hidden;
}

.simple-text-tools .simple-outline input {
  width: 22px;
  min-width: 22px;
  max-width: 22px;
  flex: 0 0 22px;
  margin: 0;
}

.simple-overlay-stage [data-simple-inline-text] {
  display: block;
  width: max-content;
  min-width: 1ch;
  max-width: 100%;
  outline: 0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  -webkit-user-select: text;
  user-select: text;
}

.simple-overlay-stage button.inline-editing {
  width: max-content;
  min-width: 2ch;
  max-width: 90%;
  touch-action: manipulation;
  cursor: text;
}

.simple-overlay-stage button[data-simple-overlay] {
  width: max-content;
  min-width: 2ch;
  max-width: 90%;
}
