.element.selected::after { display: none; }
.resize-handle {
  display: none;
  position: absolute;
  right: 0;
  bottom: 0;
  width: 12px;
  height: 12px;
  border: 1px solid var(--blue);
  border-radius: 2px;
  background: #fff;
  cursor: nwse-resize;
  touch-action: none;
}
.element.selected .resize-handle { display: block; }
.element { touch-action: none; }
.image-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 1px dashed #7c86a0;
  background-color: #f4f6fa;
  background-image: linear-gradient(45deg, #e9ecf2 25%, transparent 25%), linear-gradient(-45deg, #e9ecf2 25%, transparent 25%), linear-gradient(45deg, transparent 75%, #e9ecf2 75%), linear-gradient(-45deg, transparent 75%, #e9ecf2 75%);
  background-position: 0 0, 0 8px, 8px -8px, -8px 0;
  background-size: 16px 16px;
  color: #536078;
}
.image-placeholder-icon { padding: 4px 7px; border-radius: 5px; background: #fff; font-size: 10px; font-weight: 700; letter-spacing: .08em; }
.image-placeholder-label { padding: 3px 6px; border-radius: 4px; background: #ffffffdd; font-size: 12px; }
.element.editor-hidden { display: none; }
.selection-box {
  position: absolute;
  border: 1px dashed var(--blue);
  background: rgba(79, 70, 229, 0.14);
  pointer-events: none;
  z-index: 5;
}
.element-list-help { margin: 0 0 6px; color: #7b8494; font-size: 11px; line-height: 1.4; }
.element-list { display: flex; flex-direction: column; gap: 5px; }
.element-list-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; border: 1px solid var(--border); border-radius: 7px; background: #fff; overflow: hidden; }
.element-list-item[draggable="true"] { cursor: grab; }
.element-list-item.background-item { grid-template-columns: minmax(0, 1fr); background: #f8f9fb; }
.element-list-item.dragging { opacity: .5; cursor: grabbing; }
.element-list-item.drag-over { border-color: var(--blue); box-shadow: 0 0 0 1px var(--blue) inset; }
.element-list-select { display: flex; flex-direction: column; gap: 3px; min-width: 0; padding: 8px 9px; border: 0; background: transparent; text-align: left; cursor: pointer; }
.element-list button strong { overflow: hidden; font-size: 12px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.element-list button small, .element-list-empty { color: #7b8494; font-size: 11px; }
.element-list-item.selected { border-color: var(--blue); background: #efeeff; color: var(--blue); }
.element-list-item.hidden-element .element-list-select { opacity: .58; }
.element-visibility { align-self: stretch; padding: 0 8px; border: 0; border-left: 1px solid var(--border); background: #f8f9fb; color: #596579; font-size: 11px; cursor: pointer; }
.geometry-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 0 8px; margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--border); }
.visibility-button { width: 100%; margin-top: 10px; }
.element-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; margin-top: 7px; }
.source-actions { display: grid; gap: 6px; margin-top: 8px; }
.source-actions .button { width: 100%; text-align: center; font-size: 12px; }
.source-file-button input { display: none; }
#backgroundFields { display: grid; gap: 6px; }
#backgroundFields label { margin: 0; }
#backgroundFields .button { width: 100%; text-align: center; font-size: 12px; }
.background-toggle { display: flex; align-items: center; gap: 8px; font-size: 12px; }
.background-toggle input { margin: 0; }
.page-background { position: absolute; inset: 0; pointer-events: none; }
.border-element { background: transparent; }
.line-element { overflow: visible; padding: 0; border: 1px solid transparent; }
.line-stroke { position: absolute; top: 50%; left: 0; width: 100%; height: 0; pointer-events: none; }
