:root{color:var(--text);background:var(--surface-muted);color-scheme:light;font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,"Apple Color Emoji","Segoe UI Emoji","Noto Color Emoji",sans-serif;font-variant-emoji:emoji;font-synthesis:none;text-rendering:optimizeLegibility;--surface: #ffffff;--surface-muted: #f5f7fb;--surface-assistant: #eef2f6;--accent-soft: #e9f0ff;--text: #202938;--text-muted: #778195;--line: #e4e9f0;--accent: #2563eb;--accent-deep: #1e4fc4;--danger: #b42318;--status-idle: #a8b1c0;--status-live: #1d9a72;--shadow: 0 14px 40px rgba(34, 49, 75, .08);--app-height: 100lvh;--viewport-top: 0px;--keyboard-inset: 0px;--composer-bottom-padding: max(12px, env(safe-area-inset-bottom))}[data-theme=dark]{color-scheme:dark;--surface: #151819;--surface-muted: #101213;--surface-assistant: #252a2c;--accent-soft: #26364f;--text: #f2f4f3;--text-muted: #a5afb1;--line: #343a3d;--accent: #76a7ff;--accent-deep: #5f8fe5;--danger: #ff9b91;--status-idle: #6e787b;--status-live: #59c69d;--shadow: 0 14px 40px rgba(0, 0, 0, .28)}:root[data-keyboard=open]{--composer-bottom-padding: 8px}*{box-sizing:border-box}html,body,#root{width:100%;min-width:320px;height:100%;min-height:0;margin:0;overflow:hidden}body{background:var(--surface-muted)}#root{position:fixed;right:0;bottom:auto;left:0;top:var(--viewport-top);height:var(--app-height);overflow:hidden}button,input,textarea{font:inherit}button{touch-action:manipulation}button:focus-visible,input:focus-visible,textarea:focus-visible{outline:3px solid rgba(37,99,235,.28);outline-offset:2px}.app-shell{display:grid;grid-template-rows:auto minmax(0,1fr) auto;width:min(100%,760px);height:100%;min-height:0;margin:0 auto;overflow:hidden;background:var(--surface);box-shadow:var(--shadow)}.app-header{display:flex;align-items:center;justify-content:space-between;min-height:68px;padding:max(12px,env(safe-area-inset-top)) 16px 12px;border-bottom:1px solid var(--line)}.assistant-identity{display:flex;align-items:center;gap:10px}.assistant-mark,.empty-icon,.message-avatar{display:grid;place-items:center;color:var(--accent);background:var(--accent-soft)}.assistant-mark{width:34px;height:34px;border-radius:10px}.assistant-name{color:var(--text);font-size:15px;font-weight:700;line-height:1.2}.assistant-status{display:flex;align-items:center;gap:6px;margin-top:3px;color:var(--text-muted);font-size:12px;line-height:1.2}.assistant-disclaimer{margin-top:3px;color:var(--text-muted);font-size:10px;line-height:1.2}.status-dot{width:6px;height:6px;border-radius:50%;background:var(--status-idle)}.status-dot.is-live{background:var(--status-live)}.icon-button,.send-button,.preview-remove,.lightbox-close{display:inline-grid;place-items:center;border:0;cursor:pointer;transition:background-color .15s ease,color .15s ease,transform .15s ease}.icon-button{width:44px;height:44px;color:var(--text-muted);background:transparent;border-radius:8px}.icon-button:hover{color:var(--text);background:var(--surface-muted)}.icon-button:active,.send-button:active,.preview-remove:active,.lightbox-close:active{transform:scale(.95)}.header-action{margin-right:-6px}.conversation{min-height:0;overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scroll-padding-bottom:16px}.empty-state{display:grid;place-items:center;align-content:center;height:100%;min-height:260px;padding:48px 24px;text-align:center}.empty-icon{width:48px;height:48px;margin-bottom:18px;border-radius:14px}.empty-state h1{margin:0;color:var(--text);font-size:24px;font-weight:700;letter-spacing:0}.empty-state p{max-width:280px;margin:8px 0 0;color:var(--text-muted);font-size:15px;line-height:1.5}.message-list{display:flex;flex-direction:column;gap:18px;max-width:680px;margin:0 auto;padding:28px 16px 36px}.message-row{display:flex;align-items:flex-end;gap:8px;min-width:0;animation:message-enter .22s ease-out both}.message-row.is-own{justify-content:flex-end}.message-avatar{flex:0 0 26px;width:26px;height:26px;margin-bottom:2px;border-radius:8px}.message-content{display:flex;flex-direction:column;align-items:flex-start;min-width:0;max-width:min(78%,520px)}.message-row.is-own .message-content{align-items:flex-end}.message-time{margin:0 4px 4px;color:var(--text-muted);font-size:11px;font-variant-numeric:tabular-nums;line-height:1.2;white-space:nowrap}.message-bubble{max-width:100%;min-width:0;min-height:42px;padding:11px 14px;font-family:inherit;font-variant-emoji:emoji;overflow-wrap:anywhere;border-radius:8px}.bubble-assistant{color:var(--text);background:var(--surface-assistant)}.bubble-own{color:#fff;background:var(--accent)}.message-countdown{flex:0 0 auto;align-self:flex-end;margin-bottom:11px;color:var(--text-muted);font-size:11px;font-variant-numeric:tabular-nums;line-height:1;white-space:nowrap}.countdown-own{color:#7f9be4}.message-bubble p{margin:0;font-size:16px;line-height:1.5;white-space:pre-wrap}.image-message{display:block;max-width:100%;padding:0;overflow:hidden;border:0;border-radius:6px;background:transparent;cursor:pointer}.image-message img{display:block;width:min(260px,100%);max-height:340px;object-fit:cover}.image-placeholder{color:var(--text-muted);font-size:14px}.composer-area{z-index:2;padding:10px 12px var(--composer-bottom-padding);background:var(--surface);border-top:1px solid var(--line)}.composer{max-width:680px;margin:0 auto;padding:6px 8px 6px 6px;border:1px solid var(--line);border-radius:12px;background:var(--surface);transition:border-color .15s ease,box-shadow .15s ease}.composer.is-focused{border-color:#2563eb8c;box-shadow:0 0 0 3px #2563eb1a}.composer-row{display:flex;align-items:flex-end;gap:4px}.composer-action{flex:0 0 44px}.composer textarea,.composer input{flex:1 1 auto;width:100%;min-width:0;min-height:44px;max-height:144px;padding:11px 8px;resize:none;color:var(--text);background:transparent;border:0;outline:0;font-family:inherit;font-variant-emoji:emoji;font-size:16px;line-height:1.4}.composer textarea::placeholder,.composer input::placeholder{color:var(--text-muted)}.send-button{flex:0 0 40px;width:40px;height:40px;margin:2px 0;color:#fff;background:var(--accent);border-radius:8px}.send-button:hover{background:var(--accent-deep)}.send-button:disabled,.icon-button:disabled{cursor:not-allowed;opacity:.45}.composer-meta{display:flex;justify-content:flex-end;min-height:18px;padding:2px 8px 0 50px;color:var(--text-muted);font-size:11px;line-height:1.4}.composer-error{color:var(--danger);text-align:right}.attachment-preview{position:relative;width:64px;height:64px;margin:2px 0 6px 48px;overflow:hidden;border:1px solid var(--line);border-radius:8px}.attachment-preview img{display:block;width:100%;height:100%;object-fit:cover}.preview-remove{position:absolute;top:3px;right:3px;width:24px;height:24px;color:#fff;background:#202938c7;border-radius:6px}.visually-hidden{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.image-lightbox{position:fixed;z-index:10;inset:0;display:grid;place-items:center;padding:36px 18px;background:#101828e6}.image-lightbox img{display:block;max-width:100%;max-height:100%;object-fit:contain;cursor:zoom-out}.lightbox-close{position:absolute;top:max(12px,env(safe-area-inset-top));right:12px;width:44px;height:44px;color:#fff;background:#ffffff21;border-radius:8px}.hidden-lock-action{position:absolute;width:1px;height:1px;overflow:hidden;opacity:0;pointer-events:none}@keyframes message-enter{0%{opacity:0;transform:translateY(5px)}to{opacity:1;transform:translateY(0)}}@media(min-width:768px){.app-shell{min-height:100dvh;border-right:1px solid var(--line);border-left:1px solid var(--line)}.app-header,.message-list,.composer-area{padding-right:24px;padding-left:24px}}@media(prefers-reduced-motion:reduce){*,*:before,*:after{scroll-behavior:auto!important;animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important}}
