.template-label{font-family:Kanit,sans-serif;font-size:12pt;--label-content-offset:0mm}
.template-element{position:absolute;box-sizing:border-box;overflow:hidden;line-height:1.25;white-space:pre-wrap}
.template-element img{width:100%;height:100%;object-fit:contain;display:block}.template-text{height:100%;overflow:hidden;overflow-wrap:break-word}
.template-code{display:flex;flex-direction:column}.template-symbol{flex:1;min-height:0}.template-symbol svg{width:100%;height:100%;display:block}.template-code-value{flex:none;height:5mm;font:10pt Arial,sans-serif;line-height:5mm;text-align:center;white-space:nowrap;overflow:hidden}.template-error{color:#a11925;font:10pt Kanit,sans-serif}
.template-design-canvas{overflow:visible}.template-design-canvas .template-element{outline:1px dashed #9aa9c0;cursor:move;touch-action:none}.template-design-canvas .template-element.selected{outline:2px solid #176bcc;z-index:2}.template-design-canvas .template-element>*{pointer-events:none}
.template-editor{display:grid;grid-template-columns:300px minmax(0,1fr);gap:20px;align-items:start}.template-tools{max-height:78vh;overflow:auto;position:sticky;top:70px}.template-workspace{min-width:0}.template-canvas-scroll{overflow:auto;background:#e7edf4;border:1px solid #ccd5e0;padding:20px;min-height:300px}.template-element-list{display:flex;gap:6px;flex-wrap:wrap}.template-element-list button{font-size:.8rem}.template-props{display:grid;grid-template-columns:1fr 1fr;gap:10px}.template-props label{font-size:.85rem}.template-props .full{grid-column:1/-1}
@media(max-width:900px){.template-editor{grid-template-columns:1fr}.template-tools{position:static;max-height:none}}
@media print{.template-label{overflow:hidden}.template-design-canvas .template-element{outline:none!important}}
.template-text{white-space:pre-wrap}

.template-object-tools{min-width:0;padding:14px}.template-object-tools fieldset{min-width:0}
.template-object-tools .template-props{grid-template-columns:repeat(8,minmax(0,1fr));gap:8px 10px;max-width:1120px;align-items:start}
.template-object-tools .template-props>div{min-width:0}.template-object-tools .template-props .full{grid-column:span 2}
.template-object-tools h2{margin-bottom:8px;font-size:.85rem}.template-object-tools .template-props label{font-size:.78rem;margin-bottom:3px;display:block}
.template-object-tools .form-control,.template-object-tools .form-select{min-width:0;width:100%;font-size:.82rem;min-height:30px;padding:4px 8px}
.template-object-tools .form-select{padding-right:28px}.template-object-tools textarea.form-control{height:32px;min-height:32px;resize:vertical}
.template-object-tools .template-props>label.full{display:flex;align-items:center;gap:5px;align-self:center;margin:0}
.template-object-tools .template-props p{font-size:.74rem;margin:4px 0 0}.template-object-tools .mt-3{margin-top:10px!important}
@media(max-width:1300px){.template-object-tools .template-props{grid-template-columns:repeat(4,minmax(0,1fr))}}
@media(max-width:650px){.template-object-tools .template-props{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:400px){.template-object-tools .template-props{grid-template-columns:minmax(0,1fr)}.template-object-tools .template-props .full{grid-column:1}}

.template-element.template-text-natural{overflow:visible}.template-text-natural>.template-text{height:auto;min-height:100%;overflow:visible}

