.admin-templates .listing-toolbar{display:flex;gap:8px;align-items:center;margin-bottom:8px}
.admin-templates .listing-toolbar input{min-width:0;max-width:360px;height:32px;padding:5px 10px}
.admin-templates .listing-toolbar .btn{white-space:nowrap;flex:none}
.admin-template-list{display:grid;grid-template-columns:repeat(auto-fill,minmax(250px,1fr));gap:8px}
.admin-template-list>.card{margin:0}
.admin-template{display:grid;text-align:left;gap:7px;padding:12px;cursor:pointer;font:inherit;min-width:0;background:var(--bg);color:var(--text);align-content:start}
.admin-template:hover{background:var(--hover)}.admin-template[hidden]{display:none}
.admin-template b{font-size:13px}.admin-template span{font-size:12px;line-height:1.45;color:var(--text2);display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden;white-space:pre-wrap;overflow-wrap:anywhere}
.template-editor{align-items:center;padding:16px;box-sizing:border-box}
.template-editor .dlg__box{display:flex;flex-direction:column;max-height:calc(100dvh - 32px);overflow:hidden}
.template-editor .dlg__head,.template-editor .dlg__foot{flex:none;padding:12px 16px}
.template-editor .dlg__head [data-dlg=cancel]{width:30px;height:30px;min-height:30px;padding:0;font-size:20px;line-height:1;flex:none}
.template-editor .dlg__body{overflow:auto;min-height:0;padding:8px 16px}
.template-editor .work-field{margin:8px 0}.template-editor textarea{min-height:180px;resize:vertical}
.template-markers{font-size:12px;display:flex;gap:6px;align-items:center;flex-wrap:wrap}.template-editor .dlg__foot{flex-wrap:wrap}
.template-markers .btn{font-size:11px;white-space:nowrap}
.template-editor #dlgMsg:not(:empty){margin:0;flex-basis:100%}
