:root { color-scheme: light; --bg:#fff5f7; --fg:#483d43; --muted:#856e7a; }
#account-bar { position:fixed; top:12px; right:20px; left:20px; display:flex; justify-content:flex-end; align-items:center; gap:16px; z-index:2; font:13px/1.5 system-ui,sans-serif; color:var(--muted); }
#account-bar button { position:static; display:inline-block; width:auto; height:auto; padding:6px 0; border-radius:0; font:inherit; white-space:nowrap; }
#account-status { text-align:right; }
* { box-sizing:border-box; }
html,body { margin:0; height:100%; }
body { background:var(--bg); color:var(--fg); font:17px/1.65 ui-monospace, 'Cascadia Code', 'SFMono-Regular', Consolas, monospace; cursor:text; }
#terminal { position:fixed; inset:0; display:flex; flex-direction:column; overflow-y:auto; padding:40px 28px max(12vh,40px); overflow-wrap:anywhere; }
#conversation { margin-top:auto; white-space:pre-wrap; }
.message { margin:0 0 1.1em; max-width:760px; }
.reply { color:var(--muted); }
#form { position:relative; flex-shrink:0; max-width:760px; }
#line { white-space:pre-wrap; min-height:1.65em; padding-right:52px; }
#cursor { background:var(--fg); animation:blink 1s steps(1) infinite; }
#cursor.busy { animation:none; opacity:.4; }
@keyframes blink { 50% { opacity:0; } }
#answer { display:none; width:calc(100% - 52px); min-height:1.65em; border:0; padding:0; margin:0; background:transparent; color:var(--fg); caret-color:var(--fg); font:inherit; letter-spacing:inherit; outline:none; resize:none; overflow:hidden; overflow-wrap:anywhere; }
#form.editing #line { display:none; }
#form.editing #answer { display:block; }
#caret-mirror { position:absolute; top:0; left:0; width:calc(100% - 52px); white-space:pre-wrap; overflow-wrap:anywhere; visibility:hidden; pointer-events:none; font:inherit; letter-spacing:inherit; }
#input-cursor { position:absolute; width:1ch; height:1.25em; background:var(--fg); opacity:.55; pointer-events:none; animation:input-blink 1s steps(1) infinite; }
#input-cursor[hidden] { display:none; }
#form.block-caret #answer { caret-color:transparent; }
@keyframes input-blink { 50% { opacity:0; } }
button { position:absolute; top:-8px; right:0; display:grid; place-items:center; width:44px; height:44px; padding:0; background:none; color:var(--muted); border:0; border-radius:50%; cursor:pointer; transition:color .15s,background .15s; }
button[hidden] { display:none; }
button:hover { color:var(--fg); background:#483d4308; }
button:focus-visible { outline:1px solid var(--muted); outline-offset:2px; }
#status { color:#a13e58; font-size:14px; margin:8px 0 0; }
#status:empty { display:none; }
.sr-only { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); }
@media(max-width:600px) { #terminal { padding-left:20px; padding-right:20px; } }
@media(prefers-reduced-motion:reduce) { #cursor,#input-cursor { animation:none; } }
