#memory-dialog{width:min(680px,calc(100vw - 28px));max-height:86dvh;padding:24px;border:1px solid #dce4d4;border-radius:18px;background:#fcfdf9;color:#45523d;overflow:auto}#memory-dialog::backdrop{background:#26351f66}#memory-dialog header{display:flex;align-items:center;justify-content:space-between;gap:12px}#memory-dialog h2{font-size:23px}#memory-dialog .memory-policy,#memory-status{font-size:13px;line-height:1.8;margin:14px 0}#memory-status{color:#647558;white-space:pre-wrap}#memory-dialog label{display:block;margin:12px 0 6px;font-size:13px}#memory-dialog select,#memory-dialog input,#memory-text{font:inherit;width:100%;padding:10px 12px;border:1px solid #cfd9c6;border-radius:9px;background:white;color:inherit;box-sizing:border-box}#memory-text{resize:vertical}.memory-card{padding:14px 0;border-top:1px solid #e1e7db}.memory-card p{white-space:pre-wrap;overflow-wrap:anywhere;margin:7px 0;line-height:1.7;font-size:14px}.memory-card small{font-size:11px;color:#6f7d64}.memory-card details{font-size:12px;margin:9px 0}.memory-card summary{cursor:pointer}.memory-card a{display:block;color:#526b47;text-decoration:underline;margin:4px 0}.memory-card button,#memory-ignored button{margin:8px 10px 0 0;padding:7px 10px;border:1px solid #cbd8c2;border-radius:8px;background:#f2f6ed;color:#4e6444;cursor:pointer}#memory-form{border-top:1px solid #d9e2d1;margin-top:18px;padding-top:18px}#memory-form h3{font-size:16px}.memory-actions{display:flex;gap:10px;margin-top:16px}#memory-dialog button:disabled{opacity:.5;cursor:default}#memory-count{font-size:12px;color:#7a876f;margin:10px 0}.chat-recall{font-size:12px;color:#66795c;margin:5px 0 18px;padding:8px 12px;border-left:2px solid #d2dec6}.chat-recall a{color:inherit;text-decoration:underline}.chat-recall button{display:block}#chat-loading{margin:12vh auto;color:#7b8a6d;text-align:center}@media(max-width:600px){#memory-dialog{padding:18px;max-height:90dvh}.memory-actions{flex-wrap:wrap}}

#memory-dialog header{position:sticky;top:0;background:#fcfdf9;z-index:2;padding:10px 0;border-bottom:1px solid #e5eadf}#memory-dialog header>div{flex:1;min-width:0}#memory-dialog header .eyebrow{font-size:10px;letter-spacing:1px;margin:0 0 4px}#memory-dialog header h2{margin:0}#memory-dialog header button{flex-shrink:0}.memory-actions{position:sticky;bottom:0;background:#fcfdf9;padding:12px 0;z-index:1}#memory-dialog #memory-add{font-size:12px;padding:9px 12px}

.soul-panel{margin:20px 0;padding:18px;background:#f1f5ed;border:1px solid #dce4d4;border-radius:12px}.soul-panel h3{margin:0 0 10px}.soul-panel p{font-size:13px;line-height:1.7}#soul-core{display:block;width:100%;box-sizing:border-box;font:inherit;font-size:14px;line-height:1.8;padding:12px;border:1px solid #cfd9c6;border-radius:9px;background:#fff;color:inherit;resize:vertical}#memory-dialog #soul-growth{width:auto;margin-right:8px}#soul-status{white-space:pre-wrap}#soul-save{margin:10px 8px 0 0}

.chat-memory-note{font-size:11px;color:#718365;margin:0 10px 14px;line-height:1.8}.chat-memory-note button{font-size:11px;margin-left:8px}
