#editor{width:min(1260px,96vw);max-height:94vh;padding:24px 32px;background:#f8faf9}
#editor .dialog-head{border-bottom:1px solid var(--line);padding-bottom:12px}
#editorTitle{max-width:80%;overflow-wrap:anywhere}
#questionPreview{max-height:270px;overflow:auto;background:#fff;padding:20px;border:1px solid var(--line);border-radius:8px}
#moodleFields details{border-bottom:1px solid var(--line);padding:12px 0}
#moodleFields summary{color:var(--green);font-size:17px;margin-bottom:16px}
#moodleFields label{max-width:650px}
.field-caption{font-weight:600;margin:18px 0 8px}
.rich-field{margin:16px 0}.rich-toolbar{display:flex;gap:3px;flex-wrap:wrap;background:#edf0f2;padding:6px;border:1px solid #bfcacb;border-radius:5px 5px 0 0}
.rich-toolbar button{font-size:13px;min-width:32px;padding:5px 9px;background:white;border:1px solid #c4cdcf;border-radius:3px;color:#294853}
.rich-body{min-height:110px;max-height:520px;overflow:auto;background:white;border:1px solid #bfcacb;border-top:0;padding:15px;outline:none;resize:vertical}
.rich-body:focus{box-shadow:inset 0 0 0 2px #549180}.rich-body img{max-width:100%;cursor:pointer}.rich-body table{width:auto;min-width:160px}.rich-body td,.rich-body th{border:1px solid #a6b7b4;min-width:45px}
.answer-card{background:#f0f3f3;border:1px solid #d3dddd;padding:12px 22px;margin:18px 0;border-radius:7px}.answer-card .rich-body{min-height:65px}.answer-card select{max-width:240px}
.editor-actions{display:flex;gap:8px;flex-wrap:wrap;position:sticky;bottom:-24px;background:#f8faf9;padding:16px 0;border-top:1px solid var(--line);z-index:2}
.editor-tool{width:min(720px,94vw);max-height:90vh}.editor-tool img{max-width:100%}.editor-tool textarea{margin:12px 0}.editor-tool .rich-toolbar{margin:10px 0}
.symbol-grid{display:grid;grid-template-columns:repeat(8,1fr);gap:4px;margin:18px 0}.symbol-grid button{font-size:22px;padding:8px}.formula-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:5px}.formula-grid button{min-height:44px;overflow:auto}.formula-preview{padding:22px;min-height:80px;background:#f4f7f5;margin:10px 0;overflow:auto}
.editor-tool .answer img{max-width:100%}.katex{font-size:1.15em}
@media(max-width:650px){#editor{padding:14px}.rich-toolbar button{padding:7px}.answer-card{padding:10px}.editor-actions{bottom:-14px}.editor-actions button{width:100%}.formula-grid{grid-template-columns:repeat(2,1fr)}}
.rich-toolbar select{width:auto;max-width:160px;padding:4px 8px;font-size:13px}.dialog-message{position:sticky;top:0;z-index:4}
