/* Editor interactions share the same restrained visual language. */
.engineering-options {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  min-height: 43px;
  padding: 5px 13px;
  border-bottom: 1px solid #cfdeeb;
  background: #f2f7fc;
}
.engineering-options[hidden] { display: none; }
.engineering-options span { margin-right: 8px; color: #315b80; font-size: 12px; }
.engineering-options button { padding: 5px 10px; }
.engineering-options button.active { background: #dceafb; color: #205b91; border-color: #82afd9; }
.engineering-options button.primary { background: #2b679b; border-color: #2b679b; color: #fff; }
.engineering-options button:is([data-engineering-guide="quick"], [data-engineering-guide="spiral"]) { background: #2873ab; border-color: #1d608f; color: #fff; }
.engineering-options button:is([data-engineering-guide="quick"], [data-engineering-guide="spiral"]).active { background: #185a91; border-color: #104877; color: #fff; }
.engineering-options > :not(.engineering-status) { flex-shrink: 0; }
.engineering-options .engineering-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-left: auto; max-width: 100%; }
.engineering-options select { width: auto; min-width: 130px; padding: 5px 8px; border: 1px solid #cbd7cf; border-radius: 5px; background: white; }
.engineering-radius-prompt { position: absolute; z-index: 12; display: flex; align-items: center; justify-content: center; height: 27px; margin: 0; padding: 0 3px; box-sizing: border-box; color: #f1f8fc; background: #30485399; border: 1px solid #b2d6e366; border-radius: 0; backdrop-filter: blur(16px) saturate(125%); -webkit-backdrop-filter: blur(16px) saturate(125%); font: 14px/25px sans-serif; pointer-events: none; transform: translate(-50%, -50%); }
.engineering-radius-prompt[hidden] { display: none; }
.engineering-radius-prompt input, .engineering-radius-prompt input:focus { display: block; width: auto; min-width: 24px; max-width: 100px; height: 25px; margin: 0; padding: 0 1px; box-sizing: border-box; border: 0; border-radius: 0; outline: none; box-shadow: none; background: transparent; font: inherit; line-height: 25px; color: inherit; text-align: center; vertical-align: middle; pointer-events: none; }
.engineering-radius-prompt input::-webkit-inner-spin-button,
.engineering-radius-prompt input::-webkit-outer-spin-button { margin: 0; appearance: none; }
.structure-level-prompt { position: absolute; z-index: 13; width: 42px; height: 29px; padding: 1px 2px; box-sizing: border-box; color: #f1f8fc; background: #30485399; border: 1px solid #b2d6e366; border-radius: 0; backdrop-filter: blur(16px) saturate(125%); -webkit-backdrop-filter: blur(16px) saturate(125%); font: 9px/12px sans-serif; text-align: center; pointer-events: none; }
.structure-level-prompt[hidden] { display: none; }
.structure-level-prompt output { display: block; width: 100%; height: 13px; color: inherit; font: 12px/13px sans-serif; text-align: center; }
.engineering-options .engineering-status { flex: 0 1 auto; min-width: 0; margin: 0; color: #92551b; white-space: normal; }
.engineering-options .engineering-status[hidden] { display: none; }
.smart-editor label.engineering-ignore-warnings { display: flex; justify-content: space-between; align-items: center; gap: 12px; white-space: nowrap; color: inherit; }
.smart-editor label.standard-checkbox-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  white-space: normal;
  color: inherit;
}
.smart-editor label.standard-checkbox-row > span { min-width: 0; overflow-wrap: anywhere; }
.standard-checkbox-row input { width: auto; justify-self: end; flex: 0 0 auto; margin: 0; }
.engineering-ignore-warnings input { width: auto; margin: 0; }
.engineering-error { color: #b54538; }
.engineering-warning { color: #a87226; }
.engineering-candidates { display: grid; gap: 8px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.workspace aside button.engineering-candidate { display: grid; gap: 3px; min-width: 0; padding: 6px; border: 1px solid #bccbc2; border-radius: 7px; background: #f8faf7; color: #263c32; text-align: left; }
.workspace aside button.engineering-candidate.active { border-color: #218d70; background: #e6f3eb; box-shadow: inset 0 0 0 1px #218d70; }
.engineering-candidate strong { font-size: 14px; }
.engineering-candidate svg { display: block; width: 100%; height: 100px; }
.engineering-candidate span { font-size: 11px; }
body {
  user-select: none;
}
input,
textarea,
[contenteditable],
.form-error {
  user-select: text;
}
.workspace {
  position: relative;
}
.layer-search-overlay {
  position: absolute;
  z-index: 1300;
  top: 14px;
  left: 50%;
  display: flex;
  align-items: center;
  gap: 8px;
  width: min(520px, calc(100% - 32px));
  min-height: 42px;
  padding: 5px 7px 5px 13px;
  box-sizing: border-box;
  transform: translateX(-50%);
  color: #f2f3f4;
  background: rgba(64, 68, 72, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 14px;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.28), inset 0 1px rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(20px) saturate(115%);
  -webkit-backdrop-filter: blur(20px) saturate(115%);
}
.layer-search-overlay[hidden] { display: none; }
.layer-search-icon {
  flex: 0 0 auto;
  color: #e0e3e6;
  font: 25px/1 Georgia, serif;
  transform: rotate(-20deg);
}
.layer-search-overlay input {
  flex: 1 1 auto;
  min-width: 0;
  height: 30px;
  margin: 0;
  padding: 0 2px;
  color: #f6f7f8;
  background: transparent;
  border: 0;
  outline: 0;
  box-shadow: none;
  font: 14px/30px system-ui, sans-serif;
}
.layer-search-overlay input::placeholder { color: #d0d3d6; }
.layer-search-overlay input::-webkit-search-cancel-button,
.layer-search-overlay input::-webkit-search-decoration {
  display: none;
  -webkit-appearance: none;
}
.layer-search-overlay button {
  flex: 0 0 auto;
  height: 28px;
  padding: 0 8px;
  color: #eceff1;
  background: rgba(255, 255, 255, 0.11);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  font-size: 12px;
}
.layer-search-overlay button:hover { background: rgba(255, 255, 255, 0.2); }
.layer-search-overlay .layer-search-clear {
  width: 25px;
  padding: 0;
  color: #dfe2e5;
  background: transparent;
  border-color: transparent;
  font-size: 18px;
}
.layer-search-overlay .layer-search-close { color: #e3e6e8; }
.picker-empty {
  width: 256px;
  box-sizing: border-box;
  padding: 16px 14px;
  color: #c0d0ca;
  background: #182a34df;
  border-radius: 9px;
  text-align: center;
  font-size: 12px;
}
.layer-picker {
  position: fixed;
  z-index: 1200;
  width: 256px;
  padding: 7px;
  border: 1px solid #b9cfc3;
  border-radius: 12px;
  background: #f8faf8;
  box-shadow: 0 12px 38px #183d302b;
}
.picker-row {
  display: grid;
  grid-template-columns: 24px 1fr 28px;
  align-items: center;
  width: 100%;
  min-height: 37px;
  border: 0;
  border-radius: 6px;
  text-align: left;
  background: transparent;
  color: #314c40;
}
.picker-row.alternate {
  background: #eaf0eb;
}
.picker-row.current {
  background: #285e47;
  color: white;
  box-shadow: 0 2px 6px #143b3026;
}
.picker-row.faded {
  opacity: 0.45;
}
.picker-row.current.faded {
  opacity: 1;
}
.picker-row small {
  text-align: right;
}
.sidebar-resizer {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 7px;
  z-index: 20;
  cursor: col-resize;
  touch-action: none;
}
.sidebar-resizer:hover {
  background: #488c6566;
}
.sidebar-resizer.left::after {
  content: '⋮';
  position: absolute;
  top: 48%;
  left: 0;
  color: #34745a;
  background: #f5f8f4;
  border-radius: 3px;
}
.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding-top: 18px;
}
.cancel-settings {
  border: 1px solid #3d8963;
  color: #286b49;
  background: transparent;
}
.editor-dialog .dialog-heading {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #fff;
}
.editor-dialog hr {
  height: 1px;
  border: 0;
  background: #7ab895;
  margin: 22px 0;
}
.canvas-help {
  background: none !important;
  border: 0 !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
  opacity: 1 !important;
  color: #111 !important;
  font-size: 13px !important;
  -webkit-text-stroke: 3px white;
  paint-order: stroke fill;
  text-shadow: none !important;
  pointer-events: none;
}
.layers .layer {
  display: flex;
  align-items: center;
  gap: 2px;
  padding-left: 10px;
  padding-right: 8px;
}
.layers .layer button,
.layers .layer-group-actions button {
  width: 22px;
  min-width: 22px;
  padding: 2px;
}
.layers .layer-group {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-left: 10px;
  padding-right: 8px;
}
.layers .layer-group-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 2px;
  width: auto;
  min-width: 0;
}
.layers .layer-index {
  width: 28px;
  padding: 1px;
  border: 0;
  border-radius: 3px;
  color: #6b7c71;
  background: transparent;
  font-size: 11px;
  text-align: center;
  appearance: textfield;
}
.layer-index::-webkit-inner-spin-button {
  display: none;
}
.layers .layer-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.layers .layer-group-actions::before {
  content: none;
}
.layers .layer-group-actions {
  width: auto;
  min-width: 0;
  flex: 0 0 auto;
}
.layers .aside-footer {
  width: inherit;
  max-width: 100%;
}

.help-content {
  width: min(550px, 100%);
  max-height: 65vh;
  overflow-y: auto;
  padding: 0 12px;
  line-height: 1.5;
}
.help-content dl {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 6px 16px;
}
.help-content dd { margin: 0; }
.help-content kbd { font-weight: 700; }
.android-editor #ofmpAbout .help-content {
  margin-inline: auto;
  padding: 12px 20px;
}

#ofmpAbout .help-content h3 {
  margin-top: 0;
  padding-top: 0;
  border: 0;
}
#ofmpAbout .dialog-close svg { width: 20px; height: 20px; }
#ofmpAbout .help-content details { margin: 16px 0; }
#ofmpAbout .help-license { white-space: pre-wrap; }
.android-editor #ofmpAbout .dialog-heading {
  justify-content: flex-start;
  gap: 12px;
}
