:root{--bg: #f4f6f5;--panel: #ffffff;--ink: #16211e;--muted: #62706b;--line: #dde3e0;--accent: #0e6b5c;--accent-ink: #ffffff;--user: #e3efeb;--danger: #b3261e}@media (prefers-color-scheme: dark){:root{--bg: #0f1514;--panel: #172120;--ink: #e8efec;--muted: #98a8a2;--line: #28352f;--accent: #3fb59f;--accent-ink: #08201b;--user: #1f3430;--danger: #ff8a80}}*{box-sizing:border-box}html,body,#root{height:100%;margin:0}body{font-family:Figtree,system-ui,sans-serif;background:var(--bg);color:var(--ink);line-height:1.55}button,input,textarea{font:inherit;color:inherit}:focus-visible{outline:2px solid var(--accent);outline-offset:2px}.muted{color:var(--muted)}.small{font-size:13px}.error{color:var(--danger)}.center{min-height:100%;display:grid;place-items:center;padding:24px}button.primary{background:var(--accent);color:var(--accent-ink);border:0;border-radius:8px;padding:10px 16px;font-weight:500;cursor:pointer}button.primary:disabled{opacity:.5;cursor:not-allowed}button.link{background:none;border:0;color:var(--accent);cursor:pointer;padding:4px 0;text-align:left}button.icon{background:none;border:0;cursor:pointer;color:var(--muted);font-size:20px;line-height:1;padding:4px 8px;border-radius:6px}button.icon:hover{background:var(--line)}.auth{width:100%;max-width:380px;background:var(--panel);border:1px solid var(--line);border-radius:12px;padding:28px;display:flex;flex-direction:column;gap:8px}.auth h1{font-size:22px;margin:0;font-weight:600}.auth p{margin:0 0 8px}.auth label{font-size:14px;font-weight:500;margin-top:6px}.auth input{border:1px solid var(--line);background:var(--bg);border-radius:8px;padding:10px 12px}.auth .primary{margin-top:12px}.info{color:var(--accent)}.app{height:100%;display:grid;grid-template-columns:280px 1fr}.sidebar{background:var(--panel);border-right:1px solid var(--line);padding:16px;display:flex;flex-direction:column;gap:12px;min-height:0}.sidebar nav{flex:1;overflow-y:auto;display:flex;flex-direction:column;gap:2px}.conv{display:flex;align-items:center;border-radius:8px}.conv.active{background:var(--user)}.conv:hover:not(.active){background:var(--bg)}.conv-title{flex:1;min-width:0;text-align:left;background:none;border:0;padding:8px 10px;cursor:pointer;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.account{border-top:1px solid var(--line);padding-top:12px;display:flex;flex-direction:column;gap:2px}.account span{overflow:hidden;text-overflow:ellipsis}.main{display:flex;flex-direction:column;min-height:0;height:100%}.topbar{display:none;align-items:center;gap:8px;padding:10px 12px;border-bottom:1px solid var(--line);background:var(--panel)}.messages{flex:1;overflow-y:auto;padding:24px 16px;display:flex;flex-direction:column;gap:14px}.messages>*{width:100%;max-width:720px;margin-inline:auto}.empty{margin-top:12vh;text-align:center}.empty h2{font-size:24px;margin:0 0 6px;font-weight:600}.msg{padding:10px 14px;border-radius:12px;max-width:85%}.msg p{margin:0;white-space:pre-wrap}.msg.user{background:var(--user);margin-left:auto;margin-right:calc((100% - min(100%,720px))/2)}.msg.assistant{background:var(--panel);border:1px solid var(--line);margin-right:auto;margin-left:calc((100% - min(100%,720px))/2)}.msg.assistant>:first-child{margin-top:0}.msg.assistant>:last-child{margin-bottom:0}.msg.assistant pre{overflow-x:auto;background:var(--bg);padding:10px;border-radius:8px}.msg.assistant code{font-size:.9em}.typing{display:flex;gap:5px;width:fit-content}.typing span{width:7px;height:7px;border-radius:50%;background:var(--muted);animation:blink 1.2s infinite ease-in-out}.typing span:nth-child(2){animation-delay:.2s}.typing span:nth-child(3){animation-delay:.4s}@keyframes blink{0%,80%,to{opacity:.25}40%{opacity:1}}@media (prefers-reduced-motion: reduce){.typing span{animation:none;opacity:.6}}.banner{margin:0 16px;padding:8px 12px;border:1px solid var(--danger);border-radius:8px;max-width:720px;width:calc(100% - 32px);align-self:center}.composer{display:flex;gap:10px;padding:12px 16px 16px;width:100%;max-width:752px;margin-inline:auto;align-items:flex-end}.composer textarea{flex:1;resize:none;max-height:160px;border:1px solid var(--line);background:var(--panel);border-radius:10px;padding:10px 12px;field-sizing:content}@media (max-width: 760px){.app{grid-template-columns:1fr}.sidebar{position:absolute;top:0;right:25%;bottom:0;left:0;z-index:10;transform:translate(-100%);transition:transform .2s}.sidebar.open{transform:none;box-shadow:0 0 0 100vmax #00000059}.topbar{display:flex}.msg{max-width:92%}}
