:root{--lightningcss-light:initial;--lightningcss-dark: ;color-scheme:light dark;font-synthesis:none;text-rendering:optimizelegibility;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,sans-serif}@media (prefers-color-scheme:dark){:root{--lightningcss-light: ;--lightningcss-dark:initial}}html,body,#root{width:100%;height:100%;margin:0;padding:0}:root{--bg:#f5f5f7;--header-bg:#fff;--user-bg:#007aff;--user-fg:#fff;--asst-bg:#e9e9eb;--asst-fg:#1d1d1f;--text:#1d1d1f;--muted:#8e8e93;--border:#d1d1d6;--error:#ff3b30;--mic-base:#0a84ff;--mic-base-2:#0064d3;--mic-highlight:#ffffff8c;--mic-shadow:#00000040;--rec-red:#ff3b30}@media (prefers-color-scheme:dark){:root{--bg:#000;--header-bg:#1c1c1e;--user-bg:#0a84ff;--user-fg:#fff;--asst-bg:#2c2c2e;--asst-fg:#f2f2f7;--text:#f2f2f7;--muted:#8e8e93;--border:#38383a;--error:#ff453a;--mic-base:#0a84ff;--mic-base-2:#0050b0;--mic-highlight:#ffffff52;--mic-shadow:#0000008c;--rec-red:#ff453a}}*{box-sizing:border-box}html,body,#root{height:100%;margin:0}body{background:var(--bg);color:var(--text);-webkit-font-smoothing:antialiased;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica,Arial,sans-serif}.gate{flex-direction:column;gap:1rem;max-width:28rem;margin:4rem auto;padding:1.5rem;display:flex}.gate h1{margin:0;font-size:1.6rem}.gate p{color:var(--muted);margin:0}.gate input{border:1px solid var(--border);background:var(--header-bg);color:var(--text);border-radius:.5rem;padding:.75rem 1rem;font-size:1rem}.gate button{background:var(--user-bg);color:var(--user-fg);cursor:pointer;border:0;border-radius:.5rem;padding:.75rem 1rem;font-size:1rem}.gate button:disabled{opacity:.5;cursor:not-allowed}.chat{flex-direction:column;max-width:48rem;height:100%;margin:0 auto;display:flex}header{background:var(--header-bg);border-bottom:1px solid var(--border);justify-content:space-between;align-items:center;padding:.5rem 1rem;display:flex}header h1{margin:0;font-size:1rem;font-weight:600}header .logout{color:var(--muted);cursor:pointer;background:0 0;border:0;font-size:1.2rem}.messages{flex-direction:column;flex:1;gap:.4rem;padding:.75rem .75rem .25rem;display:flex;overflow-y:auto}.loading,.end{text-align:center;color:var(--muted);padding:.5rem;font-size:.8rem}.bubble-wrap{flex-direction:column;display:flex}.bubble-wrap.user{align-items:flex-end}.bubble-wrap.assistant,.bubble-wrap.system{align-items:flex-start}.bubble{word-wrap:break-word;white-space:pre-wrap;border-radius:1.1rem;flex-direction:column;gap:.25rem;max-width:80%;padding:.5rem .75rem;display:flex}.bubble-text{unicode-bidi:plaintext}.bubble.user{background:var(--user-bg);color:var(--user-fg);border-bottom-right-radius:.25rem}.bubble.assistant,.bubble.system{background:var(--asst-bg);color:var(--asst-fg);border-bottom-left-radius:.25rem}.bubble-meta{opacity:.65;gap:.5rem;margin-top:.1rem;font-size:.7rem;display:flex}.bubble.user .bubble-meta{color:var(--user-fg)}.bubble.assistant .bubble-meta,.bubble.system .bubble-meta{color:var(--muted)}.reactions{z-index:1;flex-wrap:wrap;gap:.25rem;margin:-.45rem .5rem .15rem;display:flex}.reaction{background:var(--header-bg);border:1px solid var(--border);cursor:default;-webkit-user-select:none;user-select:none;transform-origin:50%;border-radius:999px;padding:.05rem .45rem;font-size:.95rem;line-height:1.15;box-shadow:0 1px 2px #0000002e}.reaction.fresh{animation:.42s cubic-bezier(.34,1.56,.64,1) 1s both reaction-pop-in}@keyframes reaction-pop-in{0%{opacity:0;transform:scale(0)}to{opacity:1;transform:scale(1)}}.audio-player{width:100%;min-width:14rem;max-width:22rem;height:2.25rem}.bubble.user .audio-player{filter:invert()hue-rotate(180deg)}.audio-loading,.audio-error{opacity:.75;padding:.25rem 0;font-size:.8rem}.audio-error{color:var(--error)}.image-thumb-btn{cursor:zoom-in;background:0 0;border:0;padding:0;line-height:0;display:block}.image-thumb{border-radius:.5rem;width:auto;max-width:50%;height:auto;max-height:11rem;display:block}.lightbox{z-index:1000;padding:env(safe-area-inset-top,0) 1rem env(safe-area-inset-bottom,0);background:#000000d9;justify-content:center;align-items:center;animation:.18s ease-out lightbox-fade-in;display:flex;position:fixed;inset:0}.lightbox-img{object-fit:contain;border-radius:.4rem;max-width:100%;max-height:100%;box-shadow:0 8px 32px #00000080}.lightbox-close{top:calc(.5rem + env(safe-area-inset-top,0));color:#fff;cursor:pointer;-webkit-tap-highlight-color:transparent;background:#ffffff2e;border:0;border-radius:50%;justify-content:center;align-items:center;width:2.6rem;height:2.6rem;font-size:1.6rem;line-height:1;display:flex;position:absolute;right:.75rem}.lightbox-close:hover{background:#ffffff4d}.lightbox-close:active{transform:scale(.94)}@keyframes lightbox-fade-in{0%{opacity:0}to{opacity:1}}.image-loading,.image-error,.file-loading,.file-error{opacity:.75;padding:.25rem 0;font-size:.8rem}.image-error,.file-error{color:var(--error)}.file-link{color:inherit;align-items:center;gap:.35rem;padding:.2rem 0;font-size:.9rem;text-decoration:none;display:inline-flex}.file-link:hover{text-decoration:underline}.error{background:var(--error);color:#fff;padding:.5rem 1rem;font-size:.85rem}.composer-wrap{background:var(--header-bg);border-top:1px solid var(--border);padding-bottom:max(.5rem, env(safe-area-inset-bottom,0px))}.pending-hint{text-align:center;color:var(--muted);padding:.15rem .75rem;font-size:.75rem;font-style:italic}.composer{align-items:center;gap:.6rem;min-height:4.6rem;padding:.6rem .8rem;display:flex}.composer input,.composer .recording-indicator{border:1px solid var(--border);background:var(--bg);min-width:0;color:var(--text);border-radius:1.2rem;flex:1;align-items:center;height:2.6rem;padding:.6rem .9rem;font-size:1rem;transition:all .2s;display:flex}.composer input:focus{border-color:var(--mic-base);outline:none}.recording-indicator{font-variant-numeric:tabular-nums;gap:.75rem}.recording-indicator.cancel{color:var(--rec-red);border-color:var(--rec-red)}.rec-dot{background:var(--rec-red);border-radius:50%;flex:none;width:.6rem;height:.6rem;animation:1.2s ease-in-out infinite pulse}.recording-indicator.cancel .rec-dot{opacity:.5;animation:none}.rec-time{font-weight:500}.rec-hint{opacity:.75;align-items:center;gap:.3rem;margin-left:auto;font-size:.85rem;display:inline-flex}@keyframes pulse{0%,to{opacity:1;transform:scale(1)}50%{opacity:.4;transform:scale(.85)}}.action-btn{cursor:pointer;width:4.4rem;height:4.4rem;color:var(--user-fg);background:radial-gradient(circle at 30% 25%, var(--mic-highlight), transparent 55%), linear-gradient(160deg, var(--mic-base) 0%, var(--mic-base-2) 100%);box-shadow:0 6px 14px var(--mic-shadow), 0 2px 4px #0000002e, inset 0 1px 0 #ffffff80, inset 0 -3px 8px #00000038;touch-action:none;-webkit-user-select:none;user-select:none;-webkit-tap-highlight-color:transparent;border:0;border-radius:50%;flex:none;justify-content:center;align-items:center;transition:width .22s,height .22s,background .2s,box-shadow .2s,transform .12s;display:inline-flex}.action-btn:hover{transform:translateY(-1px)}.action-btn:active{transform:translateY(1px)}.action-btn:disabled{opacity:.45;cursor:not-allowed;transform:none}.action-btn.send{background:linear-gradient(160deg, var(--mic-base) 0%, var(--mic-base-2) 100%);width:2.6rem;height:2.6rem;box-shadow:0 2px 4px #0003,inset 0 1px #ffffff59}.action-btn.mic.is-recording{background:radial-gradient(circle at 50% 50%, #ff3b30d9, var(--mic-base-2) 75%);box-shadow:0 0 0 6px #ff3b3038, 0 6px 14px var(--mic-shadow), inset 0 -1px 0 #ffffff59, inset 0 3px 8px #0006;transform:scale(1.04)}
