.touch-ai-widget{position:fixed;right:24px;bottom:24px;z-index:150;font-family:var(--font-ui);--ai-ink:#242138;--ai-muted:#7b708b;--ai-line:#e9e7f0;--ai-purple:#7950e8;--ai-energy:0}
.touch-ai-launch{display:flex;align-items:center;gap:10px;height:54px;padding:6px 17px 6px 7px;border:1px solid #ffffffb8;border-radius:30px;background:linear-gradient(135deg,#fffefb,#f1eafe);color:#302046;box-shadow:0 6px 26px #4d246c26,0 0 0 1px #b396cb2b;cursor:pointer;font-size:12px;font-weight:600;letter-spacing:.2px;transition:transform .2s,box-shadow .2s}
.touch-ai-launch:hover{transform:translateY(-3px);box-shadow:0 9px 35px #5d327d38}
.touch-ai-launch>span>b{font-weight:750;color:#8354d8}.touch-ai-launch>svg{height:15px;width:15px;margin-left:1px;color:#9c7abb}
.ai-orb{display:block;position:relative;width:100px;height:100px;flex-shrink:0;border-radius:50%;isolation:isolate;background:radial-gradient(ellipse at 30% 25%,#ffffff 0,#c7e9ff 12%,transparent 45%),conic-gradient(from 20deg,#64cce9,#bca4ff,#ea9ad8,#ffd0b7,#9886ee,#71d4e8,#64cce9);box-shadow:inset 0 0 17px 2px #fff9,inset -8px -12px 22px #7664a244,0 8px 32px #9681d733;overflow:hidden;transform:scale(calc(1 + var(--ai-energy)*.14));transition:transform .13s,border-radius .5s}
.ai-orb:before{content:"";position:absolute;inset:7%;border-radius:45% 55% 60% 40%;background:conic-gradient(from 0deg,#fff0,#fffffff2,#8ad8e88a,#c882e099,#fff0,#fff5);filter:blur(8px);animation:ai-orbit 13s linear infinite;mix-blend-mode:screen}
.ai-orb:after{content:"";position:absolute;inset:1px;border-radius:50%;box-shadow:inset 0 2px 8px #fffffff5,inset 1px 0 9px #fff8;pointer-events:none}
.ai-orb>i{position:absolute;inset:21% 4%;border-radius:43% 57% 41% 59%;border:3px solid #ffffff98;filter:blur(4px);transform:rotate(-32deg);animation:ai-flow 8s ease-in-out infinite}
.ai-orb>b{position:absolute;width:34%;height:19%;top:11%;left:18%;border-radius:50%;background:#fffd;filter:blur(6px);transform:rotate(-35deg)}
.touch-ai-launch .ai-orb{width:40px;height:40px;box-shadow:inset 0 0 9px #fff8,0 2px 10px #9983c628}.touch-ai-launch .ai-orb>i{border-width:1px;filter:blur(2px)}
.touch-ai-panel{position:fixed;inset:auto 24px var(--ai-bottom,24px) auto;margin:0;padding:0;width:430px;height:min(760px,calc(var(--ai-vh,100dvh) - 36px));max-height:none;max-width:calc(100vw - 32px);border:1px solid #fff9;border-radius:28px;background:radial-gradient(ellipse at 15% -5%,#e7e9ffb8,transparent 44%),radial-gradient(ellipse at 100% 12%,#f2ddf879,transparent 38%),#fbfbfef5;color:var(--ai-ink,#242138);box-shadow:0 25px 90px #2b154333,0 0 0 1px #c6bdd54d;backdrop-filter:blur(30px);-webkit-backdrop-filter:blur(30px);overflow:hidden;outline:none;font-family:var(--font-ui);font-size:13px;--ai-energy:0}
.touch-ai-panel[open]{display:flex;flex-direction:column;animation:ai-panel-in .28s cubic-bezier(.2,.8,.2,1)}
.touch-ai-panel:not([open]){display:none}.touch-ai-panel::backdrop{background:#18102023;backdrop-filter:blur(3px);-webkit-backdrop-filter:blur(3px)}
.touch-ai-panel *{box-sizing:border-box}.touch-ai-panel [hidden]{display:none!important}.touch-ai-panel button,.touch-ai-panel textarea{font-family:inherit}.touch-ai-panel button{cursor:pointer}.touch-ai-panel button:disabled{cursor:wait;opacity:.45}.touch-ai-panel button:focus-visible,.touch-ai-launch:focus-visible,.ai-source:focus-visible{outline:3px solid #ab8bef;outline-offset:3px}.touch-ai-panel svg{display:block;width:20px;height:20px;flex-shrink:0}
.touch-ai-panel .ai-header{flex-shrink:0;display:flex;align-items:center;justify-content:space-between;gap:8px;padding:22px 23px 16px;border-bottom:1px solid #e3dfeb8c;background:transparent;color:inherit}
.ai-brand{min-width:0}.ai-brand>span{font-size:15px;font-weight:700;letter-spacing:.3px}.ai-brand>span>b{font-weight:650;background:linear-gradient(90deg,#7654cf,#c66ba8);-webkit-background-clip:text;background-clip:text;color:transparent;margin-left:3px}
.ai-brand small{display:flex;flex-wrap:wrap;align-items:center;gap:6px;margin-top:6px;color:var(--ai-muted,#7b708b);font-size:10px;font-weight:450;letter-spacing:0}.ai-ready-dot{height:4px;width:4px;background:#a495bd;border-radius:50%}.touch-ai-panel[data-ready="true"] .ai-ready-dot{background:#6da592;box-shadow:0 0 0 3px #75c6a815}
.ai-header-actions{display:flex;flex-shrink:0;gap:3px}.touch-ai-panel .ai-icon-button{display:grid;place-items:center;width:40px;height:40px;padding:8px;border:0;border-radius:12px;background:transparent;color:#878196;transition:background .2s,color .2s}.touch-ai-panel .ai-icon-button:hover{background:#eee9f9;color:#7050a9}.touch-ai-panel .ai-icon-button svg{width:17px;height:17px}.touch-ai-panel #touch-ai-voice[aria-pressed="true"]{color:#9676bc}
.ai-visual{position:relative;display:flex;align-items:center;flex-direction:column;justify-content:center;gap:17px;flex-shrink:0;min-height:190px;padding:28px 20px 10px;transition:min-height .35s,padding .35s}
.ai-orb-stage{position:relative;isolation:isolate;display:grid;place-items:center}.ai-orb-halo{position:absolute;inset:-20px;background:radial-gradient(ellipse,#c6aeed48,#84c5ed19,transparent 70%);filter:blur(10px);z-index:-1}.ai-visual-copy{text-align:center}.ai-state-kicker{color:#766783;font-size:10px;letter-spacing:2.3px;font-weight:600}.ai-visual-copy p{margin:7px 0 0;color:#7c728c;font-size:11px;line-height:1.4;font-weight:500}.ai-wave{display:none;height:28px;align-items:center;justify-content:center;gap:3px;margin-top:5px}.ai-wave i{display:block;width:3px;height:5px;border-radius:3px;background:linear-gradient(0deg,#b580df,#81c6df);transition:height .07s}
.touch-ai-panel[data-thread="true"] .ai-visual{min-height:80px;flex-direction:row;justify-content:flex-start;gap:13px;padding:17px 24px 11px}.touch-ai-panel[data-thread="true"] .ai-orb{width:43px;height:43px}.touch-ai-panel[data-thread="true"] .ai-visual-copy{text-align:left}.touch-ai-panel[data-thread="true"] .ai-state-kicker{font-size:10px;letter-spacing:1.8px}.touch-ai-panel[data-thread="true"] .ai-visual-copy p{margin-top:4px;font-size:10px}.touch-ai-panel[data-thread="true"] .ai-orb-halo{inset:-13px}
.touch-ai-panel[data-state="listening"] .ai-orb,.touch-ai-panel[data-state="speaking"] .ai-orb{animation:ai-breathe 2.5s ease-in-out infinite;background:radial-gradient(ellipse at 30% 20%,#fff,transparent 50%),conic-gradient(#81cfe9,#b0a4ff,#e39ad2,#ffcaae,#9986eb,#81cfe9)}
.touch-ai-panel[data-state="listening"] .ai-wave,.touch-ai-panel[data-state="speaking"] .ai-wave{display:flex}.touch-ai-panel[data-state="thinking"] .ai-orb:before,.touch-ai-panel[data-state="loading"] .ai-orb:before,.touch-ai-panel[data-state="transcribing"] .ai-orb:before{animation-duration:2.6s}.touch-ai-panel[data-state="thinking"] .ai-orb-halo,.touch-ai-panel[data-state="loading"] .ai-orb-halo{animation:ai-halo 2s ease-in-out infinite}
.ai-conversation{flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#d5ccdf transparent;outline:none;padding:0 22px 14px}.ai-welcome{text-align:center;padding:16px 0 4px}.ai-eyebrow{font-size:10px;letter-spacing:1.9px;color:#766783;font-weight:550}.ai-welcome h2{font-size:28px;line-height:1.3;letter-spacing:-.8px;font-weight:650;margin:13px 0 13px;color:var(--ai-ink,#242138)}.ai-welcome h2 span{background:linear-gradient(100deg,#7861b7,#ae6eac);-webkit-background-clip:text;background-clip:text;color:transparent}.ai-welcome>p{color:#7b708b;font-size:10px;line-height:1.8;font-weight:400;margin:0 0 25px}.ai-suggestions{display:grid;grid-template-columns:1fr 1fr;gap:9px}.ai-suggestions button{display:flex;align-items:center;gap:8px;padding:13px 10px;border:1px solid #e7e1f0;border-radius:14px;background:#ffffff82;color:#665674;text-align:left;transition:background .2s,border-color .2s,transform .2s;font-size:10px;font-weight:500;min-height:46px}.ai-suggestions button>svg:first-child{width:16px;height:16px;color:#a382c1}.ai-suggestions button>svg:last-child{margin-left:auto;height:12px;width:12px;color:#b6aabe}.ai-suggestions button:hover{background:#fff;border-color:#cdb7e4;transform:translateY(-2px)}
.ai-messages{display:flex;flex-direction:column;gap:23px;padding-top:6px}.ai-turn{min-width:0;animation:ai-message-in .24s ease-out}.ai-turn-user{align-self:flex-end;max-width:90%;border-radius:19px 19px 6px 19px;padding:12px 16px;background:linear-gradient(120deg,#eee7f8,#e8e7f4);color:#64516f;border:1px solid #e6ddf2}.ai-turn-user .ai-answer-text{font-size:13px;font-weight:500;line-height:1.7;margin:0}.ai-turn-assistant{width:100%;padding:0 1px}.ai-answer-label{display:flex;align-items:center;gap:6px;color:#7e6b8d;font-size:10px;font-weight:650;letter-spacing:1.5px;margin-bottom:11px}.ai-answer-label svg{width:12px;height:12px;color:#a98cc5}.ai-answer-text{white-space:pre-wrap;overflow-wrap:anywhere;color:var(--ai-ink,#242138);font-size:14px;font-weight:400;line-height:1.8;letter-spacing:0;margin:0}.ai-turn-error{padding:13px 15px;border-radius:15px;background:#fdf0f1;color:#a25866;font-size:11px;border:1px solid #f0d6df}.ai-turn-error .ai-answer-text{font-size:11px;color:inherit}
.ai-sources{display:grid;gap:9px;margin-top:17px}.ai-source-label{font-size:10px;color:#7b668b;letter-spacing:1.6px;font-weight:650;margin:0 0 1px}.ai-source{display:flex;align-items:center;gap:11px;padding:10px;border:1px solid #e5e0ef;border-radius:16px;text-decoration:none!important;color:inherit;background:linear-gradient(120deg,#ffffffdf,#f8f5fb9c);transition:transform .2s,border-color .2s,box-shadow .2s}.ai-source:hover{transform:translateY(-2px);border-color:#c6afe1;box-shadow:0 5px 18px #9880b01a}.ai-source .ai-source-photo{width:65px;height:74px;border-radius:10px;flex-shrink:0;overflow:hidden;background-color:#eae5f1}.ai-source .ai-source-photo img{width:100%;height:100%;object-fit:cover}.ai-source-copy{flex:1;min-width:0;display:block}.ai-source-meta{display:block;color:#765d8c;font-size:10px;font-weight:550;margin-bottom:5px}.ai-source-copy>strong{font-size:12px;font-weight:550;line-height:1.6;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;color:#484052}.ai-source-read{display:flex;align-items:center;gap:4px;font-size:10px;color:#7b668b;margin-top:7px}.ai-source-read svg{width:10px;height:10px}.ai-source-arrow{display:grid;place-items:center;background:#f0e9f6;width:24px;height:24px;border-radius:8px;flex-shrink:0;color:#b19cc3}.ai-source-arrow svg{width:13px;height:13px}
.ai-answer-actions{display:flex;gap:14px;margin-top:12px}.ai-answer-actions>button{display:flex;align-items:center;gap:5px;min-height:40px;padding:3px 2px;background:transparent;border:0;color:#7b668b;font-size:10px;font-weight:500}.ai-answer-actions>button svg{width:13px;height:13px}.ai-answer-actions>button:hover{color:#8761a5}.ai-answer-actions>button[aria-pressed="true"]{color:#9971bf}.ai-pending{min-height:58px}.ai-thinking-dots{display:inline-flex;gap:4px;align-items:center;vertical-align:middle}.ai-thinking-dots i{width:5px;height:5px;border-radius:50%;background:#b79dc8;animation:ai-dot 1.3s ease-in-out infinite}.ai-thinking-dots i:nth-child(2){animation-delay:.15s}.ai-thinking-dots i:nth-child(3){animation-delay:.3s}.ai-pending-text{color:#7b708b;font-size:10px;margin-left:10px}
.ai-notice{padding:10px 14px;margin:0 22px 9px;border:1px solid #e4dcee;border-radius:12px;color:#74617f;background:#f5f0fa;font-size:10px;line-height:1.7;flex-shrink:0}.ai-notice.is-error{border-color:#ead0dc;background:#fff0f5;color:#a36379}.ai-notice a{display:block;color:inherit;margin-top:4px;text-decoration:underline}.ai-recording{display:flex;align-items:center;gap:8px;padding:10px 25px;color:#9e72ad;font-size:10px;flex-shrink:0}.ai-recording time{margin-left:4px;font-variant-numeric:tabular-nums;color:#af9cba}.ai-record-dot{width:6px;height:6px;background:#d091b6;border-radius:50%;box-shadow:0 0 0 4px #d49cbc17;animation:ai-dot 1.3s infinite}.ai-recording button{margin-left:auto;background:none;border:0;color:#a38aa8;font-size:10px;padding:7px}.ai-footer{padding:15px 19px 16px;border-top:1px solid #eee9f280;background:#ffffff7a;flex-shrink:0}.touch-ai-panel .ai-compose{display:flex;align-items:flex-end;gap:8px;padding:10px 10px 10px 16px;background:#fffdfd;border:1px solid #e4daef;border-radius:21px;box-shadow:0 3px 14px #a58abc0c;transition:border-color .2s,box-shadow .2s}.ai-compose:focus-within{border-color:#bba0d8;box-shadow:0 0 0 3px #d3b8ec18}.touch-ai-panel #touch-ai-input{resize:none;flex:1;min-width:0;min-height:28px;max-height:100px;padding:4px 0;margin:0;border:0;outline:none;border-radius:0;background:transparent;color:var(--ai-ink,#242138);font-size:13px;font-weight:450;line-height:1.75;box-shadow:none}.touch-ai-panel #touch-ai-input::placeholder{color:#b1a4ba;font-weight:400}.ai-compose-actions{display:flex;gap:5px;align-items:center}.touch-ai-panel .ai-mic-button,.touch-ai-panel .ai-send-button{display:grid;place-items:center;flex-shrink:0;height:44px;width:44px;border-radius:13px;padding:9px;border:0;background:#f3edf8;color:#a38ab5;transition:background .2s,transform .2s}.touch-ai-panel .ai-mic-button:hover{background:#eadef4;color:#8d61af}.touch-ai-panel .ai-send-button{background:linear-gradient(135deg,#a781cd,#8263b9);color:#fff;box-shadow:0 3px 8px #a080c22e}.touch-ai-panel .ai-send-button:hover{transform:translateY(-1px);background:linear-gradient(135deg,#946bc0,#7050a7)}.touch-ai-panel .ai-mic-button[aria-pressed="true"]{background:#edd6e8;color:#ad789f;box-shadow:0 0 0 3px #d497bc14}.touch-ai-panel .ai-mic-button svg,.touch-ai-panel .ai-send-button svg{width:17px;height:17px}
.ai-footnote{display:flex;justify-content:space-between;align-items:center;gap:8px;margin:11px 3px 0;color:#7b708b}.ai-footnote>span{display:flex;align-items:center;gap:4px;font-size:10px;white-space:nowrap}.ai-footnote svg{width:10px;height:10px}.ai-footnote small{font-size:10px;font-weight:400;line-height:1.6}
[data-theme="dark"] .touch-ai-widget{--ai-ink:#ece8f4;--ai-muted:#9b90ad;--ai-line:#3c324a}
[data-theme="dark"] .touch-ai-panel{background:radial-gradient(ellipse at 10% 0,#4a396262,transparent 50%),#211a2bef;border-color:#ffffff18;color:#ece8f4;--ai-ink:#ece8f4;--ai-muted:#9b90ad}
[data-theme="dark"] .touch-ai-panel .ai-header{border-color:#ffffff0d}[data-theme="dark"] .ai-turn-user{background:linear-gradient(120deg,#42324f,#373042);border-color:#584168;color:#e4d8eb}[data-theme="dark"] .ai-suggestions button{background:#30253580;border-color:#574061;color:#d4bcde}[data-theme="dark"] .ai-source{background:#32273999;border-color:#4a3956}[data-theme="dark"] .ai-source-copy>strong{color:#e1d5e8}[data-theme="dark"] .ai-source-arrow{background:#493753;color:#bfa6d1}[data-theme="dark"] .ai-footer{background:#231b2d9c;border-color:#ffffff0c}[data-theme="dark"] .touch-ai-panel .ai-compose{background:#2d2336;border-color:#584068}[data-theme="dark"] .touch-ai-panel .ai-mic-button{background:#49354f;color:#c39fcf}[data-theme="dark"] .ai-notice{background:#35273f;border-color:#54365f;color:#c8acd6}[data-theme="dark"] .ai-notice.is-error{background:#462535;border-color:#70405a;color:#e6b0c6}[data-theme="dark"] .ai-turn-error{background:#462535;border-color:#70405a;color:#e6b0c6}[data-theme="dark"] .touch-ai-panel .ai-icon-button:hover{background:#4a3655;color:#ceb1e0}
@media(max-width:700px){.touch-ai-widget{right:15px;bottom:calc(77px + env(safe-area-inset-bottom,0px))}.touch-ai-launch{height:47px;padding:5px 14px 5px 5px;gap:8px;font-size:10px}.touch-ai-launch .ai-orb{width:35px;height:35px}.touch-ai-launch>svg{width:12px;height:12px}.touch-ai-panel{inset:auto 9px var(--ai-bottom,12px) 9px;width:auto;max-width:none;height:min(820px,calc(var(--ai-vh,100dvh) - 26px));border-radius:27px;max-height:none}.touch-ai-panel::backdrop{background:#22152f3b;backdrop-filter:blur(6px);-webkit-backdrop-filter:blur(6px)}.touch-ai-open{overflow:hidden}.touch-ai-panel .ai-header{padding:18px 19px 14px}.touch-ai-panel .ai-icon-button{width:40px;height:40px}.ai-brand>span{font-size:14px}.ai-brand small{font-size:10px}.ai-visual{padding-top:23px;min-height:177px}.ai-orb{width:89px;height:89px}.ai-welcome{padding-top:16px}.ai-welcome h2{font-size:29px}.ai-welcome>p{font-size:11px}.ai-suggestions button{font-size:10px;padding:14px 10px;min-height:48px}.ai-conversation{padding:0 19px 17px}.ai-answer-text{font-size:14px;line-height:1.8}.ai-turn-user .ai-answer-text{font-size:12px}.ai-source-copy>strong{font-size:12px}.ai-source .ai-source-photo{width:66px;height:78px}.ai-source-meta{font-size:10px}.ai-source-read{font-size:10px}.ai-source-label{font-size:10px}.ai-answer-actions>button{font-size:10px;min-height:40px}.ai-footer{padding:14px 14px max(15px,env(safe-area-inset-bottom,0px))}.touch-ai-panel #touch-ai-input{font-size:16px;line-height:1.65;letter-spacing:-.3px}.touch-ai-panel #touch-ai-input::placeholder{font-size:11px;letter-spacing:0}.touch-ai-panel .ai-mic-button,.touch-ai-panel .ai-send-button{height:44px;width:44px}.ai-footnote>span,.ai-footnote small{font-size:10px}.ai-notice{font-size:10px;margin:0 18px 8px}.touch-ai-panel[data-thread="true"] .ai-visual{padding-left:21px;min-height:79px}.ai-pending-text{font-size:10px}}
@media(max-height:680px){.touch-ai-panel:not([data-thread]) .ai-visual{min-height:125px;padding-top:18px;gap:10px}.touch-ai-panel:not([data-thread]) .ai-orb{width:68px;height:68px}.ai-welcome{padding-top:5px}.ai-welcome h2{font-size:24px;margin:10px 0}.ai-welcome>p{margin-bottom:15px}.ai-suggestions{gap:7px}.ai-suggestions button{min-height:40px;padding:10px}}
@media(prefers-reduced-motion:reduce){.touch-ai-widget *,.touch-ai-panel *{animation:none!important;transition:none!important;scroll-behavior:auto!important}.touch-ai-panel[open]{animation:none}}
@keyframes ai-orbit{to{transform:rotate(360deg)}}@keyframes ai-flow{0%,100%{transform:rotate(-32deg) scale(1);border-radius:43% 57% 41% 59%}50%{transform:rotate(140deg) scale(.9);border-radius:59% 41% 57% 43%}}@keyframes ai-breathe{0%,100%{box-shadow:inset 0 0 17px 2px #fff9,0 8px 35px #aa8adb3d}50%{box-shadow:inset 0 0 20px 2px #fff9,0 8px 44px #9279d960}}@keyframes ai-halo{50%{opacity:.5;transform:scale(.8)}}@keyframes ai-panel-in{from{opacity:0;transform:translateY(18px) scale(.98)}to{opacity:1;transform:translateY(0) scale(1)}}@keyframes ai-message-in{from{opacity:0;transform:translateY(6px)}to{opacity:1;transform:translateY(0)}}@keyframes ai-dot{0%,70%,100%{opacity:.4;transform:translateY(0)}35%{opacity:1;transform:translateY(-3px)}}
