body {
  margin: 0;
  font-family: sans-serif;
  height: 100vh;
  display: flex;
  flex-direction: column;
}

.builder {
  display: flex;
  height: 100%;
  width: 100%;
}

.sidebar, .style-editor {
  width: 200px;
  background: #f4f4f4;
  padding: 1em;
  box-shadow: 2px 0 5px rgba(0,0,0,0.1);
}

.sidebar {
  border-right: 1px solid #ddd;
}

.component {
  padding: 0.5em;
  margin-bottom: 10px;
  background: white;
  border: 1px solid #ccc;
  cursor: grab;
}

.canvas {
  flex: 1;
  background: #fff;
  padding: 2em;
  overflow: auto;
  position: relative;
}

.dropped-element {
  padding: 10px;
  border: 1px dashed #aaa;
  margin: 10px;
  position: absolute;
  cursor: move;
  min-width: 100px;
}

footer {
  position: fixed;
  bottom: 10px;
  right: 10px;
}

.style-editor {
  display: flex;
  flex-direction: column;
  gap: 10px;
  border-left: 1px solid #ddd;
}

.style-editor input {
  width: 100%;
}

.dropped-element {
  position: absolute;
  min-width: 100px;
  min-height: 50px;
  box-sizing: border-box;
}

.resizer {
  width: 10px;
  height: 10px;
  background: #000;
  position: absolute;
  z-index: 10;
}

.resizer.br { bottom: 0; right: 0; cursor: se-resize; }
.resizer.bl { bottom: 0; left: 0; cursor: sw-resize; }
.resizer.tr { top: 0; right: 0; cursor: ne-resize; }
.resizer.tl { top: 0; left: 0; cursor: nw-resize; }
