/* Vitrinoria 2.2.36 — conversation-friendly chat, fully scoped. No external assets. */
.ai-widget{position:fixed;right:20px;bottom:20px;z-index:15000;display:flex;flex-direction:column-reverse;align-items:flex-end;gap:12px;font-family:Inter,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#1d2740}
.ai-widget .ai-opener{cursor:pointer;display:inline-flex;align-items:center;gap:10px;padding:14px 19px;border:0;border-radius:999px;background:linear-gradient(135deg,#5147c4,#7361dd);color:#fff;font-size:13px;font-weight:750;box-shadow:0 10px 32px rgba(48,40,117,.29)}
.ai-widget .ai-opener:hover{filter:brightness(1.05)}
.ai-widget .ai-window{display:flex;flex-direction:column;width:410px;max-width:calc(100vw - 30px);height:min(590px,calc(100dvh - 130px));min-height:310px;padding:0;overflow:hidden;border:1px solid #e5e9f3;border-radius:22px;background:#fff;box-shadow:0 20px 70px rgba(27,38,75,.22);margin:0}
.ai-widget .ai-window[hidden]{display:none}
.ai-widget .ai-chat-head{min-height:76px;padding:16px 16px;display:flex;align-items:center;gap:12px;border-bottom:1px solid #edf0f6;background:#fff;flex:0 0 auto}
.ai-widget .ai-bot-avatar{display:grid;place-items:center;flex:0 0 42px;width:42px;height:42px;background:linear-gradient(135deg,#5c4bd9,#9584ef);color:white;border-radius:15px;font-size:20px;font-weight:750}
.ai-widget .ai-chat-title{display:flex;flex:1;min-width:0;flex-direction:column;gap:5px}
.ai-widget .ai-chat-title strong{font-size:14px;line-height:1.2;color:#1d2740;white-space:nowrap;text-overflow:ellipsis;overflow:hidden}
.ai-widget .ai-chat-title small{font-size:11px;color:#6b7891;display:inline-flex;align-items:center;gap:6px}
.ai-widget .ai-online{display:inline-block;height:7px;width:7px;border-radius:50%;background:#26ad73}
.ai-widget .ai-close{height:35px;width:35px;flex-shrink:0;border:0;background:transparent;color:#69758d;font-size:25px;font-weight:400;cursor:pointer;border-radius:10px;display:grid;place-items:center}
.ai-widget .ai-close:hover{background:#f0f2fa;color:#29304b}
.ai-widget .ai-messages{display:flex;flex-direction:column;gap:14px;flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain;padding:21px 16px 23px;background:linear-gradient(#fcfcff,#f8f9ff);scrollbar-color:#d6d8ea transparent;scrollbar-width:thin}
.ai-widget .ai-row{display:flex;width:100%;align-items:flex-end;max-width:100%;flex-shrink:0}
.ai-widget .ai-row.ai-user{justify-content:flex-end}
.ai-widget .ai-row.ai-assistant{justify-content:flex-start}
.ai-widget .ai-bubble{max-width:88%;overflow-wrap:anywhere;white-space:pre-wrap;padding:11px 14px;border-radius:16px;font-size:13px;line-height:1.6;box-shadow:0 1px 2px rgba(30,38,75,.035);color:#263146;background:#fff;border:1px solid #e9ecf4;text-align:left;font-weight:400}
.ai-widget .ai-user .ai-bubble{background:#6556d7;color:white;border-color:transparent;border-bottom-right-radius:5px}
.ai-widget .ai-assistant .ai-bubble{border-bottom-left-radius:5px}
.ai-widget .ai-rich{white-space:normal}
.ai-widget .ai-rich p{background:transparent;border-radius:0;max-width:none;align-self:auto;color:inherit;margin:0 0 9px;padding:0;line-height:1.6;font-size:13px;box-shadow:none;white-space:pre-wrap}
.ai-widget .ai-rich p:last-child{margin-bottom:0}
.ai-widget .ai-rich strong{font-weight:750;color:#24234f}
.ai-widget .ai-rich h3,.ai-widget .ai-rich h4{color:#302864;margin:12px 0 6px;padding:0;line-height:1.35;font-size:14px;font-weight:750}
.ai-widget .ai-rich h4{font-size:13px}
.ai-widget .ai-rich ul,.ai-widget .ai-rich ol{margin:5px 0 12px;padding-left:20px;display:block;list-style:outside;white-space:normal}
.ai-widget .ai-rich ul{list-style-type:disc}.ai-widget .ai-rich ol{list-style-type:decimal}
.ai-widget .ai-rich li{margin:5px 0;font-size:13px;line-height:1.5;list-style:inherit}
.ai-widget .ai-rich a{color:#5144c4;text-decoration:underline;text-underline-offset:2px}
.ai-widget .ai-rich code{background:#eef0fc;border-radius:4px;padding:1px 4px;font-size:12px}
.ai-widget .ai-rich pre{white-space:pre-wrap;overflow-wrap:anywhere;background:#eef0fb;border-radius:8px;padding:10px;font-size:12px;line-height:1.5}
.ai-widget .ai-send{display:flex;gap:10px;align-items:flex-end;border-top:1px solid #edf0f6;background:#fff;padding:13px 14px 8px;flex:0 0 auto;margin:0}
.ai-widget .ai-send textarea{margin:0;flex:1;resize:none;min-width:0;min-height:41px;max-height:108px;height:41px;box-sizing:border-box;padding:11px 14px;border:1px solid #e0e4ef;border-radius:13px;color:#263146;font-size:13px;line-height:1.4;background:#f8f9fd;font-family:inherit;outline:0;box-shadow:none}
.ai-widget .ai-send textarea:focus{border-color:#8b7ce5;box-shadow:0 0 0 3px rgba(123,104,218,.13)}
.ai-widget .ai-send button{display:grid;place-items:center;flex:0 0 42px;height:42px;cursor:pointer;background:#6453d1;color:white;border:0;border-radius:13px;font-size:17px;padding:0}
.ai-widget .ai-send button:hover{background:#5041b9}.ai-widget .ai-send button:disabled{opacity:.55;cursor:progress}
.ai-widget .ai-caption{font-size:10px;text-align:center;color:#8a93a7;padding:4px 14px 12px;background:white;margin:0;line-height:1.3}
.ai-widget .ai-typing{display:inline-flex;align-items:center;gap:9px;color:#6a738b;font-size:12px;min-height:40px}
.ai-widget .ai-typing-dots{display:inline-flex;gap:3px;align-items:center}
.ai-widget .ai-typing-dots i{height:5px;width:5px;display:block;border-radius:50%;background:#8c81d2;animation:vit-ai-dots 1.25s infinite ease-in-out}
.ai-widget .ai-typing-dots i:nth-child(2){animation-delay:.18s}.ai-widget .ai-typing-dots i:nth-child(3){animation-delay:.36s}
@keyframes vit-ai-dots{0%,65%,100%{transform:translateY(0);opacity:.45}30%{transform:translateY(-4px);opacity:1}}
.ai-widget .ai-error .ai-bubble{border-color:#f1d5d9;background:#fffafb}
#vit-ai-settings textarea[name="ai_unified_instructions"]{width:100%;min-height:420px;resize:vertical;line-height:1.6;font-size:13px;font-family:ui-monospace,Consolas,Monaco,monospace;white-space:pre-wrap}
@media(max-width:540px){.ai-widget{right:12px;bottom:12px;left:12px}.ai-widget .ai-window{width:100%;max-width:none;height:min(650px,calc(100dvh - 98px));min-height:260px;border-radius:18px}.ai-widget .ai-opener{align-self:flex-end}.ai-widget .ai-messages{padding:17px 12px}.ai-widget .ai-bubble{max-width:92%}}
@media(prefers-reduced-motion:reduce){.ai-widget .ai-typing-dots i{animation:none}}
