.taqu-rule-editor { min-width:0; width:100%; display:grid; gap:8px; color:#142331; font-size:14px; }
.taqu-rule-editor-actions { display:flex; flex-wrap:wrap; gap:6px; }
.taqu-rule-editor-actions button { min-height:36px; padding:6px 12px; width:auto; font:inherit; border:1px solid #a9b7c5; border-radius:6px; background:#fff; color:#142331; cursor:pointer; }
.taqu-rule-editor button:focus-visible, .taqu-rule-editor .cm-content:focus-visible { outline:2px solid #156aab; outline-offset:2px; }
.taqu-rule-editor-hint, .taqu-rule-editor-status { margin:0; font-size:12px; line-height:1.6; color:#40566b; overflow-wrap:anywhere; }
.taqu-rule-editor-status[data-valid="false"] { color:#b22222; font-weight:700; }
.taqu-rule-editor-mount { min-height:260px; height:380px; max-height:80vh; resize:vertical; overflow:auto; border:1px solid #a9b7c5; border-radius:6px; background:#fff; }
.taqu-rule-editor .cm-editor { height:100%; min-height:100%; text-align:left; }
.taqu-rule-editor .cm-scroller { overflow:auto; font:13px/1.7 Consolas,'Noto Sans Mono',monospace; }
.taqu-rule-editor .cm-content { min-height:100%; padding:10px 0; }
.taqu-rule-editor .cm-gutters { background:#edf2f7; color:#52677c; border-right:1px solid #ccd6e0; }
.taqu-rule-editor .cm-focused { outline:2px solid #156aab; outline-offset:1px; }
.taqu-rule-editor .cm-tooltip { color:#142331; background:#fff; border:1px solid #a9b7c5; }
.taqu-rule-editor .cm-search input, .taqu-rule-editor .cm-search button { width:auto; min-height:30px; margin:3px; padding:3px 6px; font:inherit; }
.taqu-rule-editor-dialog { width:min(1280px,94vw); max-width:94vw; height:92dvh; max-height:92dvh; padding:16px; border:1px solid #a9b7c5; border-radius:10px; background:#fff; color:#142331; box-sizing:border-box; }
.taqu-rule-editor-dialog::backdrop { background:rgb(10 25 40 / .6); }
.taqu-rule-editor-dialog-head { display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:12px; }
.taqu-rule-editor-dialog-head h2 { margin:0; font-size:18px; }
.taqu-rule-editor-dialog-head button { width:auto; min-height:40px; padding:6px 12px; }
.taqu-rule-editor-dialog > .taqu-rule-editor { height:calc(100% - 56px); grid-template-rows:auto auto minmax(180px,1fr) auto; overflow:auto; }
.taqu-rule-editor-dialog .taqu-rule-editor-mount { height:100%; min-height:180px; max-height:none; resize:none; }
@media(pointer:coarse) { .taqu-rule-editor-actions button { min-height:44px; } }
