/* Busi Studio PDF/design workspace */
.ed{display:flex;flex-direction:column;gap:8px}
.ed-top{display:flex;flex-wrap:wrap;gap:6px;align-items:center;background:#fff;border:1px solid #e5e7eb;border-radius:10px;padding:6px 8px;position:sticky;top:0;z-index:5}
.ed-group{display:flex;gap:4px;align-items:center;padding:0 6px;border-right:1px solid #eee;font-size:13px}
.ed-group:last-child{border-right:0}
.ed-sp{flex:1}
.ed-lbl{color:#6b7280;font-size:12px}
.ed-top button,.ed-text-bar button,.ed-actions button,#ed-panel button{border:1px solid #d1d5db;background:#f9fafb;border-radius:6px;padding:4px 8px;cursor:pointer;font-size:13px}
.ed-top button:hover,.ed-text-bar button:hover{background:#f3f4f6}
.ed-top button.pri,.ed-text-bar button.pri{background:#dc2626;color:#fff;border-color:#dc2626}
.ed-top select,.ed-text-bar select{border:1px solid #d1d5db;border-radius:6px;padding:4px 6px;font-size:13px;max-width:180px}

/* projectacties: horen bij de titel, niet tussen de kleine bewerkingsknoppen */
.ed-actions{display:inline-flex;gap:8px;vertical-align:middle;margin-left:14px}
.ed-actions button{padding:7px 14px;font-size:14px;border-radius:8px}
.ed-actions button.pri{background:#dc2626;color:#fff;border-color:#dc2626}
.ed-actions-inline{margin:0 0 4px;padding:6px 8px;background:#fff;border:1px solid #e5e7eb;border-radius:10px;display:flex;justify-content:flex-end}

/* tekstbalk */
.ed-text-bar{display:flex;flex-wrap:wrap;gap:6px;align-items:center;background:#fff;border:1px solid #e5e7eb;border-radius:10px;padding:6px 8px}
.ed-text-bar.off{opacity:.45;pointer-events:none}
.ed-text-bar input[type=number]{border:1px solid #d1d5db;border-radius:6px;padding:4px 6px;font-size:13px}
.ed-text-bar input[type=color]{width:34px;height:28px;padding:0;border:1px solid #d1d5db;border-radius:6px;background:#fff;cursor:pointer}
.ed-fontbtn{min-width:190px;display:inline-flex;justify-content:space-between;gap:8px;align-items:center;overflow:hidden}
.ed-fontbtn #ed-fontname{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:170px}
.ed-fontbtn .caret{color:#6b7280;flex:none}
.ed-tg.on{background:#111827;color:#fff;border-color:#111827}
.ed-miss{background:#fef2f2;color:#b91c1c;border:1px solid #fecaca;border-radius:5px;padding:2px 6px;font-size:11px}
.ed-hint{color:#6b7280;font-size:12px}

.ed-body{display:flex;gap:10px;min-height:60vh}
.ed-canvas-wrap{flex:1;overflow:auto;background:#e5e7eb;border-radius:10px;padding:20px;max-height:78vh;position:relative}
.ed-stage{position:relative;margin:0 auto;background:#fff;box-shadow:0 2px 12px rgba(0,0,0,.25)}
.ed-svg{display:block;user-select:none;cursor:default}
.ed-hit{fill:transparent;stroke:transparent;cursor:move}
.ed-hit:hover{stroke:#dc2626;stroke-width:.6;stroke-dasharray:2 1}
.ed-text.native{opacity:1}
.ed-groupbox{fill:none;stroke:#7c3aed;stroke-width:.8;stroke-dasharray:4 2}
.ed-handle{fill:#fff;stroke:#dc2626;stroke-width:.7;cursor:nwse-resize}

/* tekst bewerken: een echt bewerkbaar veld boven het canvas, met cursor en selectie */
.ed-textedit{position:absolute;z-index:20;background:rgba(255,255,255,.96);outline:2px solid #dc2626;outline-offset:1px;
  white-space:pre-wrap;word-break:normal;overflow-wrap:break-word;min-height:1em;padding:0 2px;margin:0;caret-color:#dc2626;cursor:text}
.ed-textedit:focus{outline:2px solid #dc2626}

.ed-side{width:300px;flex:none;background:#fff;border:1px solid #e5e7eb;border-radius:10px;padding:8px;font-size:13px;max-height:78vh;overflow:auto}
.ed-tabs{display:flex;gap:4px;margin-bottom:8px}
.ed-tabs button{flex:1;border:1px solid #e5e7eb;background:#f9fafb;border-radius:6px;padding:5px;cursor:pointer;font-size:12px}
.ed-tabs button.on{background:#dc2626;color:#fff;border-color:#dc2626}
.ed-layer{display:flex;align-items:center;gap:3px;padding:4px 2px;border-bottom:1px solid #f3f4f6}
.ed-layer.hidden .nm{opacity:.45}
.ed-layer .nm{flex:1;cursor:pointer;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.ed-layer .nm small{color:#6b7280}
.ed-layer button{border:0;background:transparent;cursor:pointer;padding:2px;font-size:12px;line-height:1}
.ed-layer button:hover{background:#f3f4f6;border-radius:4px}
.st{display:inline-block;width:9px;height:9px;border-radius:50%;margin-right:3px;vertical-align:middle}
.st-native{background:#16a34a}.st-preserved{background:#2563eb}.st-reconstructed{background:#f59e0b}.st-flattened{background:#6b7280}
.ed-legend{margin-top:10px;color:#6b7280;font-size:11px;display:flex;flex-wrap:wrap;gap:6px}
.ed-row{display:flex;gap:6px;align-items:center;margin:6px 0;flex-wrap:wrap}
.ed-row button.sm,#ed-panel button.sm{border:1px solid #d1d5db;background:#f9fafb;border-radius:6px;padding:3px 8px;cursor:pointer;font-size:12px}
.ed-muted{color:#6b7280;font-size:12px;margin:4px 0}
.ed-props textarea{width:100%;box-sizing:border-box;border:1px solid #d1d5db;border-radius:6px;padding:6px;font:inherit;resize:vertical}
.ed-props input[type=number],.ed-props input[type=color],.ed-props select{border:1px solid #d1d5db;border-radius:6px;padding:3px;font:inherit}
.ed-props label.ed-lbl{display:block;margin:8px 0 3px}
.ed-grid2{display:grid;grid-template-columns:auto 1fr;gap:5px 8px;align-items:center;margin:8px 0}
.ed-grid4{display:grid;grid-template-columns:auto 1fr auto 1fr;gap:5px 6px;align-items:center;margin:8px 0}
.ed-grid2 label,.ed-grid4 label{color:#6b7280;font-size:12px}
.ed-grid4 input{width:100%;box-sizing:border-box}
.ed-fontlist{margin:8px 0;max-height:220px;overflow:auto;border:1px solid #f3f4f6;border-radius:6px}
.ed-fontrow{display:flex;justify-content:space-between;align-items:center;gap:6px;padding:4px 6px;border-bottom:1px solid #f6f6f6;font-size:13px}
.ed-fontrow.miss{background:#fef2f2}
.ed-fontrow small{color:#6b7280;font-size:11px}
.ed-fontchoice{display:flex;flex-wrap:wrap;gap:8px;margin:8px 0}
#ed-out .opt{display:block;padding:4px 0}
#ed-out .opt small{color:#6b7280}

/* lettertypekiezer: alleen de zichtbare regels worden getekend, dus ook met tienduizenden namen snel */
.ed-picker{position:absolute;z-index:40;width:370px;background:#fff;border:1px solid #d1d5db;border-radius:10px;box-shadow:0 12px 34px rgba(0,0,0,.18);overflow:hidden}
.ed-picker-top{display:flex;gap:6px;padding:8px;border-bottom:1px solid #eee}
.ed-picker-top input{flex:1;border:1px solid #d1d5db;border-radius:6px;padding:5px 8px;font:inherit}
.ed-picker-top button{border:1px solid #d1d5db;background:#f9fafb;border-radius:6px;cursor:pointer;padding:4px 8px}
.ed-picker-tabs{display:flex;gap:4px;padding:6px 8px;border-bottom:1px solid #eee}
.ed-picker-tabs button{flex:1;border:1px solid #e5e7eb;background:#f9fafb;border-radius:6px;padding:4px;font-size:11px;cursor:pointer}
.ed-picker-tabs button.on{background:#111827;color:#fff;border-color:#111827}
.ed-picker-list{position:relative;height:300px;overflow-y:auto}
.ed-picker-pad{width:1px}
.ed-picker-rows{position:absolute;top:0;left:0;right:0}
.fp-row{display:flex;flex-direction:column;justify-content:center;gap:1px;padding:3px 10px;border-bottom:1px solid #f6f6f6;cursor:pointer;box-sizing:border-box;overflow:hidden}
.fp-row:hover{background:#fef2f2}
.fp-name{font-size:11px;color:#6b7280;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.fp-name small{color:#9ca3af}
.fp-prev{font-size:17px;line-height:1.15;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:#111827}
.ed-picker-note{padding:14px;font-size:12.5px;color:#4b5563;line-height:1.6;white-space:pre-line}
.ed-picker-foot{padding:6px 10px;border-top:1px solid #eee;font-size:11px;color:#6b7280}

@media (max-width:800px){.ed-body{flex-direction:column}.ed-side{width:auto;max-height:40vh}.ed-canvas-wrap{max-height:55vh}.ed-picker{width:94vw;left:3vw!important}}

/* paginaformaat en afdrukken */
.ed-pagesize .ed-grid2{grid-template-columns:auto 1fr;gap:6px 10px;max-width:520px}
.ed-pagesize select,.ed-pagesize input{border:1px solid #d1d5db;border-radius:6px;padding:4px 6px;font:inherit;width:100%;box-sizing:border-box}
.ed-pagesize .note.info{white-space:normal;line-height:1.55}
#ed-printframe{position:fixed;right:0;bottom:0;width:1px;height:1px;opacity:0;border:0}
@media print{body>*:not(#ed-printframe){display:none!important}}
