.chat-widget-wrapper{--chat-primary: #4f46e5;--pulse-ring-color: var(--chat-primary);--avatar-bg: transparent;--chat-button-size: 55px;--chat-online-dot-size: calc(var(--chat-button-size) * .17);font-family:Plus Jakarta Sans,system-ui,sans-serif}.chat-widget-portal-root,.chat-widget-wrapper,.chat-widget-wrapper *{box-sizing:border-box}.chat-button{position:fixed;bottom:20px;right:20px;width:var(--chat-button-size);height:var(--chat-button-size);border-radius:50%;border:3px solid white;background:var(--avatar-bg);box-shadow:0 4px 12px #00000026;padding:0;overflow:visible;cursor:pointer;transition:transform .2s ease,box-shadow .2s ease;z-index:2147483647;opacity:0;animation:chat-bubble-fade-in .3s ease-out .3s forwards}@keyframes chat-bubble-fade-in{0%{opacity:0;transform:scale(.92)}to{opacity:1;transform:scale(1)}}@media(prefers-reduced-motion:reduce){.chat-button{animation-duration:.2s;animation-delay:.1s}.chat-button:before{animation:none}}.chat-widget-wrapper.pos-left .chat-button{left:20px;right:auto}.chat-button:after{content:"";position:absolute;top:-4px;right:-4px;bottom:-4px;left:-4px;border-radius:50%;border:none;z-index:0;background:radial-gradient(circle,color-mix(in srgb,var(--pulse-ring-color) 48%,transparent) 0,color-mix(in srgb,var(--pulse-ring-color) 0%,transparent) 55%);box-shadow:0 0 color-mix(in srgb,var(--pulse-ring-color) 40%,transparent);opacity:0;animation:bubble-pulse-ring 4s cubic-bezier(.22,.61,.36,1) infinite;pointer-events:none}.chat-button:before{content:"";position:absolute;width:var(--chat-online-dot-size);height:var(--chat-online-dot-size);top:calc(var(--chat-button-size) * 0);right:calc(var(--chat-button-size) * 0);border-radius:50%;background:#22c55e;z-index:2;box-shadow:0 0 0 2px #fff,0 0 10px #22c55e59;animation:online-dot-pulse 1.8s ease-in-out infinite;pointer-events:none}.chat-button:hover{transform:scale(1.08);box-shadow:0 6px 20px #0003,0 0 0 4px color-mix(in srgb,var(--chat-primary) 20%,transparent)}.chat-button-avatar{width:100%;height:100%;object-fit:cover;display:block;position:relative;z-index:1;border-radius:50%}@keyframes bubble-pulse-ring{0%{transform:scale(.94);opacity:0;box-shadow:0 0 color-mix(in srgb,var(--pulse-ring-color) 35%,transparent)}40%{transform:scale(1);opacity:.82;box-shadow:0 0 0 4px color-mix(in srgb,var(--pulse-ring-color) 38%,transparent)}to{transform:scale(1.06);opacity:0;box-shadow:0 0 0 8px color-mix(in srgb,var(--pulse-ring-color) 0%,transparent)}}@keyframes online-dot-pulse{0%{transform:scale(1);opacity:1;box-shadow:0 0 0 2px #fff,0 0 10px #22c55e59}55%{transform:scale(1.1);opacity:.95;box-shadow:0 0 0 2px #fff,0 0 18px #22c55e8c}to{transform:scale(1);opacity:1;box-shadow:0 0 0 2px #fff,0 0 10px #22c55e59}}.chat-box{position:fixed;bottom:30px;right:20px;width:420px;height:620px;max-width:calc(100vw - 40px);max-height:calc(100dvh - 60px);background:#fff;border-radius:16px;box-shadow:0 10px 30px #0003;opacity:0;visibility:hidden;transition:opacity .32s cubic-bezier(.22,.61,.36,1),transform .32s cubic-bezier(.22,.61,.36,1),visibility .32s;display:flex;flex-direction:column;transform:translateY(24px) scale(.98);transform-origin:bottom right;z-index:2147483647}.chat-widget-wrapper.pos-left .chat-box{left:20px;right:auto;transform-origin:bottom left}.chat-widget-wrapper.mode-dark .chat-box{background:#0b1220;box-shadow:0 12px 34px #0000008c}.chat-widget-wrapper.mode-dark .chat-header,.chat-widget-wrapper.mode-dark .chat-input-wrap,.chat-widget-wrapper.mode-dark .chat-powered-by{background:#0f172a;border-color:#ffffff14}.chat-widget-wrapper.mode-dark .chat-header{border-bottom-color:#ffffff14}.chat-widget-wrapper.mode-dark .chat-input-wrap{border-top-color:#ffffff14}.chat-widget-wrapper.mode-dark .chat-powered-by{border-top-color:#ffffff14;color:#e5e7ebb3}.chat-widget-wrapper.mode-dark .msg-content a{color:#60a5fa;text-decoration:underline}.chat-widget-wrapper.mode-dark .msg-content a:hover{color:#93c5fd}.chat-widget-wrapper.mode-dark .chat-bot-name,.chat-widget-wrapper.mode-dark .chat-status-text,.chat-widget-wrapper.mode-dark .msg-bot .msg-content span:not(.msg-sender),.chat-widget-wrapper.mode-dark .msg-bot .msg-content,.chat-widget-wrapper.mode-dark .chat-messages{color:#e5e7eb}.chat-widget-wrapper.mode-dark .chat-bot-status{color:#e5e7ebb3}.chat-widget-wrapper.mode-dark .chat-expand-btn,.chat-widget-wrapper.mode-dark .chat-history-btn,.chat-widget-wrapper.mode-dark .chat-theme-btn,.chat-widget-wrapper.mode-dark .chat-close{color:#e5e7ebbf}.chat-widget-wrapper.mode-dark .chat-expand-btn:hover,.chat-widget-wrapper.mode-dark .chat-history-btn:hover,.chat-widget-wrapper.mode-dark .chat-theme-btn:hover,.chat-widget-wrapper.mode-dark .chat-close:hover:not(:disabled){background:#ffffff14;color:#e5e7eb}.chat-widget-wrapper.mode-dark .msg-bot .msg-content{background:#ffffff14}.chat-widget-wrapper.mode-dark .chat-input-wrap input{background:#ffffff0f;border-color:#ffffff1f;color:#e5e7eb}.chat-widget-wrapper.mode-dark .chat-input-wrap input::placeholder{color:#e5e7eb99}.chat-widget-wrapper.mode-dark .quick-question-btn{background:#ffffff0f;border-color:#ffffff1f;color:#e5e7eb}.chat-widget-wrapper.mode-dark .quick-question-btn:hover{background:#ffffff1a;border-color:#ffffff29}.chat-widget-wrapper.mode-dark .chat-entry-greeting,.chat-widget-wrapper.mode-dark .chat-entry-cta-title{color:#e5e7eb}.chat-widget-wrapper.mode-dark .chat-entry-subtitle,.chat-widget-wrapper.mode-dark .chat-entry-cta-desc,.chat-widget-wrapper.mode-dark .chat-entry-email-label{color:#e5e7ebcc}.chat-widget-wrapper.mode-dark .chat-entry-cta{background:#ffffff0f;border-color:#ffffff1f}.chat-widget-wrapper.mode-dark .chat-entry-cta:hover{background:#ffffff1a;border-color:var(--chat-primary)}.chat-widget-wrapper.mode-dark .chat-entry-email{background:#ffffff0f;border-color:#ffffff1f}.chat-widget-wrapper.mode-dark .chat-entry-email-controls input{background:#ffffff0f;border-color:#ffffff1f;color:#e5e7eb}.chat-widget-wrapper.mode-dark .chat-entry-email-controls input::placeholder{color:#e5e7eb99}.chat-widget-wrapper.mode-dark .chat-entry-nav{background:#0f172a;border-top-color:#ffffff14}.chat-widget-wrapper.mode-dark .chat-entry-nav-item{color:#e5e7ebb3}.chat-widget-wrapper.mode-dark .chat-entry-nav-item:hover{background:#ffffff0f;color:#e5e7eb}.chat-widget-wrapper.mode-dark .chat-entry-nav-item.active{background:color-mix(in srgb,var(--chat-primary) 25%,transparent);color:#93c5fd}.chat-box.open{opacity:1;visibility:visible;transform:translateY(0) scale(1)}.chat-box.expanded{width:min(560px,calc(100vw - 40px));height:min(820px,calc(100dvh - 40px));max-width:calc(100vw - 40px);max-height:calc(100dvh - 40px)}.chat-header{display:flex;align-items:center;gap:12px;padding:14px 16px;border-bottom:1px solid #f0f0f0;background:#fafafa;border-radius:16px 16px 0 0}.chat-bot-meta{flex:1;display:flex;flex-direction:column;align-items:flex-start;min-width:0}.chat-bot-avatar-wrap{width:40px;height:40px;border-radius:50%;flex-shrink:0;overflow:hidden;background:var(--avatar-bg)}.chat-bot-avatar{width:40px;height:40px;border-radius:50%;object-fit:cover;display:block;transform:scale(1.18);transform-origin:center}.chat-bot-avatar-wrap-logo{background:transparent}.chat-bot-avatar-logo{object-fit:contain;transform:scale(1)}.chat-bot-name{font-weight:600;font-size:15px;letter-spacing:-.01em;line-height:1.2;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.chat-bot-status{display:inline-flex;align-items:center;gap:6px;margin-top:2px;font-size:12px;color:#6b7280}.chat-status-dot{width:8px;margin-top:2px;height:8px;border-radius:999px;background:#22c55e;box-shadow:0 0 0 3px color-mix(in srgb,#22c55e 18%,transparent);animation:chat-status-pulse 1.6s ease-out infinite}@keyframes chat-status-pulse{0%{transform:scale(1);box-shadow:0 0 0 3px color-mix(in srgb,#22c55e 22%,transparent);opacity:1}50%{transform:scale(1.3);box-shadow:0 0 0 6px color-mix(in srgb,#22c55e 0%,transparent);opacity:.5}to{transform:scale(1);box-shadow:0 0 0 3px color-mix(in srgb,#22c55e 22%,transparent);opacity:1}}.chat-header-actions{display:flex;align-items:center;gap:4px}.chat-expand-btn,.chat-history-btn,.chat-theme-btn{width:28px;height:28px;padding:0;border:none;background:transparent;color:#6b7280;border-radius:6px;cursor:pointer;display:flex;align-items:center;justify-content:center}.chat-expand-btn:hover,.chat-history-btn:hover,.chat-theme-btn:hover{background:#e5e7eb;color:#374151}.chat-close{width:28px;height:28px;border:none;background:transparent;font-size:22px;line-height:1;cursor:pointer;color:#6b7280;border-radius:6px}.chat-close:hover:not(:disabled){background:#e5e7eb;color:#374151}.chat-close:disabled{opacity:.6;cursor:wait}.chat-input-wrap{display:flex;gap:10px;padding:12px 14px;border-top:1px solid #f0f0f0;background:#fafafa;border-radius:0}.chat-entry-nav{display:flex;align-items:stretch;justify-content:space-around;padding:10px 8px;border-top:1px solid #f0f0f0;background:#fafafa;gap:4px}.chat-entry-nav-item{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;padding:8px 6px;border:none;background:transparent;border-radius:10px;font-family:inherit;font-size:12px;color:#6b7280;cursor:pointer;transition:background .15s,color .15s}.chat-entry-nav-item:hover{background:#f3f4f6;color:#374151}.chat-entry-nav-item.active{background:color-mix(in srgb,var(--chat-primary) 12%,white);color:var(--chat-primary);font-weight:600}.chat-entry-nav-icon{font-size:18px;line-height:1}.chat-powered-by{padding:8px 14px 12px;background:#fafafa;border-radius:0 0 16px 16px;font-size:12px;color:#6b7280;text-align:center;border-top:1px solid #f0f0f0}.chat-powered-by a{color:var(--chat-primary);text-decoration:none;font-weight:600}.chat-powered-by a:hover{text-decoration:underline}@media(max-width:768px){.chat-expand-btn{display:none}}.msg-bot-avatar-wrap{width:32px;height:32px;border-radius:50%;flex-shrink:0;overflow:hidden;background:var(--avatar-bg)}.msg-bot-avatar{width:32px;height:32px;border-radius:50%;object-fit:cover;display:block}@media(max-width:768px){.chat-button{bottom:max(16px,env(safe-area-inset-bottom));right:max(16px,env(safe-area-inset-right));width:calc(var(--chat-button-size) * .9);height:calc(var(--chat-button-size) * .9)}.chat-widget-wrapper.pos-left .chat-button{left:max(16px,env(safe-area-inset-left));right:auto}.chat-box{left:0;right:0;top:0;bottom:auto;width:100vw;max-width:100vw;height:var(--chat-viewport-height, 100dvh);max-height:var(--chat-viewport-height, 100dvh);border-radius:0;box-shadow:0 -4px 24px #00000026;padding-bottom:env(safe-area-inset-bottom);transform-origin:bottom center}.chat-header{padding:12px 16px;padding-top:max(12px,env(safe-area-inset-top));border-radius:0}.chat-messages{padding:12px 14px;font-size:15px}}.chat-entry-page{flex:1;display:flex;flex-direction:column;padding:20px;overflow-y:auto}.chat-entry-greeting{margin:0 0 6px;font-size:22px;font-weight:700;letter-spacing:-.02em;line-height:1.25;color:#111827}.chat-entry-subtitle{margin:0 0 20px;font-size:15px;color:#6b7280;line-height:1.45}.chat-entry-email{margin-top:auto;margin-bottom:20px;padding:12px;border:1px solid #e5e7eb;border-radius:14px;background:linear-gradient(180deg,#fafafa,#fff);box-shadow:none}.chat-entry-email-label{display:flex;align-items:center;gap:8px;font-size:12px;font-weight:700;color:#374151;margin-bottom:10px}.chat-entry-email-label:before{content:"@";display:inline-flex;align-items:center;justify-content:center;width:22px;height:22px;border-radius:999px;background:color-mix(in srgb,var(--chat-primary) 12%,white);color:var(--chat-primary);font-weight:800;line-height:1}.chat-entry-email-controls{display:flex;gap:8px;align-items:center}.chat-entry-email-controls input{flex:1;min-width:0;border:1px solid #e5e7eb;border-radius:999px;padding:10px 14px;font-family:inherit;font-size:14px;background:#fff;outline:none;transition:border-color .2s,box-shadow .2s}.chat-entry-email-controls input::placeholder{color:#9ca3af}.chat-entry-email-controls input:focus{border-color:var(--chat-primary);box-shadow:0 0 0 3px color-mix(in srgb,var(--chat-primary) 15%,transparent)}.chat-entry-email-controls button{border:none;padding:10px 16px;border-radius:999px;background:var(--chat-primary);color:#fff;font-family:inherit;font-weight:700;font-size:13px;cursor:pointer;white-space:nowrap}.chat-entry-email-help{margin-top:8px;font-size:11.5px;line-height:1.25;color:#6b7280;text-align:center}.chat-entry-email-status{margin-top:8px;font-size:12px;display:inline-flex;align-items:center;gap:6px;padding:6px 10px;border-radius:999px;border:1px solid transparent}.chat-entry-email-status-saved{color:#047857;background:#ecfdf5;border-color:#a7f3d0}.chat-entry-email-status-error{color:#b91c1c;background:#fef2f2;border-color:#fecaca}.chat-entry-cta{display:flex;align-items:center;gap:12px;width:100%;padding:20px 18px;min-height:88px;border:1px solid #e5e7eb;border-radius:12px;background:#fff;text-align:left;cursor:pointer;transition:all .2s ease;font-family:inherit;box-shadow:0 1px 3px #0000000f}.chat-entry-cta:hover{border-color:var(--chat-primary);background:color-mix(in srgb,var(--chat-primary) 6%,white);box-shadow:0 1px 3px #0000000f}.chat-entry-cta:focus-visible{outline:none;box-shadow:0 0 0 3px color-mix(in srgb,var(--chat-primary) 25%,transparent)}.chat-entry-cta-title{display:block;font-weight:600;font-size:15px;color:#111827}.chat-entry-cta-desc{display:block;font-size:12px;color:#6b7280;margin-top:2px}.chat-entry-cta-icon{margin-left:auto;font-size:18px;color:var(--chat-primary)}.chat-messages{flex:1;padding:14px 16px;overflow-y:auto;font-size:14px;line-height:1.5}.chat-input-wrap input{flex:1;border:1px solid #e5e7eb;border-radius:12px;padding:12px 16px;font-family:inherit;font-size:14px;background:#fff;outline:none;transition:border-color .2s,box-shadow .2s}.chat-input-wrap input::placeholder{color:#9ca3af}.chat-input-wrap input:focus{border-color:var(--chat-primary);box-shadow:0 0 0 3px color-mix(in srgb,var(--chat-primary) 15%,transparent)}.chat-input-wrap button{border:none;padding:12px 18px;border-radius:12px;background:var(--chat-primary);color:#fff;font-family:inherit;font-weight:600;font-size:14px;cursor:pointer;transition:background .2s,transform .1s}.chat-input-wrap button:hover{background:#4338ca}.chat-input-wrap button:active{transform:scale(.98)}.msg-user,.msg-bot{display:flex;gap:8px;margin-bottom:10px;animation:msg-appear .35s ease-out both}.msg-user{flex-direction:row-reverse;animation-name:msg-appear-user}@keyframes msg-appear{0%{opacity:0;transform:translateY(8px) translate(-6px)}to{opacity:1;transform:translateY(0) translate(0)}}@keyframes msg-appear-user{0%{opacity:0;transform:translateY(8px) translate(6px)}to{opacity:1;transform:translateY(0) translate(0)}}.msg-bot-avatar-wrap{width:40px;height:40px;border-radius:0;flex-shrink:0;overflow:visible;background:transparent}.msg-bot-avatar{width:40px;height:40px;border-radius:0;object-fit:contain;display:block;transform:none;transform-origin:center}.msg-content{display:flex;flex-direction:column;gap:2px;padding:10px 14px;border-radius:12px;max-width:75%;word-wrap:break-word}.msg-content p{margin:0 0 8px;line-height:1.5}.msg-content p:last-child{margin-bottom:0}.msg-content .msg-list{margin:6px 0 8px;padding-left:1.25em}.msg-content .msg-list-ul{list-style-type:disc}.msg-content .msg-list-ol{list-style-type:decimal;padding-left:1.5em}.msg-content .msg-list-item{margin-bottom:4px;line-height:1.45;padding-left:.25em}.msg-content .msg-list-item::marker{color:inherit;font-weight:500}.msg-content .msg-strong{font-weight:600}.msg-user .msg-content{background:var(--chat-primary);color:#fff;border-bottom-right-radius:4px}.msg-bot .msg-content{background:#f3f4f6;color:#111827;border-bottom-left-radius:4px}.msg-sender{font-size:11px;font-weight:600;color:var(--chat-primary);letter-spacing:.02em}.msg-user .msg-content span:not(.msg-sender){color:#fff}.msg-bot .msg-content span:not(.msg-sender){color:#111827}.quick-questions{display:flex;flex-direction:column;gap:8px;padding-bottom:8px;animation:quick-questions-appear .4s ease-out both}.quick-questions-label{font-size:12px;color:#6b7280;margin-bottom:4px}.quick-question-btn{text-align:left;padding:12px 14px;border:1px solid #e5e7eb;border-radius:10px;background:#fff;font-family:inherit;font-size:13px;cursor:pointer;transition:all .15s;animation:quick-btn-appear .35s ease-out both}.quick-question-btn:nth-child(2){animation-delay:.05s}.quick-question-btn:nth-child(3){animation-delay:.1s}.quick-question-btn:nth-child(4){animation-delay:.15s}.quick-question-btn:nth-child(5){animation-delay:.2s}.quick-question-btn:nth-child(6){animation-delay:.25s}@keyframes quick-questions-appear{0%{opacity:0;transform:translateY(-10px)}to{opacity:1;transform:translateY(0)}}@keyframes quick-btn-appear{0%{opacity:0;transform:translateY(6px)}to{opacity:1;transform:translateY(0)}}.quick-question-btn:hover{background:#f8f9fa;border-color:#d1d5db}.msg-bot:has(.typing-dots){animation:msg-appear .25s ease-out both}.typing-dots{display:inline-flex;align-items:center;gap:4px;padding:4px 0}.typing-dot{width:6px;height:6px;border-radius:50%;background:var(--chat-primary);animation:typing-bounce 1.4s ease-in-out infinite both}.typing-dot:nth-child(1){animation-delay:0s}.typing-dot:nth-child(2){animation-delay:.2s}.typing-dot:nth-child(3){animation-delay:.4s}@keyframes typing-bounce{0%,60%,to{transform:translateY(0);opacity:.5}30%{transform:translateY(-6px);opacity:1}}@media(max-width:768px){.chat-input-wrap{padding:12px 14px;padding-bottom:max(12px,env(safe-area-inset-bottom));gap:8px}.chat-input-wrap input,.chat-input-wrap button{padding:14px 16px;font-size:16px;min-height:48px}.msg-content{max-width:85%}.quick-question-btn{padding:14px 16px;font-size:14px;min-height:48px}}@media(max-width:480px){.msg-content{padding:10px 12px;max-width:90%}}.chat-history-panel{position:absolute;top:0;left:0;right:0;bottom:0;z-index:10;background:#fff;border-radius:16px;display:flex;flex-direction:column;box-shadow:0 10px 30px #0003}.chat-history-header{display:flex;align-items:center;justify-content:space-between;padding:14px 16px;border-bottom:1px solid #f0f0f0;background:#fafafa;border-radius:16px 16px 0 0}.chat-history-title{font-weight:600;font-size:15px;color:#111827}.chat-history-close{width:28px;height:28px;border:none;background:transparent;font-size:22px;line-height:1;cursor:pointer;color:#6b7280;border-radius:6px}.chat-history-close:hover{background:#e5e7eb;color:#374151}.chat-history-list{flex:1;overflow-y:auto;padding:12px}.chat-history-empty{margin:0;padding:24px 0;text-align:center;font-size:14px;color:#6b7280}.chat-history-item{display:flex;align-items:center;gap:8px;margin-bottom:8px;border-radius:10px;border:1px solid #e5e7eb;background:#fff}.chat-history-item-btn{flex:1;min-width:0;display:flex;flex-direction:column;align-items:flex-start;gap:2px;padding:12px 14px;border:none;background:none;cursor:pointer;font-family:inherit;text-align:left;transition:background .15s}.chat-history-item-btn:hover{background:#f9fafb}.chat-history-item-date{font-size:11px;color:#6b7280}.chat-history-item-preview{font-size:13px;color:#111827;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%}.chat-history-item-delete{flex-shrink:0;padding:8px 12px;margin:6px 8px 6px 0;border:1px solid #e5e7eb;border-radius:8px;background:#fff;font-size:12px;color:#6b7280;cursor:pointer;font-family:inherit}.chat-history-item-delete:hover{background:#fef2f2;color:#dc2626;border-color:#fecaca}.chat-widget-wrapper.mode-dark .chat-history-panel{background:#0b1220;box-shadow:0 12px 34px #0000008c}.chat-widget-wrapper.mode-dark .chat-history-header{background:#0f172a;border-bottom-color:#ffffff14}.chat-widget-wrapper.mode-dark .chat-history-title{color:#e5e7eb}.chat-widget-wrapper.mode-dark .chat-history-close{color:#e5e7ebbf}.chat-widget-wrapper.mode-dark .chat-history-close:hover{background:#ffffff14;color:#e5e7eb}.chat-widget-wrapper.mode-dark .chat-history-list{background:transparent}.chat-widget-wrapper.mode-dark .chat-history-empty{color:#e5e7ebb3}.chat-widget-wrapper.mode-dark .chat-history-item{border-color:#ffffff14;background:#0f172ae6}.chat-widget-wrapper.mode-dark .chat-history-item-btn:hover{background:#ffffff0a}.chat-widget-wrapper.mode-dark .chat-history-item-date{color:#e5e7ebb3}.chat-widget-wrapper.mode-dark .chat-history-item-preview{color:#e5e7eb}.chat-widget-wrapper.mode-dark .chat-history-item-delete{background:#0f172ae6;border-color:#ffffff14;color:#e5e7ebbf}.chat-widget-wrapper.mode-dark .chat-history-item-delete:hover{background:#451a1a;color:#fecaca;border-color:#fecaca}
