/* Memo image editing stays inside the memo theme. */
.memo-rich-editor{display:block;min-height:150px;max-height:65vh;overflow:auto;white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.7;background:var(--memo-input-bg);color:var(--memo-text);cursor:text}
.memo-rich-editor:focus{outline:2px solid var(--memo-accent);outline-offset:1px}
.memo-rich-toolbar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:8px 0}
.memo-rich-toolbar small,.memo-image-feedback{color:var(--memo-muted);font-size:12px}
.memo-image-block{display:block;position:relative;max-width:100%;margin:12px 0;white-space:normal;min-height:52px}
.memo-image-block img{display:block;max-width:100%;height:auto;max-height:65vh;object-fit:contain;object-position:left;border-radius:8px;cursor:zoom-in;background:white}
.memo-image-block img:not([src]){min-height:45px}
.memo-image-status{display:block;font-size:12px;color:var(--memo-muted)}
.memo-image-tools{display:flex;gap:6px;margin-top:6px}
.memo-image-viewer{width:fit-content;max-width:95vw;max-height:94vh;padding:16px;border-radius:14px;background:var(--popup-bg);color:var(--popup-text);border:1px solid var(--popup-border)}
.memo-image-viewer::backdrop{background:#0009}
.memo-image-viewer>div{overflow:auto;max-height:80vh;margin-top:12px}
.memo-image-viewer img{display:block;max-width:none;background:white}

.memo-image-status[hidden],.memo-image-file[hidden],.memo-image-feedback[hidden]{display:none}

.memo-image-tools{flex-wrap:wrap}
#panel-memos .memo-image-tools button[aria-pressed="true"]{background:var(--memo-accent);color:var(--memo-accent-text);border-color:var(--memo-accent)}

