/* Owner utilities share the compact controls and outlined panels of Quick Agent Status. */
.dios-owner-utilities{display:flex;align-items:center;flex-wrap:wrap;gap:6px;margin-left:auto;min-width:0;max-width:100%}
.dios-ops-desk .dios-owner-utilities .dios-ops-privacy-toggle{margin-left:0;min-height:34px}
.memory-controls,.memory-fresh-group{display:flex;align-items:center;gap:6px;min-width:0}
.memory-controls{flex-wrap:wrap;max-width:100%;font-size:11px}
.memory-controls .memory-utility,.memory-info>summary{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:34px;padding:6px 9px;border:1px solid var(--border);border-radius:8px;background:#fff;color:var(--muted);font:inherit;font-weight:600;line-height:1.4;cursor:pointer;white-space:nowrap;box-sizing:border-box}
.memory-controls svg{width:16px;height:16px;flex-shrink:0}
.memory-controls .memory-fresh-toggle{position:relative;padding:0;border:0;background:transparent}
.memory-fresh-toggle input{position:absolute;opacity:0;width:1px;height:1px;min-height:0;margin:0}
.memory-fresh-toggle>span{display:inline-flex;align-items:center;gap:6px;min-height:34px;padding:6px 9px;border:1px solid var(--border);border-radius:8px;box-sizing:border-box}
.memory-controls button:hover,.memory-fresh-toggle:hover>span,.memory-info>summary:hover{background:#eef8f5;border-color:#9ecfc8;color:#08786d}
.memory-fresh-toggle input:checked+span{background:#eef8f5;border-color:#238579;color:#086c61}
.memory-fresh-toggle input:checked+span::after{content:'✓';font-size:11px}
.memory-fresh-toggle:has(input:disabled){opacity:.55;cursor:not-allowed}
.memory-controls button:focus-visible,.memory-info>summary:focus-visible,.memory-fresh-toggle input:focus-visible+span,.memory-bank-dialog button:focus-visible{outline:2px solid var(--accent);outline-offset:3px}
.memory-info{position:relative}
.memory-info>summary{width:30px;padding:0;background:#f8fbfb;list-style:none}
.memory-info>summary::-webkit-details-marker{display:none}
.memory-info-panel{position:absolute;right:0;bottom:calc(100% + 8px);z-index:100;width:280px;max-width:calc(100vw - 32px);padding:12px;border:1px solid var(--border);border-radius:10px;background:#fff;color:var(--ink);box-shadow:0 14px 42px #142a3b24;white-space:normal}
.memory-info-panel strong{font-size:12px}.memory-info-panel p{font-size:11px;line-height:1.65;color:var(--muted);margin:6px 0 0}
.memory-controls [data-memory-mode-note]{flex-basis:100%;max-width:360px;font-size:10px;color:var(--muted);line-height:1.5}
.memory-controls [hidden]{display:none}
.memory-bank-dialog{width:min(680px,calc(100vw - 32px));max-height:calc(100dvh - 48px);overflow:auto;overscroll-behavior:contain;padding:18px;background:#fff;color:var(--ink);border:1px solid var(--border);border-radius:14px;box-shadow:0 22px 70px #1018202e;box-sizing:border-box}
.memory-bank-dialog::backdrop{background:#10182055}
.memory-bank-dialog>header{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;padding-bottom:12px;border-bottom:1px solid var(--border)}
.memory-bank-dialog h2{font-size:18px;letter-spacing:-.35px;margin:4px 0}.memory-bank-dialog h3{font-size:14px;margin:0 0 14px}
.memory-bank-dialog p{font-size:12px;line-height:1.65;color:var(--muted);overflow-wrap:anywhere}
.memory-bank-dialog [data-memory-status]{padding:10px 12px;border:1px solid var(--border);border-radius:9px;background:#f7fafb}
.memory-bank-dialog article{padding:12px;margin:8px 0;border:1px solid var(--border);border-radius:10px;overflow-wrap:anywhere}
.memory-bank-dialog article strong{font-size:12px}.memory-bank-dialog article small{display:block;font-size:11px;line-height:1.5;color:var(--muted);margin-bottom:10px}
.memory-bank-dialog .button{min-height:34px;font-size:11px;padding:7px 10px;border-radius:8px;margin:0 6px 6px 0;max-width:100%;white-space:normal}
.memory-bank-dialog [data-memory-form]{margin-top:18px;padding-top:16px;border-top:1px solid var(--border)}
.memory-bank-dialog label{display:block;font-size:12px;color:var(--muted);margin-block:12px}
.memory-bank-dialog input,.memory-bank-dialog textarea,.memory-bank-dialog select{display:block;width:100%;max-width:100%;min-width:0;margin-top:6px;font-size:16px;background:#f8fbfb;color:var(--ink);border:1px solid var(--border);border-radius:8px;box-sizing:border-box}
.memory-bank-dialog textarea{min-height:90px;resize:vertical}
html[data-dios-theme=dark] .memory-controls .memory-utility,html[data-dios-theme=dark] .memory-info>summary{background:#21323e;color:#c9d7de;border-color:#405861}
html[data-dios-theme=dark] .memory-controls .memory-fresh-toggle{background:transparent}
html[data-dios-theme=dark] .memory-fresh-toggle>span{border-color:#405861}
html[data-dios-theme=dark] .memory-controls button:hover,html[data-dios-theme=dark] .memory-info>summary:hover,html[data-dios-theme=dark] .memory-fresh-toggle:hover>span,html[data-dios-theme=dark] .memory-fresh-toggle input:checked+span{background:#29404d;border-color:#487473;color:#91eee0}
html[data-dios-theme=dark] .memory-bank-dialog,html[data-dios-theme=dark] .memory-info-panel{background:#1b2a35;color:var(--ink);border-color:#405861}
html[data-dios-theme=dark] .memory-bank-dialog [data-memory-status],html[data-dios-theme=dark] .memory-bank-dialog input,html[data-dios-theme=dark] .memory-bank-dialog textarea,html[data-dios-theme=dark] .memory-bank-dialog select{background:#21323e;border-color:#405861}
html[data-dios-theme=dark] .memory-bank-dialog .dios-human-agent-close:hover{background:#29404d;color:#f1f7f9}
@media(max-width:750px){.dios-owner-utilities{margin-left:0;flex-basis:100%}}
@media(max-width:560px){.memory-info-panel{position:fixed;left:16px;right:16px;bottom:18px;width:auto;max-width:none}.memory-bank-dialog{padding:14px;width:calc(100vw - 24px);max-height:calc(100dvh - 24px)}.memory-bank-dialog .button{min-height:40px}}
@media(pointer:coarse){.memory-controls .memory-utility,.memory-fresh-toggle>span,.memory-info>summary,.dios-ops-desk .dios-owner-utilities .dios-ops-privacy-toggle{min-height:44px}.memory-info>summary{width:36px}}
html[data-dios-theme=dark] .memory-bank-dialog .button.primary{color:#102b2a}
/* Let the whole utility cluster wrap in reading order, without isolating OTR. */
.dios-owner-utilities .memory-controls{display:contents}
.dios-owner-utilities{font-size:11px}
@media(max-width:360px){.memory-fresh-toggle svg{display:none}}
/* Memory v2: scoped presentation only. Composer/Fresh Lens rules above remain unchanged. */
.memory-bank-dialog{--memory-surface:#fff;--memory-soft:#f7f9fa;--memory-teal:#006c62;--memory-tint:#e8f5f1;width:min(1040px,calc(100vw - 32px));max-height:calc(100dvh - 40px);padding:0;background:var(--memory-surface)}
.memory-bank-dialog [hidden]{display:none!important}
.memory-bank-dialog .memory-bank-head{display:block;position:relative;padding:24px 28px 18px;border-bottom:1px solid var(--border)}
.memory-bank-dialog .memory-bank-head h2{font-size:24px;margin:7px 40px 10px 0;letter-spacing:-.6px;line-height:1.3}
.memory-bank-dialog .memory-bank-head>[data-memory-close]{position:absolute;right:20px;top:18px}
.memory-bank-dialog .memory-eyebrow{font-size:11px;line-height:1.5;letter-spacing:1px;text-transform:uppercase;color:var(--memory-teal);font-weight:600}
.memory-bank-dialog .memory-bank-head>p{margin:0;font-size:13px;max-width:780px}
.memory-bank-dialog .memory-help{margin-top:12px}.memory-bank-dialog summary{cursor:pointer;font-size:12px;color:var(--muted);width:fit-content;max-width:100%;line-height:1.6}
.memory-bank-dialog .memory-help>summary{min-height:30px;padding:4px 0}
.memory-bank-dialog .memory-help>div{display:grid;grid-template-columns:1fr 1fr;gap:12px 22px;margin-top:8px;padding:15px 17px;background:var(--memory-soft);border:1px solid var(--border);border-radius:8px}
.memory-bank-dialog .memory-help p{margin:0}.memory-bank-dialog .memory-help strong{color:var(--ink)}
.memory-bank-dialog [data-memory-status]{margin:14px 28px;padding:10px 12px;background:var(--memory-soft);font-size:12px}
.memory-bank-body{display:grid;grid-template-columns:1.08fr 1fr;min-width:0}
.memory-saved,.memory-editor{padding:24px 28px;min-width:0}
.memory-editor{background:var(--memory-soft);border-left:1px solid var(--border)}
.memory-bank-dialog h3{font-size:18px;letter-spacing:-.3px;line-height:1.4;margin:0 0 12px}
.memory-section-heading{display:flex;align-items:center;justify-content:space-between;gap:8px}.memory-section-heading h3{margin-bottom:8px}
.memory-bank-dialog [data-memory-count]{display:inline-block;margin-left:6px;border-radius:4px;padding:2px 5px;font-size:12px;color:var(--muted);background:var(--memory-soft)}
.memory-bank-dialog .memory-saved>p{margin:0 0 8px;font-size:12px}
.memory-bank-dialog .memory-card{border:0;border-bottom:1px solid var(--border);border-radius:0;padding:17px 0;margin:0;overflow-wrap:anywhere}
.memory-labels{display:flex;gap:7px;flex-wrap:wrap;align-items:center}
.memory-tag,.memory-scope{display:inline-flex;padding:3px 7px;border-radius:5px;font-size:12px;line-height:1.5;background:var(--memory-soft);color:var(--muted)}
.memory-tag{background:var(--memory-tint);color:var(--memory-teal)}
.memory-bank-dialog .memory-value{font-size:15px;line-height:1.55;color:var(--ink);white-space:pre-wrap;margin:12px 0}
.memory-card-foot{display:flex;justify-content:space-between;align-items:center;gap:8px;flex-wrap:wrap}.memory-bank-dialog .memory-card-foot small{font-size:12px;margin:0}
.memory-card-actions{display:flex;gap:4px}.memory-bank-dialog .memory-card-actions .button{background:transparent;border-color:transparent;box-shadow:none;color:var(--muted);font-size:12px;padding:5px 7px;margin:0}
.memory-bank-dialog .memory-card-actions .button:hover{background:var(--memory-tint);color:var(--memory-teal)}
.memory-record-details{margin-top:10px}.memory-bank-dialog dl{display:grid;grid-template-columns:86px minmax(0,1fr);gap:7px 12px;font-size:12px;margin:10px 0;line-height:1.6}
.memory-bank-dialog dt{color:var(--muted)}.memory-bank-dialog dd{margin:0;overflow-wrap:anywhere}.memory-record-details dd{font-family:ui-monospace,monospace;font-size:11px}
.memory-bank-dialog [data-memory-history]{margin-top:20px}.memory-bank-dialog .memory-refresh{margin:16px 0 0;font-size:12px}
.memory-bank-dialog [data-memory-form]{padding:0;border:0;margin:0}.memory-bank-dialog label{font-weight:600;color:var(--ink);font-size:13px;margin:15px 0 7px}
.memory-bank-dialog input,.memory-bank-dialog textarea,.memory-bank-dialog select{background:var(--memory-surface);color:var(--ink);padding:10px 12px;margin-top:7px;font:inherit;font-size:14px;line-height:1.5}
.memory-bank-dialog textarea{min-height:112px;resize:vertical}.memory-fields{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.memory-bank-dialog .memory-hint,.memory-bank-dialog .memory-step{font-size:12px;line-height:1.6;margin:7px 0 15px}.memory-bank-dialog .memory-step{margin-bottom:20px}
.memory-bank-dialog .memory-review-submit{width:100%;min-height:40px;margin:20px 0 7px;font-size:13px}
.memory-bank-dialog .memory-confirmation{padding:20px;border:1px solid var(--border);border-radius:9px;background:var(--memory-surface);margin:18px 0}
.memory-bank-dialog .memory-confirmation-label{font-size:12px;font-weight:600;margin:0 0 10px}
.memory-bank-dialog .memory-confirmation blockquote{font-size:20px;line-height:1.5;letter-spacing:-.3px;color:var(--ink);white-space:pre-wrap;overflow-wrap:anywhere;margin:0 0 22px}
.memory-bank-dialog .memory-confirmation dl{font-size:13px;grid-template-columns:70px minmax(0,1fr);gap:12px;margin:0}
.memory-bank-dialog .memory-previous{padding-left:12px;border-left:2px solid var(--border);font-size:12px;white-space:pre-wrap}
.memory-review-actions{display:flex;gap:8px;margin:20px 0 12px}.memory-bank-dialog .memory-review-actions .button{margin:0;min-height:40px;font-size:13px}.memory-review-actions .primary{flex:1}
.memory-bank-dialog .memory-danger{color:#ab3434}.memory-bank-dialog .memory-empty{text-align:center;padding:34px 8px}
.memory-empty-icon{font-size:28px;color:var(--memory-teal);margin-bottom:12px}.memory-bank-dialog .memory-empty h4{font-size:18px;color:var(--ink);margin:0 0 10px}.memory-bank-dialog .memory-empty p{max-width:270px;margin:0 auto 15px;font-size:13px}
.memory-bank-dialog .memory-empty blockquote{font-size:14px;line-height:1.6;padding:15px;border:1px solid var(--border);border-radius:8px;background:var(--memory-soft);color:var(--ink);margin:20px 0}.memory-bank-dialog .memory-empty .button{font-size:13px;min-height:40px}
.memory-bank-dialog>footer{padding:13px 28px;border-top:1px solid var(--border);font-size:11px;line-height:1.6;color:var(--muted);display:flex;justify-content:space-between;gap:16px}
.memory-bank-dialog .memory-mobile-add,.memory-bank-dialog .memory-mobile-back{display:none}
.memory-bank-dialog button:focus-visible,.memory-bank-dialog summary:focus-visible,.memory-bank-dialog textarea:focus-visible,.memory-bank-dialog select:focus-visible{outline:2px solid var(--memory-teal);outline-offset:3px}
html[data-dios-theme=dark] .memory-bank-dialog{--memory-surface:#1b2a35;--memory-soft:#18252f;--memory-teal:#75dccc;--memory-tint:#203e40}
html[data-dios-theme=dark] .memory-bank-dialog textarea,html[data-dios-theme=dark] .memory-bank-dialog select{background:var(--memory-surface)}
html[data-dios-theme=dark] .memory-bank-dialog .memory-danger{color:#ffa5a5}
html[data-dios-theme=dark] .memory-bank-dialog .button.primary:hover{background:#91eee0;color:#102b2a;border-color:#91eee0}
@media(max-width:900px){.memory-saved,.memory-editor{padding:22px}.memory-fields{grid-template-columns:1fr;gap:0}}
@media(max-width:650px){.memory-bank-dialog{width:calc(100vw - 20px);max-height:calc(100dvh - 20px)}.memory-bank-dialog .memory-bank-head{padding:22px 20px 16px}.memory-bank-dialog .memory-bank-head h2{font-size:22px}.memory-bank-dialog .memory-bank-head>[data-memory-close]{right:12px;top:14px}.memory-bank-dialog .memory-bank-head>p{font-size:12px}.memory-bank-dialog .memory-help>div{grid-template-columns:1fr}.memory-bank-dialog [data-memory-status]{margin:12px 20px}.memory-bank-body{display:block}.memory-saved,.memory-editor{padding:22px 20px}.memory-editor{border-left:0;border-top:1px solid var(--border)}.memory-bank-dialog[data-memory-view=list] .memory-editor{display:none}.memory-bank-dialog:not([data-memory-view=list]) .memory-saved{display:none}.memory-bank-dialog .memory-mobile-add,.memory-bank-dialog .memory-mobile-back{display:inline-flex}.memory-bank-dialog .memory-mobile-back{margin:-6px 0 16px;font-size:12px;min-height:40px}.memory-bank-dialog textarea,.memory-bank-dialog select{font-size:16px}.memory-bank-dialog .button,.memory-bank-dialog .memory-card-actions .button{min-height:44px}.memory-bank-dialog>footer{display:block;padding:14px 20px}.memory-bank-dialog>footer span{display:block;margin-top:5px}.memory-bank-dialog .memory-confirmation{padding:17px}.memory-bank-dialog .memory-confirmation blockquote{font-size:19px}}
@media(pointer:coarse){.memory-bank-dialog .button,.memory-bank-dialog summary{min-height:44px}}
