@liip/liipgpt 3.8.5 → 3.8.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/button/liipgpt-button.iife.js +1 -1
- package/chat/liipgpt-chat.iife.js +11 -11
- package/chat/liipgpt-chat.js +11 -11
- package/configurator/_app/env.js +1 -1
- package/configurator/_app/immutable/chunks/{Bk4g5DYk.js → BEOeYw29.js} +1 -1
- package/configurator/_app/immutable/chunks/BQ-t0fFK.js +1 -0
- package/configurator/_app/immutable/chunks/{Bctf51vm.js → BcRC19q0.js} +1 -1
- package/configurator/_app/immutable/chunks/{BcilqXKJ.js → CNMUyLhW.js} +1 -1
- package/configurator/_app/immutable/chunks/{DnmrrIQ8.js → CWciD3in.js} +1 -1
- package/configurator/_app/immutable/chunks/{jVFe59vF.js → CskLxzhu.js} +1 -1
- package/configurator/_app/immutable/chunks/{CVWkjl18.js → DD7RUfH0.js} +1 -1
- package/configurator/_app/immutable/chunks/{Cs_PdD9d.js → D_H7sg4g.js} +1 -1
- package/configurator/_app/immutable/chunks/{oyqvTNXv.js → Docn--tg.js} +1 -1
- package/configurator/_app/immutable/chunks/eof59qSA.js +1 -0
- package/configurator/_app/immutable/entry/{app.Hge9M3eE.js → app.TwBWfpPg.js} +2 -2
- package/configurator/_app/immutable/entry/start.COXnrrUL.js +1 -0
- package/configurator/_app/immutable/nodes/{0.DGjBCl-6.js → 0.7vFI_dZi.js} +1 -1
- package/configurator/_app/immutable/nodes/{1.DNvFJEdz.js → 1.RIoMA8xn.js} +1 -1
- package/configurator/_app/immutable/nodes/{2.CNvMMSx1.js → 2.D384dkHE.js} +3 -3
- package/configurator/_app/immutable/nodes/{3.pBby37KF.js → 3.CiByyjYN.js} +1 -1
- package/configurator/_app/version.json +1 -1
- package/configurator/index.html +6 -6
- package/configurator/sidebar.html +6 -6
- package/index.d.ts +3 -0
- package/package.json +1 -1
- package/configurator/_app/immutable/chunks/Bu_-InX1.js +0 -1
- package/configurator/_app/immutable/chunks/Cbw5Gp1l.js +0 -1
- package/configurator/_app/immutable/entry/start.-8Jgo1rw.js +0 -1
package/chat/liipgpt-chat.js
CHANGED
|
@@ -565,22 +565,22 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
565
565
|
.sonner-loading-bar {transition:none !important;
|
|
566
566
|
animation: none !important;}
|
|
567
567
|
}.sonner-loader {position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);transform-origin:center;transition:opacity 200ms,
|
|
568
|
-
transform 200ms;}.sonner-loader[data-visible='false'] {opacity:0;transform:scale(0.8) translate(-50%, -50%);}`};function _y(e,t){D(t,!0),ga(e,gy);function n(e){return e===`system`?typeof window<`u`&&window.matchMedia&&window.matchMedia(`(prefers-color-scheme: dark)`).matches?dy:fy:e}let r=K(t,`invert`,7,!1),i=K(t,`position`,7,`bottom-right`),a=K(t,`hotkey`,23,()=>[`altKey`,`KeyT`]),o=K(t,`expand`,7,!1),s=K(t,`closeButton`,7,!1),c=K(t,`offset`,7,oy),l=K(t,`mobileOffset`,7,sy),u=K(t,`theme`,7,`light`),d=K(t,`richColors`,7,!1),f=K(t,`duration`,7,cy),p=K(t,`visibleToasts`,7,ay),m=K(t,`toastOptions`,23,()=>({})),h=K(t,`dir`,7,`auto`),g=K(t,`gap`,7,uy),_=K(t,`pauseWhenPageIsHidden`,7,!1),v=K(t,`loadingIcon`,7),y=K(t,`successIcon`,7),b=K(t,`errorIcon`,7),x=K(t,`warningIcon`,7),S=K(t,`closeIcon`,7),C=K(t,`infoIcon`,7),ee=K(t,`containerAriaLabel`,7,`Notifications`),te=K(t,`class`,7),ne=K(t,`closeButtonAriaLabel`,7,`Close toast`),re=K(t,`onblur`,7),ie=K(t,`onfocus`,7),ae=K(t,`onmouseenter`,7),oe=K(t,`onmousemove`,7),se=K(t,`onmouseleave`,7),ce=K(t,`ondragend`,7),le=K(t,`onpointerdown`,7),ue=K(t,`onpointerup`,7),de=fo(t,`$$slots.$$events.$$legacy.$$host.invert.position.hotkey.expand.closeButton.offset.mobileOffset.theme.richColors.duration.visibleToasts.toastOptions.dir.gap.pauseWhenPageIsHidden.loadingIcon.successIcon.errorIcon.warningIcon.closeIcon.infoIcon.containerAriaLabel.class.closeButtonAriaLabel.onblur.onfocus.onmouseenter.onmousemove.onmouseleave.ondragend.onpointerdown.onpointerup`.split(`.`));function fe(){if(h()!==`auto`)return h();if(typeof window>`u`||typeof document>`u`)return`ltr`;let e=document.documentElement.getAttribute(`dir`);return e===`auto`||!e?(Xr(()=>h(window.getComputedStyle(document.documentElement).direction??`ltr`)),h()):(Xr(()=>h(e)),e)}let pe=A(()=>Array.from(new Set([i(),...Ev.toasts.filter(e=>e.position).map(e=>e.position)].filter(Boolean)))),me=j(!1),he=j(!1),ge=j(Dn(n(u()))),_e=j(void 0),ve=j(null),ye=j(!1),be=A(()=>a().join(`+`).replace(/Key/g,``).replace(/Digit/g,``));$n(()=>{Ev.toasts.length<=1&&M(me,!1)}),$n(()=>{let e=Ev.toasts.filter(e=>e.dismiss&&!e.delete);e.length>0&&(Ev.toasts=Ev.toasts.map(t=>e.find(e=>e.id===t.id)?{...t,delete:!0}:t))}),$n(()=>()=>{L(_e)&&L(ve)&&(L(ve).focus({preventScroll:!0}),M(ve,null),M(ye,!1))}),Ii(()=>(Ev.reset(),ri(document,`keydown`,e=>{a().every(t=>e[t]||e.code===t)&&(M(me,!0),L(_e)?.focus()),e.code===`Escape`&&(document.activeElement===L(_e)||L(_e)?.contains(document.activeElement))&&M(me,!1)}))),$n(()=>{if(u()!==`system`&&M(ge,u()),typeof window<`u`){u()===`system`&&(window.matchMedia&&window.matchMedia(`(prefers-color-scheme: dark)`).matches?M(ge,dy):M(ge,fy));let e=window.matchMedia(`(prefers-color-scheme: dark)`),t=({matches:e})=>{u()===`system`&&M(ge,e?dy:fy,!0)};`addEventListener`in e?e.addEventListener(`change`,t):e.addListener(t)}});let xe=e=>{re()?.(e),L(ye)&&!e.currentTarget.contains(e.relatedTarget)&&(M(ye,!1),L(ve)&&(L(ve).focus({preventScroll:!0}),M(ve,null)))},Se=e=>{ie()?.(e),!(e.target instanceof HTMLElement&&e.target.dataset.dismissible===`false`)&&(L(ye)||(M(ye,!0),M(ve,e.relatedTarget,!0)))},Ce=e=>{le()?.(e),!(e.target instanceof HTMLElement&&e.target.dataset.dismissible===`false`)&&M(he,!0)},we=e=>{ae()?.(e),M(me,!0)},Te=e=>{se()?.(e),L(he)||M(me,!1)},Ee=e=>{oe()?.(e),M(me,!0)},De=e=>{ce()?.(e),M(me,!1)},Oe=e=>{ue()?.(e),M(he,!1)};Sv.set(new Ov);var ke={get invert(){return r()},set invert(e=!1){r(e),k()},get position(){return i()},set position(e=`bottom-right`){i(e),k()},get hotkey(){return a()},set hotkey(e=[`altKey`,`KeyT`]){a(e),k()},get expand(){return o()},set expand(e=!1){o(e),k()},get closeButton(){return s()},set closeButton(e=!1){s(e),k()},get offset(){return c()},set offset(e=oy){c(e),k()},get mobileOffset(){return l()},set mobileOffset(e=sy){l(e),k()},get theme(){return u()},set theme(e=`light`){u(e),k()},get richColors(){return d()},set richColors(e=!1){d(e),k()},get duration(){return f()},set duration(e=cy){f(e),k()},get visibleToasts(){return p()},set visibleToasts(e=ay){p(e),k()},get toastOptions(){return m()},set toastOptions(e={}){m(e),k()},get dir(){return h()},set dir(e=`auto`){h(e),k()},get gap(){return g()},set gap(e=uy){g(e),k()},get pauseWhenPageIsHidden(){return _()},set pauseWhenPageIsHidden(e=!1){_(e),k()},get loadingIcon(){return v()},set loadingIcon(e){v(e),k()},get successIcon(){return y()},set successIcon(e){y(e),k()},get errorIcon(){return b()},set errorIcon(e){b(e),k()},get warningIcon(){return x()},set warningIcon(e){x(e),k()},get closeIcon(){return S()},set closeIcon(e){S(e),k()},get infoIcon(){return C()},set infoIcon(e){C(e),k()},get containerAriaLabel(){return ee()},set containerAriaLabel(e=`Notifications`){ee(e),k()},get class(){return te()},set class(e){te(e),k()},get closeButtonAriaLabel(){return ne()},set closeButtonAriaLabel(e=`Close toast`){ne(e),k()},get onblur(){return re()},set onblur(e){re(e),k()},get onfocus(){return ie()},set onfocus(e){ie(e),k()},get onmouseenter(){return ae()},set onmouseenter(e){ae(e),k()},get onmousemove(){return oe()},set onmousemove(e){oe(e),k()},get onmouseleave(){return se()},set onmouseleave(e){se(e),k()},get ondragend(){return ce()},set ondragend(e){ce(e),k()},get onpointerdown(){return le()},set onpointerdown(e){le(e),k()},get onpointerup(){return ue()},set onpointerup(e){ue(e),k()}},Ae=hy();G(Ae,`tabindex`,-1);var je=N(Ae),Me=e=>{var n=z();Xi(P(n),18,()=>L(pe),e=>e,(e,n,i,a)=>{let u=A(()=>{let[e,t]=n.split(`-`);return{y:e,x:t}}),h=A(()=>py(c(),l()));var ee=my();Ja(ee,e=>({tabindex:-1,dir:e,class:te(),"data-sonner-toaster":!0,"data-sonner-theme":L(ge),"data-y-position":L(u).y,"data-x-position":L(u).x,style:t.style,onblur:xe,onfocus:Se,onmouseenter:we,onmousemove:Ee,onmouseleave:Te,ondragend:De,onpointerdown:Ce,onpointerup:Oe,...de,[Fa]:{"--front-toast-height":`${Ev.heights[0]?.height}px`,"--width":`${ly}px`,"--gap":`${g()}px`,"--offset-top":L(h)[`--offset-top`],"--offset-right":L(h)[`--offset-right`],"--offset-bottom":L(h)[`--offset-bottom`],"--offset-left":L(h)[`--offset-left`],"--mobile-offset-top":L(h)[`--mobile-offset-top`],"--mobile-offset-right":L(h)[`--mobile-offset-right`],"--mobile-offset-bottom":L(h)[`--mobile-offset-bottom`],"--mobile-offset-left":L(h)[`--mobile-offset-left`]}}),[()=>fe()],void 0,void 0,`svelte-s0xby2`),Xi(ee,23,()=>Ev.toasts.filter(e=>!e.position&&L(i)===0||e.position===n),e=>e.id,(e,t,i,a)=>{{let a=e=>{var t=z(),n=P(t),r=e=>{var t=z();H(P(t),()=>y()??w),B(e,t)},i=e=>{Xv(e,{})};U(n,e=>{y()?e(r):y()!==null&&e(i,1)}),B(e,t)},c=e=>{var t=z(),n=P(t),r=e=>{var t=z();H(P(t),()=>b()??w),B(e,t)},i=e=>{Qv(e,{})};U(n,e=>{b()?e(r):b()!==null&&e(i,1)}),B(e,t)},l=e=>{var t=z(),n=P(t),r=e=>{var t=z();H(P(t),()=>x()??w),B(e,t)},i=e=>{ey(e,{})};U(n,e=>{x()?e(r):x()!==null&&e(i,1)}),B(e,t)},u=e=>{var t=z(),n=P(t),r=e=>{var t=z();H(P(t),()=>C()??w),B(e,t)},i=e=>{ny(e,{})};U(n,e=>{C()?e(r):C()!==null&&e(i,1)}),B(e,t)},h=e=>{var t=z(),n=P(t),r=e=>{var t=z();H(P(t),()=>S()??w),B(e,t)},i=e=>{iy(e,{})};U(n,e=>{S()?e(r):S()!==null&&e(i,1)}),B(e,t)},g=A(()=>m()?.duration??f()),ee=A(()=>m()?.class??``),te=A(()=>m()?.descriptionClass||``),re=A(()=>m()?.style??``),ie=A(()=>m().classes||{}),ae=A(()=>m().unstyled??!1),oe=A(()=>m()?.cancelButtonStyle??``),se=A(()=>m()?.actionButtonStyle??``),ce=A(()=>m()?.closeButtonAriaLabel??ne());Jv(e,{get index(){return L(i)},get toast(){return L(t)},get defaultRichColors(){return d()},get duration(){return L(g)},get class(){return L(ee)},get descriptionClass(){return L(te)},get invert(){return r()},get visibleToasts(){return p()},get closeButton(){return s()},get interacting(){return L(he)},get position(){return n},get style(){return L(re)},get classes(){return L(ie)},get unstyled(){return L(ae)},get cancelButtonStyle(){return L(oe)},get actionButtonStyle(){return L(se)},get closeButtonAriaLabel(){return L(ce)},get expandByDefault(){return o()},get expanded(){return L(me)},get pauseWhenPageIsHidden(){return _()},get loadingIcon(){return v()},successIcon:a,errorIcon:c,warningIcon:l,infoIcon:u,closeIcon:h,$$slots:{successIcon:!0,errorIcon:!0,warningIcon:!0,infoIcon:!0,closeIcon:!0}})}}),E(ee),so(ee,e=>M(_e,e),()=>L(_e)),I(()=>ee.dir=ee.dir),B(e,ee)}),B(e,n)};return U(je,e=>{Ev.toasts.length>0&&e(Me)}),E(Ae),I(()=>G(Ae,`aria-label`,`${ee()??``} ${L(be)??``}`)),B(e,Ae),O(ke)}q(_y,{invert:{},position:{},hotkey:{},expand:{},closeButton:{},offset:{},mobileOffset:{},theme:{},richColors:{},duration:{},visibleToasts:{},toastOptions:{},dir:{},gap:{},pauseWhenPageIsHidden:{},loadingIcon:{},successIcon:{},errorIcon:{},warningIcon:{},closeIcon:{},infoIcon:{},containerAriaLabel:{},class:{},closeButtonAriaLabel:{},onblur:{},onfocus:{},onmouseenter:{},onmousemove:{},onmouseleave:{},ondragend:{},onpointerdown:{},onpointerup:{}},[],[],{mode:`open`});var vy=e=>{let t=new Set;Object.getOwnPropertyNames(e).forEach(e=>t.add(e));let n=Object.getPrototypeOf(e);for(;n&&n!==Object.prototype;)Object.getOwnPropertyNames(n).forEach(e=>t.add(e)),n=Object.getPrototypeOf(n);return Array.from(t)},yy=(e,t)=>{let n={};return t.forEach(t=>{n[t]=e[t]}),n},by=console.warn,xy=()=>{},Sy=(e,t)=>Xr(()=>{console.warn=xy;let n=st(t?yy(e,t):e);return console.warn=by,n}),Cy=e=>e&&typeof e.then==`function`,wy=class{config;self;devtools;stateKeys;constructor(e,t){this.config=e,this.self=t,typeof window<`u`&&window.__REDUX_DEVTOOLS_EXTENSION__&&(this.stateKeys=vy(this.config.state),this.devtools=window.__REDUX_DEVTOOLS_EXTENSION__.connect({name:this.config.name??`updatelogic`}),this.devtools.init(this.createStateSnapshot()),this.devtools.subscribe(e=>{e.type===`DISPATCH`&&e.state}))}createStateSnapshot(){return Sy(this.config.state,this.stateKeys)}sendStart(e,t){this.devtools.send({type:`→ ${e}`,args:t},this.createStateSnapshot())}sendError(e,t,n){this.devtools.send({type:`❌ ${e}`,args:t,error:n},this.createStateSnapshot())}sendSuccess(e,t,n){this.devtools.send({type:`✓ ${e}`,args:t,return:n},this.createStateSnapshot())}isIncluded(e){return this.config.excludeInDevTools?!this.config.excludeInDevTools.includes(e):!0}createProxyFunction(e,t){let n=this.devtools&&this.isIncluded(e);return typeof t==`function`?(...r)=>{if(!n)return Xr(()=>t.call(this.self,...r));let i=Sy(r);this.sendStart(e,i);try{let n=Xr(()=>t.call(this.self,...r));return Cy(n)?n.then(t=>(this.sendSuccess(e,i,t),t),t=>{throw this.sendError(e,i,t),t}):(this.sendSuccess(e,i,n),n)}catch(t){throw this.sendError(e,i,t),t}}:t}},Ty=(e,t)=>{let n={},r=new wy(e,n);return Object.keys(t).forEach(e=>{if(e===`state`||e===`name`)return;let i=t[e];n[e]=r.createProxyFunction(e,i)}),n};async function Ey(){if(typeof navigator>`u`||!navigator.mediaDevices||!navigator.mediaDevices.enumerateDevices)return!1;try{return(await navigator.mediaDevices.enumerateDevices()).some(e=>e.kind===`audioinput`)}catch(e){return console.error(`Error checking for microphone:`,e),!1}}function Dy(){return typeof window>`u`||!window.MediaRecorder?null:MediaRecorder.isTypeSupported(`audio/mp4`)?`audio/mp4`:MediaRecorder.isTypeSupported(`audio/webm`)?`audio/webm`:MediaRecorder.isTypeSupported(`audio/wav`)?`audio/wav`:null}function Oy(){return typeof window>`u`?!1:!!(window.MediaRecorder&&Dy())}function ky(){if(typeof window>`u`)return!1;if(`ontouchstart`in window||navigator.maxTouchPoints>0)return!0;let e=navigator.msMaxTouchPoints;return!!(`msMaxTouchPoints`in navigator&&e&&e>0)}function Ay(){return typeof window>`u`?!1:!!(/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)||ky())}var jy=class{mediaRecorder=null;audioChunks=[];started=!1;starting=!1;stream=null;options;audioContext=null;analyser=null;dataArray=null;volumeUpdateInterval=null;constructor(e={}){this.options=e}async start(){if(this.started||this.starting){console.warn(`AudioRecorder: Start already in progress or already started`);return}if(!Oy()||!navigator.mediaDevices){let e=Error(`MediaRecorder not supported or no microphone access`);throw this.options.onError?.(e),e}try{if(this.starting=!0,this.stream=await navigator.mediaDevices.getUserMedia({audio:{echoCancellation:!0,noiseSuppression:!0,autoGainControl:!0},video:!1}),!this.starting){this.stopStream(this.stream);return}this.mediaRecorder&&this.mediaRecorder.state!==`inactive`&&(console.warn(`AudioRecorder: MediaRecorder already active, stopping previous recording`),this.mediaRecorder.stop(),this.cleanup()),this.started=!0,this.starting=!1;let e=Dy();if(!e)throw Error(`No supported media type found`);let t={mimeType:e};this.mediaRecorder=new MediaRecorder(this.stream,t),this.audioChunks=[],this.mediaRecorder.ondataavailable=e=>{e.data.size>0&&this.audioChunks.push(e.data)},this.mediaRecorder.onstop=async()=>{let t=this.audioChunks.length>0?new Blob(this.audioChunks,{type:e}):null;await this.options.onDataAvailable?.(t),this.options.onStop?.(),this.cleanup()},this.mediaRecorder.onerror=e=>{let t=Error(`MediaRecorder error: ${e}`);this.options.onError?.(t),this.cleanup()},this.mediaRecorder.start(),this.setupVolumeAnalysis(this.stream),this.options.onStart?.()}catch(e){this.started=!1,this.starting=!1;let t=e instanceof Error?e:Error(String(e));throw this.options.onError?.(t),t}}stop(){this.started=!1,this.starting=!1,this.volumeUpdateInterval&&=(clearInterval(this.volumeUpdateInterval),null),this.mediaRecorder&&this.mediaRecorder.state!==`inactive`?this.mediaRecorder.stop():(this.stream&&this.stopStream(this.stream),this.cleanup())}setupVolumeAnalysis(e){if(this.options.onVolumeChange)try{this.audioContext=new AudioContext,this.analyser=this.audioContext.createAnalyser(),this.analyser.fftSize=256,this.analyser.smoothingTimeConstant=.8;let t=this.analyser.frequencyBinCount;this.dataArray=new Uint8Array(t),this.audioContext.createMediaStreamSource(e).connect(this.analyser),this.startVolumeMonitoring()}catch(e){console.warn(`Failed to set up volume analysis:`,e)}}startVolumeMonitoring(){!this.analyser||!this.dataArray||!this.options.onVolumeChange||(this.volumeUpdateInterval=window.setInterval(()=>{if(!this.analyser||!this.dataArray||!this.started)return;this.analyser.getByteFrequencyData(this.dataArray);let e=0;for(let t=0;t<this.dataArray.length;t++)e+=this.dataArray[t]*this.dataArray[t];let t=Math.sqrt(e/this.dataArray.length)/255;t=(t*3)**.7;let n=Math.min(100,Math.max(0,Math.round(t*100)));this.options.onVolumeChange?.(n)},100))}get recording(){return this.started&&this.mediaRecorder?.state===`recording`}get isStarting(){return this.starting}stopStream(e){e.getTracks().forEach(e=>e.stop())}cleanup(){this.volumeUpdateInterval&&=(clearInterval(this.volumeUpdateInterval),null),this.audioContext&&=(this.audioContext.close().catch(console.warn),null),this.analyser=null,this.dataArray=null,this.stream&&=(this.stopStream(this.stream),null),this.mediaRecorder=null,this.audioChunks=[],this.started=!1,this.starting=!1}static isSupported(){return Oy()}static getSupportedMediaType(){return Dy()}},My=e=>(localStorage.setItem(`liipgpt-color-scheme`,e),Py([`light`,`dark`])),Ny=()=>{let e=localStorage.getItem(`liipgpt-color-scheme`);return e===`light`||e===`dark`?e:`system`},Py=e=>{let t=Ny();return t===`system`&&(t=window.matchMedia(`(prefers-color-scheme: dark)`).matches?`dark`:`light`),e.includes(t)?t:e[0]??`light`},Fy=Cs(),Iy=(e,t)=>{if(e instanceof HTMLTextAreaElement&&t instanceof HTMLTextAreaElement){t.textContent=e.value;return}if(e instanceof HTMLSelectElement&&t instanceof HTMLSelectElement){Array.from(e.options).forEach((e,n)=>{t.options[n]&&(t.options[n].selected=e.selected)});return}e instanceof HTMLInputElement&&t instanceof HTMLInputElement&&(t.setAttribute(`value`,e.value),(e.type===`checkbox`||e.type===`radio`)&&(e.checked?t.setAttribute(`checked`,`checked`):t.removeAttribute(`checked`)))},Ly=e=>{let t=e.cloneNode(!0);if(!(t instanceof Element))return``;let n=`input, textarea, select`,r=e.querySelectorAll(n),i=t.querySelectorAll(n);return r.forEach((e,t)=>{let n=i[t];n&&Iy(e,n)}),Fy.sanitize(t.outerHTML,{FORBID_TAGS:[`style`,`script`],FORBID_ATTR:[`style`,`class`]})},Ry=e=>{if(!e?.length)return[];let t=e.join(`,`),n=document.querySelectorAll(t);return Array.from(n,Ly)},zy=`liipgpt:context`,By=class{contextVersion=0;#e=j();get currentContext(){return L(this.#e)}set currentContext(e){M(this.#e,e,!0)}getFromLocalStorage(){let e=localStorage.getItem(zy);if(e){let t;try{if(t=JSON.parse(e),t.version!==this.contextVersion){localStorage.removeItem(zy);return}else return t.context}catch(e){console.error(`Failed to parse liipgpt:context`,e);return}}}storeToLocalStorage(){localStorage.setItem(`liipgpt:context`,JSON.stringify({version:Z.data.chatConfig.contextVersion,context:this.currentContext}))}constructor(e){this.init=e,this.currentContext=this.getFromLocalStorage()??e.initialValue}getContext(){return st(this.currentContext)}setContextVersion(e){this.contextVersion=e}setContext(e){this.currentContext=e,this.storeToLocalStorage()}resetContext(){this.currentContext=this.init.initialValue,this.storeToLocalStorage()}updateContext(e){this.setContext(e(this.currentContext))}},Vy=()=>localStorage.getItem(zy),Hy=[{type:`email`,check:e=>/\b[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}\b/.test(e)},{type:`creditCard`,check:e=>/\b(?:\d[ -]*?){13,16}\b/.test(e)},{type:`ahv`,check:e=>/\b756\.\d{4}\.\d{4}\.\d{2}\b/.test(e)},{type:`phoneSwiss`,check:e=>/\b0(?:\s*\d){2}(?:\s*\/\s*)?(?:\s*\d){7,}\b/.test(e)},{type:`phoneInternational`,check:e=>/(?:\+|00)(?:\s*\d){10,}\b/.test(e)},{type:`swissPassport`,check:e=>/\b[A-HJ-NP-Z](?=.*\d)[A-HJ-NP-Z0-9]{7}\b/.test(e)},{type:`longNumber`,check:e=>/\b\d{9,}\b/.test(e)}],Uy=e=>{for(let t of Hy)if(t.check(e))return t.type},Wy=`liipgpt:selectorValues`,Gy=`liipgpt:selectorKnownDefaults`,Ky=()=>{try{let e=s_.getItem(Wy),t=s_.getItem(Gy);return e?{values:JSON.parse(e),knownDefaults:t?JSON.parse(t):{}}:null}catch{return null}},qy=e=>{let t={};for(let n of e)t[n.settingName]=n.defaultValues??(n.allowEmpty?[]:[n.values[0]]).filter(Boolean);return t},Jy=(e,t)=>{try{let n=qy(t);s_.setItem(Wy,JSON.stringify(e)),s_.setItem(Gy,JSON.stringify(n))}catch(e){console.error(`Failed to save selector values:`,e)}},Yy=e=>{try{let t=Ky();if(!t)return;delete t.values[e],delete t.knownDefaults[e],s_.setItem(Wy,JSON.stringify(t.values)),s_.setItem(Gy,JSON.stringify(t.knownDefaults))}catch(e){console.error(`Failed to clear selector saved state:`,e)}},Xy=e=>{let t=Ky(),n=e.map(e=>{let n=e.defaultValues??(e.allowEmpty?[]:[e.values[0]]).filter(Boolean);if(!t?.values[e.settingName])return[e.settingName,n];let r=t.values[e.settingName],i=t.knownDefaults[e.settingName]||[],a=r.filter(t=>e.values.includes(t)),o=i.filter(e=>!n.includes(e)),s=a.filter(e=>!o.includes(e)),c=n.filter(e=>!i.includes(e)&&!s.includes(e)),l=[...s,...c];return l.length===0&&!e.allowEmpty?[e.settingName,n]:[e.settingName,l]});return Object.fromEntries(n)},Zy=class extends Error{constructor(e){super(e),this.name=`UnreachableError`}},Qy=(e,t)=>{if(!e)return;let n=t.find(t=>t.id===e);return n||console.warn(`autofire-predefined-question-id="${e}" did not match any loaded predefined question. Falling back to default routing.`),n},$y=(e,t,n,r,i)=>{if(e&&!t)return{name:`consent-page`};let a=new URLSearchParams(window.location.search),o=a.get(`q`),s=a.get(`id`)??void 0,c=a.get(`sid`)??void 0;return o?{name:`chat-page`,query:o,predefinedQuestionId:s,switchQuestionId:c}:i?{name:`chat-page`,query:i}:r?{name:`chat-page`,query:r.question,predefinedQuestionId:r.id}:n?{name:`chat-page`}:{name:`start-page`}},eb=`follow-up-q`,tb=e=>/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i.test(e),nb=()=>{let e=new URLSearchParams(window.location.hash.replace(/^#/,``)).get(`cID`)??void 0;return{cID:e&&tb(e)?e:void 0,followUpQuestion:new URLSearchParams(window.location.search).get(eb)?.trim()||void 0}},rb=()=>{let e=new URLSearchParams(window.location.search);if(!e.has(eb))return;e.delete(eb);let t=e.toString();history.replaceState(null,``,`${window.location.pathname}${t?`?${t}`:``}${window.location.hash}`)},ib=e=>{if(e)try{let t=JSON.parse(e);if(t&&typeof t==`object`&&!Array.isArray(t))return t;console.warn(`additional-start-parameters must be a JSON object. Received: ${e}`);return}catch(t){console.warn(`Failed to parse additional-start-parameters as JSON: ${e}`,t);return}},ab=e=>{let t=ib(e);return t?(e=>Array.isArray(e)?e.map(String):typeof e==`string`?e.split(`,`).map(e=>e.trim()).filter(Boolean):[])(t.scopeAvailableSlugs).length===1:!1},ob=e=>e?e.map(e=>({id:e_(),...e})):[],Z=new class{#e=j(Dn({}));get data(){return L(this.#e)}set data(e){M(this.#e,e,!0)}#t=j(Dn({}));get targets(){return L(this.#t)}set targets(e){M(this.#t,e,!0)}#n=j(!1);get initialized(){return L(this.#n)}set initialized(e){M(this.#n,e,!0)}#r=j(0);get currentAudioVolume(){return L(this.#r)}set currentAudioVolume(e){M(this.#r,e,!0)}ariaLiveMessagesClearingTimeoutDuration=350;#i=j(null);get currentAudioRecorder(){return L(this.#i)}set currentAudioRecorder(e){M(this.#i,e,!0)}#a=j(!1);get isTranscribing(){return L(this.#a)}set isTranscribing(e){M(this.#a,e,!0)}#o=A(()=>{if(!this.initialized)return[];let e=this.data.chatConfig.menu;return e?e[this.data.language]??[]:[]});get menu(){return L(this.#o)}set menu(e){M(this.#o,e)}#s=A(()=>this.initialized?this.data.chatConfig.translations[this.data.language]??{}:{});get t(){return L(this.#s)}set t(e){M(this.#s,e)}#c=A(()=>this.initialized?R_[this.data.language]??{}:R_.en??{});get errorTranslations(){return L(this.#c)}set errorTranslations(e){M(this.#c,e)}#l=A(()=>this.initialized?z_[this.data.language]??{}:z_.en??{});get piiTranslations(){return L(this.#l)}set piiTranslations(e){M(this.#l,e)}#u=A(()=>this.initialized?this.data.currentColorScheme:`light`);get colorScheme(){return L(this.#u)}set colorScheme(e){M(this.#u,e)}#d=A(()=>this.initialized?this.data.chatConfig.fullTheme[this.data.currentColorScheme]:{});get themeBase(){return L(this.#d)}set themeBase(e){M(this.#d,e)}#f=A(()=>this.themeBase.tokens);get theme(){return L(this.#f)}set theme(e){M(this.#f,e)}#p=A(()=>{if(!this.initialized)return[];let e=[];for(let t of this.data.chatConfig.selectorsConfig)t.allowEmpty||(this.data.selectorValues[t.settingName]||[]).length===0&&e.push(t.settingName);return e});get selectorsWithErrors(){return L(this.#p)}set selectorsWithErrors(e){M(this.#p,e)}#m=A(()=>{if(!this.initialized)return{};let e=this.data.chatConfig,t={};for(let n of e.selectorsConfig){let r=q_(e.translations,n.settingName,this.data.language,e.supportedLanguages);r||console.error(`Missing translation for setting ${n.settingName} in all languages`),t[n.settingName]=r??{name:n.settingName,placeholder:``,values:{}}}return t});get selectorTranslations(){return L(this.#m)}set selectorTranslations(e){M(this.#m,e)}#h=A(()=>{if(!this.initialized)return!1;let e=this.data.chatConfig;return this.data.route.name===`chat-page`&&!e.forceChatPage||e.showContextInfo||e.showContextMenu||e.showCloseChatButton||this.data.props.flyout});get hasMainNavigationContent(){return L(this.#h)}set hasMainNavigationContent(e){M(this.#h,e)}#g=A(()=>{if(!this.initialized)return``;let e=this.t,t=this.data.chatConfig,n=this.data.route.name===`chat-page`&&!t.forceChatPage,r=[];return n&&r.push(e.newChat),t.showContextInfo&&r.push(e.ariaMainNavigationInfo),t.showContextMenu&&(this.menu.length>0&&r.push(e.ariaMainNavigationLinks),t.supportedLanguages.length>0&&r.push(e.ariaMainNavigationLanguageSwitch),this.data.has2ColorSchemes&&r.push(e.ariaMainNavigationColorMode)),(t.showCloseChatButton||this.data.props.flyout)&&r.push(e.closeChat),r.length===0?e.ariaMainNavigation:`${e.ariaMainNavigation}: ${r.join(`, `)}`});get ariaMainNavigationRegion(){return L(this.#g)}set ariaMainNavigationRegion(e){M(this.#g,e)}},sb,cb,lb,ub=Ty({name:`chat-logic`,state:Z,excludeInDevTools:[`onInput`]},{async init(e){cb=e;let t=cb.speechRecognitionApiKey||void 0;sb=new C_({apiUrl:cb.apiUrl,apiKey:cb.apiKey,speechRecognitionApiKey:t,strict:!0,startParameters:ib(cb.additionalStartParameters)});try{let e=await sb.getChatConfig();window.CHAT_CONFIG_OVERRIDE&&Object.assign(e,window.CHAT_CONFIG_OVERRIDE);let t=(await sb.getMetadata()).mode===`maintenance`;t&&this.showErrorToast(`maintenance`);let n=L_(e);cb.inlineLayout!==void 0&&(n.inlineLayout=cb.inlineLayout),cb.forceChatPage!==void 0&&(n.forceChatPage=cb.forceChatPage);let r;r=cb.lang?V_(cb.lang,n.supportedLanguages):W_(n.supportedLanguages),U_(r,Z.targets.mainElement);let i=await this.getPredefinedQuestions(r),a=n.translations[r]?.ariaOpensInNewTab;a&&sb.setNewTabSrText(a);let o=[];if(n.renderKatex){let e=await import(`https://esm.sh/marked-katex-extension@5.1.5`).catch(e=>{console.error(`Couldn't load marked-katex-extension:`,e)});e&&(sb.setMarkedExtensions(e.default({nonStandard:!0,output:`mathml`})),o.push(`https://cdn.jsdelivr.net/npm/katex@0.16.22/dist/katex.min.css`))}let s=Object.keys(n.fullTheme),c=!1;if(n.forceConsent)try{c=s_.getItem(`liipgpt:termsAccepted`)===`true`}catch(e){console.warn(`Failed to load terms acceptance from storage:`,e)}let l=Qy(cb.autofirePredefinedQuestionId,i);Z.data={currentConversationState:`idle`,chatConfig:n,language:r,predefinedQuestions:i,isInMaintenance:t,history:ob(n.messageAdditions.init),selectedColorScheme:Ny(),has2ColorSchemes:s.length===2,currentColorScheme:Py(s),conversationFeedbackId:void 0,conversationFeedbackIsOpen:!1,answerFormMessageId:void 0,openedPopup:void 0,props:cb,flyoutIsOpen:!1,questionHasPii:void 0,chatInputValue:``,selectorValues:Xy(n.selectorsConfig),selectorsIsOpen:!1,predefinedQuestionId:void 0,switchQuestionId:void 0,currentReferencesAsideId:void 0,ariaLiveStatusMessage:void 0,ariaLiveStatusMessageClearingTimeout:void 0,wasReferencesAsideClosed:!1,isAsideMobile:!0,route:$y(n.forceConsent??!1,c,n.forceChatPage??!1,l,cb.question),additionalStylesheets:o,hasOpenedOverlays:!1,isInlineLayoutContained:!1,termsAccepted:c,selectedTopic:void 0},window.LIIPGPT_LISTENERS?.route?.(Z.data.route),window.LIIPGPT_LISTENERS?.conversation?.(Z.data.currentConversationState),Z.data.selectorsIsOpen=Z.data.chatConfig.showExpandedSelectors??!1,Z.initialized=!0,this.checkForOpenedPopup(),window.addEventListener(`hashchange`,()=>{this.checkForOpenedPopup()}),await this.startFromHandoverOrRoute(()=>this.goto($y(n.forceConsent??!1,c,n.forceChatPage??!1,l,cb.question),!0))}catch(e){throw kv.error(e instanceof Error?e.message:`Failed to load the chatbot. Please reload the page.`,{duration:1e4,unstyled:!0,classes:{toast:`toast`}}),e}},setTarget(e,t){Z.targets[e]=t},goto(e,t=!1){if(!(!t&&(0,rv.default)(Z.data.route,e)))switch(Z.data.route=e,window.LIIPGPT_LISTENERS?.route?.(e),e.name){case`consent-page`:break;case`start-page`:e.prefill&&(Z.data.chatInputValue=e.prefill);break;case`chat-page`:if(Z.data.chatInputValue=e.query??``,Z.data.predefinedQuestionId=e.predefinedQuestionId,Z.data.switchQuestionId=e.switchQuestionId,e.query&&(this.onSubmit(),Z.data.chatConfig.addQueryToUrlParams)){let t=new URLSearchParams(window.location.search);t.set(`q`,e.query),e.predefinedQuestionId?t.set(`id`,e.predefinedQuestionId):t.delete(`id`),e.switchQuestionId?t.set(`sid`,e.switchQuestionId):t.delete(`sid`),history.pushState(null,``,`?${t.toString()}${window.location.hash}`)}break}},getSelectorConfig(e){let t=Z.data.chatConfig.selectorsConfig.find(t=>t.settingName===e);if(!t)throw Error(`Setting ${e} not found`);return t},getPrettifiedSelectorValues(){let e=Object.entries(Z.data.selectorValues).map(([e,t])=>{let n;try{n=this.getSelectorConfig(e)}catch(t){console.error(`Error getting selector config for ${e}: ${t}`);return}return n.type===`single-select`?[e,t[0]]:[e,t]}).filter(e=>!!e);return Object.fromEntries(e)},setSelectorValue(e,t){let n=this.getSelectorConfig(e);if(!n){console.warn(`Trying to set setting ${e} but it is not defined in the chat config`);return}if(n.type===`single-select`&&t.length>1){console.warn(`Trying to set multiple values for single-select setting ${e}`);return}Z.data.selectorValues[e]=t,Jy(Z.data.selectorValues,Z.data.chatConfig.selectorsConfig)},resetSelectorToDefaults(e){let t=this.getSelectorConfig(e);if(!t){console.warn(`Trying to reset setting ${e} but it is not defined in the chat config`);return}let n=t.defaultValues??(t.allowEmpty?[]:[t.values[0]]).filter(Boolean);return Yy(e),Z.data.selectorValues[e]=n,Jy(Z.data.selectorValues,Z.data.chatConfig.selectorsConfig),n},async getPredefinedQuestions(e){if(cb?.hidePredefinedQuestions)return[];try{return sb.getPredefinedQuestions({url:window.location.origin+window.location.pathname,language:e})}catch(e){return console.warn(`Failed to load predefined questions:`,e),[]}},setColorScheme(e){Z.data.selectedColorScheme=e,Z.data.currentColorScheme=My(e),this.setAriaLiveStatusMessage(e===`dark`?Z.t.ariaDarkSelected:Z.t.ariaLightSelected)},async abort(){await lb?.abort()},changeConversationState(e){Z.data.currentConversationState=e,window.LIIPGPT_LISTENERS?.conversation?.(e)},onInput(e){Z.data.chatConfig.blockPII&&(Z.data.questionHasPii=Uy(e)),Z.data.chatInputValue=e,Z.data.predefinedQuestionId=void 0,Z.data.switchQuestionId=void 0},onSubmit(e=!1,t,n=!1){let r=Ry(Z.data.chatConfig.parentPageContext?.extractSelectors);if(Z.data.questionHasPii){console.warn(`Question contains PII, not submitting:`,Z.data.questionHasPii);return}let i=Z.data.chatConfig.questionPrefix?`${Z.data.chatConfig.questionPrefix} ${Z.data.chatInputValue}`:Z.data.chatInputValue;n||(Z.data.history.push(...ob(Z.data.chatConfig.messageAdditions.user.before)),Z.data.history.push({type:`user`,time:new Date().toISOString(),message:Z.data.chatInputValue}),Z.data.history.push(...ob(Z.data.chatConfig.messageAdditions.user.after)));let a=Z.data.history.push(...ob(Z.data.chatConfig.messageAdditions.bot.before));Z.data.history.push({id:`UNRESOLVED`,state:`loading`,errors:[],type:`bot`,time:new Date().toISOString(),message:{markdown:``,html:``,text:``},references:{all:[],used:[],unused:[]}});let o=!1,s=!1,c={features:cb.features?cb.features.trim().split(`,`):[`formatting`],mode:cb.mode||void 0,cache:cb.cache||void 0,onError:e=>{this.showErrorToast(e),window.LIIPGPT_LISTENERS?.error?.(e),(e===`pii-detected`||e===`blocked`)&&this.editLatestQuestion()},onMessage:e=>{e.type===`topic-selected`&&(Z.data.selectedTopic={label:e.label,placeholder:e.placeholder,locked:ab(cb.additionalStartParameters)}),e.type===`state`&&e.state!==`history-entry-initialized`&&!s&&(s=!0,this.setAriaLiveStatusMessage(Z.t.ariaQuestionSent))},lang:Z.data.language,selectorValues:{...this.getPrettifiedSelectorValues(),context:Vy(),...t},predefinedQuestionId:Z.data.predefinedQuestionId,switchQuestionId:Z.data.switchQuestionId,onEmbed:e=>{let t=Z.data.history[a];t&&t.type===`bot`&&!t.message.markdown?(Z.data.history[a]={...e,id:t.id??e_()},o=!0):Z.data.history.push({...e,id:e_()})}};Z.data.predefinedQuestionId=void 0,Z.data.switchQuestionId=void 0,r.length&&(c.selectorValues.parentPageContextHtml=r);let l=(e,t)=>{try{let n=new URL(e),r=new URL(t);return n.origin===r.origin&&n.pathname===r.pathname}catch{return!1}},u=Z.data.chatConfig.sendReferrer??`all`;if([`all`,`own`,`location`].includes(u)){let e=u===`location`||Z.data.props.flyout,t;t=e?`${window.location.protocol}//${window.location.host}${window.location.pathname}`:l(document.referrer,window.location.href)?null:document.referrer;let n=u===`own`&&!Z.data.props.flyout&&t&&!t.startsWith(window.location.origin);c.referrer=t&&!n?t:void 0}Z.data.props.source?c.source=Z.data.props.source:Z.data.props.flyout&&(c.source=`flyout`),Z.data.currentConversationId||(Z.data.currentConversationId=sb.createConversationId());let d=sb.chat(Z.data.currentConversationId,i,c);lb=d,Z.data.lastChatResponseId=d.id,Z.data.currentConversationState!==`searching`&&this.changeConversationState(`searching`);let f=!1,p,m=!!Z.data.currentReferencesAsideId;(e&&m||!e&&Z.data.chatConfig.showReferencesByDefault)&&(Z.data.isAsideMobile||this.openReferencesAside(d.id)),d.subscribe(e=>{if(!o&&Z.data.history[a]&&(Z.data.history[a]={question:Z.data.chatInputValue,...e}),Z.data.chatConfig.addRetrievalQuestionToUrlParams&&e.retrievalQuestion){let t=new URLSearchParams(window.location.search);t.get(`search`)!==e.retrievalQuestion&&(t.set(`search`,e.retrievalQuestion),history.replaceState(null,``,`?${t.toString()}${window.location.hash}`))}Z.data.chatConfig.showReferencesByDefault&&!Z.data.wasReferencesAsideClosed&&Z.data.currentReferencesAsideId!==e.id&&!Z.data.isAsideMobile&&this.openReferencesAside(e.id),e.state===`streaming`&&Z.data.currentConversationState!==`answering`&&this.changeConversationState(`answering`),e.state===`done`&&(this.changeConversationState(`idle`),f||(f=!0,this.setAriaLiveStatusMessage(`${Z.t.ariaAnswerReady} ... ${e.message.text} ... ${Z.data.selectedTopic?Z.t.ariaAnswerFinishedWithSelectedTopic:Z.t.ariaAnswerFinished}`),Z.data.history.push(...ob(Z.data.chatConfig.messageAdditions.bot.after))),Z.data.currentReferencesAsideId&&e.references.used.length>0?(clearTimeout(p),p=setTimeout(()=>{this.openReferencesAside(e.id)},100)):this.closeReferencesAside())}),Z.data.chatInputValue=``},async onStartSpeechRecognition(){try{if(!await Ey()){this.showErrorToast(`speech-not-supported`);return}if(await navigator.mediaDevices.getUserMedia({audio:!0}),jy.isSupported())Z.data.chatInputValue=``,Z.currentAudioRecorder=new jy({onDataAvailable:async e=>{Z.isTranscribing=!0,await this.handleTranscription(e)},onError:()=>{this.showErrorToast(`speech-microphone-access-denied`),Z.currentAudioRecorder=null,Z.isTranscribing=!1},onVolumeChange:e=>{Z.currentAudioVolume=e}}),Z.currentAudioRecorder.start();else{this.showErrorToast(`speech-not-supported`);return}}catch(e){throw this.showErrorToast(`speech-microphone-access-denied`),Z.currentAudioRecorder=null,Z.isTranscribing=!1,e}},editLatestQuestion(){let e=Z.data.history.findLastIndex(e=>e?.type===`user`);if(e===-1){console.error(`No last user question, available`);return}let t=Z.data.history.splice(e)[0];Z.data.chatInputValue=t.message},onStopSpeechRecognition(){if(Z.currentAudioRecorder){let e=Z.currentAudioRecorder;Z.currentAudioRecorder=null,e.stop()}Z.currentAudioVolume=0},async handleTranscription(e){if(!e){console.warn(`No audio data received`);return}try{let t=await sb.transcribeAudio(e,{lang:Z.data.language});if(t.error){this.showErrorToast(`speech-transcription-failed`);return}if(t.transcript.trim()){if(Z.data.chatConfig.blockPII&&(Z.data.questionHasPii=Uy(t.transcript.trim()),Z.data.questionHasPii))return;Z.data.chatInputValue=t.transcript.trim()}else this.showErrorToast(`speech-no-text-detected`)}catch(e){console.error(`Speech transcription error:`,e),this.showErrorToast(`speech-transcription-failed`)}finally{Z.currentAudioRecorder=null,Z.isTranscribing=!1,Z.currentAudioVolume=0}},async startFromHandoverOrRoute(e){let{cID:t,followUpQuestion:n}=nb();if(!t){e();return}let r=await this.rehydrateFromSearchSummaryHandover(t);n?(Z.data.route={name:`chat-page`},Z.data.chatInputValue=n,this.onSubmit(!0)):r||e(),rb()},async rehydrateFromSearchSummaryHandover(e){Z.data.currentConversationId=e;let t=await sb.getMetadata(),n=t.mode===`ready`?t.userId:void 0,r=n?await sb.getChatHistory(e,n):[];if(r.length===0)return Z.data.currentConversationId=void 0,!1;let i={all:[],used:[],unused:[]},a=new Qc({newTabSrText:Z.t.ariaOpensInNewTab}),o=[];for(let{question:e,answer:t}of r)o.push({type:`user`,time:new Date().toISOString(),message:e,id:e_()}),o.push({id:e_(),state:`done`,errors:[],type:`bot`,time:new Date().toISOString(),message:{markdown:t,html:a.toHTML(t,i),text:t},references:{all:[],used:[],unused:[]}});return Z.data.history=[...ob(Z.data.chatConfig.messageAdditions.init),...o],Z.data.route={name:`chat-page`},!0},async onStartConversation(e,t,n){await this.abort(),Z.data.history=ob(Z.data.chatConfig.messageAdditions.init),Z.data.currentConversationId=sb.createConversationId(),this.goto({name:`chat-page`,query:e,predefinedQuestionId:t,switchQuestionId:n})},async onNewConversation(){await this.abort();let e=Z.data.currentConversationId;if(Z.data.currentConversationId=void 0,Z.data.currentReferencesAsideId=void 0,Z.data.history=ob(Z.data.chatConfig.messageAdditions.init),Z.data.predefinedQuestionId=void 0,Z.data.switchQuestionId=void 0,Z.data.selectedTopic=void 0,Z.data.chatConfig.addQueryToUrlParams){let e=new URLSearchParams(window.location.search);e.delete(`q`),e.delete(`id`),e.delete(`sid`),history.pushState(null,``,`?${e.toString()}${window.location.hash}`)}this.goto({name:`start-page`}),e&&sb.userAction(`newDiscussion`,{conversationId:e,lang:Z.data.language}).catch(e=>{console.error(`Failed to notify backend of new discussion:`,e)})},async onChangeTopic(){let e=Z.data.chatConfig.selectedTopicResetPredefinedQuestionId;if(!e){console.warn("No selectedTopicResetPredefinedQuestionId available to reset the selected topic. Set it in the `Config DB` in the backend, in a `generalConfig` default set.");return}await this.abort(),Z.data.selectedTopic=void 0,Z.data.predefinedQuestionId=e,Z.data.switchQuestionId=void 0,Z.data.chatInputValue=``,this.onSubmit(!0,void 0,!0)},showSuccessToast(e){kv.success(Z.t[e],{unstyled:!0,duration:3e3,classes:{toast:`toast`}})},showErrorToast(e){kv.error(Z.errorTranslations[e],{unstyled:!0,duration:3e3,classes:{toast:`toast`}})},async submitFeedback(e){try{let t=Z.data.conversationFeedbackId||Z.data.lastChatResponseId;if(!t)throw new Zy(`Tried to give feedback with no id.`);let n=Z.data.history.find(e=>e.type===`bot`&&e.id===t);await sb.feedback(t,n?.question??``,e),setTimeout(()=>{this.showSuccessToast(`thankYouForFeedback`)},500)}catch(e){console.error(`Feedback failed:`,e),this.showErrorToast(`feedback-failed`)}},toggleReferencesAside(e){Z.data.currentReferencesAsideId===e?this.closeReferencesAside():this.openReferencesAside(e)},openReferencesAside(e){Z.data.currentReferencesAsideId=e,this.setOpenOverlay(!0)},closeReferencesAside(){Z.data.currentReferencesAsideId=void 0,Z.data.wasReferencesAsideClosed=!0,this.setOpenOverlay(!1)},setAsideMobile(e){Z.data.isAsideMobile=e},openFlyout(){Z.data.flyoutIsOpen=!0},closeFlyout(){Z.data.flyoutIsOpen=!1},openConversationFeedback(){Z.data.conversationFeedbackIsOpen=!0,this.setOpenOverlay(!0)},openMessageFeedback(e){Z.data.conversationFeedbackId=e},closeFeedback(){Z.data.conversationFeedbackIsOpen=!1,Z.data.conversationFeedbackId=void 0,this.setOpenOverlay(!1)},openAnswerForm(e){Z.data.answerFormMessageId=e,this.setOpenOverlay(!0)},closeAnswerForm(){Z.data.answerFormMessageId=void 0,this.setOpenOverlay(!1)},async submitAnswerForm(e){try{let t=Z.data.chatConfig.answerForm,n=Z.data.answerFormMessageId;if(!t)throw new Zy(`Tried to submit the answer form with no answerForm config.`);if(!n)throw new Zy(`Tried to submit the answer form with no message id.`);let r=Z.data.history.findIndex(e=>e.type===`bot`&&e.id===n),i=r===-1?void 0:Z.data.history[r],a=Z.data.history.slice(0,r===-1?void 0:r).findLast(e=>e.type===`user`)?.message,o=i?.question||a||(i?.type===`bot`?i.retrievalQuestion??``:``);await sb.submitAnswerForm({receiverEmail:t.receiverEmail,fields:t.fields.map(t=>({name:t.name,value:e[t.name]??``})),question:o,answer:i?.type===`bot`?i.message.text:``,requestId:n,lang:Z.data.language}),setTimeout(()=>{this.showSuccessToast(`answerFormThankYou`)},500)}catch(e){console.error(`Answer form submission failed:`,e),this.showErrorToast(`answer-form-failed`)}},setOpenOverlay(e){Z.data.hasOpenedOverlays=e},setAriaLiveStatusMessage(e){Z.data.ariaLiveStatusMessage=e,clearTimeout(Z.data.ariaLiveStatusMessageClearingTimeout),Z.data.ariaLiveStatusMessageClearingTimeout=setTimeout(()=>{Z.data.ariaLiveStatusMessage=``},Z.ariaLiveMessagesClearingTimeoutDuration)},closePopup(){window.location.hash=``},checkForOpenedPopup(){let e=window.location.hash.slice(1),t=Z.t.popups?.find(t=>t.hash===e);t?Z.data.openedPopup=t:Z.data.openedPopup=void 0},async thumbs(e,t){try{let n=Z.data.history.find(t=>t.type===`bot`&&t.id===e);t===`up`?await sb.thumbsUp(e,n?.question??``):await sb.thumbsDown(e,n?.question??``),this.showSuccessToast(`thankYouForFeedback`)}catch(e){console.error(`Feedback failed:`,e),this.showErrorToast(`feedback-failed`)}},async onLanguageChange(e){if(Z.data.language=V_(e,Z.data.chatConfig.supportedLanguages),U_(Z.data.language,Z.targets.mainElement),Z.data.predefinedQuestions=await this.getPredefinedQuestions(Z.data.language),this.setAriaLiveStatusMessage(Z.t.ariaLanguageChanged),Z.data.chatConfig.reflectLanguageInPath){let e=new URL(window.location.href);e.pathname=`/${Z.data.language}`,window.history.replaceState({},``,e.toString())}},async acceptTerms(){Z.data.termsAccepted=!0;try{s_.setItem(`liipgpt:termsAccepted`,`true`)}catch(e){console.warn(`Failed to save terms acceptance to storage:`,e)}this.closePopup(),await qr(),this.goto($y(Z.data.chatConfig.forceConsent??!1,!0,Z.data.chatConfig.forceChatPage??!1,Qy(Z.data.props.autofirePredefinedQuestionId,Z.data.predefinedQuestions),Z.data.props.question))},updateChatInput(e){Z.data.chatInputValue=e}}),db=(e,t)=>{let n=window.LIIPGPT_LISTENERS?.elements?.[t];if(!n)return;let r=Object.entries(n).filter(([e,t])=>typeof t==`function`&&![`init`,`destroy`].includes(e));$n(()=>(n.init?.(e),r.forEach(([t,n])=>{e.addEventListener(t,n)}),()=>{r.forEach(([t,n])=>{e.removeEventListener(t,n)}),n.destroy?.(e)}))},fb=(e,t)=>{t&&ub.setTarget(t,e)},pb=R(`<div role="status" class="sr-only"> </div>`);function mb(e,t){D(t,!1),co();var n=pb(),r=N(n,!0);E(n),I(()=>V(r,Z.data.ariaLiveStatusMessage)),B(e,n),O()}q(mb,{},[],[],{mode:`open`});var hb=R(`<div aria-hidden="true"></div>`);function gb(e,t){D(t,!0);let n=K(t,`name`,7),r=K(t,`class`,7);var i={get name(){return n()},set name(e){n(e),k()},get class(){return r()},set class(e){r(e),k()}},a=hb();return na(a,()=>Z.theme.svgs[n()],!0),E(a),I(()=>Da(a,1,`svg svg--${n()??``} ${r()??``}`)),B(e,a),O(i)}q(gb,{name:{},class:{}},[],[],{mode:`open`});var _b=`data-disable-tooltip-on-focus`;function vb(e,t){let n=null,r;function i(){t.text&&(n||(n=document.createElement(`span`),n.ariaHidden=`true`,n.textContent=t.text,n.className=`tooltip tooltip-${t.position||`top`} tooltip-hidden`,e.appendChild(n),n.getBoundingClientRect()),n.classList.remove(`tooltip-hidden`),a())}function a(){if(!n)return;let r=e.getBoundingClientRect(),i=n.getBoundingClientRect(),a,o;switch(t.position){case`bottom`:a=r.height+5,o=r.width/2-i.width/2;break;case`bottom-right`:a=r.height+5,o=r.width-i.width;break;case`bottom-left`:a=r.height+5,o=0;break;case`left`:a=r.height/2-i.height/2,o=-i.width-5;break;case`right`:a=r.height/2-i.height/2,o=r.width+5;break;default:a=-i.height-5,o=r.width/2-i.width/2;break}let s=r.left+o,c=s+i.width,l=window.innerWidth;if(c>l){let e=c-l;if(o-=e+10,t.position===`top`||t.position===`bottom`){let t=e+10;n.style.setProperty(`--tooltip-arrow-offset`,`${t}px`)}}if(s<0&&(o-=s-10,t.position===`top`||t.position===`bottom`)){let e=s-10;n.style.setProperty(`--tooltip-arrow-offset`,`${e}px`)}n.style.top=`${a}px`,n.style.left=`${o}px`}function o(){r=window.setTimeout(()=>{i()},t.delay||200)}function s(e){let t=e.target;t&&!t.hasAttribute(`data-disable-tooltip-on-focus`)?o():t.removeAttribute(_b)}function c(){clearTimeout(r),n&&(n.classList.add(`tooltip-hidden`),n.addEventListener(`transitionend`,()=>{n?.remove(),n=null},{once:!0}))}return e.classList.add(`tooltip-container`),e.setAttribute(`tabindex`,`0`),e.addEventListener(`mouseenter`,o),e.addEventListener(`focus`,s),e.addEventListener(`mouseleave`,c),e.addEventListener(`blur`,c),e.addEventListener(`click`,c),{update(e){t=e},destroy(){c(),e.classList.remove(`tooltip-container`),e.removeEventListener(`mouseenter`,o),e.removeEventListener(`focus`,s),e.removeEventListener(`mouseleave`,c),e.removeEventListener(`blur`,c),e.removeEventListener(`click`,c)}}}var yb=R(`<button><span class="sr-only"> </span> <span><!></span></button>`);function bb(e,t){D(t,!0);let n=K(t,`class`,7),r=K(t,`tooltip`,7),i=K(t,`label`,7),a=K(t,`onclick`,7),o=K(t,`icon`,7),s=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`class`,`tooltip`,`label`,`onclick`,`icon`]);var c={get class(){return n()},set class(e){n(e),k()},get tooltip(){return r()},set tooltip(e){r(e),k()},get label(){return i()},set label(e){i(e),k()},get onclick(){return a()},set onclick(e){a(e),k()},get icon(){return o()},set icon(e){o(e),k()}},l=yb();Ja(l,()=>({onclick:a(),...s}));var u=N(l),d=N(u,!0);E(u);var f=F(u,2);return gb(N(f),{get name(){return o()}}),E(f),E(l),_a(l,(e,t)=>vb?.(e,t),()=>({text:r(),position:`top`,delay:300})),I(()=>{V(d,i()),Da(f,1,xa(n()))}),B(e,l),O(c)}q(bb,{class:{},tooltip:{},label:{},onclick:{},icon:{}},[],[],{mode:`open`});var xb=R(`<p class="jsonld-card__description"> </p>`),Sb=R(`<article class="jsonld-card jsonld-card--cta"><header class="jsonld-card__header"><h3 class="jsonld-card__title"> </h3></header> <!> <a class="jsonld-card__cta btn" target="_blank" rel="noopener noreferrer"><span> </span> <!></a></article>`);function Cb(e,t){D(t,!0);let n=K(t,`data`,7);var r={get data(){return n()},set data(e){n(e),k()}},i=Sb(),a=N(i),o=N(a),s=N(o,!0);E(o),E(a);var c=F(a,2),l=e=>{var t=xb(),r=N(t,!0);E(t),I(()=>V(r,n().description)),B(e,t)};U(c,e=>{n().description&&e(l)});var u=F(c,2),d=N(u),f=N(d,!0);return E(d),gb(F(d,2),{name:`externalLink`,class:`jsonld-card__cta-icon`}),E(u),E(i),I(()=>{G(i,`aria-label`,`${Z.t.ariaJsonLdCtaCard??``}: ${n().title??``}`),V(s,n().title),G(u,`href`,n().url),V(f,n().label??Z.t.jsonLdCtaLabel)}),B(e,i),O(r)}q(Cb,{data:{}},[],[],{mode:`open`});var wb=R(`<span class="jsonld-card__event-time"> </span>`),Tb=R(`<dt class="jsonld-card__meta-label"> </dt> <dd class="jsonld-card__meta-value"><time class="jsonld-card__event-date"><span> </span> <!></time></dd>`,1),Eb=R(`<dt class="jsonld-card__meta-label"> </dt> <dd class="jsonld-card__meta-value"> </dd>`,1),Db=R(`<dt class="jsonld-card__meta-label"> </dt> <dd class="jsonld-card__meta-value"> </dd>`,1),Ob=R(`<article class="jsonld-card jsonld-card--event"><header class="jsonld-card__header"><h3 class="jsonld-card__title"> </h3></header> <dl class="jsonld-card__meta"><!> <!> <!></dl> <a class="jsonld-card__cta btn" target="_blank" rel="noopener noreferrer"><span> </span> <!></a></article>`);function kb(e,t){D(t,!0);let n=K(t,`data`,7),r=A(()=>{if(!n().date)return;let e=new Date(n().date);if(Number.isNaN(e.getTime()))return{day:n().date,time:void 0};let t=Z.data.language||`de`;try{return{day:e.toLocaleDateString(t,{weekday:`long`,day:`numeric`,month:`long`,year:`numeric`}),time:e.getHours()!==0||e.getMinutes()!==0?e.toLocaleTimeString(t,{hour:`2-digit`,minute:`2-digit`}):void 0}}catch{return{day:e.toLocaleString(),time:void 0}}});var i={get data(){return n()},set data(e){n(e),k()}},a=Ob(),o=N(a),s=N(o),c=N(s,!0);E(s),E(o);var l=F(o,2),u=N(l),d=e=>{var t=Tb(),i=P(t),a=N(i,!0);E(i);var o=F(i,2),s=N(o),c=N(s),l=N(c,!0);E(c);var u=F(c,2),d=e=>{var t=wb(),n=N(t,!0);E(t),I(()=>V(n,L(r).time)),B(e,t)};U(u,e=>{L(r).time&&e(d)}),E(s),E(o),I(()=>{V(a,Z.t.jsonLdEventDate),G(s,`datetime`,n().date),V(l,L(r).day)}),B(e,t)};U(u,e=>{L(r)&&e(d)});var f=F(u,2),p=e=>{var t=Eb(),r=P(t),i=N(r,!0);E(r);var a=F(r,2),o=N(a,!0);E(a),I(()=>{V(i,Z.t.jsonLdEventLocation),V(o,n().location)}),B(e,t)};U(f,e=>{n().location&&e(p)});var m=F(f,2),h=e=>{var t=Db(),r=P(t),i=N(r,!0);E(r);var a=F(r,2),o=N(a,!0);E(a),I(()=>{V(i,Z.t.jsonLdEventDescription),V(o,n().description)}),B(e,t)};U(m,e=>{n().description&&e(h)}),E(l);var g=F(l,2),_=N(g),v=N(_,!0);return E(_),gb(F(_,2),{name:`externalLink`,class:`jsonld-card__cta-icon`}),E(g),E(a),I(()=>{G(a,`aria-label`,`${Z.t.ariaJsonLdEventCard??``}: ${n().title??``}`),V(c,n().title),G(g,`href`,n().ctaUrl),V(v,n().ctaLabel??Z.t.jsonLdEventCtaLabel)}),B(e,a),O(i)}q(kb,{data:{}},[],[],{mode:`open`});var Ab=R(`<p class="jsonld-card__description"> </p>`),jb=R(`<div class="jsonld-card__map-frame"><div class="jsonld-card__map-canvas"></div></div>`),Mb=R(`<p class="jsonld-card__address"> </p>`),Nb=R(`<a class="jsonld-card__contact btn btn--secondary"><!> <span> </span></a>`),Pb=R(`<a class="jsonld-card__contact btn btn--secondary"><!> <span> </span></a>`),Fb=R(`<article class="jsonld-card jsonld-card--map"><header class="jsonld-card__header"><h3 class="jsonld-card__title"> </h3></header> <!> <!> <!> <div class="jsonld-card__actions"><!> <!> <a class="jsonld-card__cta btn" target="_blank" rel="noopener noreferrer"><span> </span> <!></a></div></article>`);function Ib(e,t){D(t,!0);let n=`5.24.0`,r=[`https://cdn.jsdelivr.net/npm/maplibre-gl@${n}/+esm`,`https://unpkg.com/maplibre-gl@${n}/dist/maplibre-gl.js?module`],i=`https://cdn.jsdelivr.net/npm/maplibre-gl@${n}/dist/maplibre-gl.css`,a=K(t,`data`,7),o=j(void 0),s=A(()=>{if(a().directionsUrl)return a().directionsUrl;if(!a().coords)return a().fallbackUrl;let e=String(Z.theme.components.messageJsonLdMap?.custom?.directionsProvider||``)||`google`,{lat:t,lng:n}=a().coords;return e===`osm`?`https://www.openstreetmap.org/directions?to=${t},${n}`:`https://www.google.com/maps/dir/?api=1&destination=${t},${n}`}),c=e=>new Promise(t=>{let n=`jsonld-map-maplibre-style`,r=e.getRootNode(),a=r instanceof ShadowRoot?r:document.head,o=a.querySelector(`#${n}`);if(o instanceof HTMLLinkElement&&o.sheet){t();return}if(o){o.addEventListener(`load`,()=>t(),{once:!0});return}let s=document.createElement(`link`);s.id=n,s.rel=`stylesheet`,s.href=i,s.onload=()=>t(),s.onerror=()=>t(),a.appendChild(s)}),l=e=>{let t=e;return t.Map?t:t.default??t},u=async e=>{await c(e);let t;for(let e of r)try{return l(await import(e))}catch(e){t=e}throw t};Ii(()=>{let e=a().coords;if(!e)return;let t=String(Z.theme.components.messageJsonLdMap?.custom?.tileUrl||``)||`https://tile.openstreetmap.org/{z}/{x}/{y}.png`,n=String(Z.theme.components.messageJsonLdMap?.custom?.markerColor||``)||`#3fb1ce`,r=String(Z.theme.components.messageJsonLdMap?.custom?.mapStyleUrl||``),i,s,c,l,d=0,f=0,p=!1;return(async()=>{await qr();let m=L(o);if(!m||p)return;let h=await u(m);if(p)return;let g=(e=>{if(e.trim().startsWith(`{`))try{return JSON.parse(e)}catch{return null}return e||null})(r)??{version:8,sources:{"osm-tiles":{type:`raster`,tiles:[t],tileSize:256}},layers:[{id:`osm-tiles`,type:`raster`,source:`osm-tiles`,minzoom:0,maxzoom:19}]};if(i=new h.Map({container:m,style:g,center:[e.lng,e.lat],zoom:a().zoom,attributionControl:!1,scrollZoom:!1,touchZoomRotate:!0,touchPitch:!1,doubleClickZoom:!0}),p){i.remove();return}i.once(`style.load`,()=>{let t=()=>{if(p||!i)return;i.resize();let r=i.getCanvas();r.width>0&&r.height>0?s=new h.Marker({color:n}).setLngLat([e.lng,e.lat]).addTo(i):requestAnimationFrame(t)};t()}),l=new ResizeObserver(e=>{let t=e[0];if(!t||!i)return;let{width:n,height:r}=t.contentRect;n===d&&r===f||(d=n,f=r,cancelAnimationFrame(c??0),c=requestAnimationFrame(()=>i?.resize()))}),l.observe(m)})(),()=>{p=!0,cancelAnimationFrame(c??0),l?.disconnect(),s?.remove(),i?.remove()}});var d={get data(){return a()},set data(e){a(e),k()}},f=Fb(),p=N(f),m=N(p),h=N(m,!0);E(m),E(p);var g=F(p,2),_=e=>{var t=Ab(),n=N(t,!0);E(t),I(()=>V(n,a().description)),B(e,t)};U(g,e=>{a().description&&e(_)});var v=F(g,2),y=e=>{var t=jb(),n=N(t);so(n,e=>M(o,e),()=>L(o)),E(t),I(()=>G(n,`aria-label`,`${Z.t.ariaJsonLdMapCanvas??``}: ${a().title??``}`)),B(e,t)};U(v,e=>{a().coords&&e(y)});var b=F(v,2),x=e=>{var t=Mb(),n=N(t,!0);E(t),I(()=>V(n,a().address)),B(e,t)};U(b,e=>{a().address&&e(x)});var S=F(b,2),C=N(S),ee=e=>{var t=Nb(),n=N(t);gb(n,{name:`phone`,class:`jsonld-card__cta-icon`});var r=F(n,2),i=N(r,!0);E(r),E(t),I(()=>{G(t,`href`,`tel:${a().phone??``}`),V(i,a().phone)}),B(e,t)};U(C,e=>{a().phone&&e(ee)});var te=F(C,2),ne=e=>{var t=Pb(),n=N(t);gb(n,{name:`email`,class:`jsonld-card__cta-icon`});var r=F(n,2),i=N(r,!0);E(r),E(t),I(()=>{G(t,`href`,`mailto:${a().email??``}`),V(i,a().email)}),B(e,t)};U(te,e=>{a().email&&e(ne)});var re=F(te,2),w=N(re),ie=N(w,!0);return E(w),gb(F(w,2),{name:`externalLink`,class:`jsonld-card__cta-icon`}),E(re),E(S),E(f),I(()=>{G(f,`aria-label`,`${Z.t.ariaJsonLdMapCard??``}: ${a().title??``}`),V(h,a().title),G(re,`href`,L(s)),V(ie,Z.t.jsonLdMapOpenMap)}),B(e,f),O(d)}q(Ib,{data:{}},[],[],{mode:`open`});var Lb=(e,t)=>{let n=e[t];return typeof n==`string`&&n.length>0?n:void 0},Rb=(e,t)=>{let n=e[t];return typeof n==`number`&&Number.isFinite(n)?n:void 0},zb=e=>e.display.card.title||e.display.listItem.title,Bb=e=>{let t=e.metadata;if(t.jsonLdBlock===`event-card`)return{block:`event-card`,data:{title:zb(e),description:e.display.card.description,date:Lb(t,`jsonLdEventStartDate`),location:Lb(t,`jsonLdEventLocation`),ctaLabel:Lb(t,`jsonLdEventCtaLabel`),ctaUrl:Lb(t,`jsonLdEventCtaUrl`)??e.url}};if(t.jsonLdBlock===`map`){let n=Rb(t,`jsonLdMapLat`),r=Rb(t,`jsonLdMapLng`);return{block:`map`,data:{title:Lb(t,`jsonLdMapLabel`)??zb(e),description:Lb(t,`jsonLdMapDescription`)??e.display.card.description,address:Lb(t,`jsonLdMapAddress`),url:Lb(t,`jsonLdMapUrl`),phone:Lb(t,`jsonLdMapPhone`),email:Lb(t,`jsonLdMapEmail`),coords:n!==void 0&&r!==void 0?{lat:n,lng:r}:void 0,zoom:Rb(t,`jsonLdMapZoom`)??15,fallbackUrl:e.url,directionsUrl:Lb(t,`jsonLdMapDirectionsUrl`)}}}if(t.jsonLdBlock===`cta`)return{block:`cta`,data:{title:zb(e),description:e.display.card.description,label:Lb(t,`jsonLdCtaLabel`),url:Lb(t,`jsonLdCtaUrl`)??e.url}}},Vb=R(`<div role="listitem"><!></div>`),Hb=R(`<div class="jsonld-references" role="list"></div>`);function Ub(e,t){D(t,!0);let n=K(t,`references`,7),r=K(t,`ready`,7,!1),i=A(()=>n().flatMap(e=>{let t=Bb(e);return t?[{key:e.url+e.referenceIndex.all,display:t}]:[]})),a=A(()=>Z.theme?.components?.messageOptions?.custom),o=A(()=>Number(L(a)?.transitionDuration)||300),s=A(()=>Number(L(a)?.transitionDelay)||0),c=A(()=>Number(L(a)?.transitionY)||30);var l={get references(){return n()},set references(e){n(e),k()},get ready(){return r()},set ready(e=!1){r(e),k()}},u=z(),d=P(u),f=e=>{var t=Hb();Xi(t,23,()=>L(i),({key:e,display:t})=>e,(e,t,n)=>{let i=()=>L(t).display;var a=Vb();let l,u;var d=N(a),f=e=>{kb(e,{get data(){return i().data}})},p=e=>{Ib(e,{get data(){return i().data}})},m=e=>{Cb(e,{get data(){return i().data}})};U(d,e=>{i().block===`event-card`?e(f):i().block===`map`?e(p,1):i().block===`cta`&&e(m,2)}),E(a),I(()=>{l=Da(a,1,`jsonld-references__item`,null,l,{"jsonld-references__item--preloading":!r()}),u=ka(a,``,u,{"--jsonld-item-duration":`${L(o)??``}ms`,"--jsonld-item-delay":`${L(s)+L(n)*L(o)}ms`,"--jsonld-item-y":`${L(c)??``}px`})}),B(e,a)}),E(t),B(e,t)};return U(d,e=>{L(i).length>0&&e(f)}),B(e,u),O(l)}q(Ub,{references:{},ready:{}},[],[],{mode:`open`});var Wb;function Gb(e,t,n,r,i){Wb&&cancelAnimationFrame(Wb);let a=e instanceof Window?r===`scrollTop`?window.scrollY:window.scrollX:e[r],o=performance.now();function s(c){let l=c-o,u=Math.min(l/n,1),d=i(u),f=a+(t-a)*d;e instanceof Window?r===`scrollTop`?window.scrollTo({top:f,behavior:`instant`}):window.scrollTo({left:f,behavior:`instant`}):e[r]=f,u<1?Wb=requestAnimationFrame(s):e.dispatchEvent(new CustomEvent(`scrollcomplete`))}Wb=requestAnimationFrame(s)}function Kb(e){return typeof e==`function`}function qb(e){return typeof e==`object`&&!!e}var Jb=[`string`,`number`,`bigint`,`boolean`];function Yb(e){return e==null||Jb.includes(typeof e)?!0:Array.isArray(e)?e.every(e=>Yb(e)):typeof e==`object`?Object.getPrototypeOf(e)===Object.prototype:!1}var Xb=Symbol(`box`),Zb=Symbol(`is-writable`);function Q(e,t){let n=A(e);return t?{[Xb]:!0,[Zb]:!0,get current(){return L(n)},set current(e){t(e)}}:{[Xb]:!0,get current(){return e()}}}function Qb(e){return qb(e)&&Xb in e}function $b(e){return Qb(e)&&Zb in e}function ex(e){return Qb(e)?e:Kb(e)?Q(e):rx(e)}function tx(e){return Object.entries(e).reduce((e,[t,n])=>Qb(n)?($b(n)?Object.defineProperty(e,t,{get(){return n.current},set(e){n.current=e}}):Object.defineProperty(e,t,{get(){return n.current}}),e):Object.assign(e,{[t]:n}),{})}function nx(e){return $b(e)?{[Xb]:!0,get current(){return e.current}}:e}function rx(e){let t=j(Dn(e));return{[Xb]:!0,[Zb]:!0,get current(){return L(t)},set current(e){M(t,e,!0)}}}function ix(e){let t=j(Dn(e));return{[Xb]:!0,[Zb]:!0,get current(){return L(t)},set current(e){M(t,e,!0)}}}ix.from=ex,ix.with=Q,ix.flatten=tx,ix.readonly=nx,ix.isBox=Qb,ix.isWritableBox=$b;function ax(...e){return function(t){for(let n of e)if(n){if(t.defaultPrevented)return;typeof n==`function`?n.call(this,t):n.current?.call(this,t)}}}var ox=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,sx=/\n/g,cx=/^\s*/,lx=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,ux=/^:\s*/,dx=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,fx=/^[;\s]*/,px=/^\s+|\s+$/g,mx=`
|
|
569
|
-
`,
|
|
570
|
-
`)}function
|
|
571
|
-
`,` `)}var
|
|
572
|
-
`,` `)),t.hidden===!1&&(t.hidden=void 0,delete t.hidden),t.disabled===!1&&(t.disabled=void 0,delete t.disabled),t}var Bx=Ix({position:`absolute`,width:`1px`,height:`1px`,padding:`0`,margin:`-1px`,overflow:`hidden`,clip:`rect(0, 0, 0, 0)`,whiteSpace:`nowrap`,borderWidth:`0`,transform:`translateX(-100%)`}),Vx=typeof window<`u`?window:void 0;typeof window<`u`&&window.document,typeof window<`u`&&window.navigator,typeof window<`u`&&window.location;function Hx(e){let t=e.activeElement;for(;t?.shadowRoot;){let e=t.shadowRoot.activeElement;if(e===t)break;t=e}return t}new class{#e;#t;constructor(e={}){let{window:t=Vx,document:n=t?.document}=e;t!==void 0&&(this.#e=n,this.#t=en(e=>{let n=ri(t,`focusin`,e),r=ri(t,`focusout`,e);return()=>{n(),r()}}))}get current(){return this.#t?.(),this.#e?Hx(this.#e):null}};function Ux(e){return typeof e==`function`}var Wx=class{#e;#t;constructor(e){this.#e=e,this.#t=Symbol(e)}get key(){return this.#t}exists(){return pt(this.#t)}get(){let e=dt(this.#t);if(e===void 0)throw Error(`Context "${this.#e}" not found`);return e}getOr(e){let t=dt(this.#t);return t===void 0?e:t}set(e){return ft(this.#t,e)}};function Gx(e,t){switch(e){case`post`:$n(t);break;case`pre`:tr(t);break}}function Kx(e,t,n,r={}){let{lazy:i=!1}=r,a=!i,o=Array.isArray(e)?[]:void 0;Gx(t,()=>{let t=Array.isArray(e)?e.map(e=>e()):e();if(!a){a=!0,o=t;return}let r=Xr(()=>n(t,o));return o=t,r})}function qx(e,t,n){let r=nr(()=>{let i=!1;Kx(e,t,(e,t)=>{if(i){r();return}let a=n(e,t);return i=!0,a},{lazy:!0})});$n(()=>r)}function Jx(e,t,n){Kx(e,`post`,t,n)}function Yx(e,t,n){Kx(e,`pre`,t,n)}Jx.pre=Yx;function Xx(e,t){qx(e,`post`,t)}function Zx(e,t){qx(e,`pre`,t)}Xx.pre=Zx;function Qx(e){return Ux(e)?e():e}var $x=class{#e={width:0,height:0};#t=!1;#n;#r;#i;#a=A(()=>(L(this.#s)?.(),this.getSize().width));#o=A(()=>(L(this.#s)?.(),this.getSize().height));#s=A(()=>{let e=Qx(this.#r);if(e)return en(t=>{if(!this.#i)return;let n=new this.#i.ResizeObserver(e=>{this.#t=!0;for(let t of e){let e=this.#n.box===`content-box`?t.contentBoxSize:t.borderBoxSize,n=Array.isArray(e)?e:[e];this.#e.width=n.reduce((e,t)=>Math.max(e,t.inlineSize),0),this.#e.height=n.reduce((e,t)=>Math.max(e,t.blockSize),0)}t()});return n.observe(e),()=>{this.#t=!1,n.disconnect()}})});constructor(e,t={box:`border-box`}){this.#i=t.window??Vx,this.#n=t,this.#r=e,this.#e={width:0,height:0}}calculateSize(){let e=Qx(this.#r);if(!e||!this.#i)return;let t=e.offsetWidth,n=e.offsetHeight;if(this.#n.box===`border-box`)return{width:t,height:n};let r=this.#i.getComputedStyle(e),i=parseFloat(r.paddingLeft)+parseFloat(r.paddingRight),a=parseFloat(r.paddingTop)+parseFloat(r.paddingBottom),o=parseFloat(r.borderLeftWidth)+parseFloat(r.borderRightWidth),s=parseFloat(r.borderTopWidth)+parseFloat(r.borderBottomWidth);return{width:t-i-o,height:n-a-s}}getSize(){return this.#t?this.#e:this.calculateSize()??this.#e}get current(){return L(this.#s)?.(),this.getSize()}get width(){return L(this.#a)}get height(){return L(this.#o)}},eS=class{#e=()=>void 0;#t=A(()=>this.#e());constructor(e,t){let n;t!==void 0&&(n=t),this.#e=()=>{try{return n}finally{n=e()}}}get current(){return L(this.#t)}};function tS(e,t){let n,r=null;return(...i)=>new Promise(a=>{r&&r(void 0),r=a,clearTimeout(n),n=setTimeout(async()=>{let t=await e(...i);r&&=(r(t),null)},t)})}function nS(e,t){let n=0,r=null;return(...i)=>{let a=Date.now();return n&&a-n<t?r??Promise.resolve(void 0):(n=a,r=e(...i),r)}}function rS(e,t,n={},r){let{lazy:i=!1,once:a=!1,initialValue:o,debounce:s,throttle:c}=n,l=j(Dn(o)),u=j(!1),d=j(void 0),f=j(Dn([])),p=()=>{L(f).forEach(e=>e()),M(f,[],!0)},m=e=>{M(f,[...L(f),e],!0)},h=async(e,n,r=!1)=>{try{M(u,!0),M(d,void 0),p();let i=new AbortController;m(()=>i.abort());let a=await t(e,n,{data:L(l),refetching:r,onCleanup:m,signal:i.signal});return M(l,a,!0),a}catch(e){e instanceof DOMException&&e.name===`AbortError`||M(d,e,!0);return}finally{M(u,!1)}},g=s?tS(h,s):c?nS(h,c):h,_=Array.isArray(e)?e:[e],v;return r((t,n)=>{a&&v||(v=t,g(Array.isArray(e)?t:t[0],Array.isArray(e)?n:n?.[0]))},{lazy:i}),{get current(){return L(l)},get loading(){return L(u)},get error(){return L(d)},mutate:e=>{M(l,e,!0)},refetch:t=>{let n=_.map(e=>e());return g(Array.isArray(e)?n:n[0],Array.isArray(e)?n:n[0],t??!0)}}}function iS(e,t,n){return rS(e,t,n,(t,n)=>{let r=Array.isArray(e)?e:[e];Jx(()=>r.map(e=>e()),(e,n)=>{t(e,n??[])},n)})}function aS(e,t,n){return rS(e,t,n,(t,n)=>{let r=Array.isArray(e)?e:[e];Jx.pre(()=>r.map(e=>e()),(e,n)=>{t(e,n??[])},n)})}iS.pre=aS;function oS(e){$n(()=>()=>{e()})}function sS(e){$n(()=>Xr(()=>e()))}function cS(e,t){return setTimeout(t,e)}function lS(e){qr().then(e)}var uS=1,dS=9,fS=11;function pS(e){return qb(e)&&e.nodeType===uS&&typeof e.nodeName==`string`}function mS(e){return qb(e)&&e.nodeType===dS}function hS(e){return qb(e)&&e.constructor?.name===`VisualViewport`}function gS(e){return qb(e)&&e.nodeType!==void 0}function _S(e){return gS(e)&&e.nodeType===fS&&`host`in e}function vS(e,t){if(!e||!t||!pS(e)||!pS(t))return!1;let n=t.getRootNode?.();if(e===t||e.contains(t))return!0;if(n&&_S(n)){let n=t;for(;n;){if(e===n)return!0;n=n.parentNode||n.host}}return!1}function yS(e){return mS(e)?e:hS(e)?e.document:e?.ownerDocument??document}function bS(e){return _S(e)?bS(e.host):mS(e)?e.defaultView??window:pS(e)?e.ownerDocument?.defaultView??window:window}function xS(e){let t=e.activeElement;for(;t?.shadowRoot;){let e=t.shadowRoot.activeElement;if(e===t)break;t=e}return t}var SS=class{element;#e=A(()=>this.element.current?this.element.current.getRootNode()??document:document);get root(){return L(this.#e)}set root(e){M(this.#e,e)}constructor(e){typeof e==`function`?this.element=Q(e):this.element=e}getDocument=()=>yS(this.root);getWindow=()=>this.getDocument().defaultView??window;getActiveElement=()=>xS(this.root);isActiveElement=e=>e===this.getActiveElement();getElementById(e){return this.root.getElementById(e)}querySelector=e=>this.root?this.root.querySelector(e):null;querySelectorAll=e=>this.root?this.root.querySelectorAll(e):[];setTimeout=(e,t)=>this.getWindow().setTimeout(e,t);clearTimeout=e=>this.getWindow().clearTimeout(e)};function CS(e,t){return{[zi()]:n=>Qb(e)?(e.current=n,Xr(()=>t?.(n)),()=>{`isConnected`in n&&n.isConnected||(e.current=null,t?.(null))}):(e(n),Xr(()=>t?.(n)),()=>{`isConnected`in n&&n.isConnected||(e(null),t?.(null))})}}function wS(e){return e?`true`:`false`}function TS(e){return e?`true`:void 0}function ES(e){return e?``:void 0}function DS(e){return e?!0:void 0}function OS(e){return e?`open`:`closed`}function kS(e,t){return t?`mixed`:e?`true`:`false`}var AS=class{#e;#t;attrs;constructor(e){this.#e=e.getVariant?e.getVariant():null,this.#t=this.#e?`data-${this.#e}-`:`data-${e.component}-`,this.getAttr=this.getAttr.bind(this),this.selector=this.selector.bind(this),this.attrs=Object.fromEntries(e.parts.map(e=>[e,this.getAttr(e)]))}getAttr(e,t){return t?`data-${t}-${e}`:`${this.#t}${e}`}selector(e,t){return`[${this.getAttr(e,t)}]`}};function jS(e){let t=new AS(e);return{...t.attrs,selector:t.selector,getAttr:t.getAttr}}var MS=`ArrowDown`,NS=`ArrowLeft`,PS=`ArrowRight`,FS=`ArrowUp`,IS=`CapsLock`,LS=`Control`,RS=`Enter`,zS=`Escape`,BS=`Home`,VS=`Meta`,HS=`PageDown`,US=`PageUp`,WS=`Shift`;function GS(e){return window.getComputedStyle(e).getPropertyValue(`direction`)}var KS=[MS,US,BS],qS=[FS,HS,`End`];[...KS,...qS];function JS(e=`ltr`,t=`horizontal`){return{horizontal:e===`rtl`?NS:PS,vertical:MS}[t]}function YS(e=`ltr`,t=`horizontal`){return{horizontal:e===`rtl`?PS:NS,vertical:FS}[t]}function XS(e=`ltr`,t=`horizontal`){return[`ltr`,`rtl`].includes(e)||(e=`ltr`),[`horizontal`,`vertical`].includes(t)||(t=`horizontal`),{nextKey:JS(e,t),prevKey:YS(e,t)}}var ZS=typeof document<`u`,QS=$S();function $S(){return ZS&&window?.navigator?.userAgent&&(/iP(ad|hone|od)/.test(window.navigator.userAgent)||window?.navigator?.maxTouchPoints>2&&/iPad|Macintosh/.test(window?.navigator.userAgent))}function eC(e){return e instanceof HTMLElement}function tC(e){return e instanceof Element}function nC(e){return e instanceof Element||e instanceof SVGElement}function rC(e){return e.pointerType===`touch`}function iC(e){return e!==null}function aC(e){return e instanceof HTMLInputElement&&`select`in e}var oC=class{#e;#t=ix(null);constructor(e){this.#e=e}getCandidateNodes(){return this.#e.rootNode.current?this.#e.candidateSelector?Array.from(this.#e.rootNode.current.querySelectorAll(this.#e.candidateSelector)):this.#e.candidateAttr?Array.from(this.#e.rootNode.current.querySelectorAll(`[${this.#e.candidateAttr}]:not([data-disabled])`)):[]:[]}focusFirstCandidate(){let e=this.getCandidateNodes();e.length&&e[0]?.focus()}handleKeydown(e,t,n=!1){let r=this.#e.rootNode.current;if(!r||!e)return;let i=this.getCandidateNodes();if(!i.length)return;let a=i.indexOf(e),{nextKey:o,prevKey:s}=XS(GS(r),this.#e.orientation.current),c=this.#e.loop.current,l={[o]:a+1,[s]:a-1,[BS]:0,End:i.length-1};if(n){let e=o===`ArrowDown`?PS:MS,t=s===`ArrowUp`?NS:FS;l[e]=a+1,l[t]=a-1}let u=l[t.key];if(u===void 0)return;t.preventDefault(),u<0&&c?u=i.length-1:u===i.length&&c&&(u=0);let d=i[u];if(d)return d.focus(),this.#t.current=d.id,this.#e.onCandidateFocus?.(d),d}getTabIndex(e){let t=this.getCandidateNodes(),n=this.#t.current!==null;return e&&!n&&t[0]===e?(this.#t.current=e.id,0):e?.id===this.#t.current?0:-1}setCurrentTabStopId(e){this.#t.current=e}focusCurrentTabStop(){let e=this.#t.current;if(!e)return;let t=this.#e.rootNode.current?.querySelector(`#${e}`);!t||!eC(t)||t.focus()}},sC=class{#e;#t=null;constructor(e){this.#e=e,oS(()=>this.#n())}#n(){this.#t&&=(window.cancelAnimationFrame(this.#t),null)}run(e){this.#n();let t=this.#e.ref.current;if(t){if(typeof t.getAnimations!=`function`){this.#r(e);return}this.#t=window.requestAnimationFrame(()=>{let n=t.getAnimations();if(n.length===0){this.#r(e);return}Promise.allSettled(n.map(e=>e.finished)).then(()=>{this.#r(e)})})}}#r(e){let t=()=>{e()};this.#e.afterTick?lS(t):t()}},cC=class{#e;#t;#n;#r=j(!1);constructor(e){this.#e=e,M(this.#r,e.open.current,!0),this.#t=e.enabled??!0,this.#n=new sC({ref:this.#e.ref,afterTick:this.#e.open}),Jx(()=>this.#e.open.current,e=>{e&&M(this.#r,!0),this.#t&&this.#n.run(()=>{e===this.#e.open.current&&(this.#e.open.current||M(this.#r,!1),this.#e.onComplete?.())})})}get shouldRender(){return L(this.#r)}};function $(){}function lC(e,t){return t===void 0?`bits-${e}`:`bits-${e}-${t}`}var uC=jS({component:`dialog`,parts:[`content`,`trigger`,`overlay`,`title`,`description`,`close`,`cancel`,`action`]}),dC=new Wx(`Dialog.Root | AlertDialog.Root`),fC=class e{static create(t){let n=dC.getOr(null);return dC.set(new e(t,n))}opts;#e=j(null);get triggerNode(){return L(this.#e)}set triggerNode(e){M(this.#e,e,!0)}#t=j(null);get contentNode(){return L(this.#t)}set contentNode(e){M(this.#t,e,!0)}#n=j(null);get overlayNode(){return L(this.#n)}set overlayNode(e){M(this.#n,e,!0)}#r=j(null);get descriptionNode(){return L(this.#r)}set descriptionNode(e){M(this.#r,e,!0)}#i=j(void 0);get contentId(){return L(this.#i)}set contentId(e){M(this.#i,e,!0)}#a=j(void 0);get titleId(){return L(this.#a)}set titleId(e){M(this.#a,e,!0)}#o=j(void 0);get triggerId(){return L(this.#o)}set triggerId(e){M(this.#o,e,!0)}#s=j(void 0);get descriptionId(){return L(this.#s)}set descriptionId(e){M(this.#s,e,!0)}#c=j(null);get cancelNode(){return L(this.#c)}set cancelNode(e){M(this.#c,e,!0)}#l=j(0);get nestedOpenCount(){return L(this.#l)}set nestedOpenCount(e){M(this.#l,e,!0)}depth;parent;contentPresence;overlayPresence;constructor(e,t){this.opts=e,this.parent=t,this.depth=t?t.depth+1:0,this.handleOpen=this.handleOpen.bind(this),this.handleClose=this.handleClose.bind(this),this.contentPresence=new cC({ref:Q(()=>this.contentNode),open:this.opts.open,enabled:!0,onComplete:()=>{this.opts.onOpenChangeComplete.current(this.opts.open.current)}}),this.overlayPresence=new cC({ref:Q(()=>this.overlayNode),open:this.opts.open,enabled:!0}),Jx(()=>this.opts.open.current,e=>{this.parent&&(e?this.parent.incrementNested():this.parent.decrementNested())},{lazy:!0}),oS(()=>{this.opts.open.current&&this.parent?.decrementNested()})}handleOpen(){this.opts.open.current||(this.opts.open.current=!0)}handleClose(){this.opts.open.current&&(this.opts.open.current=!1)}getBitsAttr=e=>uC.getAttr(e,this.opts.variant.current);incrementNested(){this.nestedOpenCount++,this.parent?.incrementNested()}decrementNested(){this.nestedOpenCount!==0&&(this.nestedOpenCount--,this.parent?.decrementNested())}#u=A(()=>({"data-state":OS(this.opts.open.current)}));get sharedProps(){return L(this.#u)}set sharedProps(e){M(this.#u,e)}},pC=class e{static create(t){return new e(t,dC.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=CS(this.opts.ref),this.onclick=this.onclick.bind(this),this.onkeydown=this.onkeydown.bind(this)}onclick(e){this.opts.disabled.current||e.button>0||this.root.handleClose()}onkeydown(e){this.opts.disabled.current||(e.key===` `||e.key===`Enter`)&&(e.preventDefault(),this.root.handleClose())}#e=A(()=>({id:this.opts.id.current,[this.root.getBitsAttr(this.opts.variant.current)]:``,onclick:this.onclick,onkeydown:this.onkeydown,disabled:this.opts.disabled.current?!0:void 0,tabindex:0,...this.root.sharedProps,...this.attachment}));get props(){return L(this.#e)}set props(e){M(this.#e,e)}},mC=class e{static create(t){return new e(t,dC.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.root.titleId=this.opts.id.current,this.attachment=CS(this.opts.ref),Jx.pre(()=>this.opts.id.current,e=>{this.root.titleId=e})}#e=A(()=>({id:this.opts.id.current,role:`heading`,"aria-level":this.opts.level.current,[this.root.getBitsAttr(`title`)]:``,...this.root.sharedProps,...this.attachment}));get props(){return L(this.#e)}set props(e){M(this.#e,e)}},hC=class e{static create(t){return new e(t,dC.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.root.descriptionId=this.opts.id.current,this.attachment=CS(this.opts.ref,e=>{this.root.descriptionNode=e}),Jx.pre(()=>this.opts.id.current,e=>{this.root.descriptionId=e})}#e=A(()=>({id:this.opts.id.current,[this.root.getBitsAttr(`description`)]:``,...this.root.sharedProps,...this.attachment}));get props(){return L(this.#e)}set props(e){M(this.#e,e)}},gC=class e{static create(t){return new e(t,dC.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=CS(this.opts.ref,e=>{this.root.contentNode=e,this.root.contentId=e?.id})}#e=A(()=>({open:this.root.opts.open.current}));get snippetProps(){return L(this.#e)}set snippetProps(e){M(this.#e,e)}#t=A(()=>({id:this.opts.id.current,role:this.root.opts.variant.current===`alert-dialog`?`alertdialog`:`dialog`,"aria-modal":`true`,"aria-describedby":this.root.descriptionId,"aria-labelledby":this.root.titleId,[this.root.getBitsAttr(`content`)]:``,style:{pointerEvents:`auto`,outline:this.root.opts.variant.current===`alert-dialog`?`none`:void 0,"--bits-dialog-depth":this.root.depth,"--bits-dialog-nested-count":this.root.nestedOpenCount,contain:`layout style`},tabindex:this.root.opts.variant.current===`alert-dialog`?-1:void 0,"data-nested-open":ES(this.root.nestedOpenCount>0),"data-nested":ES(this.root.parent!==null),...this.root.sharedProps,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}get shouldRender(){return this.root.contentPresence.shouldRender}},_C=class e{static create(t){return new e(t,dC.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=CS(this.opts.ref,e=>this.root.overlayNode=e)}#e=A(()=>({open:this.root.opts.open.current}));get snippetProps(){return L(this.#e)}set snippetProps(e){M(this.#e,e)}#t=A(()=>({id:this.opts.id.current,[this.root.getBitsAttr(`overlay`)]:``,style:{pointerEvents:`auto`,"--bits-dialog-depth":this.root.depth,"--bits-dialog-nested-count":this.root.nestedOpenCount},"data-nested-open":ES(this.root.nestedOpenCount>0),"data-nested":ES(this.root.parent!==null),...this.root.sharedProps,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}get shouldRender(){return this.root.overlayPresence.shouldRender}},vC=R(`<div><!></div>`);function yC(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>lC(n)),i=K(t,`ref`,15,null),a=K(t,`child`,7),o=K(t,`children`,7),s=K(t,`level`,7,2),c=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`ref`,`child`,`children`,`level`]),l=mC.create({id:Q(()=>r()),level:Q(()=>s()),ref:Q(()=>i(),e=>i(e))}),u=A(()=>zx(c,l.props));var d={get id(){return r()},set id(e=lC(n)){r(e),k()},get ref(){return i()},set ref(e=null){i(e),k()},get child(){return a()},set child(e){a(e),k()},get children(){return o()},set children(e){o(e),k()},get level(){return s()},set level(e=2){s(e),k()}},f=z(),p=P(f),m=e=>{var t=z();H(P(t),a,()=>({props:L(u)})),B(e,t)},h=e=>{var t=vC();Ja(t,()=>({...L(u)})),H(N(t),()=>o()??w),E(t),B(e,t)};return U(p,e=>{a()?e(m):e(h,-1)}),B(e,f),O(d)}q(yC,{id:{},ref:{},child:{},children:{},level:{}},[],[],{mode:`open`});function bC(e,t){D(t,!0);let n=K(t,`children`,7);var r={get children(){return n()},set children(e){n(e),k()}},i=z();return Gi(P(i),n,e=>{var t=z();H(P(t),()=>n()??w),B(e,t)}),B(e,i),O(r)}q(bC,{children:{}},[],[],{mode:`open`});var xC=new Wx(`BitsConfig`);function SC(){let e=new wC(null,{});return xC.getOr(e).opts}function CC(e){return xC.set(new wC(xC.getOr(null),e))}var wC=class{opts;constructor(e,t){let n=TC(e,t);this.opts={defaultPortalTo:n(e=>e.defaultPortalTo),defaultLocale:n(e=>e.defaultLocale)}}};function TC(e,t){return n=>Q(()=>{let r=n(t)?.current;if(r!==void 0)return r;if(e!==null)return n(e.opts)?.current})}function EC(e,t){return n=>{let r=SC();return Q(()=>{let i=n();if(i!==void 0)return i;let a=e(r).current;return a===void 0?t:a})}}var DC=EC(e=>e.defaultPortalTo,`body`);function OC(e,t){D(t,!0);let n=K(t,`to`,7),r=K(t,`children`,7),i=K(t,`disabled`,7),a=DC(()=>n()),o=mt(),s=A(c);function c(){if(!ZS||i())return null;let e=null;return e=typeof a.current==`string`?document.querySelector(a.current):a.current,e}let l;function u(){l&&=(Pi(l),null)}Jx([()=>L(s),()=>i()],([e,t])=>{if(!e||t){u();return}return l=ki(bC,{target:e,props:{children:r()},context:o}),()=>{u()}});var d={get to(){return n()},set to(e){n(e),k()},get children(){return r()},set children(e){r(e),k()},get disabled(){return i()},set disabled(e){i(e),k()}},f=z(),p=P(f),m=e=>{var t=z();H(P(t),()=>r()??w),B(e,t)};return U(p,e=>{i()&&e(m)}),B(e,f),O(d)}q(OC,{to:{},children:{},disabled:{}},[],[],{mode:`open`});var kC=class{eventName;options;constructor(e,t={bubbles:!0,cancelable:!0}){this.eventName=e,this.options=t}createEvent(e){return new CustomEvent(this.eventName,{...this.options,detail:e})}dispatch(e,t){let n=this.createEvent(t);return e.dispatchEvent(n),n}listen(e,t,n){return ri(e,this.eventName,e=>{t(e)},n)}};function AC(e,t=500){let n=null,r=(...r)=>{n!==null&&clearTimeout(n),n=setTimeout(()=>{e(...r)},t)};return r.destroy=()=>{n!==null&&(clearTimeout(n),n=null)},r}function jC(e,t){return e===t||e.contains(t)}function MC(e){return e?.ownerDocument??document}function NC(e,t){let{clientX:n,clientY:r}=e,i=t.getBoundingClientRect();return n<i.left||n>i.right||r<i.top||r>i.bottom}var PC=[RS,` `],FC=[MS,US,BS],IC=[FS,HS,`End`],LC=[...FC,...IC];[...PC],[...PC];function RC(e){return e===`indeterminate`}function zC(e){return RC(e)?`indeterminate`:e?`checked`:`unchecked`}function BC(e){return e.pointerType===`mouse`}function VC(e,{select:t=!1}={}){if(!e||!e.focus)return;let n=yS(e);if(n.activeElement===e)return;let r=n.activeElement;e.focus({preventScroll:!0}),e!==r&&aC(e)&&t&&e.select()}function HC(e,{select:t=!1}={},n){let r=n();for(let i of e)if(VC(i,{select:t}),n()!==r)return!0}var UC=j(!1),WC=class e{static _refs=0;static _cleanup;constructor(){$n(()=>(e._refs===0&&(e._cleanup=nr(()=>{let e=[],t=e=>{M(UC,!1)};return e.push(ri(document,`pointerdown`,t,{capture:!0}),ri(document,`pointermove`,t,{capture:!0}),ri(document,`keydown`,e=>{M(UC,!0)},{capture:!0})),Mx(...e)})),e._refs++,()=>{e._refs--,e._refs===0&&(M(UC,!1),e._cleanup?.())}))}get current(){return L(UC)}set current(e){M(UC,e,!0)}},GC=[`input:not([inert]):not([inert] *)`,`select:not([inert]):not([inert] *)`,`textarea:not([inert]):not([inert] *)`,`a[href]:not([inert]):not([inert] *)`,`button:not([inert]):not([inert] *)`,`[tabindex]:not(slot):not([inert]):not([inert] *)`,`audio[controls]:not([inert]):not([inert] *)`,`video[controls]:not([inert]):not([inert] *)`,`[contenteditable]:not([contenteditable="false"]):not([inert]):not([inert] *)`,`details>summary:first-of-type:not([inert]):not([inert] *)`,`details:not([inert]):not([inert] *)`],KC=GC.join(`,`),qC=typeof Element>`u`,JC=qC?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,YC=!qC&&Element.prototype.getRootNode?function(e){return e?.getRootNode?.call(e)}:function(e){return e?.ownerDocument},XC=function(e,t){t===void 0&&(t=!0);var n=e?.getAttribute?.call(e,`inert`);return n===``||n===`true`||t&&e&&(typeof e.closest==`function`?e.closest(`[inert]`):XC(e.parentNode))},ZC=function(e){var t=e?.getAttribute?.call(e,`contenteditable`);return t===``||t===`true`},QC=function(e,t,n){if(XC(e))return[];var r=Array.prototype.slice.apply(e.querySelectorAll(KC));return t&&JC.call(e,KC)&&r.unshift(e),r=r.filter(n),r},$C=function(e,t,n){for(var r=[],i=Array.from(e);i.length;){var a=i.shift();if(!XC(a,!1))if(a.tagName===`SLOT`){var o=a.assignedElements(),s=$C(o.length?o:a.children,!0,n);n.flatten?r.push.apply(r,s):r.push({scopeParent:a,candidates:s})}else{JC.call(a,KC)&&n.filter(a)&&(t||!e.includes(a))&&r.push(a);var c=a.shadowRoot||typeof n.getShadowRoot==`function`&&n.getShadowRoot(a),l=!XC(c,!1)&&(!n.shadowRootFilter||n.shadowRootFilter(a));if(c&&l){var u=$C(c===!0?a.children:c.children,!0,n);n.flatten?r.push.apply(r,u):r.push({scopeParent:a,candidates:u})}else i.unshift.apply(i,a.children)}}return r},ew=function(e){return!isNaN(parseInt(e.getAttribute(`tabindex`),10))},tw=function(e){if(!e)throw Error(`No node provided`);return e.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(e.tagName)||ZC(e))&&!ew(e)?0:e.tabIndex},nw=function(e,t){var n=tw(e);return n<0&&t&&!ew(e)?0:n},rw=function(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex},iw=function(e){return e.tagName===`INPUT`},aw=function(e){return iw(e)&&e.type===`hidden`},ow=function(e){return e.tagName===`DETAILS`&&Array.prototype.slice.apply(e.children).some(function(e){return e.tagName===`SUMMARY`})},sw=function(e,t){for(var n=0;n<e.length;n++)if(e[n].checked&&e[n].form===t)return e[n]},cw=function(e){if(!e.name)return!0;var t=e.form||YC(e),n=function(e){return t.querySelectorAll(`input[type="radio"][name="`+e+`"]`)},r;if(typeof window<`u`&&window.CSS!==void 0&&typeof window.CSS.escape==`function`)r=n(window.CSS.escape(e.name));else try{r=n(e.name)}catch(e){return console.error(`Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s`,e.message),!1}var i=sw(r,e.form);return!i||i===e},lw=function(e){return iw(e)&&e.type===`radio`},uw=function(e){return lw(e)&&!cw(e)},dw=function(e){var t=e&&YC(e),n=t?.host,r=!1;if(t&&t!==e){var i,a,o;for(r=!!((i=n)!=null&&(a=i.ownerDocument)!=null&&a.contains(n)||e!=null&&(o=e.ownerDocument)!=null&&o.contains(e));!r&&n;){var s,c;t=YC(n),n=t?.host,r=!!((s=n)!=null&&(c=s.ownerDocument)!=null&&c.contains(n))}}return r},fw=function(e){var t=e.getBoundingClientRect(),n=t.width,r=t.height;return n===0&&r===0},pw=function(e,t){var n=t.displayCheck,r=t.getShadowRoot;if(n===`full-native`&&`checkVisibility`in e)return!e.checkVisibility({checkOpacity:!1,opacityProperty:!1,contentVisibilityAuto:!0,visibilityProperty:!0,checkVisibilityCSS:!0});if(getComputedStyle(e).visibility===`hidden`)return!0;var i=JC.call(e,`details>summary:first-of-type`)?e.parentElement:e;if(JC.call(i,`details:not([open]) *`))return!0;if(!n||n===`full`||n===`full-native`||n===`legacy-full`){if(typeof r==`function`){for(var a=e;e;){var o=e.parentElement,s=YC(e);if(o&&!o.shadowRoot&&r(o)===!0)return fw(e);e=e.assignedSlot?e.assignedSlot:!o&&s!==e.ownerDocument?s.host:o}e=a}if(dw(e))return!e.getClientRects().length;if(n!==`legacy-full`)return!0}else if(n===`non-zero-area`)return fw(e);return!1},mw=function(e){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e.tagName))for(var t=e.parentElement;t;){if(t.tagName===`FIELDSET`&&t.disabled){for(var n=0;n<t.children.length;n++){var r=t.children.item(n);if(r.tagName===`LEGEND`)return JC.call(t,`fieldset[disabled] *`)?!0:!r.contains(e)}return!0}t=t.parentElement}return!1},hw=function(e,t){return!(t.disabled||aw(t)||pw(t,e)||ow(t)||mw(t))},gw=function(e,t){return!(uw(t)||tw(t)<0||!hw(e,t))},_w=function(e){var t=parseInt(e.getAttribute(`tabindex`),10);return!!(isNaN(t)||t>=0)},vw=function(e){var t=[],n=[];return e.forEach(function(e,r){var i=!!e.scopeParent,a=i?e.scopeParent:e,o=nw(a,i),s=i?vw(e.candidates):a;o===0?i?t.push.apply(t,s):t.push(a):n.push({documentOrder:r,tabIndex:o,item:e,isScope:i,content:s})}),n.sort(rw).reduce(function(e,t){return t.isScope?e.push.apply(e,t.content):e.push(t.content),e},[]).concat(t)},yw=function(e,t){return t||={},vw(t.getShadowRoot?$C([e],t.includeContainer,{filter:gw.bind(null,t),flatten:!1,getShadowRoot:t.getShadowRoot,shadowRootFilter:_w}):QC(e,t.includeContainer,gw.bind(null,t)))},bw=function(e,t){return t||={},t.getShadowRoot?$C([e],t.includeContainer,{filter:hw.bind(null,t),flatten:!0,getShadowRoot:t.getShadowRoot}):QC(e,t.includeContainer,hw.bind(null,t))},xw=function(e,t){if(t||={},!e)throw Error(`No node provided`);return JC.call(e,KC)===!1?!1:gw(t,e)},Sw=GC.concat(`iframe:not([inert]):not([inert] *)`).join(`,`),Cw=function(e,t){if(t||={},!e)throw Error(`No node provided`);return JC.call(e,Sw)===!1?!1:hw(t,e)};function ww(){return{getShadowRoot:!0,displayCheck:typeof ResizeObserver==`function`&&ResizeObserver.toString().includes(`[native code]`)?`full`:`none`}}function Tw(e,t){if(!xw(e,ww()))return Ew(e,t);let n=yS(e),r=yw(n.body,ww());t===`prev`&&r.reverse();let i=r.indexOf(e);return i===-1?n.body:r.slice(i+1)[0]}function Ew(e,t){let n=yS(e);if(!Cw(e,ww()))return n.body;let r=bw(n.body,ww());t===`prev`&&r.reverse();let i=r.indexOf(e);return i===-1?n.body:r.slice(i+1).find(e=>xw(e,ww()))??n.body}function Dw(e,t){return e.length===t.length?e.every((e,n)=>Ow(e,t[n])):!1}function Ow(e,t){return Number.isNaN(e)&&Number.isNaN(t)?!0:Array.isArray(e)&&Array.isArray(t)?Dw(e,t):typeof e==`object`&&typeof t==`object`?kw(e,t):Object.is(e,t)}function kw(e,t){if(typeof e!=`object`||typeof t!=`object`||e===null||t===null)return!1;let n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(let i of n)if(!r.includes(i)||!Ow(e[i],t[i]))return!1;return!0}function Aw(e,t,n=!0){if(!(e.length===0||t<0||t>=e.length))return e.length===1&&t===0?e[0]:t===e.length-1?n?e[0]:void 0:e[t+1]}function jw(e,t,n=!0){if(!(e.length===0||t<0||t>=e.length))return e.length===1&&t===0?e[0]:t===0?n?e[e.length-1]:void 0:e[t-1]}function Mw(e,t,n,r=!0){if(e.length===0||t<0||t>=e.length)return;let i=t+n;return i=r?(i%e.length+e.length)%e.length:Math.max(0,Math.min(i,e.length-1)),e[i]}function Nw(e,t,n,r=!0){if(e.length===0||t<0||t>=e.length)return;let i=t-n;return i=r?(i%e.length+e.length)%e.length:Math.max(0,Math.min(i,e.length-1)),e[i]}function Pw(e,t,n){let r=t.toLowerCase();if(r.endsWith(` `)){let i=r.slice(0,-1);if(e.filter(e=>e.toLowerCase().startsWith(i)).length<=1)return Pw(e,i,n);let a=n?.toLowerCase();if(a&&a.startsWith(i)&&a.charAt(i.length)===` `&&t.trim()===i)return n;let o=e.filter(e=>e.toLowerCase().startsWith(r));if(o.length>0){let t=n?e.indexOf(n):-1;return Fw(o,Math.max(t,0)).find(e=>e!==n)||n}}let i=t.length>1&&Array.from(t).every(e=>e===t[0])?t[0]:t,a=i.toLowerCase(),o=n?e.indexOf(n):-1,s=Fw(e,Math.max(o,0));i.length===1&&(s=s.filter(e=>e!==n));let c=s.find(e=>e?.toLowerCase().startsWith(a));return c===n?void 0:c}function Fw(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var Iw={afterMs:1e4,onChange:$};function Lw(e,t){let{afterMs:n,onChange:r,getWindow:i}={...Iw,...t},a=null,o=j(Dn(e));function s(){return i().setTimeout(()=>{M(o,e,!0),r?.(e)},n)}return $n(()=>()=>{a&&i().clearTimeout(a)}),Q(()=>L(o),e=>{M(o,e,!0),r?.(e),a&&i().clearTimeout(a),a=s()})}var Rw=class{#e;#t;#n=A(()=>this.#e.onMatch?this.#e.onMatch:e=>e.focus());#r=A(()=>this.#e.getCurrentItem?this.#e.getCurrentItem:this.#e.getActiveElement);constructor(e){this.#e=e,this.#t=Lw(``,{afterMs:1e3,getWindow:e.getWindow}),this.handleTypeaheadSearch=this.handleTypeaheadSearch.bind(this),this.resetTypeahead=this.resetTypeahead.bind(this)}handleTypeaheadSearch(e,t){if(!t.length)return;this.#t.current=this.#t.current+e;let n=L(this.#r)(),r=t.find(e=>e===n)?.textContent?.trim()??``,i=Pw(t.map(e=>e.textContent?.trim()??``),this.#t.current,r),a=t.find(e=>e.textContent?.trim()===i);return a&&L(this.#n)(a),a}resetTypeahead(){this.#t.current=``}get search(){return this.#t.current}},zw=class{#e;#t;#n;#r=j(null);constructor(e){this.#e=e,this.#t=A(()=>this.#e.enabled()),this.#n=Lw(!1,{afterMs:e.transitTimeout??300,onChange:e=>{L(this.#t)&&this.#e.setIsPointerInTransit?.(e)},getWindow:()=>bS(this.#e.triggerNode())}),Jx([e.triggerNode,e.contentNode,e.enabled],([e,t,n])=>!e||!t||!n?void 0:Mx(ri(e,`pointerleave`,e=>{this.#a(e,t)}),ri(t,`pointerleave`,t=>{this.#a(t,e)}))),Jx(()=>L(this.#r),()=>{let t=t=>{if(!L(this.#r))return;let n=t.target;if(!tC(n))return;let r={x:t.clientX,y:t.clientY},i=e.triggerNode()?.contains(n)||e.contentNode()?.contains(n),a=!Uw(r,L(this.#r));i?this.#i():a&&(this.#i(),e.onPointerExit())},n=yS(e.triggerNode()??e.contentNode());if(n)return ri(n,`pointermove`,t)})}#i(){M(this.#r,null),this.#n.current=!1}#a(e,t){let n=e.currentTarget;if(!eC(n))return;let r={x:e.clientX,y:e.clientY},i=Vw(r,Bw(r,n.getBoundingClientRect())),a=Hw(t.getBoundingClientRect()),o=Ww([...i,...a]);M(this.#r,o,!0),this.#n.current=!0}};function Bw(e,t){let n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),i=Math.abs(t.right-e.x),a=Math.abs(t.left-e.x);switch(Math.min(n,r,i,a)){case a:return`left`;case i:return`right`;case n:return`top`;case r:return`bottom`;default:throw Error(`unreachable`)}}function Vw(e,t,n=5){let r=n*1.5;switch(t){case`top`:return[{x:e.x-n,y:e.y+n},{x:e.x,y:e.y-r},{x:e.x+n,y:e.y+n}];case`bottom`:return[{x:e.x-n,y:e.y-n},{x:e.x,y:e.y+r},{x:e.x+n,y:e.y-n}];case`left`:return[{x:e.x+n,y:e.y-n},{x:e.x-r,y:e.y},{x:e.x+n,y:e.y+n}];case`right`:return[{x:e.x-n,y:e.y-n},{x:e.x+r,y:e.y},{x:e.x-n,y:e.y+n}]}}function Hw(e){let{top:t,right:n,bottom:r,left:i}=e;return[{x:i,y:t},{x:n,y:t},{x:n,y:r},{x:i,y:r}]}function Uw(e,t){let{x:n,y:r}=e,i=!1;for(let e=0,a=t.length-1;e<t.length;a=e++){let o=t[e].x,s=t[e].y,c=t[a].x,l=t[a].y;s>r!=l>r&&n<(c-o)*(r-s)/(l-s)+o&&(i=!i)}return i}function Ww(e){let t=e.slice();return t.sort((e,t)=>e.x<t.x?-1:e.x>t.x?1:e.y<t.y?-1:e.y>t.y?1:0),Gw(t)}function Gw(e){if(e.length<=1)return e.slice();let t=[];for(let n=0;n<e.length;n++){let r=e[n];for(;t.length>=2;){let e=t[t.length-1],n=t[t.length-2];if((e.x-n.x)*(r.y-n.y)>=(e.y-n.y)*(r.x-n.x))t.pop();else break}t.push(r)}t.pop();let n=[];for(let t=e.length-1;t>=0;t--){let r=e[t];for(;n.length>=2;){let e=n[n.length-1],t=n[n.length-2];if((e.x-t.x)*(r.y-t.y)>=(e.y-t.y)*(r.x-t.x))n.pop();else break}n.push(r)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}var Kw=`data-context-menu-trigger`,qw=`data-context-menu-content`,Jw=new Wx(`Menu.Root`),Yw=new Wx(`Menu.Root | Menu.Sub`),Xw=new Wx(`Menu.Content`),Zw=new Wx(`Menu.Group | Menu.RadioGroup`),Qw=new Wx(`Menu.RadioGroup`),$w=new Wx(`Menu.CheckboxGroup`),eT=new kC(`bitsmenuopen`,{bubbles:!1,cancelable:!0}),tT=jS({component:`menu`,parts:[`trigger`,`content`,`sub-trigger`,`item`,`group`,`group-heading`,`checkbox-group`,`checkbox-item`,`radio-group`,`radio-item`,`separator`,`sub-content`,`arrow`]}),nT=class e{static create(t){let n=new e(t);return Jw.set(n)}opts;isUsingKeyboard=new WC;#e=j(!1);get ignoreCloseAutoFocus(){return L(this.#e)}set ignoreCloseAutoFocus(e){M(this.#e,e,!0)}#t=j(!1);get isPointerInTransit(){return L(this.#t)}set isPointerInTransit(e){M(this.#t,e,!0)}constructor(e){this.opts=e}getBitsAttr=e=>tT.getAttr(e,this.opts.variant.current)},rT=class e{static create(t,n){return Yw.set(new e(t,n,null))}opts;root;parentMenu;contentId=Q(()=>``);#e=j(null);get contentNode(){return L(this.#e)}set contentNode(e){M(this.#e,e,!0)}contentPresence;#t=j(null);get triggerNode(){return L(this.#t)}set triggerNode(e){M(this.#t,e,!0)}constructor(e,t,n){this.opts=e,this.root=t,this.parentMenu=n,this.contentPresence=new cC({ref:Q(()=>this.contentNode),open:this.opts.open,onComplete:()=>{this.opts.onOpenChangeComplete.current(this.opts.open.current)}}),n&&Jx(()=>n.opts.open.current,()=>{n.opts.open.current||(this.opts.open.current=!1)})}toggleOpen(){this.opts.open.current=!this.opts.open.current}onOpen(){this.opts.open.current=!0}onClose(){this.opts.open.current=!1}},iT=class e{static create(t){return Xw.set(new e(t,Yw.get()))}opts;parentMenu;rovingFocusGroup;domContext;attachment;#e=j(``);get search(){return L(this.#e)}set search(e){M(this.#e,e,!0)}#t=0;#n;#r=j(!1);get mounted(){return L(this.#r)}set mounted(e){M(this.#r,e,!0)}#i;constructor(e,t){this.opts=e,this.parentMenu=t,this.domContext=new SS(e.ref),this.attachment=CS(this.opts.ref,e=>{this.parentMenu.contentNode!==e&&(this.parentMenu.contentNode=e)}),t.contentId=e.id,this.#i=e.isSub??!1,this.onkeydown=this.onkeydown.bind(this),this.onblur=this.onblur.bind(this),this.onfocus=this.onfocus.bind(this),this.handleInteractOutside=this.handleInteractOutside.bind(this),new zw({contentNode:()=>this.parentMenu.contentNode,triggerNode:()=>this.parentMenu.triggerNode,enabled:()=>this.parentMenu.opts.open.current&&!!this.parentMenu.triggerNode?.hasAttribute(this.parentMenu.root.getBitsAttr(`sub-trigger`)),onPointerExit:()=>{this.parentMenu.opts.open.current=!1},setIsPointerInTransit:e=>{this.parentMenu.root.isPointerInTransit=e}}),this.#n=new Rw({getActiveElement:()=>this.domContext.getActiveElement(),getWindow:()=>this.domContext.getWindow()}).handleTypeaheadSearch,this.rovingFocusGroup=new oC({rootNode:Q(()=>this.parentMenu.contentNode),candidateAttr:this.parentMenu.root.getBitsAttr(`item`),loop:this.opts.loop,orientation:Q(()=>`vertical`)}),Jx(()=>this.parentMenu.contentNode,e=>e?eT.listen(e,()=>{lS(()=>{this.parentMenu.root.isUsingKeyboard.current&&this.rovingFocusGroup.focusFirstCandidate()})}):void 0),$n(()=>{this.parentMenu.opts.open.current||this.domContext.getWindow().clearTimeout(this.#t)})}#a(){let e=this.parentMenu.contentNode;return e?Array.from(e.querySelectorAll(`[${this.parentMenu.root.getBitsAttr(`item`)}]:not([data-disabled])`)):[]}#o(){return this.parentMenu.root.isPointerInTransit}onCloseAutoFocus=e=>{this.opts.onCloseAutoFocus.current?.(e),!(e.defaultPrevented||this.#i)&&this.parentMenu.triggerNode&&xw(this.parentMenu.triggerNode)&&(e.preventDefault(),this.parentMenu.triggerNode.focus())};handleTabKeyDown(e){let t=this.parentMenu;for(;t.parentMenu!==null;)t=t.parentMenu;if(!t.triggerNode)return;e.preventDefault();let n=Tw(t.triggerNode,e.shiftKey?`prev`:`next`);n?(this.parentMenu.root.ignoreCloseAutoFocus=!0,t.onClose(),lS(()=>{n.focus(),lS(()=>{this.parentMenu.root.ignoreCloseAutoFocus=!1})})):this.domContext.getDocument().body.focus()}onkeydown(e){if(e.defaultPrevented)return;if(e.key===`Tab`){this.handleTabKeyDown(e);return}let t=e.target,n=e.currentTarget;if(!eC(t)||!eC(n))return;let r=t.closest(`[${this.parentMenu.root.getBitsAttr(`content`)}]`)?.id===this.parentMenu.contentId.current,i=e.ctrlKey||e.altKey||e.metaKey,a=e.key.length===1;if(this.rovingFocusGroup.handleKeydown(t,e)||e.code===`Space`)return;let o=this.#a();r&&!i&&a&&this.#n(e.key,o),e.target?.id===this.parentMenu.contentId.current&&LC.includes(e.key)&&(e.preventDefault(),IC.includes(e.key)&&o.reverse(),HC(o,{select:!1},()=>this.domContext.getActiveElement()))}onblur(e){tC(e.currentTarget)&&tC(e.target)&&(e.currentTarget.contains?.(e.target)||(this.domContext.getWindow().clearTimeout(this.#t),this.search=``))}onfocus(e){this.parentMenu.root.isUsingKeyboard.current&&lS(()=>this.rovingFocusGroup.focusFirstCandidate())}onItemEnter(){return this.#o()}onItemLeave(e){e.currentTarget.hasAttribute(this.parentMenu.root.getBitsAttr(`sub-trigger`))||this.#o()||this.parentMenu.root.isUsingKeyboard.current||(this.parentMenu.contentNode?.focus(),this.rovingFocusGroup.setCurrentTabStopId(``))}onTriggerLeave(){return!!this.#o()}handleInteractOutside(e){if(!nC(e.target))return;let t=this.parentMenu.triggerNode?.id;if(e.target.id===t){e.preventDefault();return}e.target.closest(`#${t}`)&&e.preventDefault()}get shouldRender(){return this.parentMenu.contentPresence.shouldRender}#s=A(()=>({open:this.parentMenu.opts.open.current}));get snippetProps(){return L(this.#s)}set snippetProps(e){M(this.#s,e)}#c=A(()=>({id:this.opts.id.current,role:`menu`,"aria-orientation":`vertical`,[this.parentMenu.root.getBitsAttr(`content`)]:``,"data-state":OS(this.parentMenu.opts.open.current),onkeydown:this.onkeydown,onblur:this.onblur,onfocus:this.onfocus,dir:this.parentMenu.root.opts.dir.current,style:{pointerEvents:`auto`,contain:`layout style`},...this.attachment}));get props(){return L(this.#c)}set props(e){M(this.#c,e)}popperProps={onCloseAutoFocus:e=>this.onCloseAutoFocus(e)}},aT=class{opts;content;attachment;#e=j(!1);constructor(e,t){this.opts=e,this.content=t,this.attachment=CS(this.opts.ref),this.onpointermove=this.onpointermove.bind(this),this.onpointerleave=this.onpointerleave.bind(this),this.onfocus=this.onfocus.bind(this),this.onblur=this.onblur.bind(this)}onpointermove(e){if(!e.defaultPrevented&&BC(e))if(this.opts.disabled.current)this.content.onItemLeave(e);else{if(this.content.onItemEnter())return;let t=e.currentTarget;if(!eC(t))return;t.focus()}}onpointerleave(e){e.defaultPrevented||BC(e)&&this.content.onItemLeave(e)}onfocus(e){lS(()=>{e.defaultPrevented||this.opts.disabled.current||M(this.#e,!0)})}onblur(e){lS(()=>{e.defaultPrevented||M(this.#e,!1)})}#t=A(()=>({id:this.opts.id.current,tabindex:-1,role:`menuitem`,"aria-disabled":wS(this.opts.disabled.current),"data-disabled":ES(this.opts.disabled.current),"data-highlighted":L(this.#e)?``:void 0,[this.content.parentMenu.root.getBitsAttr(`item`)]:``,onpointermove:this.onpointermove,onpointerleave:this.onpointerleave,onfocus:this.onfocus,onblur:this.onblur,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},oT=class e{static create(t){return new e(t,new aT(t,Xw.get()))}opts;item;root;#e=!1;constructor(e,t){this.opts=e,this.item=t,this.root=t.content.parentMenu.root,this.onkeydown=this.onkeydown.bind(this),this.onclick=this.onclick.bind(this),this.onpointerdown=this.onpointerdown.bind(this),this.onpointerup=this.onpointerup.bind(this)}#t(){if(this.item.opts.disabled.current)return;let e=new CustomEvent(`menuitemselect`,{bubbles:!0,cancelable:!0});if(this.opts.onSelect.current(e),e.defaultPrevented){this.item.content.parentMenu.root.isUsingKeyboard.current=!1;return}this.opts.closeOnSelect.current&&this.item.content.parentMenu.root.opts.onClose()}onkeydown(e){let t=this.item.content.search!==``;if(!(this.item.opts.disabled.current||t&&e.key===` `)&&PC.includes(e.key)){if(!eC(e.currentTarget))return;e.currentTarget.click(),e.preventDefault()}}onclick(e){this.item.opts.disabled.current||this.#t()}onpointerup(e){if(!e.defaultPrevented&&!this.#e){if(!eC(e.currentTarget))return;e.currentTarget?.click()}}onpointerdown(e){this.#e=!0}#n=A(()=>zx(this.item.props,{onclick:this.onclick,onpointerdown:this.onpointerdown,onpointerup:this.onpointerup,onkeydown:this.onkeydown}));get props(){return L(this.#n)}set props(e){M(this.#n,e)}},sT=class e{static create(t,n){return new e(t,new oT(t,new aT(t,Xw.get())),n)}opts;item;group;constructor(e,t,n=null){this.opts=e,this.item=t,this.group=n,this.group&&(Jx(()=>this.group.opts.value.current,e=>{this.opts.checked.current=e.includes(this.opts.value.current)}),Jx(()=>this.opts.checked.current,e=>{e?this.group.addValue(this.opts.value.current):this.group.removeValue(this.opts.value.current)}))}toggleChecked(){this.opts.indeterminate.current?(this.opts.indeterminate.current=!1,this.opts.checked.current=!0):this.opts.checked.current=!this.opts.checked.current}#e=A(()=>({checked:this.opts.checked.current,indeterminate:this.opts.indeterminate.current}));get snippetProps(){return L(this.#e)}set snippetProps(e){M(this.#e,e)}#t=A(()=>({...this.item.props,role:`menuitemcheckbox`,"aria-checked":kS(this.opts.checked.current,this.opts.indeterminate.current),"data-state":zC(this.opts.checked.current),[this.item.root.getBitsAttr(`checkbox-item`)]:``}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},cT=class e{static create(t){return Zw.set(new e(t,Jw.get()))}opts;root;attachment;#e=j(void 0);get groupHeadingId(){return L(this.#e)}set groupHeadingId(e){M(this.#e,e,!0)}constructor(e,t){this.opts=e,this.root=t,this.attachment=CS(this.opts.ref)}#t=A(()=>({id:this.opts.id.current,role:`group`,"aria-labelledby":this.groupHeadingId,[this.root.getBitsAttr(`group`)]:``,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},lT=class e{static create(t){let n=$w.getOr(null);if(n)return new e(t,n);let r=Qw.getOr(null);return r?new e(t,r):new e(t,Zw.get())}opts;group;attachment;constructor(e,t){this.opts=e,this.group=t,this.attachment=CS(this.opts.ref,e=>this.group.groupHeadingId=e?.id)}#e=A(()=>({id:this.opts.id.current,role:`group`,[this.group.root.getBitsAttr(`group-heading`)]:``,...this.attachment}));get props(){return L(this.#e)}set props(e){M(this.#e,e)}},uT=class e{static create(t){return new e(t,Jw.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=CS(this.opts.ref)}#e=A(()=>({id:this.opts.id.current,role:`group`,[this.root.getBitsAttr(`separator`)]:``,...this.attachment}));get props(){return L(this.#e)}set props(e){M(this.#e,e)}},dT=class e{static create(t){return Zw.set(Qw.set(new e(t,Xw.get())))}opts;content;attachment;#e=j(null);get groupHeadingId(){return L(this.#e)}set groupHeadingId(e){M(this.#e,e,!0)}root;constructor(e,t){this.opts=e,this.content=t,this.root=t.parentMenu.root,this.attachment=CS(this.opts.ref)}setValue(e){this.opts.value.current=e}#t=A(()=>({id:this.opts.id.current,[this.root.getBitsAttr(`radio-group`)]:``,role:`group`,"aria-labelledby":this.groupHeadingId,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},fT=class e{static create(t){let n=Qw.get();return new e(t,new oT(t,new aT(t,n.content)),n)}opts;item;group;attachment;#e=A(()=>this.group.opts.value.current===this.opts.value.current);get isChecked(){return L(this.#e)}set isChecked(e){M(this.#e,e)}constructor(e,t,n){this.opts=e,this.item=t,this.group=n,this.attachment=CS(this.opts.ref)}selectValue(){this.group.setValue(this.opts.value.current)}#t=A(()=>({[this.group.root.getBitsAttr(`radio-item`)]:``,...this.item.props,role:`menuitemradio`,"aria-checked":kS(this.isChecked,!1),"data-state":zC(this.isChecked),...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},pT=class e{static create(t){return new e(t,Yw.get())}opts;parentMenu;attachment;constructor(e,t){this.opts=e,this.parentMenu=t,this.attachment=CS(this.opts.ref,e=>this.parentMenu.triggerNode=e)}onclick=e=>{this.opts.disabled.current||e.detail!==0||(this.parentMenu.toggleOpen(),e.preventDefault())};onpointerdown=e=>{if(!this.opts.disabled.current){if(e.pointerType===`touch`)return e.preventDefault();e.button===0&&e.ctrlKey===!1&&(this.parentMenu.toggleOpen(),this.parentMenu.opts.open.current||e.preventDefault())}};onpointerup=e=>{this.opts.disabled.current||e.pointerType===`touch`&&(e.preventDefault(),this.parentMenu.toggleOpen())};onkeydown=e=>{if(!this.opts.disabled.current){if(e.key===` `||e.key===`Enter`){this.parentMenu.toggleOpen(),e.preventDefault();return}e.key===`ArrowDown`&&(this.parentMenu.onOpen(),e.preventDefault())}};#e=A(()=>{if(this.parentMenu.opts.open.current&&this.parentMenu.contentId.current)return this.parentMenu.contentId.current});#t=A(()=>({id:this.opts.id.current,disabled:this.opts.disabled.current,"aria-haspopup":`menu`,"aria-expanded":wS(this.parentMenu.opts.open.current),"aria-controls":L(this.#e),"data-disabled":ES(this.opts.disabled.current),"data-state":OS(this.parentMenu.opts.open.current),[this.parentMenu.root.getBitsAttr(`trigger`)]:``,onclick:this.onclick,onpointerdown:this.onpointerdown,onpointerup:this.onpointerup,onkeydown:this.onkeydown,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},mT=class e{static create(t){return $w.set(new e(t,Xw.get()))}opts;content;root;attachment;#e=j(null);get groupHeadingId(){return L(this.#e)}set groupHeadingId(e){M(this.#e,e,!0)}constructor(e,t){this.opts=e,this.content=t,this.root=t.parentMenu.root,this.attachment=CS(this.opts.ref)}addValue(e){if(e&&!this.opts.value.current.includes(e)){let t=[...st(this.opts.value.current),e];if(this.opts.value.current=t,Dw(this.opts.value.current,t))return;this.opts.onValueChange.current(t)}}removeValue(e){if(!e||this.opts.value.current.indexOf(e)===-1)return;let t=this.opts.value.current.filter(t=>t!==e);this.opts.value.current=t,!Dw(this.opts.value.current,t)&&this.opts.onValueChange.current(t)}#t=A(()=>({id:this.opts.id.current,[this.root.getBitsAttr(`checkbox-group`)]:``,role:`group`,"aria-labelledby":this.groupHeadingId,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}};globalThis.bitsDismissableLayers??=new Map;var hT=class e{static create(t){return new e(t)}opts;#e;#t;#n={pointerdown:!1};#r=!1;#i=!1;#a=void 0;#o;#s=$;constructor(e){this.opts=e,this.#t=e.interactOutsideBehavior,this.#e=e.onInteractOutside,this.#o=e.onFocusOutside,$n(()=>{this.#a=MC(this.opts.ref.current)});let t=$,n=()=>{this.#g(),globalThis.bitsDismissableLayers.delete(this),this.#d.destroy(),t()};Jx([()=>this.opts.enabled.current,()=>this.opts.ref.current],()=>{if(!(!this.opts.enabled.current||!this.opts.ref.current))return cS(1,()=>{this.opts.ref.current&&(globalThis.bitsDismissableLayers.set(this,this.#t),t(),t=this.#l())}),n}),oS(()=>{this.#g.destroy(),globalThis.bitsDismissableLayers.delete(this),this.#d.destroy(),this.#s(),t()})}#c=e=>{e.defaultPrevented||this.opts.ref.current&&lS(()=>{!this.opts.ref.current||this.#h(e.target)||e.target&&!this.#i&&this.#o.current?.(e)})};#l(){return Mx(ri(this.#a,`pointerdown`,Mx(this.#f,this.#m),{capture:!0}),ri(this.#a,`pointerdown`,Mx(this.#p,this.#d)),ri(this.#a,`focusin`,this.#c))}#u=e=>{let t=e;t.defaultPrevented&&(t=yT(e)),this.#e.current(e)};#d=AC(e=>{if(!this.opts.ref.current){this.#s();return}let t=this.opts.isValidEvent.current(e,this.opts.ref.current)||vT(e,this.opts.ref.current);if(!this.#r||this.#_()||!t){this.#s();return}let n=e;if(n.defaultPrevented&&(n=yT(n)),this.#t.current!==`close`&&this.#t.current!==`defer-otherwise-close`){this.#s();return}e.pointerType===`touch`?(this.#s(),this.#s=ri(this.#a,`click`,this.#u,{once:!0})):this.#e.current(n)},10);#f=e=>{this.#n[e.type]=!0};#p=e=>{this.#n[e.type]=!1};#m=()=>{this.opts.ref.current&&(this.#r=_T(this.opts.ref.current))};#h=e=>this.opts.ref.current?jC(this.opts.ref.current,e):!1;#g=AC(()=>{for(let e in this.#n)this.#n[e]=!1;this.#r=!1},20);#_(){return Object.values(this.#n).some(Boolean)}#v=()=>{this.#i=!0};#y=()=>{this.#i=!1};props={onfocuscapture:this.#v,onblurcapture:this.#y}};function gT(e=[...globalThis.bitsDismissableLayers]){return e.findLast(([e,{current:t}])=>t===`close`||t===`ignore`)}function _T(e){let t=[...globalThis.bitsDismissableLayers],n=gT(t);if(n)return n[0].opts.ref.current===e;let[r]=t[0];return r.opts.ref.current===e}function vT(e,t){let n=e.target;if(!nC(n))return!1;let r=!!n.closest(`[${Kw}]`);if(`button`in e&&e.button>0&&!r)return!1;if(`button`in e&&e.button===0&&r)return!0;let i=!!t.closest(`[${qw}]`);return r&&i?!1:MC(n).documentElement.contains(n)&&!jC(t,n)&&NC(e,t)}function yT(e){let t=e.currentTarget,n=e.target,r;r=e instanceof PointerEvent?new PointerEvent(e.type,e):new PointerEvent(`pointerdown`,e);let i=!1;return new Proxy(r,{get:(r,a)=>a===`currentTarget`?t:a===`target`?n:a===`preventDefault`?()=>{i=!0,typeof r.preventDefault==`function`&&r.preventDefault()}:a===`defaultPrevented`?i:a in r?r[a]:e[a]})}function bT(e,t){D(t,!0);let n=K(t,`interactOutsideBehavior`,7,`close`),r=K(t,`onInteractOutside`,7,$),i=K(t,`onFocusOutside`,7,$),a=K(t,`id`,7),o=K(t,`children`,7),s=K(t,`enabled`,7),c=K(t,`isValidEvent`,7,()=>!1),l=K(t,`ref`,7),u=hT.create({id:Q(()=>a()),interactOutsideBehavior:Q(()=>n()),onInteractOutside:Q(()=>r()),enabled:Q(()=>s()),onFocusOutside:Q(()=>i()),isValidEvent:Q(()=>c()),ref:l()});var d={get interactOutsideBehavior(){return n()},set interactOutsideBehavior(e=`close`){n(e),k()},get onInteractOutside(){return r()},set onInteractOutside(e=$){r(e),k()},get onFocusOutside(){return i()},set onFocusOutside(e=$){i(e),k()},get id(){return a()},set id(e){a(e),k()},get children(){return o()},set children(e){o(e),k()},get enabled(){return s()},set enabled(e){s(e),k()},get isValidEvent(){return c()},set isValidEvent(e=()=>!1){c(e),k()},get ref(){return l()},set ref(e){l(e),k()}},f=z();return H(P(f),()=>o()??w,()=>({props:u.props})),B(e,f),O(d)}q(bT,{interactOutsideBehavior:{},onInteractOutside:{},onFocusOutside:{},id:{},children:{},enabled:{},isValidEvent:{},ref:{}},[],[],{mode:`open`}),globalThis.bitsEscapeLayers??=new Map;var xT=class e{static create(t){return new e(t)}opts;domContext;constructor(e){this.opts=e,this.domContext=new SS(this.opts.ref);let t=$;Jx(()=>e.enabled.current,n=>(n&&(globalThis.bitsEscapeLayers.set(this,e.escapeKeydownBehavior),t=this.#e()),()=>{t(),globalThis.bitsEscapeLayers.delete(this)}))}#e=()=>ri(this.domContext.getDocument(),`keydown`,this.#t,{passive:!1});#t=e=>{if(e.key!==`Escape`||!ST(this))return;let t=new KeyboardEvent(e.type,e);e.preventDefault();let n=this.opts.escapeKeydownBehavior.current;n!==`close`&&n!==`defer-otherwise-close`||this.opts.onEscapeKeydown.current(t)}};function ST(e){let t=[...globalThis.bitsEscapeLayers],n=t.findLast(([e,{current:t}])=>t===`close`||t===`ignore`);if(n)return n[0]===e;let[r]=t[0];return r===e}function CT(e,t){D(t,!0);let n=K(t,`escapeKeydownBehavior`,7,`close`),r=K(t,`onEscapeKeydown`,7,$),i=K(t,`children`,7),a=K(t,`enabled`,7),o=K(t,`ref`,7);xT.create({escapeKeydownBehavior:Q(()=>n()),onEscapeKeydown:Q(()=>r()),enabled:Q(()=>a()),ref:o()});var s={get escapeKeydownBehavior(){return n()},set escapeKeydownBehavior(e=`close`){n(e),k()},get onEscapeKeydown(){return r()},set onEscapeKeydown(e=$){r(e),k()},get children(){return i()},set children(e){i(e),k()},get enabled(){return a()},set enabled(e){a(e),k()},get ref(){return o()},set ref(e){o(e),k()}},c=z();return H(P(c),()=>i()??w),B(e,c),O(s)}q(CT,{escapeKeydownBehavior:{},onEscapeKeydown:{},children:{},enabled:{},ref:{}},[],[],{mode:`open`});var wT=class e{static instance;#e=rx([]);#t=new WeakMap;#n=new WeakMap;static getInstance(){return this.instance||=new e,this.instance}register(e){let t=this.getActive();t&&t!==e&&t.pause();let n=document.activeElement;n&&n!==document.body&&this.#n.set(e,n),this.#e.current=this.#e.current.filter(t=>t!==e),this.#e.current.unshift(e)}unregister(e){this.#e.current=this.#e.current.filter(t=>t!==e);let t=this.getActive();t&&t.resume()}getActive(){return this.#e.current[0]}setFocusMemory(e,t){this.#t.set(e,t)}getFocusMemory(e){return this.#t.get(e)}isActiveScope(e){return this.getActive()===e}setPreFocusMemory(e,t){this.#n.set(e,t)}getPreFocusMemory(e){return this.#n.get(e)}clearPreFocusMemory(e){this.#n.delete(e)}},TT=class e{#e=!1;#t=null;#n=wT.getInstance();#r=[];#i;constructor(e){this.#i=e}get paused(){return this.#e}pause(){this.#e=!0}resume(){this.#e=!1}#a(){for(let e of this.#r)e();this.#r=[]}mount(e){this.#t&&this.unmount(),this.#t=e,this.#n.register(this),this.#c(),this.#o()}unmount(){this.#t&&=(this.#a(),this.#s(),this.#n.unregister(this),this.#n.clearPreFocusMemory(this),null)}#o(){if(!this.#t)return;let e=new CustomEvent(`focusScope.onOpenAutoFocus`,{bubbles:!1,cancelable:!0});this.#i.onOpenAutoFocus.current(e),e.defaultPrevented||requestAnimationFrame(()=>{if(!this.#t)return;let e=this.#u();e?(e.focus(),this.#n.setFocusMemory(this,e)):this.#t.focus()})}#s(){let e=new CustomEvent(`focusScope.onCloseAutoFocus`,{bubbles:!1,cancelable:!0});if(this.#i.onCloseAutoFocus.current?.(e),!e.defaultPrevented){let e=this.#n.getPreFocusMemory(this);if(e&&document.contains(e))try{e.focus()}catch{document.body.focus()}}}#c(){if(!this.#t||!this.#i.trap.current)return;let e=this.#t,t=e.ownerDocument;this.#r.push(ri(t,`focusin`,t=>{if(this.#e||!this.#n.isActiveScope(this))return;let n=t.target;if(n)if(e.contains(n))this.#n.setFocusMemory(this,n);else{let n=this.#n.getFocusMemory(this);if(n&&e.contains(n)&&Cw(n))t.preventDefault(),n.focus();else{let t=this.#u(),n=this.#d()[0];(t||n||e).focus()}}},{capture:!0}),ri(e,`keydown`,e=>{if(!this.#i.loop||this.#e||e.key!==`Tab`||!this.#n.isActiveScope(this))return;let n=this.#l();if(n.length===0)return;let r=n[0],i=n[n.length-1];!e.shiftKey&&t.activeElement===i?(e.preventDefault(),r.focus()):e.shiftKey&&t.activeElement===r&&(e.preventDefault(),i.focus())}));let n=new MutationObserver(()=>{let t=this.#n.getFocusMemory(this);if(t&&!e.contains(t)){let t=this.#u(),n=this.#d()[0],r=t||n;r?(r.focus(),this.#n.setFocusMemory(this,r)):e.focus()}});n.observe(e,{childList:!0,subtree:!0}),this.#r.push(()=>n.disconnect())}#l(){return this.#t?yw(this.#t,{includeContainer:!1,getShadowRoot:!0}):[]}#u(){return this.#l()[0]||null}#d(){return this.#t?bw(this.#t,{includeContainer:!1,getShadowRoot:!0}):[]}static use(t){let n=null;return Jx([()=>t.ref.current,()=>t.enabled.current],([r,i])=>{r&&i?(n||=new e(t),n.mount(r)):n&&=(n.unmount(),null)}),oS(()=>{n?.unmount()}),{get props(){return{tabindex:-1}}}}};function ET(e,t){D(t,!0);let n=K(t,`enabled`,7,!1),r=K(t,`trapFocus`,7,!1),i=K(t,`loop`,7,!1),a=K(t,`onCloseAutoFocus`,7,$),o=K(t,`onOpenAutoFocus`,7,$),s=K(t,`focusScope`,7),c=K(t,`ref`,7),l=TT.use({enabled:Q(()=>n()),trap:Q(()=>r()),loop:i(),onCloseAutoFocus:Q(()=>a()),onOpenAutoFocus:Q(()=>o()),ref:c()});var u={get enabled(){return n()},set enabled(e=!1){n(e),k()},get trapFocus(){return r()},set trapFocus(e=!1){r(e),k()},get loop(){return i()},set loop(e=!1){i(e),k()},get onCloseAutoFocus(){return a()},set onCloseAutoFocus(e=$){a(e),k()},get onOpenAutoFocus(){return o()},set onOpenAutoFocus(e=$){o(e),k()},get focusScope(){return s()},set focusScope(e){s(e),k()},get ref(){return c()},set ref(e){c(e),k()}},d=z();return H(P(d),()=>s()??w,()=>({props:l.props})),B(e,d),O(u)}q(ET,{enabled:{},trapFocus:{},loop:{},onCloseAutoFocus:{},onOpenAutoFocus:{},focusScope:{},ref:{}},[],[],{mode:`open`}),globalThis.bitsTextSelectionLayers??=new Map;var DT=class e{static create(t){return new e(t)}opts;domContext;#e=$;constructor(e){this.opts=e,this.domContext=new SS(e.ref);let t=$;Jx(()=>this.opts.enabled.current,e=>(e&&(globalThis.bitsTextSelectionLayers.set(this,this.opts.enabled),t(),t=this.#t()),()=>{t(),this.#r(),globalThis.bitsTextSelectionLayers.delete(this)}))}#t(){return Mx(ri(this.domContext.getDocument(),`pointerdown`,this.#n),ri(this.domContext.getDocument(),`pointerup`,ax(this.#r,this.opts.onPointerUp.current)))}#n=e=>{let t=this.opts.ref.current,n=e.target;!eC(t)||!eC(n)||!this.opts.enabled.current||!jT(this)||!vS(t,n)||(this.opts.onPointerDown.current(e),!e.defaultPrevented&&(this.#e=kT(t,this.domContext.getDocument().body)))};#r=()=>{this.#e(),this.#e=$}},OT=e=>e.style.userSelect||e.style.webkitUserSelect;function kT(e,t){let n=OT(t),r=OT(e);return AT(t,`none`),AT(e,`text`),()=>{AT(t,n),AT(e,r)}}function AT(e,t){e.style.userSelect=t,e.style.webkitUserSelect=t}function jT(e){let t=[...globalThis.bitsTextSelectionLayers];if(!t.length)return!1;let n=t.at(-1);return n?n[0]===e:!1}function MT(e,t){D(t,!0);let n=K(t,`preventOverflowTextSelection`,7,!0),r=K(t,`onPointerDown`,7,$),i=K(t,`onPointerUp`,7,$),a=K(t,`id`,7),o=K(t,`children`,7),s=K(t,`enabled`,7),c=K(t,`ref`,7);DT.create({id:Q(()=>a()),onPointerDown:Q(()=>r()),onPointerUp:Q(()=>i()),enabled:Q(()=>s()&&n()),ref:c()});var l={get preventOverflowTextSelection(){return n()},set preventOverflowTextSelection(e=!0){n(e),k()},get onPointerDown(){return r()},set onPointerDown(e=$){r(e),k()},get onPointerUp(){return i()},set onPointerUp(e=$){i(e),k()},get id(){return a()},set id(e){a(e),k()},get children(){return o()},set children(e){o(e),k()},get enabled(){return s()},set enabled(e){s(e),k()},get ref(){return c()},set ref(e){c(e),k()}},u=z();return H(P(u),()=>o()??w),B(e,u),O(l)}q(MT,{preventOverflowTextSelection:{},onPointerDown:{},onPointerUp:{},id:{},children:{},enabled:{},ref:{}},[],[],{mode:`open`}),globalThis.bitsIdCounter??={current:0};function NT(e=`bits`){return globalThis.bitsIdCounter.current++,`${e}-${globalThis.bitsIdCounter.current}`}var PT=class{#e;#t=0;#n=j();#r;constructor(e){this.#e=e}#i(){--this.#t,this.#r&&this.#t<=0&&(this.#r(),M(this.#n,void 0),this.#r=void 0)}get(...e){return this.#t+=1,L(this.#n)===void 0&&(this.#r=nr(()=>{M(this.#n,this.#e(...e),!0)})),$n(()=>()=>{this.#i()}),L(this.#n)}},FT=new iv,IT=j(null),LT=null,RT=null,zT=!1,BT=Q(()=>{for(let e of FT.values())if(e)return!0;return!1}),VT=null,HT=new PT(()=>{function e(){document.body.setAttribute(`style`,L(IT)??``),document.body.style.removeProperty(`--scrollbar-width`),QS&<?.(),M(IT,null)}function t(){RT!==null&&(window.clearTimeout(RT),RT=null)}function n(e,n){t(),zT=!0,VT=Date.now();let r=VT,i=()=>{RT=null,VT===r&&(WT(FT)?zT=!1:(zT=!1,n()))},a=e===null?24:e;RT=window.setTimeout(i,a)}function r(){L(IT)===null&&FT.size===0&&!zT&&M(IT,document.body.getAttribute(`style`),!0)}return Jx(()=>BT.current,()=>{if(!BT.current)return;r(),zT=!1;let e=getComputedStyle(document.documentElement),t=getComputedStyle(document.body),n=e.scrollbarGutter?.includes(`stable`)||t.scrollbarGutter?.includes(`stable`),i=window.innerWidth-document.documentElement.clientWidth,a={padding:Number.parseInt(t.paddingRight??`0`,10)+i,margin:Number.parseInt(t.marginRight??`0`,10)};i>0&&!n&&(document.body.style.paddingRight=`${a.padding}px`,document.body.style.marginRight=`${a.margin}px`,document.body.style.setProperty(`--scrollbar-width`,`${i}px`)),document.body.style.overflow=`hidden`,QS&&(LT=ri(document,`touchmove`,e=>{e.target===document.documentElement&&(e.touches.length>1||e.preventDefault())},{passive:!1})),lS(()=>{document.body.style.pointerEvents=`none`,document.body.style.overflow=`hidden`})}),oS(()=>()=>{LT?.()}),{get lockMap(){return FT},resetBodyStyle:e,scheduleCleanupIfNoNewLocks:n,cancelPendingCleanup:t,ensureInitialStyleCaptured:r}}),UT=class{#e=NT();#t;#n=()=>null;#r;locked;constructor(e,t=()=>null){this.#t=e,this.#n=t,this.#r=HT.get(),this.#r&&(this.#r.cancelPendingCleanup(),this.#r.ensureInitialStyleCaptured(),this.#r.lockMap.set(this.#e,this.#t??!1),this.locked=Q(()=>this.#r.lockMap.get(this.#e)??!1,e=>this.#r.lockMap.set(this.#e,e)),oS(()=>{if(this.#r.lockMap.delete(this.#e),WT(this.#r.lockMap))return;let e=this.#n();this.#r.scheduleCleanupIfNoNewLocks(e,()=>{this.#r.resetBodyStyle()})}))}};function WT(e){for(let[t,n]of e)if(n)return!0;return!1}function GT(e,t){D(t,!0);let n=K(t,`preventScroll`,7,!0),r=K(t,`restoreScrollDelay`,7,null);return n()&&new UT(n(),()=>r()),O({get preventScroll(){return n()},set preventScroll(e=!0){n(e),k()},get restoreScrollDelay(){return r()},set restoreScrollDelay(e=null){r(e),k()}})}q(GT,{preventScroll:{},restoreScrollDelay:{}},[],[],{mode:`open`});var KT=R(`<div><!></div>`);function qT(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>lC(n)),i=K(t,`forceMount`,7,!1),a=K(t,`child`,7),o=K(t,`children`,7),s=K(t,`ref`,15,null),c=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`forceMount`,`child`,`children`,`ref`]),l=_C.create({id:Q(()=>r()),ref:Q(()=>s(),e=>s(e))}),u=A(()=>zx(c,l.props));var d={get id(){return r()},set id(e=lC(n)){r(e),k()},get forceMount(){return i()},set forceMount(e=!1){i(e),k()},get child(){return a()},set child(e){a(e),k()},get children(){return o()},set children(e){o(e),k()},get ref(){return s()},set ref(e=null){s(e),k()}},f=z(),p=P(f),m=e=>{var t=z(),n=P(t),r=e=>{var t=z(),n=P(t);{let e=A(()=>({props:zx(L(u)),...l.snippetProps}));H(n,a,()=>L(e))}B(e,t)},i=e=>{var t=KT();Ja(t,e=>({...e}),[()=>zx(L(u))]),H(N(t),()=>o()??w,()=>l.snippetProps),E(t),B(e,t)};U(n,e=>{a()?e(r):e(i,-1)}),B(e,t)};return U(p,e=>{(l.shouldRender||i())&&e(m)}),B(e,f),O(d)}q(qT,{id:{},forceMount:{},child:{},children:{},ref:{}},[],[],{mode:`open`});var JT=R(`<div><!></div>`);function YT(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>lC(n)),i=K(t,`children`,7),a=K(t,`child`,7),o=K(t,`ref`,15,null),s=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`children`,`child`,`ref`]),c=hC.create({id:Q(()=>r()),ref:Q(()=>o(),e=>o(e))}),l=A(()=>zx(s,c.props));var u={get id(){return r()},set id(e=lC(n)){r(e),k()},get children(){return i()},set children(e){i(e),k()},get child(){return a()},set child(e){a(e),k()},get ref(){return o()},set ref(e=null){o(e),k()}},d=z(),f=P(d),p=e=>{var t=z();H(P(t),a,()=>({props:L(l)})),B(e,t)},m=e=>{var t=JT();Ja(t,()=>({...L(l)})),H(N(t),()=>i()??w),E(t),B(e,t)};return U(f,e=>{a()?e(p):e(m,-1)}),B(e,d),O(u)}q(YT,{id:{},children:{},child:{},ref:{}},[],[],{mode:`open`});function XT(e,t){D(t,!0);let n=K(t,`children`,7),r=K(t,`defaultPortalTo`,7),i=K(t,`defaultLocale`,7);CC({defaultPortalTo:Q(()=>r()),defaultLocale:Q(()=>i())});var a={get children(){return n()},set children(e){n(e),k()},get defaultPortalTo(){return r()},set defaultPortalTo(e){r(e),k()},get defaultLocale(){return i()},set defaultLocale(e){i(e),k()}},o=z();return H(P(o),()=>n()??w),B(e,o),O(a)}q(XT,{children:{},defaultPortalTo:{},defaultLocale:{}},[],[],{mode:`open`});var ZT=R(`<input/>`),QT=R(`<input/>`);function $T(e,t){D(t,!0);let n=K(t,`value`,15),r=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`value`]),i=A(()=>zx(r,{"aria-hidden":`true`,tabindex:-1,style:Bx}));var a={get value(){return n()},set value(e){n(e),k()}},o=z(),s=P(o),c=e=>{var t=ZT();Ja(t,()=>({...L(i),value:n()}),void 0,void 0,void 0,void 0,!0),B(e,t)},l=e=>{var t=QT();Ja(t,()=>({...L(i)}),void 0,void 0,void 0,void 0,!0),Qa(t,n),B(e,t)};return U(s,e=>{L(i).type===`checkbox`?e(c):e(l,-1)}),B(e,o),O(a)}q($T,{value:{}},[],[],{mode:`open`});var eE=jS({component:`collapsible`,parts:[`root`,`content`,`trigger`]}),tE=new Wx(`Collapsible.Root`),nE=class e{static create(t){return tE.set(new e(t))}opts;attachment;#e=j(null);get contentNode(){return L(this.#e)}set contentNode(e){M(this.#e,e,!0)}contentPresence;#t=j(void 0);get contentId(){return L(this.#t)}set contentId(e){M(this.#t,e,!0)}constructor(e){this.opts=e,this.toggleOpen=this.toggleOpen.bind(this),this.attachment=CS(this.opts.ref),this.contentPresence=new cC({ref:Q(()=>this.contentNode),open:this.opts.open,onComplete:()=>{this.opts.onOpenChangeComplete.current(this.opts.open.current)}})}toggleOpen(){this.opts.open.current=!this.opts.open.current}#n=A(()=>({id:this.opts.id.current,"data-state":OS(this.opts.open.current),"data-disabled":ES(this.opts.disabled.current),[eE.root]:``,...this.attachment}));get props(){return L(this.#n)}set props(e){M(this.#n,e)}},rE=class e{static create(t){return new e(t,tE.get())}opts;root;attachment;#e=A(()=>this.opts.hiddenUntilFound.current?this.root.opts.open.current:this.opts.forceMount.current||this.root.opts.open.current);get present(){return L(this.#e)}set present(e){M(this.#e,e)}#t;#n=j(!1);#r=j(0);#i=j(0);constructor(e,t){this.opts=e,this.root=t,M(this.#n,t.opts.open.current,!0),this.root.contentId=this.opts.id.current,this.attachment=CS(this.opts.ref,e=>this.root.contentNode=e),Jx.pre(()=>this.opts.id.current,e=>{this.root.contentId=e}),tr(()=>{let e=requestAnimationFrame(()=>{M(this.#n,!1)});return()=>{cancelAnimationFrame(e)}}),Jx.pre([()=>this.opts.ref.current,()=>this.opts.hiddenUntilFound.current],([e,t])=>!e||!t?void 0:ri(e,`beforematch`,()=>{this.root.opts.open.current||requestAnimationFrame(()=>{this.root.opts.open.current=!0})})),Jx([()=>this.opts.ref.current,()=>this.present],([e])=>{e&&lS(()=>{if(!this.opts.ref.current)return;this.#t=this.#t||{transitionDuration:e.style.transitionDuration,animationName:e.style.animationName},e.style.transitionDuration=`0s`,e.style.animationName=`none`;let t=e.getBoundingClientRect();if(M(this.#i,t.height,!0),M(this.#r,t.width,!0),!L(this.#n)){let{animationName:t,transitionDuration:n}=this.#t;e.style.transitionDuration=n,e.style.animationName=t}})})}get shouldRender(){return this.root.contentPresence.shouldRender}#a=A(()=>({open:this.root.opts.open.current}));get snippetProps(){return L(this.#a)}set snippetProps(e){M(this.#a,e)}#o=A(()=>({id:this.opts.id.current,style:{"--bits-collapsible-content-height":L(this.#i)?`${L(this.#i)}px`:void 0,"--bits-collapsible-content-width":L(this.#r)?`${L(this.#r)}px`:void 0},hidden:this.opts.hiddenUntilFound.current&&!this.root.opts.open.current?`until-found`:void 0,"data-state":OS(this.root.opts.open.current),"data-disabled":ES(this.root.opts.disabled.current),[eE.content]:``,...this.opts.hiddenUntilFound.current&&!this.shouldRender?{}:{hidden:this.opts.hiddenUntilFound.current?!this.shouldRender:this.opts.forceMount.current?void 0:!this.shouldRender},...this.attachment}));get props(){return L(this.#o)}set props(e){M(this.#o,e)}},iE=class e{static create(t){return new e(t,tE.get())}opts;root;attachment;#e=A(()=>this.opts.disabled.current||this.root.opts.disabled.current);constructor(e,t){this.opts=e,this.root=t,this.attachment=CS(this.opts.ref),this.onclick=this.onclick.bind(this),this.onkeydown=this.onkeydown.bind(this)}onclick(e){if(!L(this.#e)){if(e.button!==0)return e.preventDefault();this.root.toggleOpen()}}onkeydown(e){L(this.#e)||(e.key===` `||e.key===`Enter`)&&(e.preventDefault(),this.root.toggleOpen())}#t=A(()=>({id:this.opts.id.current,type:`button`,disabled:L(this.#e),"aria-controls":this.root.contentId,"aria-expanded":wS(this.root.opts.open.current),"data-state":OS(this.root.opts.open.current),"data-disabled":ES(L(this.#e)),[eE.trigger]:``,onclick:this.onclick,onkeydown:this.onkeydown,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},aE=R(`<div><!></div>`);function oE(e,t){let n=gi();D(t,!0);let r=K(t,`children`,7),i=K(t,`child`,7),a=K(t,`id`,23,()=>lC(n)),o=K(t,`ref`,15,null),s=K(t,`open`,15,!1),c=K(t,`disabled`,7,!1),l=K(t,`onOpenChange`,7,$),u=K(t,`onOpenChangeComplete`,7,$),d=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`children`,`child`,`id`,`ref`,`open`,`disabled`,`onOpenChange`,`onOpenChangeComplete`]),f=nE.create({open:Q(()=>s(),e=>{s(e),l()(e)}),disabled:Q(()=>c()),id:Q(()=>a()),ref:Q(()=>o(),e=>o(e)),onOpenChangeComplete:Q(()=>u())}),p=A(()=>zx(d,f.props));var m={get children(){return r()},set children(e){r(e),k()},get child(){return i()},set child(e){i(e),k()},get id(){return a()},set id(e=lC(n)){a(e),k()},get ref(){return o()},set ref(e=null){o(e),k()},get open(){return s()},set open(e=!1){s(e),k()},get disabled(){return c()},set disabled(e=!1){c(e),k()},get onOpenChange(){return l()},set onOpenChange(e=$){l(e),k()},get onOpenChangeComplete(){return u()},set onOpenChangeComplete(e=$){u(e),k()}},h=z(),g=P(h),_=e=>{var t=z();H(P(t),i,()=>({props:L(p)})),B(e,t)},v=e=>{var t=aE();Ja(t,()=>({...L(p)})),H(N(t),()=>r()??w),E(t),B(e,t)};return U(g,e=>{i()?e(_):e(v,-1)}),B(e,h),O(m)}q(oE,{children:{},child:{},id:{},ref:{},open:{},disabled:{},onOpenChange:{},onOpenChangeComplete:{}},[],[],{mode:`open`});var sE=R(`<div><!></div>`);function cE(e,t){let n=gi();D(t,!0);let r=K(t,`child`,7),i=K(t,`ref`,15,null),a=K(t,`forceMount`,7,!1),o=K(t,`hiddenUntilFound`,7,!1),s=K(t,`children`,7),c=K(t,`id`,23,()=>lC(n)),l=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`child`,`ref`,`forceMount`,`hiddenUntilFound`,`children`,`id`]),u=rE.create({id:Q(()=>c()),forceMount:Q(()=>a()),hiddenUntilFound:Q(()=>o()),ref:Q(()=>i(),e=>i(e))}),d=A(()=>zx(l,u.props));var f={get child(){return r()},set child(e){r(e),k()},get ref(){return i()},set ref(e=null){i(e),k()},get forceMount(){return a()},set forceMount(e=!1){a(e),k()},get hiddenUntilFound(){return o()},set hiddenUntilFound(e=!1){o(e),k()},get children(){return s()},set children(e){s(e),k()},get id(){return c()},set id(e=lC(n)){c(e),k()}},p=z(),m=P(p),h=e=>{var t=z(),n=P(t);{let e=A(()=>({...u.snippetProps,props:L(d)}));H(n,r,()=>L(e))}B(e,t)},g=e=>{var t=sE();Ja(t,()=>({...L(d)})),H(N(t),()=>s()??w),E(t),B(e,t)};return U(m,e=>{r()?e(h):e(g,-1)}),B(e,p),O(f)}q(cE,{child:{},ref:{},forceMount:{},hiddenUntilFound:{},children:{},id:{}},[],[],{mode:`open`});var lE=R(`<button><!></button>`);function uE(e,t){let n=gi();D(t,!0);let r=K(t,`children`,7),i=K(t,`child`,7),a=K(t,`ref`,15,null),o=K(t,`id`,23,()=>lC(n)),s=K(t,`disabled`,7,!1),c=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`children`,`child`,`ref`,`id`,`disabled`]),l=iE.create({id:Q(()=>o()),ref:Q(()=>a(),e=>a(e)),disabled:Q(()=>s())}),u=A(()=>zx(c,l.props));var d={get children(){return r()},set children(e){r(e),k()},get child(){return i()},set child(e){i(e),k()},get ref(){return a()},set ref(e=null){a(e),k()},get id(){return o()},set id(e=lC(n)){o(e),k()},get disabled(){return s()},set disabled(e=!1){s(e),k()}},f=z(),p=P(f),m=e=>{var t=z();H(P(t),i,()=>({props:L(u)})),B(e,t)},h=e=>{var t=lE();Ja(t,()=>({...L(u)})),H(N(t),()=>r()??w),E(t),B(e,t)};return U(p,e=>{i()?e(m):e(h,-1)}),B(e,f),O(d)}q(uE,{children:{},child:{},ref:{},id:{},disabled:{}},[],[],{mode:`open`});var dE=[`top`,`right`,`bottom`,`left`],fE=Math.min,pE=Math.max,mE=Math.round,hE=Math.floor,gE=e=>({x:e,y:e}),_E={left:`right`,right:`left`,bottom:`top`,top:`bottom`};function vE(e,t,n){return pE(e,fE(t,n))}function yE(e,t){return typeof e==`function`?e(t):e}function bE(e){return e.split(`-`)[0]}function xE(e){return e.split(`-`)[1]}function SE(e){return e===`x`?`y`:`x`}function CE(e){return e===`y`?`height`:`width`}function wE(e){let t=e[0];return t===`t`||t===`b`?`y`:`x`}function TE(e){return SE(wE(e))}function EE(e,t,n){n===void 0&&(n=!1);let r=xE(e),i=TE(e),a=CE(i),o=i===`x`?r===(n?`end`:`start`)?`right`:`left`:r===`start`?`bottom`:`top`;return t.reference[a]>t.floating[a]&&(o=FE(o)),[o,FE(o)]}function DE(e){let t=FE(e);return[OE(e),t,OE(t)]}function OE(e){return e.includes(`start`)?e.replace(`start`,`end`):e.replace(`end`,`start`)}var kE=[`left`,`right`],AE=[`right`,`left`],jE=[`top`,`bottom`],ME=[`bottom`,`top`];function NE(e,t,n){switch(e){case`top`:case`bottom`:return n?t?AE:kE:t?kE:AE;case`left`:case`right`:return t?jE:ME;default:return[]}}function PE(e,t,n,r){let i=xE(e),a=NE(bE(e),n===`start`,r);return i&&(a=a.map(e=>e+`-`+i),t&&(a=a.concat(a.map(OE)))),a}function FE(e){let t=bE(e);return _E[t]+e.slice(t.length)}function IE(e){return{top:0,right:0,bottom:0,left:0,...e}}function LE(e){return typeof e==`number`?{top:e,right:e,bottom:e,left:e}:IE(e)}function RE(e){let{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}function zE(e,t,n){let{reference:r,floating:i}=e,a=wE(t),o=TE(t),s=CE(o),c=bE(t),l=a===`y`,u=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,f=r[s]/2-i[s]/2,p;switch(c){case`top`:p={x:u,y:r.y-i.height};break;case`bottom`:p={x:u,y:r.y+r.height};break;case`right`:p={x:r.x+r.width,y:d};break;case`left`:p={x:r.x-i.width,y:d};break;default:p={x:r.x,y:r.y}}switch(xE(t)){case`start`:p[o]-=f*(n&&l?-1:1);break;case`end`:p[o]+=f*(n&&l?-1:1);break}return p}async function BE(e,t){t===void 0&&(t={});let{x:n,y:r,platform:i,rects:a,elements:o,strategy:s}=e,{boundary:c=`clippingAncestors`,rootBoundary:l=`viewport`,elementContext:u=`floating`,altBoundary:d=!1,padding:f=0}=yE(t,e),p=LE(f),m=o[d?u===`floating`?`reference`:`floating`:u],h=RE(await i.getClippingRect({element:await(i.isElement==null?void 0:i.isElement(m))??!0?m:m.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(o.floating)),boundary:c,rootBoundary:l,strategy:s})),g=u===`floating`?{x:n,y:r,width:a.floating.width,height:a.floating.height}:a.reference,_=await(i.getOffsetParent==null?void 0:i.getOffsetParent(o.floating)),v=await(i.isElement==null?void 0:i.isElement(_))&&await(i.getScale==null?void 0:i.getScale(_))||{x:1,y:1},y=RE(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:o,rect:g,offsetParent:_,strategy:s}):g);return{top:(h.top-y.top+p.top)/v.y,bottom:(y.bottom-h.bottom+p.bottom)/v.y,left:(h.left-y.left+p.left)/v.x,right:(y.right-h.right+p.right)/v.x}}var VE=50,HE=async(e,t,n)=>{let{placement:r=`bottom`,strategy:i=`absolute`,middleware:a=[],platform:o}=n,s=o.detectOverflow?o:{...o,detectOverflow:BE},c=await(o.isRTL==null?void 0:o.isRTL(t)),l=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=zE(l,r,c),f=r,p=0,m={};for(let n=0;n<a.length;n++){let h=a[n];if(!h)continue;let{name:g,fn:_}=h,{x:v,y,data:b,reset:x}=await _({x:u,y:d,initialPlacement:r,placement:f,strategy:i,middlewareData:m,rects:l,platform:s,elements:{reference:e,floating:t}});u=v??u,d=y??d,m[g]={...m[g],...b},x&&p<VE&&(p++,typeof x==`object`&&(x.placement&&(f=x.placement),x.rects&&(l=x.rects===!0?await o.getElementRects({reference:e,floating:t,strategy:i}):x.rects),{x:u,y:d}=zE(l,f,c)),n=-1)}return{x:u,y:d,placement:f,strategy:i,middlewareData:m}},UE=e=>({name:`arrow`,options:e,async fn(t){let{x:n,y:r,placement:i,rects:a,platform:o,elements:s,middlewareData:c}=t,{element:l,padding:u=0}=yE(e,t)||{};if(l==null)return{};let d=LE(u),f={x:n,y:r},p=TE(i),m=CE(p),h=await o.getDimensions(l),g=p===`y`,_=g?`top`:`left`,v=g?`bottom`:`right`,y=g?`clientHeight`:`clientWidth`,b=a.reference[m]+a.reference[p]-f[p]-a.floating[m],x=f[p]-a.reference[p],S=await(o.getOffsetParent==null?void 0:o.getOffsetParent(l)),C=S?S[y]:0;(!C||!await(o.isElement==null?void 0:o.isElement(S)))&&(C=s.floating[y]||a.floating[m]);let ee=b/2-x/2,te=C/2-h[m]/2-1,ne=fE(d[_],te),re=fE(d[v],te),w=ne,ie=C-h[m]-re,ae=C/2-h[m]/2+ee,oe=vE(w,ae,ie),se=!c.arrow&&xE(i)!=null&&ae!==oe&&a.reference[m]/2-(ae<w?ne:re)-h[m]/2<0,ce=se?ae<w?ae-w:ae-ie:0;return{[p]:f[p]+ce,data:{[p]:oe,centerOffset:ae-oe-ce,...se&&{alignmentOffset:ce}},reset:se}}}),WE=function(e){return e===void 0&&(e={}),{name:`flip`,options:e,async fn(t){var n;let{placement:r,middlewareData:i,rects:a,initialPlacement:o,platform:s,elements:c}=t,{mainAxis:l=!0,crossAxis:u=!0,fallbackPlacements:d,fallbackStrategy:f=`bestFit`,fallbackAxisSideDirection:p=`none`,flipAlignment:m=!0,...h}=yE(e,t);if((n=i.arrow)!=null&&n.alignmentOffset)return{};let g=bE(r),_=wE(o),v=bE(o)===o,y=await(s.isRTL==null?void 0:s.isRTL(c.floating)),b=d||(v||!m?[FE(o)]:DE(o)),x=p!==`none`;!d&&x&&b.push(...PE(o,m,p,y));let S=[o,...b],C=await s.detectOverflow(t,h),ee=[],te=i.flip?.overflows||[];if(l&&ee.push(C[g]),u){let e=EE(r,a,y);ee.push(C[e[0]],C[e[1]])}if(te=[...te,{placement:r,overflows:ee}],!ee.every(e=>e<=0)){let e=(i.flip?.index||0)+1,t=S[e];if(t&&(!(u===`alignment`&&_!==wE(t))||te.every(e=>wE(e.placement)===_?e.overflows[0]>0:!0)))return{data:{index:e,overflows:te},reset:{placement:t}};let n=te.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0]?.placement;if(!n)switch(f){case`bestFit`:{let e=te.filter(e=>{if(x){let t=wE(e.placement);return t===_||t===`y`}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0]?.[0];e&&(n=e);break}case`initialPlacement`:n=o;break}if(r!==n)return{reset:{placement:n}}}return{}}}};function GE(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function KE(e){return dE.some(t=>e[t]>=0)}var qE=function(e){return e===void 0&&(e={}),{name:`hide`,options:e,async fn(t){let{rects:n,platform:r}=t,{strategy:i=`referenceHidden`,...a}=yE(e,t);switch(i){case`referenceHidden`:{let e=GE(await r.detectOverflow(t,{...a,elementContext:`reference`}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:KE(e)}}}case`escaped`:{let e=GE(await r.detectOverflow(t,{...a,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:KE(e)}}}default:return{}}}}},JE=new Set([`left`,`top`]);async function YE(e,t){let{placement:n,platform:r,elements:i}=e,a=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=bE(n),s=xE(n),c=wE(n)===`y`,l=JE.has(o)?-1:1,u=a&&c?-1:1,d=yE(t,e),{mainAxis:f,crossAxis:p,alignmentAxis:m}=typeof d==`number`?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&typeof m==`number`&&(p=s===`end`?m*-1:m),c?{x:p*u,y:f*l}:{x:f*l,y:p*u}}var XE=function(e){return e===void 0&&(e=0),{name:`offset`,options:e,async fn(t){var n;let{x:r,y:i,placement:a,middlewareData:o}=t,s=await YE(t,e);return a===o.offset?.placement&&(n=o.arrow)!=null&&n.alignmentOffset?{}:{x:r+s.x,y:i+s.y,data:{...s,placement:a}}}}},ZE=function(e){return e===void 0&&(e={}),{name:`shift`,options:e,async fn(t){let{x:n,y:r,placement:i,platform:a}=t,{mainAxis:o=!0,crossAxis:s=!1,limiter:c={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...l}=yE(e,t),u={x:n,y:r},d=await a.detectOverflow(t,l),f=wE(bE(i)),p=SE(f),m=u[p],h=u[f];if(o){let e=p===`y`?`top`:`left`,t=p===`y`?`bottom`:`right`,n=m+d[e],r=m-d[t];m=vE(n,m,r)}if(s){let e=f===`y`?`top`:`left`,t=f===`y`?`bottom`:`right`,n=h+d[e],r=h-d[t];h=vE(n,h,r)}let g=c.fn({...t,[p]:m,[f]:h});return{...g,data:{x:g.x-n,y:g.y-r,enabled:{[p]:o,[f]:s}}}}}},QE=function(e){return e===void 0&&(e={}),{options:e,fn(t){let{x:n,y:r,placement:i,rects:a,middlewareData:o}=t,{offset:s=0,mainAxis:c=!0,crossAxis:l=!0}=yE(e,t),u={x:n,y:r},d=wE(i),f=SE(d),p=u[f],m=u[d],h=yE(s,t),g=typeof h==`number`?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(c){let e=f===`y`?`height`:`width`,t=a.reference[f]-a.floating[e]+g.mainAxis,n=a.reference[f]+a.reference[e]-g.mainAxis;p<t?p=t:p>n&&(p=n)}if(l){let e=f===`y`?`width`:`height`,t=JE.has(bE(i)),n=a.reference[d]-a.floating[e]+(t&&o.offset?.[d]||0)+(t?0:g.crossAxis),r=a.reference[d]+a.reference[e]+(t?0:o.offset?.[d]||0)-(t?g.crossAxis:0);m<n?m=n:m>r&&(m=r)}return{[f]:p,[d]:m}}}},$E=function(e){return e===void 0&&(e={}),{name:`size`,options:e,async fn(t){var n,r;let{placement:i,rects:a,platform:o,elements:s}=t,{apply:c=()=>{},...l}=yE(e,t),u=await o.detectOverflow(t,l),d=bE(i),f=xE(i),p=wE(i)===`y`,{width:m,height:h}=a.floating,g,_;d===`top`||d===`bottom`?(g=d,_=f===(await(o.isRTL==null?void 0:o.isRTL(s.floating))?`start`:`end`)?`left`:`right`):(_=d,g=f===`end`?`top`:`bottom`);let v=h-u.top-u.bottom,y=m-u.left-u.right,b=fE(h-u[g],v),x=fE(m-u[_],y),S=!t.middlewareData.shift,C=b,ee=x;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(ee=y),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(C=v),S&&!f){let e=pE(u.left,0),t=pE(u.right,0),n=pE(u.top,0),r=pE(u.bottom,0);p?ee=m-2*(e!==0||t!==0?e+t:pE(u.left,u.right)):C=h-2*(n!==0||r!==0?n+r:pE(u.top,u.bottom))}await c({...t,availableWidth:ee,availableHeight:C});let te=await o.getDimensions(s.floating);return m!==te.width||h!==te.height?{reset:{rects:!0}}:{}}}};function eD(){return typeof window<`u`}function tD(e){return iD(e)?(e.nodeName||``).toLowerCase():`#document`}function nD(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function rD(e){return((iD(e)?e.ownerDocument:e.document)||window.document)?.documentElement}function iD(e){return eD()?e instanceof Node||e instanceof nD(e).Node:!1}function aD(e){return eD()?e instanceof Element||e instanceof nD(e).Element:!1}function oD(e){return eD()?e instanceof HTMLElement||e instanceof nD(e).HTMLElement:!1}function sD(e){return!eD()||typeof ShadowRoot>`u`?!1:e instanceof ShadowRoot||e instanceof nD(e).ShadowRoot}function cD(e){let{overflow:t,overflowX:n,overflowY:r,display:i}=yD(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&i!==`inline`&&i!==`contents`}function lD(e){return/^(table|td|th)$/.test(tD(e))}function uD(e){try{if(e.matches(`:popover-open`))return!0}catch{}try{return e.matches(`:modal`)}catch{return!1}}var dD=/transform|translate|scale|rotate|perspective|filter/,fD=/paint|layout|strict|content/,pD=e=>!!e&&e!==`none`,mD;function hD(e){let t=aD(e)?yD(e):e;return pD(t.transform)||pD(t.translate)||pD(t.scale)||pD(t.rotate)||pD(t.perspective)||!_D()&&(pD(t.backdropFilter)||pD(t.filter))||dD.test(t.willChange||``)||fD.test(t.contain||``)}function gD(e){let t=xD(e);for(;oD(t)&&!vD(t);){if(hD(t))return t;if(uD(t))return null;t=xD(t)}return null}function _D(){return mD??=typeof CSS<`u`&&CSS.supports&&CSS.supports(`-webkit-backdrop-filter`,`none`),mD}function vD(e){return/^(html|body|#document)$/.test(tD(e))}function yD(e){return nD(e).getComputedStyle(e)}function bD(e){return aD(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function xD(e){if(tD(e)===`html`)return e;let t=e.assignedSlot||e.parentNode||sD(e)&&e.host||rD(e);return sD(t)?t.host:t}function SD(e){let t=xD(e);return vD(t)?e.ownerDocument?e.ownerDocument.body:e.body:oD(t)&&cD(t)?t:SD(t)}function CD(e,t,n){t===void 0&&(t=[]),n===void 0&&(n=!0);let r=SD(e),i=r===e.ownerDocument?.body,a=nD(r);if(i){let e=wD(a);return t.concat(a,a.visualViewport||[],cD(r)?r:[],e&&n?CD(e):[])}else return t.concat(r,CD(r,[],n))}function wD(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function TD(e){let t=yD(e),n=parseFloat(t.width)||0,r=parseFloat(t.height)||0,i=oD(e),a=i?e.offsetWidth:n,o=i?e.offsetHeight:r,s=mE(n)!==a||mE(r)!==o;return s&&(n=a,r=o),{width:n,height:r,$:s}}function ED(e){return aD(e)?e:e.contextElement}function DD(e){let t=ED(e);if(!oD(t))return gE(1);let n=t.getBoundingClientRect(),{width:r,height:i,$:a}=TD(t),o=(a?mE(n.width):n.width)/r,s=(a?mE(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!s||!Number.isFinite(s))&&(s=1),{x:o,y:s}}var OD=gE(0);function kD(e){let t=nD(e);return!_D()||!t.visualViewport?OD:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function AD(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==nD(e)?!1:t}function jD(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);let i=e.getBoundingClientRect(),a=ED(e),o=gE(1);t&&(r?aD(r)&&(o=DD(r)):o=DD(e));let s=AD(a,n,r)?kD(a):gE(0),c=(i.left+s.x)/o.x,l=(i.top+s.y)/o.y,u=i.width/o.x,d=i.height/o.y;if(a){let e=nD(a),t=r&&aD(r)?nD(r):r,n=e,i=wD(n);for(;i&&r&&t!==n;){let e=DD(i),t=i.getBoundingClientRect(),r=yD(i),a=t.left+(i.clientLeft+parseFloat(r.paddingLeft))*e.x,o=t.top+(i.clientTop+parseFloat(r.paddingTop))*e.y;c*=e.x,l*=e.y,u*=e.x,d*=e.y,c+=a,l+=o,n=nD(i),i=wD(n)}}return RE({width:u,height:d,x:c,y:l})}function MD(e,t){let n=bD(e).scrollLeft;return t?t.left+n:jD(rD(e)).left+n}function ND(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-MD(e,n),y:n.top+t.scrollTop}}function PD(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e,a=i===`fixed`,o=rD(r),s=t?uD(t.floating):!1;if(r===o||s&&a)return n;let c={scrollLeft:0,scrollTop:0},l=gE(1),u=gE(0),d=oD(r);if((d||!d&&!a)&&((tD(r)!==`body`||cD(o))&&(c=bD(r)),d)){let e=jD(r);l=DD(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}let f=o&&!d&&!a?ND(o,c):gE(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-c.scrollLeft*l.x+u.x+f.x,y:n.y*l.y-c.scrollTop*l.y+u.y+f.y}}function FD(e){return Array.from(e.getClientRects())}function ID(e){let t=rD(e),n=bD(e),r=e.ownerDocument.body,i=pE(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=pE(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight),o=-n.scrollLeft+MD(e),s=-n.scrollTop;return yD(r).direction===`rtl`&&(o+=pE(t.clientWidth,r.clientWidth)-i),{width:i,height:a,x:o,y:s}}var LD=25;function RD(e,t){let n=nD(e),r=rD(e),i=n.visualViewport,a=r.clientWidth,o=r.clientHeight,s=0,c=0;if(i){a=i.width,o=i.height;let e=_D();(!e||e&&t===`fixed`)&&(s=i.offsetLeft,c=i.offsetTop)}let l=MD(r);if(l<=0){let e=r.ownerDocument,t=e.body,n=getComputedStyle(t),i=e.compatMode===`CSS1Compat`&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,o=Math.abs(r.clientWidth-t.clientWidth-i);o<=LD&&(a-=o)}else l<=LD&&(a+=l);return{width:a,height:o,x:s,y:c}}function zD(e,t){let n=jD(e,!0,t===`fixed`),r=n.top+e.clientTop,i=n.left+e.clientLeft,a=oD(e)?DD(e):gE(1);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:i*a.x,y:r*a.y}}function BD(e,t,n){let r;if(t===`viewport`)r=RD(e,n);else if(t===`document`)r=ID(rD(e));else if(aD(t))r=zD(t,n);else{let n=kD(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return RE(r)}function VD(e,t){let n=xD(e);return n===t||!aD(n)||vD(n)?!1:yD(n).position===`fixed`||VD(n,t)}function HD(e,t){let n=t.get(e);if(n)return n;let r=CD(e,[],!1).filter(e=>aD(e)&&tD(e)!==`body`),i=null,a=yD(e).position===`fixed`,o=a?xD(e):e;for(;aD(o)&&!vD(o);){let t=yD(o),n=hD(o);!n&&t.position===`fixed`&&(i=null),(a?!n&&!i:!n&&t.position===`static`&&i&&(i.position===`absolute`||i.position===`fixed`)||cD(o)&&!n&&VD(e,o))?r=r.filter(e=>e!==o):i=t,o=xD(o)}return t.set(e,r),r}function UD(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e,a=[...n===`clippingAncestors`?uD(t)?[]:HD(t,this._c):[].concat(n),r],o=BD(t,a[0],i),s=o.top,c=o.right,l=o.bottom,u=o.left;for(let e=1;e<a.length;e++){let n=BD(t,a[e],i);s=pE(n.top,s),c=fE(n.right,c),l=fE(n.bottom,l),u=pE(n.left,u)}return{width:c-u,height:l-s,x:u,y:s}}function WD(e){let{width:t,height:n}=TD(e);return{width:t,height:n}}function GD(e,t,n){let r=oD(t),i=rD(t),a=n===`fixed`,o=jD(e,!0,a,t),s={scrollLeft:0,scrollTop:0},c=gE(0);function l(){c.x=MD(i)}if(r||!r&&!a)if((tD(t)!==`body`||cD(i))&&(s=bD(t)),r){let e=jD(t,!0,a,t);c.x=e.x+t.clientLeft,c.y=e.y+t.clientTop}else i&&l();a&&!r&&i&&l();let u=i&&!r&&!a?ND(i,s):gE(0);return{x:o.left+s.scrollLeft-c.x-u.x,y:o.top+s.scrollTop-c.y-u.y,width:o.width,height:o.height}}function KD(e){return yD(e).position===`static`}function qD(e,t){if(!oD(e)||yD(e).position===`fixed`)return null;if(t)return t(e);let n=e.offsetParent;return rD(e)===n&&(n=n.ownerDocument.body),n}function JD(e,t){let n=nD(e);if(uD(e))return n;if(!oD(e)){let t=xD(e);for(;t&&!vD(t);){if(aD(t)&&!KD(t))return t;t=xD(t)}return n}let r=qD(e,t);for(;r&&lD(r)&&KD(r);)r=qD(r,t);return r&&vD(r)&&KD(r)&&!hD(r)?n:r||gD(e)||n}var YD=async function(e){let t=this.getOffsetParent||JD,n=this.getDimensions,r=await n(e.floating);return{reference:GD(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function XD(e){return yD(e).direction===`rtl`}var ZD={convertOffsetParentRelativeRectToViewportRelativeRect:PD,getDocumentElement:rD,getClippingRect:UD,getOffsetParent:JD,getElementRects:YD,getClientRects:FD,getDimensions:WD,getScale:DD,isElement:aD,isRTL:XD};function QD(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function $D(e,t){let n=null,r,i=rD(e);function a(){var e;clearTimeout(r),(e=n)==null||e.disconnect(),n=null}function o(s,c){s===void 0&&(s=!1),c===void 0&&(c=1),a();let l=e.getBoundingClientRect(),{left:u,top:d,width:f,height:p}=l;if(s||t(),!f||!p)return;let m=hE(d),h=hE(i.clientWidth-(u+f)),g=hE(i.clientHeight-(d+p)),_=hE(u),v={rootMargin:-m+`px `+-h+`px `+-g+`px `+-_+`px`,threshold:pE(0,fE(1,c))||1},y=!0;function b(t){let n=t[0].intersectionRatio;if(n!==c){if(!y)return o();n?o(!1,n):r=setTimeout(()=>{o(!1,1e-7)},1e3)}n===1&&!QD(l,e.getBoundingClientRect())&&o(),y=!1}try{n=new IntersectionObserver(b,{...v,root:i.ownerDocument})}catch{n=new IntersectionObserver(b,v)}n.observe(e)}return o(!0),a}function eO(e,t,n,r){r===void 0&&(r={});let{ancestorScroll:i=!0,ancestorResize:a=!0,elementResize:o=typeof ResizeObserver==`function`,layoutShift:s=typeof IntersectionObserver==`function`,animationFrame:c=!1}=r,l=ED(e),u=i||a?[...l?CD(l):[],...t?CD(t):[]]:[];u.forEach(e=>{i&&e.addEventListener(`scroll`,n,{passive:!0}),a&&e.addEventListener(`resize`,n)});let d=l&&s?$D(l,n):null,f=-1,p=null;o&&(p=new ResizeObserver(e=>{let[r]=e;r&&r.target===l&&p&&t&&(p.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var e;(e=p)==null||e.observe(t)})),n()}),l&&!c&&p.observe(l),t&&p.observe(t));let m,h=c?jD(e):null;c&&g();function g(){let t=jD(e);h&&!QD(h,t)&&n(),h=t,m=requestAnimationFrame(g)}return n(),()=>{var e;u.forEach(e=>{i&&e.removeEventListener(`scroll`,n),a&&e.removeEventListener(`resize`,n)}),d?.(),(e=p)==null||e.disconnect(),p=null,c&&cancelAnimationFrame(m)}}var tO=XE,nO=ZE,rO=WE,iO=$E,aO=qE,oO=UE,sO=QE,cO=(e,t,n)=>{let r=new Map,i={platform:ZD,...n},a={...i.platform,_c:r};return HE(e,t,{...i,platform:a})};function lO(e){return typeof e==`function`?e():e}function uO(e){return typeof window>`u`?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function dO(e,t){let n=uO(e);return Math.round(t*n)/n}function fO(e){return{[`--bits-${e}-content-transform-origin`]:`var(--bits-floating-transform-origin)`,[`--bits-${e}-content-available-width`]:`var(--bits-floating-available-width)`,[`--bits-${e}-content-available-height`]:`var(--bits-floating-available-height)`,[`--bits-${e}-anchor-width`]:`var(--bits-floating-anchor-width)`,[`--bits-${e}-anchor-height`]:`var(--bits-floating-anchor-height)`}}function pO(e){let t=e.whileElementsMounted,n=A(()=>lO(e.open)??!0),r=A(()=>lO(e.middleware)),i=A(()=>lO(e.transform)??!0),a=A(()=>lO(e.placement)??`bottom`),o=A(()=>lO(e.strategy)??`absolute`),s=A(()=>lO(e.sideOffset)??0),c=A(()=>lO(e.alignOffset)??0),l=e.reference,u=j(0),d=j(0),f=rx(null),p=j(Dn(L(o))),m=j(Dn(L(a))),h=j(Dn({})),g=j(!1),_=!1,v=A(()=>{let e=f.current?dO(f.current,L(u)):L(u),t=f.current?dO(f.current,L(d)):L(d);return L(i)?{position:L(p),left:`0`,top:`0`,transform:`translate(${e}px, ${t}px)`,...f.current&&uO(f.current)>=1.5&&{willChange:`transform`}}:{position:L(p),left:`${e}px`,top:`${t}px`}}),y;function b(){l.current===null||f.current===null||cO(l.current,f.current,{middleware:L(r),placement:L(a),strategy:L(o)}).then(e=>{let t=l.current;if(mO(t)){M(h,{...L(h),hide:{...L(h).hide,referenceHidden:!0}},!0);return}if(!L(n)&&L(u)!==0&&L(d)!==0){let t=Math.max(Math.abs(L(s)),Math.abs(L(c)),15);if(e.x<=t&&e.y<=t)return}M(u,e.x,!0),M(d,e.y,!0),M(p,e.strategy,!0),M(m,e.placement,!0),M(h,e.middlewareData,!0),M(g,!0)})}function x(){typeof y==`function`&&(y(),y=void 0)}function S(){if(x(),t===void 0){b();return}L(n)&&(l.current===null||f.current===null||(y=t(l.current,f.current,b)))}function C(){!L(n)&&f.current===null&&M(g,!1)}function ee(){return[L(r),L(a),L(o),L(s),L(c),L(n)]}return $n(()=>{t===void 0&&L(n)&&b()}),$n(S),$n(()=>{if(t!==void 0){if(ee(),!L(n)){_=!1;return}if(!L(g)){_=!1;return}if(!_){_=!0;return}b()}}),$n(C),$n(()=>x),{floating:f,reference:l,get strategy(){return L(p)},get placement(){return L(m)},get middlewareData(){return L(h)},get isPositioned(){return L(g)},get floatingStyles(){return L(v)},get update(){return b}}}function mO(e){return e instanceof Element?!e.isConnected||e instanceof HTMLElement&&e.hidden?!0:e.getClientRects().length===0:!1}var hO={top:`bottom`,right:`left`,bottom:`top`,left:`right`},gO=new Wx(`Floating.Root`),_O=new Wx(`Floating.Content`),vO=new Wx(`Floating.Root`),yO=class e{static create(t=!1){return t?vO.set(new e):gO.set(new e)}anchorNode=rx(null);customAnchorNode=rx(null);triggerNode=rx(null);constructor(){$n(()=>{this.customAnchorNode.current?typeof this.customAnchorNode.current==`string`?this.anchorNode.current=document.querySelector(this.customAnchorNode.current):this.anchorNode.current=this.customAnchorNode.current:this.anchorNode.current=this.triggerNode.current})}},bO=class e{static create(t,n=!1){return n?_O.set(new e(t,vO.get())):_O.set(new e(t,gO.get()))}opts;root;contentRef=rx(null);wrapperRef=rx(null);arrowRef=rx(null);contentAttachment=CS(this.contentRef);wrapperAttachment=CS(this.wrapperRef);arrowAttachment=CS(this.arrowRef);arrowId=rx(NT());#e=A(()=>{if(typeof this.opts.style==`string`)return jx(this.opts.style);if(!this.opts.style)return{}});#t=void 0;#n=new $x(()=>this.arrowRef.current??void 0);#r=A(()=>this.#n?.width??0);#i=A(()=>this.#n?.height??0);#a=A(()=>this.opts.side?.current+(this.opts.align.current===`center`?``:`-${this.opts.align.current}`));#o=A(()=>Array.isArray(this.opts.collisionBoundary.current)?this.opts.collisionBoundary.current:[this.opts.collisionBoundary.current]);#s=A(()=>L(this.#o).length>0);get hasExplicitBoundaries(){return L(this.#s)}set hasExplicitBoundaries(e){M(this.#s,e)}#c=A(()=>({padding:this.opts.collisionPadding.current,boundary:L(this.#o).filter(iC),altBoundary:this.hasExplicitBoundaries}));get detectOverflowOptions(){return L(this.#c)}set detectOverflowOptions(e){M(this.#c,e)}#l=j(void 0);#u=j(void 0);#d=j(void 0);#f=j(void 0);#p=A(()=>[tO({mainAxis:this.opts.sideOffset.current+L(this.#i),alignmentAxis:this.opts.alignOffset.current}),this.opts.avoidCollisions.current&&nO({mainAxis:!0,crossAxis:!1,limiter:this.opts.sticky.current===`partial`?sO():void 0,...this.detectOverflowOptions}),this.opts.avoidCollisions.current&&rO({...this.detectOverflowOptions}),iO({...this.detectOverflowOptions,apply:({rects:e,availableWidth:t,availableHeight:n})=>{let{width:r,height:i}=e.reference;M(this.#l,t,!0),M(this.#u,n,!0),M(this.#d,r,!0),M(this.#f,i,!0)}}),this.arrowRef.current&&oO({element:this.arrowRef.current,padding:this.opts.arrowPadding.current}),SO({arrowWidth:L(this.#r),arrowHeight:L(this.#i)}),this.opts.hideWhenDetached.current&&aO({strategy:`referenceHidden`,...this.detectOverflowOptions})].filter(Boolean));get middleware(){return L(this.#p)}set middleware(e){M(this.#p,e)}floating;#m=A(()=>wO(this.floating.placement));get placedSide(){return L(this.#m)}set placedSide(e){M(this.#m,e)}#h=A(()=>TO(this.floating.placement));get placedAlign(){return L(this.#h)}set placedAlign(e){M(this.#h,e)}#g=A(()=>this.floating.middlewareData.arrow?.x??0);get arrowX(){return L(this.#g)}set arrowX(e){M(this.#g,e)}#_=A(()=>this.floating.middlewareData.arrow?.y??0);get arrowY(){return L(this.#_)}set arrowY(e){M(this.#_,e)}#v=A(()=>this.floating.middlewareData.arrow?.centerOffset!==0);get cannotCenterArrow(){return L(this.#v)}set cannotCenterArrow(e){M(this.#v,e)}#y=j();get contentZIndex(){return L(this.#y)}set contentZIndex(e){M(this.#y,e,!0)}#b=A(()=>hO[this.placedSide]);get arrowBaseSide(){return L(this.#b)}set arrowBaseSide(e){M(this.#b,e)}#x=A(()=>({id:this.opts.wrapperId.current,"data-bits-floating-content-wrapper":``,style:{...this.floating.floatingStyles,transform:this.floating.isPositioned?this.floating.floatingStyles.transform:`translate(0, -200%)`,minWidth:`max-content`,zIndex:this.contentZIndex,"--bits-floating-transform-origin":`${this.floating.middlewareData.transformOrigin?.x} ${this.floating.middlewareData.transformOrigin?.y}`,"--bits-floating-available-width":`${L(this.#l)}px`,"--bits-floating-available-height":`${L(this.#u)}px`,"--bits-floating-anchor-width":`${L(this.#d)}px`,"--bits-floating-anchor-height":`${L(this.#f)}px`,...this.floating.middlewareData.hide?.referenceHidden&&{visibility:`hidden`,"pointer-events":`none`},...L(this.#e)},dir:this.opts.dir.current,...this.wrapperAttachment}));get wrapperProps(){return L(this.#x)}set wrapperProps(e){M(this.#x,e)}#S=A(()=>({"data-side":this.placedSide,"data-align":this.placedAlign,style:Ix({...L(this.#e)}),...this.contentAttachment}));get props(){return L(this.#S)}set props(e){M(this.#S,e)}#C=A(()=>({position:`absolute`,left:this.arrowX?`${this.arrowX}px`:void 0,top:this.arrowY?`${this.arrowY}px`:void 0,[this.arrowBaseSide]:0,"transform-origin":{top:``,right:`0 0`,bottom:`center 0`,left:`100% 0`}[this.placedSide],transform:{top:`translateY(100%)`,right:`translateY(50%) rotate(90deg) translateX(-50%)`,bottom:`rotate(180deg)`,left:`translateY(50%) rotate(-90deg) translateX(50%)`}[this.placedSide],visibility:this.cannotCenterArrow?`hidden`:void 0}));get arrowStyle(){return L(this.#C)}set arrowStyle(e){M(this.#C,e)}constructor(e,t){this.opts=e,this.root=t,this.#t=e.updatePositionStrategy,e.customAnchor&&(this.root.customAnchorNode.current=e.customAnchor.current),Jx(()=>e.customAnchor.current,e=>{this.root.customAnchorNode.current=e}),this.floating=pO({strategy:()=>this.opts.strategy.current,placement:()=>L(this.#a),middleware:()=>this.middleware,reference:this.root.anchorNode,whileElementsMounted:(...e)=>eO(...e,{animationFrame:this.#t?.current===`always`}),open:()=>this.opts.enabled.current,sideOffset:()=>this.opts.sideOffset.current,alignOffset:()=>this.opts.alignOffset.current}),$n(()=>{this.floating.isPositioned&&this.opts.onPlaced?.current()}),Jx(()=>this.contentRef.current,e=>{if(!e||!this.opts.enabled.current)return;let t=bS(e),n=t.requestAnimationFrame(()=>{if(this.contentRef.current!==e||!this.opts.enabled.current)return;let n=t.getComputedStyle(e).zIndex;n!==this.contentZIndex&&(this.contentZIndex=n)});return()=>{t.cancelAnimationFrame(n)}}),$n(()=>{this.floating.floating.current=this.wrapperRef.current})}},xO=class e{static create(t,n=!1){return n?new e(t,vO.get()):new e(t,gO.get())}opts;root;constructor(e,t){this.opts=e,this.root=t,e.virtualEl&&e.virtualEl.current?t.triggerNode=ex(e.virtualEl.current):t.triggerNode=e.ref}};function SO(e){return{name:`transformOrigin`,options:e,fn(t){let{placement:n,rects:r,middlewareData:i}=t,a=i.arrow?.centerOffset!==0,o=a?0:e.arrowWidth,s=a?0:e.arrowHeight,[c,l]=CO(n),u={start:`0%`,center:`50%`,end:`100%`}[l],d=(i.arrow?.x??0)+o/2,f=(i.arrow?.y??0)+s/2,p=``,m=``;return c===`bottom`?(p=a?u:`${d}px`,m=`${-s}px`):c===`top`?(p=a?u:`${d}px`,m=`${r.floating.height+s}px`):c===`right`?(p=`${-s}px`,m=a?u:`${f}px`):c===`left`&&(p=`${r.floating.width+s}px`,m=a?u:`${f}px`),{data:{x:p,y:m}}}}}function CO(e){let[t,n=`center`]=e.split(`-`);return[t,n]}function wO(e){return CO(e)[0]}function TO(e){return CO(e)[1]}function EO(e,t){D(t,!0);let n=K(t,`children`,7),r=K(t,`tooltip`,7,!1);yO.create(r());var i={get children(){return n()},set children(e){n(e),k()},get tooltip(){return r()},set tooltip(e=!1){r(e),k()}},a=z();return H(P(a),()=>n()??w),B(e,a),O(i)}q(EO,{children:{},tooltip:{}},[],[],{mode:`open`});var DO=[NS,zS,PS,WS,IS,LS,`Alt`,VS,RS,`F1`,`F2`,`F3`,`F4`,`F5`,`F6`,`F7`,`F8`,`F9`,`F10`,`F11`,`F12`],OO=[MS,US,BS],kO=[FS,HS,`End`],AO=[...OO,...kO],jO=jS({component:`select`,parts:[`trigger`,`content`,`item`,`viewport`,`scroll-up-button`,`scroll-down-button`,`group`,`group-label`,`separator`,`arrow`,`input`,`content-wrapper`,`item-text`,`value`]}),MO=new Wx(`Select.Root | Combobox.Root`);new Wx(`Select.Group | Combobox.Group`);var NO=new Wx(`Select.Content | Combobox.Content`),PO=class{opts;#e=j(!1);get touchedInput(){return L(this.#e)}set touchedInput(e){M(this.#e,e,!0)}#t=j(null);get inputNode(){return L(this.#t)}set inputNode(e){M(this.#t,e,!0)}#n=j(null);get contentNode(){return L(this.#n)}set contentNode(e){M(this.#n,e,!0)}contentPresence;#r=j(null);get viewportNode(){return L(this.#r)}set viewportNode(e){M(this.#r,e,!0)}#i=j(null);get triggerNode(){return L(this.#i)}set triggerNode(e){M(this.#i,e,!0)}#a=j(``);get valueId(){return L(this.#a)}set valueId(e){M(this.#a,e,!0)}#o=j(null);get highlightedNode(){return L(this.#o)}set highlightedNode(e){M(this.#o,e,!0)}#s=A(()=>this.highlightedNode?this.highlightedNode.getAttribute(`data-value`):null);get highlightedValue(){return L(this.#s)}set highlightedValue(e){M(this.#s,e)}#c=A(()=>{if(this.highlightedNode)return this.highlightedNode.id});get highlightedId(){return L(this.#c)}set highlightedId(e){M(this.#c,e)}#l=A(()=>this.highlightedNode?this.highlightedNode.getAttribute(`data-label`):null);get highlightedLabel(){return L(this.#l)}set highlightedLabel(e){M(this.#l,e)}isUsingKeyboard=!1;isCombobox=!1;domContext=new SS(()=>null);constructor(e){this.opts=e,this.isCombobox=e.isCombobox,this.contentPresence=new cC({ref:Q(()=>this.contentNode),open:this.opts.open,onComplete:()=>{this.opts.onOpenChangeComplete.current(this.opts.open.current)}}),tr(()=>{this.opts.open.current||this.setHighlightedNode(null)})}setHighlightedNode(e,t=!1){this.highlightedNode=e,e&&(this.isUsingKeyboard||t)&&e.scrollIntoView({block:this.opts.scrollAlignment.current})}getCandidateNodes(){let e=this.contentNode;return e?Array.from(e.querySelectorAll(`[${this.getBitsAttr(`item`)}]:not([data-disabled])`)):[]}setHighlightedToFirstCandidate(e=!1){this.setHighlightedNode(null);let t=this.getCandidateNodes();if(t.length){if(this.viewportNode){let e=this.viewportNode.getBoundingClientRect();t=t.filter(t=>{if(!this.viewportNode)return!1;let n=t.getBoundingClientRect();return n.right<=e.right&&n.left>=e.left&&n.bottom<=e.bottom&&n.top>=e.top})}this.setHighlightedNode(t[0],e)}}getNodeByValue(e){return this.getCandidateNodes().find(t=>t.dataset.value===e)??null}setOpen(e){this.opts.open.current=e}toggleOpen(){this.opts.open.current=!this.opts.open.current}handleOpen(){this.setOpen(!0)}handleClose(){this.setHighlightedNode(null),this.setOpen(!1)}toggleMenu(){this.toggleOpen()}getBitsAttr=e=>jO.getAttr(e,this.isCombobox?`combobox`:void 0)},FO=class extends PO{opts;isMulti=!1;#e=A(()=>this.opts.value.current!==``);get hasValue(){return L(this.#e)}set hasValue(e){M(this.#e,e)}#t=A(()=>this.opts.items.current.length?this.opts.items.current.find(e=>e.value===this.opts.value.current)?.label??``:``);get currentLabel(){return L(this.#t)}set currentLabel(e){M(this.#t,e)}#n=A(()=>this.opts.items.current.length?this.opts.items.current.filter(e=>!e.disabled).map(e=>e.label):[]);get candidateLabels(){return L(this.#n)}set candidateLabels(e){M(this.#n,e)}#r=A(()=>!(this.isMulti||this.opts.items.current.length===0));get dataTypeaheadEnabled(){return L(this.#r)}set dataTypeaheadEnabled(e){M(this.#r,e)}constructor(e){super(e),this.opts=e,$n(()=>{!this.opts.open.current&&this.highlightedNode&&this.setHighlightedNode(null)}),Jx(()=>this.opts.open.current,()=>{this.opts.open.current&&this.setInitialHighlightedNode()})}includesItem(e){return this.opts.value.current===e}toggleItem(e,t=e){let n=this.includesItem(e)?``:e;this.opts.value.current=n,n!==``&&(this.opts.inputValue.current=t)}setInitialHighlightedNode(){lS(()=>{if(!(this.highlightedNode&&this.domContext.getDocument().contains(this.highlightedNode))){if(this.opts.value.current!==``){let e=this.getNodeByValue(this.opts.value.current);if(e){this.setHighlightedNode(e,!0);return}}this.setHighlightedToFirstCandidate(!0)}})}},IO=class extends PO{opts;isMulti=!0;#e=A(()=>this.opts.value.current.length>0);get hasValue(){return L(this.#e)}set hasValue(e){M(this.#e,e)}constructor(e){super(e),this.opts=e,$n(()=>{!this.opts.open.current&&this.highlightedNode&&this.setHighlightedNode(null)}),Jx(()=>this.opts.open.current,()=>{this.opts.open.current&&this.setInitialHighlightedNode()})}includesItem(e){return this.opts.value.current.includes(e)}toggleItem(e,t=e){this.includesItem(e)?this.opts.value.current=this.opts.value.current.filter(t=>t!==e):this.opts.value.current=[...this.opts.value.current,e],this.opts.inputValue.current=t}setInitialHighlightedNode(){lS(()=>{if(this.domContext&&!(this.highlightedNode&&this.domContext.getDocument().contains(this.highlightedNode))){if(this.opts.value.current.length&&this.opts.value.current[0]!==``){let e=this.getNodeByValue(this.opts.value.current[0]);if(e){this.setHighlightedNode(e,!0);return}}this.setHighlightedToFirstCandidate(!0)}})}},LO=class{static create(e){let{type:t,...n}=e,r=t===`single`?new FO(n):new IO(n);return MO.set(r)}},RO=class e{static create(t){return new e(t,MO.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=CS(e.ref,e=>this.root.inputNode=e),this.root.domContext=new SS(e.ref),this.onkeydown=this.onkeydown.bind(this),this.oninput=this.oninput.bind(this),Jx([()=>this.root.opts.value.current,()=>this.opts.clearOnDeselect.current],([e,t],[n])=>{t&&(Array.isArray(e)&&Array.isArray(n)?e.length===0&&n.length!==0&&(this.root.opts.inputValue.current=``):e===``&&n!==``&&(this.root.opts.inputValue.current=``))})}onkeydown(e){if(this.root.isUsingKeyboard=!0,e.key!==`Escape`){if((e.key===`ArrowUp`||e.key===`ArrowDown`)&&e.preventDefault(),!this.root.opts.open.current){if(DO.includes(e.key)||e.key===`Tab`||e.key===`Backspace`&&this.root.opts.inputValue.current===``||(this.root.handleOpen(),this.root.hasValue))return;let t=this.root.getCandidateNodes();if(!t.length)return;if(e.key===`ArrowDown`){let e=t[0];this.root.setHighlightedNode(e)}else if(e.key===`ArrowUp`){let e=t[t.length-1];this.root.setHighlightedNode(e)}return}if(e.key===`Tab`){this.root.handleClose();return}if(e.key===`Enter`&&!e.isComposing){e.preventDefault();let t=this.root.highlightedValue===this.root.opts.value.current;if(!this.root.opts.allowDeselect.current&&t&&!this.root.isMulti){this.root.handleClose();return}this.root.highlightedValue&&this.root.highlightedNode&&this.root.highlightedNode.isConnected&&this.root.toggleItem(this.root.highlightedValue,this.root.highlightedLabel??void 0),!this.root.isMulti&&!t&&this.root.handleClose()}if(e.key===`ArrowUp`&&e.altKey&&this.root.handleClose(),AO.includes(e.key)){e.preventDefault();let t=this.root.getCandidateNodes(),n=this.root.highlightedNode,r=n?t.indexOf(n):-1,i=this.root.opts.loop.current,a;if(e.key===`ArrowDown`?a=Aw(t,r,i):e.key===`ArrowUp`?a=jw(t,r,i):e.key===`PageDown`?a=Mw(t,r,10,i):e.key===`PageUp`?a=Nw(t,r,10,i):e.key===`Home`?a=t[0]:e.key===`End`&&(a=t[t.length-1]),!a)return;this.root.setHighlightedNode(a);return}DO.includes(e.key)||this.root.highlightedNode||this.root.setHighlightedToFirstCandidate()}}oninput(e){this.root.opts.inputValue.current=e.currentTarget.value,this.root.setHighlightedToFirstCandidate()}#e=A(()=>({id:this.opts.id.current,role:`combobox`,disabled:this.root.opts.disabled.current?!0:void 0,"aria-activedescendant":this.root.highlightedId,"aria-autocomplete":`list`,"aria-expanded":wS(this.root.opts.open.current),"data-state":OS(this.root.opts.open.current),"data-disabled":ES(this.root.opts.disabled.current),onkeydown:this.onkeydown,oninput:this.oninput,[this.root.getBitsAttr(`input`)]:``,...this.attachment}));get props(){return L(this.#e)}set props(e){M(this.#e,e)}},zO=class e{static create(t){return new e(t,MO.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=CS(e.ref),this.onkeydown=this.onkeydown.bind(this),this.onpointerdown=this.onpointerdown.bind(this)}onkeydown(e){this.root.domContext&&(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),this.root.domContext.getActiveElement()!==this.root.inputNode&&this.root.inputNode?.focus(),this.root.toggleMenu())}onpointerdown(e){this.root.opts.disabled.current||!this.root.domContext||(e.preventDefault(),this.root.domContext.getActiveElement()!==this.root.inputNode&&this.root.inputNode?.focus(),this.root.toggleMenu())}#e=A(()=>({id:this.opts.id.current,disabled:this.root.opts.disabled.current?!0:void 0,"aria-haspopup":`listbox`,"data-state":OS(this.root.opts.open.current),"data-disabled":ES(this.root.opts.disabled.current),[this.root.getBitsAttr(`trigger`)]:``,onpointerdown:this.onpointerdown,onkeydown:this.onkeydown,...this.attachment}));get props(){return L(this.#e)}set props(e){M(this.#e,e)}},BO=class e{static create(t){return NO.set(new e(t,MO.get()))}opts;root;attachment;#e=j(!1);get isPositioned(){return L(this.#e)}set isPositioned(e){M(this.#e,e,!0)}domContext;constructor(e,t){this.opts=e,this.root=t,this.attachment=CS(e.ref,e=>this.root.contentNode=e),this.domContext=new SS(this.opts.ref),this.root.domContext===null&&(this.root.domContext=this.domContext),oS(()=>{this.root.contentNode=null,this.isPositioned=!1}),Jx(()=>this.root.opts.open.current,()=>{this.root.opts.open.current||(this.isPositioned=!1)}),this.onpointermove=this.onpointermove.bind(this)}onpointermove(e){this.root.isUsingKeyboard=!1}#t=A(()=>fO(this.root.isCombobox?`combobox`:`select`));onInteractOutside=e=>{if(e.target===this.root.triggerNode||e.target===this.root.inputNode){e.preventDefault();return}this.opts.onInteractOutside.current(e),!e.defaultPrevented&&this.root.handleClose()};onEscapeKeydown=e=>{this.opts.onEscapeKeydown.current(e),!e.defaultPrevented&&this.root.handleClose()};onOpenAutoFocus=e=>{e.preventDefault()};onCloseAutoFocus=e=>{e.preventDefault()};get shouldRender(){return this.root.contentPresence.shouldRender}#n=A(()=>({open:this.root.opts.open.current}));get snippetProps(){return L(this.#n)}set snippetProps(e){M(this.#n,e)}#r=A(()=>({id:this.opts.id.current,role:`listbox`,"aria-multiselectable":this.root.isMulti?`true`:void 0,"data-state":OS(this.root.opts.open.current),[this.root.getBitsAttr(`content`)]:``,style:{display:`flex`,flexDirection:`column`,outline:`none`,boxSizing:`border-box`,pointerEvents:`auto`,...L(this.#t)},onpointermove:this.onpointermove,...this.attachment}));get props(){return L(this.#r)}set props(e){M(this.#r,e)}popperProps={onInteractOutside:this.onInteractOutside,onEscapeKeydown:this.onEscapeKeydown,onOpenAutoFocus:this.onOpenAutoFocus,onCloseAutoFocus:this.onCloseAutoFocus,trapFocus:!1,loop:!1,onPlaced:()=>{this.root.opts.open.current&&(this.isPositioned=!0)}}},VO=class e{static create(t){return new e(t,MO.get())}opts;root;attachment;#e=A(()=>this.root.includesItem(this.opts.value.current));get isSelected(){return L(this.#e)}set isSelected(e){M(this.#e,e)}#t=A(()=>this.root.highlightedValue===this.opts.value.current);get isHighlighted(){return L(this.#t)}set isHighlighted(e){M(this.#t,e)}prevHighlighted=new eS(()=>this.isHighlighted);#n=j(!1);get mounted(){return L(this.#n)}set mounted(e){M(this.#n,e,!0)}constructor(e,t){this.opts=e,this.root=t,this.attachment=CS(e.ref),Jx([()=>this.isHighlighted,()=>this.prevHighlighted.current],()=>{this.isHighlighted?this.opts.onHighlight.current():this.prevHighlighted.current&&this.opts.onUnhighlight.current()}),Jx(()=>this.mounted,()=>{this.mounted&&this.root.setInitialHighlightedNode()}),this.onpointerdown=this.onpointerdown.bind(this),this.onpointerup=this.onpointerup.bind(this),this.onpointermove=this.onpointermove.bind(this)}handleSelect(){if(this.opts.disabled.current)return;let e=this.opts.value.current===this.root.opts.value.current;if(!this.root.opts.allowDeselect.current&&e&&!this.root.isMulti){this.root.handleClose();return}this.root.toggleItem(this.opts.value.current,this.opts.label.current),!this.root.isMulti&&!e&&this.root.handleClose()}#r=A(()=>({selected:this.isSelected,highlighted:this.isHighlighted}));get snippetProps(){return L(this.#r)}set snippetProps(e){M(this.#r,e)}onpointerdown(e){e.preventDefault()}onpointerup(e){if(!(e.defaultPrevented||!this.opts.ref.current)){if(e.pointerType===`touch`&&!QS){ri(this.opts.ref.current,`click`,()=>{this.handleSelect(),this.root.setHighlightedNode(this.opts.ref.current)},{once:!0});return}e.preventDefault(),this.handleSelect(),e.pointerType===`touch`&&this.root.setHighlightedNode(this.opts.ref.current)}}onpointermove(e){e.pointerType!==`touch`&&this.root.highlightedNode!==this.opts.ref.current&&this.root.setHighlightedNode(this.opts.ref.current)}#i=A(()=>({id:this.opts.id.current,role:`option`,"aria-selected":this.root.includesItem(this.opts.value.current)?`true`:void 0,"data-value":this.opts.value.current,"data-disabled":ES(this.opts.disabled.current),"data-highlighted":this.root.highlightedValue===this.opts.value.current&&!this.opts.disabled.current?``:void 0,"data-selected":this.root.includesItem(this.opts.value.current)?``:void 0,"data-label":this.opts.label.current,[this.root.getBitsAttr(`item`)]:``,onpointermove:this.onpointermove,onpointerdown:this.onpointerdown,onpointerup:this.onpointerup,...this.attachment}));get props(){return L(this.#i)}set props(e){M(this.#i,e)}},HO=class e{static create(t){return new e(t,MO.get())}opts;root;#e=A(()=>this.root.opts.name.current!==``);get shouldRender(){return L(this.#e)}set shouldRender(e){M(this.#e,e)}constructor(e,t){this.opts=e,this.root=t,this.onfocus=this.onfocus.bind(this)}onfocus(e){e.preventDefault(),this.root.isCombobox?this.root.inputNode?.focus():this.root.triggerNode?.focus()}#t=A(()=>({disabled:DS(this.root.opts.disabled.current),required:DS(this.root.opts.required.current),name:this.root.opts.name.current,value:this.opts.value.current,onfocus:this.onfocus}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},UO=class e{static create(t){return new e(t,NO.get())}opts;content;root;attachment;#e=j(0);get prevScrollTop(){return L(this.#e)}set prevScrollTop(e){M(this.#e,e,!0)}constructor(e,t){this.opts=e,this.content=t,this.root=t.root,this.attachment=CS(e.ref,e=>{this.root.viewportNode=e})}#t=A(()=>({id:this.opts.id.current,role:`presentation`,[this.root.getBitsAttr(`viewport`)]:``,style:{position:`relative`,flex:1,overflow:`auto`},...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},WO=class{opts;content;root;attachment;autoScrollTimer=null;userScrollTimer=-1;isUserScrolling=!1;onAutoScroll=$;#e=j(!1);get mounted(){return L(this.#e)}set mounted(e){M(this.#e,e,!0)}constructor(e,t){this.opts=e,this.content=t,this.root=t.root,this.attachment=CS(e.ref),Jx([()=>this.mounted],()=>{if(!this.mounted){this.isUserScrolling=!1;return}this.isUserScrolling}),$n(()=>{this.mounted||this.clearAutoScrollInterval()}),this.onpointerdown=this.onpointerdown.bind(this),this.onpointermove=this.onpointermove.bind(this),this.onpointerleave=this.onpointerleave.bind(this)}handleUserScroll(){this.content.domContext.clearTimeout(this.userScrollTimer),this.isUserScrolling=!0,this.userScrollTimer=this.content.domContext.setTimeout(()=>{this.isUserScrolling=!1},200)}clearAutoScrollInterval(){this.autoScrollTimer!==null&&(this.content.domContext.clearTimeout(this.autoScrollTimer),this.autoScrollTimer=null)}onpointerdown(e){if(this.autoScrollTimer!==null)return;let t=e=>{this.onAutoScroll(),this.autoScrollTimer=this.content.domContext.setTimeout(()=>t(e+1),this.opts.delay.current(e))};this.autoScrollTimer=this.content.domContext.setTimeout(()=>t(1),this.opts.delay.current(0))}onpointermove(e){this.onpointerdown(e)}onpointerleave(e){this.clearAutoScrollInterval()}#t=A(()=>({id:this.opts.id.current,"aria-hidden":TS(!0),style:{flexShrink:0},onpointerdown:this.onpointerdown,onpointermove:this.onpointermove,onpointerleave:this.onpointerleave,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},GO=class e{static create(t){return new e(new WO(t,NO.get()))}scrollButtonState;content;root;#e=j(!1);get canScrollDown(){return L(this.#e)}set canScrollDown(e){M(this.#e,e,!0)}scrollIntoViewTimer=null;constructor(e){this.scrollButtonState=e,this.content=e.content,this.root=e.root,this.scrollButtonState.onAutoScroll=this.handleAutoScroll,Jx([()=>this.root.viewportNode,()=>this.content.isPositioned],()=>{if(!(!this.root.viewportNode||!this.content.isPositioned))return this.handleScroll(!0),ri(this.root.viewportNode,`scroll`,()=>this.handleScroll())}),Jx([()=>this.root.opts.inputValue.current,()=>this.root.viewportNode,()=>this.content.isPositioned],()=>{!this.root.viewportNode||!this.content.isPositioned||this.handleScroll(!0)}),Jx(()=>this.scrollButtonState.mounted,()=>{this.scrollButtonState.mounted&&(this.scrollIntoViewTimer&&clearTimeout(this.scrollIntoViewTimer),this.scrollIntoViewTimer=cS(5,()=>{this.root.highlightedNode?.scrollIntoView({block:this.root.opts.scrollAlignment.current})}))})}handleScroll=(e=!1)=>{if(e||this.scrollButtonState.handleUserScroll(),!this.root.viewportNode)return;let t=this.root.viewportNode.scrollHeight-this.root.viewportNode.clientHeight,n=Number.parseInt(getComputedStyle(this.root.viewportNode).paddingTop,10);this.canScrollDown=Math.ceil(this.root.viewportNode.scrollTop)<t-n};handleAutoScroll=()=>{let e=this.root.viewportNode,t=this.root.highlightedNode;!e||!t||(e.scrollTop+=t.offsetHeight)};#t=A(()=>({...this.scrollButtonState.props,[this.root.getBitsAttr(`scroll-down-button`)]:``}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},KO=class e{static create(t){return new e(new WO(t,NO.get()))}scrollButtonState;content;root;#e=j(!1);get canScrollUp(){return L(this.#e)}set canScrollUp(e){M(this.#e,e,!0)}constructor(e){this.scrollButtonState=e,this.content=e.content,this.root=e.root,this.scrollButtonState.onAutoScroll=this.handleAutoScroll,Jx([()=>this.root.viewportNode,()=>this.content.isPositioned],()=>{if(!(!this.root.viewportNode||!this.content.isPositioned))return this.handleScroll(!0),ri(this.root.viewportNode,`scroll`,()=>this.handleScroll())})}handleScroll=(e=!1)=>{if(e||this.scrollButtonState.handleUserScroll(),!this.root.viewportNode)return;let t=Number.parseInt(getComputedStyle(this.root.viewportNode).paddingTop,10);this.canScrollUp=this.root.viewportNode.scrollTop-t>.1};handleAutoScroll=()=>{!this.root.viewportNode||!this.root.highlightedNode||(this.root.viewportNode.scrollTop=this.root.viewportNode.scrollTop-this.root.highlightedNode.offsetHeight)};#t=A(()=>({...this.scrollButtonState.props,[this.root.getBitsAttr(`scroll-up-button`)]:``}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}};function qO(e,t){D(t,!0);let n=K(t,`value`,15),r=K(t,`autocomplete`,7),i=HO.create({value:Q(()=>n())});var a={get value(){return n()},set value(e){n(e),k()},get autocomplete(){return r()},set autocomplete(e){r(e),k()}},o=z(),s=P(o),c=e=>{$T(e,mo(()=>i.props,{get autocomplete(){return r()},get value(){return n()},set value(e){n(e)}}))};return U(s,e=>{i.shouldRender&&e(c)}),B(e,o),O(a)}q(qO,{value:{},autocomplete:{}},[],[],{mode:`open`});var JO=R(`<!> <!>`,1);function YO(e,t){D(t,!0);let n=K(t,`value`,15),r=K(t,`onValueChange`,7,$),i=K(t,`name`,7,``),a=K(t,`disabled`,7,!1),o=K(t,`type`,7),s=K(t,`open`,15,!1),c=K(t,`onOpenChange`,7,$),l=K(t,`onOpenChangeComplete`,7,$),u=K(t,`loop`,7,!1),d=K(t,`scrollAlignment`,7,`nearest`),f=K(t,`required`,7,!1),p=K(t,`items`,23,()=>[]),m=K(t,`allowDeselect`,7,!0),h=K(t,`inputValue`,7,``),g=K(t,`children`,7);n()===void 0&&n(o()===`single`?``:[]),Jx.pre(()=>n(),()=>{n()===void 0&&n(o()===`single`?``:[])});let _=LO.create({type:o(),value:Q(()=>n(),e=>{n(e),r()(e)}),disabled:Q(()=>a()),required:Q(()=>f()),open:Q(()=>s(),e=>{s(e),c()(e)}),loop:Q(()=>u()),scrollAlignment:Q(()=>d()),name:Q(()=>i()),isCombobox:!0,items:Q(()=>p()),allowDeselect:Q(()=>m()),inputValue:Q(()=>h(),e=>h(e)),onOpenChangeComplete:Q(()=>l())});var v={get value(){return n()},set value(e){n(e),k()},get onValueChange(){return r()},set onValueChange(e=$){r(e),k()},get name(){return i()},set name(e=``){i(e),k()},get disabled(){return a()},set disabled(e=!1){a(e),k()},get type(){return o()},set type(e){o(e),k()},get open(){return s()},set open(e=!1){s(e),k()},get onOpenChange(){return c()},set onOpenChange(e=$){c(e),k()},get onOpenChangeComplete(){return l()},set onOpenChangeComplete(e=$){l(e),k()},get loop(){return u()},set loop(e=!1){u(e),k()},get scrollAlignment(){return d()},set scrollAlignment(e=`nearest`){d(e),k()},get required(){return f()},set required(e=!1){f(e),k()},get items(){return p()},set items(e=[]){p(e),k()},get allowDeselect(){return m()},set allowDeselect(e=!0){m(e),k()},get inputValue(){return h()},set inputValue(e=``){h(e),k()},get children(){return g()},set children(e){g(e),k()}},y=JO(),b=P(y);EO(b,{children:(e,t)=>{var n=z();H(P(n),()=>g()??w),B(e,n)},$$slots:{default:!0}});var x=F(b,2),S=e=>{var t=z(),n=P(t),r=e=>{var t=z();Xi(P(t),16,()=>_.opts.value.current,e=>e,(e,t)=>{qO(e,{get value(){return t}})}),B(e,t)};U(n,e=>{_.opts.value.current.length&&e(r)}),B(e,t)},C=A(()=>Array.isArray(_.opts.value.current)),ee=e=>{qO(e,{get value(){return _.opts.value.current},set value(e){_.opts.value.current=e}})};return U(x,e=>{L(C)?e(S):e(ee,-1)}),B(e,y),O(v)}q(YO,{value:{},onValueChange:{},name:{},disabled:{},type:{},open:{},onOpenChange:{},onOpenChangeComplete:{},loop:{},scrollAlignment:{},required:{},items:{},allowDeselect:{},inputValue:{},children:{}},[],[],{mode:`open`});function XO(e,t){D(t,!0);let n=K(t,`id`,7),r=K(t,`children`,7),i=K(t,`virtualEl`,7),a=K(t,`ref`,7),o=K(t,`tooltip`,7,!1);xO.create({id:Q(()=>n()),virtualEl:Q(()=>i()),ref:a()},o());var s={get id(){return n()},set id(e){n(e),k()},get children(){return r()},set children(e){r(e),k()},get virtualEl(){return i()},set virtualEl(e){i(e),k()},get ref(){return a()},set ref(e){a(e),k()},get tooltip(){return o()},set tooltip(e=!1){o(e),k()}},c=z();return H(P(c),()=>r()??w),B(e,c),O(s)}q(XO,{id:{},children:{},virtualEl:{},ref:{},tooltip:{}},[],[],{mode:`open`});function ZO(e,t){D(t,!0);let n=K(t,`content`,7),r=K(t,`side`,7,`bottom`),i=K(t,`sideOffset`,7,0),a=K(t,`align`,7,`center`),o=K(t,`alignOffset`,7,0),s=K(t,`id`,7),c=K(t,`arrowPadding`,7,0),l=K(t,`avoidCollisions`,7,!0),u=K(t,`collisionBoundary`,23,()=>[]),d=K(t,`collisionPadding`,7,0),f=K(t,`hideWhenDetached`,7,!1),p=K(t,`onPlaced`,7,()=>{}),m=K(t,`sticky`,7,`partial`),h=K(t,`updatePositionStrategy`,7,`optimized`),g=K(t,`strategy`,7,`fixed`),_=K(t,`dir`,7,`ltr`),v=K(t,`style`,23,()=>({})),y=K(t,`wrapperId`,23,NT),b=K(t,`customAnchor`,7,null),x=K(t,`enabled`,7),S=K(t,`tooltip`,7,!1),C=bO.create({side:Q(()=>r()),sideOffset:Q(()=>i()),align:Q(()=>a()),alignOffset:Q(()=>o()),id:Q(()=>s()),arrowPadding:Q(()=>c()),avoidCollisions:Q(()=>l()),collisionBoundary:Q(()=>u()),collisionPadding:Q(()=>d()),hideWhenDetached:Q(()=>f()),onPlaced:Q(()=>p()),sticky:Q(()=>m()),updatePositionStrategy:Q(()=>h()),strategy:Q(()=>g()),dir:Q(()=>_()),style:Q(()=>v()),enabled:Q(()=>x()),wrapperId:Q(()=>y()),customAnchor:Q(()=>b())},S()),ee=A(()=>zx(C.wrapperProps,{style:{pointerEvents:`auto`}}));var te={get content(){return n()},set content(e){n(e),k()},get side(){return r()},set side(e=`bottom`){r(e),k()},get sideOffset(){return i()},set sideOffset(e=0){i(e),k()},get align(){return a()},set align(e=`center`){a(e),k()},get alignOffset(){return o()},set alignOffset(e=0){o(e),k()},get id(){return s()},set id(e){s(e),k()},get arrowPadding(){return c()},set arrowPadding(e=0){c(e),k()},get avoidCollisions(){return l()},set avoidCollisions(e=!0){l(e),k()},get collisionBoundary(){return u()},set collisionBoundary(e=[]){u(e),k()},get collisionPadding(){return d()},set collisionPadding(e=0){d(e),k()},get hideWhenDetached(){return f()},set hideWhenDetached(e=!1){f(e),k()},get onPlaced(){return p()},set onPlaced(e=()=>{}){p(e),k()},get sticky(){return m()},set sticky(e=`partial`){m(e),k()},get updatePositionStrategy(){return h()},set updatePositionStrategy(e=`optimized`){h(e),k()},get strategy(){return g()},set strategy(e=`fixed`){g(e),k()},get dir(){return _()},set dir(e=`ltr`){_(e),k()},get style(){return v()},set style(e={}){v(e),k()},get wrapperId(){return y()},set wrapperId(e=NT()){y(e),k()},get customAnchor(){return b()},set customAnchor(e=null){b(e),k()},get enabled(){return x()},set enabled(e){x(e),k()},get tooltip(){return S()},set tooltip(e=!1){S(e),k()}},ne=z();return H(P(ne),()=>n()??w,()=>({props:C.props,wrapperProps:L(ee)})),B(e,ne),O(te)}q(ZO,{content:{},side:{},sideOffset:{},align:{},alignOffset:{},id:{},arrowPadding:{},avoidCollisions:{},collisionBoundary:{},collisionPadding:{},hideWhenDetached:{},onPlaced:{},sticky:{},updatePositionStrategy:{},strategy:{},dir:{},style:{},wrapperId:{},customAnchor:{},enabled:{},tooltip:{}},[],[],{mode:`open`});function QO(e,t){D(t,!0);let n=K(t,`content`,7),r=K(t,`onPlaced`,7);Ii(()=>{r()?.()});var i={get content(){return n()},set content(e){n(e),k()},get onPlaced(){return r()},set onPlaced(e){r(e),k()}},a=z();return H(P(a),()=>n()??w,()=>({props:{},wrapperProps:{}})),B(e,a),O(i)}q(QO,{content:{},onPlaced:{}},[],[],{mode:`open`});var $O=R(`<input/>`);function ek(e,t){D(t,!0);let n=K(t,`id`,23,NT),r=K(t,`ref`,15,null),i=K(t,`child`,7),a=K(t,`defaultValue`,7),o=K(t,`clearOnDeselect`,7,!1),s=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`ref`,`child`,`defaultValue`,`clearOnDeselect`]),c=RO.create({id:Q(()=>n()),ref:Q(()=>r(),e=>r(e)),clearOnDeselect:Q(()=>o())});a()&&(c.root.opts.inputValue.current=a());let l=A(()=>zx(s,c.props,{value:c.root.opts.inputValue.current}));var u={get id(){return n()},set id(e=NT()){n(e),k()},get ref(){return r()},set ref(e=null){r(e),k()},get child(){return i()},set child(e){i(e),k()},get defaultValue(){return a()},set defaultValue(e){a(e),k()},get clearOnDeselect(){return o()},set clearOnDeselect(e=!1){o(e),k()}},d=z();return W(P(d),()=>XO,(e,t)=>{t(e,{get id(){return n()},get ref(){return c.opts.ref},children:(e,t)=>{var n=z(),r=P(n),a=e=>{var t=z();H(P(t),i,()=>({props:L(l)})),B(e,t)},o=e=>{var t=$O();Ja(t,()=>({...L(l)}),void 0,void 0,void 0,void 0,!0),B(e,t)};U(r,e=>{i()?e(a):e(o,-1)}),B(e,n)},$$slots:{default:!0}})}),B(e,d),O(u)}q(ek,{id:{},ref:{},child:{},defaultValue:{},clearOnDeselect:{}},[],[],{mode:`open`});var tk=R(`<button><!></button>`);function nk(e,t){D(t,!0);let n=K(t,`id`,23,NT),r=K(t,`ref`,15,null),i=K(t,`child`,7),a=K(t,`children`,7),o=K(t,`type`,7,`button`),s=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`ref`,`child`,`children`,`type`]),c=zO.create({id:Q(()=>n()),ref:Q(()=>r(),e=>r(e))}),l=A(()=>zx(s,c.props,{type:o()}));var u={get id(){return n()},set id(e=NT()){n(e),k()},get ref(){return r()},set ref(e=null){r(e),k()},get child(){return i()},set child(e){i(e),k()},get children(){return a()},set children(e){a(e),k()},get type(){return o()},set type(e=`button`){o(e),k()}},d=z(),f=P(d),p=e=>{var t=z();H(P(t),i,()=>({props:L(l)})),B(e,t)},m=e=>{var t=tk();Ja(t,()=>({...L(l)})),H(N(t),()=>a()??w),E(t),B(e,t)};return U(f,e=>{i()?e(p):e(m,-1)}),B(e,d),O(u)}q(nk,{id:{},ref:{},child:{},children:{},type:{}},[],[],{mode:`open`});function rk(e,t){D(t,!0);let n=K(t,`content`,7),r=K(t,`isStatic`,7,!1),i=K(t,`onPlaced`,7),a=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`content`,`isStatic`,`onPlaced`]);var o={get content(){return n()},set content(e){n(e),k()},get isStatic(){return r()},set isStatic(e=!1){r(e),k()},get onPlaced(){return i()},set onPlaced(e){i(e),k()}},s=z(),c=P(s),l=e=>{QO(e,{get content(){return n()},get onPlaced(){return i()}})},u=e=>{ZO(e,mo({get content(){return n()},get onPlaced(){return i()}},()=>a))};return U(c,e=>{r()?e(l):e(u,-1)}),B(e,s),O(o)}q(rk,{content:{},isStatic:{},onPlaced:{}},[],[],{mode:`open`});var ik=R(`<!> <!>`,1);function ak(e,t){D(t,!0);let n=K(t,`popper`,7),r=K(t,`onEscapeKeydown`,7),i=K(t,`escapeKeydownBehavior`,7),a=K(t,`preventOverflowTextSelection`,7),o=K(t,`id`,7),s=K(t,`onPointerDown`,7),c=K(t,`onPointerUp`,7),l=K(t,`side`,7),u=K(t,`sideOffset`,7),d=K(t,`align`,7),f=K(t,`alignOffset`,7),p=K(t,`arrowPadding`,7),m=K(t,`avoidCollisions`,7),h=K(t,`collisionBoundary`,7),g=K(t,`collisionPadding`,7),_=K(t,`sticky`,7),v=K(t,`hideWhenDetached`,7),y=K(t,`updatePositionStrategy`,7),b=K(t,`strategy`,7),x=K(t,`dir`,7),S=K(t,`preventScroll`,7),C=K(t,`wrapperId`,7),ee=K(t,`style`,7),te=K(t,`onPlaced`,7),ne=K(t,`onInteractOutside`,7),re=K(t,`onCloseAutoFocus`,7),ie=K(t,`onOpenAutoFocus`,7),ae=K(t,`onFocusOutside`,7),oe=K(t,`interactOutsideBehavior`,7,`close`),se=K(t,`loop`,7),ce=K(t,`trapFocus`,7,!0),le=K(t,`isValidEvent`,7,()=>!1),ue=K(t,`customAnchor`,7,null),de=K(t,`isStatic`,7,!1),fe=K(t,`enabled`,7),pe=K(t,`ref`,7),me=K(t,`tooltip`,7,!1),he=K(t,`contentPointerEvents`,7,`auto`),ge=fo(t,`$$slots.$$events.$$legacy.$$host.popper.onEscapeKeydown.escapeKeydownBehavior.preventOverflowTextSelection.id.onPointerDown.onPointerUp.side.sideOffset.align.alignOffset.arrowPadding.avoidCollisions.collisionBoundary.collisionPadding.sticky.hideWhenDetached.updatePositionStrategy.strategy.dir.preventScroll.wrapperId.style.onPlaced.onInteractOutside.onCloseAutoFocus.onOpenAutoFocus.onFocusOutside.interactOutsideBehavior.loop.trapFocus.isValidEvent.customAnchor.isStatic.enabled.ref.tooltip.contentPointerEvents`.split(`.`));return rk(e,{get isStatic(){return de()},get id(){return o()},get side(){return l()},get sideOffset(){return u()},get align(){return d()},get alignOffset(){return f()},get arrowPadding(){return p()},get avoidCollisions(){return m()},get collisionBoundary(){return h()},get collisionPadding(){return g()},get sticky(){return _()},get hideWhenDetached(){return v()},get updatePositionStrategy(){return y()},get strategy(){return b()},get dir(){return x()},get wrapperId(){return C()},get style(){return ee()},get onPlaced(){return te()},get customAnchor(){return ue()},get enabled(){return fe()},get tooltip(){return me()},content:(e,l)=>{let u=()=>l?.().props,d=()=>l?.().wrapperProps;var f=ik(),p=P(f),m=e=>{GT(e,{get preventScroll(){return S()}})},h=e=>{GT(e,{get preventScroll(){return S()}})};U(p,e=>{t.forceMount&&fe()?e(m):t.forceMount||e(h,1)}),ET(F(p,2),{get onOpenAutoFocus(){return ie()},get onCloseAutoFocus(){return re()},get loop(){return se()},get enabled(){return fe()},get trapFocus(){return ce()},get forceMount(){return t.forceMount},get ref(){return pe()},focusScope:(e,t)=>{let l=()=>t?.().props;CT(e,{get onEscapeKeydown(){return r()},get escapeKeydownBehavior(){return i()},get enabled(){return fe()},get ref(){return pe()},children:(e,t)=>{bT(e,{get id(){return o()},get onInteractOutside(){return ne()},get onFocusOutside(){return ae()},get interactOutsideBehavior(){return oe()},get isValidEvent(){return le()},get enabled(){return fe()},get ref(){return pe()},children:(e,t)=>{let r=()=>t?.().props;MT(e,{get id(){return o()},get preventOverflowTextSelection(){return a()},get onPointerDown(){return s()},get onPointerUp(){return c()},get enabled(){return fe()},get ref(){return pe()},children:(e,t)=>{var i=z(),a=P(i);{let e=A(()=>({props:zx(ge,u(),r(),l(),{style:{pointerEvents:he()}}),wrapperProps:d()}));H(a,()=>n()??w,()=>L(e))}B(e,i)},$$slots:{default:!0}})},$$slots:{default:!0}})},$$slots:{default:!0}})},$$slots:{focusScope:!0}}),B(e,f)},$$slots:{content:!0}}),O({get popper(){return n()},set popper(e){n(e),k()},get onEscapeKeydown(){return r()},set onEscapeKeydown(e){r(e),k()},get escapeKeydownBehavior(){return i()},set escapeKeydownBehavior(e){i(e),k()},get preventOverflowTextSelection(){return a()},set preventOverflowTextSelection(e){a(e),k()},get id(){return o()},set id(e){o(e),k()},get onPointerDown(){return s()},set onPointerDown(e){s(e),k()},get onPointerUp(){return c()},set onPointerUp(e){c(e),k()},get side(){return l()},set side(e){l(e),k()},get sideOffset(){return u()},set sideOffset(e){u(e),k()},get align(){return d()},set align(e){d(e),k()},get alignOffset(){return f()},set alignOffset(e){f(e),k()},get arrowPadding(){return p()},set arrowPadding(e){p(e),k()},get avoidCollisions(){return m()},set avoidCollisions(e){m(e),k()},get collisionBoundary(){return h()},set collisionBoundary(e){h(e),k()},get collisionPadding(){return g()},set collisionPadding(e){g(e),k()},get sticky(){return _()},set sticky(e){_(e),k()},get hideWhenDetached(){return v()},set hideWhenDetached(e){v(e),k()},get updatePositionStrategy(){return y()},set updatePositionStrategy(e){y(e),k()},get strategy(){return b()},set strategy(e){b(e),k()},get dir(){return x()},set dir(e){x(e),k()},get preventScroll(){return S()},set preventScroll(e){S(e),k()},get wrapperId(){return C()},set wrapperId(e){C(e),k()},get style(){return ee()},set style(e){ee(e),k()},get onPlaced(){return te()},set onPlaced(e){te(e),k()},get onInteractOutside(){return ne()},set onInteractOutside(e){ne(e),k()},get onCloseAutoFocus(){return re()},set onCloseAutoFocus(e){re(e),k()},get onOpenAutoFocus(){return ie()},set onOpenAutoFocus(e){ie(e),k()},get onFocusOutside(){return ae()},set onFocusOutside(e){ae(e),k()},get interactOutsideBehavior(){return oe()},set interactOutsideBehavior(e=`close`){oe(e),k()},get loop(){return se()},set loop(e){se(e),k()},get trapFocus(){return ce()},set trapFocus(e=!0){ce(e),k()},get isValidEvent(){return le()},set isValidEvent(e=()=>!1){le(e),k()},get customAnchor(){return ue()},set customAnchor(e=null){ue(e),k()},get isStatic(){return de()},set isStatic(e=!1){de(e),k()},get enabled(){return fe()},set enabled(e){fe(e),k()},get ref(){return pe()},set ref(e){pe(e),k()},get tooltip(){return me()},set tooltip(e=!1){me(e),k()},get contentPointerEvents(){return he()},set contentPointerEvents(e=`auto`){he(e),k()}})}q(ak,{popper:{},onEscapeKeydown:{},escapeKeydownBehavior:{},preventOverflowTextSelection:{},id:{},onPointerDown:{},onPointerUp:{},side:{},sideOffset:{},align:{},alignOffset:{},arrowPadding:{},avoidCollisions:{},collisionBoundary:{},collisionPadding:{},sticky:{},hideWhenDetached:{},updatePositionStrategy:{},strategy:{},dir:{},preventScroll:{},wrapperId:{},style:{},onPlaced:{},onInteractOutside:{},onCloseAutoFocus:{},onOpenAutoFocus:{},onFocusOutside:{},interactOutsideBehavior:{},loop:{},trapFocus:{},isValidEvent:{},customAnchor:{},isStatic:{},enabled:{},ref:{},tooltip:{},contentPointerEvents:{}},[],[],{mode:`open`});function ok(e,t){D(t,!0);let n=K(t,`popper`,7),r=K(t,`open`,7),i=K(t,`onEscapeKeydown`,7),a=K(t,`escapeKeydownBehavior`,7),o=K(t,`preventOverflowTextSelection`,7),s=K(t,`id`,7),c=K(t,`onPointerDown`,7),l=K(t,`onPointerUp`,7),u=K(t,`side`,7),d=K(t,`sideOffset`,7),f=K(t,`align`,7),p=K(t,`alignOffset`,7),m=K(t,`arrowPadding`,7),h=K(t,`avoidCollisions`,7),g=K(t,`collisionBoundary`,7),_=K(t,`collisionPadding`,7),v=K(t,`sticky`,7),y=K(t,`hideWhenDetached`,7),b=K(t,`updatePositionStrategy`,7),x=K(t,`strategy`,7),S=K(t,`dir`,7),C=K(t,`preventScroll`,7),ee=K(t,`wrapperId`,7),te=K(t,`style`,7),ne=K(t,`onPlaced`,7),re=K(t,`onInteractOutside`,7),w=K(t,`onCloseAutoFocus`,7),ie=K(t,`onOpenAutoFocus`,7),ae=K(t,`onFocusOutside`,7),oe=K(t,`interactOutsideBehavior`,7,`close`),se=K(t,`loop`,7),ce=K(t,`trapFocus`,7,!0),le=K(t,`isValidEvent`,7,()=>!1),ue=K(t,`customAnchor`,7,null),de=K(t,`isStatic`,7,!1),fe=K(t,`ref`,7),pe=K(t,`shouldRender`,7),me=fo(t,`$$slots.$$events.$$legacy.$$host.popper.open.onEscapeKeydown.escapeKeydownBehavior.preventOverflowTextSelection.id.onPointerDown.onPointerUp.side.sideOffset.align.alignOffset.arrowPadding.avoidCollisions.collisionBoundary.collisionPadding.sticky.hideWhenDetached.updatePositionStrategy.strategy.dir.preventScroll.wrapperId.style.onPlaced.onInteractOutside.onCloseAutoFocus.onOpenAutoFocus.onFocusOutside.interactOutsideBehavior.loop.trapFocus.isValidEvent.customAnchor.isStatic.ref.shouldRender`.split(`.`));var he={get popper(){return n()},set popper(e){n(e),k()},get open(){return r()},set open(e){r(e),k()},get onEscapeKeydown(){return i()},set onEscapeKeydown(e){i(e),k()},get escapeKeydownBehavior(){return a()},set escapeKeydownBehavior(e){a(e),k()},get preventOverflowTextSelection(){return o()},set preventOverflowTextSelection(e){o(e),k()},get id(){return s()},set id(e){s(e),k()},get onPointerDown(){return c()},set onPointerDown(e){c(e),k()},get onPointerUp(){return l()},set onPointerUp(e){l(e),k()},get side(){return u()},set side(e){u(e),k()},get sideOffset(){return d()},set sideOffset(e){d(e),k()},get align(){return f()},set align(e){f(e),k()},get alignOffset(){return p()},set alignOffset(e){p(e),k()},get arrowPadding(){return m()},set arrowPadding(e){m(e),k()},get avoidCollisions(){return h()},set avoidCollisions(e){h(e),k()},get collisionBoundary(){return g()},set collisionBoundary(e){g(e),k()},get collisionPadding(){return _()},set collisionPadding(e){_(e),k()},get sticky(){return v()},set sticky(e){v(e),k()},get hideWhenDetached(){return y()},set hideWhenDetached(e){y(e),k()},get updatePositionStrategy(){return b()},set updatePositionStrategy(e){b(e),k()},get strategy(){return x()},set strategy(e){x(e),k()},get dir(){return S()},set dir(e){S(e),k()},get preventScroll(){return C()},set preventScroll(e){C(e),k()},get wrapperId(){return ee()},set wrapperId(e){ee(e),k()},get style(){return te()},set style(e){te(e),k()},get onPlaced(){return ne()},set onPlaced(e){ne(e),k()},get onInteractOutside(){return re()},set onInteractOutside(e){re(e),k()},get onCloseAutoFocus(){return w()},set onCloseAutoFocus(e){w(e),k()},get onOpenAutoFocus(){return ie()},set onOpenAutoFocus(e){ie(e),k()},get onFocusOutside(){return ae()},set onFocusOutside(e){ae(e),k()},get interactOutsideBehavior(){return oe()},set interactOutsideBehavior(e=`close`){oe(e),k()},get loop(){return se()},set loop(e){se(e),k()},get trapFocus(){return ce()},set trapFocus(e=!0){ce(e),k()},get isValidEvent(){return le()},set isValidEvent(e=()=>!1){le(e),k()},get customAnchor(){return ue()},set customAnchor(e=null){ue(e),k()},get isStatic(){return de()},set isStatic(e=!1){de(e),k()},get ref(){return fe()},set ref(e){fe(e),k()},get shouldRender(){return pe()},set shouldRender(e){pe(e),k()}},ge=z(),_e=P(ge),ve=e=>{ak(e,mo({get popper(){return n()},get onEscapeKeydown(){return i()},get escapeKeydownBehavior(){return a()},get preventOverflowTextSelection(){return o()},get id(){return s()},get onPointerDown(){return c()},get onPointerUp(){return l()},get side(){return u()},get sideOffset(){return d()},get align(){return f()},get alignOffset(){return p()},get arrowPadding(){return m()},get avoidCollisions(){return h()},get collisionBoundary(){return g()},get collisionPadding(){return _()},get sticky(){return v()},get hideWhenDetached(){return y()},get updatePositionStrategy(){return b()},get strategy(){return x()},get dir(){return S()},get preventScroll(){return C()},get wrapperId(){return ee()},get style(){return te()},get onPlaced(){return ne()},get customAnchor(){return ue()},get isStatic(){return de()},get enabled(){return r()},get onInteractOutside(){return re()},get onCloseAutoFocus(){return w()},get onOpenAutoFocus(){return ie()},get interactOutsideBehavior(){return oe()},get loop(){return se()},get trapFocus(){return ce()},get isValidEvent(){return le()},get onFocusOutside(){return ae()},forceMount:!1,get ref(){return fe()}},()=>me))};return U(_e,e=>{pe()&&e(ve)}),B(e,ge),O(he)}q(ok,{popper:{},open:{},onEscapeKeydown:{},escapeKeydownBehavior:{},preventOverflowTextSelection:{},id:{},onPointerDown:{},onPointerUp:{},side:{},sideOffset:{},align:{},alignOffset:{},arrowPadding:{},avoidCollisions:{},collisionBoundary:{},collisionPadding:{},sticky:{},hideWhenDetached:{},updatePositionStrategy:{},strategy:{},dir:{},preventScroll:{},wrapperId:{},style:{},onPlaced:{},onInteractOutside:{},onCloseAutoFocus:{},onOpenAutoFocus:{},onFocusOutside:{},interactOutsideBehavior:{},loop:{},trapFocus:{},isValidEvent:{},customAnchor:{},isStatic:{},ref:{},shouldRender:{}},[],[],{mode:`open`});function sk(e,t){D(t,!0);let n=K(t,`popper`,7),r=K(t,`onEscapeKeydown`,7),i=K(t,`escapeKeydownBehavior`,7),a=K(t,`preventOverflowTextSelection`,7),o=K(t,`id`,7),s=K(t,`onPointerDown`,7),c=K(t,`onPointerUp`,7),l=K(t,`side`,7),u=K(t,`sideOffset`,7),d=K(t,`align`,7),f=K(t,`alignOffset`,7),p=K(t,`arrowPadding`,7),m=K(t,`avoidCollisions`,7),h=K(t,`collisionBoundary`,7),g=K(t,`collisionPadding`,7),_=K(t,`sticky`,7),v=K(t,`hideWhenDetached`,7),y=K(t,`updatePositionStrategy`,7),b=K(t,`strategy`,7),x=K(t,`dir`,7),S=K(t,`preventScroll`,7),C=K(t,`wrapperId`,7),ee=K(t,`style`,7),te=K(t,`onPlaced`,7),ne=K(t,`onInteractOutside`,7),re=K(t,`onCloseAutoFocus`,7),w=K(t,`onOpenAutoFocus`,7),ie=K(t,`onFocusOutside`,7),ae=K(t,`interactOutsideBehavior`,7,`close`),oe=K(t,`loop`,7),se=K(t,`trapFocus`,7,!0),ce=K(t,`isValidEvent`,7,()=>!1),le=K(t,`customAnchor`,7,null),ue=K(t,`isStatic`,7,!1),de=K(t,`enabled`,7),fe=fo(t,`$$slots.$$events.$$legacy.$$host.popper.onEscapeKeydown.escapeKeydownBehavior.preventOverflowTextSelection.id.onPointerDown.onPointerUp.side.sideOffset.align.alignOffset.arrowPadding.avoidCollisions.collisionBoundary.collisionPadding.sticky.hideWhenDetached.updatePositionStrategy.strategy.dir.preventScroll.wrapperId.style.onPlaced.onInteractOutside.onCloseAutoFocus.onOpenAutoFocus.onFocusOutside.interactOutsideBehavior.loop.trapFocus.isValidEvent.customAnchor.isStatic.enabled`.split(`.`));return ak(e,mo({get popper(){return n()},get onEscapeKeydown(){return r()},get escapeKeydownBehavior(){return i()},get preventOverflowTextSelection(){return a()},get id(){return o()},get onPointerDown(){return s()},get onPointerUp(){return c()},get side(){return l()},get sideOffset(){return u()},get align(){return d()},get alignOffset(){return f()},get arrowPadding(){return p()},get avoidCollisions(){return m()},get collisionBoundary(){return h()},get collisionPadding(){return g()},get sticky(){return _()},get hideWhenDetached(){return v()},get updatePositionStrategy(){return y()},get strategy(){return b()},get dir(){return x()},get preventScroll(){return S()},get wrapperId(){return C()},get style(){return ee()},get onPlaced(){return te()},get customAnchor(){return le()},get isStatic(){return ue()},get enabled(){return de()},get onInteractOutside(){return ne()},get onCloseAutoFocus(){return re()},get onOpenAutoFocus(){return w()},get interactOutsideBehavior(){return ae()},get loop(){return oe()},get trapFocus(){return se()},get isValidEvent(){return ce()},get onFocusOutside(){return ie()}},()=>fe,{forceMount:!0})),O({get popper(){return n()},set popper(e){n(e),k()},get onEscapeKeydown(){return r()},set onEscapeKeydown(e){r(e),k()},get escapeKeydownBehavior(){return i()},set escapeKeydownBehavior(e){i(e),k()},get preventOverflowTextSelection(){return a()},set preventOverflowTextSelection(e){a(e),k()},get id(){return o()},set id(e){o(e),k()},get onPointerDown(){return s()},set onPointerDown(e){s(e),k()},get onPointerUp(){return c()},set onPointerUp(e){c(e),k()},get side(){return l()},set side(e){l(e),k()},get sideOffset(){return u()},set sideOffset(e){u(e),k()},get align(){return d()},set align(e){d(e),k()},get alignOffset(){return f()},set alignOffset(e){f(e),k()},get arrowPadding(){return p()},set arrowPadding(e){p(e),k()},get avoidCollisions(){return m()},set avoidCollisions(e){m(e),k()},get collisionBoundary(){return h()},set collisionBoundary(e){h(e),k()},get collisionPadding(){return g()},set collisionPadding(e){g(e),k()},get sticky(){return _()},set sticky(e){_(e),k()},get hideWhenDetached(){return v()},set hideWhenDetached(e){v(e),k()},get updatePositionStrategy(){return y()},set updatePositionStrategy(e){y(e),k()},get strategy(){return b()},set strategy(e){b(e),k()},get dir(){return x()},set dir(e){x(e),k()},get preventScroll(){return S()},set preventScroll(e){S(e),k()},get wrapperId(){return C()},set wrapperId(e){C(e),k()},get style(){return ee()},set style(e){ee(e),k()},get onPlaced(){return te()},set onPlaced(e){te(e),k()},get onInteractOutside(){return ne()},set onInteractOutside(e){ne(e),k()},get onCloseAutoFocus(){return re()},set onCloseAutoFocus(e){re(e),k()},get onOpenAutoFocus(){return w()},set onOpenAutoFocus(e){w(e),k()},get onFocusOutside(){return ie()},set onFocusOutside(e){ie(e),k()},get interactOutsideBehavior(){return ae()},set interactOutsideBehavior(e=`close`){ae(e),k()},get loop(){return oe()},set loop(e){oe(e),k()},get trapFocus(){return se()},set trapFocus(e=!0){se(e),k()},get isValidEvent(){return ce()},set isValidEvent(e=()=>!1){ce(e),k()},get customAnchor(){return le()},set customAnchor(e=null){le(e),k()},get isStatic(){return ue()},set isStatic(e=!1){ue(e),k()},get enabled(){return de()},set enabled(e){de(e),k()}})}q(sk,{popper:{},onEscapeKeydown:{},escapeKeydownBehavior:{},preventOverflowTextSelection:{},id:{},onPointerDown:{},onPointerUp:{},side:{},sideOffset:{},align:{},alignOffset:{},arrowPadding:{},avoidCollisions:{},collisionBoundary:{},collisionPadding:{},sticky:{},hideWhenDetached:{},updatePositionStrategy:{},strategy:{},dir:{},preventScroll:{},wrapperId:{},style:{},onPlaced:{},onInteractOutside:{},onCloseAutoFocus:{},onOpenAutoFocus:{},onFocusOutside:{},interactOutsideBehavior:{},loop:{},trapFocus:{},isValidEvent:{},customAnchor:{},isStatic:{},enabled:{}},[],[],{mode:`open`});var ck=R(`<div><div><!></div></div>`),lk=R(`<div><div><!></div></div>`);function uk(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>lC(n)),i=K(t,`ref`,15,null),a=K(t,`forceMount`,7,!1),o=K(t,`side`,7,`bottom`),s=K(t,`onInteractOutside`,7,$),c=K(t,`onEscapeKeydown`,7,$),l=K(t,`children`,7),u=K(t,`child`,7),d=K(t,`preventScroll`,7,!1),f=K(t,`style`,7),p=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`ref`,`forceMount`,`side`,`onInteractOutside`,`onEscapeKeydown`,`children`,`child`,`preventScroll`,`style`]),m=BO.create({id:Q(()=>r()),ref:Q(()=>i(),e=>i(e)),onInteractOutside:Q(()=>s()),onEscapeKeydown:Q(()=>c())}),h=A(()=>zx(p,m.props));var g={get id(){return r()},set id(e=lC(n)){r(e),k()},get ref(){return i()},set ref(e=null){i(e),k()},get forceMount(){return a()},set forceMount(e=!1){a(e),k()},get side(){return o()},set side(e=`bottom`){o(e),k()},get onInteractOutside(){return s()},set onInteractOutside(e=$){s(e),k()},get onEscapeKeydown(){return c()},set onEscapeKeydown(e=$){c(e),k()},get children(){return l()},set children(e){l(e),k()},get child(){return u()},set child(e){u(e),k()},get preventScroll(){return d()},set preventScroll(e=!1){d(e),k()},get style(){return f()},set style(e){f(e),k()}},_=z(),v=P(_),y=e=>{sk(e,mo(()=>L(h),()=>m.popperProps,{get ref(){return m.opts.ref},get side(){return o()},get enabled(){return m.root.opts.open.current},get id(){return r()},get preventScroll(){return d()},forceMount:!0,get shouldRender(){return m.shouldRender},popper:(e,t)=>{let n=()=>t?.().props,r=()=>t?.().wrapperProps,i=A(()=>zx(n(),{style:m.props.style},{style:f()}));var a=z(),o=P(a),s=e=>{var t=z(),n=P(t);{let e=A(()=>({props:L(i),wrapperProps:r(),...m.snippetProps}));H(n,u,()=>L(e))}B(e,t)},c=e=>{var t=ck();Ja(t,()=>({...r()}));var n=N(t);Ja(n,()=>({...L(i)})),H(N(n),()=>l()??w),E(n),E(t),B(e,t)};U(o,e=>{u()?e(s):e(c,-1)}),B(e,a)},$$slots:{popper:!0}}))},b=e=>{ok(e,mo(()=>L(h),()=>m.popperProps,{get ref(){return m.opts.ref},get side(){return o()},get open(){return m.root.opts.open.current},get id(){return r()},get preventScroll(){return d()},forceMount:!1,get shouldRender(){return m.shouldRender},popper:(e,t)=>{let n=()=>t?.().props,r=()=>t?.().wrapperProps,i=A(()=>zx(n(),{style:m.props.style},{style:f()}));var a=z(),o=P(a),s=e=>{var t=z(),n=P(t);{let e=A(()=>({props:L(i),wrapperProps:r(),...m.snippetProps}));H(n,u,()=>L(e))}B(e,t)},c=e=>{var t=lk();Ja(t,()=>({...r()}));var n=N(t);Ja(n,()=>({...L(i)})),H(N(n),()=>l()??w),E(n),E(t),B(e,t)};U(o,e=>{u()?e(s):e(c,-1)}),B(e,a)},$$slots:{popper:!0}}))};return U(v,e=>{a()?e(y):a()||e(b,1)}),B(e,_),O(g)}q(uk,{id:{},ref:{},forceMount:{},side:{},onInteractOutside:{},onEscapeKeydown:{},children:{},child:{},preventScroll:{},style:{}},[],[],{mode:`open`});function dk(e,t){D(t,!0);let n=K(t,`mounted`,15,!1),r=K(t,`onMountedChange`,7,$);return sS(()=>(n(!0),r()(!0),()=>{n(!1),r()(!1)})),O({get mounted(){return n()},set mounted(e=!1){n(e),k()},get onMountedChange(){return r()},set onMountedChange(e=$){r(e),k()}})}q(dk,{mounted:{},onMountedChange:{}},[],[],{mode:`open`});var fk=R(`<div><!></div>`),pk=R(`<!> <!>`,1);function mk(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>lC(n)),i=K(t,`ref`,15,null),a=K(t,`value`,7),o=K(t,`label`,23,a),s=K(t,`disabled`,7,!1),c=K(t,`children`,7),l=K(t,`child`,7),u=K(t,`onHighlight`,7,$),d=K(t,`onUnhighlight`,7,$),f=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`ref`,`value`,`label`,`disabled`,`children`,`child`,`onHighlight`,`onUnhighlight`]),p=VO.create({id:Q(()=>r()),ref:Q(()=>i(),e=>i(e)),value:Q(()=>a()),disabled:Q(()=>s()),label:Q(()=>o()),onHighlight:Q(()=>u()),onUnhighlight:Q(()=>d())}),m=A(()=>zx(f,p.props));var h={get id(){return r()},set id(e=lC(n)){r(e),k()},get ref(){return i()},set ref(e=null){i(e),k()},get value(){return a()},set value(e){a(e),k()},get label(){return o()},set label(e=a){o(e),k()},get disabled(){return s()},set disabled(e=!1){s(e),k()},get children(){return c()},set children(e){c(e),k()},get child(){return l()},set child(e){l(e),k()},get onHighlight(){return u()},set onHighlight(e=$){u(e),k()},get onUnhighlight(){return d()},set onUnhighlight(e=$){d(e),k()}},g=pk(),_=P(g),v=e=>{var t=z(),n=P(t);{let e=A(()=>({props:L(m),...p.snippetProps}));H(n,l,()=>L(e))}B(e,t)},y=e=>{var t=fk();Ja(t,()=>({...L(m)})),H(N(t),()=>c()??w,()=>p.snippetProps),E(t),B(e,t)};return U(_,e=>{l()?e(v):e(y,-1)}),dk(F(_,2),{get mounted(){return p.mounted},set mounted(e){p.mounted=e}}),B(e,g),O(h)}q(mk,{id:{},ref:{},value:{},label:{},disabled:{},children:{},child:{},onHighlight:{},onUnhighlight:{}},[],[],{mode:`open`});var hk=R(`<div><!></div>`),gk={hash:`svelte-5vjl6o`,code:`
|
|
573
|
-
/* Hide scrollbars cross browser and enable momentum scroll for touch devices */[data-select-viewport] {scrollbar-width:none !important;-ms-overflow-style:none !important;-webkit-overflow-scrolling:touch !important;}[data-combobox-viewport] {scrollbar-width:none !important;-ms-overflow-style:none !important;-webkit-overflow-scrolling:touch !important;}[data-combobox-viewport]::-webkit-scrollbar {display:none !important;}[data-select-viewport]::-webkit-scrollbar {display:none !important;}`};function _k(e,t){let n=gi();D(t,!0),ga(e,gk);let r=K(t,`id`,23,()=>lC(n)),i=K(t,`ref`,15,null),a=K(t,`children`,7),o=K(t,`child`,7),s=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`ref`,`children`,`child`]),c=UO.create({id:Q(()=>r()),ref:Q(()=>i(),e=>i(e))}),l=A(()=>zx(s,c.props));var u={get id(){return r()},set id(e=lC(n)){r(e),k()},get ref(){return i()},set ref(e=null){i(e),k()},get children(){return a()},set children(e){a(e),k()},get child(){return o()},set child(e){o(e),k()}},d=z(),f=P(d),p=e=>{var t=z();H(P(t),o,()=>({props:L(l)})),B(e,t)},m=e=>{var t=hk();Ja(t,()=>({...L(l)})),H(N(t),()=>a()??w),E(t),B(e,t)};return U(f,e=>{o()?e(p):e(m,-1)}),B(e,d),O(u)}q(_k,{id:{},ref:{},children:{},child:{}},[],[],{mode:`open`});var vk=R(`<div><!></div>`),yk=R(`<!> <!>`,1);function bk(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>lC(n)),i=K(t,`ref`,15,null),a=K(t,`delay`,7,()=>50),o=K(t,`child`,7),s=K(t,`children`,7),c=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`ref`,`delay`,`child`,`children`]),l=GO.create({id:Q(()=>r()),ref:Q(()=>i(),e=>i(e)),delay:Q(()=>a())}),u=A(()=>zx(c,l.props));var d={get id(){return r()},set id(e=lC(n)){r(e),k()},get ref(){return i()},set ref(e=null){i(e),k()},get delay(){return a()},set delay(e=()=>50){a(e),k()},get child(){return o()},set child(e){o(e),k()},get children(){return s()},set children(e){s(e),k()}},f=z(),p=P(f),m=e=>{var t=yk(),n=P(t);dk(n,{get mounted(){return l.scrollButtonState.mounted},set mounted(e){l.scrollButtonState.mounted=e}});var r=F(n,2),i=e=>{var t=z();H(P(t),o,()=>({props:c})),B(e,t)},a=e=>{var t=vk();Ja(t,()=>({...L(u)})),H(N(t),()=>s()??w),E(t),B(e,t)};U(r,e=>{o()?e(i):e(a,-1)}),B(e,t)};return U(p,e=>{l.canScrollDown&&e(m)}),B(e,f),O(d)}q(bk,{id:{},ref:{},delay:{},child:{},children:{}},[],[],{mode:`open`});var xk=R(`<div><!></div>`),Sk=R(`<!> <!>`,1);function Ck(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>lC(n)),i=K(t,`ref`,15,null),a=K(t,`delay`,7,()=>50),o=K(t,`child`,7),s=K(t,`children`,7),c=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`ref`,`delay`,`child`,`children`]),l=KO.create({id:Q(()=>r()),ref:Q(()=>i(),e=>i(e)),delay:Q(()=>a())}),u=A(()=>zx(c,l.props));var d={get id(){return r()},set id(e=lC(n)){r(e),k()},get ref(){return i()},set ref(e=null){i(e),k()},get delay(){return a()},set delay(e=()=>50){a(e),k()},get child(){return o()},set child(e){o(e),k()},get children(){return s()},set children(e){s(e),k()}},f=z(),p=P(f),m=e=>{var t=Sk(),n=P(t);dk(n,{get mounted(){return l.scrollButtonState.mounted},set mounted(e){l.scrollButtonState.mounted=e}});var r=F(n,2),i=e=>{var t=z();H(P(t),o,()=>({props:c})),B(e,t)},a=e=>{var t=xk();Ja(t,()=>({...L(u)})),H(N(t),()=>s()??w),E(t),B(e,t)};U(r,e=>{o()?e(i):e(a,-1)}),B(e,t)};return U(p,e=>{l.canScrollUp&&e(m)}),B(e,f),O(d)}q(Ck,{id:{},ref:{},delay:{},child:{},children:{}},[],[],{mode:`open`});var wk=R(`<div><!></div>`);function Tk(e,t){let n=gi();D(t,!0);let r=K(t,`child`,7),i=K(t,`children`,7),a=K(t,`ref`,15,null),o=K(t,`id`,23,()=>lC(n)),s=K(t,`disabled`,7,!1),c=K(t,`onSelect`,7,$),l=K(t,`closeOnSelect`,7,!0),u=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`child`,`children`,`ref`,`id`,`disabled`,`onSelect`,`closeOnSelect`]),d=oT.create({id:Q(()=>o()),disabled:Q(()=>s()),onSelect:Q(()=>c()),ref:Q(()=>a(),e=>a(e)),closeOnSelect:Q(()=>l())}),f=A(()=>zx(u,d.props));var p={get child(){return r()},set child(e){r(e),k()},get children(){return i()},set children(e){i(e),k()},get ref(){return a()},set ref(e=null){a(e),k()},get id(){return o()},set id(e=lC(n)){o(e),k()},get disabled(){return s()},set disabled(e=!1){s(e),k()},get onSelect(){return c()},set onSelect(e=$){c(e),k()},get closeOnSelect(){return l()},set closeOnSelect(e=!0){l(e),k()}},m=z(),h=P(m),g=e=>{var t=z();H(P(t),r,()=>({props:L(f)})),B(e,t)},_=e=>{var t=wk();Ja(t,()=>({...L(f)})),H(N(t),()=>i()??w),E(t),B(e,t)};return U(h,e=>{r()?e(g):e(_,-1)}),B(e,m),O(p)}q(Tk,{child:{},children:{},ref:{},id:{},disabled:{},onSelect:{},closeOnSelect:{}},[],[],{mode:`open`});var Ek=R(`<div><!></div>`);function Dk(e,t){let n=gi();D(t,!0);let r=K(t,`children`,7),i=K(t,`child`,7),a=K(t,`ref`,15,null),o=K(t,`id`,23,()=>lC(n)),s=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`children`,`child`,`ref`,`id`]),c=cT.create({id:Q(()=>o()),ref:Q(()=>a(),e=>a(e))}),l=A(()=>zx(s,c.props));var u={get children(){return r()},set children(e){r(e),k()},get child(){return i()},set child(e){i(e),k()},get ref(){return a()},set ref(e=null){a(e),k()},get id(){return o()},set id(e=lC(n)){o(e),k()}},d=z(),f=P(d),p=e=>{var t=z();H(P(t),i,()=>({props:L(l)})),B(e,t)},m=e=>{var t=Ek();Ja(t,()=>({...L(l)})),H(N(t),()=>r()??w),E(t),B(e,t)};return U(f,e=>{i()?e(p):e(m,-1)}),B(e,d),O(u)}q(Dk,{children:{},child:{},ref:{},id:{}},[],[],{mode:`open`});var Ok=R(`<div><!></div>`);function kk(e,t){let n=gi();D(t,!0);let r=K(t,`children`,7),i=K(t,`child`,7),a=K(t,`ref`,15,null),o=K(t,`id`,23,()=>lC(n)),s=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`children`,`child`,`ref`,`id`]),c=lT.create({id:Q(()=>o()),ref:Q(()=>a(),e=>a(e))}),l=A(()=>zx(s,c.props));var u={get children(){return r()},set children(e){r(e),k()},get child(){return i()},set child(e){i(e),k()},get ref(){return a()},set ref(e=null){a(e),k()},get id(){return o()},set id(e=lC(n)){o(e),k()}},d=z(),f=P(d),p=e=>{var t=z();H(P(t),i,()=>({props:L(l)})),B(e,t)},m=e=>{var t=Ok();Ja(t,()=>({...L(l)})),H(N(t),()=>r()??w),E(t),B(e,t)};return U(f,e=>{i()?e(p):e(m,-1)}),B(e,d),O(u)}q(kk,{children:{},child:{},ref:{},id:{}},[],[],{mode:`open`});var Ak=R(`<div><!></div>`);function jk(e,t){let n=gi();D(t,!0);let r=K(t,`children`,7),i=K(t,`child`,7),a=K(t,`ref`,15,null),o=K(t,`value`,7),s=K(t,`onSelect`,7,$),c=K(t,`id`,23,()=>lC(n)),l=K(t,`disabled`,7,!1),u=K(t,`closeOnSelect`,7,!0),d=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`children`,`child`,`ref`,`value`,`onSelect`,`id`,`disabled`,`closeOnSelect`]),f=fT.create({value:Q(()=>o()),id:Q(()=>c()),disabled:Q(()=>l()),onSelect:Q(()=>p),ref:Q(()=>a(),e=>a(e)),closeOnSelect:Q(()=>u())});function p(e){s()(e),!e.defaultPrevented&&f.selectValue()}let m=A(()=>zx(d,f.props));var h={get children(){return r()},set children(e){r(e),k()},get child(){return i()},set child(e){i(e),k()},get ref(){return a()},set ref(e=null){a(e),k()},get value(){return o()},set value(e){o(e),k()},get onSelect(){return s()},set onSelect(e=$){s(e),k()},get id(){return c()},set id(e=lC(n)){c(e),k()},get disabled(){return l()},set disabled(e=!1){l(e),k()},get closeOnSelect(){return u()},set closeOnSelect(e=!0){u(e),k()}},g=z(),_=P(g),v=e=>{var t=z();H(P(t),i,()=>({props:L(m),checked:f.isChecked})),B(e,t)},y=e=>{var t=Ak();Ja(t,()=>({...L(m)})),H(N(t),()=>r()??w,()=>({checked:f.isChecked})),E(t),B(e,t)};return U(_,e=>{i()?e(v):e(y,-1)}),B(e,g),O(h)}q(jk,{children:{},child:{},ref:{},value:{},onSelect:{},id:{},disabled:{},closeOnSelect:{}},[],[],{mode:`open`});var Mk=R(`<div><!></div>`);function Nk(e,t){let n=gi();D(t,!0);let r=K(t,`ref`,15,null),i=K(t,`id`,23,()=>lC(n)),a=K(t,`child`,7),o=K(t,`children`,7),s=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`ref`,`id`,`child`,`children`]),c=uT.create({id:Q(()=>i()),ref:Q(()=>r(),e=>r(e))}),l=A(()=>zx(s,c.props));var u={get ref(){return r()},set ref(e=null){r(e),k()},get id(){return i()},set id(e=lC(n)){i(e),k()},get child(){return a()},set child(e){a(e),k()},get children(){return o()},set children(e){o(e),k()}},d=z(),f=P(d),p=e=>{var t=z();H(P(t),a,()=>({props:L(l)})),B(e,t)},m=e=>{var t=Mk();Ja(t,()=>({...L(l)})),H(N(t),()=>o()??w),E(t),B(e,t)};return U(f,e=>{a()?e(p):e(m,-1)}),B(e,d),O(u)}q(Nk,{ref:{},id:{},child:{},children:{}},[],[],{mode:`open`});var Pk=R(`<div><!></div>`);function Fk(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>lC(n)),i=K(t,`children`,7),a=K(t,`child`,7),o=K(t,`ref`,15,null),s=K(t,`value`,15,``),c=K(t,`onValueChange`,7,$),l=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`children`,`child`,`ref`,`value`,`onValueChange`]),u=dT.create({value:Q(()=>s(),e=>{s(e),c()(e)}),ref:Q(()=>o(),e=>o(e)),id:Q(()=>r())}),d=A(()=>zx(l,u.props));var f={get id(){return r()},set id(e=lC(n)){r(e),k()},get children(){return i()},set children(e){i(e),k()},get child(){return a()},set child(e){a(e),k()},get ref(){return o()},set ref(e=null){o(e),k()},get value(){return s()},set value(e=``){s(e),k()},get onValueChange(){return c()},set onValueChange(e=$){c(e),k()}},p=z(),m=P(p),h=e=>{var t=z();H(P(t),a,()=>({props:L(d)})),B(e,t)},g=e=>{var t=Pk();Ja(t,()=>({...L(d)})),H(N(t),()=>i()??w),E(t),B(e,t)};return U(m,e=>{a()?e(h):e(g,-1)}),B(e,p),O(f)}q(Fk,{id:{},children:{},child:{},ref:{},value:{},onValueChange:{}},[],[],{mode:`open`});var Ik=R(`<div><!></div>`);function Lk(e,t){let n=gi();D(t,!0);let r=K(t,`child`,7),i=K(t,`children`,7),a=K(t,`ref`,15,null),o=K(t,`checked`,15,!1),s=K(t,`id`,23,()=>lC(n)),c=K(t,`onCheckedChange`,7,$),l=K(t,`disabled`,7,!1),u=K(t,`onSelect`,7,$),d=K(t,`closeOnSelect`,7,!0),f=K(t,`indeterminate`,15,!1),p=K(t,`onIndeterminateChange`,7,$),m=K(t,`value`,7,``),h=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`child`,`children`,`ref`,`checked`,`id`,`onCheckedChange`,`disabled`,`onSelect`,`closeOnSelect`,`indeterminate`,`onIndeterminateChange`,`value`]),g=$w.getOr(null);g&&m()&&(g.opts.value.current.includes(m())?o(!0):o(!1)),Jx.pre(()=>m(),()=>{g&&m()&&(g.opts.value.current.includes(m())?o(!0):o(!1))});let _=sT.create({checked:Q(()=>o(),e=>{e!==o()&&(o(e),c()(e))}),id:Q(()=>s()),disabled:Q(()=>l()),onSelect:Q(()=>v),ref:Q(()=>a(),e=>a(e)),closeOnSelect:Q(()=>d()),indeterminate:Q(()=>f(),e=>{e!==f()&&(f(e),p()(e))}),value:Q(()=>m())},g);function v(e){u()(e),!e.defaultPrevented&&_.toggleChecked()}let y=A(()=>zx(h,_.props));var b={get child(){return r()},set child(e){r(e),k()},get children(){return i()},set children(e){i(e),k()},get ref(){return a()},set ref(e=null){a(e),k()},get checked(){return o()},set checked(e=!1){o(e),k()},get id(){return s()},set id(e=lC(n)){s(e),k()},get onCheckedChange(){return c()},set onCheckedChange(e=$){c(e),k()},get disabled(){return l()},set disabled(e=!1){l(e),k()},get onSelect(){return u()},set onSelect(e=$){u(e),k()},get closeOnSelect(){return d()},set closeOnSelect(e=!0){d(e),k()},get indeterminate(){return f()},set indeterminate(e=!1){f(e),k()},get onIndeterminateChange(){return p()},set onIndeterminateChange(e=$){p(e),k()},get value(){return m()},set value(e=``){m(e),k()}},x=z(),S=P(x),C=e=>{var t=z();H(P(t),r,()=>({checked:o(),indeterminate:f(),props:L(y)})),B(e,t)},ee=e=>{var t=Ik();Ja(t,()=>({...L(y)})),H(N(t),()=>i()??w,()=>({checked:o(),indeterminate:f()})),E(t),B(e,t)};return U(S,e=>{r()?e(C):e(ee,-1)}),B(e,x),O(b)}q(Lk,{child:{},children:{},ref:{},checked:{},id:{},onCheckedChange:{},disabled:{},onSelect:{},closeOnSelect:{},indeterminate:{},onIndeterminateChange:{},value:{}},[],[],{mode:`open`});var Rk=R(`<div><!></div>`);function zk(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>lC(n)),i=K(t,`children`,7),a=K(t,`child`,7),o=K(t,`ref`,15,null),s=K(t,`value`,31,()=>Dn([])),c=K(t,`onValueChange`,7,$),l=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`children`,`child`,`ref`,`value`,`onValueChange`]),u=mT.create({value:Q(()=>st(s()),e=>{s(st(e)),c()(e)}),onValueChange:Q(()=>c()),ref:Q(()=>o(),e=>o(e)),id:Q(()=>r())}),d=A(()=>zx(l,u.props));var f={get id(){return r()},set id(e=lC(n)){r(e),k()},get children(){return i()},set children(e){i(e),k()},get child(){return a()},set child(e){a(e),k()},get ref(){return o()},set ref(e=null){o(e),k()},get value(){return s()},set value(e=[]){s(e),k()},get onValueChange(){return c()},set onValueChange(e=$){c(e),k()}},p=z(),m=P(p),h=e=>{var t=z();H(P(t),a,()=>({props:L(d)})),B(e,t)},g=e=>{var t=Rk();Ja(t,()=>({...L(d)})),H(N(t),()=>i()??w),E(t),B(e,t)};return U(m,e=>{a()?e(h):e(g,-1)}),B(e,p),O(f)}q(zk,{id:{},children:{},child:{},ref:{},value:{},onValueChange:{}},[],[],{mode:`open`});function Bk(e,t){let[n,r]=e,i=!1,a=t.length;for(let e=0,o=a-1;e<a;o=e++){let[a,s]=t[e]??[0,0],[c,l]=t[o]??[0,0];s>=r!=l>=r&&n<=(c-a)*(r-s)/(l-s)+a&&(i=!i)}return i}function Vk(e,t){return e[0]>=t.left&&e[0]<=t.right&&e[1]>=t.top&&e[1]<=t.bottom}function Hk(e,t){let n=e.left+e.width/2,r=e.top+e.height/2,i=t.left+t.width/2,a=t.top+t.height/2,o=i-n,s=a-r;return Math.abs(o)>Math.abs(s)?o>0?`right`:`left`:s>0?`bottom`:`top`}var Uk=class{#e;#t;#n;#r=null;#i=null;#a=[];#o=null;#s=null;#c=null;#l(){this.#s!==null&&(cancelAnimationFrame(this.#s),this.#s=null)}#u(){this.#l(),this.#s=requestAnimationFrame(()=>{this.#s=null,!(!this.#r||!this.#i)&&(this.#m(),this.#e.onPointerExit())})}#d(){this.#c!==null&&(clearTimeout(this.#c),this.#c=null)}#f(){this.#n!==null&&(this.#d(),this.#c=window.setTimeout(()=>{this.#c=null,!(!this.#r||!this.#i)&&(this.#m(),this.#e.onPointerExit())},this.#n))}constructor(e){this.#e=e,this.#t=e.buffer??1;let t=e.transitIntentTimeout;this.#n=typeof t==`number`&&t>0?t:null,Jx([e.triggerNode,e.contentNode,e.enabled],([e,t,n])=>{if(!e||!t||!n){this.#o=null,this.#m();return}return this.#o&&this.#o!==e&&this.#m(),this.#o=e,[ri(yS(e),`pointermove`,n=>{this.#p([n.clientX,n.clientY],e,t)}),ri(e,`pointerleave`,e=>{let n=e.relatedTarget;if(tC(n)&&t.contains(n))return;let r=this.#e.ignoredTargets?.()??[];tC(n)&&r.some(e=>e===n||e.contains(n))||(this.#a=tC(n)&&r.length>0?r.filter(e=>n.contains(e)):[],this.#r=[e.clientX,e.clientY],this.#i=`content`,this.#u())}),ri(e,`pointerenter`,()=>{this.#m()}),ri(t,`pointerenter`,()=>{this.#m()}),ri(t,`pointerleave`,t=>{let n=t.relatedTarget;tC(n)&&e.contains(n)||(this.#r=[t.clientX,t.clientY],this.#i=`trigger`,this.#u())})].reduce((e,t)=>()=>{e(),t()},()=>{})})}#p(e,t,n){if(!this.#r||!this.#i)return;this.#l(),this.#f();let r=t.getBoundingClientRect(),i=n.getBoundingClientRect();if(this.#i===`content`&&Vk(e,i)){this.#m();return}if(this.#i===`trigger`&&Vk(e,r)){this.#m();return}if(this.#i===`content`&&this.#a.length>0)for(let t of this.#a){let n=t.getBoundingClientRect();if(Vk(e,n))return;let i=Hk(r,n),a=this.#h(r,n,i);if(a&&Bk(e,a))return}let a=Hk(r,i),o=this.#h(r,i,a);if(o&&Bk(e,o))return;let s=this.#i===`content`?i:r;Bk(e,this.#g(this.#r,s,a,this.#i))||(this.#m(),this.#e.onPointerExit())}#m(){this.#r=null,this.#i=null,this.#a=[],this.#l(),this.#d()}#h(e,t,n){let r=this.#t;switch(n){case`top`:return[[Math.min(e.left,t.left)-r,e.top],[Math.min(e.left,t.left)-r,t.bottom],[Math.max(e.right,t.right)+r,t.bottom],[Math.max(e.right,t.right)+r,e.top]];case`bottom`:return[[Math.min(e.left,t.left)-r,e.bottom],[Math.min(e.left,t.left)-r,t.top],[Math.max(e.right,t.right)+r,t.top],[Math.max(e.right,t.right)+r,e.bottom]];case`left`:return[[e.left,Math.min(e.top,t.top)-r],[t.right,Math.min(e.top,t.top)-r],[t.right,Math.max(e.bottom,t.bottom)+r],[e.left,Math.max(e.bottom,t.bottom)+r]];case`right`:return[[e.right,Math.min(e.top,t.top)-r],[t.left,Math.min(e.top,t.top)-r],[t.left,Math.max(e.bottom,t.bottom)+r],[e.right,Math.max(e.bottom,t.bottom)+r]]}}#g(e,t,n,r){let i=this.#t*4,[a,o]=e;switch(r===`trigger`?this.#_(n):n){case`top`:return[[a-i,o+i],[a+i,o+i],[t.right+i,t.bottom],[t.right+i,t.top],[t.left-i,t.top],[t.left-i,t.bottom]];case`bottom`:return[[a-i,o-i],[a+i,o-i],[t.right+i,t.top],[t.right+i,t.bottom],[t.left-i,t.bottom],[t.left-i,t.top]];case`left`:return[[a+i,o-i],[a+i,o+i],[t.right,t.bottom+i],[t.left,t.bottom+i],[t.left,t.top-i],[t.right,t.top-i]];case`right`:return[[a-i,o-i],[a-i,o+i],[t.left,t.bottom+i],[t.right,t.bottom+i],[t.right,t.top-i],[t.left,t.top-i]]}}#_(e){switch(e){case`top`:return`bottom`;case`bottom`:return`top`;case`left`:return`right`;case`right`:return`left`}}},Wk=jS({component:`popover`,parts:[`root`,`trigger`,`content`,`close`,`overlay`]}),Gk=new Wx(`Popover.Root`),Kk=class e{static create(t){return Gk.set(new e(t))}opts;#e=j(null);get contentNode(){return L(this.#e)}set contentNode(e){M(this.#e,e,!0)}contentPresence;#t=j(null);get triggerNode(){return L(this.#t)}set triggerNode(e){M(this.#t,e,!0)}#n=j(null);get overlayNode(){return L(this.#n)}set overlayNode(e){M(this.#n,e,!0)}overlayPresence;#r=j(!1);get openedViaHover(){return L(this.#r)}set openedViaHover(e){M(this.#r,e,!0)}#i=j(!1);get hasInteractedWithContent(){return L(this.#i)}set hasInteractedWithContent(e){M(this.#i,e,!0)}#a=j(!1);get hoverCooldown(){return L(this.#a)}set hoverCooldown(e){M(this.#a,e,!0)}#o=j(0);get closeDelay(){return L(this.#o)}set closeDelay(e){M(this.#o,e,!0)}#s=null;#c=null;constructor(e){this.opts=e,this.contentPresence=new cC({ref:Q(()=>this.contentNode),open:this.opts.open,onComplete:()=>{this.opts.onOpenChangeComplete.current(this.opts.open.current)}}),this.overlayPresence=new cC({ref:Q(()=>this.overlayNode),open:this.opts.open}),Jx(()=>this.opts.open.current,e=>{e||(this.openedViaHover=!1,this.hasInteractedWithContent=!1,this.#l())})}setDomContext(e){this.#c=e}#l(){this.#s!==null&&this.#c&&(this.#c.clearTimeout(this.#s),this.#s=null)}toggleOpen(){this.#l(),this.opts.open.current=!this.opts.open.current}handleClose(){this.#l(),this.opts.open.current&&(this.opts.open.current=!1)}handleHoverOpen(){this.#l(),!this.opts.open.current&&(this.openedViaHover=!0,this.opts.open.current=!0)}handleHoverClose(){this.opts.open.current&&this.openedViaHover&&!this.hasInteractedWithContent&&(this.opts.open.current=!1)}handleDelayedHoverClose(){this.opts.open.current&&(!this.openedViaHover||this.hasInteractedWithContent||(this.#l(),this.closeDelay<=0?this.opts.open.current=!1:this.#c&&(this.#s=this.#c.setTimeout(()=>{this.openedViaHover&&!this.hasInteractedWithContent&&(this.opts.open.current=!1),this.#s=null},this.closeDelay))))}cancelDelayedClose(){this.#l()}markInteraction(){this.hasInteractedWithContent=!0,this.#l()}},qk=class e{static create(t){return new e(t,Gk.get())}opts;root;attachment;domContext;#e=null;#t=null;#n=j(!1);constructor(e,t){this.opts=e,this.root=t,this.attachment=CS(this.opts.ref,e=>this.root.triggerNode=e),this.domContext=new SS(e.ref),this.root.setDomContext(this.domContext),this.onclick=this.onclick.bind(this),this.onkeydown=this.onkeydown.bind(this),this.onpointerenter=this.onpointerenter.bind(this),this.onpointerleave=this.onpointerleave.bind(this),Jx(()=>this.opts.closeDelay.current,e=>{this.root.closeDelay=e})}#r(){this.#e!==null&&(this.domContext.clearTimeout(this.#e),this.#e=null)}#i(){this.#t!==null&&(this.domContext.clearTimeout(this.#t),this.#t=null)}#a(){this.#r(),this.#i()}onpointerenter(e){if(this.opts.disabled.current||!this.opts.openOnHover.current||rC(e)||(M(this.#n,!0),this.#i(),this.root.cancelDelayedClose(),this.root.opts.open.current||this.root.hoverCooldown))return;let t=this.opts.openDelay.current;t<=0?this.root.handleHoverOpen():this.#e=this.domContext.setTimeout(()=>{this.root.handleHoverOpen(),this.#e=null},t)}onpointerleave(e){this.opts.disabled.current||this.opts.openOnHover.current&&(rC(e)||(M(this.#n,!1),this.#r(),this.root.hoverCooldown=!1))}onclick(e){if(!this.opts.disabled.current&&e.button===0){if(this.#a(),L(this.#n)&&this.root.opts.open.current&&this.root.openedViaHover){this.root.openedViaHover=!1,this.root.hasInteractedWithContent=!0;return}L(this.#n)&&this.opts.openOnHover.current&&this.root.opts.open.current&&(this.root.hoverCooldown=!0),this.root.hoverCooldown&&!this.root.opts.open.current&&(this.root.hoverCooldown=!1),this.root.toggleOpen()}}onkeydown(e){this.opts.disabled.current||(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),this.#a(),this.root.toggleOpen())}#o(){if(this.root.opts.open.current&&this.root.contentNode?.id)return this.root.contentNode?.id}#s=A(()=>({id:this.opts.id.current,"aria-haspopup":`dialog`,"aria-expanded":wS(this.root.opts.open.current),"data-state":OS(this.root.opts.open.current),"aria-controls":this.#o(),[Wk.trigger]:``,disabled:this.opts.disabled.current,onkeydown:this.onkeydown,onclick:this.onclick,onpointerenter:this.onpointerenter,onpointerleave:this.onpointerleave,...this.attachment}));get props(){return L(this.#s)}set props(e){M(this.#s,e)}},Jk=class e{static create(t){return new e(t,Gk.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=CS(this.opts.ref,e=>this.root.contentNode=e),this.onpointerdown=this.onpointerdown.bind(this),this.onfocusin=this.onfocusin.bind(this),this.onpointerenter=this.onpointerenter.bind(this),this.onpointerleave=this.onpointerleave.bind(this),new Uk({triggerNode:()=>this.root.triggerNode,contentNode:()=>this.root.contentNode,enabled:()=>this.root.opts.open.current&&this.root.openedViaHover&&!this.root.hasInteractedWithContent,onPointerExit:()=>{this.root.handleDelayedHoverClose()}})}onpointerdown(e){this.root.markInteraction()}onfocusin(e){let t=e.target;tC(t)&&xw(t)&&this.root.markInteraction()}onpointerenter(e){rC(e)||this.root.cancelDelayedClose()}onpointerleave(e){rC(e)}onInteractOutside=e=>{if(this.opts.onInteractOutside.current(e),e.defaultPrevented||!tC(e.target))return;let t=e.target.closest(Wk.selector(`trigger`));if(!(t&&t===this.root.triggerNode)){if(this.opts.customAnchor.current){if(tC(this.opts.customAnchor.current)){if(this.opts.customAnchor.current.contains(e.target))return}else if(typeof this.opts.customAnchor.current==`string`){let t=document.querySelector(this.opts.customAnchor.current);if(t&&t.contains(e.target))return}}this.root.handleClose()}};onEscapeKeydown=e=>{this.opts.onEscapeKeydown.current(e),!e.defaultPrevented&&this.root.handleClose()};get shouldRender(){return this.root.contentPresence.shouldRender}get shouldTrapFocus(){return!(this.root.openedViaHover&&!this.root.hasInteractedWithContent)}#e=A(()=>({open:this.root.opts.open.current}));get snippetProps(){return L(this.#e)}set snippetProps(e){M(this.#e,e)}#t=A(()=>({id:this.opts.id.current,tabindex:-1,"data-state":OS(this.root.opts.open.current),[Wk.content]:``,style:{pointerEvents:`auto`,contain:`layout style`},onpointerdown:this.onpointerdown,onfocusin:this.onfocusin,onpointerenter:this.onpointerenter,onpointerleave:this.onpointerleave,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}popperProps={onInteractOutside:this.onInteractOutside,onEscapeKeydown:this.onEscapeKeydown}},Yk=R(`<div><div><!></div></div>`),Xk=R(`<div><div><!></div></div>`);function Zk(e,t){let n=gi();D(t,!0);let r=K(t,`child`,7),i=K(t,`children`,7),a=K(t,`ref`,15,null),o=K(t,`id`,23,()=>lC(n)),s=K(t,`forceMount`,7,!1),c=K(t,`onOpenAutoFocus`,7,$),l=K(t,`onCloseAutoFocus`,7,$),u=K(t,`onEscapeKeydown`,7,$),d=K(t,`onInteractOutside`,7,$),f=K(t,`trapFocus`,7,!0),p=K(t,`preventScroll`,7,!1),m=K(t,`customAnchor`,7,null),h=K(t,`style`,7),g=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`child`,`children`,`ref`,`id`,`forceMount`,`onOpenAutoFocus`,`onCloseAutoFocus`,`onEscapeKeydown`,`onInteractOutside`,`trapFocus`,`preventScroll`,`customAnchor`,`style`]),_=Jk.create({id:Q(()=>o()),ref:Q(()=>a(),e=>a(e)),onInteractOutside:Q(()=>d()),onEscapeKeydown:Q(()=>u()),customAnchor:Q(()=>m())}),v=A(()=>zx(g,_.props)),y=A(()=>f()&&_.shouldTrapFocus);function b(e){_.shouldTrapFocus||e.preventDefault(),c()(e)}var x={get child(){return r()},set child(e){r(e),k()},get children(){return i()},set children(e){i(e),k()},get ref(){return a()},set ref(e=null){a(e),k()},get id(){return o()},set id(e=lC(n)){o(e),k()},get forceMount(){return s()},set forceMount(e=!1){s(e),k()},get onOpenAutoFocus(){return c()},set onOpenAutoFocus(e=$){c(e),k()},get onCloseAutoFocus(){return l()},set onCloseAutoFocus(e=$){l(e),k()},get onEscapeKeydown(){return u()},set onEscapeKeydown(e=$){u(e),k()},get onInteractOutside(){return d()},set onInteractOutside(e=$){d(e),k()},get trapFocus(){return f()},set trapFocus(e=!0){f(e),k()},get preventScroll(){return p()},set preventScroll(e=!1){p(e),k()},get customAnchor(){return m()},set customAnchor(e=null){m(e),k()},get style(){return h()},set style(e){h(e),k()}},S=z(),C=P(S),ee=e=>{sk(e,mo(()=>L(v),()=>_.popperProps,{get ref(){return _.opts.ref},get enabled(){return _.root.opts.open.current},get id(){return o()},get trapFocus(){return L(y)},get preventScroll(){return p()},loop:!0,forceMount:!0,get customAnchor(){return m()},onOpenAutoFocus:b,get onCloseAutoFocus(){return l()},get shouldRender(){return _.shouldRender},popper:(e,t)=>{let n=()=>t?.().props,a=()=>t?.().wrapperProps,o=A(()=>zx(n(),{style:fO(`popover`)},{style:h()}));var s=z(),c=P(s),l=e=>{var t=z(),n=P(t);{let e=A(()=>({props:L(o),wrapperProps:a(),..._.snippetProps}));H(n,r,()=>L(e))}B(e,t)},u=e=>{var t=Yk();Ja(t,()=>({...a()}));var n=N(t);Ja(n,()=>({...L(o)})),H(N(n),()=>i()??w),E(n),E(t),B(e,t)};U(c,e=>{r()?e(l):e(u,-1)}),B(e,s)},$$slots:{popper:!0}}))},te=e=>{ok(e,mo(()=>L(v),()=>_.popperProps,{get ref(){return _.opts.ref},get open(){return _.root.opts.open.current},get id(){return o()},get trapFocus(){return L(y)},get preventScroll(){return p()},loop:!0,forceMount:!1,get customAnchor(){return m()},onOpenAutoFocus:b,get onCloseAutoFocus(){return l()},get shouldRender(){return _.shouldRender},popper:(e,t)=>{let n=()=>t?.().props,a=()=>t?.().wrapperProps,o=A(()=>zx(n(),{style:fO(`popover`)},{style:h()}));var s=z(),c=P(s),l=e=>{var t=z(),n=P(t);{let e=A(()=>({props:L(o),wrapperProps:a(),..._.snippetProps}));H(n,r,()=>L(e))}B(e,t)},u=e=>{var t=Xk();Ja(t,()=>({...a()}));var n=N(t);Ja(n,()=>({...L(o)})),H(N(n),()=>i()??w),E(n),E(t),B(e,t)};U(c,e=>{r()?e(l):e(u,-1)}),B(e,s)},$$slots:{popper:!0}}))};return U(C,e=>{s()?e(ee):s()||e(te,1)}),B(e,S),O(x)}q(Zk,{child:{},children:{},ref:{},id:{},forceMount:{},onOpenAutoFocus:{},onCloseAutoFocus:{},onEscapeKeydown:{},onInteractOutside:{},trapFocus:{},preventScroll:{},customAnchor:{},style:{}},[],[],{mode:`open`});var Qk=R(`<button><!></button>`);function $k(e,t){let n=gi();D(t,!0);let r=K(t,`children`,7),i=K(t,`child`,7),a=K(t,`id`,23,()=>lC(n)),o=K(t,`ref`,15,null),s=K(t,`type`,7,`button`),c=K(t,`disabled`,7,!1),l=K(t,`openOnHover`,7,!1),u=K(t,`openDelay`,7,700),d=K(t,`closeDelay`,7,300),f=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`children`,`child`,`id`,`ref`,`type`,`disabled`,`openOnHover`,`openDelay`,`closeDelay`]),p=qk.create({id:Q(()=>a()),ref:Q(()=>o(),e=>o(e)),disabled:Q(()=>!!c()),openOnHover:Q(()=>l()),openDelay:Q(()=>u()),closeDelay:Q(()=>d())}),m=A(()=>zx(f,p.props,{type:s()}));return XO(e,{get id(){return a()},get ref(){return p.opts.ref},children:(e,t)=>{var n=z(),a=P(n),o=e=>{var t=z();H(P(t),i,()=>({props:L(m)})),B(e,t)},s=e=>{var t=Qk();Ja(t,()=>({...L(m)})),H(N(t),()=>r()??w),E(t),B(e,t)};U(a,e=>{i()?e(o):e(s,-1)}),B(e,n)},$$slots:{default:!0}}),O({get children(){return r()},set children(e){r(e),k()},get child(){return i()},set child(e){i(e),k()},get id(){return a()},set id(e=lC(n)){a(e),k()},get ref(){return o()},set ref(e=null){o(e),k()},get type(){return s()},set type(e=`button`){s(e),k()},get disabled(){return c()},set disabled(e=!1){c(e),k()},get openOnHover(){return l()},set openOnHover(e=!1){l(e),k()},get openDelay(){return u()},set openDelay(e=700){u(e),k()},get closeDelay(){return d()},set closeDelay(e=300){d(e),k()}})}q($k,{children:{},child:{},id:{},ref:{},type:{},disabled:{},openOnHover:{},openDelay:{},closeDelay:{}},[],[],{mode:`open`});function eA(e,t){D(t,!0);let n=K(t,`open`,15,!1),r=K(t,`onOpenChange`,7,$),i=K(t,`onOpenChangeComplete`,7,$),a=K(t,`children`,7);fC.create({variant:Q(()=>`dialog`),open:Q(()=>n(),e=>{n(e),r()(e)}),onOpenChangeComplete:Q(()=>i())});var o={get open(){return n()},set open(e=!1){n(e),k()},get onOpenChange(){return r()},set onOpenChange(e=$){r(e),k()},get onOpenChangeComplete(){return i()},set onOpenChangeComplete(e=$){i(e),k()},get children(){return a()},set children(e){a(e),k()}},s=z();return H(P(s),()=>a()??w),B(e,s),O(o)}q(eA,{open:{},onOpenChange:{},onOpenChangeComplete:{},children:{}},[],[],{mode:`open`});var tA=R(`<button><!></button>`);function nA(e,t){let n=gi();D(t,!0);let r=K(t,`children`,7),i=K(t,`child`,7),a=K(t,`id`,23,()=>lC(n)),o=K(t,`ref`,15,null),s=K(t,`disabled`,7,!1),c=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`children`,`child`,`id`,`ref`,`disabled`]),l=pC.create({variant:Q(()=>`close`),id:Q(()=>a()),ref:Q(()=>o(),e=>o(e)),disabled:Q(()=>!!s())}),u=A(()=>zx(c,l.props));var d={get children(){return r()},set children(e){r(e),k()},get child(){return i()},set child(e){i(e),k()},get id(){return a()},set id(e=lC(n)){a(e),k()},get ref(){return o()},set ref(e=null){o(e),k()},get disabled(){return s()},set disabled(e=!1){s(e),k()}},f=z(),p=P(f),m=e=>{var t=z();H(P(t),i,()=>({props:L(u)})),B(e,t)},h=e=>{var t=tA();Ja(t,()=>({...L(u)})),H(N(t),()=>r()??w),E(t),B(e,t)};return U(p,e=>{i()?e(m):e(h,-1)}),B(e,f),O(d)}q(nA,{children:{},child:{},id:{},ref:{},disabled:{}},[],[],{mode:`open`});var rA=R(`<!> <!>`,1),iA=R(`<!> <div><!></div>`,1);function aA(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>lC(n)),i=K(t,`children`,7),a=K(t,`child`,7),o=K(t,`ref`,15,null),s=K(t,`forceMount`,7,!1),c=K(t,`onCloseAutoFocus`,7,$),l=K(t,`onOpenAutoFocus`,7,$),u=K(t,`onEscapeKeydown`,7,$),d=K(t,`onInteractOutside`,7,$),f=K(t,`trapFocus`,7,!0),p=K(t,`preventScroll`,7,!0),m=K(t,`restoreScrollDelay`,7,null),h=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`children`,`child`,`ref`,`forceMount`,`onCloseAutoFocus`,`onOpenAutoFocus`,`onEscapeKeydown`,`onInteractOutside`,`trapFocus`,`preventScroll`,`restoreScrollDelay`]),g=gC.create({id:Q(()=>r()),ref:Q(()=>o(),e=>o(e))}),_=A(()=>zx(h,g.props));var v={get id(){return r()},set id(e=lC(n)){r(e),k()},get children(){return i()},set children(e){i(e),k()},get child(){return a()},set child(e){a(e),k()},get ref(){return o()},set ref(e=null){o(e),k()},get forceMount(){return s()},set forceMount(e=!1){s(e),k()},get onCloseAutoFocus(){return c()},set onCloseAutoFocus(e=$){c(e),k()},get onOpenAutoFocus(){return l()},set onOpenAutoFocus(e=$){l(e),k()},get onEscapeKeydown(){return u()},set onEscapeKeydown(e=$){u(e),k()},get onInteractOutside(){return d()},set onInteractOutside(e=$){d(e),k()},get trapFocus(){return f()},set trapFocus(e=!0){f(e),k()},get preventScroll(){return p()},set preventScroll(e=!0){p(e),k()},get restoreScrollDelay(){return m()},set restoreScrollDelay(e=null){m(e),k()}},y=z(),b=P(y),x=e=>{ET(e,{get ref(){return g.opts.ref},loop:!0,get trapFocus(){return f()},get enabled(){return g.root.opts.open.current},get onOpenAutoFocus(){return l()},get onCloseAutoFocus(){return c()},focusScope:(e,t)=>{let n=()=>t?.().props;CT(e,mo(()=>L(_),{get enabled(){return g.root.opts.open.current},get ref(){return g.opts.ref},onEscapeKeydown:e=>{u()(e),!e.defaultPrevented&&g.root.handleClose()},children:(e,t)=>{bT(e,mo(()=>L(_),{get ref(){return g.opts.ref},get enabled(){return g.root.opts.open.current},onInteractOutside:e=>{d()(e),!e.defaultPrevented&&g.root.handleClose()},children:(e,t)=>{MT(e,mo(()=>L(_),{get ref(){return g.opts.ref},get enabled(){return g.root.opts.open.current},children:(e,t)=>{var r=z(),o=P(r),s=e=>{var t=rA(),r=P(t),i=e=>{GT(e,{get preventScroll(){return p()},get restoreScrollDelay(){return m()}})};U(r,e=>{g.root.opts.open.current&&e(i)});var o=F(r,2);{let e=A(()=>({props:zx(L(_),n()),...g.snippetProps}));H(o,a,()=>L(e))}B(e,t)},c=e=>{var t=iA(),r=P(t);GT(r,{get preventScroll(){return p()}});var a=F(r,2);Ja(a,e=>({...e}),[()=>zx(L(_),n())]),H(N(a),()=>i()??w),E(a),B(e,t)};U(o,e=>{a()?e(s):e(c,-1)}),B(e,r)},$$slots:{default:!0}}))},$$slots:{default:!0}}))},$$slots:{default:!0}}))},$$slots:{focusScope:!0}})};return U(b,e=>{(g.shouldRender||s())&&e(x)}),B(e,y),O(v)}q(aA,{id:{},children:{},child:{},ref:{},forceMount:{},onCloseAutoFocus:{},onOpenAutoFocus:{},onEscapeKeydown:{},onInteractOutside:{},trapFocus:{},preventScroll:{},restoreScrollDelay:{}},[],[],{mode:`open`});function oA(e,t){D(t,!0);let n=K(t,`open`,15,!1),r=K(t,`dir`,7,`ltr`),i=K(t,`onOpenChange`,7,$),a=K(t,`onOpenChangeComplete`,7,$),o=K(t,`_internal_variant`,7,`dropdown-menu`),s=K(t,`children`,7),c=nT.create({variant:Q(()=>o()),dir:Q(()=>r()),onClose:()=>{n(!1),i()(!1)}});return rT.create({open:Q(()=>n(),e=>{n(e),i()(e)}),onOpenChangeComplete:Q(()=>a())},c),EO(e,{children:(e,t)=>{var n=z();H(P(n),()=>s()??w),B(e,n)},$$slots:{default:!0}}),O({get open(){return n()},set open(e=!1){n(e),k()},get dir(){return r()},set dir(e=`ltr`){r(e),k()},get onOpenChange(){return i()},set onOpenChange(e=$){i(e),k()},get onOpenChangeComplete(){return a()},set onOpenChangeComplete(e=$){a(e),k()},get _internal_variant(){return o()},set _internal_variant(e=`dropdown-menu`){o(e),k()},get children(){return s()},set children(e){s(e),k()}})}q(oA,{open:{},dir:{},onOpenChange:{},onOpenChangeComplete:{},_internal_variant:{},children:{}},[],[],{mode:`open`});var sA=R(`<div><div><!></div></div>`),cA=R(`<div><div><!></div></div>`);function lA(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>lC(n)),i=K(t,`child`,7),a=K(t,`children`,7),o=K(t,`ref`,15,null),s=K(t,`loop`,7,!0),c=K(t,`onInteractOutside`,7,$),l=K(t,`onEscapeKeydown`,7,$),u=K(t,`onCloseAutoFocus`,7,$),d=K(t,`forceMount`,7,!1),f=K(t,`trapFocus`,7,!1),p=K(t,`style`,7),m=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`child`,`children`,`ref`,`loop`,`onInteractOutside`,`onEscapeKeydown`,`onCloseAutoFocus`,`forceMount`,`trapFocus`,`style`]),h=iT.create({id:Q(()=>r()),loop:Q(()=>s()),ref:Q(()=>o(),e=>o(e)),onCloseAutoFocus:Q(()=>u())}),g=A(()=>zx(m,h.props));function _(e){if(h.handleInteractOutside(e),!e.defaultPrevented&&(c()(e),!e.defaultPrevented)){if(e.target&&e.target instanceof Element){let t=`[${h.parentMenu.root.getBitsAttr(`sub-content`)}]`;if(e.target.closest(t))return}h.parentMenu.onClose()}}function v(e){l()(e),!e.defaultPrevented&&h.parentMenu.onClose()}var y={get id(){return r()},set id(e=lC(n)){r(e),k()},get child(){return i()},set child(e){i(e),k()},get children(){return a()},set children(e){a(e),k()},get ref(){return o()},set ref(e=null){o(e),k()},get loop(){return s()},set loop(e=!0){s(e),k()},get onInteractOutside(){return c()},set onInteractOutside(e=$){c(e),k()},get onEscapeKeydown(){return l()},set onEscapeKeydown(e=$){l(e),k()},get onCloseAutoFocus(){return u()},set onCloseAutoFocus(e=$){u(e),k()},get forceMount(){return d()},set forceMount(e=!1){d(e),k()},get trapFocus(){return f()},set trapFocus(e=!1){f(e),k()},get style(){return p()},set style(e){p(e),k()}},b=z(),x=P(b),S=e=>{sk(e,mo(()=>L(g),()=>h.popperProps,{get ref(){return h.opts.ref},get enabled(){return h.parentMenu.opts.open.current},onInteractOutside:_,onEscapeKeydown:v,get trapFocus(){return f()},get loop(){return s()},forceMount:!0,get id(){return r()},get shouldRender(){return h.shouldRender},popper:(e,t)=>{let n=()=>t?.().props,r=()=>t?.().wrapperProps,o=A(()=>zx(n(),{style:fO(`dropdown-menu`)},{style:p()}));var s=z(),c=P(s),l=e=>{var t=z(),n=P(t);{let e=A(()=>({props:L(o),wrapperProps:r(),...h.snippetProps}));H(n,i,()=>L(e))}B(e,t)},u=e=>{var t=sA();Ja(t,()=>({...r()}));var n=N(t);Ja(n,()=>({...L(o)})),H(N(n),()=>a()??w),E(n),E(t),B(e,t)};U(c,e=>{i()?e(l):e(u,-1)}),B(e,s)},$$slots:{popper:!0}}))},C=e=>{ok(e,mo(()=>L(g),()=>h.popperProps,{get ref(){return h.opts.ref},get open(){return h.parentMenu.opts.open.current},onInteractOutside:_,onEscapeKeydown:v,get trapFocus(){return f()},get loop(){return s()},forceMount:!1,get id(){return r()},get shouldRender(){return h.shouldRender},popper:(e,t)=>{let n=()=>t?.().props,r=()=>t?.().wrapperProps,o=A(()=>zx(n(),{style:fO(`dropdown-menu`)},{style:p()}));var s=z(),c=P(s),l=e=>{var t=z(),n=P(t);{let e=A(()=>({props:L(o),wrapperProps:r(),...h.snippetProps}));H(n,i,()=>L(e))}B(e,t)},u=e=>{var t=cA();Ja(t,()=>({...r()}));var n=N(t);Ja(n,()=>({...L(o)})),H(N(n),()=>a()??w),E(n),E(t),B(e,t)};U(c,e=>{i()?e(l):e(u,-1)}),B(e,s)},$$slots:{popper:!0}}))};return U(x,e=>{d()?e(S):d()||e(C,1)}),B(e,b),O(y)}q(lA,{id:{},child:{},children:{},ref:{},loop:{},onInteractOutside:{},onEscapeKeydown:{},onCloseAutoFocus:{},forceMount:{},trapFocus:{},style:{}},[],[],{mode:`open`});var uA=R(`<button><!></button>`);function dA(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>lC(n)),i=K(t,`ref`,15,null),a=K(t,`child`,7),o=K(t,`children`,7),s=K(t,`disabled`,7,!1),c=K(t,`type`,7,`button`),l=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`ref`,`child`,`children`,`disabled`,`type`]),u=pT.create({id:Q(()=>r()),disabled:Q(()=>s()??!1),ref:Q(()=>i(),e=>i(e))}),d=A(()=>zx(l,u.props,{type:c()}));return XO(e,{get id(){return r()},get ref(){return u.opts.ref},children:(e,t)=>{var n=z(),r=P(n),i=e=>{var t=z();H(P(t),a,()=>({props:L(d)})),B(e,t)},s=e=>{var t=uA();Ja(t,()=>({...L(d)})),H(N(t),()=>o()??w),E(t),B(e,t)};U(r,e=>{a()?e(i):e(s,-1)}),B(e,n)},$$slots:{default:!0}}),O({get id(){return r()},set id(e=lC(n)){r(e),k()},get ref(){return i()},set ref(e=null){i(e),k()},get child(){return a()},set child(e){a(e),k()},get children(){return o()},set children(e){o(e),k()},get disabled(){return s()},set disabled(e=!1){s(e),k()},get type(){return c()},set type(e=`button`){c(e),k()}})}q(dA,{id:{},ref:{},child:{},children:{},disabled:{},type:{}},[],[],{mode:`open`});var fA=jS({component:`label`,parts:[`root`]}),pA=class e{static create(t){return new e(t)}opts;attachment;constructor(e){this.opts=e,this.attachment=CS(this.opts.ref),this.onmousedown=this.onmousedown.bind(this)}onmousedown(e){e.detail>1&&e.preventDefault()}#e=A(()=>({id:this.opts.id.current,[fA.root]:``,onmousedown:this.onmousedown,...this.attachment}));get props(){return L(this.#e)}set props(e){M(this.#e,e)}},mA=R(`<label><!></label>`);function hA(e,t){let n=gi();D(t,!0);let r=K(t,`children`,7),i=K(t,`child`,7),a=K(t,`id`,23,()=>lC(n)),o=K(t,`ref`,15,null),s=K(t,`for`,7),c=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`children`,`child`,`id`,`ref`,`for`]),l=pA.create({id:Q(()=>a()),ref:Q(()=>o(),e=>o(e))}),u=A(()=>zx(c,l.props,{for:s()}));var d={get children(){return r()},set children(e){r(e),k()},get child(){return i()},set child(e){i(e),k()},get id(){return a()},set id(e=lC(n)){a(e),k()},get ref(){return o()},set ref(e=null){o(e),k()},get for(){return s()},set for(e){s(e),k()}},f=z(),p=P(f),m=e=>{var t=z();H(P(t),i,()=>({props:L(u)})),B(e,t)},h=e=>{var t=mA();Ja(t,()=>({...L(u),for:s()})),H(N(t),()=>r()??w),E(t),B(e,t)};return U(p,e=>{i()?e(m):e(h,-1)}),B(e,f),O(d)}q(hA,{children:{},child:{},id:{},ref:{},for:{}},[],[],{mode:`open`});function gA(e,t){D(t,!0);let n=K(t,`open`,15,!1),r=K(t,`onOpenChange`,7,$),i=K(t,`onOpenChangeComplete`,7,$),a=K(t,`children`,7);return Kk.create({open:Q(()=>n(),e=>{n(e),r()(e)}),onOpenChangeComplete:Q(()=>i())}),EO(e,{children:(e,t)=>{var n=z();H(P(n),()=>a()??w),B(e,n)},$$slots:{default:!0}}),O({get open(){return n()},set open(e=!1){n(e),k()},get onOpenChange(){return r()},set onOpenChange(e=$){r(e),k()},get onOpenChangeComplete(){return i()},set onOpenChangeComplete(e=$){i(e),k()},get children(){return a()},set children(e){a(e),k()}})}q(gA,{open:{},onOpenChange:{},onOpenChangeComplete:{},children:{}},[],[],{mode:`open`});function _A(e){return e<.5?8*e**4:-8*(e-1)**4+1}function vA(e){return e**4}function yA(e){return(e-1)**3*(1-e)+1}function bA(e){return--e*e*e*e*e+1}var xA=e=>e;function SA(e){let t=e-1;return t*t*t+1}function CA(e){let t=typeof e==`string`&&e.match(/^\s*(-?[\d.]+)([^\s]*)\s*$/);return t?[parseFloat(t[1]),t[2]||`px`]:[e,`px`]}function wA(e,{delay:t=0,duration:n=400,easing:r=xA}={}){let i=+getComputedStyle(e).opacity;return{delay:t,duration:n,easing:r,css:e=>`opacity: ${e*i}`}}function TA(e,{delay:t=0,duration:n=400,easing:r=SA,x:i=0,y:a=0,opacity:o=0}={}){let s=getComputedStyle(e),c=+s.opacity,l=s.transform===`none`?``:s.transform,u=c*(1-o),[d,f]=CA(i),[p,m]=CA(a);return{delay:t,duration:n,easing:r,css:(e,t)=>`
|
|
568
|
+
transform 200ms;}.sonner-loader[data-visible='false'] {opacity:0;transform:scale(0.8) translate(-50%, -50%);}`};function _y(e,t){D(t,!0),ga(e,gy);function n(e){return e===`system`?typeof window<`u`&&window.matchMedia&&window.matchMedia(`(prefers-color-scheme: dark)`).matches?dy:fy:e}let r=K(t,`invert`,7,!1),i=K(t,`position`,7,`bottom-right`),a=K(t,`hotkey`,23,()=>[`altKey`,`KeyT`]),o=K(t,`expand`,7,!1),s=K(t,`closeButton`,7,!1),c=K(t,`offset`,7,oy),l=K(t,`mobileOffset`,7,sy),u=K(t,`theme`,7,`light`),d=K(t,`richColors`,7,!1),f=K(t,`duration`,7,cy),p=K(t,`visibleToasts`,7,ay),m=K(t,`toastOptions`,23,()=>({})),h=K(t,`dir`,7,`auto`),g=K(t,`gap`,7,uy),_=K(t,`pauseWhenPageIsHidden`,7,!1),v=K(t,`loadingIcon`,7),y=K(t,`successIcon`,7),b=K(t,`errorIcon`,7),x=K(t,`warningIcon`,7),S=K(t,`closeIcon`,7),C=K(t,`infoIcon`,7),ee=K(t,`containerAriaLabel`,7,`Notifications`),te=K(t,`class`,7),ne=K(t,`closeButtonAriaLabel`,7,`Close toast`),re=K(t,`onblur`,7),ie=K(t,`onfocus`,7),ae=K(t,`onmouseenter`,7),oe=K(t,`onmousemove`,7),se=K(t,`onmouseleave`,7),ce=K(t,`ondragend`,7),le=K(t,`onpointerdown`,7),ue=K(t,`onpointerup`,7),de=fo(t,`$$slots.$$events.$$legacy.$$host.invert.position.hotkey.expand.closeButton.offset.mobileOffset.theme.richColors.duration.visibleToasts.toastOptions.dir.gap.pauseWhenPageIsHidden.loadingIcon.successIcon.errorIcon.warningIcon.closeIcon.infoIcon.containerAriaLabel.class.closeButtonAriaLabel.onblur.onfocus.onmouseenter.onmousemove.onmouseleave.ondragend.onpointerdown.onpointerup`.split(`.`));function fe(){if(h()!==`auto`)return h();if(typeof window>`u`||typeof document>`u`)return`ltr`;let e=document.documentElement.getAttribute(`dir`);return e===`auto`||!e?(Xr(()=>h(window.getComputedStyle(document.documentElement).direction??`ltr`)),h()):(Xr(()=>h(e)),e)}let pe=A(()=>Array.from(new Set([i(),...Ev.toasts.filter(e=>e.position).map(e=>e.position)].filter(Boolean)))),me=j(!1),he=j(!1),ge=j(Dn(n(u()))),_e=j(void 0),ve=j(null),ye=j(!1),be=A(()=>a().join(`+`).replace(/Key/g,``).replace(/Digit/g,``));$n(()=>{Ev.toasts.length<=1&&M(me,!1)}),$n(()=>{let e=Ev.toasts.filter(e=>e.dismiss&&!e.delete);e.length>0&&(Ev.toasts=Ev.toasts.map(t=>e.find(e=>e.id===t.id)?{...t,delete:!0}:t))}),$n(()=>()=>{L(_e)&&L(ve)&&(L(ve).focus({preventScroll:!0}),M(ve,null),M(ye,!1))}),Ii(()=>(Ev.reset(),ri(document,`keydown`,e=>{a().every(t=>e[t]||e.code===t)&&(M(me,!0),L(_e)?.focus()),e.code===`Escape`&&(document.activeElement===L(_e)||L(_e)?.contains(document.activeElement))&&M(me,!1)}))),$n(()=>{if(u()!==`system`&&M(ge,u()),typeof window<`u`){u()===`system`&&(window.matchMedia&&window.matchMedia(`(prefers-color-scheme: dark)`).matches?M(ge,dy):M(ge,fy));let e=window.matchMedia(`(prefers-color-scheme: dark)`),t=({matches:e})=>{u()===`system`&&M(ge,e?dy:fy,!0)};`addEventListener`in e?e.addEventListener(`change`,t):e.addListener(t)}});let xe=e=>{re()?.(e),L(ye)&&!e.currentTarget.contains(e.relatedTarget)&&(M(ye,!1),L(ve)&&(L(ve).focus({preventScroll:!0}),M(ve,null)))},Se=e=>{ie()?.(e),!(e.target instanceof HTMLElement&&e.target.dataset.dismissible===`false`)&&(L(ye)||(M(ye,!0),M(ve,e.relatedTarget,!0)))},Ce=e=>{le()?.(e),!(e.target instanceof HTMLElement&&e.target.dataset.dismissible===`false`)&&M(he,!0)},we=e=>{ae()?.(e),M(me,!0)},Te=e=>{se()?.(e),L(he)||M(me,!1)},Ee=e=>{oe()?.(e),M(me,!0)},De=e=>{ce()?.(e),M(me,!1)},Oe=e=>{ue()?.(e),M(he,!1)};Sv.set(new Ov);var ke={get invert(){return r()},set invert(e=!1){r(e),k()},get position(){return i()},set position(e=`bottom-right`){i(e),k()},get hotkey(){return a()},set hotkey(e=[`altKey`,`KeyT`]){a(e),k()},get expand(){return o()},set expand(e=!1){o(e),k()},get closeButton(){return s()},set closeButton(e=!1){s(e),k()},get offset(){return c()},set offset(e=oy){c(e),k()},get mobileOffset(){return l()},set mobileOffset(e=sy){l(e),k()},get theme(){return u()},set theme(e=`light`){u(e),k()},get richColors(){return d()},set richColors(e=!1){d(e),k()},get duration(){return f()},set duration(e=cy){f(e),k()},get visibleToasts(){return p()},set visibleToasts(e=ay){p(e),k()},get toastOptions(){return m()},set toastOptions(e={}){m(e),k()},get dir(){return h()},set dir(e=`auto`){h(e),k()},get gap(){return g()},set gap(e=uy){g(e),k()},get pauseWhenPageIsHidden(){return _()},set pauseWhenPageIsHidden(e=!1){_(e),k()},get loadingIcon(){return v()},set loadingIcon(e){v(e),k()},get successIcon(){return y()},set successIcon(e){y(e),k()},get errorIcon(){return b()},set errorIcon(e){b(e),k()},get warningIcon(){return x()},set warningIcon(e){x(e),k()},get closeIcon(){return S()},set closeIcon(e){S(e),k()},get infoIcon(){return C()},set infoIcon(e){C(e),k()},get containerAriaLabel(){return ee()},set containerAriaLabel(e=`Notifications`){ee(e),k()},get class(){return te()},set class(e){te(e),k()},get closeButtonAriaLabel(){return ne()},set closeButtonAriaLabel(e=`Close toast`){ne(e),k()},get onblur(){return re()},set onblur(e){re(e),k()},get onfocus(){return ie()},set onfocus(e){ie(e),k()},get onmouseenter(){return ae()},set onmouseenter(e){ae(e),k()},get onmousemove(){return oe()},set onmousemove(e){oe(e),k()},get onmouseleave(){return se()},set onmouseleave(e){se(e),k()},get ondragend(){return ce()},set ondragend(e){ce(e),k()},get onpointerdown(){return le()},set onpointerdown(e){le(e),k()},get onpointerup(){return ue()},set onpointerup(e){ue(e),k()}},Ae=hy();G(Ae,`tabindex`,-1);var je=N(Ae),Me=e=>{var n=z();Xi(P(n),18,()=>L(pe),e=>e,(e,n,i,a)=>{let u=A(()=>{let[e,t]=n.split(`-`);return{y:e,x:t}}),h=A(()=>py(c(),l()));var ee=my();Ja(ee,e=>({tabindex:-1,dir:e,class:te(),"data-sonner-toaster":!0,"data-sonner-theme":L(ge),"data-y-position":L(u).y,"data-x-position":L(u).x,style:t.style,onblur:xe,onfocus:Se,onmouseenter:we,onmousemove:Ee,onmouseleave:Te,ondragend:De,onpointerdown:Ce,onpointerup:Oe,...de,[Fa]:{"--front-toast-height":`${Ev.heights[0]?.height}px`,"--width":`${ly}px`,"--gap":`${g()}px`,"--offset-top":L(h)[`--offset-top`],"--offset-right":L(h)[`--offset-right`],"--offset-bottom":L(h)[`--offset-bottom`],"--offset-left":L(h)[`--offset-left`],"--mobile-offset-top":L(h)[`--mobile-offset-top`],"--mobile-offset-right":L(h)[`--mobile-offset-right`],"--mobile-offset-bottom":L(h)[`--mobile-offset-bottom`],"--mobile-offset-left":L(h)[`--mobile-offset-left`]}}),[()=>fe()],void 0,void 0,`svelte-s0xby2`),Xi(ee,23,()=>Ev.toasts.filter(e=>!e.position&&L(i)===0||e.position===n),e=>e.id,(e,t,i,a)=>{{let a=e=>{var t=z(),n=P(t),r=e=>{var t=z();H(P(t),()=>y()??w),B(e,t)},i=e=>{Xv(e,{})};U(n,e=>{y()?e(r):y()!==null&&e(i,1)}),B(e,t)},c=e=>{var t=z(),n=P(t),r=e=>{var t=z();H(P(t),()=>b()??w),B(e,t)},i=e=>{Qv(e,{})};U(n,e=>{b()?e(r):b()!==null&&e(i,1)}),B(e,t)},l=e=>{var t=z(),n=P(t),r=e=>{var t=z();H(P(t),()=>x()??w),B(e,t)},i=e=>{ey(e,{})};U(n,e=>{x()?e(r):x()!==null&&e(i,1)}),B(e,t)},u=e=>{var t=z(),n=P(t),r=e=>{var t=z();H(P(t),()=>C()??w),B(e,t)},i=e=>{ny(e,{})};U(n,e=>{C()?e(r):C()!==null&&e(i,1)}),B(e,t)},h=e=>{var t=z(),n=P(t),r=e=>{var t=z();H(P(t),()=>S()??w),B(e,t)},i=e=>{iy(e,{})};U(n,e=>{S()?e(r):S()!==null&&e(i,1)}),B(e,t)},g=A(()=>m()?.duration??f()),ee=A(()=>m()?.class??``),te=A(()=>m()?.descriptionClass||``),re=A(()=>m()?.style??``),ie=A(()=>m().classes||{}),ae=A(()=>m().unstyled??!1),oe=A(()=>m()?.cancelButtonStyle??``),se=A(()=>m()?.actionButtonStyle??``),ce=A(()=>m()?.closeButtonAriaLabel??ne());Jv(e,{get index(){return L(i)},get toast(){return L(t)},get defaultRichColors(){return d()},get duration(){return L(g)},get class(){return L(ee)},get descriptionClass(){return L(te)},get invert(){return r()},get visibleToasts(){return p()},get closeButton(){return s()},get interacting(){return L(he)},get position(){return n},get style(){return L(re)},get classes(){return L(ie)},get unstyled(){return L(ae)},get cancelButtonStyle(){return L(oe)},get actionButtonStyle(){return L(se)},get closeButtonAriaLabel(){return L(ce)},get expandByDefault(){return o()},get expanded(){return L(me)},get pauseWhenPageIsHidden(){return _()},get loadingIcon(){return v()},successIcon:a,errorIcon:c,warningIcon:l,infoIcon:u,closeIcon:h,$$slots:{successIcon:!0,errorIcon:!0,warningIcon:!0,infoIcon:!0,closeIcon:!0}})}}),E(ee),so(ee,e=>M(_e,e),()=>L(_e)),I(()=>ee.dir=ee.dir),B(e,ee)}),B(e,n)};return U(je,e=>{Ev.toasts.length>0&&e(Me)}),E(Ae),I(()=>G(Ae,`aria-label`,`${ee()??``} ${L(be)??``}`)),B(e,Ae),O(ke)}q(_y,{invert:{},position:{},hotkey:{},expand:{},closeButton:{},offset:{},mobileOffset:{},theme:{},richColors:{},duration:{},visibleToasts:{},toastOptions:{},dir:{},gap:{},pauseWhenPageIsHidden:{},loadingIcon:{},successIcon:{},errorIcon:{},warningIcon:{},closeIcon:{},infoIcon:{},containerAriaLabel:{},class:{},closeButtonAriaLabel:{},onblur:{},onfocus:{},onmouseenter:{},onmousemove:{},onmouseleave:{},ondragend:{},onpointerdown:{},onpointerup:{}},[],[],{mode:`open`});var vy=e=>{let t=new Set;Object.getOwnPropertyNames(e).forEach(e=>t.add(e));let n=Object.getPrototypeOf(e);for(;n&&n!==Object.prototype;)Object.getOwnPropertyNames(n).forEach(e=>t.add(e)),n=Object.getPrototypeOf(n);return Array.from(t)},yy=(e,t)=>{let n={};return t.forEach(t=>{n[t]=e[t]}),n},by=console.warn,xy=()=>{},Sy=(e,t)=>Xr(()=>{console.warn=xy;let n=st(t?yy(e,t):e);return console.warn=by,n}),Cy=e=>e&&typeof e.then==`function`,wy=class{config;self;devtools;stateKeys;constructor(e,t){this.config=e,this.self=t,typeof window<`u`&&window.__REDUX_DEVTOOLS_EXTENSION__&&(this.stateKeys=vy(this.config.state),this.devtools=window.__REDUX_DEVTOOLS_EXTENSION__.connect({name:this.config.name??`updatelogic`}),this.devtools.init(this.createStateSnapshot()),this.devtools.subscribe(e=>{e.type===`DISPATCH`&&e.state}))}createStateSnapshot(){return Sy(this.config.state,this.stateKeys)}sendStart(e,t){this.devtools.send({type:`→ ${e}`,args:t},this.createStateSnapshot())}sendError(e,t,n){this.devtools.send({type:`❌ ${e}`,args:t,error:n},this.createStateSnapshot())}sendSuccess(e,t,n){this.devtools.send({type:`✓ ${e}`,args:t,return:n},this.createStateSnapshot())}isIncluded(e){return this.config.excludeInDevTools?!this.config.excludeInDevTools.includes(e):!0}createProxyFunction(e,t){let n=this.devtools&&this.isIncluded(e);return typeof t==`function`?(...r)=>{if(!n)return Xr(()=>t.call(this.self,...r));let i=Sy(r);this.sendStart(e,i);try{let n=Xr(()=>t.call(this.self,...r));return Cy(n)?n.then(t=>(this.sendSuccess(e,i,t),t),t=>{throw this.sendError(e,i,t),t}):(this.sendSuccess(e,i,n),n)}catch(t){throw this.sendError(e,i,t),t}}:t}},Ty=(e,t)=>{let n={},r=new wy(e,n);return Object.keys(t).forEach(e=>{if(e===`state`||e===`name`)return;let i=t[e];n[e]=r.createProxyFunction(e,i)}),n};async function Ey(){if(typeof navigator>`u`||!navigator.mediaDevices||!navigator.mediaDevices.enumerateDevices)return!1;try{return(await navigator.mediaDevices.enumerateDevices()).some(e=>e.kind===`audioinput`)}catch(e){return console.error(`Error checking for microphone:`,e),!1}}function Dy(){return typeof window>`u`||!window.MediaRecorder?null:MediaRecorder.isTypeSupported(`audio/mp4`)?`audio/mp4`:MediaRecorder.isTypeSupported(`audio/webm`)?`audio/webm`:MediaRecorder.isTypeSupported(`audio/wav`)?`audio/wav`:null}function Oy(){return typeof window>`u`?!1:!!(window.MediaRecorder&&Dy())}function ky(){if(typeof window>`u`)return!1;if(`ontouchstart`in window||navigator.maxTouchPoints>0)return!0;let e=navigator.msMaxTouchPoints;return!!(`msMaxTouchPoints`in navigator&&e&&e>0)}function Ay(){return typeof window>`u`?!1:!!(/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)||ky())}var jy=class{mediaRecorder=null;audioChunks=[];started=!1;starting=!1;stream=null;options;audioContext=null;analyser=null;dataArray=null;volumeUpdateInterval=null;constructor(e={}){this.options=e}async start(){if(this.started||this.starting){console.warn(`AudioRecorder: Start already in progress or already started`);return}if(!Oy()||!navigator.mediaDevices){let e=Error(`MediaRecorder not supported or no microphone access`);throw this.options.onError?.(e),e}try{if(this.starting=!0,this.stream=await navigator.mediaDevices.getUserMedia({audio:{echoCancellation:!0,noiseSuppression:!0,autoGainControl:!0},video:!1}),!this.starting){this.stopStream(this.stream);return}this.mediaRecorder&&this.mediaRecorder.state!==`inactive`&&(console.warn(`AudioRecorder: MediaRecorder already active, stopping previous recording`),this.mediaRecorder.stop(),this.cleanup()),this.started=!0,this.starting=!1;let e=Dy();if(!e)throw Error(`No supported media type found`);let t={mimeType:e};this.mediaRecorder=new MediaRecorder(this.stream,t),this.audioChunks=[],this.mediaRecorder.ondataavailable=e=>{e.data.size>0&&this.audioChunks.push(e.data)},this.mediaRecorder.onstop=async()=>{let t=this.audioChunks.length>0?new Blob(this.audioChunks,{type:e}):null;await this.options.onDataAvailable?.(t),this.options.onStop?.(),this.cleanup()},this.mediaRecorder.onerror=e=>{let t=Error(`MediaRecorder error: ${e}`);this.options.onError?.(t),this.cleanup()},this.mediaRecorder.start(),this.setupVolumeAnalysis(this.stream),this.options.onStart?.()}catch(e){this.started=!1,this.starting=!1;let t=e instanceof Error?e:Error(String(e));throw this.options.onError?.(t),t}}stop(){this.started=!1,this.starting=!1,this.volumeUpdateInterval&&=(clearInterval(this.volumeUpdateInterval),null),this.mediaRecorder&&this.mediaRecorder.state!==`inactive`?this.mediaRecorder.stop():(this.stream&&this.stopStream(this.stream),this.cleanup())}setupVolumeAnalysis(e){if(this.options.onVolumeChange)try{this.audioContext=new AudioContext,this.analyser=this.audioContext.createAnalyser(),this.analyser.fftSize=256,this.analyser.smoothingTimeConstant=.8;let t=this.analyser.frequencyBinCount;this.dataArray=new Uint8Array(t),this.audioContext.createMediaStreamSource(e).connect(this.analyser),this.startVolumeMonitoring()}catch(e){console.warn(`Failed to set up volume analysis:`,e)}}startVolumeMonitoring(){!this.analyser||!this.dataArray||!this.options.onVolumeChange||(this.volumeUpdateInterval=window.setInterval(()=>{if(!this.analyser||!this.dataArray||!this.started)return;this.analyser.getByteFrequencyData(this.dataArray);let e=0;for(let t=0;t<this.dataArray.length;t++)e+=this.dataArray[t]*this.dataArray[t];let t=Math.sqrt(e/this.dataArray.length)/255;t=(t*3)**.7;let n=Math.min(100,Math.max(0,Math.round(t*100)));this.options.onVolumeChange?.(n)},100))}get recording(){return this.started&&this.mediaRecorder?.state===`recording`}get isStarting(){return this.starting}stopStream(e){e.getTracks().forEach(e=>e.stop())}cleanup(){this.volumeUpdateInterval&&=(clearInterval(this.volumeUpdateInterval),null),this.audioContext&&=(this.audioContext.close().catch(console.warn),null),this.analyser=null,this.dataArray=null,this.stream&&=(this.stopStream(this.stream),null),this.mediaRecorder=null,this.audioChunks=[],this.started=!1,this.starting=!1}static isSupported(){return Oy()}static getSupportedMediaType(){return Dy()}};function My(e,t,n){let r=e.translations[t];r&&(r.chatFooterText=n)}var Ny=e=>(localStorage.setItem(`liipgpt-color-scheme`,e),Fy([`light`,`dark`])),Py=()=>{let e=localStorage.getItem(`liipgpt-color-scheme`);return e===`light`||e===`dark`?e:`system`},Fy=e=>{let t=Py();return t===`system`&&(t=window.matchMedia(`(prefers-color-scheme: dark)`).matches?`dark`:`light`),e.includes(t)?t:e[0]??`light`},Iy=Cs(),Ly=(e,t)=>{if(e instanceof HTMLTextAreaElement&&t instanceof HTMLTextAreaElement){t.textContent=e.value;return}if(e instanceof HTMLSelectElement&&t instanceof HTMLSelectElement){Array.from(e.options).forEach((e,n)=>{t.options[n]&&(t.options[n].selected=e.selected)});return}e instanceof HTMLInputElement&&t instanceof HTMLInputElement&&(t.setAttribute(`value`,e.value),(e.type===`checkbox`||e.type===`radio`)&&(e.checked?t.setAttribute(`checked`,`checked`):t.removeAttribute(`checked`)))},Ry=e=>{let t=e.cloneNode(!0);if(!(t instanceof Element))return``;let n=`input, textarea, select`,r=e.querySelectorAll(n),i=t.querySelectorAll(n);return r.forEach((e,t)=>{let n=i[t];n&&Ly(e,n)}),Iy.sanitize(t.outerHTML,{FORBID_TAGS:[`style`,`script`],FORBID_ATTR:[`style`,`class`]})},zy=e=>{if(!e?.length)return[];let t=e.join(`,`),n=document.querySelectorAll(t);return Array.from(n,Ry)},By=`liipgpt:context`,Vy=class{contextVersion=0;#e=j();get currentContext(){return L(this.#e)}set currentContext(e){M(this.#e,e,!0)}getFromLocalStorage(){let e=localStorage.getItem(By);if(e){let t;try{if(t=JSON.parse(e),t.version!==this.contextVersion){localStorage.removeItem(By);return}else return t.context}catch(e){console.error(`Failed to parse liipgpt:context`,e);return}}}storeToLocalStorage(){localStorage.setItem(`liipgpt:context`,JSON.stringify({version:Z.data.chatConfig.contextVersion,context:this.currentContext}))}constructor(e){this.init=e,this.currentContext=this.getFromLocalStorage()??e.initialValue}getContext(){return st(this.currentContext)}setContextVersion(e){this.contextVersion=e}setContext(e){this.currentContext=e,this.storeToLocalStorage()}resetContext(){this.currentContext=this.init.initialValue,this.storeToLocalStorage()}updateContext(e){this.setContext(e(this.currentContext))}},Hy=()=>localStorage.getItem(By),Uy=[{type:`email`,check:e=>/\b[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}\b/.test(e)},{type:`creditCard`,check:e=>/\b(?:\d[ -]*?){13,16}\b/.test(e)},{type:`ahv`,check:e=>/\b756\.\d{4}\.\d{4}\.\d{2}\b/.test(e)},{type:`phoneSwiss`,check:e=>/\b0(?:\s*\d){2}(?:\s*\/\s*)?(?:\s*\d){7,}\b/.test(e)},{type:`phoneInternational`,check:e=>/(?:\+|00)(?:\s*\d){10,}\b/.test(e)},{type:`swissPassport`,check:e=>/\b[A-HJ-NP-Z](?=.*\d)[A-HJ-NP-Z0-9]{7}\b/.test(e)},{type:`longNumber`,check:e=>/\b\d{9,}\b/.test(e)}],Wy=e=>{for(let t of Uy)if(t.check(e))return t.type},Gy=`liipgpt:selectorValues`,Ky=`liipgpt:selectorKnownDefaults`,qy=()=>{try{let e=s_.getItem(Gy),t=s_.getItem(Ky);return e?{values:JSON.parse(e),knownDefaults:t?JSON.parse(t):{}}:null}catch{return null}},Jy=e=>{let t={};for(let n of e)t[n.settingName]=n.defaultValues??(n.allowEmpty?[]:[n.values[0]]).filter(Boolean);return t},Yy=(e,t)=>{try{let n=Jy(t);s_.setItem(Gy,JSON.stringify(e)),s_.setItem(Ky,JSON.stringify(n))}catch(e){console.error(`Failed to save selector values:`,e)}},Xy=e=>{try{let t=qy();if(!t)return;delete t.values[e],delete t.knownDefaults[e],s_.setItem(Gy,JSON.stringify(t.values)),s_.setItem(Ky,JSON.stringify(t.knownDefaults))}catch(e){console.error(`Failed to clear selector saved state:`,e)}},Zy=e=>{let t=qy(),n=e.map(e=>{let n=e.defaultValues??(e.allowEmpty?[]:[e.values[0]]).filter(Boolean);if(!t?.values[e.settingName])return[e.settingName,n];let r=t.values[e.settingName],i=t.knownDefaults[e.settingName]||[],a=r.filter(t=>e.values.includes(t)),o=i.filter(e=>!n.includes(e)),s=a.filter(e=>!o.includes(e)),c=n.filter(e=>!i.includes(e)&&!s.includes(e)),l=[...s,...c];return l.length===0&&!e.allowEmpty?[e.settingName,n]:[e.settingName,l]});return Object.fromEntries(n)},Qy=class extends Error{constructor(e){super(e),this.name=`UnreachableError`}},$y=(e,t)=>{if(!e)return;let n=t.find(t=>t.id===e);return n||console.warn(`autofire-predefined-question-id="${e}" did not match any loaded predefined question. Falling back to default routing.`),n},eb=(e,t,n,r,i)=>{if(e&&!t)return{name:`consent-page`};let a=new URLSearchParams(window.location.search),o=a.get(`q`),s=a.get(`id`)??void 0,c=a.get(`sid`)??void 0;return o?{name:`chat-page`,query:o,predefinedQuestionId:s,switchQuestionId:c}:i?{name:`chat-page`,query:i}:r?{name:`chat-page`,query:r.question,predefinedQuestionId:r.id}:n?{name:`chat-page`}:{name:`start-page`}},tb=`follow-up-q`,nb=e=>/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i.test(e),rb=()=>{let e=new URLSearchParams(window.location.hash.replace(/^#/,``)).get(`cID`)??void 0;return{cID:e&&nb(e)?e:void 0,followUpQuestion:new URLSearchParams(window.location.search).get(tb)?.trim()||void 0}},ib=()=>{let e=new URLSearchParams(window.location.search);if(!e.has(tb))return;e.delete(tb);let t=e.toString();history.replaceState(null,``,`${window.location.pathname}${t?`?${t}`:``}${window.location.hash}`)},ab=e=>{if(e)try{let t=JSON.parse(e);if(t&&typeof t==`object`&&!Array.isArray(t))return t;console.warn(`additional-start-parameters must be a JSON object. Received: ${e}`);return}catch(t){console.warn(`Failed to parse additional-start-parameters as JSON: ${e}`,t);return}},ob=e=>{let t=ab(e);return t?(e=>Array.isArray(e)?e.map(String):typeof e==`string`?e.split(`,`).map(e=>e.trim()).filter(Boolean):[])(t.scopeAvailableSlugs).length===1:!1},sb=e=>e?e.map(e=>({id:e_(),...e})):[],Z=new class{#e=j(Dn({}));get data(){return L(this.#e)}set data(e){M(this.#e,e,!0)}#t=j(Dn({}));get targets(){return L(this.#t)}set targets(e){M(this.#t,e,!0)}#n=j(!1);get initialized(){return L(this.#n)}set initialized(e){M(this.#n,e,!0)}#r=j(0);get currentAudioVolume(){return L(this.#r)}set currentAudioVolume(e){M(this.#r,e,!0)}ariaLiveMessagesClearingTimeoutDuration=350;#i=j(null);get currentAudioRecorder(){return L(this.#i)}set currentAudioRecorder(e){M(this.#i,e,!0)}#a=j(!1);get isTranscribing(){return L(this.#a)}set isTranscribing(e){M(this.#a,e,!0)}#o=A(()=>{if(!this.initialized)return[];let e=this.data.chatConfig.menu;return e?e[this.data.language]??[]:[]});get menu(){return L(this.#o)}set menu(e){M(this.#o,e)}#s=A(()=>this.initialized?this.data.chatConfig.translations[this.data.language]??{}:{});get t(){return L(this.#s)}set t(e){M(this.#s,e)}#c=A(()=>this.initialized?R_[this.data.language]??{}:R_.en??{});get errorTranslations(){return L(this.#c)}set errorTranslations(e){M(this.#c,e)}#l=A(()=>this.initialized?z_[this.data.language]??{}:z_.en??{});get piiTranslations(){return L(this.#l)}set piiTranslations(e){M(this.#l,e)}#u=A(()=>this.initialized?this.data.currentColorScheme:`light`);get colorScheme(){return L(this.#u)}set colorScheme(e){M(this.#u,e)}#d=A(()=>this.initialized?this.data.chatConfig.fullTheme[this.data.currentColorScheme]:{});get themeBase(){return L(this.#d)}set themeBase(e){M(this.#d,e)}#f=A(()=>this.themeBase.tokens);get theme(){return L(this.#f)}set theme(e){M(this.#f,e)}#p=A(()=>{if(!this.initialized)return[];let e=[];for(let t of this.data.chatConfig.selectorsConfig)t.allowEmpty||(this.data.selectorValues[t.settingName]||[]).length===0&&e.push(t.settingName);return e});get selectorsWithErrors(){return L(this.#p)}set selectorsWithErrors(e){M(this.#p,e)}#m=A(()=>{if(!this.initialized)return{};let e=this.data.chatConfig,t={};for(let n of e.selectorsConfig){let r=q_(e.translations,n.settingName,this.data.language,e.supportedLanguages);r||console.error(`Missing translation for setting ${n.settingName} in all languages`),t[n.settingName]=r??{name:n.settingName,placeholder:``,values:{}}}return t});get selectorTranslations(){return L(this.#m)}set selectorTranslations(e){M(this.#m,e)}#h=A(()=>{if(!this.initialized)return!1;let e=this.data.chatConfig;return this.data.route.name===`chat-page`&&!e.forceChatPage||e.showContextInfo||e.showContextMenu||e.showCloseChatButton||this.data.props.flyout});get hasMainNavigationContent(){return L(this.#h)}set hasMainNavigationContent(e){M(this.#h,e)}#g=A(()=>{if(!this.initialized)return``;let e=this.t,t=this.data.chatConfig,n=this.data.route.name===`chat-page`&&!t.forceChatPage,r=[];return n&&r.push(e.newChat),t.showContextInfo&&r.push(e.ariaMainNavigationInfo),t.showContextMenu&&(this.menu.length>0&&r.push(e.ariaMainNavigationLinks),t.supportedLanguages.length>0&&r.push(e.ariaMainNavigationLanguageSwitch),this.data.has2ColorSchemes&&r.push(e.ariaMainNavigationColorMode)),(t.showCloseChatButton||this.data.props.flyout)&&r.push(e.closeChat),r.length===0?e.ariaMainNavigation:`${e.ariaMainNavigation}: ${r.join(`, `)}`});get ariaMainNavigationRegion(){return L(this.#g)}set ariaMainNavigationRegion(e){M(this.#g,e)}},cb,lb,ub,db=Ty({name:`chat-logic`,state:Z,excludeInDevTools:[`onInput`]},{async init(e){lb=e;let t=lb.speechRecognitionApiKey||void 0;cb=new C_({apiUrl:lb.apiUrl,apiKey:lb.apiKey,speechRecognitionApiKey:t,strict:!0,startParameters:ab(lb.additionalStartParameters)});try{let e=await cb.getChatConfig();window.CHAT_CONFIG_OVERRIDE&&Object.assign(e,window.CHAT_CONFIG_OVERRIDE);let t=(await cb.getMetadata()).mode===`maintenance`;t&&this.showErrorToast(`maintenance`);let n=L_(e);lb.inlineLayout!==void 0&&(n.inlineLayout=lb.inlineLayout),lb.forceChatPage!==void 0&&(n.forceChatPage=lb.forceChatPage);let r;r=lb.lang?V_(lb.lang,n.supportedLanguages):W_(n.supportedLanguages),U_(r,Z.targets.mainElement);let i=await this.getPredefinedQuestions(r),a=n.translations[r]?.ariaOpensInNewTab;a&&cb.setNewTabSrText(a);let o=[];if(n.renderKatex){let e=await import(`https://esm.sh/marked-katex-extension@5.1.5`).catch(e=>{console.error(`Couldn't load marked-katex-extension:`,e)});e&&(cb.setMarkedExtensions(e.default({nonStandard:!0,output:`mathml`})),o.push(`https://cdn.jsdelivr.net/npm/katex@0.16.22/dist/katex.min.css`))}let s=Object.keys(n.fullTheme),c=!1;if(n.forceConsent)try{c=s_.getItem(`liipgpt:termsAccepted`)===`true`}catch(e){console.warn(`Failed to load terms acceptance from storage:`,e)}let l=$y(lb.autofirePredefinedQuestionId,i);Z.data={currentConversationState:`idle`,chatConfig:n,language:r,predefinedQuestions:i,isInMaintenance:t,history:sb(n.messageAdditions.init),selectedColorScheme:Py(),has2ColorSchemes:s.length===2,currentColorScheme:Fy(s),conversationFeedbackId:void 0,conversationFeedbackIsOpen:!1,answerFormMessageId:void 0,openedPopup:void 0,props:lb,flyoutIsOpen:!1,questionHasPii:void 0,chatInputValue:``,selectorValues:Zy(n.selectorsConfig),selectorsIsOpen:!1,predefinedQuestionId:void 0,switchQuestionId:void 0,currentReferencesAsideId:void 0,ariaLiveStatusMessage:void 0,ariaLiveStatusMessageClearingTimeout:void 0,wasReferencesAsideClosed:!1,isAsideMobile:!0,route:eb(n.forceConsent??!1,c,n.forceChatPage??!1,l,lb.question),additionalStylesheets:o,hasOpenedOverlays:!1,isInlineLayoutContained:!1,termsAccepted:c,selectedTopic:void 0},window.LIIPGPT_LISTENERS?.route?.(Z.data.route),window.LIIPGPT_LISTENERS?.conversation?.(Z.data.currentConversationState),Z.data.selectorsIsOpen=Z.data.chatConfig.showExpandedSelectors??!1,Z.initialized=!0,this.checkForOpenedPopup(),window.addEventListener(`hashchange`,()=>{this.checkForOpenedPopup()}),await this.startFromHandoverOrRoute(()=>this.goto(eb(n.forceConsent??!1,c,n.forceChatPage??!1,l,lb.question),!0))}catch(e){throw kv.error(e instanceof Error?e.message:`Failed to load the chatbot. Please reload the page.`,{duration:1e4,unstyled:!0,classes:{toast:`toast`}}),e}},setTarget(e,t){Z.targets[e]=t},goto(e,t=!1){if(!(!t&&(0,rv.default)(Z.data.route,e)))switch(Z.data.route=e,window.LIIPGPT_LISTENERS?.route?.(e),e.name){case`consent-page`:break;case`start-page`:e.prefill&&(Z.data.chatInputValue=e.prefill);break;case`chat-page`:if(Z.data.chatInputValue=e.query??``,Z.data.predefinedQuestionId=e.predefinedQuestionId,Z.data.switchQuestionId=e.switchQuestionId,e.query&&(this.onSubmit(),Z.data.chatConfig.addQueryToUrlParams)){let t=new URLSearchParams(window.location.search);t.set(`q`,e.query),e.predefinedQuestionId?t.set(`id`,e.predefinedQuestionId):t.delete(`id`),e.switchQuestionId?t.set(`sid`,e.switchQuestionId):t.delete(`sid`),history.pushState(null,``,`?${t.toString()}${window.location.hash}`)}break}},getSelectorConfig(e){let t=Z.data.chatConfig.selectorsConfig.find(t=>t.settingName===e);if(!t)throw Error(`Setting ${e} not found`);return t},getPrettifiedSelectorValues(){let e=Object.entries(Z.data.selectorValues).map(([e,t])=>{let n;try{n=this.getSelectorConfig(e)}catch(t){console.error(`Error getting selector config for ${e}: ${t}`);return}return n.type===`single-select`?[e,t[0]]:[e,t]}).filter(e=>!!e);return Object.fromEntries(e)},setSelectorValue(e,t){let n=this.getSelectorConfig(e);if(!n){console.warn(`Trying to set setting ${e} but it is not defined in the chat config`);return}if(n.type===`single-select`&&t.length>1){console.warn(`Trying to set multiple values for single-select setting ${e}`);return}Z.data.selectorValues[e]=t,Yy(Z.data.selectorValues,Z.data.chatConfig.selectorsConfig)},resetSelectorToDefaults(e){let t=this.getSelectorConfig(e);if(!t){console.warn(`Trying to reset setting ${e} but it is not defined in the chat config`);return}let n=t.defaultValues??(t.allowEmpty?[]:[t.values[0]]).filter(Boolean);return Xy(e),Z.data.selectorValues[e]=n,Yy(Z.data.selectorValues,Z.data.chatConfig.selectorsConfig),n},async getPredefinedQuestions(e){if(lb?.hidePredefinedQuestions)return[];try{return cb.getPredefinedQuestions({url:window.location.origin+window.location.pathname,language:e})}catch(e){return console.warn(`Failed to load predefined questions:`,e),[]}},setColorScheme(e){Z.data.selectedColorScheme=e,Z.data.currentColorScheme=Ny(e),this.setAriaLiveStatusMessage(e===`dark`?Z.t.ariaDarkSelected:Z.t.ariaLightSelected)},async abort(){await ub?.abort()},changeConversationState(e){Z.data.currentConversationState=e,window.LIIPGPT_LISTENERS?.conversation?.(e)},onInput(e){Z.data.chatConfig.blockPII&&(Z.data.questionHasPii=Wy(e)),Z.data.chatInputValue=e,Z.data.predefinedQuestionId=void 0,Z.data.switchQuestionId=void 0},onSubmit(e=!1,t,n=!1){let r=zy(Z.data.chatConfig.parentPageContext?.extractSelectors);if(Z.data.questionHasPii){console.warn(`Question contains PII, not submitting:`,Z.data.questionHasPii);return}let i=Z.data.chatConfig.questionPrefix?`${Z.data.chatConfig.questionPrefix} ${Z.data.chatInputValue}`:Z.data.chatInputValue;n||(Z.data.history.push(...sb(Z.data.chatConfig.messageAdditions.user.before)),Z.data.history.push({type:`user`,time:new Date().toISOString(),message:Z.data.chatInputValue}),Z.data.history.push(...sb(Z.data.chatConfig.messageAdditions.user.after)));let a=Z.data.history.push(...sb(Z.data.chatConfig.messageAdditions.bot.before));Z.data.history.push({id:`UNRESOLVED`,state:`loading`,errors:[],type:`bot`,time:new Date().toISOString(),message:{markdown:``,html:``,text:``},references:{all:[],used:[],unused:[]}});let o=!1,s=!1,c={features:lb.features?lb.features.trim().split(`,`):[`formatting`],mode:lb.mode||void 0,cache:lb.cache||void 0,onError:e=>{this.showErrorToast(e),window.LIIPGPT_LISTENERS?.error?.(e),(e===`pii-detected`||e===`blocked`)&&this.editLatestQuestion()},onMessage:e=>{e.type===`topic-selected`&&(Z.data.selectedTopic={label:e.label,placeholder:e.placeholder,locked:ob(lb.additionalStartParameters)}),e.type===`chat-footer-text`&&My(Z.data.chatConfig,Z.data.language,e.text),e.type===`state`&&e.state!==`history-entry-initialized`&&!s&&(s=!0,this.setAriaLiveStatusMessage(Z.t.ariaQuestionSent))},lang:Z.data.language,selectorValues:{...this.getPrettifiedSelectorValues(),context:Hy(),...t},predefinedQuestionId:Z.data.predefinedQuestionId,switchQuestionId:Z.data.switchQuestionId,onEmbed:e=>{let t=Z.data.history[a];t&&t.type===`bot`&&!t.message.markdown?(Z.data.history[a]={...e,id:t.id??e_()},o=!0):Z.data.history.push({...e,id:e_()})}};Z.data.predefinedQuestionId=void 0,Z.data.switchQuestionId=void 0,r.length&&(c.selectorValues.parentPageContextHtml=r);let l=(e,t)=>{try{let n=new URL(e),r=new URL(t);return n.origin===r.origin&&n.pathname===r.pathname}catch{return!1}},u=Z.data.chatConfig.sendReferrer??`all`;if([`all`,`own`,`location`].includes(u)){let e=u===`location`||Z.data.props.flyout,t;t=e?`${window.location.protocol}//${window.location.host}${window.location.pathname}`:l(document.referrer,window.location.href)?null:document.referrer;let n=u===`own`&&!Z.data.props.flyout&&t&&!t.startsWith(window.location.origin);c.referrer=t&&!n?t:void 0}Z.data.props.source?c.source=Z.data.props.source:Z.data.props.flyout&&(c.source=`flyout`),Z.data.currentConversationId||(Z.data.currentConversationId=cb.createConversationId());let d=cb.chat(Z.data.currentConversationId,i,c);ub=d,Z.data.lastChatResponseId=d.id,Z.data.currentConversationState!==`searching`&&this.changeConversationState(`searching`);let f=!1,p,m=!!Z.data.currentReferencesAsideId;(e&&m||!e&&Z.data.chatConfig.showReferencesByDefault)&&(Z.data.isAsideMobile||this.openReferencesAside(d.id)),d.subscribe(e=>{if(!o&&Z.data.history[a]&&(Z.data.history[a]={question:Z.data.chatInputValue,...e}),Z.data.chatConfig.addRetrievalQuestionToUrlParams&&e.retrievalQuestion){let t=new URLSearchParams(window.location.search);t.get(`search`)!==e.retrievalQuestion&&(t.set(`search`,e.retrievalQuestion),history.replaceState(null,``,`?${t.toString()}${window.location.hash}`))}Z.data.chatConfig.showReferencesByDefault&&!Z.data.wasReferencesAsideClosed&&Z.data.currentReferencesAsideId!==e.id&&!Z.data.isAsideMobile&&this.openReferencesAside(e.id),e.state===`streaming`&&Z.data.currentConversationState!==`answering`&&this.changeConversationState(`answering`),e.state===`done`&&(this.changeConversationState(`idle`),f||(f=!0,this.setAriaLiveStatusMessage(`${Z.t.ariaAnswerReady} ... ${e.message.text} ... ${Z.data.selectedTopic?Z.t.ariaAnswerFinishedWithSelectedTopic:Z.t.ariaAnswerFinished}`),Z.data.history.push(...sb(Z.data.chatConfig.messageAdditions.bot.after))),Z.data.currentReferencesAsideId&&e.references.used.length>0?(clearTimeout(p),p=setTimeout(()=>{this.openReferencesAside(e.id)},100)):this.closeReferencesAside())}),Z.data.chatInputValue=``},async onStartSpeechRecognition(){try{if(!await Ey()){this.showErrorToast(`speech-not-supported`);return}if(await navigator.mediaDevices.getUserMedia({audio:!0}),jy.isSupported())Z.data.chatInputValue=``,Z.currentAudioRecorder=new jy({onDataAvailable:async e=>{Z.isTranscribing=!0,await this.handleTranscription(e)},onError:()=>{this.showErrorToast(`speech-microphone-access-denied`),Z.currentAudioRecorder=null,Z.isTranscribing=!1},onVolumeChange:e=>{Z.currentAudioVolume=e}}),Z.currentAudioRecorder.start();else{this.showErrorToast(`speech-not-supported`);return}}catch(e){throw this.showErrorToast(`speech-microphone-access-denied`),Z.currentAudioRecorder=null,Z.isTranscribing=!1,e}},editLatestQuestion(){let e=Z.data.history.findLastIndex(e=>e?.type===`user`);if(e===-1){console.error(`No last user question, available`);return}let t=Z.data.history.splice(e)[0];Z.data.chatInputValue=t.message},onStopSpeechRecognition(){if(Z.currentAudioRecorder){let e=Z.currentAudioRecorder;Z.currentAudioRecorder=null,e.stop()}Z.currentAudioVolume=0},async handleTranscription(e){if(!e){console.warn(`No audio data received`);return}try{let t=await cb.transcribeAudio(e,{lang:Z.data.language});if(t.error){this.showErrorToast(`speech-transcription-failed`);return}if(t.transcript.trim()){if(Z.data.chatConfig.blockPII&&(Z.data.questionHasPii=Wy(t.transcript.trim()),Z.data.questionHasPii))return;Z.data.chatInputValue=t.transcript.trim()}else this.showErrorToast(`speech-no-text-detected`)}catch(e){console.error(`Speech transcription error:`,e),this.showErrorToast(`speech-transcription-failed`)}finally{Z.currentAudioRecorder=null,Z.isTranscribing=!1,Z.currentAudioVolume=0}},async startFromHandoverOrRoute(e){let{cID:t,followUpQuestion:n}=rb();if(!t){e();return}let r=await this.rehydrateFromSearchSummaryHandover(t);n?(Z.data.route={name:`chat-page`},Z.data.chatInputValue=n,this.onSubmit(!0)):r||e(),ib()},async rehydrateFromSearchSummaryHandover(e){Z.data.currentConversationId=e;let t=await cb.getMetadata(),n=t.mode===`ready`?t.userId:void 0,r=n?await cb.getChatHistory(e,n):[];if(r.length===0)return Z.data.currentConversationId=void 0,!1;let i={all:[],used:[],unused:[]},a=new Qc({newTabSrText:Z.t.ariaOpensInNewTab}),o=[];for(let{question:e,answer:t}of r)o.push({type:`user`,time:new Date().toISOString(),message:e,id:e_()}),o.push({id:e_(),state:`done`,errors:[],type:`bot`,time:new Date().toISOString(),message:{markdown:t,html:a.toHTML(t,i),text:t},references:{all:[],used:[],unused:[]}});return Z.data.history=[...sb(Z.data.chatConfig.messageAdditions.init),...o],Z.data.route={name:`chat-page`},!0},async onStartConversation(e,t,n){await this.abort(),Z.data.history=sb(Z.data.chatConfig.messageAdditions.init),Z.data.currentConversationId=cb.createConversationId(),this.goto({name:`chat-page`,query:e,predefinedQuestionId:t,switchQuestionId:n})},async onNewConversation(){await this.abort();let e=Z.data.currentConversationId;if(Z.data.currentConversationId=void 0,Z.data.currentReferencesAsideId=void 0,Z.data.history=sb(Z.data.chatConfig.messageAdditions.init),Z.data.predefinedQuestionId=void 0,Z.data.switchQuestionId=void 0,Z.data.selectedTopic=void 0,Z.data.chatConfig.addQueryToUrlParams){let e=new URLSearchParams(window.location.search);e.delete(`q`),e.delete(`id`),e.delete(`sid`),history.pushState(null,``,`?${e.toString()}${window.location.hash}`)}let t=$y(Z.data.props.autofirePredefinedQuestionId,Z.data.predefinedQuestions);t?this.goto({name:`chat-page`,query:t.question,predefinedQuestionId:t.id},!0):this.goto({name:`start-page`}),e&&cb.userAction(`newDiscussion`,{conversationId:e,lang:Z.data.language}).catch(e=>{console.error(`Failed to notify backend of new discussion:`,e)})},async onChangeTopic(){let e=Z.data.chatConfig.selectedTopicResetPredefinedQuestionId;if(!e){console.warn("No selectedTopicResetPredefinedQuestionId available to reset the selected topic. Set it in the `Config DB` in the backend, in a `generalConfig` default set.");return}await this.abort(),Z.data.selectedTopic=void 0,Z.data.predefinedQuestionId=e,Z.data.switchQuestionId=void 0,Z.data.chatInputValue=``,this.onSubmit(!0,void 0,!0)},showSuccessToast(e){kv.success(Z.t[e],{unstyled:!0,duration:3e3,classes:{toast:`toast`}})},showErrorToast(e){kv.error(Z.errorTranslations[e],{unstyled:!0,duration:3e3,classes:{toast:`toast`}})},async submitFeedback(e){try{let t=Z.data.conversationFeedbackId||Z.data.lastChatResponseId;if(!t)throw new Qy(`Tried to give feedback with no id.`);let n=Z.data.history.find(e=>e.type===`bot`&&e.id===t);await cb.feedback(t,n?.question??``,e),setTimeout(()=>{this.showSuccessToast(`thankYouForFeedback`)},500)}catch(e){console.error(`Feedback failed:`,e),this.showErrorToast(`feedback-failed`)}},toggleReferencesAside(e){Z.data.currentReferencesAsideId===e?this.closeReferencesAside():this.openReferencesAside(e)},openReferencesAside(e){Z.data.currentReferencesAsideId=e,this.setOpenOverlay(!0)},closeReferencesAside(){Z.data.currentReferencesAsideId=void 0,Z.data.wasReferencesAsideClosed=!0,this.setOpenOverlay(!1)},setAsideMobile(e){Z.data.isAsideMobile=e},openFlyout(){Z.data.flyoutIsOpen=!0},closeFlyout(){Z.data.flyoutIsOpen=!1},openConversationFeedback(){Z.data.conversationFeedbackIsOpen=!0,this.setOpenOverlay(!0)},openMessageFeedback(e){Z.data.conversationFeedbackId=e},closeFeedback(){Z.data.conversationFeedbackIsOpen=!1,Z.data.conversationFeedbackId=void 0,this.setOpenOverlay(!1)},openAnswerForm(e){Z.data.answerFormMessageId=e,this.setOpenOverlay(!0)},closeAnswerForm(){Z.data.answerFormMessageId=void 0,this.setOpenOverlay(!1)},async submitAnswerForm(e){try{let t=Z.data.chatConfig.answerForm,n=Z.data.answerFormMessageId;if(!t)throw new Qy(`Tried to submit the answer form with no answerForm config.`);if(!n)throw new Qy(`Tried to submit the answer form with no message id.`);let r=Z.data.history.findIndex(e=>e.type===`bot`&&e.id===n),i=r===-1?void 0:Z.data.history[r],a=Z.data.history.slice(0,r===-1?void 0:r).findLast(e=>e.type===`user`)?.message,o=i?.question||a||(i?.type===`bot`?i.retrievalQuestion??``:``);await cb.submitAnswerForm({receiverEmail:t.receiverEmail,fields:t.fields.map(t=>({name:t.name,value:e[t.name]??``})),question:o,answer:i?.type===`bot`?i.message.text:``,requestId:n,lang:Z.data.language}),setTimeout(()=>{this.showSuccessToast(`answerFormThankYou`)},500)}catch(e){console.error(`Answer form submission failed:`,e),this.showErrorToast(`answer-form-failed`)}},setOpenOverlay(e){Z.data.hasOpenedOverlays=e},setAriaLiveStatusMessage(e){Z.data.ariaLiveStatusMessage=e,clearTimeout(Z.data.ariaLiveStatusMessageClearingTimeout),Z.data.ariaLiveStatusMessageClearingTimeout=setTimeout(()=>{Z.data.ariaLiveStatusMessage=``},Z.ariaLiveMessagesClearingTimeoutDuration)},closePopup(){window.location.hash=``},checkForOpenedPopup(){let e=window.location.hash.slice(1),t=Z.t.popups?.find(t=>t.hash===e);t?Z.data.openedPopup=t:Z.data.openedPopup=void 0},async thumbs(e,t){try{let n=Z.data.history.find(t=>t.type===`bot`&&t.id===e);t===`up`?await cb.thumbsUp(e,n?.question??``):await cb.thumbsDown(e,n?.question??``),this.showSuccessToast(`thankYouForFeedback`)}catch(e){console.error(`Feedback failed:`,e),this.showErrorToast(`feedback-failed`)}},async onLanguageChange(e){if(Z.data.language=V_(e,Z.data.chatConfig.supportedLanguages),U_(Z.data.language,Z.targets.mainElement),Z.data.predefinedQuestions=await this.getPredefinedQuestions(Z.data.language),this.setAriaLiveStatusMessage(Z.t.ariaLanguageChanged),Z.data.chatConfig.reflectLanguageInPath){let e=new URL(window.location.href);e.pathname=`/${Z.data.language}`,window.history.replaceState({},``,e.toString())}},async acceptTerms(){Z.data.termsAccepted=!0;try{s_.setItem(`liipgpt:termsAccepted`,`true`)}catch(e){console.warn(`Failed to save terms acceptance to storage:`,e)}this.closePopup(),await qr(),this.goto(eb(Z.data.chatConfig.forceConsent??!1,!0,Z.data.chatConfig.forceChatPage??!1,$y(Z.data.props.autofirePredefinedQuestionId,Z.data.predefinedQuestions),Z.data.props.question))},updateChatInput(e){Z.data.chatInputValue=e}}),fb=(e,t)=>{let n=window.LIIPGPT_LISTENERS?.elements?.[t];if(!n)return;let r=Object.entries(n).filter(([e,t])=>typeof t==`function`&&![`init`,`destroy`].includes(e));$n(()=>(n.init?.(e),r.forEach(([t,n])=>{e.addEventListener(t,n)}),()=>{r.forEach(([t,n])=>{e.removeEventListener(t,n)}),n.destroy?.(e)}))},pb=(e,t)=>{t&&db.setTarget(t,e)},mb=R(`<div role="status" class="sr-only"> </div>`);function hb(e,t){D(t,!1),co();var n=mb(),r=N(n,!0);E(n),I(()=>V(r,Z.data.ariaLiveStatusMessage)),B(e,n),O()}q(hb,{},[],[],{mode:`open`});var gb=R(`<div aria-hidden="true"></div>`);function _b(e,t){D(t,!0);let n=K(t,`name`,7),r=K(t,`class`,7);var i={get name(){return n()},set name(e){n(e),k()},get class(){return r()},set class(e){r(e),k()}},a=gb();return na(a,()=>Z.theme.svgs[n()],!0),E(a),I(()=>Da(a,1,`svg svg--${n()??``} ${r()??``}`)),B(e,a),O(i)}q(_b,{name:{},class:{}},[],[],{mode:`open`});var vb=`data-disable-tooltip-on-focus`;function yb(e,t){let n=null,r;function i(){t.text&&(n||(n=document.createElement(`span`),n.ariaHidden=`true`,n.textContent=t.text,n.className=`tooltip tooltip-${t.position||`top`} tooltip-hidden`,e.appendChild(n),n.getBoundingClientRect()),n.classList.remove(`tooltip-hidden`),a())}function a(){if(!n)return;let r=e.getBoundingClientRect(),i=n.getBoundingClientRect(),a,o;switch(t.position){case`bottom`:a=r.height+5,o=r.width/2-i.width/2;break;case`bottom-right`:a=r.height+5,o=r.width-i.width;break;case`bottom-left`:a=r.height+5,o=0;break;case`left`:a=r.height/2-i.height/2,o=-i.width-5;break;case`right`:a=r.height/2-i.height/2,o=r.width+5;break;default:a=-i.height-5,o=r.width/2-i.width/2;break}let s=r.left+o,c=s+i.width,l=window.innerWidth;if(c>l){let e=c-l;if(o-=e+10,t.position===`top`||t.position===`bottom`){let t=e+10;n.style.setProperty(`--tooltip-arrow-offset`,`${t}px`)}}if(s<0&&(o-=s-10,t.position===`top`||t.position===`bottom`)){let e=s-10;n.style.setProperty(`--tooltip-arrow-offset`,`${e}px`)}n.style.top=`${a}px`,n.style.left=`${o}px`}function o(){r=window.setTimeout(()=>{i()},t.delay||200)}function s(e){let t=e.target;t&&!t.hasAttribute(`data-disable-tooltip-on-focus`)?o():t.removeAttribute(vb)}function c(){clearTimeout(r),n&&(n.classList.add(`tooltip-hidden`),n.addEventListener(`transitionend`,()=>{n?.remove(),n=null},{once:!0}))}return e.classList.add(`tooltip-container`),e.setAttribute(`tabindex`,`0`),e.addEventListener(`mouseenter`,o),e.addEventListener(`focus`,s),e.addEventListener(`mouseleave`,c),e.addEventListener(`blur`,c),e.addEventListener(`click`,c),{update(e){t=e},destroy(){c(),e.classList.remove(`tooltip-container`),e.removeEventListener(`mouseenter`,o),e.removeEventListener(`focus`,s),e.removeEventListener(`mouseleave`,c),e.removeEventListener(`blur`,c),e.removeEventListener(`click`,c)}}}var bb=R(`<button><span class="sr-only"> </span> <span><!></span></button>`);function xb(e,t){D(t,!0);let n=K(t,`class`,7),r=K(t,`tooltip`,7),i=K(t,`label`,7),a=K(t,`onclick`,7),o=K(t,`icon`,7),s=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`class`,`tooltip`,`label`,`onclick`,`icon`]);var c={get class(){return n()},set class(e){n(e),k()},get tooltip(){return r()},set tooltip(e){r(e),k()},get label(){return i()},set label(e){i(e),k()},get onclick(){return a()},set onclick(e){a(e),k()},get icon(){return o()},set icon(e){o(e),k()}},l=bb();Ja(l,()=>({onclick:a(),...s}));var u=N(l),d=N(u,!0);E(u);var f=F(u,2);return _b(N(f),{get name(){return o()}}),E(f),E(l),_a(l,(e,t)=>yb?.(e,t),()=>({text:r(),position:`top`,delay:300})),I(()=>{V(d,i()),Da(f,1,xa(n()))}),B(e,l),O(c)}q(xb,{class:{},tooltip:{},label:{},onclick:{},icon:{}},[],[],{mode:`open`});var Sb=R(`<p class="jsonld-card__description"> </p>`),Cb=R(`<article class="jsonld-card jsonld-card--cta"><header class="jsonld-card__header"><h3 class="jsonld-card__title"> </h3></header> <!> <a class="jsonld-card__cta btn" target="_blank" rel="noopener noreferrer"><span> </span> <!></a></article>`);function wb(e,t){D(t,!0);let n=K(t,`data`,7);var r={get data(){return n()},set data(e){n(e),k()}},i=Cb(),a=N(i),o=N(a),s=N(o,!0);E(o),E(a);var c=F(a,2),l=e=>{var t=Sb(),r=N(t,!0);E(t),I(()=>V(r,n().description)),B(e,t)};U(c,e=>{n().description&&e(l)});var u=F(c,2),d=N(u),f=N(d,!0);return E(d),_b(F(d,2),{name:`externalLink`,class:`jsonld-card__cta-icon`}),E(u),E(i),I(()=>{G(i,`aria-label`,`${Z.t.ariaJsonLdCtaCard??``}: ${n().title??``}`),V(s,n().title),G(u,`href`,n().url),V(f,n().label??Z.t.jsonLdCtaLabel)}),B(e,i),O(r)}q(wb,{data:{}},[],[],{mode:`open`});var Tb=R(`<span class="jsonld-card__event-time"> </span>`),Eb=R(`<dt class="jsonld-card__meta-label"> </dt> <dd class="jsonld-card__meta-value"><time class="jsonld-card__event-date"><span> </span> <!></time></dd>`,1),Db=R(`<dt class="jsonld-card__meta-label"> </dt> <dd class="jsonld-card__meta-value"> </dd>`,1),Ob=R(`<dt class="jsonld-card__meta-label"> </dt> <dd class="jsonld-card__meta-value"> </dd>`,1),kb=R(`<article class="jsonld-card jsonld-card--event"><header class="jsonld-card__header"><h3 class="jsonld-card__title"> </h3></header> <dl class="jsonld-card__meta"><!> <!> <!></dl> <a class="jsonld-card__cta btn" target="_blank" rel="noopener noreferrer"><span> </span> <!></a></article>`);function Ab(e,t){D(t,!0);let n=K(t,`data`,7),r=A(()=>{if(!n().date)return;let e=new Date(n().date);if(Number.isNaN(e.getTime()))return{day:n().date,time:void 0};let t=Z.data.language||`de`;try{return{day:e.toLocaleDateString(t,{weekday:`long`,day:`numeric`,month:`long`,year:`numeric`}),time:e.getHours()!==0||e.getMinutes()!==0?e.toLocaleTimeString(t,{hour:`2-digit`,minute:`2-digit`}):void 0}}catch{return{day:e.toLocaleString(),time:void 0}}});var i={get data(){return n()},set data(e){n(e),k()}},a=kb(),o=N(a),s=N(o),c=N(s,!0);E(s),E(o);var l=F(o,2),u=N(l),d=e=>{var t=Eb(),i=P(t),a=N(i,!0);E(i);var o=F(i,2),s=N(o),c=N(s),l=N(c,!0);E(c);var u=F(c,2),d=e=>{var t=Tb(),n=N(t,!0);E(t),I(()=>V(n,L(r).time)),B(e,t)};U(u,e=>{L(r).time&&e(d)}),E(s),E(o),I(()=>{V(a,Z.t.jsonLdEventDate),G(s,`datetime`,n().date),V(l,L(r).day)}),B(e,t)};U(u,e=>{L(r)&&e(d)});var f=F(u,2),p=e=>{var t=Db(),r=P(t),i=N(r,!0);E(r);var a=F(r,2),o=N(a,!0);E(a),I(()=>{V(i,Z.t.jsonLdEventLocation),V(o,n().location)}),B(e,t)};U(f,e=>{n().location&&e(p)});var m=F(f,2),h=e=>{var t=Ob(),r=P(t),i=N(r,!0);E(r);var a=F(r,2),o=N(a,!0);E(a),I(()=>{V(i,Z.t.jsonLdEventDescription),V(o,n().description)}),B(e,t)};U(m,e=>{n().description&&e(h)}),E(l);var g=F(l,2),_=N(g),v=N(_,!0);return E(_),_b(F(_,2),{name:`externalLink`,class:`jsonld-card__cta-icon`}),E(g),E(a),I(()=>{G(a,`aria-label`,`${Z.t.ariaJsonLdEventCard??``}: ${n().title??``}`),V(c,n().title),G(g,`href`,n().ctaUrl),V(v,n().ctaLabel??Z.t.jsonLdEventCtaLabel)}),B(e,a),O(i)}q(Ab,{data:{}},[],[],{mode:`open`});var jb=R(`<p class="jsonld-card__description"> </p>`),Mb=R(`<div class="jsonld-card__map-frame"><div class="jsonld-card__map-canvas"></div></div>`),Nb=R(`<p class="jsonld-card__address"> </p>`),Pb=R(`<a class="jsonld-card__contact btn btn--secondary"><!> <span> </span></a>`),Fb=R(`<a class="jsonld-card__contact btn btn--secondary"><!> <span> </span></a>`),Ib=R(`<article class="jsonld-card jsonld-card--map"><header class="jsonld-card__header"><h3 class="jsonld-card__title"> </h3></header> <!> <!> <!> <div class="jsonld-card__actions"><!> <!> <a class="jsonld-card__cta btn" target="_blank" rel="noopener noreferrer"><span> </span> <!></a></div></article>`);function Lb(e,t){D(t,!0);let n=`5.24.0`,r=[`https://cdn.jsdelivr.net/npm/maplibre-gl@${n}/+esm`,`https://unpkg.com/maplibre-gl@${n}/dist/maplibre-gl.js?module`],i=`https://cdn.jsdelivr.net/npm/maplibre-gl@${n}/dist/maplibre-gl.css`,a=K(t,`data`,7),o=j(void 0),s=A(()=>{if(a().directionsUrl)return a().directionsUrl;if(!a().coords)return a().fallbackUrl;let e=String(Z.theme.components.messageJsonLdMap?.custom?.directionsProvider||``)||`google`,{lat:t,lng:n}=a().coords;return e===`osm`?`https://www.openstreetmap.org/directions?to=${t},${n}`:`https://www.google.com/maps/dir/?api=1&destination=${t},${n}`}),c=e=>new Promise(t=>{let n=`jsonld-map-maplibre-style`,r=e.getRootNode(),a=r instanceof ShadowRoot?r:document.head,o=a.querySelector(`#${n}`);if(o instanceof HTMLLinkElement&&o.sheet){t();return}if(o){o.addEventListener(`load`,()=>t(),{once:!0});return}let s=document.createElement(`link`);s.id=n,s.rel=`stylesheet`,s.href=i,s.onload=()=>t(),s.onerror=()=>t(),a.appendChild(s)}),l=e=>{let t=e;return t.Map?t:t.default??t},u=async e=>{await c(e);let t;for(let e of r)try{return l(await import(e))}catch(e){t=e}throw t};Ii(()=>{let e=a().coords;if(!e)return;let t=String(Z.theme.components.messageJsonLdMap?.custom?.tileUrl||``)||`https://tile.openstreetmap.org/{z}/{x}/{y}.png`,n=String(Z.theme.components.messageJsonLdMap?.custom?.markerColor||``)||`#3fb1ce`,r=String(Z.theme.components.messageJsonLdMap?.custom?.mapStyleUrl||``),i,s,c,l,d=0,f=0,p=!1;return(async()=>{await qr();let m=L(o);if(!m||p)return;let h=await u(m);if(p)return;let g=(e=>{if(e.trim().startsWith(`{`))try{return JSON.parse(e)}catch{return null}return e||null})(r)??{version:8,sources:{"osm-tiles":{type:`raster`,tiles:[t],tileSize:256}},layers:[{id:`osm-tiles`,type:`raster`,source:`osm-tiles`,minzoom:0,maxzoom:19}]};if(i=new h.Map({container:m,style:g,center:[e.lng,e.lat],zoom:a().zoom,attributionControl:!1,scrollZoom:!1,touchZoomRotate:!0,touchPitch:!1,doubleClickZoom:!0}),p){i.remove();return}i.once(`style.load`,()=>{let t=()=>{if(p||!i)return;i.resize();let r=i.getCanvas();r.width>0&&r.height>0?s=new h.Marker({color:n}).setLngLat([e.lng,e.lat]).addTo(i):requestAnimationFrame(t)};t()}),l=new ResizeObserver(e=>{let t=e[0];if(!t||!i)return;let{width:n,height:r}=t.contentRect;n===d&&r===f||(d=n,f=r,cancelAnimationFrame(c??0),c=requestAnimationFrame(()=>i?.resize()))}),l.observe(m)})(),()=>{p=!0,cancelAnimationFrame(c??0),l?.disconnect(),s?.remove(),i?.remove()}});var d={get data(){return a()},set data(e){a(e),k()}},f=Ib(),p=N(f),m=N(p),h=N(m,!0);E(m),E(p);var g=F(p,2),_=e=>{var t=jb(),n=N(t,!0);E(t),I(()=>V(n,a().description)),B(e,t)};U(g,e=>{a().description&&e(_)});var v=F(g,2),y=e=>{var t=Mb(),n=N(t);so(n,e=>M(o,e),()=>L(o)),E(t),I(()=>G(n,`aria-label`,`${Z.t.ariaJsonLdMapCanvas??``}: ${a().title??``}`)),B(e,t)};U(v,e=>{a().coords&&e(y)});var b=F(v,2),x=e=>{var t=Nb(),n=N(t,!0);E(t),I(()=>V(n,a().address)),B(e,t)};U(b,e=>{a().address&&e(x)});var S=F(b,2),C=N(S),ee=e=>{var t=Pb(),n=N(t);_b(n,{name:`phone`,class:`jsonld-card__cta-icon`});var r=F(n,2),i=N(r,!0);E(r),E(t),I(()=>{G(t,`href`,`tel:${a().phone??``}`),V(i,a().phone)}),B(e,t)};U(C,e=>{a().phone&&e(ee)});var te=F(C,2),ne=e=>{var t=Fb(),n=N(t);_b(n,{name:`email`,class:`jsonld-card__cta-icon`});var r=F(n,2),i=N(r,!0);E(r),E(t),I(()=>{G(t,`href`,`mailto:${a().email??``}`),V(i,a().email)}),B(e,t)};U(te,e=>{a().email&&e(ne)});var re=F(te,2),w=N(re),ie=N(w,!0);return E(w),_b(F(w,2),{name:`externalLink`,class:`jsonld-card__cta-icon`}),E(re),E(S),E(f),I(()=>{G(f,`aria-label`,`${Z.t.ariaJsonLdMapCard??``}: ${a().title??``}`),V(h,a().title),G(re,`href`,L(s)),V(ie,Z.t.jsonLdMapOpenMap)}),B(e,f),O(d)}q(Lb,{data:{}},[],[],{mode:`open`});var Rb=(e,t)=>{let n=e[t];return typeof n==`string`&&n.length>0?n:void 0},zb=(e,t)=>{let n=e[t];return typeof n==`number`&&Number.isFinite(n)?n:void 0},Bb=e=>e.display.card.title||e.display.listItem.title,Vb=e=>{let t=e.metadata;if(t.jsonLdBlock===`event-card`)return{block:`event-card`,data:{title:Bb(e),description:e.display.card.description,date:Rb(t,`jsonLdEventStartDate`),location:Rb(t,`jsonLdEventLocation`),ctaLabel:Rb(t,`jsonLdEventCtaLabel`),ctaUrl:Rb(t,`jsonLdEventCtaUrl`)??e.url}};if(t.jsonLdBlock===`map`){let n=zb(t,`jsonLdMapLat`),r=zb(t,`jsonLdMapLng`);return{block:`map`,data:{title:Rb(t,`jsonLdMapLabel`)??Bb(e),description:Rb(t,`jsonLdMapDescription`)??e.display.card.description,address:Rb(t,`jsonLdMapAddress`),url:Rb(t,`jsonLdMapUrl`),phone:Rb(t,`jsonLdMapPhone`),email:Rb(t,`jsonLdMapEmail`),coords:n!==void 0&&r!==void 0?{lat:n,lng:r}:void 0,zoom:zb(t,`jsonLdMapZoom`)??15,fallbackUrl:e.url,directionsUrl:Rb(t,`jsonLdMapDirectionsUrl`)}}}if(t.jsonLdBlock===`cta`)return{block:`cta`,data:{title:Bb(e),description:e.display.card.description,label:Rb(t,`jsonLdCtaLabel`),url:Rb(t,`jsonLdCtaUrl`)??e.url}}},Hb=R(`<div role="listitem"><!></div>`),Ub=R(`<div class="jsonld-references" role="list"></div>`);function Wb(e,t){D(t,!0);let n=K(t,`references`,7),r=K(t,`ready`,7,!1),i=A(()=>n().flatMap(e=>{let t=Vb(e);return t?[{key:e.url+e.referenceIndex.all,display:t}]:[]})),a=A(()=>Z.theme?.components?.messageOptions?.custom),o=A(()=>Number(L(a)?.transitionDuration)||300),s=A(()=>Number(L(a)?.transitionDelay)||0),c=A(()=>Number(L(a)?.transitionY)||30);var l={get references(){return n()},set references(e){n(e),k()},get ready(){return r()},set ready(e=!1){r(e),k()}},u=z(),d=P(u),f=e=>{var t=Ub();Xi(t,23,()=>L(i),({key:e,display:t})=>e,(e,t,n)=>{let i=()=>L(t).display;var a=Hb();let l,u;var d=N(a),f=e=>{Ab(e,{get data(){return i().data}})},p=e=>{Lb(e,{get data(){return i().data}})},m=e=>{wb(e,{get data(){return i().data}})};U(d,e=>{i().block===`event-card`?e(f):i().block===`map`?e(p,1):i().block===`cta`&&e(m,2)}),E(a),I(()=>{l=Da(a,1,`jsonld-references__item`,null,l,{"jsonld-references__item--preloading":!r()}),u=ka(a,``,u,{"--jsonld-item-duration":`${L(o)??``}ms`,"--jsonld-item-delay":`${L(s)+L(n)*L(o)}ms`,"--jsonld-item-y":`${L(c)??``}px`})}),B(e,a)}),E(t),B(e,t)};return U(d,e=>{L(i).length>0&&e(f)}),B(e,u),O(l)}q(Wb,{references:{},ready:{}},[],[],{mode:`open`});var Gb;function Kb(e,t,n,r,i){Gb&&cancelAnimationFrame(Gb);let a=e instanceof Window?r===`scrollTop`?window.scrollY:window.scrollX:e[r],o=performance.now();function s(c){let l=c-o,u=Math.min(l/n,1),d=i(u),f=a+(t-a)*d;e instanceof Window?r===`scrollTop`?window.scrollTo({top:f,behavior:`instant`}):window.scrollTo({left:f,behavior:`instant`}):e[r]=f,u<1?Gb=requestAnimationFrame(s):e.dispatchEvent(new CustomEvent(`scrollcomplete`))}Gb=requestAnimationFrame(s)}function qb(e){return typeof e==`function`}function Jb(e){return typeof e==`object`&&!!e}var Yb=[`string`,`number`,`bigint`,`boolean`];function Xb(e){return e==null||Yb.includes(typeof e)?!0:Array.isArray(e)?e.every(e=>Xb(e)):typeof e==`object`?Object.getPrototypeOf(e)===Object.prototype:!1}var Zb=Symbol(`box`),Qb=Symbol(`is-writable`);function Q(e,t){let n=A(e);return t?{[Zb]:!0,[Qb]:!0,get current(){return L(n)},set current(e){t(e)}}:{[Zb]:!0,get current(){return e()}}}function $b(e){return Jb(e)&&Zb in e}function ex(e){return $b(e)&&Qb in e}function tx(e){return $b(e)?e:qb(e)?Q(e):ix(e)}function nx(e){return Object.entries(e).reduce((e,[t,n])=>$b(n)?(ex(n)?Object.defineProperty(e,t,{get(){return n.current},set(e){n.current=e}}):Object.defineProperty(e,t,{get(){return n.current}}),e):Object.assign(e,{[t]:n}),{})}function rx(e){return ex(e)?{[Zb]:!0,get current(){return e.current}}:e}function ix(e){let t=j(Dn(e));return{[Zb]:!0,[Qb]:!0,get current(){return L(t)},set current(e){M(t,e,!0)}}}function ax(e){let t=j(Dn(e));return{[Zb]:!0,[Qb]:!0,get current(){return L(t)},set current(e){M(t,e,!0)}}}ax.from=tx,ax.with=Q,ax.flatten=nx,ax.readonly=rx,ax.isBox=$b,ax.isWritableBox=ex;function ox(...e){return function(t){for(let n of e)if(n){if(t.defaultPrevented)return;typeof n==`function`?n.call(this,t):n.current?.call(this,t)}}}var sx=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,cx=/\n/g,lx=/^\s*/,ux=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,dx=/^:\s*/,fx=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,px=/^[;\s]*/,mx=/^\s+|\s+$/g,hx=`
|
|
569
|
+
`,gx=`/`,_x=`*`,vx=``,yx=`comment`,bx=`declaration`;function xx(e,t){if(typeof e!=`string`)throw TypeError(`First argument must be a string`);if(!e)return[];t||={};var n=1,r=1;function i(e){var t=e.match(cx);t&&(n+=t.length);var i=e.lastIndexOf(hx);r=~i?e.length-i:r+e.length}function a(){var e={line:n,column:r};return function(t){return t.position=new o(e),l(),t}}function o(e){this.start=e,this.end={line:n,column:r},this.source=t.source}o.prototype.content=e;function s(i){var a=Error(t.source+`:`+n+`:`+r+`: `+i);if(a.reason=i,a.filename=t.source,a.line=n,a.column=r,a.source=e,!t.silent)throw a}function c(t){var n=t.exec(e);if(n){var r=n[0];return i(r),e=e.slice(r.length),n}}function l(){c(lx)}function u(e){var t;for(e||=[];t=d();)t!==!1&&e.push(t);return e}function d(){var t=a();if(!(gx!=e.charAt(0)||_x!=e.charAt(1))){for(var n=2;vx!=e.charAt(n)&&(_x!=e.charAt(n)||gx!=e.charAt(n+1));)++n;if(n+=2,vx===e.charAt(n-1))return s(`End of comment missing`);var o=e.slice(2,n-2);return r+=2,i(o),e=e.slice(n),r+=2,t({type:yx,comment:o})}}function f(){var e=a(),t=c(ux);if(t){if(d(),!c(dx))return s(`property missing ':'`);var n=c(fx),r=e({type:bx,property:Sx(t[0].replace(sx,vx)),value:n?Sx(n[0].replace(sx,vx)):vx});return c(px),r}}function p(){var e=[];u(e);for(var t;t=f();)t!==!1&&(e.push(t),u(e));return e}return l(),p()}function Sx(e){return e?e.replace(mx,vx):vx}function Cx(e,t){let n=null;if(!e||typeof e!=`string`)return n;let r=xx(e),i=typeof t==`function`;return r.forEach(e=>{if(e.type!==`declaration`)return;let{property:r,value:a}=e;i?t(r,a,e):a&&(n||={},n[r]=a)}),n}var wx=/\d/,Tx=[`-`,`_`,`/`,`.`];function Ex(e=``){if(!wx.test(e))return e!==e.toLowerCase()}function Dx(e){let t=[],n=``,r,i;for(let a of e){let e=Tx.includes(a);if(e===!0){t.push(n),n=``,r=void 0;continue}let o=Ex(a);if(i===!1){if(r===!1&&o===!0){t.push(n),n=a,r=o;continue}if(r===!0&&o===!1&&n.length>1){let e=n.at(-1);t.push(n.slice(0,Math.max(0,n.length-1))),n=e+a,r=o;continue}}n+=a,r=o,i=e}return t.push(n),t}function Ox(e){return e?Dx(e).map(e=>Ax(e)).join(``):``}function kx(e){return jx(Ox(e||``))}function Ax(e){return e?e[0].toUpperCase()+e.slice(1):``}function jx(e){return e?e[0].toLowerCase()+e.slice(1):``}function Mx(e){if(!e)return{};let t={};function n(e,n){if(e.startsWith(`-moz-`)||e.startsWith(`-webkit-`)||e.startsWith(`-ms-`)||e.startsWith(`-o-`)){t[Ox(e)]=n;return}if(e.startsWith(`--`)){t[e]=n;return}t[kx(e)]=n}return Cx(e,n),t}function Nx(...e){return(...t)=>{for(let n of e)typeof n==`function`&&n(...t)}}function Px(e,t){let n=RegExp(e,`g`);return e=>{if(typeof e!=`string`)throw TypeError(`expected an argument of type string, but got ${typeof e}`);return e.match(n)?e.replace(n,t):e}}var Fx=Px(/[A-Z]/,e=>`-${e.toLowerCase()}`);function Ix(e){if(!e||typeof e!=`object`||Array.isArray(e))throw TypeError(`expected an argument of type object, but got ${typeof e}`);return Object.keys(e).map(t=>`${Fx(t)}: ${e[t]};`).join(`
|
|
570
|
+
`)}function Lx(e={}){return Ix(e).replace(`
|
|
571
|
+
`,` `)}var Rx=new Set(`onabort.onanimationcancel.onanimationend.onanimationiteration.onanimationstart.onauxclick.onbeforeinput.onbeforetoggle.onblur.oncancel.oncanplay.oncanplaythrough.onchange.onclick.onclose.oncompositionend.oncompositionstart.oncompositionupdate.oncontextlost.oncontextmenu.oncontextrestored.oncopy.oncuechange.oncut.ondblclick.ondrag.ondragend.ondragenter.ondragleave.ondragover.ondragstart.ondrop.ondurationchange.onemptied.onended.onerror.onfocus.onfocusin.onfocusout.onformdata.ongotpointercapture.oninput.oninvalid.onkeydown.onkeypress.onkeyup.onload.onloadeddata.onloadedmetadata.onloadstart.onlostpointercapture.onmousedown.onmouseenter.onmouseleave.onmousemove.onmouseout.onmouseover.onmouseup.onpaste.onpause.onplay.onplaying.onpointercancel.onpointerdown.onpointerenter.onpointerleave.onpointermove.onpointerout.onpointerover.onpointerup.onprogress.onratechange.onreset.onresize.onscroll.onscrollend.onsecuritypolicyviolation.onseeked.onseeking.onselect.onselectionchange.onselectstart.onslotchange.onstalled.onsubmit.onsuspend.ontimeupdate.ontoggle.ontouchcancel.ontouchend.ontouchmove.ontouchstart.ontransitioncancel.ontransitionend.ontransitionrun.ontransitionstart.onvolumechange.onwaiting.onwebkitanimationend.onwebkitanimationiteration.onwebkitanimationstart.onwebkittransitionend.onwheel`.split(`.`));function zx(e){return Rx.has(e)}function Bx(...e){let t={...e[0]};for(let n=1;n<e.length;n++){let r=e[n];if(r){for(let e of Object.keys(r)){let n=t[e],i=r[e],a=typeof n==`function`,o=typeof i==`function`;if(a&&typeof o&&zx(e))t[e]=ox(n,i);else if(a&&o)t[e]=Nx(n,i);else if(e===`class`){let r=Xb(n),a=Xb(i);r&&a?t[e]=ba(n,i):r?t[e]=ba(n):a&&(t[e]=ba(i))}else if(e===`style`){let r=typeof n==`object`,a=typeof i==`object`,o=typeof n==`string`,s=typeof i==`string`;if(r&&a)t[e]={...n,...i};else if(r&&s){let r=Mx(i);t[e]={...n,...r}}else if(o&&a)t[e]={...Mx(n),...i};else if(o&&s){let r=Mx(n),a=Mx(i);t[e]={...r,...a}}else r?t[e]=n:a?t[e]=i:o?t[e]=n:s&&(t[e]=i)}else t[e]=i===void 0?n:i}for(let e of Object.getOwnPropertySymbols(r)){let n=t[e],i=r[e];t[e]=i===void 0?n:i}}}return typeof t.style==`object`&&(t.style=Lx(t.style).replaceAll(`
|
|
572
|
+
`,` `)),t.hidden===!1&&(t.hidden=void 0,delete t.hidden),t.disabled===!1&&(t.disabled=void 0,delete t.disabled),t}var Vx=Lx({position:`absolute`,width:`1px`,height:`1px`,padding:`0`,margin:`-1px`,overflow:`hidden`,clip:`rect(0, 0, 0, 0)`,whiteSpace:`nowrap`,borderWidth:`0`,transform:`translateX(-100%)`}),Hx=typeof window<`u`?window:void 0;typeof window<`u`&&window.document,typeof window<`u`&&window.navigator,typeof window<`u`&&window.location;function Ux(e){let t=e.activeElement;for(;t?.shadowRoot;){let e=t.shadowRoot.activeElement;if(e===t)break;t=e}return t}new class{#e;#t;constructor(e={}){let{window:t=Hx,document:n=t?.document}=e;t!==void 0&&(this.#e=n,this.#t=en(e=>{let n=ri(t,`focusin`,e),r=ri(t,`focusout`,e);return()=>{n(),r()}}))}get current(){return this.#t?.(),this.#e?Ux(this.#e):null}};function Wx(e){return typeof e==`function`}var Gx=class{#e;#t;constructor(e){this.#e=e,this.#t=Symbol(e)}get key(){return this.#t}exists(){return pt(this.#t)}get(){let e=dt(this.#t);if(e===void 0)throw Error(`Context "${this.#e}" not found`);return e}getOr(e){let t=dt(this.#t);return t===void 0?e:t}set(e){return ft(this.#t,e)}};function Kx(e,t){switch(e){case`post`:$n(t);break;case`pre`:tr(t);break}}function qx(e,t,n,r={}){let{lazy:i=!1}=r,a=!i,o=Array.isArray(e)?[]:void 0;Kx(t,()=>{let t=Array.isArray(e)?e.map(e=>e()):e();if(!a){a=!0,o=t;return}let r=Xr(()=>n(t,o));return o=t,r})}function Jx(e,t,n){let r=nr(()=>{let i=!1;qx(e,t,(e,t)=>{if(i){r();return}let a=n(e,t);return i=!0,a},{lazy:!0})});$n(()=>r)}function Yx(e,t,n){qx(e,`post`,t,n)}function Xx(e,t,n){qx(e,`pre`,t,n)}Yx.pre=Xx;function Zx(e,t){Jx(e,`post`,t)}function Qx(e,t){Jx(e,`pre`,t)}Zx.pre=Qx;function $x(e){return Wx(e)?e():e}var eS=class{#e={width:0,height:0};#t=!1;#n;#r;#i;#a=A(()=>(L(this.#s)?.(),this.getSize().width));#o=A(()=>(L(this.#s)?.(),this.getSize().height));#s=A(()=>{let e=$x(this.#r);if(e)return en(t=>{if(!this.#i)return;let n=new this.#i.ResizeObserver(e=>{this.#t=!0;for(let t of e){let e=this.#n.box===`content-box`?t.contentBoxSize:t.borderBoxSize,n=Array.isArray(e)?e:[e];this.#e.width=n.reduce((e,t)=>Math.max(e,t.inlineSize),0),this.#e.height=n.reduce((e,t)=>Math.max(e,t.blockSize),0)}t()});return n.observe(e),()=>{this.#t=!1,n.disconnect()}})});constructor(e,t={box:`border-box`}){this.#i=t.window??Hx,this.#n=t,this.#r=e,this.#e={width:0,height:0}}calculateSize(){let e=$x(this.#r);if(!e||!this.#i)return;let t=e.offsetWidth,n=e.offsetHeight;if(this.#n.box===`border-box`)return{width:t,height:n};let r=this.#i.getComputedStyle(e),i=parseFloat(r.paddingLeft)+parseFloat(r.paddingRight),a=parseFloat(r.paddingTop)+parseFloat(r.paddingBottom),o=parseFloat(r.borderLeftWidth)+parseFloat(r.borderRightWidth),s=parseFloat(r.borderTopWidth)+parseFloat(r.borderBottomWidth);return{width:t-i-o,height:n-a-s}}getSize(){return this.#t?this.#e:this.calculateSize()??this.#e}get current(){return L(this.#s)?.(),this.getSize()}get width(){return L(this.#a)}get height(){return L(this.#o)}},tS=class{#e=()=>void 0;#t=A(()=>this.#e());constructor(e,t){let n;t!==void 0&&(n=t),this.#e=()=>{try{return n}finally{n=e()}}}get current(){return L(this.#t)}};function nS(e,t){let n,r=null;return(...i)=>new Promise(a=>{r&&r(void 0),r=a,clearTimeout(n),n=setTimeout(async()=>{let t=await e(...i);r&&=(r(t),null)},t)})}function rS(e,t){let n=0,r=null;return(...i)=>{let a=Date.now();return n&&a-n<t?r??Promise.resolve(void 0):(n=a,r=e(...i),r)}}function iS(e,t,n={},r){let{lazy:i=!1,once:a=!1,initialValue:o,debounce:s,throttle:c}=n,l=j(Dn(o)),u=j(!1),d=j(void 0),f=j(Dn([])),p=()=>{L(f).forEach(e=>e()),M(f,[],!0)},m=e=>{M(f,[...L(f),e],!0)},h=async(e,n,r=!1)=>{try{M(u,!0),M(d,void 0),p();let i=new AbortController;m(()=>i.abort());let a=await t(e,n,{data:L(l),refetching:r,onCleanup:m,signal:i.signal});return M(l,a,!0),a}catch(e){e instanceof DOMException&&e.name===`AbortError`||M(d,e,!0);return}finally{M(u,!1)}},g=s?nS(h,s):c?rS(h,c):h,_=Array.isArray(e)?e:[e],v;return r((t,n)=>{a&&v||(v=t,g(Array.isArray(e)?t:t[0],Array.isArray(e)?n:n?.[0]))},{lazy:i}),{get current(){return L(l)},get loading(){return L(u)},get error(){return L(d)},mutate:e=>{M(l,e,!0)},refetch:t=>{let n=_.map(e=>e());return g(Array.isArray(e)?n:n[0],Array.isArray(e)?n:n[0],t??!0)}}}function aS(e,t,n){return iS(e,t,n,(t,n)=>{let r=Array.isArray(e)?e:[e];Yx(()=>r.map(e=>e()),(e,n)=>{t(e,n??[])},n)})}function oS(e,t,n){return iS(e,t,n,(t,n)=>{let r=Array.isArray(e)?e:[e];Yx.pre(()=>r.map(e=>e()),(e,n)=>{t(e,n??[])},n)})}aS.pre=oS;function sS(e){$n(()=>()=>{e()})}function cS(e){$n(()=>Xr(()=>e()))}function lS(e,t){return setTimeout(t,e)}function uS(e){qr().then(e)}var dS=1,fS=9,pS=11;function mS(e){return Jb(e)&&e.nodeType===dS&&typeof e.nodeName==`string`}function hS(e){return Jb(e)&&e.nodeType===fS}function gS(e){return Jb(e)&&e.constructor?.name===`VisualViewport`}function _S(e){return Jb(e)&&e.nodeType!==void 0}function vS(e){return _S(e)&&e.nodeType===pS&&`host`in e}function yS(e,t){if(!e||!t||!mS(e)||!mS(t))return!1;let n=t.getRootNode?.();if(e===t||e.contains(t))return!0;if(n&&vS(n)){let n=t;for(;n;){if(e===n)return!0;n=n.parentNode||n.host}}return!1}function bS(e){return hS(e)?e:gS(e)?e.document:e?.ownerDocument??document}function xS(e){return vS(e)?xS(e.host):hS(e)?e.defaultView??window:mS(e)?e.ownerDocument?.defaultView??window:window}function SS(e){let t=e.activeElement;for(;t?.shadowRoot;){let e=t.shadowRoot.activeElement;if(e===t)break;t=e}return t}var CS=class{element;#e=A(()=>this.element.current?this.element.current.getRootNode()??document:document);get root(){return L(this.#e)}set root(e){M(this.#e,e)}constructor(e){typeof e==`function`?this.element=Q(e):this.element=e}getDocument=()=>bS(this.root);getWindow=()=>this.getDocument().defaultView??window;getActiveElement=()=>SS(this.root);isActiveElement=e=>e===this.getActiveElement();getElementById(e){return this.root.getElementById(e)}querySelector=e=>this.root?this.root.querySelector(e):null;querySelectorAll=e=>this.root?this.root.querySelectorAll(e):[];setTimeout=(e,t)=>this.getWindow().setTimeout(e,t);clearTimeout=e=>this.getWindow().clearTimeout(e)};function wS(e,t){return{[zi()]:n=>$b(e)?(e.current=n,Xr(()=>t?.(n)),()=>{`isConnected`in n&&n.isConnected||(e.current=null,t?.(null))}):(e(n),Xr(()=>t?.(n)),()=>{`isConnected`in n&&n.isConnected||(e(null),t?.(null))})}}function TS(e){return e?`true`:`false`}function ES(e){return e?`true`:void 0}function DS(e){return e?``:void 0}function OS(e){return e?!0:void 0}function kS(e){return e?`open`:`closed`}function AS(e,t){return t?`mixed`:e?`true`:`false`}var jS=class{#e;#t;attrs;constructor(e){this.#e=e.getVariant?e.getVariant():null,this.#t=this.#e?`data-${this.#e}-`:`data-${e.component}-`,this.getAttr=this.getAttr.bind(this),this.selector=this.selector.bind(this),this.attrs=Object.fromEntries(e.parts.map(e=>[e,this.getAttr(e)]))}getAttr(e,t){return t?`data-${t}-${e}`:`${this.#t}${e}`}selector(e,t){return`[${this.getAttr(e,t)}]`}};function MS(e){let t=new jS(e);return{...t.attrs,selector:t.selector,getAttr:t.getAttr}}var NS=`ArrowDown`,PS=`ArrowLeft`,FS=`ArrowRight`,IS=`ArrowUp`,LS=`CapsLock`,RS=`Control`,zS=`Enter`,BS=`Escape`,VS=`Home`,HS=`Meta`,US=`PageDown`,WS=`PageUp`,GS=`Shift`;function KS(e){return window.getComputedStyle(e).getPropertyValue(`direction`)}var qS=[NS,WS,VS],JS=[IS,US,`End`];[...qS,...JS];function YS(e=`ltr`,t=`horizontal`){return{horizontal:e===`rtl`?PS:FS,vertical:NS}[t]}function XS(e=`ltr`,t=`horizontal`){return{horizontal:e===`rtl`?FS:PS,vertical:IS}[t]}function ZS(e=`ltr`,t=`horizontal`){return[`ltr`,`rtl`].includes(e)||(e=`ltr`),[`horizontal`,`vertical`].includes(t)||(t=`horizontal`),{nextKey:YS(e,t),prevKey:XS(e,t)}}var QS=typeof document<`u`,$S=eC();function eC(){return QS&&window?.navigator?.userAgent&&(/iP(ad|hone|od)/.test(window.navigator.userAgent)||window?.navigator?.maxTouchPoints>2&&/iPad|Macintosh/.test(window?.navigator.userAgent))}function tC(e){return e instanceof HTMLElement}function nC(e){return e instanceof Element}function rC(e){return e instanceof Element||e instanceof SVGElement}function iC(e){return e.pointerType===`touch`}function aC(e){return e!==null}function oC(e){return e instanceof HTMLInputElement&&`select`in e}var sC=class{#e;#t=ax(null);constructor(e){this.#e=e}getCandidateNodes(){return this.#e.rootNode.current?this.#e.candidateSelector?Array.from(this.#e.rootNode.current.querySelectorAll(this.#e.candidateSelector)):this.#e.candidateAttr?Array.from(this.#e.rootNode.current.querySelectorAll(`[${this.#e.candidateAttr}]:not([data-disabled])`)):[]:[]}focusFirstCandidate(){let e=this.getCandidateNodes();e.length&&e[0]?.focus()}handleKeydown(e,t,n=!1){let r=this.#e.rootNode.current;if(!r||!e)return;let i=this.getCandidateNodes();if(!i.length)return;let a=i.indexOf(e),{nextKey:o,prevKey:s}=ZS(KS(r),this.#e.orientation.current),c=this.#e.loop.current,l={[o]:a+1,[s]:a-1,[VS]:0,End:i.length-1};if(n){let e=o===`ArrowDown`?FS:NS,t=s===`ArrowUp`?PS:IS;l[e]=a+1,l[t]=a-1}let u=l[t.key];if(u===void 0)return;t.preventDefault(),u<0&&c?u=i.length-1:u===i.length&&c&&(u=0);let d=i[u];if(d)return d.focus(),this.#t.current=d.id,this.#e.onCandidateFocus?.(d),d}getTabIndex(e){let t=this.getCandidateNodes(),n=this.#t.current!==null;return e&&!n&&t[0]===e?(this.#t.current=e.id,0):e?.id===this.#t.current?0:-1}setCurrentTabStopId(e){this.#t.current=e}focusCurrentTabStop(){let e=this.#t.current;if(!e)return;let t=this.#e.rootNode.current?.querySelector(`#${e}`);!t||!tC(t)||t.focus()}},cC=class{#e;#t=null;constructor(e){this.#e=e,sS(()=>this.#n())}#n(){this.#t&&=(window.cancelAnimationFrame(this.#t),null)}run(e){this.#n();let t=this.#e.ref.current;if(t){if(typeof t.getAnimations!=`function`){this.#r(e);return}this.#t=window.requestAnimationFrame(()=>{let n=t.getAnimations();if(n.length===0){this.#r(e);return}Promise.allSettled(n.map(e=>e.finished)).then(()=>{this.#r(e)})})}}#r(e){let t=()=>{e()};this.#e.afterTick?uS(t):t()}},lC=class{#e;#t;#n;#r=j(!1);constructor(e){this.#e=e,M(this.#r,e.open.current,!0),this.#t=e.enabled??!0,this.#n=new cC({ref:this.#e.ref,afterTick:this.#e.open}),Yx(()=>this.#e.open.current,e=>{e&&M(this.#r,!0),this.#t&&this.#n.run(()=>{e===this.#e.open.current&&(this.#e.open.current||M(this.#r,!1),this.#e.onComplete?.())})})}get shouldRender(){return L(this.#r)}};function $(){}function uC(e,t){return t===void 0?`bits-${e}`:`bits-${e}-${t}`}var dC=MS({component:`dialog`,parts:[`content`,`trigger`,`overlay`,`title`,`description`,`close`,`cancel`,`action`]}),fC=new Gx(`Dialog.Root | AlertDialog.Root`),pC=class e{static create(t){let n=fC.getOr(null);return fC.set(new e(t,n))}opts;#e=j(null);get triggerNode(){return L(this.#e)}set triggerNode(e){M(this.#e,e,!0)}#t=j(null);get contentNode(){return L(this.#t)}set contentNode(e){M(this.#t,e,!0)}#n=j(null);get overlayNode(){return L(this.#n)}set overlayNode(e){M(this.#n,e,!0)}#r=j(null);get descriptionNode(){return L(this.#r)}set descriptionNode(e){M(this.#r,e,!0)}#i=j(void 0);get contentId(){return L(this.#i)}set contentId(e){M(this.#i,e,!0)}#a=j(void 0);get titleId(){return L(this.#a)}set titleId(e){M(this.#a,e,!0)}#o=j(void 0);get triggerId(){return L(this.#o)}set triggerId(e){M(this.#o,e,!0)}#s=j(void 0);get descriptionId(){return L(this.#s)}set descriptionId(e){M(this.#s,e,!0)}#c=j(null);get cancelNode(){return L(this.#c)}set cancelNode(e){M(this.#c,e,!0)}#l=j(0);get nestedOpenCount(){return L(this.#l)}set nestedOpenCount(e){M(this.#l,e,!0)}depth;parent;contentPresence;overlayPresence;constructor(e,t){this.opts=e,this.parent=t,this.depth=t?t.depth+1:0,this.handleOpen=this.handleOpen.bind(this),this.handleClose=this.handleClose.bind(this),this.contentPresence=new lC({ref:Q(()=>this.contentNode),open:this.opts.open,enabled:!0,onComplete:()=>{this.opts.onOpenChangeComplete.current(this.opts.open.current)}}),this.overlayPresence=new lC({ref:Q(()=>this.overlayNode),open:this.opts.open,enabled:!0}),Yx(()=>this.opts.open.current,e=>{this.parent&&(e?this.parent.incrementNested():this.parent.decrementNested())},{lazy:!0}),sS(()=>{this.opts.open.current&&this.parent?.decrementNested()})}handleOpen(){this.opts.open.current||(this.opts.open.current=!0)}handleClose(){this.opts.open.current&&(this.opts.open.current=!1)}getBitsAttr=e=>dC.getAttr(e,this.opts.variant.current);incrementNested(){this.nestedOpenCount++,this.parent?.incrementNested()}decrementNested(){this.nestedOpenCount!==0&&(this.nestedOpenCount--,this.parent?.decrementNested())}#u=A(()=>({"data-state":kS(this.opts.open.current)}));get sharedProps(){return L(this.#u)}set sharedProps(e){M(this.#u,e)}},mC=class e{static create(t){return new e(t,fC.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=wS(this.opts.ref),this.onclick=this.onclick.bind(this),this.onkeydown=this.onkeydown.bind(this)}onclick(e){this.opts.disabled.current||e.button>0||this.root.handleClose()}onkeydown(e){this.opts.disabled.current||(e.key===` `||e.key===`Enter`)&&(e.preventDefault(),this.root.handleClose())}#e=A(()=>({id:this.opts.id.current,[this.root.getBitsAttr(this.opts.variant.current)]:``,onclick:this.onclick,onkeydown:this.onkeydown,disabled:this.opts.disabled.current?!0:void 0,tabindex:0,...this.root.sharedProps,...this.attachment}));get props(){return L(this.#e)}set props(e){M(this.#e,e)}},hC=class e{static create(t){return new e(t,fC.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.root.titleId=this.opts.id.current,this.attachment=wS(this.opts.ref),Yx.pre(()=>this.opts.id.current,e=>{this.root.titleId=e})}#e=A(()=>({id:this.opts.id.current,role:`heading`,"aria-level":this.opts.level.current,[this.root.getBitsAttr(`title`)]:``,...this.root.sharedProps,...this.attachment}));get props(){return L(this.#e)}set props(e){M(this.#e,e)}},gC=class e{static create(t){return new e(t,fC.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.root.descriptionId=this.opts.id.current,this.attachment=wS(this.opts.ref,e=>{this.root.descriptionNode=e}),Yx.pre(()=>this.opts.id.current,e=>{this.root.descriptionId=e})}#e=A(()=>({id:this.opts.id.current,[this.root.getBitsAttr(`description`)]:``,...this.root.sharedProps,...this.attachment}));get props(){return L(this.#e)}set props(e){M(this.#e,e)}},_C=class e{static create(t){return new e(t,fC.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=wS(this.opts.ref,e=>{this.root.contentNode=e,this.root.contentId=e?.id})}#e=A(()=>({open:this.root.opts.open.current}));get snippetProps(){return L(this.#e)}set snippetProps(e){M(this.#e,e)}#t=A(()=>({id:this.opts.id.current,role:this.root.opts.variant.current===`alert-dialog`?`alertdialog`:`dialog`,"aria-modal":`true`,"aria-describedby":this.root.descriptionId,"aria-labelledby":this.root.titleId,[this.root.getBitsAttr(`content`)]:``,style:{pointerEvents:`auto`,outline:this.root.opts.variant.current===`alert-dialog`?`none`:void 0,"--bits-dialog-depth":this.root.depth,"--bits-dialog-nested-count":this.root.nestedOpenCount,contain:`layout style`},tabindex:this.root.opts.variant.current===`alert-dialog`?-1:void 0,"data-nested-open":DS(this.root.nestedOpenCount>0),"data-nested":DS(this.root.parent!==null),...this.root.sharedProps,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}get shouldRender(){return this.root.contentPresence.shouldRender}},vC=class e{static create(t){return new e(t,fC.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=wS(this.opts.ref,e=>this.root.overlayNode=e)}#e=A(()=>({open:this.root.opts.open.current}));get snippetProps(){return L(this.#e)}set snippetProps(e){M(this.#e,e)}#t=A(()=>({id:this.opts.id.current,[this.root.getBitsAttr(`overlay`)]:``,style:{pointerEvents:`auto`,"--bits-dialog-depth":this.root.depth,"--bits-dialog-nested-count":this.root.nestedOpenCount},"data-nested-open":DS(this.root.nestedOpenCount>0),"data-nested":DS(this.root.parent!==null),...this.root.sharedProps,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}get shouldRender(){return this.root.overlayPresence.shouldRender}},yC=R(`<div><!></div>`);function bC(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>uC(n)),i=K(t,`ref`,15,null),a=K(t,`child`,7),o=K(t,`children`,7),s=K(t,`level`,7,2),c=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`ref`,`child`,`children`,`level`]),l=hC.create({id:Q(()=>r()),level:Q(()=>s()),ref:Q(()=>i(),e=>i(e))}),u=A(()=>Bx(c,l.props));var d={get id(){return r()},set id(e=uC(n)){r(e),k()},get ref(){return i()},set ref(e=null){i(e),k()},get child(){return a()},set child(e){a(e),k()},get children(){return o()},set children(e){o(e),k()},get level(){return s()},set level(e=2){s(e),k()}},f=z(),p=P(f),m=e=>{var t=z();H(P(t),a,()=>({props:L(u)})),B(e,t)},h=e=>{var t=yC();Ja(t,()=>({...L(u)})),H(N(t),()=>o()??w),E(t),B(e,t)};return U(p,e=>{a()?e(m):e(h,-1)}),B(e,f),O(d)}q(bC,{id:{},ref:{},child:{},children:{},level:{}},[],[],{mode:`open`});function xC(e,t){D(t,!0);let n=K(t,`children`,7);var r={get children(){return n()},set children(e){n(e),k()}},i=z();return Gi(P(i),n,e=>{var t=z();H(P(t),()=>n()??w),B(e,t)}),B(e,i),O(r)}q(xC,{children:{}},[],[],{mode:`open`});var SC=new Gx(`BitsConfig`);function CC(){let e=new TC(null,{});return SC.getOr(e).opts}function wC(e){return SC.set(new TC(SC.getOr(null),e))}var TC=class{opts;constructor(e,t){let n=EC(e,t);this.opts={defaultPortalTo:n(e=>e.defaultPortalTo),defaultLocale:n(e=>e.defaultLocale)}}};function EC(e,t){return n=>Q(()=>{let r=n(t)?.current;if(r!==void 0)return r;if(e!==null)return n(e.opts)?.current})}function DC(e,t){return n=>{let r=CC();return Q(()=>{let i=n();if(i!==void 0)return i;let a=e(r).current;return a===void 0?t:a})}}var OC=DC(e=>e.defaultPortalTo,`body`);function kC(e,t){D(t,!0);let n=K(t,`to`,7),r=K(t,`children`,7),i=K(t,`disabled`,7),a=OC(()=>n()),o=mt(),s=A(c);function c(){if(!QS||i())return null;let e=null;return e=typeof a.current==`string`?document.querySelector(a.current):a.current,e}let l;function u(){l&&=(Pi(l),null)}Yx([()=>L(s),()=>i()],([e,t])=>{if(!e||t){u();return}return l=ki(xC,{target:e,props:{children:r()},context:o}),()=>{u()}});var d={get to(){return n()},set to(e){n(e),k()},get children(){return r()},set children(e){r(e),k()},get disabled(){return i()},set disabled(e){i(e),k()}},f=z(),p=P(f),m=e=>{var t=z();H(P(t),()=>r()??w),B(e,t)};return U(p,e=>{i()&&e(m)}),B(e,f),O(d)}q(kC,{to:{},children:{},disabled:{}},[],[],{mode:`open`});var AC=class{eventName;options;constructor(e,t={bubbles:!0,cancelable:!0}){this.eventName=e,this.options=t}createEvent(e){return new CustomEvent(this.eventName,{...this.options,detail:e})}dispatch(e,t){let n=this.createEvent(t);return e.dispatchEvent(n),n}listen(e,t,n){return ri(e,this.eventName,e=>{t(e)},n)}};function jC(e,t=500){let n=null,r=(...r)=>{n!==null&&clearTimeout(n),n=setTimeout(()=>{e(...r)},t)};return r.destroy=()=>{n!==null&&(clearTimeout(n),n=null)},r}function MC(e,t){return e===t||e.contains(t)}function NC(e){return e?.ownerDocument??document}function PC(e,t){let{clientX:n,clientY:r}=e,i=t.getBoundingClientRect();return n<i.left||n>i.right||r<i.top||r>i.bottom}var FC=[zS,` `],IC=[NS,WS,VS],LC=[IS,US,`End`],RC=[...IC,...LC];[...FC],[...FC];function zC(e){return e===`indeterminate`}function BC(e){return zC(e)?`indeterminate`:e?`checked`:`unchecked`}function VC(e){return e.pointerType===`mouse`}function HC(e,{select:t=!1}={}){if(!e||!e.focus)return;let n=bS(e);if(n.activeElement===e)return;let r=n.activeElement;e.focus({preventScroll:!0}),e!==r&&oC(e)&&t&&e.select()}function UC(e,{select:t=!1}={},n){let r=n();for(let i of e)if(HC(i,{select:t}),n()!==r)return!0}var WC=j(!1),GC=class e{static _refs=0;static _cleanup;constructor(){$n(()=>(e._refs===0&&(e._cleanup=nr(()=>{let e=[],t=e=>{M(WC,!1)};return e.push(ri(document,`pointerdown`,t,{capture:!0}),ri(document,`pointermove`,t,{capture:!0}),ri(document,`keydown`,e=>{M(WC,!0)},{capture:!0})),Nx(...e)})),e._refs++,()=>{e._refs--,e._refs===0&&(M(WC,!1),e._cleanup?.())}))}get current(){return L(WC)}set current(e){M(WC,e,!0)}},KC=[`input:not([inert]):not([inert] *)`,`select:not([inert]):not([inert] *)`,`textarea:not([inert]):not([inert] *)`,`a[href]:not([inert]):not([inert] *)`,`button:not([inert]):not([inert] *)`,`[tabindex]:not(slot):not([inert]):not([inert] *)`,`audio[controls]:not([inert]):not([inert] *)`,`video[controls]:not([inert]):not([inert] *)`,`[contenteditable]:not([contenteditable="false"]):not([inert]):not([inert] *)`,`details>summary:first-of-type:not([inert]):not([inert] *)`,`details:not([inert]):not([inert] *)`],qC=KC.join(`,`),JC=typeof Element>`u`,YC=JC?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,XC=!JC&&Element.prototype.getRootNode?function(e){return e?.getRootNode?.call(e)}:function(e){return e?.ownerDocument},ZC=function(e,t){t===void 0&&(t=!0);var n=e?.getAttribute?.call(e,`inert`);return n===``||n===`true`||t&&e&&(typeof e.closest==`function`?e.closest(`[inert]`):ZC(e.parentNode))},QC=function(e){var t=e?.getAttribute?.call(e,`contenteditable`);return t===``||t===`true`},$C=function(e,t,n){if(ZC(e))return[];var r=Array.prototype.slice.apply(e.querySelectorAll(qC));return t&&YC.call(e,qC)&&r.unshift(e),r=r.filter(n),r},ew=function(e,t,n){for(var r=[],i=Array.from(e);i.length;){var a=i.shift();if(!ZC(a,!1))if(a.tagName===`SLOT`){var o=a.assignedElements(),s=ew(o.length?o:a.children,!0,n);n.flatten?r.push.apply(r,s):r.push({scopeParent:a,candidates:s})}else{YC.call(a,qC)&&n.filter(a)&&(t||!e.includes(a))&&r.push(a);var c=a.shadowRoot||typeof n.getShadowRoot==`function`&&n.getShadowRoot(a),l=!ZC(c,!1)&&(!n.shadowRootFilter||n.shadowRootFilter(a));if(c&&l){var u=ew(c===!0?a.children:c.children,!0,n);n.flatten?r.push.apply(r,u):r.push({scopeParent:a,candidates:u})}else i.unshift.apply(i,a.children)}}return r},tw=function(e){return!isNaN(parseInt(e.getAttribute(`tabindex`),10))},nw=function(e){if(!e)throw Error(`No node provided`);return e.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(e.tagName)||QC(e))&&!tw(e)?0:e.tabIndex},rw=function(e,t){var n=nw(e);return n<0&&t&&!tw(e)?0:n},iw=function(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex},aw=function(e){return e.tagName===`INPUT`},ow=function(e){return aw(e)&&e.type===`hidden`},sw=function(e){return e.tagName===`DETAILS`&&Array.prototype.slice.apply(e.children).some(function(e){return e.tagName===`SUMMARY`})},cw=function(e,t){for(var n=0;n<e.length;n++)if(e[n].checked&&e[n].form===t)return e[n]},lw=function(e){if(!e.name)return!0;var t=e.form||XC(e),n=function(e){return t.querySelectorAll(`input[type="radio"][name="`+e+`"]`)},r;if(typeof window<`u`&&window.CSS!==void 0&&typeof window.CSS.escape==`function`)r=n(window.CSS.escape(e.name));else try{r=n(e.name)}catch(e){return console.error(`Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s`,e.message),!1}var i=cw(r,e.form);return!i||i===e},uw=function(e){return aw(e)&&e.type===`radio`},dw=function(e){return uw(e)&&!lw(e)},fw=function(e){var t=e&&XC(e),n=t?.host,r=!1;if(t&&t!==e){var i,a,o;for(r=!!((i=n)!=null&&(a=i.ownerDocument)!=null&&a.contains(n)||e!=null&&(o=e.ownerDocument)!=null&&o.contains(e));!r&&n;){var s,c;t=XC(n),n=t?.host,r=!!((s=n)!=null&&(c=s.ownerDocument)!=null&&c.contains(n))}}return r},pw=function(e){var t=e.getBoundingClientRect(),n=t.width,r=t.height;return n===0&&r===0},mw=function(e,t){var n=t.displayCheck,r=t.getShadowRoot;if(n===`full-native`&&`checkVisibility`in e)return!e.checkVisibility({checkOpacity:!1,opacityProperty:!1,contentVisibilityAuto:!0,visibilityProperty:!0,checkVisibilityCSS:!0});if(getComputedStyle(e).visibility===`hidden`)return!0;var i=YC.call(e,`details>summary:first-of-type`)?e.parentElement:e;if(YC.call(i,`details:not([open]) *`))return!0;if(!n||n===`full`||n===`full-native`||n===`legacy-full`){if(typeof r==`function`){for(var a=e;e;){var o=e.parentElement,s=XC(e);if(o&&!o.shadowRoot&&r(o)===!0)return pw(e);e=e.assignedSlot?e.assignedSlot:!o&&s!==e.ownerDocument?s.host:o}e=a}if(fw(e))return!e.getClientRects().length;if(n!==`legacy-full`)return!0}else if(n===`non-zero-area`)return pw(e);return!1},hw=function(e){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e.tagName))for(var t=e.parentElement;t;){if(t.tagName===`FIELDSET`&&t.disabled){for(var n=0;n<t.children.length;n++){var r=t.children.item(n);if(r.tagName===`LEGEND`)return YC.call(t,`fieldset[disabled] *`)?!0:!r.contains(e)}return!0}t=t.parentElement}return!1},gw=function(e,t){return!(t.disabled||ow(t)||mw(t,e)||sw(t)||hw(t))},_w=function(e,t){return!(dw(t)||nw(t)<0||!gw(e,t))},vw=function(e){var t=parseInt(e.getAttribute(`tabindex`),10);return!!(isNaN(t)||t>=0)},yw=function(e){var t=[],n=[];return e.forEach(function(e,r){var i=!!e.scopeParent,a=i?e.scopeParent:e,o=rw(a,i),s=i?yw(e.candidates):a;o===0?i?t.push.apply(t,s):t.push(a):n.push({documentOrder:r,tabIndex:o,item:e,isScope:i,content:s})}),n.sort(iw).reduce(function(e,t){return t.isScope?e.push.apply(e,t.content):e.push(t.content),e},[]).concat(t)},bw=function(e,t){return t||={},yw(t.getShadowRoot?ew([e],t.includeContainer,{filter:_w.bind(null,t),flatten:!1,getShadowRoot:t.getShadowRoot,shadowRootFilter:vw}):$C(e,t.includeContainer,_w.bind(null,t)))},xw=function(e,t){return t||={},t.getShadowRoot?ew([e],t.includeContainer,{filter:gw.bind(null,t),flatten:!0,getShadowRoot:t.getShadowRoot}):$C(e,t.includeContainer,gw.bind(null,t))},Sw=function(e,t){if(t||={},!e)throw Error(`No node provided`);return YC.call(e,qC)===!1?!1:_w(t,e)},Cw=KC.concat(`iframe:not([inert]):not([inert] *)`).join(`,`),ww=function(e,t){if(t||={},!e)throw Error(`No node provided`);return YC.call(e,Cw)===!1?!1:gw(t,e)};function Tw(){return{getShadowRoot:!0,displayCheck:typeof ResizeObserver==`function`&&ResizeObserver.toString().includes(`[native code]`)?`full`:`none`}}function Ew(e,t){if(!Sw(e,Tw()))return Dw(e,t);let n=bS(e),r=bw(n.body,Tw());t===`prev`&&r.reverse();let i=r.indexOf(e);return i===-1?n.body:r.slice(i+1)[0]}function Dw(e,t){let n=bS(e);if(!ww(e,Tw()))return n.body;let r=xw(n.body,Tw());t===`prev`&&r.reverse();let i=r.indexOf(e);return i===-1?n.body:r.slice(i+1).find(e=>Sw(e,Tw()))??n.body}function Ow(e,t){return e.length===t.length?e.every((e,n)=>kw(e,t[n])):!1}function kw(e,t){return Number.isNaN(e)&&Number.isNaN(t)?!0:Array.isArray(e)&&Array.isArray(t)?Ow(e,t):typeof e==`object`&&typeof t==`object`?Aw(e,t):Object.is(e,t)}function Aw(e,t){if(typeof e!=`object`||typeof t!=`object`||e===null||t===null)return!1;let n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(let i of n)if(!r.includes(i)||!kw(e[i],t[i]))return!1;return!0}function jw(e,t,n=!0){if(!(e.length===0||t<0||t>=e.length))return e.length===1&&t===0?e[0]:t===e.length-1?n?e[0]:void 0:e[t+1]}function Mw(e,t,n=!0){if(!(e.length===0||t<0||t>=e.length))return e.length===1&&t===0?e[0]:t===0?n?e[e.length-1]:void 0:e[t-1]}function Nw(e,t,n,r=!0){if(e.length===0||t<0||t>=e.length)return;let i=t+n;return i=r?(i%e.length+e.length)%e.length:Math.max(0,Math.min(i,e.length-1)),e[i]}function Pw(e,t,n,r=!0){if(e.length===0||t<0||t>=e.length)return;let i=t-n;return i=r?(i%e.length+e.length)%e.length:Math.max(0,Math.min(i,e.length-1)),e[i]}function Fw(e,t,n){let r=t.toLowerCase();if(r.endsWith(` `)){let i=r.slice(0,-1);if(e.filter(e=>e.toLowerCase().startsWith(i)).length<=1)return Fw(e,i,n);let a=n?.toLowerCase();if(a&&a.startsWith(i)&&a.charAt(i.length)===` `&&t.trim()===i)return n;let o=e.filter(e=>e.toLowerCase().startsWith(r));if(o.length>0){let t=n?e.indexOf(n):-1;return Iw(o,Math.max(t,0)).find(e=>e!==n)||n}}let i=t.length>1&&Array.from(t).every(e=>e===t[0])?t[0]:t,a=i.toLowerCase(),o=n?e.indexOf(n):-1,s=Iw(e,Math.max(o,0));i.length===1&&(s=s.filter(e=>e!==n));let c=s.find(e=>e?.toLowerCase().startsWith(a));return c===n?void 0:c}function Iw(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var Lw={afterMs:1e4,onChange:$};function Rw(e,t){let{afterMs:n,onChange:r,getWindow:i}={...Lw,...t},a=null,o=j(Dn(e));function s(){return i().setTimeout(()=>{M(o,e,!0),r?.(e)},n)}return $n(()=>()=>{a&&i().clearTimeout(a)}),Q(()=>L(o),e=>{M(o,e,!0),r?.(e),a&&i().clearTimeout(a),a=s()})}var zw=class{#e;#t;#n=A(()=>this.#e.onMatch?this.#e.onMatch:e=>e.focus());#r=A(()=>this.#e.getCurrentItem?this.#e.getCurrentItem:this.#e.getActiveElement);constructor(e){this.#e=e,this.#t=Rw(``,{afterMs:1e3,getWindow:e.getWindow}),this.handleTypeaheadSearch=this.handleTypeaheadSearch.bind(this),this.resetTypeahead=this.resetTypeahead.bind(this)}handleTypeaheadSearch(e,t){if(!t.length)return;this.#t.current=this.#t.current+e;let n=L(this.#r)(),r=t.find(e=>e===n)?.textContent?.trim()??``,i=Fw(t.map(e=>e.textContent?.trim()??``),this.#t.current,r),a=t.find(e=>e.textContent?.trim()===i);return a&&L(this.#n)(a),a}resetTypeahead(){this.#t.current=``}get search(){return this.#t.current}},Bw=class{#e;#t;#n;#r=j(null);constructor(e){this.#e=e,this.#t=A(()=>this.#e.enabled()),this.#n=Rw(!1,{afterMs:e.transitTimeout??300,onChange:e=>{L(this.#t)&&this.#e.setIsPointerInTransit?.(e)},getWindow:()=>xS(this.#e.triggerNode())}),Yx([e.triggerNode,e.contentNode,e.enabled],([e,t,n])=>!e||!t||!n?void 0:Nx(ri(e,`pointerleave`,e=>{this.#a(e,t)}),ri(t,`pointerleave`,t=>{this.#a(t,e)}))),Yx(()=>L(this.#r),()=>{let t=t=>{if(!L(this.#r))return;let n=t.target;if(!nC(n))return;let r={x:t.clientX,y:t.clientY},i=e.triggerNode()?.contains(n)||e.contentNode()?.contains(n),a=!Ww(r,L(this.#r));i?this.#i():a&&(this.#i(),e.onPointerExit())},n=bS(e.triggerNode()??e.contentNode());if(n)return ri(n,`pointermove`,t)})}#i(){M(this.#r,null),this.#n.current=!1}#a(e,t){let n=e.currentTarget;if(!tC(n))return;let r={x:e.clientX,y:e.clientY},i=Hw(r,Vw(r,n.getBoundingClientRect())),a=Uw(t.getBoundingClientRect()),o=Gw([...i,...a]);M(this.#r,o,!0),this.#n.current=!0}};function Vw(e,t){let n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),i=Math.abs(t.right-e.x),a=Math.abs(t.left-e.x);switch(Math.min(n,r,i,a)){case a:return`left`;case i:return`right`;case n:return`top`;case r:return`bottom`;default:throw Error(`unreachable`)}}function Hw(e,t,n=5){let r=n*1.5;switch(t){case`top`:return[{x:e.x-n,y:e.y+n},{x:e.x,y:e.y-r},{x:e.x+n,y:e.y+n}];case`bottom`:return[{x:e.x-n,y:e.y-n},{x:e.x,y:e.y+r},{x:e.x+n,y:e.y-n}];case`left`:return[{x:e.x+n,y:e.y-n},{x:e.x-r,y:e.y},{x:e.x+n,y:e.y+n}];case`right`:return[{x:e.x-n,y:e.y-n},{x:e.x+r,y:e.y},{x:e.x-n,y:e.y+n}]}}function Uw(e){let{top:t,right:n,bottom:r,left:i}=e;return[{x:i,y:t},{x:n,y:t},{x:n,y:r},{x:i,y:r}]}function Ww(e,t){let{x:n,y:r}=e,i=!1;for(let e=0,a=t.length-1;e<t.length;a=e++){let o=t[e].x,s=t[e].y,c=t[a].x,l=t[a].y;s>r!=l>r&&n<(c-o)*(r-s)/(l-s)+o&&(i=!i)}return i}function Gw(e){let t=e.slice();return t.sort((e,t)=>e.x<t.x?-1:e.x>t.x?1:e.y<t.y?-1:e.y>t.y?1:0),Kw(t)}function Kw(e){if(e.length<=1)return e.slice();let t=[];for(let n=0;n<e.length;n++){let r=e[n];for(;t.length>=2;){let e=t[t.length-1],n=t[t.length-2];if((e.x-n.x)*(r.y-n.y)>=(e.y-n.y)*(r.x-n.x))t.pop();else break}t.push(r)}t.pop();let n=[];for(let t=e.length-1;t>=0;t--){let r=e[t];for(;n.length>=2;){let e=n[n.length-1],t=n[n.length-2];if((e.x-t.x)*(r.y-t.y)>=(e.y-t.y)*(r.x-t.x))n.pop();else break}n.push(r)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}var qw=`data-context-menu-trigger`,Jw=`data-context-menu-content`,Yw=new Gx(`Menu.Root`),Xw=new Gx(`Menu.Root | Menu.Sub`),Zw=new Gx(`Menu.Content`),Qw=new Gx(`Menu.Group | Menu.RadioGroup`),$w=new Gx(`Menu.RadioGroup`),eT=new Gx(`Menu.CheckboxGroup`),tT=new AC(`bitsmenuopen`,{bubbles:!1,cancelable:!0}),nT=MS({component:`menu`,parts:[`trigger`,`content`,`sub-trigger`,`item`,`group`,`group-heading`,`checkbox-group`,`checkbox-item`,`radio-group`,`radio-item`,`separator`,`sub-content`,`arrow`]}),rT=class e{static create(t){let n=new e(t);return Yw.set(n)}opts;isUsingKeyboard=new GC;#e=j(!1);get ignoreCloseAutoFocus(){return L(this.#e)}set ignoreCloseAutoFocus(e){M(this.#e,e,!0)}#t=j(!1);get isPointerInTransit(){return L(this.#t)}set isPointerInTransit(e){M(this.#t,e,!0)}constructor(e){this.opts=e}getBitsAttr=e=>nT.getAttr(e,this.opts.variant.current)},iT=class e{static create(t,n){return Xw.set(new e(t,n,null))}opts;root;parentMenu;contentId=Q(()=>``);#e=j(null);get contentNode(){return L(this.#e)}set contentNode(e){M(this.#e,e,!0)}contentPresence;#t=j(null);get triggerNode(){return L(this.#t)}set triggerNode(e){M(this.#t,e,!0)}constructor(e,t,n){this.opts=e,this.root=t,this.parentMenu=n,this.contentPresence=new lC({ref:Q(()=>this.contentNode),open:this.opts.open,onComplete:()=>{this.opts.onOpenChangeComplete.current(this.opts.open.current)}}),n&&Yx(()=>n.opts.open.current,()=>{n.opts.open.current||(this.opts.open.current=!1)})}toggleOpen(){this.opts.open.current=!this.opts.open.current}onOpen(){this.opts.open.current=!0}onClose(){this.opts.open.current=!1}},aT=class e{static create(t){return Zw.set(new e(t,Xw.get()))}opts;parentMenu;rovingFocusGroup;domContext;attachment;#e=j(``);get search(){return L(this.#e)}set search(e){M(this.#e,e,!0)}#t=0;#n;#r=j(!1);get mounted(){return L(this.#r)}set mounted(e){M(this.#r,e,!0)}#i;constructor(e,t){this.opts=e,this.parentMenu=t,this.domContext=new CS(e.ref),this.attachment=wS(this.opts.ref,e=>{this.parentMenu.contentNode!==e&&(this.parentMenu.contentNode=e)}),t.contentId=e.id,this.#i=e.isSub??!1,this.onkeydown=this.onkeydown.bind(this),this.onblur=this.onblur.bind(this),this.onfocus=this.onfocus.bind(this),this.handleInteractOutside=this.handleInteractOutside.bind(this),new Bw({contentNode:()=>this.parentMenu.contentNode,triggerNode:()=>this.parentMenu.triggerNode,enabled:()=>this.parentMenu.opts.open.current&&!!this.parentMenu.triggerNode?.hasAttribute(this.parentMenu.root.getBitsAttr(`sub-trigger`)),onPointerExit:()=>{this.parentMenu.opts.open.current=!1},setIsPointerInTransit:e=>{this.parentMenu.root.isPointerInTransit=e}}),this.#n=new zw({getActiveElement:()=>this.domContext.getActiveElement(),getWindow:()=>this.domContext.getWindow()}).handleTypeaheadSearch,this.rovingFocusGroup=new sC({rootNode:Q(()=>this.parentMenu.contentNode),candidateAttr:this.parentMenu.root.getBitsAttr(`item`),loop:this.opts.loop,orientation:Q(()=>`vertical`)}),Yx(()=>this.parentMenu.contentNode,e=>e?tT.listen(e,()=>{uS(()=>{this.parentMenu.root.isUsingKeyboard.current&&this.rovingFocusGroup.focusFirstCandidate()})}):void 0),$n(()=>{this.parentMenu.opts.open.current||this.domContext.getWindow().clearTimeout(this.#t)})}#a(){let e=this.parentMenu.contentNode;return e?Array.from(e.querySelectorAll(`[${this.parentMenu.root.getBitsAttr(`item`)}]:not([data-disabled])`)):[]}#o(){return this.parentMenu.root.isPointerInTransit}onCloseAutoFocus=e=>{this.opts.onCloseAutoFocus.current?.(e),!(e.defaultPrevented||this.#i)&&this.parentMenu.triggerNode&&Sw(this.parentMenu.triggerNode)&&(e.preventDefault(),this.parentMenu.triggerNode.focus())};handleTabKeyDown(e){let t=this.parentMenu;for(;t.parentMenu!==null;)t=t.parentMenu;if(!t.triggerNode)return;e.preventDefault();let n=Ew(t.triggerNode,e.shiftKey?`prev`:`next`);n?(this.parentMenu.root.ignoreCloseAutoFocus=!0,t.onClose(),uS(()=>{n.focus(),uS(()=>{this.parentMenu.root.ignoreCloseAutoFocus=!1})})):this.domContext.getDocument().body.focus()}onkeydown(e){if(e.defaultPrevented)return;if(e.key===`Tab`){this.handleTabKeyDown(e);return}let t=e.target,n=e.currentTarget;if(!tC(t)||!tC(n))return;let r=t.closest(`[${this.parentMenu.root.getBitsAttr(`content`)}]`)?.id===this.parentMenu.contentId.current,i=e.ctrlKey||e.altKey||e.metaKey,a=e.key.length===1;if(this.rovingFocusGroup.handleKeydown(t,e)||e.code===`Space`)return;let o=this.#a();r&&!i&&a&&this.#n(e.key,o),e.target?.id===this.parentMenu.contentId.current&&RC.includes(e.key)&&(e.preventDefault(),LC.includes(e.key)&&o.reverse(),UC(o,{select:!1},()=>this.domContext.getActiveElement()))}onblur(e){nC(e.currentTarget)&&nC(e.target)&&(e.currentTarget.contains?.(e.target)||(this.domContext.getWindow().clearTimeout(this.#t),this.search=``))}onfocus(e){this.parentMenu.root.isUsingKeyboard.current&&uS(()=>this.rovingFocusGroup.focusFirstCandidate())}onItemEnter(){return this.#o()}onItemLeave(e){e.currentTarget.hasAttribute(this.parentMenu.root.getBitsAttr(`sub-trigger`))||this.#o()||this.parentMenu.root.isUsingKeyboard.current||(this.parentMenu.contentNode?.focus(),this.rovingFocusGroup.setCurrentTabStopId(``))}onTriggerLeave(){return!!this.#o()}handleInteractOutside(e){if(!rC(e.target))return;let t=this.parentMenu.triggerNode?.id;if(e.target.id===t){e.preventDefault();return}e.target.closest(`#${t}`)&&e.preventDefault()}get shouldRender(){return this.parentMenu.contentPresence.shouldRender}#s=A(()=>({open:this.parentMenu.opts.open.current}));get snippetProps(){return L(this.#s)}set snippetProps(e){M(this.#s,e)}#c=A(()=>({id:this.opts.id.current,role:`menu`,"aria-orientation":`vertical`,[this.parentMenu.root.getBitsAttr(`content`)]:``,"data-state":kS(this.parentMenu.opts.open.current),onkeydown:this.onkeydown,onblur:this.onblur,onfocus:this.onfocus,dir:this.parentMenu.root.opts.dir.current,style:{pointerEvents:`auto`,contain:`layout style`},...this.attachment}));get props(){return L(this.#c)}set props(e){M(this.#c,e)}popperProps={onCloseAutoFocus:e=>this.onCloseAutoFocus(e)}},oT=class{opts;content;attachment;#e=j(!1);constructor(e,t){this.opts=e,this.content=t,this.attachment=wS(this.opts.ref),this.onpointermove=this.onpointermove.bind(this),this.onpointerleave=this.onpointerleave.bind(this),this.onfocus=this.onfocus.bind(this),this.onblur=this.onblur.bind(this)}onpointermove(e){if(!e.defaultPrevented&&VC(e))if(this.opts.disabled.current)this.content.onItemLeave(e);else{if(this.content.onItemEnter())return;let t=e.currentTarget;if(!tC(t))return;t.focus()}}onpointerleave(e){e.defaultPrevented||VC(e)&&this.content.onItemLeave(e)}onfocus(e){uS(()=>{e.defaultPrevented||this.opts.disabled.current||M(this.#e,!0)})}onblur(e){uS(()=>{e.defaultPrevented||M(this.#e,!1)})}#t=A(()=>({id:this.opts.id.current,tabindex:-1,role:`menuitem`,"aria-disabled":TS(this.opts.disabled.current),"data-disabled":DS(this.opts.disabled.current),"data-highlighted":L(this.#e)?``:void 0,[this.content.parentMenu.root.getBitsAttr(`item`)]:``,onpointermove:this.onpointermove,onpointerleave:this.onpointerleave,onfocus:this.onfocus,onblur:this.onblur,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},sT=class e{static create(t){return new e(t,new oT(t,Zw.get()))}opts;item;root;#e=!1;constructor(e,t){this.opts=e,this.item=t,this.root=t.content.parentMenu.root,this.onkeydown=this.onkeydown.bind(this),this.onclick=this.onclick.bind(this),this.onpointerdown=this.onpointerdown.bind(this),this.onpointerup=this.onpointerup.bind(this)}#t(){if(this.item.opts.disabled.current)return;let e=new CustomEvent(`menuitemselect`,{bubbles:!0,cancelable:!0});if(this.opts.onSelect.current(e),e.defaultPrevented){this.item.content.parentMenu.root.isUsingKeyboard.current=!1;return}this.opts.closeOnSelect.current&&this.item.content.parentMenu.root.opts.onClose()}onkeydown(e){let t=this.item.content.search!==``;if(!(this.item.opts.disabled.current||t&&e.key===` `)&&FC.includes(e.key)){if(!tC(e.currentTarget))return;e.currentTarget.click(),e.preventDefault()}}onclick(e){this.item.opts.disabled.current||this.#t()}onpointerup(e){if(!e.defaultPrevented&&!this.#e){if(!tC(e.currentTarget))return;e.currentTarget?.click()}}onpointerdown(e){this.#e=!0}#n=A(()=>Bx(this.item.props,{onclick:this.onclick,onpointerdown:this.onpointerdown,onpointerup:this.onpointerup,onkeydown:this.onkeydown}));get props(){return L(this.#n)}set props(e){M(this.#n,e)}},cT=class e{static create(t,n){return new e(t,new sT(t,new oT(t,Zw.get())),n)}opts;item;group;constructor(e,t,n=null){this.opts=e,this.item=t,this.group=n,this.group&&(Yx(()=>this.group.opts.value.current,e=>{this.opts.checked.current=e.includes(this.opts.value.current)}),Yx(()=>this.opts.checked.current,e=>{e?this.group.addValue(this.opts.value.current):this.group.removeValue(this.opts.value.current)}))}toggleChecked(){this.opts.indeterminate.current?(this.opts.indeterminate.current=!1,this.opts.checked.current=!0):this.opts.checked.current=!this.opts.checked.current}#e=A(()=>({checked:this.opts.checked.current,indeterminate:this.opts.indeterminate.current}));get snippetProps(){return L(this.#e)}set snippetProps(e){M(this.#e,e)}#t=A(()=>({...this.item.props,role:`menuitemcheckbox`,"aria-checked":AS(this.opts.checked.current,this.opts.indeterminate.current),"data-state":BC(this.opts.checked.current),[this.item.root.getBitsAttr(`checkbox-item`)]:``}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},lT=class e{static create(t){return Qw.set(new e(t,Yw.get()))}opts;root;attachment;#e=j(void 0);get groupHeadingId(){return L(this.#e)}set groupHeadingId(e){M(this.#e,e,!0)}constructor(e,t){this.opts=e,this.root=t,this.attachment=wS(this.opts.ref)}#t=A(()=>({id:this.opts.id.current,role:`group`,"aria-labelledby":this.groupHeadingId,[this.root.getBitsAttr(`group`)]:``,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},uT=class e{static create(t){let n=eT.getOr(null);if(n)return new e(t,n);let r=$w.getOr(null);return r?new e(t,r):new e(t,Qw.get())}opts;group;attachment;constructor(e,t){this.opts=e,this.group=t,this.attachment=wS(this.opts.ref,e=>this.group.groupHeadingId=e?.id)}#e=A(()=>({id:this.opts.id.current,role:`group`,[this.group.root.getBitsAttr(`group-heading`)]:``,...this.attachment}));get props(){return L(this.#e)}set props(e){M(this.#e,e)}},dT=class e{static create(t){return new e(t,Yw.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=wS(this.opts.ref)}#e=A(()=>({id:this.opts.id.current,role:`group`,[this.root.getBitsAttr(`separator`)]:``,...this.attachment}));get props(){return L(this.#e)}set props(e){M(this.#e,e)}},fT=class e{static create(t){return Qw.set($w.set(new e(t,Zw.get())))}opts;content;attachment;#e=j(null);get groupHeadingId(){return L(this.#e)}set groupHeadingId(e){M(this.#e,e,!0)}root;constructor(e,t){this.opts=e,this.content=t,this.root=t.parentMenu.root,this.attachment=wS(this.opts.ref)}setValue(e){this.opts.value.current=e}#t=A(()=>({id:this.opts.id.current,[this.root.getBitsAttr(`radio-group`)]:``,role:`group`,"aria-labelledby":this.groupHeadingId,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},pT=class e{static create(t){let n=$w.get();return new e(t,new sT(t,new oT(t,n.content)),n)}opts;item;group;attachment;#e=A(()=>this.group.opts.value.current===this.opts.value.current);get isChecked(){return L(this.#e)}set isChecked(e){M(this.#e,e)}constructor(e,t,n){this.opts=e,this.item=t,this.group=n,this.attachment=wS(this.opts.ref)}selectValue(){this.group.setValue(this.opts.value.current)}#t=A(()=>({[this.group.root.getBitsAttr(`radio-item`)]:``,...this.item.props,role:`menuitemradio`,"aria-checked":AS(this.isChecked,!1),"data-state":BC(this.isChecked),...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},mT=class e{static create(t){return new e(t,Xw.get())}opts;parentMenu;attachment;constructor(e,t){this.opts=e,this.parentMenu=t,this.attachment=wS(this.opts.ref,e=>this.parentMenu.triggerNode=e)}onclick=e=>{this.opts.disabled.current||e.detail!==0||(this.parentMenu.toggleOpen(),e.preventDefault())};onpointerdown=e=>{if(!this.opts.disabled.current){if(e.pointerType===`touch`)return e.preventDefault();e.button===0&&e.ctrlKey===!1&&(this.parentMenu.toggleOpen(),this.parentMenu.opts.open.current||e.preventDefault())}};onpointerup=e=>{this.opts.disabled.current||e.pointerType===`touch`&&(e.preventDefault(),this.parentMenu.toggleOpen())};onkeydown=e=>{if(!this.opts.disabled.current){if(e.key===` `||e.key===`Enter`){this.parentMenu.toggleOpen(),e.preventDefault();return}e.key===`ArrowDown`&&(this.parentMenu.onOpen(),e.preventDefault())}};#e=A(()=>{if(this.parentMenu.opts.open.current&&this.parentMenu.contentId.current)return this.parentMenu.contentId.current});#t=A(()=>({id:this.opts.id.current,disabled:this.opts.disabled.current,"aria-haspopup":`menu`,"aria-expanded":TS(this.parentMenu.opts.open.current),"aria-controls":L(this.#e),"data-disabled":DS(this.opts.disabled.current),"data-state":kS(this.parentMenu.opts.open.current),[this.parentMenu.root.getBitsAttr(`trigger`)]:``,onclick:this.onclick,onpointerdown:this.onpointerdown,onpointerup:this.onpointerup,onkeydown:this.onkeydown,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},hT=class e{static create(t){return eT.set(new e(t,Zw.get()))}opts;content;root;attachment;#e=j(null);get groupHeadingId(){return L(this.#e)}set groupHeadingId(e){M(this.#e,e,!0)}constructor(e,t){this.opts=e,this.content=t,this.root=t.parentMenu.root,this.attachment=wS(this.opts.ref)}addValue(e){if(e&&!this.opts.value.current.includes(e)){let t=[...st(this.opts.value.current),e];if(this.opts.value.current=t,Ow(this.opts.value.current,t))return;this.opts.onValueChange.current(t)}}removeValue(e){if(!e||this.opts.value.current.indexOf(e)===-1)return;let t=this.opts.value.current.filter(t=>t!==e);this.opts.value.current=t,!Ow(this.opts.value.current,t)&&this.opts.onValueChange.current(t)}#t=A(()=>({id:this.opts.id.current,[this.root.getBitsAttr(`checkbox-group`)]:``,role:`group`,"aria-labelledby":this.groupHeadingId,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}};globalThis.bitsDismissableLayers??=new Map;var gT=class e{static create(t){return new e(t)}opts;#e;#t;#n={pointerdown:!1};#r=!1;#i=!1;#a=void 0;#o;#s=$;constructor(e){this.opts=e,this.#t=e.interactOutsideBehavior,this.#e=e.onInteractOutside,this.#o=e.onFocusOutside,$n(()=>{this.#a=NC(this.opts.ref.current)});let t=$,n=()=>{this.#g(),globalThis.bitsDismissableLayers.delete(this),this.#d.destroy(),t()};Yx([()=>this.opts.enabled.current,()=>this.opts.ref.current],()=>{if(!(!this.opts.enabled.current||!this.opts.ref.current))return lS(1,()=>{this.opts.ref.current&&(globalThis.bitsDismissableLayers.set(this,this.#t),t(),t=this.#l())}),n}),sS(()=>{this.#g.destroy(),globalThis.bitsDismissableLayers.delete(this),this.#d.destroy(),this.#s(),t()})}#c=e=>{e.defaultPrevented||this.opts.ref.current&&uS(()=>{!this.opts.ref.current||this.#h(e.target)||e.target&&!this.#i&&this.#o.current?.(e)})};#l(){return Nx(ri(this.#a,`pointerdown`,Nx(this.#f,this.#m),{capture:!0}),ri(this.#a,`pointerdown`,Nx(this.#p,this.#d)),ri(this.#a,`focusin`,this.#c))}#u=e=>{let t=e;t.defaultPrevented&&(t=bT(e)),this.#e.current(e)};#d=jC(e=>{if(!this.opts.ref.current){this.#s();return}let t=this.opts.isValidEvent.current(e,this.opts.ref.current)||yT(e,this.opts.ref.current);if(!this.#r||this.#_()||!t){this.#s();return}let n=e;if(n.defaultPrevented&&(n=bT(n)),this.#t.current!==`close`&&this.#t.current!==`defer-otherwise-close`){this.#s();return}e.pointerType===`touch`?(this.#s(),this.#s=ri(this.#a,`click`,this.#u,{once:!0})):this.#e.current(n)},10);#f=e=>{this.#n[e.type]=!0};#p=e=>{this.#n[e.type]=!1};#m=()=>{this.opts.ref.current&&(this.#r=vT(this.opts.ref.current))};#h=e=>this.opts.ref.current?MC(this.opts.ref.current,e):!1;#g=jC(()=>{for(let e in this.#n)this.#n[e]=!1;this.#r=!1},20);#_(){return Object.values(this.#n).some(Boolean)}#v=()=>{this.#i=!0};#y=()=>{this.#i=!1};props={onfocuscapture:this.#v,onblurcapture:this.#y}};function _T(e=[...globalThis.bitsDismissableLayers]){return e.findLast(([e,{current:t}])=>t===`close`||t===`ignore`)}function vT(e){let t=[...globalThis.bitsDismissableLayers],n=_T(t);if(n)return n[0].opts.ref.current===e;let[r]=t[0];return r.opts.ref.current===e}function yT(e,t){let n=e.target;if(!rC(n))return!1;let r=!!n.closest(`[${qw}]`);if(`button`in e&&e.button>0&&!r)return!1;if(`button`in e&&e.button===0&&r)return!0;let i=!!t.closest(`[${Jw}]`);return r&&i?!1:NC(n).documentElement.contains(n)&&!MC(t,n)&&PC(e,t)}function bT(e){let t=e.currentTarget,n=e.target,r;r=e instanceof PointerEvent?new PointerEvent(e.type,e):new PointerEvent(`pointerdown`,e);let i=!1;return new Proxy(r,{get:(r,a)=>a===`currentTarget`?t:a===`target`?n:a===`preventDefault`?()=>{i=!0,typeof r.preventDefault==`function`&&r.preventDefault()}:a===`defaultPrevented`?i:a in r?r[a]:e[a]})}function xT(e,t){D(t,!0);let n=K(t,`interactOutsideBehavior`,7,`close`),r=K(t,`onInteractOutside`,7,$),i=K(t,`onFocusOutside`,7,$),a=K(t,`id`,7),o=K(t,`children`,7),s=K(t,`enabled`,7),c=K(t,`isValidEvent`,7,()=>!1),l=K(t,`ref`,7),u=gT.create({id:Q(()=>a()),interactOutsideBehavior:Q(()=>n()),onInteractOutside:Q(()=>r()),enabled:Q(()=>s()),onFocusOutside:Q(()=>i()),isValidEvent:Q(()=>c()),ref:l()});var d={get interactOutsideBehavior(){return n()},set interactOutsideBehavior(e=`close`){n(e),k()},get onInteractOutside(){return r()},set onInteractOutside(e=$){r(e),k()},get onFocusOutside(){return i()},set onFocusOutside(e=$){i(e),k()},get id(){return a()},set id(e){a(e),k()},get children(){return o()},set children(e){o(e),k()},get enabled(){return s()},set enabled(e){s(e),k()},get isValidEvent(){return c()},set isValidEvent(e=()=>!1){c(e),k()},get ref(){return l()},set ref(e){l(e),k()}},f=z();return H(P(f),()=>o()??w,()=>({props:u.props})),B(e,f),O(d)}q(xT,{interactOutsideBehavior:{},onInteractOutside:{},onFocusOutside:{},id:{},children:{},enabled:{},isValidEvent:{},ref:{}},[],[],{mode:`open`}),globalThis.bitsEscapeLayers??=new Map;var ST=class e{static create(t){return new e(t)}opts;domContext;constructor(e){this.opts=e,this.domContext=new CS(this.opts.ref);let t=$;Yx(()=>e.enabled.current,n=>(n&&(globalThis.bitsEscapeLayers.set(this,e.escapeKeydownBehavior),t=this.#e()),()=>{t(),globalThis.bitsEscapeLayers.delete(this)}))}#e=()=>ri(this.domContext.getDocument(),`keydown`,this.#t,{passive:!1});#t=e=>{if(e.key!==`Escape`||!CT(this))return;let t=new KeyboardEvent(e.type,e);e.preventDefault();let n=this.opts.escapeKeydownBehavior.current;n!==`close`&&n!==`defer-otherwise-close`||this.opts.onEscapeKeydown.current(t)}};function CT(e){let t=[...globalThis.bitsEscapeLayers],n=t.findLast(([e,{current:t}])=>t===`close`||t===`ignore`);if(n)return n[0]===e;let[r]=t[0];return r===e}function wT(e,t){D(t,!0);let n=K(t,`escapeKeydownBehavior`,7,`close`),r=K(t,`onEscapeKeydown`,7,$),i=K(t,`children`,7),a=K(t,`enabled`,7),o=K(t,`ref`,7);ST.create({escapeKeydownBehavior:Q(()=>n()),onEscapeKeydown:Q(()=>r()),enabled:Q(()=>a()),ref:o()});var s={get escapeKeydownBehavior(){return n()},set escapeKeydownBehavior(e=`close`){n(e),k()},get onEscapeKeydown(){return r()},set onEscapeKeydown(e=$){r(e),k()},get children(){return i()},set children(e){i(e),k()},get enabled(){return a()},set enabled(e){a(e),k()},get ref(){return o()},set ref(e){o(e),k()}},c=z();return H(P(c),()=>i()??w),B(e,c),O(s)}q(wT,{escapeKeydownBehavior:{},onEscapeKeydown:{},children:{},enabled:{},ref:{}},[],[],{mode:`open`});var TT=class e{static instance;#e=ix([]);#t=new WeakMap;#n=new WeakMap;static getInstance(){return this.instance||=new e,this.instance}register(e){let t=this.getActive();t&&t!==e&&t.pause();let n=document.activeElement;n&&n!==document.body&&this.#n.set(e,n),this.#e.current=this.#e.current.filter(t=>t!==e),this.#e.current.unshift(e)}unregister(e){this.#e.current=this.#e.current.filter(t=>t!==e);let t=this.getActive();t&&t.resume()}getActive(){return this.#e.current[0]}setFocusMemory(e,t){this.#t.set(e,t)}getFocusMemory(e){return this.#t.get(e)}isActiveScope(e){return this.getActive()===e}setPreFocusMemory(e,t){this.#n.set(e,t)}getPreFocusMemory(e){return this.#n.get(e)}clearPreFocusMemory(e){this.#n.delete(e)}},ET=class e{#e=!1;#t=null;#n=TT.getInstance();#r=[];#i;constructor(e){this.#i=e}get paused(){return this.#e}pause(){this.#e=!0}resume(){this.#e=!1}#a(){for(let e of this.#r)e();this.#r=[]}mount(e){this.#t&&this.unmount(),this.#t=e,this.#n.register(this),this.#c(),this.#o()}unmount(){this.#t&&=(this.#a(),this.#s(),this.#n.unregister(this),this.#n.clearPreFocusMemory(this),null)}#o(){if(!this.#t)return;let e=new CustomEvent(`focusScope.onOpenAutoFocus`,{bubbles:!1,cancelable:!0});this.#i.onOpenAutoFocus.current(e),e.defaultPrevented||requestAnimationFrame(()=>{if(!this.#t)return;let e=this.#u();e?(e.focus(),this.#n.setFocusMemory(this,e)):this.#t.focus()})}#s(){let e=new CustomEvent(`focusScope.onCloseAutoFocus`,{bubbles:!1,cancelable:!0});if(this.#i.onCloseAutoFocus.current?.(e),!e.defaultPrevented){let e=this.#n.getPreFocusMemory(this);if(e&&document.contains(e))try{e.focus()}catch{document.body.focus()}}}#c(){if(!this.#t||!this.#i.trap.current)return;let e=this.#t,t=e.ownerDocument;this.#r.push(ri(t,`focusin`,t=>{if(this.#e||!this.#n.isActiveScope(this))return;let n=t.target;if(n)if(e.contains(n))this.#n.setFocusMemory(this,n);else{let n=this.#n.getFocusMemory(this);if(n&&e.contains(n)&&ww(n))t.preventDefault(),n.focus();else{let t=this.#u(),n=this.#d()[0];(t||n||e).focus()}}},{capture:!0}),ri(e,`keydown`,e=>{if(!this.#i.loop||this.#e||e.key!==`Tab`||!this.#n.isActiveScope(this))return;let n=this.#l();if(n.length===0)return;let r=n[0],i=n[n.length-1];!e.shiftKey&&t.activeElement===i?(e.preventDefault(),r.focus()):e.shiftKey&&t.activeElement===r&&(e.preventDefault(),i.focus())}));let n=new MutationObserver(()=>{let t=this.#n.getFocusMemory(this);if(t&&!e.contains(t)){let t=this.#u(),n=this.#d()[0],r=t||n;r?(r.focus(),this.#n.setFocusMemory(this,r)):e.focus()}});n.observe(e,{childList:!0,subtree:!0}),this.#r.push(()=>n.disconnect())}#l(){return this.#t?bw(this.#t,{includeContainer:!1,getShadowRoot:!0}):[]}#u(){return this.#l()[0]||null}#d(){return this.#t?xw(this.#t,{includeContainer:!1,getShadowRoot:!0}):[]}static use(t){let n=null;return Yx([()=>t.ref.current,()=>t.enabled.current],([r,i])=>{r&&i?(n||=new e(t),n.mount(r)):n&&=(n.unmount(),null)}),sS(()=>{n?.unmount()}),{get props(){return{tabindex:-1}}}}};function DT(e,t){D(t,!0);let n=K(t,`enabled`,7,!1),r=K(t,`trapFocus`,7,!1),i=K(t,`loop`,7,!1),a=K(t,`onCloseAutoFocus`,7,$),o=K(t,`onOpenAutoFocus`,7,$),s=K(t,`focusScope`,7),c=K(t,`ref`,7),l=ET.use({enabled:Q(()=>n()),trap:Q(()=>r()),loop:i(),onCloseAutoFocus:Q(()=>a()),onOpenAutoFocus:Q(()=>o()),ref:c()});var u={get enabled(){return n()},set enabled(e=!1){n(e),k()},get trapFocus(){return r()},set trapFocus(e=!1){r(e),k()},get loop(){return i()},set loop(e=!1){i(e),k()},get onCloseAutoFocus(){return a()},set onCloseAutoFocus(e=$){a(e),k()},get onOpenAutoFocus(){return o()},set onOpenAutoFocus(e=$){o(e),k()},get focusScope(){return s()},set focusScope(e){s(e),k()},get ref(){return c()},set ref(e){c(e),k()}},d=z();return H(P(d),()=>s()??w,()=>({props:l.props})),B(e,d),O(u)}q(DT,{enabled:{},trapFocus:{},loop:{},onCloseAutoFocus:{},onOpenAutoFocus:{},focusScope:{},ref:{}},[],[],{mode:`open`}),globalThis.bitsTextSelectionLayers??=new Map;var OT=class e{static create(t){return new e(t)}opts;domContext;#e=$;constructor(e){this.opts=e,this.domContext=new CS(e.ref);let t=$;Yx(()=>this.opts.enabled.current,e=>(e&&(globalThis.bitsTextSelectionLayers.set(this,this.opts.enabled),t(),t=this.#t()),()=>{t(),this.#r(),globalThis.bitsTextSelectionLayers.delete(this)}))}#t(){return Nx(ri(this.domContext.getDocument(),`pointerdown`,this.#n),ri(this.domContext.getDocument(),`pointerup`,ox(this.#r,this.opts.onPointerUp.current)))}#n=e=>{let t=this.opts.ref.current,n=e.target;!tC(t)||!tC(n)||!this.opts.enabled.current||!MT(this)||!yS(t,n)||(this.opts.onPointerDown.current(e),!e.defaultPrevented&&(this.#e=AT(t,this.domContext.getDocument().body)))};#r=()=>{this.#e(),this.#e=$}},kT=e=>e.style.userSelect||e.style.webkitUserSelect;function AT(e,t){let n=kT(t),r=kT(e);return jT(t,`none`),jT(e,`text`),()=>{jT(t,n),jT(e,r)}}function jT(e,t){e.style.userSelect=t,e.style.webkitUserSelect=t}function MT(e){let t=[...globalThis.bitsTextSelectionLayers];if(!t.length)return!1;let n=t.at(-1);return n?n[0]===e:!1}function NT(e,t){D(t,!0);let n=K(t,`preventOverflowTextSelection`,7,!0),r=K(t,`onPointerDown`,7,$),i=K(t,`onPointerUp`,7,$),a=K(t,`id`,7),o=K(t,`children`,7),s=K(t,`enabled`,7),c=K(t,`ref`,7);OT.create({id:Q(()=>a()),onPointerDown:Q(()=>r()),onPointerUp:Q(()=>i()),enabled:Q(()=>s()&&n()),ref:c()});var l={get preventOverflowTextSelection(){return n()},set preventOverflowTextSelection(e=!0){n(e),k()},get onPointerDown(){return r()},set onPointerDown(e=$){r(e),k()},get onPointerUp(){return i()},set onPointerUp(e=$){i(e),k()},get id(){return a()},set id(e){a(e),k()},get children(){return o()},set children(e){o(e),k()},get enabled(){return s()},set enabled(e){s(e),k()},get ref(){return c()},set ref(e){c(e),k()}},u=z();return H(P(u),()=>o()??w),B(e,u),O(l)}q(NT,{preventOverflowTextSelection:{},onPointerDown:{},onPointerUp:{},id:{},children:{},enabled:{},ref:{}},[],[],{mode:`open`}),globalThis.bitsIdCounter??={current:0};function PT(e=`bits`){return globalThis.bitsIdCounter.current++,`${e}-${globalThis.bitsIdCounter.current}`}var FT=class{#e;#t=0;#n=j();#r;constructor(e){this.#e=e}#i(){--this.#t,this.#r&&this.#t<=0&&(this.#r(),M(this.#n,void 0),this.#r=void 0)}get(...e){return this.#t+=1,L(this.#n)===void 0&&(this.#r=nr(()=>{M(this.#n,this.#e(...e),!0)})),$n(()=>()=>{this.#i()}),L(this.#n)}},IT=new iv,LT=j(null),RT=null,zT=null,BT=!1,VT=Q(()=>{for(let e of IT.values())if(e)return!0;return!1}),HT=null,UT=new FT(()=>{function e(){document.body.setAttribute(`style`,L(LT)??``),document.body.style.removeProperty(`--scrollbar-width`),$S&&RT?.(),M(LT,null)}function t(){zT!==null&&(window.clearTimeout(zT),zT=null)}function n(e,n){t(),BT=!0,HT=Date.now();let r=HT,i=()=>{zT=null,HT===r&&(GT(IT)?BT=!1:(BT=!1,n()))},a=e===null?24:e;zT=window.setTimeout(i,a)}function r(){L(LT)===null&&IT.size===0&&!BT&&M(LT,document.body.getAttribute(`style`),!0)}return Yx(()=>VT.current,()=>{if(!VT.current)return;r(),BT=!1;let e=getComputedStyle(document.documentElement),t=getComputedStyle(document.body),n=e.scrollbarGutter?.includes(`stable`)||t.scrollbarGutter?.includes(`stable`),i=window.innerWidth-document.documentElement.clientWidth,a={padding:Number.parseInt(t.paddingRight??`0`,10)+i,margin:Number.parseInt(t.marginRight??`0`,10)};i>0&&!n&&(document.body.style.paddingRight=`${a.padding}px`,document.body.style.marginRight=`${a.margin}px`,document.body.style.setProperty(`--scrollbar-width`,`${i}px`)),document.body.style.overflow=`hidden`,$S&&(RT=ri(document,`touchmove`,e=>{e.target===document.documentElement&&(e.touches.length>1||e.preventDefault())},{passive:!1})),uS(()=>{document.body.style.pointerEvents=`none`,document.body.style.overflow=`hidden`})}),sS(()=>()=>{RT?.()}),{get lockMap(){return IT},resetBodyStyle:e,scheduleCleanupIfNoNewLocks:n,cancelPendingCleanup:t,ensureInitialStyleCaptured:r}}),WT=class{#e=PT();#t;#n=()=>null;#r;locked;constructor(e,t=()=>null){this.#t=e,this.#n=t,this.#r=UT.get(),this.#r&&(this.#r.cancelPendingCleanup(),this.#r.ensureInitialStyleCaptured(),this.#r.lockMap.set(this.#e,this.#t??!1),this.locked=Q(()=>this.#r.lockMap.get(this.#e)??!1,e=>this.#r.lockMap.set(this.#e,e)),sS(()=>{if(this.#r.lockMap.delete(this.#e),GT(this.#r.lockMap))return;let e=this.#n();this.#r.scheduleCleanupIfNoNewLocks(e,()=>{this.#r.resetBodyStyle()})}))}};function GT(e){for(let[t,n]of e)if(n)return!0;return!1}function KT(e,t){D(t,!0);let n=K(t,`preventScroll`,7,!0),r=K(t,`restoreScrollDelay`,7,null);return n()&&new WT(n(),()=>r()),O({get preventScroll(){return n()},set preventScroll(e=!0){n(e),k()},get restoreScrollDelay(){return r()},set restoreScrollDelay(e=null){r(e),k()}})}q(KT,{preventScroll:{},restoreScrollDelay:{}},[],[],{mode:`open`});var qT=R(`<div><!></div>`);function JT(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>uC(n)),i=K(t,`forceMount`,7,!1),a=K(t,`child`,7),o=K(t,`children`,7),s=K(t,`ref`,15,null),c=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`forceMount`,`child`,`children`,`ref`]),l=vC.create({id:Q(()=>r()),ref:Q(()=>s(),e=>s(e))}),u=A(()=>Bx(c,l.props));var d={get id(){return r()},set id(e=uC(n)){r(e),k()},get forceMount(){return i()},set forceMount(e=!1){i(e),k()},get child(){return a()},set child(e){a(e),k()},get children(){return o()},set children(e){o(e),k()},get ref(){return s()},set ref(e=null){s(e),k()}},f=z(),p=P(f),m=e=>{var t=z(),n=P(t),r=e=>{var t=z(),n=P(t);{let e=A(()=>({props:Bx(L(u)),...l.snippetProps}));H(n,a,()=>L(e))}B(e,t)},i=e=>{var t=qT();Ja(t,e=>({...e}),[()=>Bx(L(u))]),H(N(t),()=>o()??w,()=>l.snippetProps),E(t),B(e,t)};U(n,e=>{a()?e(r):e(i,-1)}),B(e,t)};return U(p,e=>{(l.shouldRender||i())&&e(m)}),B(e,f),O(d)}q(JT,{id:{},forceMount:{},child:{},children:{},ref:{}},[],[],{mode:`open`});var YT=R(`<div><!></div>`);function XT(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>uC(n)),i=K(t,`children`,7),a=K(t,`child`,7),o=K(t,`ref`,15,null),s=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`children`,`child`,`ref`]),c=gC.create({id:Q(()=>r()),ref:Q(()=>o(),e=>o(e))}),l=A(()=>Bx(s,c.props));var u={get id(){return r()},set id(e=uC(n)){r(e),k()},get children(){return i()},set children(e){i(e),k()},get child(){return a()},set child(e){a(e),k()},get ref(){return o()},set ref(e=null){o(e),k()}},d=z(),f=P(d),p=e=>{var t=z();H(P(t),a,()=>({props:L(l)})),B(e,t)},m=e=>{var t=YT();Ja(t,()=>({...L(l)})),H(N(t),()=>i()??w),E(t),B(e,t)};return U(f,e=>{a()?e(p):e(m,-1)}),B(e,d),O(u)}q(XT,{id:{},children:{},child:{},ref:{}},[],[],{mode:`open`});function ZT(e,t){D(t,!0);let n=K(t,`children`,7),r=K(t,`defaultPortalTo`,7),i=K(t,`defaultLocale`,7);wC({defaultPortalTo:Q(()=>r()),defaultLocale:Q(()=>i())});var a={get children(){return n()},set children(e){n(e),k()},get defaultPortalTo(){return r()},set defaultPortalTo(e){r(e),k()},get defaultLocale(){return i()},set defaultLocale(e){i(e),k()}},o=z();return H(P(o),()=>n()??w),B(e,o),O(a)}q(ZT,{children:{},defaultPortalTo:{},defaultLocale:{}},[],[],{mode:`open`});var QT=R(`<input/>`),$T=R(`<input/>`);function eE(e,t){D(t,!0);let n=K(t,`value`,15),r=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`value`]),i=A(()=>Bx(r,{"aria-hidden":`true`,tabindex:-1,style:Vx}));var a={get value(){return n()},set value(e){n(e),k()}},o=z(),s=P(o),c=e=>{var t=QT();Ja(t,()=>({...L(i),value:n()}),void 0,void 0,void 0,void 0,!0),B(e,t)},l=e=>{var t=$T();Ja(t,()=>({...L(i)}),void 0,void 0,void 0,void 0,!0),Qa(t,n),B(e,t)};return U(s,e=>{L(i).type===`checkbox`?e(c):e(l,-1)}),B(e,o),O(a)}q(eE,{value:{}},[],[],{mode:`open`});var tE=MS({component:`collapsible`,parts:[`root`,`content`,`trigger`]}),nE=new Gx(`Collapsible.Root`),rE=class e{static create(t){return nE.set(new e(t))}opts;attachment;#e=j(null);get contentNode(){return L(this.#e)}set contentNode(e){M(this.#e,e,!0)}contentPresence;#t=j(void 0);get contentId(){return L(this.#t)}set contentId(e){M(this.#t,e,!0)}constructor(e){this.opts=e,this.toggleOpen=this.toggleOpen.bind(this),this.attachment=wS(this.opts.ref),this.contentPresence=new lC({ref:Q(()=>this.contentNode),open:this.opts.open,onComplete:()=>{this.opts.onOpenChangeComplete.current(this.opts.open.current)}})}toggleOpen(){this.opts.open.current=!this.opts.open.current}#n=A(()=>({id:this.opts.id.current,"data-state":kS(this.opts.open.current),"data-disabled":DS(this.opts.disabled.current),[tE.root]:``,...this.attachment}));get props(){return L(this.#n)}set props(e){M(this.#n,e)}},iE=class e{static create(t){return new e(t,nE.get())}opts;root;attachment;#e=A(()=>this.opts.hiddenUntilFound.current?this.root.opts.open.current:this.opts.forceMount.current||this.root.opts.open.current);get present(){return L(this.#e)}set present(e){M(this.#e,e)}#t;#n=j(!1);#r=j(0);#i=j(0);constructor(e,t){this.opts=e,this.root=t,M(this.#n,t.opts.open.current,!0),this.root.contentId=this.opts.id.current,this.attachment=wS(this.opts.ref,e=>this.root.contentNode=e),Yx.pre(()=>this.opts.id.current,e=>{this.root.contentId=e}),tr(()=>{let e=requestAnimationFrame(()=>{M(this.#n,!1)});return()=>{cancelAnimationFrame(e)}}),Yx.pre([()=>this.opts.ref.current,()=>this.opts.hiddenUntilFound.current],([e,t])=>!e||!t?void 0:ri(e,`beforematch`,()=>{this.root.opts.open.current||requestAnimationFrame(()=>{this.root.opts.open.current=!0})})),Yx([()=>this.opts.ref.current,()=>this.present],([e])=>{e&&uS(()=>{if(!this.opts.ref.current)return;this.#t=this.#t||{transitionDuration:e.style.transitionDuration,animationName:e.style.animationName},e.style.transitionDuration=`0s`,e.style.animationName=`none`;let t=e.getBoundingClientRect();if(M(this.#i,t.height,!0),M(this.#r,t.width,!0),!L(this.#n)){let{animationName:t,transitionDuration:n}=this.#t;e.style.transitionDuration=n,e.style.animationName=t}})})}get shouldRender(){return this.root.contentPresence.shouldRender}#a=A(()=>({open:this.root.opts.open.current}));get snippetProps(){return L(this.#a)}set snippetProps(e){M(this.#a,e)}#o=A(()=>({id:this.opts.id.current,style:{"--bits-collapsible-content-height":L(this.#i)?`${L(this.#i)}px`:void 0,"--bits-collapsible-content-width":L(this.#r)?`${L(this.#r)}px`:void 0},hidden:this.opts.hiddenUntilFound.current&&!this.root.opts.open.current?`until-found`:void 0,"data-state":kS(this.root.opts.open.current),"data-disabled":DS(this.root.opts.disabled.current),[tE.content]:``,...this.opts.hiddenUntilFound.current&&!this.shouldRender?{}:{hidden:this.opts.hiddenUntilFound.current?!this.shouldRender:this.opts.forceMount.current?void 0:!this.shouldRender},...this.attachment}));get props(){return L(this.#o)}set props(e){M(this.#o,e)}},aE=class e{static create(t){return new e(t,nE.get())}opts;root;attachment;#e=A(()=>this.opts.disabled.current||this.root.opts.disabled.current);constructor(e,t){this.opts=e,this.root=t,this.attachment=wS(this.opts.ref),this.onclick=this.onclick.bind(this),this.onkeydown=this.onkeydown.bind(this)}onclick(e){if(!L(this.#e)){if(e.button!==0)return e.preventDefault();this.root.toggleOpen()}}onkeydown(e){L(this.#e)||(e.key===` `||e.key===`Enter`)&&(e.preventDefault(),this.root.toggleOpen())}#t=A(()=>({id:this.opts.id.current,type:`button`,disabled:L(this.#e),"aria-controls":this.root.contentId,"aria-expanded":TS(this.root.opts.open.current),"data-state":kS(this.root.opts.open.current),"data-disabled":DS(L(this.#e)),[tE.trigger]:``,onclick:this.onclick,onkeydown:this.onkeydown,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},oE=R(`<div><!></div>`);function sE(e,t){let n=gi();D(t,!0);let r=K(t,`children`,7),i=K(t,`child`,7),a=K(t,`id`,23,()=>uC(n)),o=K(t,`ref`,15,null),s=K(t,`open`,15,!1),c=K(t,`disabled`,7,!1),l=K(t,`onOpenChange`,7,$),u=K(t,`onOpenChangeComplete`,7,$),d=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`children`,`child`,`id`,`ref`,`open`,`disabled`,`onOpenChange`,`onOpenChangeComplete`]),f=rE.create({open:Q(()=>s(),e=>{s(e),l()(e)}),disabled:Q(()=>c()),id:Q(()=>a()),ref:Q(()=>o(),e=>o(e)),onOpenChangeComplete:Q(()=>u())}),p=A(()=>Bx(d,f.props));var m={get children(){return r()},set children(e){r(e),k()},get child(){return i()},set child(e){i(e),k()},get id(){return a()},set id(e=uC(n)){a(e),k()},get ref(){return o()},set ref(e=null){o(e),k()},get open(){return s()},set open(e=!1){s(e),k()},get disabled(){return c()},set disabled(e=!1){c(e),k()},get onOpenChange(){return l()},set onOpenChange(e=$){l(e),k()},get onOpenChangeComplete(){return u()},set onOpenChangeComplete(e=$){u(e),k()}},h=z(),g=P(h),_=e=>{var t=z();H(P(t),i,()=>({props:L(p)})),B(e,t)},v=e=>{var t=oE();Ja(t,()=>({...L(p)})),H(N(t),()=>r()??w),E(t),B(e,t)};return U(g,e=>{i()?e(_):e(v,-1)}),B(e,h),O(m)}q(sE,{children:{},child:{},id:{},ref:{},open:{},disabled:{},onOpenChange:{},onOpenChangeComplete:{}},[],[],{mode:`open`});var cE=R(`<div><!></div>`);function lE(e,t){let n=gi();D(t,!0);let r=K(t,`child`,7),i=K(t,`ref`,15,null),a=K(t,`forceMount`,7,!1),o=K(t,`hiddenUntilFound`,7,!1),s=K(t,`children`,7),c=K(t,`id`,23,()=>uC(n)),l=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`child`,`ref`,`forceMount`,`hiddenUntilFound`,`children`,`id`]),u=iE.create({id:Q(()=>c()),forceMount:Q(()=>a()),hiddenUntilFound:Q(()=>o()),ref:Q(()=>i(),e=>i(e))}),d=A(()=>Bx(l,u.props));var f={get child(){return r()},set child(e){r(e),k()},get ref(){return i()},set ref(e=null){i(e),k()},get forceMount(){return a()},set forceMount(e=!1){a(e),k()},get hiddenUntilFound(){return o()},set hiddenUntilFound(e=!1){o(e),k()},get children(){return s()},set children(e){s(e),k()},get id(){return c()},set id(e=uC(n)){c(e),k()}},p=z(),m=P(p),h=e=>{var t=z(),n=P(t);{let e=A(()=>({...u.snippetProps,props:L(d)}));H(n,r,()=>L(e))}B(e,t)},g=e=>{var t=cE();Ja(t,()=>({...L(d)})),H(N(t),()=>s()??w),E(t),B(e,t)};return U(m,e=>{r()?e(h):e(g,-1)}),B(e,p),O(f)}q(lE,{child:{},ref:{},forceMount:{},hiddenUntilFound:{},children:{},id:{}},[],[],{mode:`open`});var uE=R(`<button><!></button>`);function dE(e,t){let n=gi();D(t,!0);let r=K(t,`children`,7),i=K(t,`child`,7),a=K(t,`ref`,15,null),o=K(t,`id`,23,()=>uC(n)),s=K(t,`disabled`,7,!1),c=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`children`,`child`,`ref`,`id`,`disabled`]),l=aE.create({id:Q(()=>o()),ref:Q(()=>a(),e=>a(e)),disabled:Q(()=>s())}),u=A(()=>Bx(c,l.props));var d={get children(){return r()},set children(e){r(e),k()},get child(){return i()},set child(e){i(e),k()},get ref(){return a()},set ref(e=null){a(e),k()},get id(){return o()},set id(e=uC(n)){o(e),k()},get disabled(){return s()},set disabled(e=!1){s(e),k()}},f=z(),p=P(f),m=e=>{var t=z();H(P(t),i,()=>({props:L(u)})),B(e,t)},h=e=>{var t=uE();Ja(t,()=>({...L(u)})),H(N(t),()=>r()??w),E(t),B(e,t)};return U(p,e=>{i()?e(m):e(h,-1)}),B(e,f),O(d)}q(dE,{children:{},child:{},ref:{},id:{},disabled:{}},[],[],{mode:`open`});var fE=[`top`,`right`,`bottom`,`left`],pE=Math.min,mE=Math.max,hE=Math.round,gE=Math.floor,_E=e=>({x:e,y:e}),vE={left:`right`,right:`left`,bottom:`top`,top:`bottom`};function yE(e,t,n){return mE(e,pE(t,n))}function bE(e,t){return typeof e==`function`?e(t):e}function xE(e){return e.split(`-`)[0]}function SE(e){return e.split(`-`)[1]}function CE(e){return e===`x`?`y`:`x`}function wE(e){return e===`y`?`height`:`width`}function TE(e){let t=e[0];return t===`t`||t===`b`?`y`:`x`}function EE(e){return CE(TE(e))}function DE(e,t,n){n===void 0&&(n=!1);let r=SE(e),i=EE(e),a=wE(i),o=i===`x`?r===(n?`end`:`start`)?`right`:`left`:r===`start`?`bottom`:`top`;return t.reference[a]>t.floating[a]&&(o=IE(o)),[o,IE(o)]}function OE(e){let t=IE(e);return[kE(e),t,kE(t)]}function kE(e){return e.includes(`start`)?e.replace(`start`,`end`):e.replace(`end`,`start`)}var AE=[`left`,`right`],jE=[`right`,`left`],ME=[`top`,`bottom`],NE=[`bottom`,`top`];function PE(e,t,n){switch(e){case`top`:case`bottom`:return n?t?jE:AE:t?AE:jE;case`left`:case`right`:return t?ME:NE;default:return[]}}function FE(e,t,n,r){let i=SE(e),a=PE(xE(e),n===`start`,r);return i&&(a=a.map(e=>e+`-`+i),t&&(a=a.concat(a.map(kE)))),a}function IE(e){let t=xE(e);return vE[t]+e.slice(t.length)}function LE(e){return{top:0,right:0,bottom:0,left:0,...e}}function RE(e){return typeof e==`number`?{top:e,right:e,bottom:e,left:e}:LE(e)}function zE(e){let{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}function BE(e,t,n){let{reference:r,floating:i}=e,a=TE(t),o=EE(t),s=wE(o),c=xE(t),l=a===`y`,u=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,f=r[s]/2-i[s]/2,p;switch(c){case`top`:p={x:u,y:r.y-i.height};break;case`bottom`:p={x:u,y:r.y+r.height};break;case`right`:p={x:r.x+r.width,y:d};break;case`left`:p={x:r.x-i.width,y:d};break;default:p={x:r.x,y:r.y}}switch(SE(t)){case`start`:p[o]-=f*(n&&l?-1:1);break;case`end`:p[o]+=f*(n&&l?-1:1);break}return p}async function VE(e,t){t===void 0&&(t={});let{x:n,y:r,platform:i,rects:a,elements:o,strategy:s}=e,{boundary:c=`clippingAncestors`,rootBoundary:l=`viewport`,elementContext:u=`floating`,altBoundary:d=!1,padding:f=0}=bE(t,e),p=RE(f),m=o[d?u===`floating`?`reference`:`floating`:u],h=zE(await i.getClippingRect({element:await(i.isElement==null?void 0:i.isElement(m))??!0?m:m.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(o.floating)),boundary:c,rootBoundary:l,strategy:s})),g=u===`floating`?{x:n,y:r,width:a.floating.width,height:a.floating.height}:a.reference,_=await(i.getOffsetParent==null?void 0:i.getOffsetParent(o.floating)),v=await(i.isElement==null?void 0:i.isElement(_))&&await(i.getScale==null?void 0:i.getScale(_))||{x:1,y:1},y=zE(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:o,rect:g,offsetParent:_,strategy:s}):g);return{top:(h.top-y.top+p.top)/v.y,bottom:(y.bottom-h.bottom+p.bottom)/v.y,left:(h.left-y.left+p.left)/v.x,right:(y.right-h.right+p.right)/v.x}}var HE=50,UE=async(e,t,n)=>{let{placement:r=`bottom`,strategy:i=`absolute`,middleware:a=[],platform:o}=n,s=o.detectOverflow?o:{...o,detectOverflow:VE},c=await(o.isRTL==null?void 0:o.isRTL(t)),l=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=BE(l,r,c),f=r,p=0,m={};for(let n=0;n<a.length;n++){let h=a[n];if(!h)continue;let{name:g,fn:_}=h,{x:v,y,data:b,reset:x}=await _({x:u,y:d,initialPlacement:r,placement:f,strategy:i,middlewareData:m,rects:l,platform:s,elements:{reference:e,floating:t}});u=v??u,d=y??d,m[g]={...m[g],...b},x&&p<HE&&(p++,typeof x==`object`&&(x.placement&&(f=x.placement),x.rects&&(l=x.rects===!0?await o.getElementRects({reference:e,floating:t,strategy:i}):x.rects),{x:u,y:d}=BE(l,f,c)),n=-1)}return{x:u,y:d,placement:f,strategy:i,middlewareData:m}},WE=e=>({name:`arrow`,options:e,async fn(t){let{x:n,y:r,placement:i,rects:a,platform:o,elements:s,middlewareData:c}=t,{element:l,padding:u=0}=bE(e,t)||{};if(l==null)return{};let d=RE(u),f={x:n,y:r},p=EE(i),m=wE(p),h=await o.getDimensions(l),g=p===`y`,_=g?`top`:`left`,v=g?`bottom`:`right`,y=g?`clientHeight`:`clientWidth`,b=a.reference[m]+a.reference[p]-f[p]-a.floating[m],x=f[p]-a.reference[p],S=await(o.getOffsetParent==null?void 0:o.getOffsetParent(l)),C=S?S[y]:0;(!C||!await(o.isElement==null?void 0:o.isElement(S)))&&(C=s.floating[y]||a.floating[m]);let ee=b/2-x/2,te=C/2-h[m]/2-1,ne=pE(d[_],te),re=pE(d[v],te),w=ne,ie=C-h[m]-re,ae=C/2-h[m]/2+ee,oe=yE(w,ae,ie),se=!c.arrow&&SE(i)!=null&&ae!==oe&&a.reference[m]/2-(ae<w?ne:re)-h[m]/2<0,ce=se?ae<w?ae-w:ae-ie:0;return{[p]:f[p]+ce,data:{[p]:oe,centerOffset:ae-oe-ce,...se&&{alignmentOffset:ce}},reset:se}}}),GE=function(e){return e===void 0&&(e={}),{name:`flip`,options:e,async fn(t){var n;let{placement:r,middlewareData:i,rects:a,initialPlacement:o,platform:s,elements:c}=t,{mainAxis:l=!0,crossAxis:u=!0,fallbackPlacements:d,fallbackStrategy:f=`bestFit`,fallbackAxisSideDirection:p=`none`,flipAlignment:m=!0,...h}=bE(e,t);if((n=i.arrow)!=null&&n.alignmentOffset)return{};let g=xE(r),_=TE(o),v=xE(o)===o,y=await(s.isRTL==null?void 0:s.isRTL(c.floating)),b=d||(v||!m?[IE(o)]:OE(o)),x=p!==`none`;!d&&x&&b.push(...FE(o,m,p,y));let S=[o,...b],C=await s.detectOverflow(t,h),ee=[],te=i.flip?.overflows||[];if(l&&ee.push(C[g]),u){let e=DE(r,a,y);ee.push(C[e[0]],C[e[1]])}if(te=[...te,{placement:r,overflows:ee}],!ee.every(e=>e<=0)){let e=(i.flip?.index||0)+1,t=S[e];if(t&&(!(u===`alignment`&&_!==TE(t))||te.every(e=>TE(e.placement)===_?e.overflows[0]>0:!0)))return{data:{index:e,overflows:te},reset:{placement:t}};let n=te.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0]?.placement;if(!n)switch(f){case`bestFit`:{let e=te.filter(e=>{if(x){let t=TE(e.placement);return t===_||t===`y`}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0]?.[0];e&&(n=e);break}case`initialPlacement`:n=o;break}if(r!==n)return{reset:{placement:n}}}return{}}}};function KE(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function qE(e){return fE.some(t=>e[t]>=0)}var JE=function(e){return e===void 0&&(e={}),{name:`hide`,options:e,async fn(t){let{rects:n,platform:r}=t,{strategy:i=`referenceHidden`,...a}=bE(e,t);switch(i){case`referenceHidden`:{let e=KE(await r.detectOverflow(t,{...a,elementContext:`reference`}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:qE(e)}}}case`escaped`:{let e=KE(await r.detectOverflow(t,{...a,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:qE(e)}}}default:return{}}}}},YE=new Set([`left`,`top`]);async function XE(e,t){let{placement:n,platform:r,elements:i}=e,a=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=xE(n),s=SE(n),c=TE(n)===`y`,l=YE.has(o)?-1:1,u=a&&c?-1:1,d=bE(t,e),{mainAxis:f,crossAxis:p,alignmentAxis:m}=typeof d==`number`?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&typeof m==`number`&&(p=s===`end`?m*-1:m),c?{x:p*u,y:f*l}:{x:f*l,y:p*u}}var ZE=function(e){return e===void 0&&(e=0),{name:`offset`,options:e,async fn(t){var n;let{x:r,y:i,placement:a,middlewareData:o}=t,s=await XE(t,e);return a===o.offset?.placement&&(n=o.arrow)!=null&&n.alignmentOffset?{}:{x:r+s.x,y:i+s.y,data:{...s,placement:a}}}}},QE=function(e){return e===void 0&&(e={}),{name:`shift`,options:e,async fn(t){let{x:n,y:r,placement:i,platform:a}=t,{mainAxis:o=!0,crossAxis:s=!1,limiter:c={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...l}=bE(e,t),u={x:n,y:r},d=await a.detectOverflow(t,l),f=TE(xE(i)),p=CE(f),m=u[p],h=u[f];if(o){let e=p===`y`?`top`:`left`,t=p===`y`?`bottom`:`right`,n=m+d[e],r=m-d[t];m=yE(n,m,r)}if(s){let e=f===`y`?`top`:`left`,t=f===`y`?`bottom`:`right`,n=h+d[e],r=h-d[t];h=yE(n,h,r)}let g=c.fn({...t,[p]:m,[f]:h});return{...g,data:{x:g.x-n,y:g.y-r,enabled:{[p]:o,[f]:s}}}}}},$E=function(e){return e===void 0&&(e={}),{options:e,fn(t){let{x:n,y:r,placement:i,rects:a,middlewareData:o}=t,{offset:s=0,mainAxis:c=!0,crossAxis:l=!0}=bE(e,t),u={x:n,y:r},d=TE(i),f=CE(d),p=u[f],m=u[d],h=bE(s,t),g=typeof h==`number`?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(c){let e=f===`y`?`height`:`width`,t=a.reference[f]-a.floating[e]+g.mainAxis,n=a.reference[f]+a.reference[e]-g.mainAxis;p<t?p=t:p>n&&(p=n)}if(l){let e=f===`y`?`width`:`height`,t=YE.has(xE(i)),n=a.reference[d]-a.floating[e]+(t&&o.offset?.[d]||0)+(t?0:g.crossAxis),r=a.reference[d]+a.reference[e]+(t?0:o.offset?.[d]||0)-(t?g.crossAxis:0);m<n?m=n:m>r&&(m=r)}return{[f]:p,[d]:m}}}},eD=function(e){return e===void 0&&(e={}),{name:`size`,options:e,async fn(t){var n,r;let{placement:i,rects:a,platform:o,elements:s}=t,{apply:c=()=>{},...l}=bE(e,t),u=await o.detectOverflow(t,l),d=xE(i),f=SE(i),p=TE(i)===`y`,{width:m,height:h}=a.floating,g,_;d===`top`||d===`bottom`?(g=d,_=f===(await(o.isRTL==null?void 0:o.isRTL(s.floating))?`start`:`end`)?`left`:`right`):(_=d,g=f===`end`?`top`:`bottom`);let v=h-u.top-u.bottom,y=m-u.left-u.right,b=pE(h-u[g],v),x=pE(m-u[_],y),S=!t.middlewareData.shift,C=b,ee=x;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(ee=y),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(C=v),S&&!f){let e=mE(u.left,0),t=mE(u.right,0),n=mE(u.top,0),r=mE(u.bottom,0);p?ee=m-2*(e!==0||t!==0?e+t:mE(u.left,u.right)):C=h-2*(n!==0||r!==0?n+r:mE(u.top,u.bottom))}await c({...t,availableWidth:ee,availableHeight:C});let te=await o.getDimensions(s.floating);return m!==te.width||h!==te.height?{reset:{rects:!0}}:{}}}};function tD(){return typeof window<`u`}function nD(e){return aD(e)?(e.nodeName||``).toLowerCase():`#document`}function rD(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function iD(e){return((aD(e)?e.ownerDocument:e.document)||window.document)?.documentElement}function aD(e){return tD()?e instanceof Node||e instanceof rD(e).Node:!1}function oD(e){return tD()?e instanceof Element||e instanceof rD(e).Element:!1}function sD(e){return tD()?e instanceof HTMLElement||e instanceof rD(e).HTMLElement:!1}function cD(e){return!tD()||typeof ShadowRoot>`u`?!1:e instanceof ShadowRoot||e instanceof rD(e).ShadowRoot}function lD(e){let{overflow:t,overflowX:n,overflowY:r,display:i}=bD(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&i!==`inline`&&i!==`contents`}function uD(e){return/^(table|td|th)$/.test(nD(e))}function dD(e){try{if(e.matches(`:popover-open`))return!0}catch{}try{return e.matches(`:modal`)}catch{return!1}}var fD=/transform|translate|scale|rotate|perspective|filter/,pD=/paint|layout|strict|content/,mD=e=>!!e&&e!==`none`,hD;function gD(e){let t=oD(e)?bD(e):e;return mD(t.transform)||mD(t.translate)||mD(t.scale)||mD(t.rotate)||mD(t.perspective)||!vD()&&(mD(t.backdropFilter)||mD(t.filter))||fD.test(t.willChange||``)||pD.test(t.contain||``)}function _D(e){let t=SD(e);for(;sD(t)&&!yD(t);){if(gD(t))return t;if(dD(t))return null;t=SD(t)}return null}function vD(){return hD??=typeof CSS<`u`&&CSS.supports&&CSS.supports(`-webkit-backdrop-filter`,`none`),hD}function yD(e){return/^(html|body|#document)$/.test(nD(e))}function bD(e){return rD(e).getComputedStyle(e)}function xD(e){return oD(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function SD(e){if(nD(e)===`html`)return e;let t=e.assignedSlot||e.parentNode||cD(e)&&e.host||iD(e);return cD(t)?t.host:t}function CD(e){let t=SD(e);return yD(t)?e.ownerDocument?e.ownerDocument.body:e.body:sD(t)&&lD(t)?t:CD(t)}function wD(e,t,n){t===void 0&&(t=[]),n===void 0&&(n=!0);let r=CD(e),i=r===e.ownerDocument?.body,a=rD(r);if(i){let e=TD(a);return t.concat(a,a.visualViewport||[],lD(r)?r:[],e&&n?wD(e):[])}else return t.concat(r,wD(r,[],n))}function TD(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function ED(e){let t=bD(e),n=parseFloat(t.width)||0,r=parseFloat(t.height)||0,i=sD(e),a=i?e.offsetWidth:n,o=i?e.offsetHeight:r,s=hE(n)!==a||hE(r)!==o;return s&&(n=a,r=o),{width:n,height:r,$:s}}function DD(e){return oD(e)?e:e.contextElement}function OD(e){let t=DD(e);if(!sD(t))return _E(1);let n=t.getBoundingClientRect(),{width:r,height:i,$:a}=ED(t),o=(a?hE(n.width):n.width)/r,s=(a?hE(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!s||!Number.isFinite(s))&&(s=1),{x:o,y:s}}var kD=_E(0);function AD(e){let t=rD(e);return!vD()||!t.visualViewport?kD:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function jD(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==rD(e)?!1:t}function MD(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);let i=e.getBoundingClientRect(),a=DD(e),o=_E(1);t&&(r?oD(r)&&(o=OD(r)):o=OD(e));let s=jD(a,n,r)?AD(a):_E(0),c=(i.left+s.x)/o.x,l=(i.top+s.y)/o.y,u=i.width/o.x,d=i.height/o.y;if(a){let e=rD(a),t=r&&oD(r)?rD(r):r,n=e,i=TD(n);for(;i&&r&&t!==n;){let e=OD(i),t=i.getBoundingClientRect(),r=bD(i),a=t.left+(i.clientLeft+parseFloat(r.paddingLeft))*e.x,o=t.top+(i.clientTop+parseFloat(r.paddingTop))*e.y;c*=e.x,l*=e.y,u*=e.x,d*=e.y,c+=a,l+=o,n=rD(i),i=TD(n)}}return zE({width:u,height:d,x:c,y:l})}function ND(e,t){let n=xD(e).scrollLeft;return t?t.left+n:MD(iD(e)).left+n}function PD(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-ND(e,n),y:n.top+t.scrollTop}}function FD(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e,a=i===`fixed`,o=iD(r),s=t?dD(t.floating):!1;if(r===o||s&&a)return n;let c={scrollLeft:0,scrollTop:0},l=_E(1),u=_E(0),d=sD(r);if((d||!d&&!a)&&((nD(r)!==`body`||lD(o))&&(c=xD(r)),d)){let e=MD(r);l=OD(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}let f=o&&!d&&!a?PD(o,c):_E(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-c.scrollLeft*l.x+u.x+f.x,y:n.y*l.y-c.scrollTop*l.y+u.y+f.y}}function ID(e){return Array.from(e.getClientRects())}function LD(e){let t=iD(e),n=xD(e),r=e.ownerDocument.body,i=mE(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=mE(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight),o=-n.scrollLeft+ND(e),s=-n.scrollTop;return bD(r).direction===`rtl`&&(o+=mE(t.clientWidth,r.clientWidth)-i),{width:i,height:a,x:o,y:s}}var RD=25;function zD(e,t){let n=rD(e),r=iD(e),i=n.visualViewport,a=r.clientWidth,o=r.clientHeight,s=0,c=0;if(i){a=i.width,o=i.height;let e=vD();(!e||e&&t===`fixed`)&&(s=i.offsetLeft,c=i.offsetTop)}let l=ND(r);if(l<=0){let e=r.ownerDocument,t=e.body,n=getComputedStyle(t),i=e.compatMode===`CSS1Compat`&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,o=Math.abs(r.clientWidth-t.clientWidth-i);o<=RD&&(a-=o)}else l<=RD&&(a+=l);return{width:a,height:o,x:s,y:c}}function BD(e,t){let n=MD(e,!0,t===`fixed`),r=n.top+e.clientTop,i=n.left+e.clientLeft,a=sD(e)?OD(e):_E(1);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:i*a.x,y:r*a.y}}function VD(e,t,n){let r;if(t===`viewport`)r=zD(e,n);else if(t===`document`)r=LD(iD(e));else if(oD(t))r=BD(t,n);else{let n=AD(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return zE(r)}function HD(e,t){let n=SD(e);return n===t||!oD(n)||yD(n)?!1:bD(n).position===`fixed`||HD(n,t)}function UD(e,t){let n=t.get(e);if(n)return n;let r=wD(e,[],!1).filter(e=>oD(e)&&nD(e)!==`body`),i=null,a=bD(e).position===`fixed`,o=a?SD(e):e;for(;oD(o)&&!yD(o);){let t=bD(o),n=gD(o);!n&&t.position===`fixed`&&(i=null),(a?!n&&!i:!n&&t.position===`static`&&i&&(i.position===`absolute`||i.position===`fixed`)||lD(o)&&!n&&HD(e,o))?r=r.filter(e=>e!==o):i=t,o=SD(o)}return t.set(e,r),r}function WD(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e,a=[...n===`clippingAncestors`?dD(t)?[]:UD(t,this._c):[].concat(n),r],o=VD(t,a[0],i),s=o.top,c=o.right,l=o.bottom,u=o.left;for(let e=1;e<a.length;e++){let n=VD(t,a[e],i);s=mE(n.top,s),c=pE(n.right,c),l=pE(n.bottom,l),u=mE(n.left,u)}return{width:c-u,height:l-s,x:u,y:s}}function GD(e){let{width:t,height:n}=ED(e);return{width:t,height:n}}function KD(e,t,n){let r=sD(t),i=iD(t),a=n===`fixed`,o=MD(e,!0,a,t),s={scrollLeft:0,scrollTop:0},c=_E(0);function l(){c.x=ND(i)}if(r||!r&&!a)if((nD(t)!==`body`||lD(i))&&(s=xD(t)),r){let e=MD(t,!0,a,t);c.x=e.x+t.clientLeft,c.y=e.y+t.clientTop}else i&&l();a&&!r&&i&&l();let u=i&&!r&&!a?PD(i,s):_E(0);return{x:o.left+s.scrollLeft-c.x-u.x,y:o.top+s.scrollTop-c.y-u.y,width:o.width,height:o.height}}function qD(e){return bD(e).position===`static`}function JD(e,t){if(!sD(e)||bD(e).position===`fixed`)return null;if(t)return t(e);let n=e.offsetParent;return iD(e)===n&&(n=n.ownerDocument.body),n}function YD(e,t){let n=rD(e);if(dD(e))return n;if(!sD(e)){let t=SD(e);for(;t&&!yD(t);){if(oD(t)&&!qD(t))return t;t=SD(t)}return n}let r=JD(e,t);for(;r&&uD(r)&&qD(r);)r=JD(r,t);return r&&yD(r)&&qD(r)&&!gD(r)?n:r||_D(e)||n}var XD=async function(e){let t=this.getOffsetParent||YD,n=this.getDimensions,r=await n(e.floating);return{reference:KD(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function ZD(e){return bD(e).direction===`rtl`}var QD={convertOffsetParentRelativeRectToViewportRelativeRect:FD,getDocumentElement:iD,getClippingRect:WD,getOffsetParent:YD,getElementRects:XD,getClientRects:ID,getDimensions:GD,getScale:OD,isElement:oD,isRTL:ZD};function $D(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function eO(e,t){let n=null,r,i=iD(e);function a(){var e;clearTimeout(r),(e=n)==null||e.disconnect(),n=null}function o(s,c){s===void 0&&(s=!1),c===void 0&&(c=1),a();let l=e.getBoundingClientRect(),{left:u,top:d,width:f,height:p}=l;if(s||t(),!f||!p)return;let m=gE(d),h=gE(i.clientWidth-(u+f)),g=gE(i.clientHeight-(d+p)),_=gE(u),v={rootMargin:-m+`px `+-h+`px `+-g+`px `+-_+`px`,threshold:mE(0,pE(1,c))||1},y=!0;function b(t){let n=t[0].intersectionRatio;if(n!==c){if(!y)return o();n?o(!1,n):r=setTimeout(()=>{o(!1,1e-7)},1e3)}n===1&&!$D(l,e.getBoundingClientRect())&&o(),y=!1}try{n=new IntersectionObserver(b,{...v,root:i.ownerDocument})}catch{n=new IntersectionObserver(b,v)}n.observe(e)}return o(!0),a}function tO(e,t,n,r){r===void 0&&(r={});let{ancestorScroll:i=!0,ancestorResize:a=!0,elementResize:o=typeof ResizeObserver==`function`,layoutShift:s=typeof IntersectionObserver==`function`,animationFrame:c=!1}=r,l=DD(e),u=i||a?[...l?wD(l):[],...t?wD(t):[]]:[];u.forEach(e=>{i&&e.addEventListener(`scroll`,n,{passive:!0}),a&&e.addEventListener(`resize`,n)});let d=l&&s?eO(l,n):null,f=-1,p=null;o&&(p=new ResizeObserver(e=>{let[r]=e;r&&r.target===l&&p&&t&&(p.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var e;(e=p)==null||e.observe(t)})),n()}),l&&!c&&p.observe(l),t&&p.observe(t));let m,h=c?MD(e):null;c&&g();function g(){let t=MD(e);h&&!$D(h,t)&&n(),h=t,m=requestAnimationFrame(g)}return n(),()=>{var e;u.forEach(e=>{i&&e.removeEventListener(`scroll`,n),a&&e.removeEventListener(`resize`,n)}),d?.(),(e=p)==null||e.disconnect(),p=null,c&&cancelAnimationFrame(m)}}var nO=ZE,rO=QE,iO=GE,aO=eD,oO=JE,sO=WE,cO=$E,lO=(e,t,n)=>{let r=new Map,i={platform:QD,...n},a={...i.platform,_c:r};return UE(e,t,{...i,platform:a})};function uO(e){return typeof e==`function`?e():e}function dO(e){return typeof window>`u`?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function fO(e,t){let n=dO(e);return Math.round(t*n)/n}function pO(e){return{[`--bits-${e}-content-transform-origin`]:`var(--bits-floating-transform-origin)`,[`--bits-${e}-content-available-width`]:`var(--bits-floating-available-width)`,[`--bits-${e}-content-available-height`]:`var(--bits-floating-available-height)`,[`--bits-${e}-anchor-width`]:`var(--bits-floating-anchor-width)`,[`--bits-${e}-anchor-height`]:`var(--bits-floating-anchor-height)`}}function mO(e){let t=e.whileElementsMounted,n=A(()=>uO(e.open)??!0),r=A(()=>uO(e.middleware)),i=A(()=>uO(e.transform)??!0),a=A(()=>uO(e.placement)??`bottom`),o=A(()=>uO(e.strategy)??`absolute`),s=A(()=>uO(e.sideOffset)??0),c=A(()=>uO(e.alignOffset)??0),l=e.reference,u=j(0),d=j(0),f=ix(null),p=j(Dn(L(o))),m=j(Dn(L(a))),h=j(Dn({})),g=j(!1),_=!1,v=A(()=>{let e=f.current?fO(f.current,L(u)):L(u),t=f.current?fO(f.current,L(d)):L(d);return L(i)?{position:L(p),left:`0`,top:`0`,transform:`translate(${e}px, ${t}px)`,...f.current&&dO(f.current)>=1.5&&{willChange:`transform`}}:{position:L(p),left:`${e}px`,top:`${t}px`}}),y;function b(){l.current===null||f.current===null||lO(l.current,f.current,{middleware:L(r),placement:L(a),strategy:L(o)}).then(e=>{let t=l.current;if(hO(t)){M(h,{...L(h),hide:{...L(h).hide,referenceHidden:!0}},!0);return}if(!L(n)&&L(u)!==0&&L(d)!==0){let t=Math.max(Math.abs(L(s)),Math.abs(L(c)),15);if(e.x<=t&&e.y<=t)return}M(u,e.x,!0),M(d,e.y,!0),M(p,e.strategy,!0),M(m,e.placement,!0),M(h,e.middlewareData,!0),M(g,!0)})}function x(){typeof y==`function`&&(y(),y=void 0)}function S(){if(x(),t===void 0){b();return}L(n)&&(l.current===null||f.current===null||(y=t(l.current,f.current,b)))}function C(){!L(n)&&f.current===null&&M(g,!1)}function ee(){return[L(r),L(a),L(o),L(s),L(c),L(n)]}return $n(()=>{t===void 0&&L(n)&&b()}),$n(S),$n(()=>{if(t!==void 0){if(ee(),!L(n)){_=!1;return}if(!L(g)){_=!1;return}if(!_){_=!0;return}b()}}),$n(C),$n(()=>x),{floating:f,reference:l,get strategy(){return L(p)},get placement(){return L(m)},get middlewareData(){return L(h)},get isPositioned(){return L(g)},get floatingStyles(){return L(v)},get update(){return b}}}function hO(e){return e instanceof Element?!e.isConnected||e instanceof HTMLElement&&e.hidden?!0:e.getClientRects().length===0:!1}var gO={top:`bottom`,right:`left`,bottom:`top`,left:`right`},_O=new Gx(`Floating.Root`),vO=new Gx(`Floating.Content`),yO=new Gx(`Floating.Root`),bO=class e{static create(t=!1){return t?yO.set(new e):_O.set(new e)}anchorNode=ix(null);customAnchorNode=ix(null);triggerNode=ix(null);constructor(){$n(()=>{this.customAnchorNode.current?typeof this.customAnchorNode.current==`string`?this.anchorNode.current=document.querySelector(this.customAnchorNode.current):this.anchorNode.current=this.customAnchorNode.current:this.anchorNode.current=this.triggerNode.current})}},xO=class e{static create(t,n=!1){return n?vO.set(new e(t,yO.get())):vO.set(new e(t,_O.get()))}opts;root;contentRef=ix(null);wrapperRef=ix(null);arrowRef=ix(null);contentAttachment=wS(this.contentRef);wrapperAttachment=wS(this.wrapperRef);arrowAttachment=wS(this.arrowRef);arrowId=ix(PT());#e=A(()=>{if(typeof this.opts.style==`string`)return Mx(this.opts.style);if(!this.opts.style)return{}});#t=void 0;#n=new eS(()=>this.arrowRef.current??void 0);#r=A(()=>this.#n?.width??0);#i=A(()=>this.#n?.height??0);#a=A(()=>this.opts.side?.current+(this.opts.align.current===`center`?``:`-${this.opts.align.current}`));#o=A(()=>Array.isArray(this.opts.collisionBoundary.current)?this.opts.collisionBoundary.current:[this.opts.collisionBoundary.current]);#s=A(()=>L(this.#o).length>0);get hasExplicitBoundaries(){return L(this.#s)}set hasExplicitBoundaries(e){M(this.#s,e)}#c=A(()=>({padding:this.opts.collisionPadding.current,boundary:L(this.#o).filter(aC),altBoundary:this.hasExplicitBoundaries}));get detectOverflowOptions(){return L(this.#c)}set detectOverflowOptions(e){M(this.#c,e)}#l=j(void 0);#u=j(void 0);#d=j(void 0);#f=j(void 0);#p=A(()=>[nO({mainAxis:this.opts.sideOffset.current+L(this.#i),alignmentAxis:this.opts.alignOffset.current}),this.opts.avoidCollisions.current&&rO({mainAxis:!0,crossAxis:!1,limiter:this.opts.sticky.current===`partial`?cO():void 0,...this.detectOverflowOptions}),this.opts.avoidCollisions.current&&iO({...this.detectOverflowOptions}),aO({...this.detectOverflowOptions,apply:({rects:e,availableWidth:t,availableHeight:n})=>{let{width:r,height:i}=e.reference;M(this.#l,t,!0),M(this.#u,n,!0),M(this.#d,r,!0),M(this.#f,i,!0)}}),this.arrowRef.current&&sO({element:this.arrowRef.current,padding:this.opts.arrowPadding.current}),CO({arrowWidth:L(this.#r),arrowHeight:L(this.#i)}),this.opts.hideWhenDetached.current&&oO({strategy:`referenceHidden`,...this.detectOverflowOptions})].filter(Boolean));get middleware(){return L(this.#p)}set middleware(e){M(this.#p,e)}floating;#m=A(()=>TO(this.floating.placement));get placedSide(){return L(this.#m)}set placedSide(e){M(this.#m,e)}#h=A(()=>EO(this.floating.placement));get placedAlign(){return L(this.#h)}set placedAlign(e){M(this.#h,e)}#g=A(()=>this.floating.middlewareData.arrow?.x??0);get arrowX(){return L(this.#g)}set arrowX(e){M(this.#g,e)}#_=A(()=>this.floating.middlewareData.arrow?.y??0);get arrowY(){return L(this.#_)}set arrowY(e){M(this.#_,e)}#v=A(()=>this.floating.middlewareData.arrow?.centerOffset!==0);get cannotCenterArrow(){return L(this.#v)}set cannotCenterArrow(e){M(this.#v,e)}#y=j();get contentZIndex(){return L(this.#y)}set contentZIndex(e){M(this.#y,e,!0)}#b=A(()=>gO[this.placedSide]);get arrowBaseSide(){return L(this.#b)}set arrowBaseSide(e){M(this.#b,e)}#x=A(()=>({id:this.opts.wrapperId.current,"data-bits-floating-content-wrapper":``,style:{...this.floating.floatingStyles,transform:this.floating.isPositioned?this.floating.floatingStyles.transform:`translate(0, -200%)`,minWidth:`max-content`,zIndex:this.contentZIndex,"--bits-floating-transform-origin":`${this.floating.middlewareData.transformOrigin?.x} ${this.floating.middlewareData.transformOrigin?.y}`,"--bits-floating-available-width":`${L(this.#l)}px`,"--bits-floating-available-height":`${L(this.#u)}px`,"--bits-floating-anchor-width":`${L(this.#d)}px`,"--bits-floating-anchor-height":`${L(this.#f)}px`,...this.floating.middlewareData.hide?.referenceHidden&&{visibility:`hidden`,"pointer-events":`none`},...L(this.#e)},dir:this.opts.dir.current,...this.wrapperAttachment}));get wrapperProps(){return L(this.#x)}set wrapperProps(e){M(this.#x,e)}#S=A(()=>({"data-side":this.placedSide,"data-align":this.placedAlign,style:Lx({...L(this.#e)}),...this.contentAttachment}));get props(){return L(this.#S)}set props(e){M(this.#S,e)}#C=A(()=>({position:`absolute`,left:this.arrowX?`${this.arrowX}px`:void 0,top:this.arrowY?`${this.arrowY}px`:void 0,[this.arrowBaseSide]:0,"transform-origin":{top:``,right:`0 0`,bottom:`center 0`,left:`100% 0`}[this.placedSide],transform:{top:`translateY(100%)`,right:`translateY(50%) rotate(90deg) translateX(-50%)`,bottom:`rotate(180deg)`,left:`translateY(50%) rotate(-90deg) translateX(50%)`}[this.placedSide],visibility:this.cannotCenterArrow?`hidden`:void 0}));get arrowStyle(){return L(this.#C)}set arrowStyle(e){M(this.#C,e)}constructor(e,t){this.opts=e,this.root=t,this.#t=e.updatePositionStrategy,e.customAnchor&&(this.root.customAnchorNode.current=e.customAnchor.current),Yx(()=>e.customAnchor.current,e=>{this.root.customAnchorNode.current=e}),this.floating=mO({strategy:()=>this.opts.strategy.current,placement:()=>L(this.#a),middleware:()=>this.middleware,reference:this.root.anchorNode,whileElementsMounted:(...e)=>tO(...e,{animationFrame:this.#t?.current===`always`}),open:()=>this.opts.enabled.current,sideOffset:()=>this.opts.sideOffset.current,alignOffset:()=>this.opts.alignOffset.current}),$n(()=>{this.floating.isPositioned&&this.opts.onPlaced?.current()}),Yx(()=>this.contentRef.current,e=>{if(!e||!this.opts.enabled.current)return;let t=xS(e),n=t.requestAnimationFrame(()=>{if(this.contentRef.current!==e||!this.opts.enabled.current)return;let n=t.getComputedStyle(e).zIndex;n!==this.contentZIndex&&(this.contentZIndex=n)});return()=>{t.cancelAnimationFrame(n)}}),$n(()=>{this.floating.floating.current=this.wrapperRef.current})}},SO=class e{static create(t,n=!1){return n?new e(t,yO.get()):new e(t,_O.get())}opts;root;constructor(e,t){this.opts=e,this.root=t,e.virtualEl&&e.virtualEl.current?t.triggerNode=tx(e.virtualEl.current):t.triggerNode=e.ref}};function CO(e){return{name:`transformOrigin`,options:e,fn(t){let{placement:n,rects:r,middlewareData:i}=t,a=i.arrow?.centerOffset!==0,o=a?0:e.arrowWidth,s=a?0:e.arrowHeight,[c,l]=wO(n),u={start:`0%`,center:`50%`,end:`100%`}[l],d=(i.arrow?.x??0)+o/2,f=(i.arrow?.y??0)+s/2,p=``,m=``;return c===`bottom`?(p=a?u:`${d}px`,m=`${-s}px`):c===`top`?(p=a?u:`${d}px`,m=`${r.floating.height+s}px`):c===`right`?(p=`${-s}px`,m=a?u:`${f}px`):c===`left`&&(p=`${r.floating.width+s}px`,m=a?u:`${f}px`),{data:{x:p,y:m}}}}}function wO(e){let[t,n=`center`]=e.split(`-`);return[t,n]}function TO(e){return wO(e)[0]}function EO(e){return wO(e)[1]}function DO(e,t){D(t,!0);let n=K(t,`children`,7),r=K(t,`tooltip`,7,!1);bO.create(r());var i={get children(){return n()},set children(e){n(e),k()},get tooltip(){return r()},set tooltip(e=!1){r(e),k()}},a=z();return H(P(a),()=>n()??w),B(e,a),O(i)}q(DO,{children:{},tooltip:{}},[],[],{mode:`open`});var OO=[PS,BS,FS,GS,LS,RS,`Alt`,HS,zS,`F1`,`F2`,`F3`,`F4`,`F5`,`F6`,`F7`,`F8`,`F9`,`F10`,`F11`,`F12`],kO=[NS,WS,VS],AO=[IS,US,`End`],jO=[...kO,...AO],MO=MS({component:`select`,parts:[`trigger`,`content`,`item`,`viewport`,`scroll-up-button`,`scroll-down-button`,`group`,`group-label`,`separator`,`arrow`,`input`,`content-wrapper`,`item-text`,`value`]}),NO=new Gx(`Select.Root | Combobox.Root`);new Gx(`Select.Group | Combobox.Group`);var PO=new Gx(`Select.Content | Combobox.Content`),FO=class{opts;#e=j(!1);get touchedInput(){return L(this.#e)}set touchedInput(e){M(this.#e,e,!0)}#t=j(null);get inputNode(){return L(this.#t)}set inputNode(e){M(this.#t,e,!0)}#n=j(null);get contentNode(){return L(this.#n)}set contentNode(e){M(this.#n,e,!0)}contentPresence;#r=j(null);get viewportNode(){return L(this.#r)}set viewportNode(e){M(this.#r,e,!0)}#i=j(null);get triggerNode(){return L(this.#i)}set triggerNode(e){M(this.#i,e,!0)}#a=j(``);get valueId(){return L(this.#a)}set valueId(e){M(this.#a,e,!0)}#o=j(null);get highlightedNode(){return L(this.#o)}set highlightedNode(e){M(this.#o,e,!0)}#s=A(()=>this.highlightedNode?this.highlightedNode.getAttribute(`data-value`):null);get highlightedValue(){return L(this.#s)}set highlightedValue(e){M(this.#s,e)}#c=A(()=>{if(this.highlightedNode)return this.highlightedNode.id});get highlightedId(){return L(this.#c)}set highlightedId(e){M(this.#c,e)}#l=A(()=>this.highlightedNode?this.highlightedNode.getAttribute(`data-label`):null);get highlightedLabel(){return L(this.#l)}set highlightedLabel(e){M(this.#l,e)}isUsingKeyboard=!1;isCombobox=!1;domContext=new CS(()=>null);constructor(e){this.opts=e,this.isCombobox=e.isCombobox,this.contentPresence=new lC({ref:Q(()=>this.contentNode),open:this.opts.open,onComplete:()=>{this.opts.onOpenChangeComplete.current(this.opts.open.current)}}),tr(()=>{this.opts.open.current||this.setHighlightedNode(null)})}setHighlightedNode(e,t=!1){this.highlightedNode=e,e&&(this.isUsingKeyboard||t)&&e.scrollIntoView({block:this.opts.scrollAlignment.current})}getCandidateNodes(){let e=this.contentNode;return e?Array.from(e.querySelectorAll(`[${this.getBitsAttr(`item`)}]:not([data-disabled])`)):[]}setHighlightedToFirstCandidate(e=!1){this.setHighlightedNode(null);let t=this.getCandidateNodes();if(t.length){if(this.viewportNode){let e=this.viewportNode.getBoundingClientRect();t=t.filter(t=>{if(!this.viewportNode)return!1;let n=t.getBoundingClientRect();return n.right<=e.right&&n.left>=e.left&&n.bottom<=e.bottom&&n.top>=e.top})}this.setHighlightedNode(t[0],e)}}getNodeByValue(e){return this.getCandidateNodes().find(t=>t.dataset.value===e)??null}setOpen(e){this.opts.open.current=e}toggleOpen(){this.opts.open.current=!this.opts.open.current}handleOpen(){this.setOpen(!0)}handleClose(){this.setHighlightedNode(null),this.setOpen(!1)}toggleMenu(){this.toggleOpen()}getBitsAttr=e=>MO.getAttr(e,this.isCombobox?`combobox`:void 0)},IO=class extends FO{opts;isMulti=!1;#e=A(()=>this.opts.value.current!==``);get hasValue(){return L(this.#e)}set hasValue(e){M(this.#e,e)}#t=A(()=>this.opts.items.current.length?this.opts.items.current.find(e=>e.value===this.opts.value.current)?.label??``:``);get currentLabel(){return L(this.#t)}set currentLabel(e){M(this.#t,e)}#n=A(()=>this.opts.items.current.length?this.opts.items.current.filter(e=>!e.disabled).map(e=>e.label):[]);get candidateLabels(){return L(this.#n)}set candidateLabels(e){M(this.#n,e)}#r=A(()=>!(this.isMulti||this.opts.items.current.length===0));get dataTypeaheadEnabled(){return L(this.#r)}set dataTypeaheadEnabled(e){M(this.#r,e)}constructor(e){super(e),this.opts=e,$n(()=>{!this.opts.open.current&&this.highlightedNode&&this.setHighlightedNode(null)}),Yx(()=>this.opts.open.current,()=>{this.opts.open.current&&this.setInitialHighlightedNode()})}includesItem(e){return this.opts.value.current===e}toggleItem(e,t=e){let n=this.includesItem(e)?``:e;this.opts.value.current=n,n!==``&&(this.opts.inputValue.current=t)}setInitialHighlightedNode(){uS(()=>{if(!(this.highlightedNode&&this.domContext.getDocument().contains(this.highlightedNode))){if(this.opts.value.current!==``){let e=this.getNodeByValue(this.opts.value.current);if(e){this.setHighlightedNode(e,!0);return}}this.setHighlightedToFirstCandidate(!0)}})}},LO=class extends FO{opts;isMulti=!0;#e=A(()=>this.opts.value.current.length>0);get hasValue(){return L(this.#e)}set hasValue(e){M(this.#e,e)}constructor(e){super(e),this.opts=e,$n(()=>{!this.opts.open.current&&this.highlightedNode&&this.setHighlightedNode(null)}),Yx(()=>this.opts.open.current,()=>{this.opts.open.current&&this.setInitialHighlightedNode()})}includesItem(e){return this.opts.value.current.includes(e)}toggleItem(e,t=e){this.includesItem(e)?this.opts.value.current=this.opts.value.current.filter(t=>t!==e):this.opts.value.current=[...this.opts.value.current,e],this.opts.inputValue.current=t}setInitialHighlightedNode(){uS(()=>{if(this.domContext&&!(this.highlightedNode&&this.domContext.getDocument().contains(this.highlightedNode))){if(this.opts.value.current.length&&this.opts.value.current[0]!==``){let e=this.getNodeByValue(this.opts.value.current[0]);if(e){this.setHighlightedNode(e,!0);return}}this.setHighlightedToFirstCandidate(!0)}})}},RO=class{static create(e){let{type:t,...n}=e,r=t===`single`?new IO(n):new LO(n);return NO.set(r)}},zO=class e{static create(t){return new e(t,NO.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=wS(e.ref,e=>this.root.inputNode=e),this.root.domContext=new CS(e.ref),this.onkeydown=this.onkeydown.bind(this),this.oninput=this.oninput.bind(this),Yx([()=>this.root.opts.value.current,()=>this.opts.clearOnDeselect.current],([e,t],[n])=>{t&&(Array.isArray(e)&&Array.isArray(n)?e.length===0&&n.length!==0&&(this.root.opts.inputValue.current=``):e===``&&n!==``&&(this.root.opts.inputValue.current=``))})}onkeydown(e){if(this.root.isUsingKeyboard=!0,e.key!==`Escape`){if((e.key===`ArrowUp`||e.key===`ArrowDown`)&&e.preventDefault(),!this.root.opts.open.current){if(OO.includes(e.key)||e.key===`Tab`||e.key===`Backspace`&&this.root.opts.inputValue.current===``||(this.root.handleOpen(),this.root.hasValue))return;let t=this.root.getCandidateNodes();if(!t.length)return;if(e.key===`ArrowDown`){let e=t[0];this.root.setHighlightedNode(e)}else if(e.key===`ArrowUp`){let e=t[t.length-1];this.root.setHighlightedNode(e)}return}if(e.key===`Tab`){this.root.handleClose();return}if(e.key===`Enter`&&!e.isComposing){e.preventDefault();let t=this.root.highlightedValue===this.root.opts.value.current;if(!this.root.opts.allowDeselect.current&&t&&!this.root.isMulti){this.root.handleClose();return}this.root.highlightedValue&&this.root.highlightedNode&&this.root.highlightedNode.isConnected&&this.root.toggleItem(this.root.highlightedValue,this.root.highlightedLabel??void 0),!this.root.isMulti&&!t&&this.root.handleClose()}if(e.key===`ArrowUp`&&e.altKey&&this.root.handleClose(),jO.includes(e.key)){e.preventDefault();let t=this.root.getCandidateNodes(),n=this.root.highlightedNode,r=n?t.indexOf(n):-1,i=this.root.opts.loop.current,a;if(e.key===`ArrowDown`?a=jw(t,r,i):e.key===`ArrowUp`?a=Mw(t,r,i):e.key===`PageDown`?a=Nw(t,r,10,i):e.key===`PageUp`?a=Pw(t,r,10,i):e.key===`Home`?a=t[0]:e.key===`End`&&(a=t[t.length-1]),!a)return;this.root.setHighlightedNode(a);return}OO.includes(e.key)||this.root.highlightedNode||this.root.setHighlightedToFirstCandidate()}}oninput(e){this.root.opts.inputValue.current=e.currentTarget.value,this.root.setHighlightedToFirstCandidate()}#e=A(()=>({id:this.opts.id.current,role:`combobox`,disabled:this.root.opts.disabled.current?!0:void 0,"aria-activedescendant":this.root.highlightedId,"aria-autocomplete":`list`,"aria-expanded":TS(this.root.opts.open.current),"data-state":kS(this.root.opts.open.current),"data-disabled":DS(this.root.opts.disabled.current),onkeydown:this.onkeydown,oninput:this.oninput,[this.root.getBitsAttr(`input`)]:``,...this.attachment}));get props(){return L(this.#e)}set props(e){M(this.#e,e)}},BO=class e{static create(t){return new e(t,NO.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=wS(e.ref),this.onkeydown=this.onkeydown.bind(this),this.onpointerdown=this.onpointerdown.bind(this)}onkeydown(e){this.root.domContext&&(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),this.root.domContext.getActiveElement()!==this.root.inputNode&&this.root.inputNode?.focus(),this.root.toggleMenu())}onpointerdown(e){this.root.opts.disabled.current||!this.root.domContext||(e.preventDefault(),this.root.domContext.getActiveElement()!==this.root.inputNode&&this.root.inputNode?.focus(),this.root.toggleMenu())}#e=A(()=>({id:this.opts.id.current,disabled:this.root.opts.disabled.current?!0:void 0,"aria-haspopup":`listbox`,"data-state":kS(this.root.opts.open.current),"data-disabled":DS(this.root.opts.disabled.current),[this.root.getBitsAttr(`trigger`)]:``,onpointerdown:this.onpointerdown,onkeydown:this.onkeydown,...this.attachment}));get props(){return L(this.#e)}set props(e){M(this.#e,e)}},VO=class e{static create(t){return PO.set(new e(t,NO.get()))}opts;root;attachment;#e=j(!1);get isPositioned(){return L(this.#e)}set isPositioned(e){M(this.#e,e,!0)}domContext;constructor(e,t){this.opts=e,this.root=t,this.attachment=wS(e.ref,e=>this.root.contentNode=e),this.domContext=new CS(this.opts.ref),this.root.domContext===null&&(this.root.domContext=this.domContext),sS(()=>{this.root.contentNode=null,this.isPositioned=!1}),Yx(()=>this.root.opts.open.current,()=>{this.root.opts.open.current||(this.isPositioned=!1)}),this.onpointermove=this.onpointermove.bind(this)}onpointermove(e){this.root.isUsingKeyboard=!1}#t=A(()=>pO(this.root.isCombobox?`combobox`:`select`));onInteractOutside=e=>{if(e.target===this.root.triggerNode||e.target===this.root.inputNode){e.preventDefault();return}this.opts.onInteractOutside.current(e),!e.defaultPrevented&&this.root.handleClose()};onEscapeKeydown=e=>{this.opts.onEscapeKeydown.current(e),!e.defaultPrevented&&this.root.handleClose()};onOpenAutoFocus=e=>{e.preventDefault()};onCloseAutoFocus=e=>{e.preventDefault()};get shouldRender(){return this.root.contentPresence.shouldRender}#n=A(()=>({open:this.root.opts.open.current}));get snippetProps(){return L(this.#n)}set snippetProps(e){M(this.#n,e)}#r=A(()=>({id:this.opts.id.current,role:`listbox`,"aria-multiselectable":this.root.isMulti?`true`:void 0,"data-state":kS(this.root.opts.open.current),[this.root.getBitsAttr(`content`)]:``,style:{display:`flex`,flexDirection:`column`,outline:`none`,boxSizing:`border-box`,pointerEvents:`auto`,...L(this.#t)},onpointermove:this.onpointermove,...this.attachment}));get props(){return L(this.#r)}set props(e){M(this.#r,e)}popperProps={onInteractOutside:this.onInteractOutside,onEscapeKeydown:this.onEscapeKeydown,onOpenAutoFocus:this.onOpenAutoFocus,onCloseAutoFocus:this.onCloseAutoFocus,trapFocus:!1,loop:!1,onPlaced:()=>{this.root.opts.open.current&&(this.isPositioned=!0)}}},HO=class e{static create(t){return new e(t,NO.get())}opts;root;attachment;#e=A(()=>this.root.includesItem(this.opts.value.current));get isSelected(){return L(this.#e)}set isSelected(e){M(this.#e,e)}#t=A(()=>this.root.highlightedValue===this.opts.value.current);get isHighlighted(){return L(this.#t)}set isHighlighted(e){M(this.#t,e)}prevHighlighted=new tS(()=>this.isHighlighted);#n=j(!1);get mounted(){return L(this.#n)}set mounted(e){M(this.#n,e,!0)}constructor(e,t){this.opts=e,this.root=t,this.attachment=wS(e.ref),Yx([()=>this.isHighlighted,()=>this.prevHighlighted.current],()=>{this.isHighlighted?this.opts.onHighlight.current():this.prevHighlighted.current&&this.opts.onUnhighlight.current()}),Yx(()=>this.mounted,()=>{this.mounted&&this.root.setInitialHighlightedNode()}),this.onpointerdown=this.onpointerdown.bind(this),this.onpointerup=this.onpointerup.bind(this),this.onpointermove=this.onpointermove.bind(this)}handleSelect(){if(this.opts.disabled.current)return;let e=this.opts.value.current===this.root.opts.value.current;if(!this.root.opts.allowDeselect.current&&e&&!this.root.isMulti){this.root.handleClose();return}this.root.toggleItem(this.opts.value.current,this.opts.label.current),!this.root.isMulti&&!e&&this.root.handleClose()}#r=A(()=>({selected:this.isSelected,highlighted:this.isHighlighted}));get snippetProps(){return L(this.#r)}set snippetProps(e){M(this.#r,e)}onpointerdown(e){e.preventDefault()}onpointerup(e){if(!(e.defaultPrevented||!this.opts.ref.current)){if(e.pointerType===`touch`&&!$S){ri(this.opts.ref.current,`click`,()=>{this.handleSelect(),this.root.setHighlightedNode(this.opts.ref.current)},{once:!0});return}e.preventDefault(),this.handleSelect(),e.pointerType===`touch`&&this.root.setHighlightedNode(this.opts.ref.current)}}onpointermove(e){e.pointerType!==`touch`&&this.root.highlightedNode!==this.opts.ref.current&&this.root.setHighlightedNode(this.opts.ref.current)}#i=A(()=>({id:this.opts.id.current,role:`option`,"aria-selected":this.root.includesItem(this.opts.value.current)?`true`:void 0,"data-value":this.opts.value.current,"data-disabled":DS(this.opts.disabled.current),"data-highlighted":this.root.highlightedValue===this.opts.value.current&&!this.opts.disabled.current?``:void 0,"data-selected":this.root.includesItem(this.opts.value.current)?``:void 0,"data-label":this.opts.label.current,[this.root.getBitsAttr(`item`)]:``,onpointermove:this.onpointermove,onpointerdown:this.onpointerdown,onpointerup:this.onpointerup,...this.attachment}));get props(){return L(this.#i)}set props(e){M(this.#i,e)}},UO=class e{static create(t){return new e(t,NO.get())}opts;root;#e=A(()=>this.root.opts.name.current!==``);get shouldRender(){return L(this.#e)}set shouldRender(e){M(this.#e,e)}constructor(e,t){this.opts=e,this.root=t,this.onfocus=this.onfocus.bind(this)}onfocus(e){e.preventDefault(),this.root.isCombobox?this.root.inputNode?.focus():this.root.triggerNode?.focus()}#t=A(()=>({disabled:OS(this.root.opts.disabled.current),required:OS(this.root.opts.required.current),name:this.root.opts.name.current,value:this.opts.value.current,onfocus:this.onfocus}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},WO=class e{static create(t){return new e(t,PO.get())}opts;content;root;attachment;#e=j(0);get prevScrollTop(){return L(this.#e)}set prevScrollTop(e){M(this.#e,e,!0)}constructor(e,t){this.opts=e,this.content=t,this.root=t.root,this.attachment=wS(e.ref,e=>{this.root.viewportNode=e})}#t=A(()=>({id:this.opts.id.current,role:`presentation`,[this.root.getBitsAttr(`viewport`)]:``,style:{position:`relative`,flex:1,overflow:`auto`},...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},GO=class{opts;content;root;attachment;autoScrollTimer=null;userScrollTimer=-1;isUserScrolling=!1;onAutoScroll=$;#e=j(!1);get mounted(){return L(this.#e)}set mounted(e){M(this.#e,e,!0)}constructor(e,t){this.opts=e,this.content=t,this.root=t.root,this.attachment=wS(e.ref),Yx([()=>this.mounted],()=>{if(!this.mounted){this.isUserScrolling=!1;return}this.isUserScrolling}),$n(()=>{this.mounted||this.clearAutoScrollInterval()}),this.onpointerdown=this.onpointerdown.bind(this),this.onpointermove=this.onpointermove.bind(this),this.onpointerleave=this.onpointerleave.bind(this)}handleUserScroll(){this.content.domContext.clearTimeout(this.userScrollTimer),this.isUserScrolling=!0,this.userScrollTimer=this.content.domContext.setTimeout(()=>{this.isUserScrolling=!1},200)}clearAutoScrollInterval(){this.autoScrollTimer!==null&&(this.content.domContext.clearTimeout(this.autoScrollTimer),this.autoScrollTimer=null)}onpointerdown(e){if(this.autoScrollTimer!==null)return;let t=e=>{this.onAutoScroll(),this.autoScrollTimer=this.content.domContext.setTimeout(()=>t(e+1),this.opts.delay.current(e))};this.autoScrollTimer=this.content.domContext.setTimeout(()=>t(1),this.opts.delay.current(0))}onpointermove(e){this.onpointerdown(e)}onpointerleave(e){this.clearAutoScrollInterval()}#t=A(()=>({id:this.opts.id.current,"aria-hidden":ES(!0),style:{flexShrink:0},onpointerdown:this.onpointerdown,onpointermove:this.onpointermove,onpointerleave:this.onpointerleave,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},KO=class e{static create(t){return new e(new GO(t,PO.get()))}scrollButtonState;content;root;#e=j(!1);get canScrollDown(){return L(this.#e)}set canScrollDown(e){M(this.#e,e,!0)}scrollIntoViewTimer=null;constructor(e){this.scrollButtonState=e,this.content=e.content,this.root=e.root,this.scrollButtonState.onAutoScroll=this.handleAutoScroll,Yx([()=>this.root.viewportNode,()=>this.content.isPositioned],()=>{if(!(!this.root.viewportNode||!this.content.isPositioned))return this.handleScroll(!0),ri(this.root.viewportNode,`scroll`,()=>this.handleScroll())}),Yx([()=>this.root.opts.inputValue.current,()=>this.root.viewportNode,()=>this.content.isPositioned],()=>{!this.root.viewportNode||!this.content.isPositioned||this.handleScroll(!0)}),Yx(()=>this.scrollButtonState.mounted,()=>{this.scrollButtonState.mounted&&(this.scrollIntoViewTimer&&clearTimeout(this.scrollIntoViewTimer),this.scrollIntoViewTimer=lS(5,()=>{this.root.highlightedNode?.scrollIntoView({block:this.root.opts.scrollAlignment.current})}))})}handleScroll=(e=!1)=>{if(e||this.scrollButtonState.handleUserScroll(),!this.root.viewportNode)return;let t=this.root.viewportNode.scrollHeight-this.root.viewportNode.clientHeight,n=Number.parseInt(getComputedStyle(this.root.viewportNode).paddingTop,10);this.canScrollDown=Math.ceil(this.root.viewportNode.scrollTop)<t-n};handleAutoScroll=()=>{let e=this.root.viewportNode,t=this.root.highlightedNode;!e||!t||(e.scrollTop+=t.offsetHeight)};#t=A(()=>({...this.scrollButtonState.props,[this.root.getBitsAttr(`scroll-down-button`)]:``}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}},qO=class e{static create(t){return new e(new GO(t,PO.get()))}scrollButtonState;content;root;#e=j(!1);get canScrollUp(){return L(this.#e)}set canScrollUp(e){M(this.#e,e,!0)}constructor(e){this.scrollButtonState=e,this.content=e.content,this.root=e.root,this.scrollButtonState.onAutoScroll=this.handleAutoScroll,Yx([()=>this.root.viewportNode,()=>this.content.isPositioned],()=>{if(!(!this.root.viewportNode||!this.content.isPositioned))return this.handleScroll(!0),ri(this.root.viewportNode,`scroll`,()=>this.handleScroll())})}handleScroll=(e=!1)=>{if(e||this.scrollButtonState.handleUserScroll(),!this.root.viewportNode)return;let t=Number.parseInt(getComputedStyle(this.root.viewportNode).paddingTop,10);this.canScrollUp=this.root.viewportNode.scrollTop-t>.1};handleAutoScroll=()=>{!this.root.viewportNode||!this.root.highlightedNode||(this.root.viewportNode.scrollTop=this.root.viewportNode.scrollTop-this.root.highlightedNode.offsetHeight)};#t=A(()=>({...this.scrollButtonState.props,[this.root.getBitsAttr(`scroll-up-button`)]:``}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}};function JO(e,t){D(t,!0);let n=K(t,`value`,15),r=K(t,`autocomplete`,7),i=UO.create({value:Q(()=>n())});var a={get value(){return n()},set value(e){n(e),k()},get autocomplete(){return r()},set autocomplete(e){r(e),k()}},o=z(),s=P(o),c=e=>{eE(e,mo(()=>i.props,{get autocomplete(){return r()},get value(){return n()},set value(e){n(e)}}))};return U(s,e=>{i.shouldRender&&e(c)}),B(e,o),O(a)}q(JO,{value:{},autocomplete:{}},[],[],{mode:`open`});var YO=R(`<!> <!>`,1);function XO(e,t){D(t,!0);let n=K(t,`value`,15),r=K(t,`onValueChange`,7,$),i=K(t,`name`,7,``),a=K(t,`disabled`,7,!1),o=K(t,`type`,7),s=K(t,`open`,15,!1),c=K(t,`onOpenChange`,7,$),l=K(t,`onOpenChangeComplete`,7,$),u=K(t,`loop`,7,!1),d=K(t,`scrollAlignment`,7,`nearest`),f=K(t,`required`,7,!1),p=K(t,`items`,23,()=>[]),m=K(t,`allowDeselect`,7,!0),h=K(t,`inputValue`,7,``),g=K(t,`children`,7);n()===void 0&&n(o()===`single`?``:[]),Yx.pre(()=>n(),()=>{n()===void 0&&n(o()===`single`?``:[])});let _=RO.create({type:o(),value:Q(()=>n(),e=>{n(e),r()(e)}),disabled:Q(()=>a()),required:Q(()=>f()),open:Q(()=>s(),e=>{s(e),c()(e)}),loop:Q(()=>u()),scrollAlignment:Q(()=>d()),name:Q(()=>i()),isCombobox:!0,items:Q(()=>p()),allowDeselect:Q(()=>m()),inputValue:Q(()=>h(),e=>h(e)),onOpenChangeComplete:Q(()=>l())});var v={get value(){return n()},set value(e){n(e),k()},get onValueChange(){return r()},set onValueChange(e=$){r(e),k()},get name(){return i()},set name(e=``){i(e),k()},get disabled(){return a()},set disabled(e=!1){a(e),k()},get type(){return o()},set type(e){o(e),k()},get open(){return s()},set open(e=!1){s(e),k()},get onOpenChange(){return c()},set onOpenChange(e=$){c(e),k()},get onOpenChangeComplete(){return l()},set onOpenChangeComplete(e=$){l(e),k()},get loop(){return u()},set loop(e=!1){u(e),k()},get scrollAlignment(){return d()},set scrollAlignment(e=`nearest`){d(e),k()},get required(){return f()},set required(e=!1){f(e),k()},get items(){return p()},set items(e=[]){p(e),k()},get allowDeselect(){return m()},set allowDeselect(e=!0){m(e),k()},get inputValue(){return h()},set inputValue(e=``){h(e),k()},get children(){return g()},set children(e){g(e),k()}},y=YO(),b=P(y);DO(b,{children:(e,t)=>{var n=z();H(P(n),()=>g()??w),B(e,n)},$$slots:{default:!0}});var x=F(b,2),S=e=>{var t=z(),n=P(t),r=e=>{var t=z();Xi(P(t),16,()=>_.opts.value.current,e=>e,(e,t)=>{JO(e,{get value(){return t}})}),B(e,t)};U(n,e=>{_.opts.value.current.length&&e(r)}),B(e,t)},C=A(()=>Array.isArray(_.opts.value.current)),ee=e=>{JO(e,{get value(){return _.opts.value.current},set value(e){_.opts.value.current=e}})};return U(x,e=>{L(C)?e(S):e(ee,-1)}),B(e,y),O(v)}q(XO,{value:{},onValueChange:{},name:{},disabled:{},type:{},open:{},onOpenChange:{},onOpenChangeComplete:{},loop:{},scrollAlignment:{},required:{},items:{},allowDeselect:{},inputValue:{},children:{}},[],[],{mode:`open`});function ZO(e,t){D(t,!0);let n=K(t,`id`,7),r=K(t,`children`,7),i=K(t,`virtualEl`,7),a=K(t,`ref`,7),o=K(t,`tooltip`,7,!1);SO.create({id:Q(()=>n()),virtualEl:Q(()=>i()),ref:a()},o());var s={get id(){return n()},set id(e){n(e),k()},get children(){return r()},set children(e){r(e),k()},get virtualEl(){return i()},set virtualEl(e){i(e),k()},get ref(){return a()},set ref(e){a(e),k()},get tooltip(){return o()},set tooltip(e=!1){o(e),k()}},c=z();return H(P(c),()=>r()??w),B(e,c),O(s)}q(ZO,{id:{},children:{},virtualEl:{},ref:{},tooltip:{}},[],[],{mode:`open`});function QO(e,t){D(t,!0);let n=K(t,`content`,7),r=K(t,`side`,7,`bottom`),i=K(t,`sideOffset`,7,0),a=K(t,`align`,7,`center`),o=K(t,`alignOffset`,7,0),s=K(t,`id`,7),c=K(t,`arrowPadding`,7,0),l=K(t,`avoidCollisions`,7,!0),u=K(t,`collisionBoundary`,23,()=>[]),d=K(t,`collisionPadding`,7,0),f=K(t,`hideWhenDetached`,7,!1),p=K(t,`onPlaced`,7,()=>{}),m=K(t,`sticky`,7,`partial`),h=K(t,`updatePositionStrategy`,7,`optimized`),g=K(t,`strategy`,7,`fixed`),_=K(t,`dir`,7,`ltr`),v=K(t,`style`,23,()=>({})),y=K(t,`wrapperId`,23,PT),b=K(t,`customAnchor`,7,null),x=K(t,`enabled`,7),S=K(t,`tooltip`,7,!1),C=xO.create({side:Q(()=>r()),sideOffset:Q(()=>i()),align:Q(()=>a()),alignOffset:Q(()=>o()),id:Q(()=>s()),arrowPadding:Q(()=>c()),avoidCollisions:Q(()=>l()),collisionBoundary:Q(()=>u()),collisionPadding:Q(()=>d()),hideWhenDetached:Q(()=>f()),onPlaced:Q(()=>p()),sticky:Q(()=>m()),updatePositionStrategy:Q(()=>h()),strategy:Q(()=>g()),dir:Q(()=>_()),style:Q(()=>v()),enabled:Q(()=>x()),wrapperId:Q(()=>y()),customAnchor:Q(()=>b())},S()),ee=A(()=>Bx(C.wrapperProps,{style:{pointerEvents:`auto`}}));var te={get content(){return n()},set content(e){n(e),k()},get side(){return r()},set side(e=`bottom`){r(e),k()},get sideOffset(){return i()},set sideOffset(e=0){i(e),k()},get align(){return a()},set align(e=`center`){a(e),k()},get alignOffset(){return o()},set alignOffset(e=0){o(e),k()},get id(){return s()},set id(e){s(e),k()},get arrowPadding(){return c()},set arrowPadding(e=0){c(e),k()},get avoidCollisions(){return l()},set avoidCollisions(e=!0){l(e),k()},get collisionBoundary(){return u()},set collisionBoundary(e=[]){u(e),k()},get collisionPadding(){return d()},set collisionPadding(e=0){d(e),k()},get hideWhenDetached(){return f()},set hideWhenDetached(e=!1){f(e),k()},get onPlaced(){return p()},set onPlaced(e=()=>{}){p(e),k()},get sticky(){return m()},set sticky(e=`partial`){m(e),k()},get updatePositionStrategy(){return h()},set updatePositionStrategy(e=`optimized`){h(e),k()},get strategy(){return g()},set strategy(e=`fixed`){g(e),k()},get dir(){return _()},set dir(e=`ltr`){_(e),k()},get style(){return v()},set style(e={}){v(e),k()},get wrapperId(){return y()},set wrapperId(e=PT()){y(e),k()},get customAnchor(){return b()},set customAnchor(e=null){b(e),k()},get enabled(){return x()},set enabled(e){x(e),k()},get tooltip(){return S()},set tooltip(e=!1){S(e),k()}},ne=z();return H(P(ne),()=>n()??w,()=>({props:C.props,wrapperProps:L(ee)})),B(e,ne),O(te)}q(QO,{content:{},side:{},sideOffset:{},align:{},alignOffset:{},id:{},arrowPadding:{},avoidCollisions:{},collisionBoundary:{},collisionPadding:{},hideWhenDetached:{},onPlaced:{},sticky:{},updatePositionStrategy:{},strategy:{},dir:{},style:{},wrapperId:{},customAnchor:{},enabled:{},tooltip:{}},[],[],{mode:`open`});function $O(e,t){D(t,!0);let n=K(t,`content`,7),r=K(t,`onPlaced`,7);Ii(()=>{r()?.()});var i={get content(){return n()},set content(e){n(e),k()},get onPlaced(){return r()},set onPlaced(e){r(e),k()}},a=z();return H(P(a),()=>n()??w,()=>({props:{},wrapperProps:{}})),B(e,a),O(i)}q($O,{content:{},onPlaced:{}},[],[],{mode:`open`});var ek=R(`<input/>`);function tk(e,t){D(t,!0);let n=K(t,`id`,23,PT),r=K(t,`ref`,15,null),i=K(t,`child`,7),a=K(t,`defaultValue`,7),o=K(t,`clearOnDeselect`,7,!1),s=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`ref`,`child`,`defaultValue`,`clearOnDeselect`]),c=zO.create({id:Q(()=>n()),ref:Q(()=>r(),e=>r(e)),clearOnDeselect:Q(()=>o())});a()&&(c.root.opts.inputValue.current=a());let l=A(()=>Bx(s,c.props,{value:c.root.opts.inputValue.current}));var u={get id(){return n()},set id(e=PT()){n(e),k()},get ref(){return r()},set ref(e=null){r(e),k()},get child(){return i()},set child(e){i(e),k()},get defaultValue(){return a()},set defaultValue(e){a(e),k()},get clearOnDeselect(){return o()},set clearOnDeselect(e=!1){o(e),k()}},d=z();return W(P(d),()=>ZO,(e,t)=>{t(e,{get id(){return n()},get ref(){return c.opts.ref},children:(e,t)=>{var n=z(),r=P(n),a=e=>{var t=z();H(P(t),i,()=>({props:L(l)})),B(e,t)},o=e=>{var t=ek();Ja(t,()=>({...L(l)}),void 0,void 0,void 0,void 0,!0),B(e,t)};U(r,e=>{i()?e(a):e(o,-1)}),B(e,n)},$$slots:{default:!0}})}),B(e,d),O(u)}q(tk,{id:{},ref:{},child:{},defaultValue:{},clearOnDeselect:{}},[],[],{mode:`open`});var nk=R(`<button><!></button>`);function rk(e,t){D(t,!0);let n=K(t,`id`,23,PT),r=K(t,`ref`,15,null),i=K(t,`child`,7),a=K(t,`children`,7),o=K(t,`type`,7,`button`),s=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`ref`,`child`,`children`,`type`]),c=BO.create({id:Q(()=>n()),ref:Q(()=>r(),e=>r(e))}),l=A(()=>Bx(s,c.props,{type:o()}));var u={get id(){return n()},set id(e=PT()){n(e),k()},get ref(){return r()},set ref(e=null){r(e),k()},get child(){return i()},set child(e){i(e),k()},get children(){return a()},set children(e){a(e),k()},get type(){return o()},set type(e=`button`){o(e),k()}},d=z(),f=P(d),p=e=>{var t=z();H(P(t),i,()=>({props:L(l)})),B(e,t)},m=e=>{var t=nk();Ja(t,()=>({...L(l)})),H(N(t),()=>a()??w),E(t),B(e,t)};return U(f,e=>{i()?e(p):e(m,-1)}),B(e,d),O(u)}q(rk,{id:{},ref:{},child:{},children:{},type:{}},[],[],{mode:`open`});function ik(e,t){D(t,!0);let n=K(t,`content`,7),r=K(t,`isStatic`,7,!1),i=K(t,`onPlaced`,7),a=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`content`,`isStatic`,`onPlaced`]);var o={get content(){return n()},set content(e){n(e),k()},get isStatic(){return r()},set isStatic(e=!1){r(e),k()},get onPlaced(){return i()},set onPlaced(e){i(e),k()}},s=z(),c=P(s),l=e=>{$O(e,{get content(){return n()},get onPlaced(){return i()}})},u=e=>{QO(e,mo({get content(){return n()},get onPlaced(){return i()}},()=>a))};return U(c,e=>{r()?e(l):e(u,-1)}),B(e,s),O(o)}q(ik,{content:{},isStatic:{},onPlaced:{}},[],[],{mode:`open`});var ak=R(`<!> <!>`,1);function ok(e,t){D(t,!0);let n=K(t,`popper`,7),r=K(t,`onEscapeKeydown`,7),i=K(t,`escapeKeydownBehavior`,7),a=K(t,`preventOverflowTextSelection`,7),o=K(t,`id`,7),s=K(t,`onPointerDown`,7),c=K(t,`onPointerUp`,7),l=K(t,`side`,7),u=K(t,`sideOffset`,7),d=K(t,`align`,7),f=K(t,`alignOffset`,7),p=K(t,`arrowPadding`,7),m=K(t,`avoidCollisions`,7),h=K(t,`collisionBoundary`,7),g=K(t,`collisionPadding`,7),_=K(t,`sticky`,7),v=K(t,`hideWhenDetached`,7),y=K(t,`updatePositionStrategy`,7),b=K(t,`strategy`,7),x=K(t,`dir`,7),S=K(t,`preventScroll`,7),C=K(t,`wrapperId`,7),ee=K(t,`style`,7),te=K(t,`onPlaced`,7),ne=K(t,`onInteractOutside`,7),re=K(t,`onCloseAutoFocus`,7),ie=K(t,`onOpenAutoFocus`,7),ae=K(t,`onFocusOutside`,7),oe=K(t,`interactOutsideBehavior`,7,`close`),se=K(t,`loop`,7),ce=K(t,`trapFocus`,7,!0),le=K(t,`isValidEvent`,7,()=>!1),ue=K(t,`customAnchor`,7,null),de=K(t,`isStatic`,7,!1),fe=K(t,`enabled`,7),pe=K(t,`ref`,7),me=K(t,`tooltip`,7,!1),he=K(t,`contentPointerEvents`,7,`auto`),ge=fo(t,`$$slots.$$events.$$legacy.$$host.popper.onEscapeKeydown.escapeKeydownBehavior.preventOverflowTextSelection.id.onPointerDown.onPointerUp.side.sideOffset.align.alignOffset.arrowPadding.avoidCollisions.collisionBoundary.collisionPadding.sticky.hideWhenDetached.updatePositionStrategy.strategy.dir.preventScroll.wrapperId.style.onPlaced.onInteractOutside.onCloseAutoFocus.onOpenAutoFocus.onFocusOutside.interactOutsideBehavior.loop.trapFocus.isValidEvent.customAnchor.isStatic.enabled.ref.tooltip.contentPointerEvents`.split(`.`));return ik(e,{get isStatic(){return de()},get id(){return o()},get side(){return l()},get sideOffset(){return u()},get align(){return d()},get alignOffset(){return f()},get arrowPadding(){return p()},get avoidCollisions(){return m()},get collisionBoundary(){return h()},get collisionPadding(){return g()},get sticky(){return _()},get hideWhenDetached(){return v()},get updatePositionStrategy(){return y()},get strategy(){return b()},get dir(){return x()},get wrapperId(){return C()},get style(){return ee()},get onPlaced(){return te()},get customAnchor(){return ue()},get enabled(){return fe()},get tooltip(){return me()},content:(e,l)=>{let u=()=>l?.().props,d=()=>l?.().wrapperProps;var f=ak(),p=P(f),m=e=>{KT(e,{get preventScroll(){return S()}})},h=e=>{KT(e,{get preventScroll(){return S()}})};U(p,e=>{t.forceMount&&fe()?e(m):t.forceMount||e(h,1)}),DT(F(p,2),{get onOpenAutoFocus(){return ie()},get onCloseAutoFocus(){return re()},get loop(){return se()},get enabled(){return fe()},get trapFocus(){return ce()},get forceMount(){return t.forceMount},get ref(){return pe()},focusScope:(e,t)=>{let l=()=>t?.().props;wT(e,{get onEscapeKeydown(){return r()},get escapeKeydownBehavior(){return i()},get enabled(){return fe()},get ref(){return pe()},children:(e,t)=>{xT(e,{get id(){return o()},get onInteractOutside(){return ne()},get onFocusOutside(){return ae()},get interactOutsideBehavior(){return oe()},get isValidEvent(){return le()},get enabled(){return fe()},get ref(){return pe()},children:(e,t)=>{let r=()=>t?.().props;NT(e,{get id(){return o()},get preventOverflowTextSelection(){return a()},get onPointerDown(){return s()},get onPointerUp(){return c()},get enabled(){return fe()},get ref(){return pe()},children:(e,t)=>{var i=z(),a=P(i);{let e=A(()=>({props:Bx(ge,u(),r(),l(),{style:{pointerEvents:he()}}),wrapperProps:d()}));H(a,()=>n()??w,()=>L(e))}B(e,i)},$$slots:{default:!0}})},$$slots:{default:!0}})},$$slots:{default:!0}})},$$slots:{focusScope:!0}}),B(e,f)},$$slots:{content:!0}}),O({get popper(){return n()},set popper(e){n(e),k()},get onEscapeKeydown(){return r()},set onEscapeKeydown(e){r(e),k()},get escapeKeydownBehavior(){return i()},set escapeKeydownBehavior(e){i(e),k()},get preventOverflowTextSelection(){return a()},set preventOverflowTextSelection(e){a(e),k()},get id(){return o()},set id(e){o(e),k()},get onPointerDown(){return s()},set onPointerDown(e){s(e),k()},get onPointerUp(){return c()},set onPointerUp(e){c(e),k()},get side(){return l()},set side(e){l(e),k()},get sideOffset(){return u()},set sideOffset(e){u(e),k()},get align(){return d()},set align(e){d(e),k()},get alignOffset(){return f()},set alignOffset(e){f(e),k()},get arrowPadding(){return p()},set arrowPadding(e){p(e),k()},get avoidCollisions(){return m()},set avoidCollisions(e){m(e),k()},get collisionBoundary(){return h()},set collisionBoundary(e){h(e),k()},get collisionPadding(){return g()},set collisionPadding(e){g(e),k()},get sticky(){return _()},set sticky(e){_(e),k()},get hideWhenDetached(){return v()},set hideWhenDetached(e){v(e),k()},get updatePositionStrategy(){return y()},set updatePositionStrategy(e){y(e),k()},get strategy(){return b()},set strategy(e){b(e),k()},get dir(){return x()},set dir(e){x(e),k()},get preventScroll(){return S()},set preventScroll(e){S(e),k()},get wrapperId(){return C()},set wrapperId(e){C(e),k()},get style(){return ee()},set style(e){ee(e),k()},get onPlaced(){return te()},set onPlaced(e){te(e),k()},get onInteractOutside(){return ne()},set onInteractOutside(e){ne(e),k()},get onCloseAutoFocus(){return re()},set onCloseAutoFocus(e){re(e),k()},get onOpenAutoFocus(){return ie()},set onOpenAutoFocus(e){ie(e),k()},get onFocusOutside(){return ae()},set onFocusOutside(e){ae(e),k()},get interactOutsideBehavior(){return oe()},set interactOutsideBehavior(e=`close`){oe(e),k()},get loop(){return se()},set loop(e){se(e),k()},get trapFocus(){return ce()},set trapFocus(e=!0){ce(e),k()},get isValidEvent(){return le()},set isValidEvent(e=()=>!1){le(e),k()},get customAnchor(){return ue()},set customAnchor(e=null){ue(e),k()},get isStatic(){return de()},set isStatic(e=!1){de(e),k()},get enabled(){return fe()},set enabled(e){fe(e),k()},get ref(){return pe()},set ref(e){pe(e),k()},get tooltip(){return me()},set tooltip(e=!1){me(e),k()},get contentPointerEvents(){return he()},set contentPointerEvents(e=`auto`){he(e),k()}})}q(ok,{popper:{},onEscapeKeydown:{},escapeKeydownBehavior:{},preventOverflowTextSelection:{},id:{},onPointerDown:{},onPointerUp:{},side:{},sideOffset:{},align:{},alignOffset:{},arrowPadding:{},avoidCollisions:{},collisionBoundary:{},collisionPadding:{},sticky:{},hideWhenDetached:{},updatePositionStrategy:{},strategy:{},dir:{},preventScroll:{},wrapperId:{},style:{},onPlaced:{},onInteractOutside:{},onCloseAutoFocus:{},onOpenAutoFocus:{},onFocusOutside:{},interactOutsideBehavior:{},loop:{},trapFocus:{},isValidEvent:{},customAnchor:{},isStatic:{},enabled:{},ref:{},tooltip:{},contentPointerEvents:{}},[],[],{mode:`open`});function sk(e,t){D(t,!0);let n=K(t,`popper`,7),r=K(t,`open`,7),i=K(t,`onEscapeKeydown`,7),a=K(t,`escapeKeydownBehavior`,7),o=K(t,`preventOverflowTextSelection`,7),s=K(t,`id`,7),c=K(t,`onPointerDown`,7),l=K(t,`onPointerUp`,7),u=K(t,`side`,7),d=K(t,`sideOffset`,7),f=K(t,`align`,7),p=K(t,`alignOffset`,7),m=K(t,`arrowPadding`,7),h=K(t,`avoidCollisions`,7),g=K(t,`collisionBoundary`,7),_=K(t,`collisionPadding`,7),v=K(t,`sticky`,7),y=K(t,`hideWhenDetached`,7),b=K(t,`updatePositionStrategy`,7),x=K(t,`strategy`,7),S=K(t,`dir`,7),C=K(t,`preventScroll`,7),ee=K(t,`wrapperId`,7),te=K(t,`style`,7),ne=K(t,`onPlaced`,7),re=K(t,`onInteractOutside`,7),w=K(t,`onCloseAutoFocus`,7),ie=K(t,`onOpenAutoFocus`,7),ae=K(t,`onFocusOutside`,7),oe=K(t,`interactOutsideBehavior`,7,`close`),se=K(t,`loop`,7),ce=K(t,`trapFocus`,7,!0),le=K(t,`isValidEvent`,7,()=>!1),ue=K(t,`customAnchor`,7,null),de=K(t,`isStatic`,7,!1),fe=K(t,`ref`,7),pe=K(t,`shouldRender`,7),me=fo(t,`$$slots.$$events.$$legacy.$$host.popper.open.onEscapeKeydown.escapeKeydownBehavior.preventOverflowTextSelection.id.onPointerDown.onPointerUp.side.sideOffset.align.alignOffset.arrowPadding.avoidCollisions.collisionBoundary.collisionPadding.sticky.hideWhenDetached.updatePositionStrategy.strategy.dir.preventScroll.wrapperId.style.onPlaced.onInteractOutside.onCloseAutoFocus.onOpenAutoFocus.onFocusOutside.interactOutsideBehavior.loop.trapFocus.isValidEvent.customAnchor.isStatic.ref.shouldRender`.split(`.`));var he={get popper(){return n()},set popper(e){n(e),k()},get open(){return r()},set open(e){r(e),k()},get onEscapeKeydown(){return i()},set onEscapeKeydown(e){i(e),k()},get escapeKeydownBehavior(){return a()},set escapeKeydownBehavior(e){a(e),k()},get preventOverflowTextSelection(){return o()},set preventOverflowTextSelection(e){o(e),k()},get id(){return s()},set id(e){s(e),k()},get onPointerDown(){return c()},set onPointerDown(e){c(e),k()},get onPointerUp(){return l()},set onPointerUp(e){l(e),k()},get side(){return u()},set side(e){u(e),k()},get sideOffset(){return d()},set sideOffset(e){d(e),k()},get align(){return f()},set align(e){f(e),k()},get alignOffset(){return p()},set alignOffset(e){p(e),k()},get arrowPadding(){return m()},set arrowPadding(e){m(e),k()},get avoidCollisions(){return h()},set avoidCollisions(e){h(e),k()},get collisionBoundary(){return g()},set collisionBoundary(e){g(e),k()},get collisionPadding(){return _()},set collisionPadding(e){_(e),k()},get sticky(){return v()},set sticky(e){v(e),k()},get hideWhenDetached(){return y()},set hideWhenDetached(e){y(e),k()},get updatePositionStrategy(){return b()},set updatePositionStrategy(e){b(e),k()},get strategy(){return x()},set strategy(e){x(e),k()},get dir(){return S()},set dir(e){S(e),k()},get preventScroll(){return C()},set preventScroll(e){C(e),k()},get wrapperId(){return ee()},set wrapperId(e){ee(e),k()},get style(){return te()},set style(e){te(e),k()},get onPlaced(){return ne()},set onPlaced(e){ne(e),k()},get onInteractOutside(){return re()},set onInteractOutside(e){re(e),k()},get onCloseAutoFocus(){return w()},set onCloseAutoFocus(e){w(e),k()},get onOpenAutoFocus(){return ie()},set onOpenAutoFocus(e){ie(e),k()},get onFocusOutside(){return ae()},set onFocusOutside(e){ae(e),k()},get interactOutsideBehavior(){return oe()},set interactOutsideBehavior(e=`close`){oe(e),k()},get loop(){return se()},set loop(e){se(e),k()},get trapFocus(){return ce()},set trapFocus(e=!0){ce(e),k()},get isValidEvent(){return le()},set isValidEvent(e=()=>!1){le(e),k()},get customAnchor(){return ue()},set customAnchor(e=null){ue(e),k()},get isStatic(){return de()},set isStatic(e=!1){de(e),k()},get ref(){return fe()},set ref(e){fe(e),k()},get shouldRender(){return pe()},set shouldRender(e){pe(e),k()}},ge=z(),_e=P(ge),ve=e=>{ok(e,mo({get popper(){return n()},get onEscapeKeydown(){return i()},get escapeKeydownBehavior(){return a()},get preventOverflowTextSelection(){return o()},get id(){return s()},get onPointerDown(){return c()},get onPointerUp(){return l()},get side(){return u()},get sideOffset(){return d()},get align(){return f()},get alignOffset(){return p()},get arrowPadding(){return m()},get avoidCollisions(){return h()},get collisionBoundary(){return g()},get collisionPadding(){return _()},get sticky(){return v()},get hideWhenDetached(){return y()},get updatePositionStrategy(){return b()},get strategy(){return x()},get dir(){return S()},get preventScroll(){return C()},get wrapperId(){return ee()},get style(){return te()},get onPlaced(){return ne()},get customAnchor(){return ue()},get isStatic(){return de()},get enabled(){return r()},get onInteractOutside(){return re()},get onCloseAutoFocus(){return w()},get onOpenAutoFocus(){return ie()},get interactOutsideBehavior(){return oe()},get loop(){return se()},get trapFocus(){return ce()},get isValidEvent(){return le()},get onFocusOutside(){return ae()},forceMount:!1,get ref(){return fe()}},()=>me))};return U(_e,e=>{pe()&&e(ve)}),B(e,ge),O(he)}q(sk,{popper:{},open:{},onEscapeKeydown:{},escapeKeydownBehavior:{},preventOverflowTextSelection:{},id:{},onPointerDown:{},onPointerUp:{},side:{},sideOffset:{},align:{},alignOffset:{},arrowPadding:{},avoidCollisions:{},collisionBoundary:{},collisionPadding:{},sticky:{},hideWhenDetached:{},updatePositionStrategy:{},strategy:{},dir:{},preventScroll:{},wrapperId:{},style:{},onPlaced:{},onInteractOutside:{},onCloseAutoFocus:{},onOpenAutoFocus:{},onFocusOutside:{},interactOutsideBehavior:{},loop:{},trapFocus:{},isValidEvent:{},customAnchor:{},isStatic:{},ref:{},shouldRender:{}},[],[],{mode:`open`});function ck(e,t){D(t,!0);let n=K(t,`popper`,7),r=K(t,`onEscapeKeydown`,7),i=K(t,`escapeKeydownBehavior`,7),a=K(t,`preventOverflowTextSelection`,7),o=K(t,`id`,7),s=K(t,`onPointerDown`,7),c=K(t,`onPointerUp`,7),l=K(t,`side`,7),u=K(t,`sideOffset`,7),d=K(t,`align`,7),f=K(t,`alignOffset`,7),p=K(t,`arrowPadding`,7),m=K(t,`avoidCollisions`,7),h=K(t,`collisionBoundary`,7),g=K(t,`collisionPadding`,7),_=K(t,`sticky`,7),v=K(t,`hideWhenDetached`,7),y=K(t,`updatePositionStrategy`,7),b=K(t,`strategy`,7),x=K(t,`dir`,7),S=K(t,`preventScroll`,7),C=K(t,`wrapperId`,7),ee=K(t,`style`,7),te=K(t,`onPlaced`,7),ne=K(t,`onInteractOutside`,7),re=K(t,`onCloseAutoFocus`,7),w=K(t,`onOpenAutoFocus`,7),ie=K(t,`onFocusOutside`,7),ae=K(t,`interactOutsideBehavior`,7,`close`),oe=K(t,`loop`,7),se=K(t,`trapFocus`,7,!0),ce=K(t,`isValidEvent`,7,()=>!1),le=K(t,`customAnchor`,7,null),ue=K(t,`isStatic`,7,!1),de=K(t,`enabled`,7),fe=fo(t,`$$slots.$$events.$$legacy.$$host.popper.onEscapeKeydown.escapeKeydownBehavior.preventOverflowTextSelection.id.onPointerDown.onPointerUp.side.sideOffset.align.alignOffset.arrowPadding.avoidCollisions.collisionBoundary.collisionPadding.sticky.hideWhenDetached.updatePositionStrategy.strategy.dir.preventScroll.wrapperId.style.onPlaced.onInteractOutside.onCloseAutoFocus.onOpenAutoFocus.onFocusOutside.interactOutsideBehavior.loop.trapFocus.isValidEvent.customAnchor.isStatic.enabled`.split(`.`));return ok(e,mo({get popper(){return n()},get onEscapeKeydown(){return r()},get escapeKeydownBehavior(){return i()},get preventOverflowTextSelection(){return a()},get id(){return o()},get onPointerDown(){return s()},get onPointerUp(){return c()},get side(){return l()},get sideOffset(){return u()},get align(){return d()},get alignOffset(){return f()},get arrowPadding(){return p()},get avoidCollisions(){return m()},get collisionBoundary(){return h()},get collisionPadding(){return g()},get sticky(){return _()},get hideWhenDetached(){return v()},get updatePositionStrategy(){return y()},get strategy(){return b()},get dir(){return x()},get preventScroll(){return S()},get wrapperId(){return C()},get style(){return ee()},get onPlaced(){return te()},get customAnchor(){return le()},get isStatic(){return ue()},get enabled(){return de()},get onInteractOutside(){return ne()},get onCloseAutoFocus(){return re()},get onOpenAutoFocus(){return w()},get interactOutsideBehavior(){return ae()},get loop(){return oe()},get trapFocus(){return se()},get isValidEvent(){return ce()},get onFocusOutside(){return ie()}},()=>fe,{forceMount:!0})),O({get popper(){return n()},set popper(e){n(e),k()},get onEscapeKeydown(){return r()},set onEscapeKeydown(e){r(e),k()},get escapeKeydownBehavior(){return i()},set escapeKeydownBehavior(e){i(e),k()},get preventOverflowTextSelection(){return a()},set preventOverflowTextSelection(e){a(e),k()},get id(){return o()},set id(e){o(e),k()},get onPointerDown(){return s()},set onPointerDown(e){s(e),k()},get onPointerUp(){return c()},set onPointerUp(e){c(e),k()},get side(){return l()},set side(e){l(e),k()},get sideOffset(){return u()},set sideOffset(e){u(e),k()},get align(){return d()},set align(e){d(e),k()},get alignOffset(){return f()},set alignOffset(e){f(e),k()},get arrowPadding(){return p()},set arrowPadding(e){p(e),k()},get avoidCollisions(){return m()},set avoidCollisions(e){m(e),k()},get collisionBoundary(){return h()},set collisionBoundary(e){h(e),k()},get collisionPadding(){return g()},set collisionPadding(e){g(e),k()},get sticky(){return _()},set sticky(e){_(e),k()},get hideWhenDetached(){return v()},set hideWhenDetached(e){v(e),k()},get updatePositionStrategy(){return y()},set updatePositionStrategy(e){y(e),k()},get strategy(){return b()},set strategy(e){b(e),k()},get dir(){return x()},set dir(e){x(e),k()},get preventScroll(){return S()},set preventScroll(e){S(e),k()},get wrapperId(){return C()},set wrapperId(e){C(e),k()},get style(){return ee()},set style(e){ee(e),k()},get onPlaced(){return te()},set onPlaced(e){te(e),k()},get onInteractOutside(){return ne()},set onInteractOutside(e){ne(e),k()},get onCloseAutoFocus(){return re()},set onCloseAutoFocus(e){re(e),k()},get onOpenAutoFocus(){return w()},set onOpenAutoFocus(e){w(e),k()},get onFocusOutside(){return ie()},set onFocusOutside(e){ie(e),k()},get interactOutsideBehavior(){return ae()},set interactOutsideBehavior(e=`close`){ae(e),k()},get loop(){return oe()},set loop(e){oe(e),k()},get trapFocus(){return se()},set trapFocus(e=!0){se(e),k()},get isValidEvent(){return ce()},set isValidEvent(e=()=>!1){ce(e),k()},get customAnchor(){return le()},set customAnchor(e=null){le(e),k()},get isStatic(){return ue()},set isStatic(e=!1){ue(e),k()},get enabled(){return de()},set enabled(e){de(e),k()}})}q(ck,{popper:{},onEscapeKeydown:{},escapeKeydownBehavior:{},preventOverflowTextSelection:{},id:{},onPointerDown:{},onPointerUp:{},side:{},sideOffset:{},align:{},alignOffset:{},arrowPadding:{},avoidCollisions:{},collisionBoundary:{},collisionPadding:{},sticky:{},hideWhenDetached:{},updatePositionStrategy:{},strategy:{},dir:{},preventScroll:{},wrapperId:{},style:{},onPlaced:{},onInteractOutside:{},onCloseAutoFocus:{},onOpenAutoFocus:{},onFocusOutside:{},interactOutsideBehavior:{},loop:{},trapFocus:{},isValidEvent:{},customAnchor:{},isStatic:{},enabled:{}},[],[],{mode:`open`});var lk=R(`<div><div><!></div></div>`),uk=R(`<div><div><!></div></div>`);function dk(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>uC(n)),i=K(t,`ref`,15,null),a=K(t,`forceMount`,7,!1),o=K(t,`side`,7,`bottom`),s=K(t,`onInteractOutside`,7,$),c=K(t,`onEscapeKeydown`,7,$),l=K(t,`children`,7),u=K(t,`child`,7),d=K(t,`preventScroll`,7,!1),f=K(t,`style`,7),p=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`ref`,`forceMount`,`side`,`onInteractOutside`,`onEscapeKeydown`,`children`,`child`,`preventScroll`,`style`]),m=VO.create({id:Q(()=>r()),ref:Q(()=>i(),e=>i(e)),onInteractOutside:Q(()=>s()),onEscapeKeydown:Q(()=>c())}),h=A(()=>Bx(p,m.props));var g={get id(){return r()},set id(e=uC(n)){r(e),k()},get ref(){return i()},set ref(e=null){i(e),k()},get forceMount(){return a()},set forceMount(e=!1){a(e),k()},get side(){return o()},set side(e=`bottom`){o(e),k()},get onInteractOutside(){return s()},set onInteractOutside(e=$){s(e),k()},get onEscapeKeydown(){return c()},set onEscapeKeydown(e=$){c(e),k()},get children(){return l()},set children(e){l(e),k()},get child(){return u()},set child(e){u(e),k()},get preventScroll(){return d()},set preventScroll(e=!1){d(e),k()},get style(){return f()},set style(e){f(e),k()}},_=z(),v=P(_),y=e=>{ck(e,mo(()=>L(h),()=>m.popperProps,{get ref(){return m.opts.ref},get side(){return o()},get enabled(){return m.root.opts.open.current},get id(){return r()},get preventScroll(){return d()},forceMount:!0,get shouldRender(){return m.shouldRender},popper:(e,t)=>{let n=()=>t?.().props,r=()=>t?.().wrapperProps,i=A(()=>Bx(n(),{style:m.props.style},{style:f()}));var a=z(),o=P(a),s=e=>{var t=z(),n=P(t);{let e=A(()=>({props:L(i),wrapperProps:r(),...m.snippetProps}));H(n,u,()=>L(e))}B(e,t)},c=e=>{var t=lk();Ja(t,()=>({...r()}));var n=N(t);Ja(n,()=>({...L(i)})),H(N(n),()=>l()??w),E(n),E(t),B(e,t)};U(o,e=>{u()?e(s):e(c,-1)}),B(e,a)},$$slots:{popper:!0}}))},b=e=>{sk(e,mo(()=>L(h),()=>m.popperProps,{get ref(){return m.opts.ref},get side(){return o()},get open(){return m.root.opts.open.current},get id(){return r()},get preventScroll(){return d()},forceMount:!1,get shouldRender(){return m.shouldRender},popper:(e,t)=>{let n=()=>t?.().props,r=()=>t?.().wrapperProps,i=A(()=>Bx(n(),{style:m.props.style},{style:f()}));var a=z(),o=P(a),s=e=>{var t=z(),n=P(t);{let e=A(()=>({props:L(i),wrapperProps:r(),...m.snippetProps}));H(n,u,()=>L(e))}B(e,t)},c=e=>{var t=uk();Ja(t,()=>({...r()}));var n=N(t);Ja(n,()=>({...L(i)})),H(N(n),()=>l()??w),E(n),E(t),B(e,t)};U(o,e=>{u()?e(s):e(c,-1)}),B(e,a)},$$slots:{popper:!0}}))};return U(v,e=>{a()?e(y):a()||e(b,1)}),B(e,_),O(g)}q(dk,{id:{},ref:{},forceMount:{},side:{},onInteractOutside:{},onEscapeKeydown:{},children:{},child:{},preventScroll:{},style:{}},[],[],{mode:`open`});function fk(e,t){D(t,!0);let n=K(t,`mounted`,15,!1),r=K(t,`onMountedChange`,7,$);return cS(()=>(n(!0),r()(!0),()=>{n(!1),r()(!1)})),O({get mounted(){return n()},set mounted(e=!1){n(e),k()},get onMountedChange(){return r()},set onMountedChange(e=$){r(e),k()}})}q(fk,{mounted:{},onMountedChange:{}},[],[],{mode:`open`});var pk=R(`<div><!></div>`),mk=R(`<!> <!>`,1);function hk(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>uC(n)),i=K(t,`ref`,15,null),a=K(t,`value`,7),o=K(t,`label`,23,a),s=K(t,`disabled`,7,!1),c=K(t,`children`,7),l=K(t,`child`,7),u=K(t,`onHighlight`,7,$),d=K(t,`onUnhighlight`,7,$),f=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`ref`,`value`,`label`,`disabled`,`children`,`child`,`onHighlight`,`onUnhighlight`]),p=HO.create({id:Q(()=>r()),ref:Q(()=>i(),e=>i(e)),value:Q(()=>a()),disabled:Q(()=>s()),label:Q(()=>o()),onHighlight:Q(()=>u()),onUnhighlight:Q(()=>d())}),m=A(()=>Bx(f,p.props));var h={get id(){return r()},set id(e=uC(n)){r(e),k()},get ref(){return i()},set ref(e=null){i(e),k()},get value(){return a()},set value(e){a(e),k()},get label(){return o()},set label(e=a){o(e),k()},get disabled(){return s()},set disabled(e=!1){s(e),k()},get children(){return c()},set children(e){c(e),k()},get child(){return l()},set child(e){l(e),k()},get onHighlight(){return u()},set onHighlight(e=$){u(e),k()},get onUnhighlight(){return d()},set onUnhighlight(e=$){d(e),k()}},g=mk(),_=P(g),v=e=>{var t=z(),n=P(t);{let e=A(()=>({props:L(m),...p.snippetProps}));H(n,l,()=>L(e))}B(e,t)},y=e=>{var t=pk();Ja(t,()=>({...L(m)})),H(N(t),()=>c()??w,()=>p.snippetProps),E(t),B(e,t)};return U(_,e=>{l()?e(v):e(y,-1)}),fk(F(_,2),{get mounted(){return p.mounted},set mounted(e){p.mounted=e}}),B(e,g),O(h)}q(hk,{id:{},ref:{},value:{},label:{},disabled:{},children:{},child:{},onHighlight:{},onUnhighlight:{}},[],[],{mode:`open`});var gk=R(`<div><!></div>`),_k={hash:`svelte-5vjl6o`,code:`
|
|
573
|
+
/* Hide scrollbars cross browser and enable momentum scroll for touch devices */[data-select-viewport] {scrollbar-width:none !important;-ms-overflow-style:none !important;-webkit-overflow-scrolling:touch !important;}[data-combobox-viewport] {scrollbar-width:none !important;-ms-overflow-style:none !important;-webkit-overflow-scrolling:touch !important;}[data-combobox-viewport]::-webkit-scrollbar {display:none !important;}[data-select-viewport]::-webkit-scrollbar {display:none !important;}`};function vk(e,t){let n=gi();D(t,!0),ga(e,_k);let r=K(t,`id`,23,()=>uC(n)),i=K(t,`ref`,15,null),a=K(t,`children`,7),o=K(t,`child`,7),s=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`ref`,`children`,`child`]),c=WO.create({id:Q(()=>r()),ref:Q(()=>i(),e=>i(e))}),l=A(()=>Bx(s,c.props));var u={get id(){return r()},set id(e=uC(n)){r(e),k()},get ref(){return i()},set ref(e=null){i(e),k()},get children(){return a()},set children(e){a(e),k()},get child(){return o()},set child(e){o(e),k()}},d=z(),f=P(d),p=e=>{var t=z();H(P(t),o,()=>({props:L(l)})),B(e,t)},m=e=>{var t=gk();Ja(t,()=>({...L(l)})),H(N(t),()=>a()??w),E(t),B(e,t)};return U(f,e=>{o()?e(p):e(m,-1)}),B(e,d),O(u)}q(vk,{id:{},ref:{},children:{},child:{}},[],[],{mode:`open`});var yk=R(`<div><!></div>`),bk=R(`<!> <!>`,1);function xk(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>uC(n)),i=K(t,`ref`,15,null),a=K(t,`delay`,7,()=>50),o=K(t,`child`,7),s=K(t,`children`,7),c=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`ref`,`delay`,`child`,`children`]),l=KO.create({id:Q(()=>r()),ref:Q(()=>i(),e=>i(e)),delay:Q(()=>a())}),u=A(()=>Bx(c,l.props));var d={get id(){return r()},set id(e=uC(n)){r(e),k()},get ref(){return i()},set ref(e=null){i(e),k()},get delay(){return a()},set delay(e=()=>50){a(e),k()},get child(){return o()},set child(e){o(e),k()},get children(){return s()},set children(e){s(e),k()}},f=z(),p=P(f),m=e=>{var t=bk(),n=P(t);fk(n,{get mounted(){return l.scrollButtonState.mounted},set mounted(e){l.scrollButtonState.mounted=e}});var r=F(n,2),i=e=>{var t=z();H(P(t),o,()=>({props:c})),B(e,t)},a=e=>{var t=yk();Ja(t,()=>({...L(u)})),H(N(t),()=>s()??w),E(t),B(e,t)};U(r,e=>{o()?e(i):e(a,-1)}),B(e,t)};return U(p,e=>{l.canScrollDown&&e(m)}),B(e,f),O(d)}q(xk,{id:{},ref:{},delay:{},child:{},children:{}},[],[],{mode:`open`});var Sk=R(`<div><!></div>`),Ck=R(`<!> <!>`,1);function wk(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>uC(n)),i=K(t,`ref`,15,null),a=K(t,`delay`,7,()=>50),o=K(t,`child`,7),s=K(t,`children`,7),c=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`ref`,`delay`,`child`,`children`]),l=qO.create({id:Q(()=>r()),ref:Q(()=>i(),e=>i(e)),delay:Q(()=>a())}),u=A(()=>Bx(c,l.props));var d={get id(){return r()},set id(e=uC(n)){r(e),k()},get ref(){return i()},set ref(e=null){i(e),k()},get delay(){return a()},set delay(e=()=>50){a(e),k()},get child(){return o()},set child(e){o(e),k()},get children(){return s()},set children(e){s(e),k()}},f=z(),p=P(f),m=e=>{var t=Ck(),n=P(t);fk(n,{get mounted(){return l.scrollButtonState.mounted},set mounted(e){l.scrollButtonState.mounted=e}});var r=F(n,2),i=e=>{var t=z();H(P(t),o,()=>({props:c})),B(e,t)},a=e=>{var t=Sk();Ja(t,()=>({...L(u)})),H(N(t),()=>s()??w),E(t),B(e,t)};U(r,e=>{o()?e(i):e(a,-1)}),B(e,t)};return U(p,e=>{l.canScrollUp&&e(m)}),B(e,f),O(d)}q(wk,{id:{},ref:{},delay:{},child:{},children:{}},[],[],{mode:`open`});var Tk=R(`<div><!></div>`);function Ek(e,t){let n=gi();D(t,!0);let r=K(t,`child`,7),i=K(t,`children`,7),a=K(t,`ref`,15,null),o=K(t,`id`,23,()=>uC(n)),s=K(t,`disabled`,7,!1),c=K(t,`onSelect`,7,$),l=K(t,`closeOnSelect`,7,!0),u=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`child`,`children`,`ref`,`id`,`disabled`,`onSelect`,`closeOnSelect`]),d=sT.create({id:Q(()=>o()),disabled:Q(()=>s()),onSelect:Q(()=>c()),ref:Q(()=>a(),e=>a(e)),closeOnSelect:Q(()=>l())}),f=A(()=>Bx(u,d.props));var p={get child(){return r()},set child(e){r(e),k()},get children(){return i()},set children(e){i(e),k()},get ref(){return a()},set ref(e=null){a(e),k()},get id(){return o()},set id(e=uC(n)){o(e),k()},get disabled(){return s()},set disabled(e=!1){s(e),k()},get onSelect(){return c()},set onSelect(e=$){c(e),k()},get closeOnSelect(){return l()},set closeOnSelect(e=!0){l(e),k()}},m=z(),h=P(m),g=e=>{var t=z();H(P(t),r,()=>({props:L(f)})),B(e,t)},_=e=>{var t=Tk();Ja(t,()=>({...L(f)})),H(N(t),()=>i()??w),E(t),B(e,t)};return U(h,e=>{r()?e(g):e(_,-1)}),B(e,m),O(p)}q(Ek,{child:{},children:{},ref:{},id:{},disabled:{},onSelect:{},closeOnSelect:{}},[],[],{mode:`open`});var Dk=R(`<div><!></div>`);function Ok(e,t){let n=gi();D(t,!0);let r=K(t,`children`,7),i=K(t,`child`,7),a=K(t,`ref`,15,null),o=K(t,`id`,23,()=>uC(n)),s=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`children`,`child`,`ref`,`id`]),c=lT.create({id:Q(()=>o()),ref:Q(()=>a(),e=>a(e))}),l=A(()=>Bx(s,c.props));var u={get children(){return r()},set children(e){r(e),k()},get child(){return i()},set child(e){i(e),k()},get ref(){return a()},set ref(e=null){a(e),k()},get id(){return o()},set id(e=uC(n)){o(e),k()}},d=z(),f=P(d),p=e=>{var t=z();H(P(t),i,()=>({props:L(l)})),B(e,t)},m=e=>{var t=Dk();Ja(t,()=>({...L(l)})),H(N(t),()=>r()??w),E(t),B(e,t)};return U(f,e=>{i()?e(p):e(m,-1)}),B(e,d),O(u)}q(Ok,{children:{},child:{},ref:{},id:{}},[],[],{mode:`open`});var kk=R(`<div><!></div>`);function Ak(e,t){let n=gi();D(t,!0);let r=K(t,`children`,7),i=K(t,`child`,7),a=K(t,`ref`,15,null),o=K(t,`id`,23,()=>uC(n)),s=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`children`,`child`,`ref`,`id`]),c=uT.create({id:Q(()=>o()),ref:Q(()=>a(),e=>a(e))}),l=A(()=>Bx(s,c.props));var u={get children(){return r()},set children(e){r(e),k()},get child(){return i()},set child(e){i(e),k()},get ref(){return a()},set ref(e=null){a(e),k()},get id(){return o()},set id(e=uC(n)){o(e),k()}},d=z(),f=P(d),p=e=>{var t=z();H(P(t),i,()=>({props:L(l)})),B(e,t)},m=e=>{var t=kk();Ja(t,()=>({...L(l)})),H(N(t),()=>r()??w),E(t),B(e,t)};return U(f,e=>{i()?e(p):e(m,-1)}),B(e,d),O(u)}q(Ak,{children:{},child:{},ref:{},id:{}},[],[],{mode:`open`});var jk=R(`<div><!></div>`);function Mk(e,t){let n=gi();D(t,!0);let r=K(t,`children`,7),i=K(t,`child`,7),a=K(t,`ref`,15,null),o=K(t,`value`,7),s=K(t,`onSelect`,7,$),c=K(t,`id`,23,()=>uC(n)),l=K(t,`disabled`,7,!1),u=K(t,`closeOnSelect`,7,!0),d=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`children`,`child`,`ref`,`value`,`onSelect`,`id`,`disabled`,`closeOnSelect`]),f=pT.create({value:Q(()=>o()),id:Q(()=>c()),disabled:Q(()=>l()),onSelect:Q(()=>p),ref:Q(()=>a(),e=>a(e)),closeOnSelect:Q(()=>u())});function p(e){s()(e),!e.defaultPrevented&&f.selectValue()}let m=A(()=>Bx(d,f.props));var h={get children(){return r()},set children(e){r(e),k()},get child(){return i()},set child(e){i(e),k()},get ref(){return a()},set ref(e=null){a(e),k()},get value(){return o()},set value(e){o(e),k()},get onSelect(){return s()},set onSelect(e=$){s(e),k()},get id(){return c()},set id(e=uC(n)){c(e),k()},get disabled(){return l()},set disabled(e=!1){l(e),k()},get closeOnSelect(){return u()},set closeOnSelect(e=!0){u(e),k()}},g=z(),_=P(g),v=e=>{var t=z();H(P(t),i,()=>({props:L(m),checked:f.isChecked})),B(e,t)},y=e=>{var t=jk();Ja(t,()=>({...L(m)})),H(N(t),()=>r()??w,()=>({checked:f.isChecked})),E(t),B(e,t)};return U(_,e=>{i()?e(v):e(y,-1)}),B(e,g),O(h)}q(Mk,{children:{},child:{},ref:{},value:{},onSelect:{},id:{},disabled:{},closeOnSelect:{}},[],[],{mode:`open`});var Nk=R(`<div><!></div>`);function Pk(e,t){let n=gi();D(t,!0);let r=K(t,`ref`,15,null),i=K(t,`id`,23,()=>uC(n)),a=K(t,`child`,7),o=K(t,`children`,7),s=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`ref`,`id`,`child`,`children`]),c=dT.create({id:Q(()=>i()),ref:Q(()=>r(),e=>r(e))}),l=A(()=>Bx(s,c.props));var u={get ref(){return r()},set ref(e=null){r(e),k()},get id(){return i()},set id(e=uC(n)){i(e),k()},get child(){return a()},set child(e){a(e),k()},get children(){return o()},set children(e){o(e),k()}},d=z(),f=P(d),p=e=>{var t=z();H(P(t),a,()=>({props:L(l)})),B(e,t)},m=e=>{var t=Nk();Ja(t,()=>({...L(l)})),H(N(t),()=>o()??w),E(t),B(e,t)};return U(f,e=>{a()?e(p):e(m,-1)}),B(e,d),O(u)}q(Pk,{ref:{},id:{},child:{},children:{}},[],[],{mode:`open`});var Fk=R(`<div><!></div>`);function Ik(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>uC(n)),i=K(t,`children`,7),a=K(t,`child`,7),o=K(t,`ref`,15,null),s=K(t,`value`,15,``),c=K(t,`onValueChange`,7,$),l=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`children`,`child`,`ref`,`value`,`onValueChange`]),u=fT.create({value:Q(()=>s(),e=>{s(e),c()(e)}),ref:Q(()=>o(),e=>o(e)),id:Q(()=>r())}),d=A(()=>Bx(l,u.props));var f={get id(){return r()},set id(e=uC(n)){r(e),k()},get children(){return i()},set children(e){i(e),k()},get child(){return a()},set child(e){a(e),k()},get ref(){return o()},set ref(e=null){o(e),k()},get value(){return s()},set value(e=``){s(e),k()},get onValueChange(){return c()},set onValueChange(e=$){c(e),k()}},p=z(),m=P(p),h=e=>{var t=z();H(P(t),a,()=>({props:L(d)})),B(e,t)},g=e=>{var t=Fk();Ja(t,()=>({...L(d)})),H(N(t),()=>i()??w),E(t),B(e,t)};return U(m,e=>{a()?e(h):e(g,-1)}),B(e,p),O(f)}q(Ik,{id:{},children:{},child:{},ref:{},value:{},onValueChange:{}},[],[],{mode:`open`});var Lk=R(`<div><!></div>`);function Rk(e,t){let n=gi();D(t,!0);let r=K(t,`child`,7),i=K(t,`children`,7),a=K(t,`ref`,15,null),o=K(t,`checked`,15,!1),s=K(t,`id`,23,()=>uC(n)),c=K(t,`onCheckedChange`,7,$),l=K(t,`disabled`,7,!1),u=K(t,`onSelect`,7,$),d=K(t,`closeOnSelect`,7,!0),f=K(t,`indeterminate`,15,!1),p=K(t,`onIndeterminateChange`,7,$),m=K(t,`value`,7,``),h=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`child`,`children`,`ref`,`checked`,`id`,`onCheckedChange`,`disabled`,`onSelect`,`closeOnSelect`,`indeterminate`,`onIndeterminateChange`,`value`]),g=eT.getOr(null);g&&m()&&(g.opts.value.current.includes(m())?o(!0):o(!1)),Yx.pre(()=>m(),()=>{g&&m()&&(g.opts.value.current.includes(m())?o(!0):o(!1))});let _=cT.create({checked:Q(()=>o(),e=>{e!==o()&&(o(e),c()(e))}),id:Q(()=>s()),disabled:Q(()=>l()),onSelect:Q(()=>v),ref:Q(()=>a(),e=>a(e)),closeOnSelect:Q(()=>d()),indeterminate:Q(()=>f(),e=>{e!==f()&&(f(e),p()(e))}),value:Q(()=>m())},g);function v(e){u()(e),!e.defaultPrevented&&_.toggleChecked()}let y=A(()=>Bx(h,_.props));var b={get child(){return r()},set child(e){r(e),k()},get children(){return i()},set children(e){i(e),k()},get ref(){return a()},set ref(e=null){a(e),k()},get checked(){return o()},set checked(e=!1){o(e),k()},get id(){return s()},set id(e=uC(n)){s(e),k()},get onCheckedChange(){return c()},set onCheckedChange(e=$){c(e),k()},get disabled(){return l()},set disabled(e=!1){l(e),k()},get onSelect(){return u()},set onSelect(e=$){u(e),k()},get closeOnSelect(){return d()},set closeOnSelect(e=!0){d(e),k()},get indeterminate(){return f()},set indeterminate(e=!1){f(e),k()},get onIndeterminateChange(){return p()},set onIndeterminateChange(e=$){p(e),k()},get value(){return m()},set value(e=``){m(e),k()}},x=z(),S=P(x),C=e=>{var t=z();H(P(t),r,()=>({checked:o(),indeterminate:f(),props:L(y)})),B(e,t)},ee=e=>{var t=Lk();Ja(t,()=>({...L(y)})),H(N(t),()=>i()??w,()=>({checked:o(),indeterminate:f()})),E(t),B(e,t)};return U(S,e=>{r()?e(C):e(ee,-1)}),B(e,x),O(b)}q(Rk,{child:{},children:{},ref:{},checked:{},id:{},onCheckedChange:{},disabled:{},onSelect:{},closeOnSelect:{},indeterminate:{},onIndeterminateChange:{},value:{}},[],[],{mode:`open`});var zk=R(`<div><!></div>`);function Bk(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>uC(n)),i=K(t,`children`,7),a=K(t,`child`,7),o=K(t,`ref`,15,null),s=K(t,`value`,31,()=>Dn([])),c=K(t,`onValueChange`,7,$),l=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`children`,`child`,`ref`,`value`,`onValueChange`]),u=hT.create({value:Q(()=>st(s()),e=>{s(st(e)),c()(e)}),onValueChange:Q(()=>c()),ref:Q(()=>o(),e=>o(e)),id:Q(()=>r())}),d=A(()=>Bx(l,u.props));var f={get id(){return r()},set id(e=uC(n)){r(e),k()},get children(){return i()},set children(e){i(e),k()},get child(){return a()},set child(e){a(e),k()},get ref(){return o()},set ref(e=null){o(e),k()},get value(){return s()},set value(e=[]){s(e),k()},get onValueChange(){return c()},set onValueChange(e=$){c(e),k()}},p=z(),m=P(p),h=e=>{var t=z();H(P(t),a,()=>({props:L(d)})),B(e,t)},g=e=>{var t=zk();Ja(t,()=>({...L(d)})),H(N(t),()=>i()??w),E(t),B(e,t)};return U(m,e=>{a()?e(h):e(g,-1)}),B(e,p),O(f)}q(Bk,{id:{},children:{},child:{},ref:{},value:{},onValueChange:{}},[],[],{mode:`open`});function Vk(e,t){let[n,r]=e,i=!1,a=t.length;for(let e=0,o=a-1;e<a;o=e++){let[a,s]=t[e]??[0,0],[c,l]=t[o]??[0,0];s>=r!=l>=r&&n<=(c-a)*(r-s)/(l-s)+a&&(i=!i)}return i}function Hk(e,t){return e[0]>=t.left&&e[0]<=t.right&&e[1]>=t.top&&e[1]<=t.bottom}function Uk(e,t){let n=e.left+e.width/2,r=e.top+e.height/2,i=t.left+t.width/2,a=t.top+t.height/2,o=i-n,s=a-r;return Math.abs(o)>Math.abs(s)?o>0?`right`:`left`:s>0?`bottom`:`top`}var Wk=class{#e;#t;#n;#r=null;#i=null;#a=[];#o=null;#s=null;#c=null;#l(){this.#s!==null&&(cancelAnimationFrame(this.#s),this.#s=null)}#u(){this.#l(),this.#s=requestAnimationFrame(()=>{this.#s=null,!(!this.#r||!this.#i)&&(this.#m(),this.#e.onPointerExit())})}#d(){this.#c!==null&&(clearTimeout(this.#c),this.#c=null)}#f(){this.#n!==null&&(this.#d(),this.#c=window.setTimeout(()=>{this.#c=null,!(!this.#r||!this.#i)&&(this.#m(),this.#e.onPointerExit())},this.#n))}constructor(e){this.#e=e,this.#t=e.buffer??1;let t=e.transitIntentTimeout;this.#n=typeof t==`number`&&t>0?t:null,Yx([e.triggerNode,e.contentNode,e.enabled],([e,t,n])=>{if(!e||!t||!n){this.#o=null,this.#m();return}return this.#o&&this.#o!==e&&this.#m(),this.#o=e,[ri(bS(e),`pointermove`,n=>{this.#p([n.clientX,n.clientY],e,t)}),ri(e,`pointerleave`,e=>{let n=e.relatedTarget;if(nC(n)&&t.contains(n))return;let r=this.#e.ignoredTargets?.()??[];nC(n)&&r.some(e=>e===n||e.contains(n))||(this.#a=nC(n)&&r.length>0?r.filter(e=>n.contains(e)):[],this.#r=[e.clientX,e.clientY],this.#i=`content`,this.#u())}),ri(e,`pointerenter`,()=>{this.#m()}),ri(t,`pointerenter`,()=>{this.#m()}),ri(t,`pointerleave`,t=>{let n=t.relatedTarget;nC(n)&&e.contains(n)||(this.#r=[t.clientX,t.clientY],this.#i=`trigger`,this.#u())})].reduce((e,t)=>()=>{e(),t()},()=>{})})}#p(e,t,n){if(!this.#r||!this.#i)return;this.#l(),this.#f();let r=t.getBoundingClientRect(),i=n.getBoundingClientRect();if(this.#i===`content`&&Hk(e,i)){this.#m();return}if(this.#i===`trigger`&&Hk(e,r)){this.#m();return}if(this.#i===`content`&&this.#a.length>0)for(let t of this.#a){let n=t.getBoundingClientRect();if(Hk(e,n))return;let i=Uk(r,n),a=this.#h(r,n,i);if(a&&Vk(e,a))return}let a=Uk(r,i),o=this.#h(r,i,a);if(o&&Vk(e,o))return;let s=this.#i===`content`?i:r;Vk(e,this.#g(this.#r,s,a,this.#i))||(this.#m(),this.#e.onPointerExit())}#m(){this.#r=null,this.#i=null,this.#a=[],this.#l(),this.#d()}#h(e,t,n){let r=this.#t;switch(n){case`top`:return[[Math.min(e.left,t.left)-r,e.top],[Math.min(e.left,t.left)-r,t.bottom],[Math.max(e.right,t.right)+r,t.bottom],[Math.max(e.right,t.right)+r,e.top]];case`bottom`:return[[Math.min(e.left,t.left)-r,e.bottom],[Math.min(e.left,t.left)-r,t.top],[Math.max(e.right,t.right)+r,t.top],[Math.max(e.right,t.right)+r,e.bottom]];case`left`:return[[e.left,Math.min(e.top,t.top)-r],[t.right,Math.min(e.top,t.top)-r],[t.right,Math.max(e.bottom,t.bottom)+r],[e.left,Math.max(e.bottom,t.bottom)+r]];case`right`:return[[e.right,Math.min(e.top,t.top)-r],[t.left,Math.min(e.top,t.top)-r],[t.left,Math.max(e.bottom,t.bottom)+r],[e.right,Math.max(e.bottom,t.bottom)+r]]}}#g(e,t,n,r){let i=this.#t*4,[a,o]=e;switch(r===`trigger`?this.#_(n):n){case`top`:return[[a-i,o+i],[a+i,o+i],[t.right+i,t.bottom],[t.right+i,t.top],[t.left-i,t.top],[t.left-i,t.bottom]];case`bottom`:return[[a-i,o-i],[a+i,o-i],[t.right+i,t.top],[t.right+i,t.bottom],[t.left-i,t.bottom],[t.left-i,t.top]];case`left`:return[[a+i,o-i],[a+i,o+i],[t.right,t.bottom+i],[t.left,t.bottom+i],[t.left,t.top-i],[t.right,t.top-i]];case`right`:return[[a-i,o-i],[a-i,o+i],[t.left,t.bottom+i],[t.right,t.bottom+i],[t.right,t.top-i],[t.left,t.top-i]]}}#_(e){switch(e){case`top`:return`bottom`;case`bottom`:return`top`;case`left`:return`right`;case`right`:return`left`}}},Gk=MS({component:`popover`,parts:[`root`,`trigger`,`content`,`close`,`overlay`]}),Kk=new Gx(`Popover.Root`),qk=class e{static create(t){return Kk.set(new e(t))}opts;#e=j(null);get contentNode(){return L(this.#e)}set contentNode(e){M(this.#e,e,!0)}contentPresence;#t=j(null);get triggerNode(){return L(this.#t)}set triggerNode(e){M(this.#t,e,!0)}#n=j(null);get overlayNode(){return L(this.#n)}set overlayNode(e){M(this.#n,e,!0)}overlayPresence;#r=j(!1);get openedViaHover(){return L(this.#r)}set openedViaHover(e){M(this.#r,e,!0)}#i=j(!1);get hasInteractedWithContent(){return L(this.#i)}set hasInteractedWithContent(e){M(this.#i,e,!0)}#a=j(!1);get hoverCooldown(){return L(this.#a)}set hoverCooldown(e){M(this.#a,e,!0)}#o=j(0);get closeDelay(){return L(this.#o)}set closeDelay(e){M(this.#o,e,!0)}#s=null;#c=null;constructor(e){this.opts=e,this.contentPresence=new lC({ref:Q(()=>this.contentNode),open:this.opts.open,onComplete:()=>{this.opts.onOpenChangeComplete.current(this.opts.open.current)}}),this.overlayPresence=new lC({ref:Q(()=>this.overlayNode),open:this.opts.open}),Yx(()=>this.opts.open.current,e=>{e||(this.openedViaHover=!1,this.hasInteractedWithContent=!1,this.#l())})}setDomContext(e){this.#c=e}#l(){this.#s!==null&&this.#c&&(this.#c.clearTimeout(this.#s),this.#s=null)}toggleOpen(){this.#l(),this.opts.open.current=!this.opts.open.current}handleClose(){this.#l(),this.opts.open.current&&(this.opts.open.current=!1)}handleHoverOpen(){this.#l(),!this.opts.open.current&&(this.openedViaHover=!0,this.opts.open.current=!0)}handleHoverClose(){this.opts.open.current&&this.openedViaHover&&!this.hasInteractedWithContent&&(this.opts.open.current=!1)}handleDelayedHoverClose(){this.opts.open.current&&(!this.openedViaHover||this.hasInteractedWithContent||(this.#l(),this.closeDelay<=0?this.opts.open.current=!1:this.#c&&(this.#s=this.#c.setTimeout(()=>{this.openedViaHover&&!this.hasInteractedWithContent&&(this.opts.open.current=!1),this.#s=null},this.closeDelay))))}cancelDelayedClose(){this.#l()}markInteraction(){this.hasInteractedWithContent=!0,this.#l()}},Jk=class e{static create(t){return new e(t,Kk.get())}opts;root;attachment;domContext;#e=null;#t=null;#n=j(!1);constructor(e,t){this.opts=e,this.root=t,this.attachment=wS(this.opts.ref,e=>this.root.triggerNode=e),this.domContext=new CS(e.ref),this.root.setDomContext(this.domContext),this.onclick=this.onclick.bind(this),this.onkeydown=this.onkeydown.bind(this),this.onpointerenter=this.onpointerenter.bind(this),this.onpointerleave=this.onpointerleave.bind(this),Yx(()=>this.opts.closeDelay.current,e=>{this.root.closeDelay=e})}#r(){this.#e!==null&&(this.domContext.clearTimeout(this.#e),this.#e=null)}#i(){this.#t!==null&&(this.domContext.clearTimeout(this.#t),this.#t=null)}#a(){this.#r(),this.#i()}onpointerenter(e){if(this.opts.disabled.current||!this.opts.openOnHover.current||iC(e)||(M(this.#n,!0),this.#i(),this.root.cancelDelayedClose(),this.root.opts.open.current||this.root.hoverCooldown))return;let t=this.opts.openDelay.current;t<=0?this.root.handleHoverOpen():this.#e=this.domContext.setTimeout(()=>{this.root.handleHoverOpen(),this.#e=null},t)}onpointerleave(e){this.opts.disabled.current||this.opts.openOnHover.current&&(iC(e)||(M(this.#n,!1),this.#r(),this.root.hoverCooldown=!1))}onclick(e){if(!this.opts.disabled.current&&e.button===0){if(this.#a(),L(this.#n)&&this.root.opts.open.current&&this.root.openedViaHover){this.root.openedViaHover=!1,this.root.hasInteractedWithContent=!0;return}L(this.#n)&&this.opts.openOnHover.current&&this.root.opts.open.current&&(this.root.hoverCooldown=!0),this.root.hoverCooldown&&!this.root.opts.open.current&&(this.root.hoverCooldown=!1),this.root.toggleOpen()}}onkeydown(e){this.opts.disabled.current||(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),this.#a(),this.root.toggleOpen())}#o(){if(this.root.opts.open.current&&this.root.contentNode?.id)return this.root.contentNode?.id}#s=A(()=>({id:this.opts.id.current,"aria-haspopup":`dialog`,"aria-expanded":TS(this.root.opts.open.current),"data-state":kS(this.root.opts.open.current),"aria-controls":this.#o(),[Gk.trigger]:``,disabled:this.opts.disabled.current,onkeydown:this.onkeydown,onclick:this.onclick,onpointerenter:this.onpointerenter,onpointerleave:this.onpointerleave,...this.attachment}));get props(){return L(this.#s)}set props(e){M(this.#s,e)}},Yk=class e{static create(t){return new e(t,Kk.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=wS(this.opts.ref,e=>this.root.contentNode=e),this.onpointerdown=this.onpointerdown.bind(this),this.onfocusin=this.onfocusin.bind(this),this.onpointerenter=this.onpointerenter.bind(this),this.onpointerleave=this.onpointerleave.bind(this),new Wk({triggerNode:()=>this.root.triggerNode,contentNode:()=>this.root.contentNode,enabled:()=>this.root.opts.open.current&&this.root.openedViaHover&&!this.root.hasInteractedWithContent,onPointerExit:()=>{this.root.handleDelayedHoverClose()}})}onpointerdown(e){this.root.markInteraction()}onfocusin(e){let t=e.target;nC(t)&&Sw(t)&&this.root.markInteraction()}onpointerenter(e){iC(e)||this.root.cancelDelayedClose()}onpointerleave(e){iC(e)}onInteractOutside=e=>{if(this.opts.onInteractOutside.current(e),e.defaultPrevented||!nC(e.target))return;let t=e.target.closest(Gk.selector(`trigger`));if(!(t&&t===this.root.triggerNode)){if(this.opts.customAnchor.current){if(nC(this.opts.customAnchor.current)){if(this.opts.customAnchor.current.contains(e.target))return}else if(typeof this.opts.customAnchor.current==`string`){let t=document.querySelector(this.opts.customAnchor.current);if(t&&t.contains(e.target))return}}this.root.handleClose()}};onEscapeKeydown=e=>{this.opts.onEscapeKeydown.current(e),!e.defaultPrevented&&this.root.handleClose()};get shouldRender(){return this.root.contentPresence.shouldRender}get shouldTrapFocus(){return!(this.root.openedViaHover&&!this.root.hasInteractedWithContent)}#e=A(()=>({open:this.root.opts.open.current}));get snippetProps(){return L(this.#e)}set snippetProps(e){M(this.#e,e)}#t=A(()=>({id:this.opts.id.current,tabindex:-1,"data-state":kS(this.root.opts.open.current),[Gk.content]:``,style:{pointerEvents:`auto`,contain:`layout style`},onpointerdown:this.onpointerdown,onfocusin:this.onfocusin,onpointerenter:this.onpointerenter,onpointerleave:this.onpointerleave,...this.attachment}));get props(){return L(this.#t)}set props(e){M(this.#t,e)}popperProps={onInteractOutside:this.onInteractOutside,onEscapeKeydown:this.onEscapeKeydown}},Xk=R(`<div><div><!></div></div>`),Zk=R(`<div><div><!></div></div>`);function Qk(e,t){let n=gi();D(t,!0);let r=K(t,`child`,7),i=K(t,`children`,7),a=K(t,`ref`,15,null),o=K(t,`id`,23,()=>uC(n)),s=K(t,`forceMount`,7,!1),c=K(t,`onOpenAutoFocus`,7,$),l=K(t,`onCloseAutoFocus`,7,$),u=K(t,`onEscapeKeydown`,7,$),d=K(t,`onInteractOutside`,7,$),f=K(t,`trapFocus`,7,!0),p=K(t,`preventScroll`,7,!1),m=K(t,`customAnchor`,7,null),h=K(t,`style`,7),g=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`child`,`children`,`ref`,`id`,`forceMount`,`onOpenAutoFocus`,`onCloseAutoFocus`,`onEscapeKeydown`,`onInteractOutside`,`trapFocus`,`preventScroll`,`customAnchor`,`style`]),_=Yk.create({id:Q(()=>o()),ref:Q(()=>a(),e=>a(e)),onInteractOutside:Q(()=>d()),onEscapeKeydown:Q(()=>u()),customAnchor:Q(()=>m())}),v=A(()=>Bx(g,_.props)),y=A(()=>f()&&_.shouldTrapFocus);function b(e){_.shouldTrapFocus||e.preventDefault(),c()(e)}var x={get child(){return r()},set child(e){r(e),k()},get children(){return i()},set children(e){i(e),k()},get ref(){return a()},set ref(e=null){a(e),k()},get id(){return o()},set id(e=uC(n)){o(e),k()},get forceMount(){return s()},set forceMount(e=!1){s(e),k()},get onOpenAutoFocus(){return c()},set onOpenAutoFocus(e=$){c(e),k()},get onCloseAutoFocus(){return l()},set onCloseAutoFocus(e=$){l(e),k()},get onEscapeKeydown(){return u()},set onEscapeKeydown(e=$){u(e),k()},get onInteractOutside(){return d()},set onInteractOutside(e=$){d(e),k()},get trapFocus(){return f()},set trapFocus(e=!0){f(e),k()},get preventScroll(){return p()},set preventScroll(e=!1){p(e),k()},get customAnchor(){return m()},set customAnchor(e=null){m(e),k()},get style(){return h()},set style(e){h(e),k()}},S=z(),C=P(S),ee=e=>{ck(e,mo(()=>L(v),()=>_.popperProps,{get ref(){return _.opts.ref},get enabled(){return _.root.opts.open.current},get id(){return o()},get trapFocus(){return L(y)},get preventScroll(){return p()},loop:!0,forceMount:!0,get customAnchor(){return m()},onOpenAutoFocus:b,get onCloseAutoFocus(){return l()},get shouldRender(){return _.shouldRender},popper:(e,t)=>{let n=()=>t?.().props,a=()=>t?.().wrapperProps,o=A(()=>Bx(n(),{style:pO(`popover`)},{style:h()}));var s=z(),c=P(s),l=e=>{var t=z(),n=P(t);{let e=A(()=>({props:L(o),wrapperProps:a(),..._.snippetProps}));H(n,r,()=>L(e))}B(e,t)},u=e=>{var t=Xk();Ja(t,()=>({...a()}));var n=N(t);Ja(n,()=>({...L(o)})),H(N(n),()=>i()??w),E(n),E(t),B(e,t)};U(c,e=>{r()?e(l):e(u,-1)}),B(e,s)},$$slots:{popper:!0}}))},te=e=>{sk(e,mo(()=>L(v),()=>_.popperProps,{get ref(){return _.opts.ref},get open(){return _.root.opts.open.current},get id(){return o()},get trapFocus(){return L(y)},get preventScroll(){return p()},loop:!0,forceMount:!1,get customAnchor(){return m()},onOpenAutoFocus:b,get onCloseAutoFocus(){return l()},get shouldRender(){return _.shouldRender},popper:(e,t)=>{let n=()=>t?.().props,a=()=>t?.().wrapperProps,o=A(()=>Bx(n(),{style:pO(`popover`)},{style:h()}));var s=z(),c=P(s),l=e=>{var t=z(),n=P(t);{let e=A(()=>({props:L(o),wrapperProps:a(),..._.snippetProps}));H(n,r,()=>L(e))}B(e,t)},u=e=>{var t=Zk();Ja(t,()=>({...a()}));var n=N(t);Ja(n,()=>({...L(o)})),H(N(n),()=>i()??w),E(n),E(t),B(e,t)};U(c,e=>{r()?e(l):e(u,-1)}),B(e,s)},$$slots:{popper:!0}}))};return U(C,e=>{s()?e(ee):s()||e(te,1)}),B(e,S),O(x)}q(Qk,{child:{},children:{},ref:{},id:{},forceMount:{},onOpenAutoFocus:{},onCloseAutoFocus:{},onEscapeKeydown:{},onInteractOutside:{},trapFocus:{},preventScroll:{},customAnchor:{},style:{}},[],[],{mode:`open`});var $k=R(`<button><!></button>`);function eA(e,t){let n=gi();D(t,!0);let r=K(t,`children`,7),i=K(t,`child`,7),a=K(t,`id`,23,()=>uC(n)),o=K(t,`ref`,15,null),s=K(t,`type`,7,`button`),c=K(t,`disabled`,7,!1),l=K(t,`openOnHover`,7,!1),u=K(t,`openDelay`,7,700),d=K(t,`closeDelay`,7,300),f=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`children`,`child`,`id`,`ref`,`type`,`disabled`,`openOnHover`,`openDelay`,`closeDelay`]),p=Jk.create({id:Q(()=>a()),ref:Q(()=>o(),e=>o(e)),disabled:Q(()=>!!c()),openOnHover:Q(()=>l()),openDelay:Q(()=>u()),closeDelay:Q(()=>d())}),m=A(()=>Bx(f,p.props,{type:s()}));return ZO(e,{get id(){return a()},get ref(){return p.opts.ref},children:(e,t)=>{var n=z(),a=P(n),o=e=>{var t=z();H(P(t),i,()=>({props:L(m)})),B(e,t)},s=e=>{var t=$k();Ja(t,()=>({...L(m)})),H(N(t),()=>r()??w),E(t),B(e,t)};U(a,e=>{i()?e(o):e(s,-1)}),B(e,n)},$$slots:{default:!0}}),O({get children(){return r()},set children(e){r(e),k()},get child(){return i()},set child(e){i(e),k()},get id(){return a()},set id(e=uC(n)){a(e),k()},get ref(){return o()},set ref(e=null){o(e),k()},get type(){return s()},set type(e=`button`){s(e),k()},get disabled(){return c()},set disabled(e=!1){c(e),k()},get openOnHover(){return l()},set openOnHover(e=!1){l(e),k()},get openDelay(){return u()},set openDelay(e=700){u(e),k()},get closeDelay(){return d()},set closeDelay(e=300){d(e),k()}})}q(eA,{children:{},child:{},id:{},ref:{},type:{},disabled:{},openOnHover:{},openDelay:{},closeDelay:{}},[],[],{mode:`open`});function tA(e,t){D(t,!0);let n=K(t,`open`,15,!1),r=K(t,`onOpenChange`,7,$),i=K(t,`onOpenChangeComplete`,7,$),a=K(t,`children`,7);pC.create({variant:Q(()=>`dialog`),open:Q(()=>n(),e=>{n(e),r()(e)}),onOpenChangeComplete:Q(()=>i())});var o={get open(){return n()},set open(e=!1){n(e),k()},get onOpenChange(){return r()},set onOpenChange(e=$){r(e),k()},get onOpenChangeComplete(){return i()},set onOpenChangeComplete(e=$){i(e),k()},get children(){return a()},set children(e){a(e),k()}},s=z();return H(P(s),()=>a()??w),B(e,s),O(o)}q(tA,{open:{},onOpenChange:{},onOpenChangeComplete:{},children:{}},[],[],{mode:`open`});var nA=R(`<button><!></button>`);function rA(e,t){let n=gi();D(t,!0);let r=K(t,`children`,7),i=K(t,`child`,7),a=K(t,`id`,23,()=>uC(n)),o=K(t,`ref`,15,null),s=K(t,`disabled`,7,!1),c=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`children`,`child`,`id`,`ref`,`disabled`]),l=mC.create({variant:Q(()=>`close`),id:Q(()=>a()),ref:Q(()=>o(),e=>o(e)),disabled:Q(()=>!!s())}),u=A(()=>Bx(c,l.props));var d={get children(){return r()},set children(e){r(e),k()},get child(){return i()},set child(e){i(e),k()},get id(){return a()},set id(e=uC(n)){a(e),k()},get ref(){return o()},set ref(e=null){o(e),k()},get disabled(){return s()},set disabled(e=!1){s(e),k()}},f=z(),p=P(f),m=e=>{var t=z();H(P(t),i,()=>({props:L(u)})),B(e,t)},h=e=>{var t=nA();Ja(t,()=>({...L(u)})),H(N(t),()=>r()??w),E(t),B(e,t)};return U(p,e=>{i()?e(m):e(h,-1)}),B(e,f),O(d)}q(rA,{children:{},child:{},id:{},ref:{},disabled:{}},[],[],{mode:`open`});var iA=R(`<!> <!>`,1),aA=R(`<!> <div><!></div>`,1);function oA(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>uC(n)),i=K(t,`children`,7),a=K(t,`child`,7),o=K(t,`ref`,15,null),s=K(t,`forceMount`,7,!1),c=K(t,`onCloseAutoFocus`,7,$),l=K(t,`onOpenAutoFocus`,7,$),u=K(t,`onEscapeKeydown`,7,$),d=K(t,`onInteractOutside`,7,$),f=K(t,`trapFocus`,7,!0),p=K(t,`preventScroll`,7,!0),m=K(t,`restoreScrollDelay`,7,null),h=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`children`,`child`,`ref`,`forceMount`,`onCloseAutoFocus`,`onOpenAutoFocus`,`onEscapeKeydown`,`onInteractOutside`,`trapFocus`,`preventScroll`,`restoreScrollDelay`]),g=_C.create({id:Q(()=>r()),ref:Q(()=>o(),e=>o(e))}),_=A(()=>Bx(h,g.props));var v={get id(){return r()},set id(e=uC(n)){r(e),k()},get children(){return i()},set children(e){i(e),k()},get child(){return a()},set child(e){a(e),k()},get ref(){return o()},set ref(e=null){o(e),k()},get forceMount(){return s()},set forceMount(e=!1){s(e),k()},get onCloseAutoFocus(){return c()},set onCloseAutoFocus(e=$){c(e),k()},get onOpenAutoFocus(){return l()},set onOpenAutoFocus(e=$){l(e),k()},get onEscapeKeydown(){return u()},set onEscapeKeydown(e=$){u(e),k()},get onInteractOutside(){return d()},set onInteractOutside(e=$){d(e),k()},get trapFocus(){return f()},set trapFocus(e=!0){f(e),k()},get preventScroll(){return p()},set preventScroll(e=!0){p(e),k()},get restoreScrollDelay(){return m()},set restoreScrollDelay(e=null){m(e),k()}},y=z(),b=P(y),x=e=>{DT(e,{get ref(){return g.opts.ref},loop:!0,get trapFocus(){return f()},get enabled(){return g.root.opts.open.current},get onOpenAutoFocus(){return l()},get onCloseAutoFocus(){return c()},focusScope:(e,t)=>{let n=()=>t?.().props;wT(e,mo(()=>L(_),{get enabled(){return g.root.opts.open.current},get ref(){return g.opts.ref},onEscapeKeydown:e=>{u()(e),!e.defaultPrevented&&g.root.handleClose()},children:(e,t)=>{xT(e,mo(()=>L(_),{get ref(){return g.opts.ref},get enabled(){return g.root.opts.open.current},onInteractOutside:e=>{d()(e),!e.defaultPrevented&&g.root.handleClose()},children:(e,t)=>{NT(e,mo(()=>L(_),{get ref(){return g.opts.ref},get enabled(){return g.root.opts.open.current},children:(e,t)=>{var r=z(),o=P(r),s=e=>{var t=iA(),r=P(t),i=e=>{KT(e,{get preventScroll(){return p()},get restoreScrollDelay(){return m()}})};U(r,e=>{g.root.opts.open.current&&e(i)});var o=F(r,2);{let e=A(()=>({props:Bx(L(_),n()),...g.snippetProps}));H(o,a,()=>L(e))}B(e,t)},c=e=>{var t=aA(),r=P(t);KT(r,{get preventScroll(){return p()}});var a=F(r,2);Ja(a,e=>({...e}),[()=>Bx(L(_),n())]),H(N(a),()=>i()??w),E(a),B(e,t)};U(o,e=>{a()?e(s):e(c,-1)}),B(e,r)},$$slots:{default:!0}}))},$$slots:{default:!0}}))},$$slots:{default:!0}}))},$$slots:{focusScope:!0}})};return U(b,e=>{(g.shouldRender||s())&&e(x)}),B(e,y),O(v)}q(oA,{id:{},children:{},child:{},ref:{},forceMount:{},onCloseAutoFocus:{},onOpenAutoFocus:{},onEscapeKeydown:{},onInteractOutside:{},trapFocus:{},preventScroll:{},restoreScrollDelay:{}},[],[],{mode:`open`});function sA(e,t){D(t,!0);let n=K(t,`open`,15,!1),r=K(t,`dir`,7,`ltr`),i=K(t,`onOpenChange`,7,$),a=K(t,`onOpenChangeComplete`,7,$),o=K(t,`_internal_variant`,7,`dropdown-menu`),s=K(t,`children`,7),c=rT.create({variant:Q(()=>o()),dir:Q(()=>r()),onClose:()=>{n(!1),i()(!1)}});return iT.create({open:Q(()=>n(),e=>{n(e),i()(e)}),onOpenChangeComplete:Q(()=>a())},c),DO(e,{children:(e,t)=>{var n=z();H(P(n),()=>s()??w),B(e,n)},$$slots:{default:!0}}),O({get open(){return n()},set open(e=!1){n(e),k()},get dir(){return r()},set dir(e=`ltr`){r(e),k()},get onOpenChange(){return i()},set onOpenChange(e=$){i(e),k()},get onOpenChangeComplete(){return a()},set onOpenChangeComplete(e=$){a(e),k()},get _internal_variant(){return o()},set _internal_variant(e=`dropdown-menu`){o(e),k()},get children(){return s()},set children(e){s(e),k()}})}q(sA,{open:{},dir:{},onOpenChange:{},onOpenChangeComplete:{},_internal_variant:{},children:{}},[],[],{mode:`open`});var cA=R(`<div><div><!></div></div>`),lA=R(`<div><div><!></div></div>`);function uA(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>uC(n)),i=K(t,`child`,7),a=K(t,`children`,7),o=K(t,`ref`,15,null),s=K(t,`loop`,7,!0),c=K(t,`onInteractOutside`,7,$),l=K(t,`onEscapeKeydown`,7,$),u=K(t,`onCloseAutoFocus`,7,$),d=K(t,`forceMount`,7,!1),f=K(t,`trapFocus`,7,!1),p=K(t,`style`,7),m=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`child`,`children`,`ref`,`loop`,`onInteractOutside`,`onEscapeKeydown`,`onCloseAutoFocus`,`forceMount`,`trapFocus`,`style`]),h=aT.create({id:Q(()=>r()),loop:Q(()=>s()),ref:Q(()=>o(),e=>o(e)),onCloseAutoFocus:Q(()=>u())}),g=A(()=>Bx(m,h.props));function _(e){if(h.handleInteractOutside(e),!e.defaultPrevented&&(c()(e),!e.defaultPrevented)){if(e.target&&e.target instanceof Element){let t=`[${h.parentMenu.root.getBitsAttr(`sub-content`)}]`;if(e.target.closest(t))return}h.parentMenu.onClose()}}function v(e){l()(e),!e.defaultPrevented&&h.parentMenu.onClose()}var y={get id(){return r()},set id(e=uC(n)){r(e),k()},get child(){return i()},set child(e){i(e),k()},get children(){return a()},set children(e){a(e),k()},get ref(){return o()},set ref(e=null){o(e),k()},get loop(){return s()},set loop(e=!0){s(e),k()},get onInteractOutside(){return c()},set onInteractOutside(e=$){c(e),k()},get onEscapeKeydown(){return l()},set onEscapeKeydown(e=$){l(e),k()},get onCloseAutoFocus(){return u()},set onCloseAutoFocus(e=$){u(e),k()},get forceMount(){return d()},set forceMount(e=!1){d(e),k()},get trapFocus(){return f()},set trapFocus(e=!1){f(e),k()},get style(){return p()},set style(e){p(e),k()}},b=z(),x=P(b),S=e=>{ck(e,mo(()=>L(g),()=>h.popperProps,{get ref(){return h.opts.ref},get enabled(){return h.parentMenu.opts.open.current},onInteractOutside:_,onEscapeKeydown:v,get trapFocus(){return f()},get loop(){return s()},forceMount:!0,get id(){return r()},get shouldRender(){return h.shouldRender},popper:(e,t)=>{let n=()=>t?.().props,r=()=>t?.().wrapperProps,o=A(()=>Bx(n(),{style:pO(`dropdown-menu`)},{style:p()}));var s=z(),c=P(s),l=e=>{var t=z(),n=P(t);{let e=A(()=>({props:L(o),wrapperProps:r(),...h.snippetProps}));H(n,i,()=>L(e))}B(e,t)},u=e=>{var t=cA();Ja(t,()=>({...r()}));var n=N(t);Ja(n,()=>({...L(o)})),H(N(n),()=>a()??w),E(n),E(t),B(e,t)};U(c,e=>{i()?e(l):e(u,-1)}),B(e,s)},$$slots:{popper:!0}}))},C=e=>{sk(e,mo(()=>L(g),()=>h.popperProps,{get ref(){return h.opts.ref},get open(){return h.parentMenu.opts.open.current},onInteractOutside:_,onEscapeKeydown:v,get trapFocus(){return f()},get loop(){return s()},forceMount:!1,get id(){return r()},get shouldRender(){return h.shouldRender},popper:(e,t)=>{let n=()=>t?.().props,r=()=>t?.().wrapperProps,o=A(()=>Bx(n(),{style:pO(`dropdown-menu`)},{style:p()}));var s=z(),c=P(s),l=e=>{var t=z(),n=P(t);{let e=A(()=>({props:L(o),wrapperProps:r(),...h.snippetProps}));H(n,i,()=>L(e))}B(e,t)},u=e=>{var t=lA();Ja(t,()=>({...r()}));var n=N(t);Ja(n,()=>({...L(o)})),H(N(n),()=>a()??w),E(n),E(t),B(e,t)};U(c,e=>{i()?e(l):e(u,-1)}),B(e,s)},$$slots:{popper:!0}}))};return U(x,e=>{d()?e(S):d()||e(C,1)}),B(e,b),O(y)}q(uA,{id:{},child:{},children:{},ref:{},loop:{},onInteractOutside:{},onEscapeKeydown:{},onCloseAutoFocus:{},forceMount:{},trapFocus:{},style:{}},[],[],{mode:`open`});var dA=R(`<button><!></button>`);function fA(e,t){let n=gi();D(t,!0);let r=K(t,`id`,23,()=>uC(n)),i=K(t,`ref`,15,null),a=K(t,`child`,7),o=K(t,`children`,7),s=K(t,`disabled`,7,!1),c=K(t,`type`,7,`button`),l=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`id`,`ref`,`child`,`children`,`disabled`,`type`]),u=mT.create({id:Q(()=>r()),disabled:Q(()=>s()??!1),ref:Q(()=>i(),e=>i(e))}),d=A(()=>Bx(l,u.props,{type:c()}));return ZO(e,{get id(){return r()},get ref(){return u.opts.ref},children:(e,t)=>{var n=z(),r=P(n),i=e=>{var t=z();H(P(t),a,()=>({props:L(d)})),B(e,t)},s=e=>{var t=dA();Ja(t,()=>({...L(d)})),H(N(t),()=>o()??w),E(t),B(e,t)};U(r,e=>{a()?e(i):e(s,-1)}),B(e,n)},$$slots:{default:!0}}),O({get id(){return r()},set id(e=uC(n)){r(e),k()},get ref(){return i()},set ref(e=null){i(e),k()},get child(){return a()},set child(e){a(e),k()},get children(){return o()},set children(e){o(e),k()},get disabled(){return s()},set disabled(e=!1){s(e),k()},get type(){return c()},set type(e=`button`){c(e),k()}})}q(fA,{id:{},ref:{},child:{},children:{},disabled:{},type:{}},[],[],{mode:`open`});var pA=MS({component:`label`,parts:[`root`]}),mA=class e{static create(t){return new e(t)}opts;attachment;constructor(e){this.opts=e,this.attachment=wS(this.opts.ref),this.onmousedown=this.onmousedown.bind(this)}onmousedown(e){e.detail>1&&e.preventDefault()}#e=A(()=>({id:this.opts.id.current,[pA.root]:``,onmousedown:this.onmousedown,...this.attachment}));get props(){return L(this.#e)}set props(e){M(this.#e,e)}},hA=R(`<label><!></label>`);function gA(e,t){let n=gi();D(t,!0);let r=K(t,`children`,7),i=K(t,`child`,7),a=K(t,`id`,23,()=>uC(n)),o=K(t,`ref`,15,null),s=K(t,`for`,7),c=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`children`,`child`,`id`,`ref`,`for`]),l=mA.create({id:Q(()=>a()),ref:Q(()=>o(),e=>o(e))}),u=A(()=>Bx(c,l.props,{for:s()}));var d={get children(){return r()},set children(e){r(e),k()},get child(){return i()},set child(e){i(e),k()},get id(){return a()},set id(e=uC(n)){a(e),k()},get ref(){return o()},set ref(e=null){o(e),k()},get for(){return s()},set for(e){s(e),k()}},f=z(),p=P(f),m=e=>{var t=z();H(P(t),i,()=>({props:L(u)})),B(e,t)},h=e=>{var t=hA();Ja(t,()=>({...L(u),for:s()})),H(N(t),()=>r()??w),E(t),B(e,t)};return U(p,e=>{i()?e(m):e(h,-1)}),B(e,f),O(d)}q(gA,{children:{},child:{},id:{},ref:{},for:{}},[],[],{mode:`open`});function _A(e,t){D(t,!0);let n=K(t,`open`,15,!1),r=K(t,`onOpenChange`,7,$),i=K(t,`onOpenChangeComplete`,7,$),a=K(t,`children`,7);return qk.create({open:Q(()=>n(),e=>{n(e),r()(e)}),onOpenChangeComplete:Q(()=>i())}),DO(e,{children:(e,t)=>{var n=z();H(P(n),()=>a()??w),B(e,n)},$$slots:{default:!0}}),O({get open(){return n()},set open(e=!1){n(e),k()},get onOpenChange(){return r()},set onOpenChange(e=$){r(e),k()},get onOpenChangeComplete(){return i()},set onOpenChangeComplete(e=$){i(e),k()},get children(){return a()},set children(e){a(e),k()}})}q(_A,{open:{},onOpenChange:{},onOpenChangeComplete:{},children:{}},[],[],{mode:`open`});function vA(e){return e<.5?8*e**4:-8*(e-1)**4+1}function yA(e){return e**4}function bA(e){return(e-1)**3*(1-e)+1}function xA(e){return--e*e*e*e*e+1}var SA=e=>e;function CA(e){let t=e-1;return t*t*t+1}function wA(e){let t=typeof e==`string`&&e.match(/^\s*(-?[\d.]+)([^\s]*)\s*$/);return t?[parseFloat(t[1]),t[2]||`px`]:[e,`px`]}function TA(e,{delay:t=0,duration:n=400,easing:r=SA}={}){let i=+getComputedStyle(e).opacity;return{delay:t,duration:n,easing:r,css:e=>`opacity: ${e*i}`}}function EA(e,{delay:t=0,duration:n=400,easing:r=CA,x:i=0,y:a=0,opacity:o=0}={}){let s=getComputedStyle(e),c=+s.opacity,l=s.transform===`none`?``:s.transform,u=c*(1-o),[d,f]=wA(i),[p,m]=wA(a);return{delay:t,duration:n,easing:r,css:(e,t)=>`
|
|
574
574
|
transform: ${l} translate(${(1-e)*d}${f}, ${(1-e)*p}${m});
|
|
575
|
-
opacity: ${c-u*t}`}}var
|
|
575
|
+
opacity: ${c-u*t}`}}var DA=R(`<div class="embed-alva embed-alva--question-box"><div class="embed-alva__body"><div class="embed-alva__row"><p class="embed-alva__description">Möchten Sie an der Umfrage teilnehmen? <span class="embed-alva__time">Dauer: ca. 5 Minuten.</span></p> <a class="btn btn--primary" target="_blank" rel="noopener noreferrer"><span class="btn__label">Umfrage ausfüllen</span></a> <button class="embed-alva__close transition-colors"><span class="sr-only">Schliessen</span> <!></button></div></div></div>`);function OA(e,t){D(t,!0);let n=K(t,`belowScore`,7),r=j(void 0);tr(()=>{Xr(()=>{M(r,kA.getContext(),!0)})});let i=()=>{kA.updateContext(e=>({...e,experimentState:`completed-without-survey`}))},a=()=>kA.updateContext(e=>({...e,experimentState:`completed`})),o={certainty:`https://forms.office.com/e/r2xanSsUsy`,uncertainty:`https://forms.office.com/e/5C9VAhrpWS`,control:`https://forms.office.com/e/i8Mf5t4QVZ`,"<unassigned>":``},s=(e,t)=>t.enabled?EA(e,t):{duration:0};var c={get belowScore(){return n()},set belowScore(e){n(e),k()}},l=z(),u=P(l),d=e=>{kC(e,{get to(){return Z.targets.surveyPortal},children:(e,t)=>{var c=z(),l=P(c),u=e=>{var t=z(),c=P(t),l=e=>{var t=DA(),c=N(t),l=N(c),u=F(N(l),2),d=F(u,2);_b(F(N(d),2),{name:`dismiss`}),E(d),E(l),E(c),E(t),I(()=>G(u,`href`,o[L(r).assignedGroup])),ai(`click`,u,a),ai(`click`,d,i),fa(5,t,()=>s,()=>({enabled:n(),duration:300,delay:1e3,y:30})),B(e,t)};U(c,e=>{(n()?L(r).nextShowCount===3:L(r).nextShowCount>=3)&&kA.currentContext.experimentState===`in-progress`&&e(l)}),B(e,t)};U(l,e=>{kA.currentContext.isDesktop&&L(r).experimentState===`in-progress`&&e(u)}),B(e,c)},$$slots:{default:!0}})};return U(u,e=>{Z.targets.surveyPortal&&e(d)}),B(e,l),O(c)}oi([`click`]),q(OA,{belowScore:{}},[],[],{mode:`open`});var kA=new Vy({initialValue:{isDesktop:!!(new cv(`(hover: hover) and (pointer: fine)`,!1).current||navigator.userAgentData?.mobile===!1),experimentState:`new`,assignedGroup:`<unassigned>`,nextLevel:`<unassigned>`,nextShowCount:-1}}),AA=e=>{let t=new Uint32Array(1);return crypto.getRandomValues(t),e[t[0]%e.length]},jA=()=>AA([`certainty`,`uncertainty`,`control`]),MA=()=>AA([`low`,`medium`,`high`]),NA=R(`<button class="debug-btn svelte-yb76lo">Reset</button>`),PA=R(`<div class="debug-panel svelte-yb76lo"><pre class="svelte-yb76lo"><code class="svelte-yb76lo"> </code></pre> <!></div>`),FA=R(`<div class="debug svelte-yb76lo"><!> <button class="debug-toggle svelte-yb76lo"> </button></div>`),IA=R(`<div class="embed-alva svelte-yb76lo"><div class="embed-alva__body svelte-yb76lo"><button class="embed-alva__close transition-colors svelte-yb76lo"><span class="sr-only svelte-yb76lo">Schliessen</span> <!></button> <p class="embed-alva__title svelte-yb76lo">Helfen Sie uns, Alva zu verbessern!</p> <p class="embed-alva__description svelte-yb76lo">Nehmen Sie an einer kurzen wissenschaftlichen Befragung teil (ca. 5 Min. im Anschluss an Ihre Nutzung). <br class="svelte-yb76lo"/> <a href="#experiment-info" class="embed-alva__link svelte-yb76lo">Mehr erfahren</a></p> <div class="embed-alva__actions svelte-yb76lo"><button class="btn btn--primary svelte-yb76lo"><span class="btn__label svelte-yb76lo">Ja, mitmachen</span></button> <button class="btn btn--secondary svelte-yb76lo"><span class="btn__label svelte-yb76lo">Nein, danke</span></button></div></div></div>`),LA=R(`<!> <!>`,1),RA=R(`<!> <!>`,1),zA={hash:`svelte-yb76lo`,code:`.chat-app .message--bot:has(+ .message--bot) {padding-bottom:0;}
|
|
576
576
|
/* Alva init embed styles */
|
|
577
577
|
/* Debug panel */.debug.svelte-yb76lo {display:flex;z-index:100000;position:fixed;top:0;left:20px;flex-direction:column;align-items:start;}.debug-panel.svelte-yb76lo {max-width:320px;padding:var(--spacer-10);border-radius:0 0 var(--spacer-6) 0;background-color:#68a518;color:var(--color-grey-0);font-size:var(--base-font-size-xs);}.debug-panel.svelte-yb76lo pre:where(.svelte-yb76lo) {margin:0;white-space:pre-wrap;word-break:break-word;}.debug-btn.svelte-yb76lo {width:100%;margin-top:var(--spacer-4);padding:var(--spacer-4) var(--spacer-10);border:1px solid var(--color-grey-0);border-radius:var(--spacer-4);background-color:#84cf23;color:var(--color-grey-0);font-size:var(--base-font-size-xs);}.debug-toggle.svelte-yb76lo {padding:var(--spacer-1) var(--spacer-10);border:none;border-radius:0 0 var(--spacer-4) var(--spacer-4);background-color:#68a518;color:var(--color-grey-0);font-size:var(--base-font-size-xs);line-height:var(--base-line-height-tight);}.embed-alva {padding:0;overflow:hidden;gap:2px;border-radius:var(--base-border-radius);background:var(--alva-gradient-card); /* stylelint-disable-line */background-position-x:0%;background-size:240%;transition:height 0.4s var(--default-transition-timing-function);&:after,
|
|
578
578
|
&:before {display:none;}}.embed-alva--question-box {box-shadow:0 1.5rem 1rem -0.5rem rgb(245 245 245 / 0.7);font-size:var(--base-font-size-body);}.embed-alva--question-box .btn {margin-right:1.2rem;padding:0.5rem 1.3rem;}.embed-alva__row {display:flex;flex-direction:row;align-items:center;gap:10px;}.embed-alva__body {position:relative;padding:var(--spacer-r-24) var(--spacer-r-28);}.embed-alva__close {position:absolute;top:var(--spacer-8);right:var(--spacer-8);padding:var(--spacer-4);border:none;background:transparent;color:var(--anchor-color);&:hover {color:var(--anchor-hover-color);}}.embed-alva__time {opacity:0.8;}.embed-alva__title {margin:0 0 var(--spacer-4);
|
|
579
|
-
/* To not clash with x */padding-right:1rem;padding-bottom:0.8rem;color:var(--card-color);font-weight:var(--base-font-weight-bold);line-height:var(--base-line-height-tight);}.embed-alva__description {margin:0;text-wrap:balance;}.embed-alva__link {display:inline-block;color:var(--anchor-color);text-decoration:underline;&:hover {color:var(--anchor-hover-color);}}.embed-alva__actions {display:flex;margin-top:var(--spacer-r-20);gap:var(--spacer-r-8);}.embed-alva__actions .btn__label {font-size:var(--base-font-size-sm);}`};function
|
|
579
|
+
/* To not clash with x */padding-right:1rem;padding-bottom:0.8rem;color:var(--card-color);font-weight:var(--base-font-weight-bold);line-height:var(--base-line-height-tight);}.embed-alva__description {margin:0;text-wrap:balance;}.embed-alva__link {display:inline-block;color:var(--anchor-color);text-decoration:underline;&:hover {color:var(--anchor-hover-color);}}.embed-alva__actions {display:flex;margin-top:var(--spacer-r-20);gap:var(--spacer-r-8);}.embed-alva__actions .btn__label {font-size:var(--base-font-size-sm);}`};function BA(e,t){D(t,!0),ga(e,zA),tr(()=>{Xr(()=>{kA.setContextVersion(Z.data.chatConfig.contextVersion)})});let n=j(!1),r=j(void 0);Ii(()=>{if(kA.currentContext.experimentState===`new`||kA.currentContext.experimentState===`in-progress`&&kA.currentContext.nextShowCount>=3){let e=Z.targets.scrollContainer;e&&setTimeout(()=>Kb(e,0,600,`scrollTop`,vA),100)}});let i=(e,t)=>{e.style.height=`${e.offsetHeight}px`,t(),qr().then(()=>{let t=e.scrollHeight;e.style.height=`${t}px`,e.addEventListener(`transitionend`,()=>e.style.height=``,{once:!0})})},a=()=>{kA.updateContext(e=>({...e,experimentState:`denied`})),Z.targets.chatInput?.focus()},o=()=>{kv.success(`Vielen Dank für Ihre Teilnahme!`,{unstyled:!0,duration:4e3,classes:{toast:`toast`}}),L(r)?i(L(r),()=>kA.updateContext(e=>({...e,experimentState:`in-progress`,assignedGroup:jA(),nextShowCount:1,nextLevel:MA()}))):kA.updateContext(e=>({...e,experimentState:`in-progress`,assignedGroup:jA(),nextShowCount:1,nextLevel:MA()}))};var s=RA(),c=P(s),l=e=>{var t=LA(),i=P(t),s=e=>{kC(e,{get to(){return Z.targets.portals},children:(e,t)=>{var r=FA(),i=N(r),a=e=>{var t=PA(),n=N(t),r=N(n),i=N(r,!0);E(r),E(n);var a=F(n,2),o=e=>{var t=NA();ai(`click`,t,()=>kA.resetContext()),B(e,t)};U(a,e=>{kA.currentContext.experimentState!==`new`&&e(o)}),E(t),I(e=>V(i,e),[()=>JSON.stringify(kA.currentContext,null,2)]),B(e,t)};U(i,e=>{L(n)&&e(a)});var o=F(i,2),s=N(o,!0);E(o),E(r),I(()=>V(s,L(n)?`▲ close`:`▼ context`)),ai(`click`,o,()=>M(n,!L(n))),B(e,r)},$$slots:{default:!0}})};U(i,e=>{window.location.origin.endsWith(`.dev.cluster.liipgpt.ch`)&&Z.targets.portals&&e(s)});var c=F(i,2),l=e=>{var t=IA(),n=N(t),i=N(n);_b(F(N(i),2),{name:`dismiss`}),E(i);var s=F(i,6),c=N(s),l=F(c,2);E(s),E(n),E(t),so(t,e=>M(r,e),()=>L(r)),ai(`click`,i,a),ai(`click`,c,o),ai(`click`,l,a),B(e,t)};U(c,e=>{kA.currentContext.experimentState===`new`&&e(l)}),B(e,t)};U(c,e=>{kA.currentContext.isDesktop&&e(l)}),OA(F(c,2),{}),B(e,s),O()}oi([`click`]),q(BA,{},[],[],{mode:`open`});var VA=R(`<p class="embed-alva-score svelte-16h2wiv"><span class="embed-alva-score__separator svelte-16h2wiv"></span> </p>`),HA=R(`<p class="embed-alva-score svelte-16h2wiv"><span class="embed-alva-score__separator svelte-16h2wiv"></span> </p>`),UA=R(`<!> <!>`,1),WA={hash:`svelte-16h2wiv`,code:`
|
|
580
580
|
@value container-xs, container-sm, container-md, container-lg, container-inner-xs, container-inner-sm, container-inner-md, container-inner-lg from '../css/viewports.css';.embed-alva-score.svelte-16h2wiv {display:flex;flex-direction:column;margin-top:calc(var(--spacer-r-24) * -1);color:var(--card-color);font-weight:var(--base-font-weight-normal);font-size:var(--base-font-size-md); /* stylelint-disable-line */line-height:var(--base-line-height-tight);text-align:right;
|
|
581
581
|
|
|
582
582
|
@container chat-container (min-width: 640px) {margin-top:calc((var(--spacer-20) + var(--spacer-r-24)) * -1);
|
|
583
|
-
}}.embed-alva-score__separator.svelte-16h2wiv {display:block;align-self:flex-end;width:4.8rem;margin-top:-0.3rem;padding-bottom:0.5rem;border-top-width:var(--message-options-border-width);border-color:var(--message-options-border-color);}`};function WA(e,t){D(t,!0),ga(e,UA);let n=j(void 0);tr(()=>{Xr(()=>{M(n,OA.getContext(),!0),OA.currentContext.experimentState===`in-progress`&&OA.updateContext(e=>({...e,nextLevel:jA(),nextShowCount:e.nextShowCount+1}))})});let r={low:`Tief`,medium:`Mittel`,high:`Hoch`};var i=HA(),a=P(i),o=e=>{var t=z(),i=P(t),a=e=>{var t=z(),i=P(t),a=e=>{var t=BA(),i=F(N(t));E(t),I(()=>V(i,` Antwortsicherheit: ${r[L(n).nextLevel]??L(n).nextLevel??``}`)),B(e,t)},o=e=>{var t=VA(),i=F(N(t));E(t),I(()=>V(i,` Antwortunsicherheit: ${r[L(n).nextLevel]??L(n).nextLevel??``}`)),B(e,t)};U(i,e=>{L(n).assignedGroup===`certainty`?e(a):L(n).assignedGroup===`uncertainty`&&e(o,1)}),B(e,t)};U(i,e=>{L(n).nextShowCount<=2&&e(a)}),B(e,t)};U(a,e=>{OA.currentContext.isDesktop&&L(n).experimentState===`in-progress`&&e(o)}),DA(F(a,2),{belowScore:!0}),B(e,i),O()}q(WA,{},[],[],{mode:`open`});function GA(e,t){D(t,!0);let n=K(t,`href`,7),r=K(t,`target`,7),i=K(t,`onclick`,7),a=K(t,`className`,23,()=>[]),o=K(t,`isStandalone`,7,!1),s=K(t,`children`,7),c=K(t,`type`,7,`button`),l=K(t,`use`,7),u=K(t,`class`,7),d=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`href`,`target`,`onclick`,`className`,`isStandalone`,`children`,`type`,`use`,`class`]),f=A(()=>n()?`a`:`button`),p=A(()=>[...Array.isArray(a())?a():a()?[a()]:[],...u()?[u()]:[]]),m=()=>({}),h=A(()=>l()??m);var g={get href(){return n()},set href(e){n(e),k()},get target(){return r()},set target(e){r(e),k()},get onclick(){return i()},set onclick(e){i(e),k()},get className(){return a()},set className(e=[]){a(e),k()},get isStandalone(){return o()},set isStandalone(e=!1){o(e),k()},get children(){return s()},set children(e){s(e),k()},get type(){return c()},set type(e=`button`){c(e),k()},get use(){return l()},set use(e){l(e),k()},get class(){return u()},set class(e){u(e),k()}},_=z();return ma(P(_),()=>L(f),!1,(e,t)=>{_a(e,e=>L(h)?.(e)),Ja(e,()=>({...d,onclick:n()?void 0:i(),type:n()?void 0:c(),href:n(),role:n()?`link`:`button`,target:n()?r():void 0,class:L(p),[Pa]:{"open-button--standalone":o()}}));var a=z();H(P(a),s),B(t,a)}),B(e,_),O(g)}q(GA,{href:{},target:{},onclick:{},className:{},isStandalone:{},children:{},type:{},use:{},class:{}},[],[],{mode:`open`});function KA(e,t){D(t,!0);let n=K(t,`html`,7),r=K(t,`oncomplete`,7),i=j(``),a=null;Ii(()=>{if(!n()){M(i,``),r()?.();return}let e=y_(n());if(e.length<=1){M(i,n(),!0),r()?.();return}let t=0,o=()=>{if(a=null,t>=e.length)return;M(i,L(i)+e[t]);let n=b_(e[t]);t++,t<e.length?a=setTimeout(o,n):r()?.()};return o(),()=>{a!==null&&(clearTimeout(a),a=null)}});var o={get html(){return n()},set html(e){n(e),k()},get oncomplete(){return r()},set oncomplete(e){r(e),k()}},s=z();return na(P(s),()=>L(i)),B(e,s),O(o)}q(KA,{html:{},oncomplete:{}},[],[],{mode:`open`});var qA=R(`<p class="embed-buttons__caption"><!></p>`),JA=R(`<span class="btn__label"></span> <!>`,1),YA=R(`<div class="embed-buttons"><!> <div class="embed-buttons__buttons"></div></div>`);function XA(e,t){D(t,!0);let n=K(t,`data`,7);var r={get data(){return n()},set data(e){n(e),k()}},i=YA(),a=N(i),o=e=>{var t=qA();KA(N(t),{get html(){return n().caption}}),E(t),B(e,t)};U(a,e=>{n().caption&&e(o)});var s=F(a,2);return Xi(s,21,()=>n().buttons,Ki,(e,t)=>{{let n=A(()=>[`btn`,`btn--${L(t).variant??`primary`}`]);GA(e,{get href(){return L(t).href},get target(){return L(t).target},get className(){return L(n)},children:(e,n)=>{var r=JA(),i=P(r);na(i,()=>L(t).label,!0),E(i);var a=F(i,2),o=e=>{gb(e,{get name(){return L(t).icon}})};U(a,e=>{L(t).icon&&e(o)}),B(e,r)},$$slots:{default:!0}})}}),E(s),E(i),B(e,i),O(r)}q(XA,{data:{}},[],[],{mode:`open`});var ZA=R(`<p class="embed-combobox__caption"><!></p>`),QA=R(`<p class="embed-combobox__no-result"> </p>`),$A=R(`<div><div><!> <!> <!></div></div>`),ej=R(`<span class="btn btn--tertiary btn--square"><!> <span class="sr-only"> </span></span>`),tj=R(`<!> <!> <!>`,1),nj=R(`<div role="region"><h2 class="sr-only"> </h2> <div class="embed-combobox__combobox"><!></div></div>`),rj=R(`<div class="embed-combobox"><!> <!></div>`);function ij(e,t){D(t,!0);let n=K(t,`data`,7),r=K(t,`hideChatInput`,7),i=A(()=>Z.t),a=j(``),o=j(!1),s=j(!1),c=j(null),l=j(null),u=j(null),d=j(!1),f=NT(),p=j(10);$n(()=>{if(!L(l))return;let e=getComputedStyle(L(l)).getPropertyValue(`--embed-combobox-side-offset`).trim(),t=parseFloat(e);Number.isNaN(t)||M(p,t,!0)});let m=e=>e===0?150:180,h=e=>G_(e,Z.data.language,Z.data.chatConfig.supportedLanguages),g=A(()=>n().caption?h(n().caption):``),_=A(()=>h(n().placeholder)),v=A(()=>n().values.map(e=>({value:e.value,label:h(e.label),metadata:e.metadata}))),y=A(()=>L(a)===``?L(v):L(v).filter(e=>e.label.toLowerCase().includes(L(a).toLowerCase()))),b=e=>{let t=L(v).find(t=>t.value===e);t&&(Z.data.chatInputValue=t.label,ub.onSubmit(!1,{[n().selectorKey??`componentValue`]:t.value,...t.metadata?{scopeMetadata:t.metadata}:{}}),n().removeComponentAfterValueSelection&&M(s,!0))},x=()=>{M(d,!0),r()&&!Ay()?setTimeout(()=>{L(c)?.focus()},300):L(g)&&ub.setAriaLiveStatusMessage(L(u)?.textContent??``)};var S={get data(){return n()},set data(e){n(e),k()},get hideChatInput(){return r()},set hideChatInput(e){r(e),k()}},C=rj(),ee=N(C),te=e=>{var t=ZA();KA(N(t),{get html(){return L(g)},oncomplete:x}),E(t),so(t,e=>M(u,e),()=>L(u)),I(()=>G(t,`id`,f)),B(e,t)};U(ee,e=>{L(g)&&e(te)});var ne=F(ee,2),re=e=>{var t=nj(),n=N(t),r=N(n,!0);E(n);var l=F(n,2);W(N(l),()=>YO,(e,t)=>{t(e,{type:`single`,onOpenChange:e=>{e||M(a,``)},onValueChange:b,get open(){return L(o)},set open(e){M(o,e,!0)},children:(e,t)=>{var n=tj(),r=P(n);{let e=A(()=>L(g)?f:void 0);W(r,()=>ek,(t,n)=>{n(t,{get placeholder(){return L(_)},get"aria-describedby"(){return L(e)},onclick:()=>M(o,!0),oninput:e=>M(a,e.currentTarget.value,!0),get ref(){return L(c)},set ref(e){M(c,e,!0)}})})}var s=F(r,2);W(s,()=>OC,(e,t)=>{t(e,{get to(){return Z.targets.portals},children:(e,t)=>{var n=z(),r=P(n);{let e=(e,t)=>{let n=()=>t?.().wrapperProps,r=()=>t?.().props,a=()=>t?.().open;var o=z(),s=P(o),c=e=>{var t=$A();Ja(t,()=>({...n()}));var a=N(t);Ja(a,()=>({...r()}));var o=N(a);W(o,()=>Ck,(e,t)=>{t(e,{delay:m,children:(e,t)=>{gb(e,{name:`chevronUp`})},$$slots:{default:!0}})});var s=F(o,2);W(s,()=>_k,(e,t)=>{t(e,{children:(e,t)=>{var n=z();Xi(P(n),19,()=>L(y),(e,t)=>t+e.value,(e,t)=>{var n=z();W(P(n),()=>mk,(e,n)=>{n(e,{get value(){return L(t).value},get label(){return L(t).label},children:(e,n)=>{Ze();var r=hi();I(()=>V(r,L(t).label)),B(e,r)},$$slots:{default:!0}})}),B(e,n)},e=>{var t=QA(),n=N(t,!0);E(t),I(()=>V(n,L(i).noResultsFound)),B(e,t)}),B(e,n)},$$slots:{default:!0}})}),W(F(s,2),()=>bk,(e,t)=>{t(e,{delay:m,children:(e,t)=>{gb(e,{name:`chevronDown`})},$$slots:{default:!0}})}),E(a),E(t),fa(1,a,()=>TA,()=>({duration:300,easing:yA,y:40})),fa(2,a,()=>TA,()=>({duration:150,easing:vA,y:20})),B(e,t)};U(s,e=>{a()&&e(c)}),B(e,o)};W(r,()=>uk,(t,n)=>{n(t,{get sideOffset(){return L(p)},forceMount:!0,strategy:`absolute`,side:`bottom`,avoidCollisions:!1,child:e,$$slots:{child:!0}})})}B(e,n)},$$slots:{default:!0}})}),W(F(s,2),()=>nk,(e,t)=>{t(e,{children:(e,t)=>{var n=ej(),r=N(n);gb(r,{name:`chevronTopDown`});var a=F(r,2),o=N(a,!0);E(a),E(n),I(()=>V(o,L(i).openMenu)),B(e,n)},$$slots:{default:!0}})}),B(e,n)},$$slots:{default:!0}})}),E(l),E(t),I(()=>{Da(t,1,xa([`embed-combobox__container`,{"embed-combobox__container--hidden":L(s)}])),t.inert=L(s)?!0:void 0,G(t,`aria-hidden`,L(s)?`true`:void 0),G(t,`aria-label`,L(_)),V(r,L(_))}),fa(1,t,()=>TA,()=>({duration:400,easing:yA,y:30,delay:100})),B(e,t)};return U(ne,e=>{Z.targets.portals&&(!L(g)||L(d))&&e(re)}),E(C),so(C,e=>M(l,e),()=>L(l)),B(e,C),O(S)}q(ij,{data:{},hideChatInput:{}},[],[],{mode:`open`});var aj={buttons:XA,combobox:ij,"alva-init":zA,"alva-score-survey":WA},oj=e=>{let t=aj[e];if(!t){console.error(`No embed component found with name "${e}"`);return}return t};function sj(e,t){D(t,!0);let n=K(t,`componentName`,7),r=K(t,`data`,7),i=K(t,`hideChatInput`,7),a=A(()=>oj(n())),o=j(!1);Ii(()=>{requestAnimationFrame(()=>M(o,!0))});var s={get componentName(){return n()},set componentName(e){n(e),k()},get data(){return r()},set data(e){r(e),k()},get hideChatInput(){return i()},set hideChatInput(e){i(e),k()}},c=z(),l=P(c),u=e=>{var t=z();W(P(t),()=>L(a),(e,t)=>{t(e,{get data(){return r()},get hideChatInput(){return i()}})}),B(e,t)};return U(l,e=>{L(a)&&L(o)&&e(u)}),B(e,c),O(s)}q(sj,{componentName:{},data:{},hideChatInput:{}},[],[],{mode:`open`});var cj=R(`<div aria-hidden="true"><!></div>`);function lj(e,t){D(t,!0);let n=K(t,`class`,7),r=K(t,`isLarge`,7),i=K(t,`hide`,7,!1);var a={get class(){return n()},set class(e){n(e),k()},get isLarge(){return r()},set isLarge(e){r(e),k()},get hide(){return i()},set hide(e=!1){i(e),k()}},o=cj();let s;var c=N(o),l=e=>{var t=z();na(P(t),()=>Z.theme.svgs.avatarLarge||Z.theme.svgs.avatar),B(e,t)},u=e=>{var t=z();na(P(t),()=>Z.theme.svgs.avatar),B(e,t)};return U(c,e=>{r()?e(l):e(u,-1)}),E(o),_a(o,(e,t)=>db?.(e,t),()=>r()?`avatarLarge`:`avatar`),I(()=>s=Da(o,1,`svg svg--avatar ${n()??``}`,null,s,{"svg--avatar--hide":i()})),B(e,o),O(a)}q(lj,{class:{},isLarge:{},hide:{}},[],[],{mode:`open`});var uj=`data-references-toggle-button`,dj=R(` <!>`,1),fj=R(`<span class="btn__label"> </span>`),pj=R(`<button><!> <!></button>`),mj=R(`<span class="btn__label"> </span>`),hj=R(`<button class="btn btn--tertiary btn--square" aria-haspopup="dialog"><!> <!></button>`),gj=R(`<div class="message__bot-references"><!> <!></div>`),_j=R(`<div class="message__bot-actions"><!> <!> <!> <!></div>`),vj=R(`<!> <!>`,1),yj=R(`<div class="message__bot-layout"><!> <div class="message__bot-body"><div class="text-container"><!> <!></div> <!> <!></div></div>`),bj=R(`<div class="message__bot-layout"><!> <div class="message__bot-body"><!></div></div>`),xj=R(`<section><div class="message__content"><!></div></section>`);function Sj(e,t){D(t,!0);let n=A(()=>Z.t),r=K(t,`message`,7),i=K(t,`index`,7),a=K(t,`onmessageupdate`,7),o=K(t,`onbotmessageinit`,7),s=K(t,`onaskQuestion`,7),c=K(t,`isLast`,7,!1),l={duration:Number(Z.theme.components.message.custom?.transitionDuration)||300,delay:Number(Z.theme.components.message.custom?.transitionDelay)||0,y:Number(Z.theme.components.message.custom?.transitionY)||30,ease:yA};Xr(()=>r().type===`bot`||r().type===`component`)&&(l.delay+=Number(Z.theme.components.message.custom?.transitionBotLoadingDelay)||300);let u={duration:Number(Z.theme.components.messageOptions.custom?.transitionDuration)||300,delay:Number(Z.theme.components.messageOptions.custom?.transitionDelay)||0,y:Number(Z.theme.components.messageOptions.custom?.transitionY)||30,ease:yA},d=A(()=>r().type===`bot`?r().references.all.filter(Bb).length:0),f=A(()=>({...u,delay:u.delay+L(d)*u.duration}));$n(()=>{r()?.type===`bot`&&r().state!==`done`&&a()()}),Xr(()=>{r()?.type===`bot`&&o()()});let p=A(()=>Z.data.history.slice(0,i()+1).filter(e=>e.type===`bot`||e.type===`component`).length),m=A(()=>r().type===`bot`||r().type===`component`?L(n).ariaAnswerFromBot.replace(`{n}`,String(L(p))):`${L(n).ariaQuestionFromYou} ${(r().message?.length??0)>20?r().message.slice(0,20)+`...`:r().message}`),h=A(()=>Z.data.currentReferencesAsideId===r().id?L(n).referencesHide:L(n).referencesDisplay),g=A(()=>Z.data.chatConfig.answerForm),_=A(()=>L(g)?G_(L(g).triggerLabel,Z.data.language,Z.data.chatConfig.supportedLanguages):``),v=A(()=>r().type===`bot`&&(!!r().references?.used.length||!r().noFeedback||!!L(g)));var y={get message(){return r()},set message(e){r(e),k()},get index(){return i()},set index(e){i(e),k()},get onmessageupdate(){return a()},set onmessageupdate(e){a(e),k()},get onbotmessageinit(){return o()},set onbotmessageinit(e){o(e),k()},get onaskQuestion(){return s()},set onaskQuestion(e){s(e),k()},get isLast(){return c()},set isLast(e=!1){c(e),k()}},b=xj();let x;var S=N(b),C=N(S),ee=e=>{var t=yj(),i=N(t);lj(i,{class:`message__bot-avatar`});var a=F(i,2),o=N(a),l=N(o);na(l,()=>r().message.html);var u=F(l,2),d=e=>{var t=dj(),r=P(t);gb(F(r),{name:`messageLoading`,class:`message__bot-loading`}),I(()=>V(r,`${L(n).messageBotLoading??``} `)),B(e,t)};U(u,e=>{r().state===`loading`&&e(d)}),E(o);var p=F(o,2),m=e=>{{let t=A(()=>r().state===`done`);Ub(e,{get references(){return r().references.all},get ready(){return L(t)}})}};U(p,e=>{r().references&&r().references.all.length>0&&e(m)});var y=F(p,2),b=e=>{var t=z();ma(P(t),()=>c()?`nav`:`div`,!1,(e,t)=>{Ja(e,()=>({"aria-label":c()?Z.t.ariaLastAnswerNavigation:void 0,class:`message__bot-options`})),fa(3,e,()=>TA,()=>L(f));var i=vj(),a=P(i),o=e=>{var t=gj(),i=N(t),a=e=>{var t=pj(),n=()=>ub.toggleReferencesAside(r().id);Ja(t,()=>({class:`btn btn--tertiary btn--square`,onclick:n,"aria-expanded":Z.data.currentReferencesAsideId===r().id,"aria-controls":Ej,[uj]:!0}));var i=N(t);gb(i,{name:`listUnordered`});var a=F(i,2),o=e=>{var t=fj(),n=N(t,!0);E(t),I(()=>V(n,L(h))),B(e,t)};U(a,e=>{L(h)&&e(o)}),E(t),B(e,t)};U(i,e=>{r().references&&r().references.used.length&&e(a)});var o=F(i,2),s=e=>{var t=hj(),i=N(t);gb(i,{name:`forward`});var a=F(i,2),o=e=>{var t=mj(),n=N(t,!0);E(t),I(()=>V(n,L(_))),B(e,t)};U(a,e=>{L(_)&&e(o)}),E(t),I(()=>{G(t,`aria-expanded`,Z.data.answerFormMessageId===r().id),G(t,`aria-label`,L(n).ariaAnswerForm)}),ai(`click`,t,()=>ub.openAnswerForm(r().id)),B(e,t)};U(o,e=>{L(g)&&e(s)}),E(t),B(e,t)};U(a,e=>{(r().references&&r().references.used.length||L(g))&&e(o)});var l=F(a,2),u=e=>{var t=_j(),i=N(t),a=e=>{bb(e,{icon:`retry`,get label(){return L(n).ariaAskQuestionAgain},get tooltip(){return L(n).askQuestionAgain},get onclick(){return s()},class:`message__bot-action btn btn--tertiary btn--square`})};U(i,e=>{Z.data.chatConfig.askQuestionAgain&&e(a)});var o=F(i,2);bb(o,{icon:`voteUp`,get label(){return L(n).ariaAnswerGood},get tooltip(){return L(n).answerGood},onclick:()=>ub.thumbs(r().id,`up`),class:`message__bot-action btn btn--tertiary btn--square`});var c=F(o,2);bb(c,{icon:`voteDown`,get label(){return L(n).ariaAnswerBad},get tooltip(){return L(n).answerBad},onclick:()=>ub.thumbs(r().id,`down`),class:`message__bot-action btn btn--tertiary btn--square`});var l=F(c,2),u=e=>{bb(e,{icon:`message`,get label(){return L(n).ariaGiveFeedback},"aria-haspopup":`dialog`,get"aria-expanded"(){return Z.data.conversationFeedbackIsOpen},get tooltip(){return L(n).giveFeedback},onclick:()=>ub.openMessageFeedback(r().id),class:`message__bot-action btn btn--tertiary btn--square`})};U(l,e=>{(Z.data.chatConfig.showTextFeedback||Z.data.chatConfig.classification)&&e(u)}),E(t),B(e,t)};U(l,e=>{r().noFeedback||e(u)}),B(t,i)}),B(e,t)};U(y,e=>{r().state===`done`&&L(v)&&e(b)}),E(a),E(t),B(e,t)},te=e=>{var t=bj(),n=N(t);lj(n,{class:`message__bot-avatar`,get hide(){return r().hideAvatar}});var i=F(n,2);sj(N(i),{get componentName(){return r().componentName},get data(){return r().data},get hideChatInput(){return r().hideChatInput}}),E(i),E(t),B(e,t)},ne=e=>{var t=hi();I(()=>V(t,r().message)),B(e,t)};return U(C,e=>{r().type===`bot`?e(ee):r().type===`component`?e(te,1):r().type===`user`&&e(ne,2)}),E(S),E(b),_a(b,(e,t)=>fb?.(e,t),()=>r().type===`user`?`chatPageLastUserMessage`:void 0),I(()=>{x=Da(b,1,`message container`,null,x,{"message--bot":r().type===`bot`||r().type===`component`,"message--user":r().type===`user`,"message--no-padding":r().type===`component`&&r().noSectionPadding}),G(b,`aria-label`,L(m))}),fa(3,b,()=>TA,()=>l),B(e,b),O(y)}oi([`click`]),q(Sj,{message:{},index:{},onmessageupdate:{},onbotmessageinit:{},onaskQuestion:{},isLast:{}},[],[],{mode:`open`});var Cj=e=>Array.from(e.querySelectorAll(`a[href], button, input:not([type="hidden"]), textarea, select, details,[tabindex]:not([tabindex="-1"])`)).filter(e=>!e.hasAttribute(`disabled`)&&!e.getAttribute(`aria-hidden`)),wj=e=>{let t=e.getRootNode();return`activeElement`in t?t.activeElement:document.activeElement};function Tj(e,t){let{firstFocusableOnMount:n=!0,resetFocusOnDestroy:r=!0,avoidFocusLoop:i=!1}=t||{},a=wj(e),o=Cj(e),s,c=new MutationObserver(()=>{o=Cj(e)}),l=t=>{o&&e.dataset.disabled!==`true`&&t.key===`Tab`&&(t.shiftKey?wj(e)===o[0]&&(t.preventDefault(),o[o.length-1].focus()):wj(e)===o[o.length-1]&&(t.preventDefault(),o[0].focus()))};return o&&o.length>0&&!i&&(n&&(s=o[0],requestAnimationFrame(()=>{s?.focus({preventScroll:!0})})),e.addEventListener(`keydown`,l),c.observe(e,{childList:!0,subtree:!0,attributes:!0,attributeFilter:[`disabled`,`aria-hidden`,`tabindex`]})),{destroy(){o&&o.length>0&&!i&&(o=null,s=null,e.removeEventListener(`keydown`,l),c.disconnect(),r&&a&&requestAnimationFrame(()=>{a.focus({preventScroll:!0})}))}}}var Ej=`aside`,Dj=R(`<div></div>`),Oj=R(`<h2 class="chat-app__sheet-title"> </h2>`),kj=R(`<span class="btn btn--tertiary btn--square"><span class="sr-only"> </span> <!></span>`),Aj=R(`<div><div class="chat-app__sheet-header"><!> <!></div> <!></div>`),jj=R(`<!> <!>`,1),Mj=R(`<h2 class="chat-app__aside-title"> </h2>`),Nj=R(`<div><div class="chat-app__aside-container"><div class="chat-app__aside-header"><!> <div class="chat-app__aside-close"><button class="btn btn--tertiary btn--square"><span class="sr-only"> </span> <!></button></div></div> <!></div></div>`);function Pj(e,t){D(t,!0);let n=K(t,`title`,7),r=K(t,`isOpen`,7),i=K(t,`isMobile`,7),a=K(t,`showReferencesByDefault`,7),o=K(t,`onClose`,7),s=K(t,`children`,7),c=j(void 0),l=null,u=e=>{e.key===`Escape`&&o()()};$n(()=>{if(!i())if(r()){if(a()||document.addEventListener(`keydown`,u),L(c)&&(l=wj(L(c)),!a()||l?.hasAttribute(`data-references-toggle-button`))){let e=Cj(L(c));e[0].setAttribute(_b,`true`),e[0].focus({preventScroll:!0})}}else document.removeEventListener(`keydown`,u),l?.hasAttribute(`data-references-toggle-button`)?l.focus({preventScroll:!0}):Z.targets.chatInput?.focus({preventScroll:!0})});var d={get title(){return n()},set title(e){n(e),k()},get isOpen(){return r()},set isOpen(e){r(e),k()},get isMobile(){return i()},set isMobile(e){i(e),k()},get showReferencesByDefault(){return a()},set showReferencesByDefault(e){a(e),k()},get onClose(){return o()},set onClose(e){o(e),k()},get children(){return s()},set children(e){s(e),k()}},f=z(),p=P(f),m=e=>{var t=z(),i=P(t),a=e=>{var t=z();W(P(t),()=>eA,(e,t)=>{t(e,{onOpenChange:e=>{e||o()()},get open(){return r()},set open(e){r(e)},children:(e,t)=>{var r=z();W(P(r),()=>OC,(e,t)=>{t(e,{get to(){return Z.targets.portals},children:(e,t)=>{var r=jj(),i=P(r);{let e=(e,t)=>{let n=()=>t?.().props,r=()=>t?.().open;var i=z(),a=P(i),o=e=>{var t=Dj();Ja(t,()=>({class:`chat-app__sheet-overlay`,...n()})),fa(1,t,()=>wA,()=>({duration:200})),fa(2,t,()=>wA,()=>({duration:200,delay:150})),B(e,t)};U(a,e=>{r()&&e(o)}),B(e,i)};W(i,()=>qT,(t,n)=>{n(t,{forceMount:!0,child:e,$$slots:{child:!0}})})}var a=F(i,2);{let e=(e,t)=>{let r=()=>t?.().props,i=()=>t?.().open;var a=z(),o=P(a),c=e=>{var t=Aj();Ja(t,()=>({...r()}));var i=N(t),a=N(i),o=e=>{var t=z();W(P(t),()=>yC,(e,t)=>{t(e,{children:(e,t)=>{var r=Oj(),i=N(r,!0);E(r),I(()=>V(i,n())),B(e,r)},$$slots:{default:!0}})}),B(e,t)};U(a,e=>{n()&&e(o)}),W(F(a,2),()=>nA,(e,t)=>{t(e,{class:`chat-app__sheet-close`,children:(e,t)=>{var n=kj(),r=N(n),i=N(r,!0);E(r),gb(F(r,2),{name:`dismiss`}),E(n),I(()=>V(i,Z.t.close)),B(e,n)},$$slots:{default:!0}})}),E(i),H(F(i,2),()=>s()??w),E(t),_a(t,e=>Tj?.(e)),fa(1,t,()=>TA,()=>({x:`100%`,opacity:1,duration:650,easing:yA})),fa(2,t,()=>TA,()=>({x:`100%`,opacity:1,duration:500,easing:_A})),B(e,t)};U(o,e=>{i()&&e(c)}),B(e,a)},t=A(()=>!Z.data.chatConfig.inlineLayout&&!Z.data.props.flyout);W(a,()=>aA,(n,r)=>{r(n,{class:`chat-app__sheet-content`,trapFocus:!1,forceMount:!0,get preventScroll(){return L(t)},child:e,$$slots:{child:!0}})})}B(e,r)},$$slots:{default:!0}})}),B(e,r)},$$slots:{default:!0}})}),B(e,t)};U(i,e=>{Z.targets.portals&&e(a)}),B(e,t)},h=e=>{var t=Nj();let i;G(t,`id`,Ej);var l=N(t),u=N(l),d=N(u),f=e=>{var t=Mj(),r=N(t,!0);E(t),I(()=>V(r,n())),B(e,t)};U(d,e=>{n()&&e(f)});var p=F(d,2),m=N(p),h=N(m),g=N(h,!0);E(h),gb(F(h,2),{name:`dismiss`}),E(m),_a(m,(e,t)=>vb?.(e,t),()=>({text:Z.t.close,position:`bottom-right`,delay:0})),E(p),E(u),H(F(u,2),()=>s()??w),E(l),E(t),_a(t,(e,t)=>Tj?.(e,t),()=>({firstFocusableOnMount:!1,resetFocusOnDestroy:!1,avoidFocusLoop:a()})),so(t,e=>M(c,e),()=>L(c)),I(()=>{i=Da(t,1,`chat-app__aside`,null,i,{open:r()}),G(t,`role`,a()?`complementary`:`dialog`),G(t,`aria-modal`,a()?`false`:`true`),G(t,`aria-label`,Z.t.ariaReferencesRegion),G(t,`aria-hidden`,!r()),V(g,Z.t.close)}),ai(`click`,m,function(...e){o()?.apply(this,e)}),B(e,t)};return U(p,e=>{i()?e(m):e(h,-1)}),B(e,f),O(d)}oi([`click`]),q(Pj,{title:{},isOpen:{},isMobile:{},showReferencesByDefault:{},onClose:{},children:{}},[],[],{mode:`open`});var Fj=R(`<div class="chat-app__close-button"><button class="btn btn--tertiary btn--square"><span class="sr-only"> </span> <!></button></div>`);function Ij(e,t){D(t,!0);let n=A(()=>Z.t),r=K(t,`onclick`,7);var i={get onclick(){return r()},set onclick(e){r(e),k()}},a=Fj(),o=N(a),s=N(o),c=N(s,!0);return E(s),gb(F(s,2),{name:`dismiss`}),E(o),_a(o,(e,t)=>vb?.(e,t),()=>({text:L(n).closeChat,position:`bottom-right`,delay:600})),E(a),I(()=>{G(o,`aria-label`,L(n).closeChat),V(c,L(n).closeChat)}),ai(`click`,o,function(...e){r()?.apply(this,e)}),B(e,a),O(i)}oi([`click`]),q(Ij,{onclick:{}},[],[],{mode:`open`});var Lj=R(`<div></div>`),Rj=R(`<div><!></div>`),zj=R(`<span class="sr-only"> </span> <!>`,1),Bj=R(`<div class="dialog-footer"><!></div>`),Vj=R(`<div><div class="dialog-header"><!> <!></div> <!> <!></div>`),Hj=R(`<!> <!>`,1);function Uj(e,t){D(t,!0);let n=K(t,`open`,7),r=K(t,`content`,7),i=K(t,`title`,7),a=K(t,`footer`,7),o=K(t,`onClose`,7),s=j(void 0),c=j(void 0),l={duration:Number(Z.theme.components.dialog.custom?.transitionDuration)||200,delay:Number(Z.theme.components.dialog.custom?.transitionDelay)||0,y:Number(Z.theme.components.dialog.custom?.transitionY)||10},u=e=>{e||o()()};$n(()=>{if(n()&&L(s)&&L(c)&&L(c).textContent){let e=rl(L(c).textContent.trim());L(s).setAttribute(`aria-label`,e),L(s).removeAttribute(`aria-labelledby`),Cj(L(s))[0].focus({preventScroll:!0})}});var d={get open(){return n()},set open(e){n(e),k()},get content(){return r()},set content(e){r(e),k()},get title(){return i()},set title(e){i(e),k()},get footer(){return a()},set footer(e){a(e),k()},get onClose(){return o()},set onClose(e){o(e),k()}},f=z(),p=P(f),m=e=>{var t=z();W(P(t),()=>eA,(e,t)=>{t(e,{get open(){return n()},onOpenChange:u,children:(e,t)=>{var n=z();W(P(n),()=>OC,(e,t)=>{t(e,{get to(){return Z.targets.portals},children:(e,t)=>{var n=Hj(),o=P(n);{let e=(e,t)=>{let n=()=>t?.().props,r=()=>t?.().open;var i=z(),a=P(i),o=e=>{var t=Lj();Ja(t,()=>({...n(),class:`dialog-overlay`})),fa(3,t,()=>wA,()=>l),B(e,t)};U(a,e=>{r()&&e(o)}),B(e,i)};W(o,()=>qT,(t,n)=>{n(t,{forceMount:!0,child:e,$$slots:{child:!0}})})}var u=F(o,2);{let e=(e,t)=>{let n=()=>t?.().props,o=()=>t?.().open;var u=z(),d=P(u),f=e=>{var t=Vj();Ja(t,()=>({...n(),class:`dialog-content`}));var o=N(t),u=N(o);W(u,()=>yC,(e,t)=>{t(e,{class:`dialog-title h4`,children:(e,t)=>{var n=Rj();H(N(n),()=>i()??w),E(n),so(n,e=>M(c,e),()=>L(c)),B(e,n)},$$slots:{default:!0}})}),W(F(u,2),()=>nA,(e,t)=>{t(e,{class:`dialog-close`,children:(e,t)=>{var n=zj(),r=P(n),i=N(r,!0);E(r),gb(F(r,2),{name:`dismiss`}),I(()=>V(i,Z.t.close)),B(e,n)},$$slots:{default:!0}})}),E(o);var d=F(o,2);W(d,()=>YT,(e,t)=>{t(e,{class:`dialog-description text-container`,children:(e,t)=>{var n=z();H(P(n),r),B(e,n)},$$slots:{default:!0}})});var f=F(d,2),p=e=>{var t=Bj();H(N(t),a),E(t),B(e,t)};U(f,e=>{a()&&e(p)}),E(t),_a(t,(e,t)=>Tj?.(e,t),()=>({firstFocusableOnMount:!1})),so(t,e=>M(s,e),()=>L(s)),fa(3,t,()=>TA,()=>l),B(e,t)};U(d,e=>{o()&&e(f)}),B(e,u)},t=A(()=>!Z.data.chatConfig.inlineLayout&&!Z.data.props.flyout);W(u,()=>aA,(n,r)=>{r(n,{trapFocus:!1,forceMount:!0,get preventScroll(){return L(t)},child:e,$$slots:{child:!0}})})}B(e,n)},$$slots:{default:!0}})}),B(e,n)},$$slots:{default:!0}})}),B(e,t)};return U(p,e=>{Z.targets.portals&&e(m)}),B(e,f),O(d)}q(Uj,{open:{},content:{},title:{},footer:{},onClose:{}},[],[],{mode:`open`});var Wj=R(`<div><!></div>`);function Gj(e,t){D(t,!0);let n=K(t,`checked`,7,!1),r=K(t,`class`,7,``);var i={get checked(){return n()},set checked(e=!1){n(e),k()},get class(){return r()},set class(e=``){r(e),k()}},a=Wj();return gb(N(a),{name:`checkbox`,class:`checkbox__icon`}),E(a),I(()=>{Da(a,1,`checkbox ${r()??``}`),G(a,`data-checked`,n())}),B(e,a),O(i)}q(Gj,{checked:{},class:{}},[],[],{mode:`open`});var Kj=R(`<div><div class="radio__indicator"></div></div>`);function qj(e,t){D(t,!0);let n=K(t,`checked`,7,!1),r=K(t,`class`,7,``);var i={get checked(){return n()},set checked(e=!1){n(e),k()},get class(){return r()},set class(e=``){r(e),k()}},a=Kj();return I(()=>{Da(a,1,`radio ${r()??``}`),G(a,`data-checked`,n())}),B(e,a),O(i)}q(qj,{checked:{},class:{}},[],[],{mode:`open`});var Jj=R(`<p class="form__caption"></p>`),Yj=R(`<input class="form__option-input" type="radio"/> <!>`,1),Xj=R(`<input class="form__option-input" type="checkbox"/> <!>`,1),Zj=R(`<label class="form__option"><!> <span> </span></label>`),Qj=R(`<fieldset class="form__fieldset"><legend class="form__label"> </legend> <div class="form__options"></div></fieldset>`),$j=R(`<textarea class="input"></textarea>`),eM=R(`<option disabled=""> </option>`),tM=R(`<option> </option>`),nM=R(`<div class="form__select"><select class="input"><!><!></select> <!></div>`),rM=R(`<input class="input"/>`),iM=R(`<div class="form__item"><label class="form__label"> </label> <!></div>`),aM=R(`<form class="form"><!> <!> <div class="form__fields"></div> <div class="form__footer"><button type="submit" class="btn btn--primary"> </button></div></form>`);function oM(e,t){D(t,!0);let n=K(t,`open`,7),r=K(t,`onClose`,7),i=K(t,`dialogTitle`,7),a=K(t,`caption`,7),o=K(t,`fields`,7),s=K(t,`submitLabel`,7),c=K(t,`submitEnabled`,7),l=K(t,`onSubmit`,7),u=K(t,`values`,15),d=K(t,`header`,7),f=`form-dialog-${e_()}`,p=e=>`${f}-${e}`,m=e=>(u()[e]??``).split(`,`).map(e=>e.trim()).filter(Boolean),h=(e,t)=>m(e).includes(t),g=(e,t,n)=>{let r=m(e);u(u()[e]=(n?[...r,t]:r.filter(e=>e!==t)).join(`, `),!0)};return Uj(e,{get open(){return n()},get onClose(){return r()},title:e=>{var t=z();na(P(t),i),B(e,t)},content:e=>{var t=aM(),n=N(t);H(n,()=>d()??w);var r=F(n,2),i=e=>{var t=Jj();na(t,a,!0),E(t),B(e,t)};U(r,e=>{a()&&e(i)});var f=F(r,2);Xi(f,21,o,e=>e.name,(e,t)=>{var n=z(),r=P(n),i=e=>{var n=Qj(),r=N(n),i=N(r,!0);E(r);var a=F(r,2);Xi(a,21,()=>L(t).options??[],e=>e.value,(e,n)=>{var r=Zj(),i=N(r),a=e=>{var r=Yj(),i=P(r);Ua(i);var a=F(i,2);{let e=A(()=>u()[L(t).name]===L(n).value);qj(a,{get checked(){return L(e)}})}I(e=>{G(i,`name`,e),Wa(i,L(n).value),Ga(i,u()[L(t).name]===L(n).value)},[()=>p(L(t).name)]),ai(`change`,i,()=>u(u()[L(t).name]=L(n).value,!0)),B(e,r)},o=e=>{var r=Xj(),i=P(r);Ua(i);var a=F(i,2);{let e=A(()=>h(L(t).name,L(n).value));Gj(a,{get checked(){return L(e)}})}I(e=>{Wa(i,L(n).value),Ga(i,e)},[()=>h(L(t).name,L(n).value)]),ai(`change`,i,e=>g(L(t).name,L(n).value,e.currentTarget.checked)),B(e,r)};U(i,e=>{L(t).type===`radio`?e(a):e(o,-1)});var s=F(i,2),c=N(s,!0);E(s),E(r),I(()=>V(c,L(n).label)),B(e,r)}),E(a),E(n),I(()=>V(i,L(t).label)),B(e,n)},a=e=>{var n=iM(),r=N(n),i=N(r,!0);E(r);var a=F(r,2),o=e=>{var n=$j();Un(n),I(e=>{G(n,`id`,e),G(n,`placeholder`,L(t).placeholder),n.required=L(t).required},[()=>p(L(t).name)]),Qa(n,()=>u()[L(t).name],e=>u(u()[L(t).name]=e,!0)),B(e,n)},s=e=>{var n=nM(),r=N(n),i=N(r),a=e=>{var n=eM(),r=N(n,!0);E(n),n.value=n.__value=``,I(()=>V(r,L(t).placeholder)),B(e,n)};U(i,e=>{L(t).placeholder&&e(a)}),Xi(F(i),17,()=>L(t).options??[],e=>e.value,(e,t)=>{var n=tM(),r=N(n,!0);E(n);var i={};I(()=>{V(r,L(t).label),i!==(i=L(t).value)&&(n.value=(n.__value=L(t).value)??``)}),B(e,n)}),E(r),gb(F(r,2),{name:`chevronDown`,class:`form__select-arrow`}),E(n),I(e=>{G(r,`id`,e),r.required=L(t).required},[()=>p(L(t).name)]),Ma(r,()=>u()[L(t).name],e=>u(u()[L(t).name]=e,!0)),B(e,n)},c=e=>{var n=rM();Ua(n),I(e=>{G(n,`type`,L(t).type),G(n,`id`,e),G(n,`placeholder`,L(t).placeholder),n.required=L(t).required},[()=>p(L(t).name)]),Qa(n,()=>u()[L(t).name],e=>u(u()[L(t).name]=e,!0)),B(e,n)};U(a,e=>{L(t).type===`textarea`?e(o):L(t).type===`select`?e(s,1):e(c,-1)}),E(n),I(e=>{G(r,`for`,e),V(i,L(t).label)},[()=>p(L(t).name)]),B(e,n)};U(r,e=>{L(t).type===`checkbox`||L(t).type===`radio`?e(i):e(a,-1)}),B(e,n)}),E(f);var m=F(f,2),_=N(m),v=N(_,!0);E(_),E(m),E(t),I(()=>{_.disabled=!c(),V(v,s())}),ii(`submit`,t,async e=>{e.preventDefault(),await l()()}),B(e,t)},$$slots:{title:!0,content:!0}}),O({get open(){return n()},set open(e){n(e),k()},get onClose(){return r()},set onClose(e){r(e),k()},get dialogTitle(){return i()},set dialogTitle(e){i(e),k()},get caption(){return a()},set caption(e){a(e),k()},get fields(){return o()},set fields(e){o(e),k()},get submitLabel(){return s()},set submitLabel(e){s(e),k()},get submitEnabled(){return c()},set submitEnabled(e){c(e),k()},get onSubmit(){return l()},set onSubmit(e){l(e),k()},get values(){return u()},set values(e){u(e),k()},get header(){return d()},set header(e){d(e),k()}})}oi([`change`]),q(oM,{open:{},onClose:{},dialogTitle:{},caption:{},fields:{},submitLabel:{},submitEnabled:{},onSubmit:{},values:{},header:{}},[],[],{mode:`open`});function sM(e,t){D(t,!0);let n=A(()=>Z.data.chatConfig.answerForm),r=e=>G_(e,Z.data.language,Z.data.chatConfig.supportedLanguages),i=A(()=>L(n)?r(L(n).title??L(n).triggerLabel):``),a=A(()=>L(n)?.caption?r(L(n).caption):void 0),o=A(()=>L(n)?r(L(n).submitLabel):``),s=A(()=>L(n)?.fields.map(e=>({type:e.type,name:e.name,label:r(e.label),placeholder:e.placeholder?r(e.placeholder):void 0,required:e.required,options:e.options?.map(e=>({value:e.value,label:r(e.label)}))}))??[]),c=()=>Object.fromEntries((L(n)?.fields??[]).map(e=>[e.name,``])),l=j(Dn(c())),u=A(()=>(L(n)?.fields??[]).every(e=>!e.required||(L(l)[e.name]??``).trim()!==``));var d=z(),f=P(d),p=e=>{{let t=A(()=>!!Z.data.answerFormMessageId);oM(e,{get open(){return L(t)},get onClose(){return ub.closeAnswerForm},get dialogTitle(){return L(i)},get caption(){return L(a)},get fields(){return L(s)},get submitLabel(){return L(o)},get submitEnabled(){return L(u)},onSubmit:async()=>{await ub.submitAnswerForm(L(l)),M(l,c(),!0),ub.closeAnswerForm()},get values(){return L(l)},set values(e){M(l,e,!0)}})}};U(f,e=>{L(n)&&e(p)}),B(e,d),O()}q(sM,{},[],[],{mode:`open`});var cM=R(`<button type="button" class="selected-topic__btn"> </button>`),lM=R(`<div class="selected-topic__container"><h2 class="selected-topic__label"><!> <span class="selected-topic__label-complement"> </span> <span> </span></h2> <!></div>`),uM=R(`<section class="selected-topic"><div><div><!></div></div></section>`);function dM(e,t){D(t,!0);let n=A(()=>Z.t),r=A(()=>Z.data.selectedTopic),i=j(0);var a=uM();let o;var s=N(a),c=N(s),l=N(c),u=e=>{var t=lM(),i=N(t),a=N(i);gb(a,{name:`topic`});var o=F(a,2),s=N(o);E(o);var c=F(o,2),l=N(c,!0);E(c),E(i);var u=F(i,2),d=e=>{var t=cM(),r=N(t,!0);E(t),I(()=>V(r,L(n).changeTopic)),ai(`click`,t,()=>ub.onChangeTopic()),B(e,t)};U(u,e=>{L(r).locked||e(d)}),E(t),I(()=>{V(s,`${L(n).selectedTopic??``}:`),V(l,L(r).label)}),fa(1,t,()=>TA,()=>({duration:500,easing:yA,y:50})),fa(2,t,()=>TA,()=>({duration:250,easing:vA,y:50})),B(e,t)};U(l,e=>{L(r)&&e(u)}),E(c),E(s),E(a),I(()=>{G(a,`aria-label`,L(n).ariaChangeTopic),o=ka(a,``,o,{height:L(r)?`${L(i)}px`:`0px`}),Da(c,1,xa([`selected-topic__animation-container`,{"selected-topic__animation-container--hidden":!L(r)}]))}),ao(s,`clientHeight`,e=>M(i,e)),B(e,a),O()}oi([`click`]),q(dM,{},[],[],{mode:`open`});var fM=R(`<button><!> <div class="chat-input__settings-button-label"> </div> <!></button>`),pM=R(`<span class="context-box__notification" data-type="error"> </span>`),mM=R(`<!> <!>`,1),hM=R(`<!> <!>`,1),gM=R(`<!> <!>`,1),_M=R(`<div><div><div class="context-box__content"><div class="context-box__header"><span class="sr-only"> </span> <span> <!></span> <button type="button" class="context-box__close-button btn btn--tertiary btn--square"><!></button></div> <div><!></div> <!></div></div></div>`),vM=R(`<!> <!>`,1),yM=R(`<div><div></div> <!></div>`);function bM(e,t){D(t,!0);let n=K(t,`settingName`,7),r=K(t,`iconName`,7),i=K(t,`currentValues`,7),a=K(t,`possibleValues`,7),o=K(t,`disabled`,7),s=A(()=>Z.selectorTranslations[n()]??{name:n(),placeholder:``,values:{}}),c=A(()=>()=>i().length===0?`${L(s).placeholder}`:i().length===1?`1 ${L(s).name}`:`${i().length} ${L(s).namePlural||L(s).name}`),l=A(()=>Z.selectorsWithErrors.includes(n())),u={duration:Number(Z.theme.components.contextBox.custom?.transitionDuration)||200,delay:Number(Z.theme.components.contextBox.custom?.transitionDelay)||0,y:Number(Z.theme.components.contextBox.custom?.transitionY)||10},d=j(!1);$n(()=>{L(d)&&setTimeout(()=>{M(d,!1)},200)});let f=()=>{M(d,!0),ub.setSelectorValue(n(),a()),ub.setAriaLiveStatusMessage(Z.t.ariaAllSelected)},p=async()=>{M(d,!0),ub.setSelectorValue(n(),[]),await qr().then(()=>{let e=Z.t.ariaAllUnselected;L(l)&&(e+=`. ${Z.t.chooseAtLeastOneOption}`),ub.setAriaLiveStatusMessage(e)})},m=()=>{M(d,!0);let e=ub.resetSelectorToDefaults(n());ub.setAriaLiveStatusMessage(`${Z.t.ariaAllReseted}: ${e.join(`, `)}`)},h=j(void 0),g=j(!1);var _={get settingName(){return n()},set settingName(e){n(e),k()},get iconName(){return r()},set iconName(e){r(e),k()},get currentValues(){return i()},set currentValues(e){i(e),k()},get possibleValues(){return a()},set possibleValues(e){a(e),k()},get disabled(){return o()},set disabled(e){o(e),k()}},v=yM(),y=N(v);return so(y,e=>M(h,e),()=>L(h)),W(F(y,2),()=>oA,(e,t)=>{t(e,{get open(){return L(g)},set open(e){M(g,e,!0)},children:(e,t)=>{var _=vM(),v=P(_);{let e=(e,t)=>{let n=()=>t?.().props;var i=fM();Ja(i,()=>({type:`button`,class:`chat-input__settings-button btn btn--tertiary`,"data-has-error":L(l),...n(),disabled:o(),"aria-hidden":o(),tabindex:o()?-1:void 0}));var a=N(i);gb(a,{get name(){return r()},class:`chat-input__settings-button-icon`});var s=F(a,2),u=N(s,!0);E(s),gb(F(s,2),{name:`chevronDownSmall`,class:`chat-input__settings-button-chevron`}),E(i),I(e=>V(u,e),[()=>L(c)()]),B(e,i)};W(v,()=>dA,(t,n)=>{n(t,{child:e,$$slots:{child:!0}})})}W(F(v,2),()=>OC,(e,t)=>{t(e,{get to(){return L(h)},children:(e,t)=>{var r=z(),o=P(r);{let e=(e,t)=>{let r=()=>t?.().wrapperProps,o=()=>t?.().props,c=()=>t?.().open;var h=z(),_=P(h),v=e=>{var t=_M();Ja(t,()=>({...r()}));var c=N(t);Ja(c,()=>({...o()}));var h=N(c),_=N(h),v=N(_),y=N(v,!0);E(v);var b=F(v,2),x=N(b),S=F(x),C=e=>{var t=pM(),n=N(t,!0);E(t),I(()=>V(n,Z.t.chooseAtLeastOneOption)),B(e,t)};U(S,e=>{L(l)&&e(C)}),E(b);var ee=F(b,2);gb(N(ee),{name:`menuClose`}),E(ee),E(_);var te=F(_,2);let ne;W(N(te),()=>zk,(e,t)=>{t(e,{get value(){return i()},onValueChange:e=>{ub.setSelectorValue(n(),e)},class:`display-contents`,children:(e,t)=>{var n=z();Xi(P(n),17,a,Ki,(e,t)=>{let n=A(NT),r=A(()=>L(s).values?.[L(t)]||L(t));var i=z(),a=P(i);{let e=(e,t)=>{let i=()=>t?.().checked;var a=mM(),o=P(a);Gj(o,{get checked(){return i()}}),W(F(o,2),()=>hA,(e,t)=>{t(e,{get for(){return L(n)},children:(e,t)=>{Ze();var n=hi();I(()=>V(n,L(r))),B(e,n)},$$slots:{default:!0}})}),B(e,a)};W(a,()=>Lk,(i,a)=>{a(i,{get value(){return L(t)},class:`context-box__menu-item context-box__menu-item--option`,get id(){return L(n)},closeOnSelect:!1,onCheckedChange:async e=>{L(d)||await qr().then(()=>{let t=e?Z.t.ariaSelected:Z.t.ariaUnselected,n=`${L(r)}, ${t}`;L(l)&&(n+=`. ${Z.t.chooseAtLeastOneOption}`),ub.setAriaLiveStatusMessage(n)})},children:e,$$slots:{default:!0}})})}B(e,i)}),B(e,n)},$$slots:{default:!0}})}),E(te),W(F(te,2),()=>Dk,(e,t)=>{t(e,{class:`context-box__footer`,children:(e,t)=>{var n=gM(),r=P(n),i=e=>{var t=hM(),n=P(t);W(n,()=>Tk,(e,t)=>{t(e,{onclick:f,closeOnSelect:!1,class:`context-box__footer-item btn btn--tertiary`,children:(e,t)=>{Ze();var n=hi();I(()=>V(n,Z.t.selectAll)),B(e,n)},$$slots:{default:!0}})}),W(F(n,2),()=>Tk,(e,t)=>{t(e,{onclick:p,closeOnSelect:!1,class:`context-box__footer-item btn btn--tertiary`,children:(e,t)=>{Ze();var n=hi();I(()=>V(n,Z.t.selectNone)),B(e,n)},$$slots:{default:!0}})}),B(e,t)};U(r,e=>{a().length>5&&e(i)}),W(F(r,2),()=>Tk,(e,t)=>{t(e,{onclick:m,closeOnSelect:!1,class:`context-box__footer-item btn btn--tertiary`,children:(e,t)=>{Ze();var n=hi();I(()=>V(n,Z.t.resetToDefaults)),B(e,n)},$$slots:{default:!0}})}),B(e,n)},$$slots:{default:!0}})}),E(h),E(c),E(t),I(()=>{V(y,Z.t.ariaCloseWithEsc),V(x,`${(L(s).intro||L(s).name)??``} `),G(ee,`aria-label`,Z.t.close),ne=Da(te,1,`context-box__menu context-box__menu--scrollable`,null,ne,{"context-box__menu--two-cols":a().length>8,"context-box__menu--three-cols":a().length>16})}),ai(`click`,ee,()=>M(g,!1)),fa(3,c,()=>TA,()=>u),B(e,t)};U(_,e=>{c()&&e(v)}),B(e,h)};W(o,()=>lA,(t,n)=>{n(t,{class:`context-box context-box--dropdown`,align:`start`,sideOffset:8,forceMount:!0,strategy:`absolute`,preventScroll:!1,child:e,$$slots:{child:!0}})})}B(e,r)},$$slots:{default:!0}})}),B(e,_)},$$slots:{default:!0}})}),E(v),B(e,v),O(_)}oi([`click`]),q(bM,{settingName:{},iconName:{},currentValues:{},possibleValues:{},disabled:{}},[],[],{mode:`open`});var xM=R(`<button><!> <div class="chat-input__settings-button-label"><span class="chat-input__settings-button-label-name"> </span> </div> <!></button>`),SM=R(`<!> <!>`,1),CM=R(`<!> <!>`,1),wM=R(`<!> <!>`,1),TM=R(`<div><div><div class="context-box__content"><div class="context-box__header"><span class="sr-only"> </span> <span> </span> <button type="button" class="context-box__close-button btn btn--tertiary btn--square"><!></button></div> <div><!></div> <!></div></div></div>`),EM=R(`<!> <!>`,1),DM=R(`<div><div></div> <!></div>`);function OM(e,t){D(t,!0);let n=K(t,`settingName`,7),r=K(t,`iconName`,7),i=K(t,`currentValue`,7),a=K(t,`possibleValues`,7),o=K(t,`allowEmpty`,7),s=K(t,`disabled`,7),c=A(()=>Z.selectorTranslations[n()]??{name:n(),placeholder:``,values:{}}),l=A(()=>i()?L(c).values?.[i()]||i():L(c).placeholder),u=A(()=>Z.selectorsWithErrors.includes(n())),d={duration:Number(Z.theme.components.contextBox.custom?.transitionDuration)||200,delay:Number(Z.theme.components.contextBox.custom?.transitionDelay)||0,y:Number(Z.theme.components.contextBox.custom?.transitionY)||10},f=()=>{ub.resetSelectorToDefaults(n())},p=j(void 0),m=j(!1);var h={get settingName(){return n()},set settingName(e){n(e),k()},get iconName(){return r()},set iconName(e){r(e),k()},get currentValue(){return i()},set currentValue(e){i(e),k()},get possibleValues(){return a()},set possibleValues(e){a(e),k()},get allowEmpty(){return o()},set allowEmpty(e){o(e),k()},get disabled(){return s()},set disabled(e){s(e),k()}},g=DM(),_=N(g);return so(_,e=>M(p,e),()=>L(p)),W(F(_,2),()=>oA,(e,t)=>{t(e,{get open(){return L(m)},set open(e){M(m,e,!0)},children:(e,t)=>{var h=EM(),g=P(h);{let e=(e,t)=>{let n=()=>t?.().props;var i=xM();Ja(i,()=>({type:`button`,class:`chat-input__settings-button btn btn--tertiary`,"data-has-error":L(u),...n(),disabled:s(),"aria-hidden":s(),tabindex:s()?-1:void 0}));var a=N(i);gb(a,{get name(){return r()},class:`chat-input__settings-button-icon`});var o=F(a,2),d=N(o),f=N(d);E(d);var p=F(d);E(o),gb(F(o,2),{name:`chevronDownSmall`,class:`chat-input__settings-button-chevron`}),E(i),I(()=>{V(f,`${L(c).name??``}:`),V(p,` ${L(l)??``}`)}),B(e,i)};W(g,()=>dA,(t,n)=>{n(t,{child:e,$$slots:{child:!0}})})}W(F(g,2),()=>OC,(e,t)=>{t(e,{get to(){return L(p)},children:(e,t)=>{var r=z(),s=P(r);{let e=(e,t)=>{let r=()=>t?.().wrapperProps,s=()=>t?.().props,l=()=>t?.().open;var u=z(),p=P(u),h=e=>{var t=TM();Ja(t,()=>({...r()}));var l=N(t);Ja(l,()=>({...s()}));var u=N(l),p=N(u),h=N(p),g=N(h,!0);E(h);var _=F(h,2),v=N(_,!0);E(_);var y=F(_,2);gb(N(y),{name:`menuClose`}),E(y),E(p);var b=F(p,2);let x;var S=N(b);{let e=A(()=>i()||``);W(S,()=>Fk,(t,r)=>{r(t,{get value(){return L(e)},onValueChange:e=>{e?ub.setSelectorValue(n(),[e]):ub.setSelectorValue(n(),[])},children:(e,t)=>{var n=wM(),r=P(n),i=e=>{let t=A(NT);var n=z(),r=P(n);{let e=(e,n)=>{let r=()=>n?.().checked;var i=SM(),a=P(i);qj(a,{get checked(){return r()}}),W(F(a,2),()=>hA,(e,n)=>{n(e,{get for(){return L(t)},children:(e,t)=>{Ze();var n=hi();I(()=>V(n,L(c).placeholder)),B(e,n)},$$slots:{default:!0}})}),B(e,i)};W(r,()=>jk,(n,r)=>{r(n,{value:``,class:`context-box__menu-item context-box__menu-item--option`,get id(){return L(t)},children:e,$$slots:{default:!0}})})}B(e,n)};U(r,e=>{o()&&e(i)}),Xi(F(r,2),17,a,Ki,(e,t)=>{let n=A(NT);var r=z(),i=P(r);{let e=(e,r)=>{let i=()=>r?.().checked;var a=CM(),o=P(a);qj(o,{get checked(){return i()}}),W(F(o,2),()=>hA,(e,r)=>{r(e,{get for(){return L(n)},children:(e,n)=>{Ze();var r=hi();I(()=>V(r,L(c).values?.[L(t)]||L(t))),B(e,r)},$$slots:{default:!0}})}),B(e,a)};W(i,()=>jk,(r,i)=>{i(r,{get value(){return L(t)},class:`context-box__menu-item context-box__menu-item--option`,get id(){return L(n)},children:e,$$slots:{default:!0}})})}B(e,r)}),B(e,n)},$$slots:{default:!0}})})}E(b),W(F(b,2),()=>Dk,(e,t)=>{t(e,{class:`context-box__footer`,children:(e,t)=>{var n=z();W(P(n),()=>Tk,(e,t)=>{t(e,{onclick:f,closeOnSelect:!1,class:`context-box__footer-item btn btn--tertiary`,children:(e,t)=>{Ze();var n=hi();I(()=>V(n,Z.t.resetToDefaults)),B(e,n)},$$slots:{default:!0}})}),B(e,n)},$$slots:{default:!0}})}),E(u),E(l),E(t),I(()=>{V(g,Z.t.ariaCloseWithEsc),V(v,L(c).intro||L(c).name),G(y,`aria-label`,Z.t.close),x=Da(b,1,`context-box__menu context-box__menu--scrollable`,null,x,{"context-box__menu--two-cols":a().length>8,"context-box__menu--three-cols":a().length>16})}),ai(`click`,y,()=>M(m,!1)),fa(3,l,()=>TA,()=>d),B(e,t)};U(p,e=>{l()&&e(h)}),B(e,u)};W(s,()=>lA,(t,n)=>{n(t,{class:`context-box context-box--dropdown`,align:`start`,sideOffset:8,forceMount:!0,strategy:`absolute`,preventScroll:!1,child:e,$$slots:{child:!0}})})}B(e,r)},$$slots:{default:!0}})}),B(e,h)},$$slots:{default:!0}})}),E(g),B(e,g),O(h)}oi([`click`]),q(OM,{settingName:{},iconName:{},currentValue:{},possibleValues:{},allowEmpty:{},disabled:{}},[],[],{mode:`open`});function kM(e,t){D(t,!0);let n=K(t,`chatSettingConfig`,7),r=K(t,`settingsIsOpen`,7);var i={get chatSettingConfig(){return n()},set chatSettingConfig(e){n(e),k()},get settingsIsOpen(){return r()},set settingsIsOpen(e){r(e),k()}},a=z(),o=P(a),s=e=>{{let t=A(()=>n().iconName||n().settingName),i=A(()=>!r());OM(e,{get settingName(){return n().settingName},get iconName(){return L(t)},get currentValue(){return Z.data.selectorValues[n().settingName][0]},get possibleValues(){return n().values},get allowEmpty(){return n().allowEmpty},get disabled(){return L(i)}})}},c=e=>{{let t=A(()=>n().iconName||n().settingName),i=A(()=>!r());bM(e,{get settingName(){return n().settingName},get iconName(){return L(t)},get currentValues(){return Z.data.selectorValues[n().settingName]},get possibleValues(){return n().values},get disabled(){return L(i)}})}};return U(o,e=>{n().type===`single-select`?e(s):n().type===`multi-select`&&e(c,1)}),B(e,a),O(i)}q(kM,{chatSettingConfig:{},settingsIsOpen:{}},[],[],{mode:`open`});function AM(e,t){D(t,!0);let n=K(t,`settingsIsOpen`,7);var r={get settingsIsOpen(){return n()},set settingsIsOpen(e){n(e),k()}},i=z();return Xi(P(i),17,()=>Z.data.chatConfig.selectorsConfig,Ki,(e,t)=>{kM(e,{get settingsIsOpen(){return n()},get chatSettingConfig(){return L(t)}})}),B(e,i),O(r)}q(AM,{settingsIsOpen:{}},[],[],{mode:`open`});var jM=mi(`<svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" aria-hidden="true"><defs><linearGradient x1="0" y1="1" x2="0" y2="0"><stop></stop><stop></stop></linearGradient><mask maskUnits="userSpaceOnUse" x="0" y="0" width="24" height="24"><g stroke="white" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" fill="none"><path d="M12 1a3 3 0 0 0-3 3v8a3 3 0 0 0 6 0V4a3 3 0 0 0-3-3z"></path><path d="M19 10v2a7 7 0 0 1-14 0v-2"></path><path d="M12 19v4"></path><path d="M8 23h8"></path></g></mask></defs><rect width="24" height="24"></rect></svg>`);function MM(e,t){D(t,!0);let n=K(t,`level`,7),r=K(t,`class`,7,``),i=K(t,`baseColor`,7,`var(--mic-base-color)`),a=K(t,`accentColor`,7,`var(--mic-accent-color)`),o=Math.random().toString(36).substring(2),s=`audio-level-gradient-${o}`,c=`audio-level-mask-${o}`;var l={get level(){return n()},set level(e){n(e),k()},get class(){return r()},set class(e=``){r(e),k()},get baseColor(){return i()},set baseColor(e=`var(--mic-base-color)`){i(e),k()},get accentColor(){return a()},set accentColor(e=`var(--mic-accent-color)`){a(e),k()}},u=jM(),d=N(u),f=N(d),p=N(f),m=F(p);E(f);var h=F(f);E(d);var g=F(d);return E(u),I(()=>{Da(u,0,`audio-level-mic-svg ${r()??``}`),G(f,`id`,s),G(p,`offset`,n()/100),G(p,`stop-color`,a()),G(m,`offset`,n()/100),G(m,`stop-color`,i()),G(h,`id`,c),G(g,`fill`,`url(#${s})`),G(g,`mask`,`url(#${c})`)}),B(e,u),O(l)}q(MM,{level:{},class:{},baseColor:{},accentColor:{}},[],[],{mode:`open`});var NM=R(`<button type="button"><div class="mic-icon" aria-hidden="true"><!></div></button>`);function PM(e,t){D(t,!0);let n=typeof window<`u`,r=A(()=>Z.t),i=K(t,`class`,7),a=A(()=>!!Z.currentAudioRecorder),o=A(()=>n&&jy.isSupported()),s=A(()=>Z.currentAudioVolume||0),c=j(!1),l=async()=>{try{L(a)?ub.onStopSpeechRecognition():await ub.onStartSpeechRecognition(),M(c,!1)}catch(e){console.error(`Speech recognition error:`,e),M(c,!0)}};$n(()=>()=>{L(a)&&ub.onStopSpeechRecognition()});var u={get class(){return i()},set class(e){i(e),k()}},d=z(),f=P(d),p=e=>{var t=NM();let n;var o=N(t);MM(N(o),{get level(){return L(s)}}),E(o),E(t),I(()=>{G(t,`aria-label`,L(a)?L(r).chatInputStopListening:L(r).chatInputStartListening),n=Da(t,1,`chat-input__mic-button transition-colors ${i()??``}`,null,n,{"chat-input__mic-button--listening":L(a),"chat-input__mic-button--error":L(c)})}),ai(`click`,t,l),B(e,t)};return U(f,e=>{L(o)&&e(p)}),B(e,d),O(u)}oi([`click`]),q(PM,{class:{}},[],[],{mode:`open`});var FM=R(`<div class="chat-input__notification" data-type="error" aria-live="assertive"><!> <span class="chat-input__notification-label"> </span></div>`),IM=R(`<button><!></button>`),LM=R(`<button type="button" class="chat-input__settings-button btn btn--tertiary"><!> <div class="chat-input__settings-button-label"> </div></button>`),RM=R(`<!> <!>`,1),zM=R(`<nav><h2 class="sr-only"> </h2> <div class="chat-input__toggle-area"><!></div> <div class="chat-input__settings"><!></div></nav>`),BM=R(`<form><!> <div class="animated-height chat-input__notification-wrapper" role="presentation"><div class="chat-input__notification-animation-element"><!></div></div> <div role="region"><h2 class="sr-only"> </h2> <textarea name="chat-input-value" class="chat-input__textarea"></textarea> <!> <div class="chat-input__buttons"><!> <button type="submit"><span class="sr-only"> </span> <!></button></div></div></form>`);function VM(e,t){D(t,!0);let n=A(()=>Z.t),r=K(t,`class`,7),i=K(t,`ariaLabel`,7),a=K(t,`onSubmit`,7),o=K(t,`avoidFocusOnMount`,7),s=K(t,`disabledInput`,7),c=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`class`,`ariaLabel`,`onSubmit`,`avoidFocusOnMount`,`disabledInput`]),l=A(()=>Z.data.chatInputValue),u=A(()=>Z.data.selectedTopic),d=A(()=>L(l).trim().length>(Z.data.chatConfig.questionLengthLimit||600)),f=A(()=>L(l).trim()&&!L(d)&&!Z.data.questionHasPii),p=A(()=>Z.data.currentConversationState===`answering`||Z.data.currentConversationState===`searching`),m=A(()=>!L(f)&&!L(p)),h=j(void 0),g,_=A(()=>Z.data?.chatConfig?.allowAudioInput??!0),v=A(()=>!!Z.currentAudioRecorder),y=A(()=>Z.isTranscribing),b=j(0),x=j(void 0),S=j(void 0),C=j(Dn(Z.data.selectorsIsOpen)),ee=j(Dn(Z.data.selectorsIsOpen)),te=A(()=>Z.data.chatConfig.selectorsConfig.length>0),ne=A(()=>Z.data.chatConfig.showExpandedSelectors),re=j(void 0),w,ie=A(()=>{let e=``;return Z.data.questionHasPii?e=Z.piiTranslations[Z.data.questionHasPii]:L(d)&&(e=L(n).messageTooLong?.replace(`{questionLengthLimit}`,(Z.data.chatConfig.questionLengthLimit||600).toString())?.replace(`{questionLength}`,L(l).trim().length.toString())),e}),ae=A(()=>()=>L(y)?L(n).messageBotLoading:L(v)&&L(n).chatInputPlaceholderListening?L(n).chatInputPlaceholderListening:L(u)?.placeholder?L(u).placeholder:L(n).chatInputPlaceholder),oe=()=>{L(p)?ub.abort():L(f)&&(a()(L(l)),pe(),Ay()&&L(h)?.blur())},se=e=>{e.preventDefault(),oe()},ce=e=>{e.key===`Enter`&&!e.shiftKey&&(e.preventDefault(),oe())},le=e=>{e.composedPath()[0].matches(`button, a, textarea, input`)||setTimeout(()=>{L(h)?.blur()},100)},ue=()=>{Ay()&&window.addEventListener(`pointerdown`,le)},de=()=>{Ay()&&window.removeEventListener(`pointerdown`,le)},fe=e=>{if(!e.value){e.value=e.placeholder;let t=Math.ceil(e.scrollHeight);return e.value=``,t}return e.scrollHeight},pe=()=>{qr().then(()=>{if(L(h)){L(h).style.height=`auto`;let e=fe(L(h));L(h).style.height=`${e}px`}})};$n(()=>{L(l)&&pe()});let me=e=>{pe(),ub.onInput(e.currentTarget.value),w&&clearTimeout(w),w=setTimeout(()=>{L(ie)&&ub.setAriaLiveStatusMessage(L(ie))},1e3)},he=()=>{M(C,!1),qr().then(()=>L(x)?.focus())};$n(()=>{if(L(h))return g=new ResizeObserver(()=>{pe()}),g.observe(L(h)),()=>{g.disconnect()}}),$n(()=>{let e=new URLSearchParams(window.location.search),t=e.get(`prefill`);t&&(M(l,t),e.delete(`prefill`),history.replaceState(null,``,`${location.pathname}?${e.toString()}${window.location.hash}`))}),Ii(()=>{!Ay()&&!o()&&setTimeout(()=>{L(h)?.focus()},100)}),$n(()=>{let e=L(C)&&!L(ee);M(ee,L(C),!0),e&&(L(x)?.setAttribute(_b,`true`),Z.data.chatConfig.showExpandedSelectors||qr().then(()=>L(S)?.focus({preventScroll:!0})))});function ge(){L(h)?.focus()}var _e={focus:ge,get class(){return r()},set class(e){r(e),k()},get ariaLabel(){return i()},set ariaLabel(e){i(e),k()},get onSubmit(){return a()},set onSubmit(e){a(e),k()},get avoidFocusOnMount(){return o()},set avoidFocusOnMount(e){o(e),k()},get disabledInput(){return s()},set disabledInput(e){s(e),k()}},ve=BM();ii(`resize`,An,pe),Ja(ve,()=>({name:`chat-input`,onsubmit:se,class:[`chat-input`,{"chat-input--disabled":s()},r()],...c,inert:s()?!0:void 0}));var ye=N(ve);dM(ye,{});var be=F(ye,2);let xe;var Se=N(be),Ce=N(Se),we=e=>{var t=FM(),n=N(t);gb(n,{name:`warning`,class:`chat-input__notification-icon`});var r=F(n,2),i=N(r,!0);E(r),E(t),I(()=>V(i,L(ie))),fa(2,t,()=>wA,()=>({duration:100,delay:1e3})),B(e,t)};U(Ce,e=>{L(ie)&&e(we)}),E(Se),E(be);var Te=F(be,2);let Ee;var De=N(Te),Oe=N(De,!0);E(De);var ke=F(De,2);Un(ke),G(ke,`rows`,1),so(ke,e=>M(h,e),()=>L(h)),_a(ke,(e,t)=>db?.(e,t),()=>`chatInput`),_a(ke,(e,t)=>fb?.(e,t),()=>`chatInput`);var Ae=F(ke,2),je=e=>{var t=z(),r=P(t);{let e=e=>{var t=zM(),r=N(t),i=N(r,!0);E(r);var a=F(r,2),o=N(a);{let e=(e,t)=>{let r=()=>t?.().props;var i=IM();Ja(i,()=>({class:`chat-input__settings-toggle-button btn btn--tertiary btn--square`,...r(),disabled:L(C),"aria-hidden":L(C),"aria-label":L(n).showSettings,tabindex:L(C)?-1:void 0})),gb(N(i),{name:`settings`}),E(i),_a(i,(e,t)=>vb?.(e,t),()=>({text:L(C)?``:L(n).showSettings,position:`top`,delay:0})),so(i,e=>M(x,e),()=>L(x)),B(e,i)};W(o,()=>uE,(t,n)=>{n(t,{child:e,$$slots:{child:!0}})})}E(a);var s=F(a,2);W(N(s),()=>cE,(e,t)=>{t(e,{class:`display-contents`,forceMount:!0,children:(e,t)=>{var r=RM(),i=P(r),a=e=>{var t=LM(),r=N(t);gb(r,{name:`settingsClose`,class:`chat-input__settings-button-icon`});var i=F(r,2),a=N(i,!0);E(i),E(t),so(t,e=>M(S,e),()=>L(S)),I(()=>{G(t,`aria-label`,L(n).hideSettings),G(t,`aria-hidden`,!L(C)),t.disabled=!L(C),G(t,`tabindex`,L(C)?void 0:-1),V(a,L(n).hideSettings)}),ai(`click`,t,he),B(e,t)};U(i,e=>{L(ne)||e(a)}),AM(F(i,2),{get settingsIsOpen(){return L(C)}}),B(e,r)},$$slots:{default:!0}})}),E(s),E(t),I(()=>{G(t,`aria-label`,L(n).ariaSettingsRegion),V(i,L(n).ariaSettings)}),ao(s,`clientHeight`,e=>M(b,e)),B(e,t)};W(r,()=>oE,(t,n)=>{n(t,{get open(){return L(C)},set open(e){M(C,e,!0)},child:e,$$slots:{child:!0}})})}B(e,t)};U(Ae,e=>{L(te)&&e(je)});var Me=F(Ae,2),Ne=N(Me),Pe=e=>{PM(e,{})};U(Ne,e=>{L(_)&&e(Pe)});var Fe=F(Ne,2);let Ie;var Le=N(Fe),Re=N(Le,!0);E(Le);var ze=F(Le,2),Be=e=>{gb(e,{name:`abort`,class:`chat-input__submit-icon`})},Ve=e=>{gb(e,{name:`submit`,class:`chat-input__submit-icon`})};return U(ze,e=>{L(p)?e(Be):e(Ve,-1)}),E(Fe),E(Me),E(Te),E(ve),I(e=>{xe=ka(be,``,xe,{height:L(ie)?`${L(re)}px`:`0px`}),Ee=Da(Te,1,`chat-input__grid`,null,Ee,{"chat-input__grid--has-settings":L(te),"chat-input__grid--settings-is-open":L(C)}),ka(Te,`--chat-input-settings-height: ${L(C)?L(b):0}px`),G(Te,`aria-label`,L(n).ariaAskQuestionRegion),V(Oe,L(n).ariaAskQuestion),Wa(ke,L(l)),G(ke,`aria-label`,i()),G(ke,`placeholder`,e),Fe.disabled=L(m),Ie=Da(Fe,1,`chat-input__submit-button transition-colors`,null,Ie,{"chat-input__submit-button--deactivated":L(m)}),V(Re,L(p)?L(n).chatInputAbort:L(n).chatInputSubmit)},[()=>L(ae)()]),ao(Se,`clientHeight`,e=>M(re,e)),ai(`input`,ke,me),ai(`focusin`,ke,ue),ai(`focusout`,ke,de),ii(`keypress`,ke,ce),B(e,ve),O(_e)}oi([`input`,`focusin`,`focusout`,`click`]),q(VM,{class:{},ariaLabel:{},onSubmit:{},avoidFocusOnMount:{},disabledInput:{}},[],[`focus`],{mode:`open`});var HM=R(`<label class="classification-feedback__option btn btn--secondary"><input type="radio" name="quality"/> </label>`),UM=R(`<fieldset class="classification-feedback__item"><legend class="classification-feedback__label"> </legend> <!></fieldset>`),WM=R(`<label class="classification-feedback__option btn btn--secondary"><input type="radio" name="impact"/> </label>`),GM=R(`<fieldset class="classification-feedback__item"><legend class="classification-feedback__label"> </legend> <!></fieldset>`),KM=R(`<div class="classification-feedback"><div class="classification-feedback__title"> </div> <!> <!></div>`);function qM(e,t){D(t,!0);let n=[],r=[],i=A(()=>Z.t),a=K(t,`impact`,15),o=K(t,`quality`,15),s=K(t,`classificationConfig`,7);var c={get impact(){return a()},set impact(e){a(e),k()},get quality(){return o()},set quality(e){o(e),k()},get classificationConfig(){return s()},set classificationConfig(e){s(e),k()}},l=z(),u=P(l),d=e=>{var t=KM(),c=N(t),l=N(c,!0);E(c);var u=F(c,2),d=e=>{var t=UM(),r=N(t),i=N(r,!0);E(r),Xi(F(r,2),17,()=>s().quality.options,Ki,(e,t)=>{var r=HM(),i=N(r);Ua(i);var a,s=F(i);E(r),I(()=>{a!==(a=L(t).value)&&(i.value=(i.__value=L(t).value)??``),V(s,` ${L(t).label??``}`)}),eo(n,[],i,()=>(L(t).value,o()),o),B(e,r)}),E(t),I(()=>V(i,s().quality.label)),B(e,t)};U(u,e=>{s().quality&&s().quality.options.length!==0&&e(d)});var f=F(u,2),p=e=>{var t=GM(),n=N(t),i=N(n,!0);E(n),Xi(F(n,2),17,()=>s().impact.options,Ki,(e,t)=>{var n=WM(),i=N(n);Ua(i);var o,s=F(i);E(n),I(()=>{o!==(o=L(t).value)&&(i.value=(i.__value=L(t).value)??``),V(s,` ${L(t).label??``}`)}),eo(r,[],i,()=>(L(t).value,a()),a),B(e,n)}),E(t),I(()=>V(i,s().impact.label)),B(e,t)};U(f,e=>{s().impact&&s().impact.options.length!==0&&e(p)}),E(t),I(()=>V(l,L(i).classificationTitle)),B(e,t)};return U(u,e=>{s()&&(s().quality||s().impact)&&e(d)}),B(e,l),O(c)}q(qM,{impact:{},quality:{},classificationConfig:{}},[],[],{mode:`open`});function JM(e,t){D(t,!0);let n=A(()=>Z.t),r=j(void 0),i=j(void 0),a=j(Dn({message:``,email:``})),o=A(()=>[{type:`textarea`,name:`message`,label:L(n).feedbackFormMessage,placeholder:L(n).feedbackFormMessagePlaceholder},...Z.data.chatConfig.showOverallFeedbackEmail?[{type:`email`,name:`email`,label:L(n).feedbackFormEmail,placeholder:L(n).feedbackFormEmailPlaceholder}]:[]]),s=A(()=>L(r)!==void 0||L(i)!==void 0||L(a).message!==``);{let t=e=>{qM(e,{get classificationConfig(){return Z.data.chatConfig.classification},get impact(){return L(r)},set impact(e){M(r,e,!0)},get quality(){return L(i)},set quality(e){M(i,e,!0)}})},c=A(()=>!!Z.data.conversationFeedbackId||Z.data.conversationFeedbackIsOpen);oM(e,{get open(){return L(c)},get onClose(){return ub.closeFeedback},get dialogTitle(){return L(n).feedbackFormTitle},get fields(){return L(o)},get submitEnabled(){return L(s)},get submitLabel(){return L(n).send},onSubmit:async()=>{Z.data.chatConfig.classification?await ub.submitFeedback({email:L(a).email,message:L(a).message,classification:{impact:L(r),quality:L(i)}}):await ub.submitFeedback({email:L(a).email,message:L(a).message}),M(r,void 0),M(i,void 0),M(a,{message:``,email:``},!0),ub.closeFeedback()},get values(){return L(a)},set values(e){M(a,e,!0)},header:t,$$slots:{header:!0}})}O()}q(JM,{},[],[],{mode:`open`});var YM=R(`<div><button class="btn btn--primary" aria-haspopup="dialog"> </button></div>`),XM=R(`<a class="skip-link"> </a>`),ZM=R(`<div class="chat-page__footer-text"></div>`),QM=R(`<section class="chat-page"><!> <!> <div class="chat-page__survey-portal"><div class="container"></div></div> <div class="chat-page__body"><h2 class="sr-only"></h2> <div class="chat-page__messages"></div> <div class="chat-page__buttons"><!></div></div> <div><div class="container"><div class="chat-page__footer-content"><button aria-hidden="true"><span class="sr-only"> </span> <!></button> <!> <!> <!></div></div></div></section>`);function $M(e,t){D(t,!0);let n=A(()=>Z.t),r=j(!1),i=j(void 0),a=j(void 0),o=j(void 0),s=j(void 0),c=j(void 0),l,u=A(()=>Z.data.history.findLast(e=>e.type===`bot`)),d=A(()=>Z.data.history.findLast(e=>e.type===`bot`||e.type===`component`)),f=A(()=>L(d)?.type===`component`&&!!L(d).hideChatInput),p=A(()=>!!L(u)?.noFeedback),m=e=>{l&&Gb(l,l.scrollHeight-l.clientHeight,e,`scrollTop`,_A)},h=()=>{l&&M(r,!(l.scrollHeight-l.scrollTop-l.clientHeight<90))},g,_=j(!1),v=()=>{M(_,!1),g?.disconnect(),g=new IntersectionObserver(([e])=>{e.isIntersecting?(M(_,!0),g.disconnect()):M(_,!1)},{root:Z.targets.scrollContainer,rootMargin:`0px 0px -30% 0px`}),L(s)&&g.observe(L(s))};Ii(()=>(v(),window.addEventListener(`resize`,v),()=>{g?.disconnect(),window.removeEventListener(`resize`,v)}));let y=()=>{h()},b=e=>{if(e.altKey&&e.code===`KeyR`){if(Z.data.chatConfig.forceChatPage)return;e.preventDefault();let t=Z.data.history.findLast(e=>e.type===`user`)?.message;ub.goto({name:`start-page`,prefill:t})}},x=()=>{setTimeout(()=>{let{chatAppContainer:e,chatAppHeader:t,chatPageMessages:n,chatPageLastUserMessage:r}=Z.targets;if(!(Z.data.chatConfig.inlineLayout&&!Z.data.props.flyout&&!Z.data.isInlineLayoutContained)&&e&&t&&L(s)&&n&&L(a)&&L(o)&&r){let i=e.clientHeight-t.offsetHeight-L(s).offsetHeight-L(o).offsetHeight-r.offsetHeight-parseInt(getComputedStyle(n).gap)*2;i>0?(L(a).style.setProperty(`--last-bot-message-min-height`,`${i}px`),m(1e3)):r.scrollIntoView({behavior:`smooth`})}},150)},S=()=>{ub.onSubmit(!0)};$n(()=>{L(i)&&(l=L(i).closest(`.chat-app__main`))}),$n(()=>{if(l)return l.addEventListener(`scroll`,h),()=>{l.removeEventListener(`scroll`,h)}}),$n(()=>{!L(f)&&!Ay()&&qr().then(()=>L(c)?.focus())});let C=e=>{let t=Z.data.history[e-1];t&&t.type===`user`&&(ub.updateChatInput(t.message),L(c)?.focus())};var ee=QM();ii(`resize`,An,y),ii(`keypress`,An,b);var te=N(ee);JM(te,{});var ne=F(te,2);sM(ne,{});var re=F(ne,2);_a(N(re),(e,t)=>fb?.(e,t),()=>`surveyPortal`),E(re);var w=F(re,2),ie=N(w);na(ie,()=>L(n).ariaChatHistory,!0),E(ie);var ae=F(ie,2);Xi(ae,23,()=>Z.data.history,e=>e?.id??e?.time,(e,t,n)=>{{let r=A(()=>L(n)===Z.data.history.length-1);Sj(e,{get message(){return L(t)},get index(){return L(n)},onmessageupdate:h,onbotmessageinit:x,onaskQuestion:()=>{C(L(n))},get isLast(){return L(r)}})}}),E(ae),so(ae,e=>M(a,e),()=>L(a)),_a(ae,(e,t)=>fb?.(e,t),()=>`chatPageMessages`);var oe=F(ae,2),se=N(oe),ce=e=>{var t=YM(),r=N(t),i=N(r,!0);E(r),E(t),I(()=>{Da(t,1,xa([`chat-page__give-feedback`,{"chat-page__give-feedback--disabled":L(p)}])),t.inert=L(p)?!0:void 0,G(r,`aria-expanded`,Z.data.conversationFeedbackIsOpen),V(i,L(n).giveFeedback)}),ai(`click`,r,()=>ub.openConversationFeedback()),B(e,t)};U(se,e=>{Z.data.chatConfig.showOverallFeedbackButton&&e(ce)}),E(oe),so(oe,e=>M(o,e),()=>L(o)),E(w);var le=F(w,2),ue=N(le),de=N(ue),fe=N(de);let pe;G(fe,`tabindex`,-1);var me=N(fe),he=N(me,!0);E(me),gb(F(me,2),{name:`chevronDown`}),E(fe);var ge=F(fe,2);so(VM(ge,{onSubmit:S,class:`chat-page__chat-input`,get disabledInput(){return L(f)}}),e=>M(c,e,!0),()=>L(c));var _e=F(ge,2),ve=e=>{var t=XM(),r=N(t,!0);E(t),I(()=>{G(t,`href`,`#${lI}`),V(r,L(n).ariaGotoMainNavigation)}),ai(`click`,t,function(...e){uI?.apply(this,e)}),B(e,t)};U(_e,e=>{Z.hasMainNavigationContent&&e(ve)});var ye=F(_e,2),be=e=>{var t=ZM();na(t,()=>L(n).chatFooterText,!0),E(t),B(e,t)};U(ye,e=>{L(n).chatFooterText!==void 0&&e(be)}),E(de),E(ue),E(le),so(le,e=>M(s,e),()=>L(s)),E(ee),so(ee,e=>M(i,e),()=>L(i)),I(()=>{Da(le,1,xa([`chat-page__footer`,{"chat-page__footer--unsticked":L(_)}])),pe=Da(fe,1,`chat-page__scroll-to-bottom btn btn--secondary btn--square`,null,pe,{"chat-page__scroll-to-bottom--hidden":!L(r)}),fe.disabled=!L(r),V(he,L(n).scrollToBottom)}),ai(`click`,fe,()=>{m(500)}),B(e,ee),O()}oi([`click`]),q($M,{},[],[],{mode:`open`});var eN=R(`<div><!> <h2 class="introduction__title"></h2></div>`);function tN(e,t){D(t,!0);let n=A(()=>Z.t),r=K(t,`class`,7);var i={get class(){return r()},set class(e){r(e),k()}},a=eN(),o=N(a);lj(o,{class:`introduction__avatar`,isLarge:!0});var s=F(o,2);return na(s,()=>L(n).introductionTitle,!0),E(s),E(a),I(()=>Da(a,1,`introduction ${r()??``}`)),B(e,a),O(i)}q(tN,{class:{}},[],[],{mode:`open`});var nN=R(`<div class="consent-page__disclaimer text-container fly-in" style="--fly-in-id: 1;"></div>`),rN=R(`<button class="btn btn--secondary" type="button"> </button>`),iN=R(`<section><!> <!> <div class="consent-page__actions fly-in" style="--fly-in-id: 2;"><!> <button class="btn btn--primary" type="button"> </button></div></section>`);function aN(e,t){D(t,!0);let n=A(()=>Z.t),r=A(()=>L(n).popups?.find(e=>e.actions?.some(e=>e.action===`acceptTerms`))),i=j(!1);$n(()=>{M(i,!0)});var a=iN();let o;var s=N(a);tN(s,{class:`consent-page__introduction fly-in`});var c=F(s,2),l=e=>{var t=nN();na(t,()=>L(n).termsInvitationToConsent,!0),E(t),B(e,t)};U(c,e=>{L(n).termsInvitationToConsent&&e(l)});var u=F(c,2),d=N(u),f=e=>{var t=rN(),i=N(t,!0);E(t),I(()=>V(i,L(n).termsReadButton)),ai(`click`,t,()=>window.location.hash=L(r).hash),B(e,t)};U(d,e=>{L(r)&&e(f)});var p=F(d,2),m=N(p,!0);E(p),E(u),E(a),I(()=>{o=Da(a,1,`consent-page container`,null,o,{mounted:L(i)}),V(m,L(n).termsAcceptButton)}),ai(`click`,p,()=>ub.acceptTerms()),B(e,a),O()}oi([`click`]),q(aN,{},[],[],{mode:`open`});var oN=R(`<button><span class="sr-only"> </span> <!></button>`),sN=R(`<div><div><button type="button" class="context-box__popover-close"><!> <span class="sr-only"> </span></button> <!></div></div>`),cN=R(`<!> <!>`,1),lN=R(`<div><!></div>`);function uN(e,t){D(t,!0);let n={duration:Number(Z.theme.components.contextBox.custom?.transitionDuration)||200,delay:Number(Z.theme.components.contextBox.custom?.transitionDelay)||0,y:Number(Z.theme.components.contextBox.custom?.transitionY)||10},r=K(t,`openLabel`,7),i=K(t,`closeLabel`,7),a=K(t,`openIcon`,7),o=K(t,`closeIcon`,7),s=K(t,`ariaLabel`,7),c=K(t,`children`,7),l=K(t,`class`,7),u=K(t,`contentClass`,7),d=K(t,`portal`,7),f=j(!1),p=j(void 0);$n(()=>{L(f)?(L(p)?.setAttribute(_b,`true`),Xr(()=>ub.setOpenOverlay(!0))):Xr(()=>ub.setOpenOverlay(!1))});var m={get openLabel(){return r()},set openLabel(e){r(e),k()},get closeLabel(){return i()},set closeLabel(e){i(e),k()},get openIcon(){return a()},set openIcon(e){a(e),k()},get closeIcon(){return o()},set closeIcon(e){o(e),k()},get ariaLabel(){return s()},set ariaLabel(e){s(e),k()},get children(){return c()},set children(e){c(e),k()},get class(){return l()},set class(e){l(e),k()},get contentClass(){return u()},set contentClass(e){u(e),k()},get portal(){return d()},set portal(e){d(e),k()}},h=lN();return W(N(h),()=>gA,(e,t)=>{t(e,{get open(){return L(f)},set open(e){M(f,e,!0)},children:(e,t)=>{var l=cN(),m=P(l);{let e=(e,t)=>{let n=()=>t?.().props;var s=oN();Ja(s,()=>({class:`context-box__trigger btn btn--tertiary btn--square`,...n(),"aria-controls":d()?.id}));var c=N(s),l=N(c,!0);E(c);var u=F(c,2);{let e=A(()=>L(f)?o():a());gb(u,{get name(){return L(e)}})}E(s),_a(s,(e,t)=>vb?.(e,t),()=>({text:L(f)?i():r(),position:`bottom-right`,delay:0})),so(s,e=>M(p,e),()=>L(p)),I(()=>V(l,L(f)?i():r())),B(e,s)};W(m,()=>$k,(t,n)=>{n(t,{child:e,$$slots:{child:!0}})})}var h=F(m,2);{let e=A(()=>d()||Z.targets.portals);W(h,()=>OC,(t,r)=>{r(t,{get to(){return L(e)},children:(e,t)=>{var r=z(),a=P(r);{let e=(e,t)=>{let r=()=>t?.().wrapperProps,a=()=>t?.().props,l=()=>t?.().open;var u=z(),d=P(u),p=e=>{var t=sN();Ja(t,()=>({...r()}));var l=N(t);Ja(l,()=>({...a(),role:`dialog`,"aria-label":s()}));var u=N(l),d=N(u);gb(d,{get name(){return o()}});var p=F(d,2),m=N(p,!0);E(p),E(u),H(F(u,2),c),E(l),_a(l,e=>Tj?.(e)),E(t),I(()=>V(m,i())),ai(`click`,u,()=>M(f,!1)),fa(3,l,()=>TA,()=>n),B(e,t)};U(d,e=>{l()&&e(p)}),B(e,u)},t=A(()=>[`context-box__content`,u()]);W(a,()=>Zk,(n,r)=>{r(n,{get class(){return L(t)},sideOffset:8,alignOffset:-11,align:`end`,side:`bottom`,strategy:`absolute`,onOpenAutoFocus:e=>e.preventDefault(),onCloseAutoFocus:()=>L(p)?.focus(),forceMount:!0,child:e,$$slots:{child:!0}})})}B(e,r)},$$slots:{default:!0}})})}B(e,l)},$$slots:{default:!0}})}),E(h),I(()=>Da(h,1,xa([`context-box`,l()]))),B(e,h),O(m)}oi([`click`]),q(uN,{openLabel:{},closeLabel:{},openIcon:{},closeIcon:{},ariaLabel:{},children:{},class:{},contentClass:{},portal:{}},[],[],{mode:`open`});var dN=R(`<div class="text-container" aria-live="polite"><span class="sr-only"> </span> <!></div>`);function fN(e,t){D(t,!0);let n=A(()=>Z.t),r=K(t,`content`,7);return uN(e,{get openLabel(){return L(n).openInfo},get closeLabel(){return L(n).close},openIcon:`info`,closeIcon:`menuClose`,contentClass:`context-box__content--info`,get portal(){return Z.targets.chatAppHeaderPortal},get ariaLabel(){return L(n).ariaInfoTitle},children:(e,t)=>{var i=dN(),a=N(i),o=N(a,!0);E(a),na(F(a,2),r),E(i),I(()=>V(o,L(n).ariaCloseWithEsc)),B(e,i)},$$slots:{default:!0}}),O({get content(){return r()},set content(e){r(e),k()}})}q(fN,{content:{}},[],[],{mode:`open`});var pN=R(`<button><span class="sr-only"> </span> <!></button>`),mN=R(`<div><div><!></div></div>`),hN=R(`<!> <!>`,1),gN=R(`<div><!></div>`);function _N(e,t){D(t,!0);let n={duration:Number(Z.theme.components.contextBox.custom?.transitionDuration)||200,delay:Number(Z.theme.components.contextBox.custom?.transitionDelay)||0,y:Number(Z.theme.components.contextBox.custom?.transitionY)||10},r=K(t,`openLabel`,7),i=K(t,`closeLabel`,7),a=K(t,`openIcon`,7),o=K(t,`closeIcon`,7),s=K(t,`disableAutoFocusOnOpen`,7,!1),c=K(t,`children`,7),l=K(t,`class`,7),u=K(t,`contentClass`,7),d=K(t,`portal`,7),f=j(!1),p=j(void 0);$n(()=>{L(f)?(L(p)?.setAttribute(_b,`true`),Xr(()=>ub.setOpenOverlay(!0))):Xr(()=>ub.setOpenOverlay(!1))});var m={get openLabel(){return r()},set openLabel(e){r(e),k()},get closeLabel(){return i()},set closeLabel(e){i(e),k()},get openIcon(){return a()},set openIcon(e){a(e),k()},get closeIcon(){return o()},set closeIcon(e){o(e),k()},get disableAutoFocusOnOpen(){return s()},set disableAutoFocusOnOpen(e=!1){s(e),k()},get children(){return c()},set children(e){c(e),k()},get class(){return l()},set class(e){l(e),k()},get contentClass(){return u()},set contentClass(e){u(e),k()},get portal(){return d()},set portal(e){d(e),k()}},h=gN();return W(N(h),()=>oA,(e,t)=>{t(e,{get open(){return L(f)},set open(e){M(f,e,!0)},children:(e,t)=>{var l=hN(),m=P(l);{let e=(e,t)=>{let n=()=>t?.().props;var s=pN();Ja(s,()=>({class:`context-box__trigger btn btn--tertiary btn--square`,...n(),"aria-controls":d()?.id}));var c=N(s),l=N(c,!0);E(c);var u=F(c,2);{let e=A(()=>L(f)?o():a());gb(u,{get name(){return L(e)}})}E(s),_a(s,(e,t)=>vb?.(e,t),()=>({text:L(f)?i():r(),position:`bottom-right`,delay:0})),so(s,e=>M(p,e),()=>L(p)),I(()=>V(l,L(f)?i():r())),B(e,s)};W(m,()=>dA,(t,n)=>{n(t,{child:e,$$slots:{child:!0}})})}var h=F(m,2);{let e=A(()=>d()||Z.targets.portals);W(h,()=>OC,(t,r)=>{r(t,{get to(){return L(e)},children:(e,t)=>{var r=z(),i=P(r);{let e=(e,t)=>{let r=()=>t?.().wrapperProps,i=()=>t?.().props,a=()=>t?.().open;var o=z(),s=P(o),l=e=>{var t=mN();Ja(t,()=>({...r()}));var a=N(t);Ja(a,()=>({...i()})),H(N(a),c),E(a),E(t),fa(3,a,()=>TA,()=>n),B(e,t)};U(s,e=>{a()&&e(l)}),B(e,o)},t=A(()=>[`context-box__content`,u()]);W(i,()=>lA,(n,r)=>{r(n,{get class(){return L(t)},sideOffset:8,alignOffset:-11,align:`end`,side:`bottom`,strategy:`absolute`,onOpenAutoFocus:e=>{s()&&e.preventDefault()},forceMount:!0,child:e,$$slots:{child:!0}})})}B(e,r)},$$slots:{default:!0}})})}B(e,l)},$$slots:{default:!0}})}),E(h),I(()=>Da(h,1,xa([`context-box`,l()]))),B(e,h),O(m)}q(_N,{openLabel:{},closeLabel:{},openIcon:{},closeIcon:{},disableAutoFocusOnOpen:{},children:{},class:{},contentClass:{},portal:{}},[],[],{mode:`open`});var vN=e=>e.charAt(0).toUpperCase()+e.slice(1),yN=R(`<span class="sr-only"> </span>`),bN=R(`<!> <span> <!></span>`,1),xN=R(`<div class="context-box__menu"></div>`),SN=R(`<!> <span> </span>`,1),CN=R(`<!> <div class="context-box__menu"></div>`,1),wN=R(`<!> <!>`,1),TN=R(`<!> <span> </span>`,1),EN=R(`<!> <span> </span>`,1),DN=R(`<!> <div class="context-box__color-scheme-selector"><!> <!> <!></div>`,1),ON=R(`<!> <!>`,1),kN=R(`<!> <!> <!>`,1);function AN(e,t){D(t,!0);let n=A(()=>Z.t),r=e=>{ub.onLanguageChange(e)},i=e=>`Intl`in globalThis&&Intl.DisplayNames?vN(new Intl.DisplayNames([e],{type:`language`}).of(e)??e.toUpperCase()):e.toUpperCase(),a=e=>{Z.data.selectedColorScheme===e?ub.setColorScheme(`system`):ub.setColorScheme(e)};_N(e,{get openLabel(){return L(n).openMenu},get closeLabel(){return L(n).closeMenu},openIcon:`menu`,closeIcon:`menuClose`,contentClass:`context-box__content--menu`,get portal(){return Z.targets.chatAppHeaderPortal},children:(e,t)=>{var o=kN(),s=P(o),c=e=>{var t=xN();Xi(t,21,()=>Z.menu,Ki,(e,t)=>{var r=z();W(P(r),()=>Tk,(e,r)=>{r(e,{class:`context-box__menu-item transition-colors`,onSelect:()=>window.open(L(t).url,L(t).target,`noopener,noreferrer`),closeOnSelect:!0,children:(e,r)=>{var i=bN(),a=P(i);gb(a,{get name(){return L(t).icon},class:`context-box__menu-item__icon`});var o=F(a,2),s=N(o,!0),c=F(s),l=e=>{var t=yN(),r=N(t);E(t),I(()=>V(r,`, ${L(n).ariaOpensInNewTab??``}`)),B(e,t)};U(c,e=>{L(t).target===`_blank`&&e(l)}),E(o),I(()=>V(s,L(t).label)),B(e,i)},$$slots:{default:!0}})}),B(e,r)}),E(t),B(e,t)};U(s,e=>{Z.menu.length>0&&e(c)});var l=F(s,2),u=e=>{var t=wN(),a=P(t),o=e=>{var t=z();W(P(t),()=>Nk,(e,t)=>{t(e,{class:`context-box__separator`,"aria-hidden":`true`})}),B(e,t)};U(a,e=>{Z.menu.length>0&&e(o)}),W(F(a,2),()=>Fk,(e,t)=>{t(e,{children:(e,t)=>{var a=CN(),o=P(a);W(o,()=>kk,(e,t)=>{t(e,{class:`context-box__title`,"aria-hidden":`true`,children:(e,t)=>{Ze();var r=hi();I(()=>V(r,L(n).selectLanguage)),B(e,r)},$$slots:{default:!0}})});var s=F(o,2);Xi(s,21,()=>Z.data.chatConfig.supportedLanguages,Ki,(e,t)=>{var n=z(),a=P(n);{let e=A(()=>[`context-box__menu-item transition-colors`,{active:Z.data.language===L(t)}]);W(a,()=>jk,(n,a)=>{a(n,{get value(){return L(t)},closeOnSelect:!0,get class(){return L(e)},onSelect:()=>r(L(t)),children:(e,n)=>{var r=SN(),a=P(r);gb(a,{name:`internalLink`,class:`context-box__menu-item__icon`});var o=F(a,2),s=N(o,!0);E(o),I(e=>V(s,e),[()=>i(L(t))]),B(e,r)},$$slots:{default:!0}})})}B(e,n)}),E(s),B(e,a)},$$slots:{default:!0}})}),B(e,t)};U(l,e=>{Z.data.chatConfig.supportedLanguages.length>0&&e(u)});var d=F(l,2),f=e=>{var t=ON(),r=P(t);W(r,()=>Nk,(e,t)=>{t(e,{class:`context-box__separator`,"aria-hidden":`true`})}),W(F(r,2),()=>Fk,(e,t)=>{t(e,{children:(e,t)=>{var r=DN(),i=P(r);W(i,()=>kk,(e,t)=>{t(e,{class:`context-box__title sr-only`,"aria-hidden":`true`,children:(e,t)=>{Ze();var r=hi();I(()=>V(r,L(n).selectColorTheme)),B(e,r)},$$slots:{default:!0}})});var o=F(i,2),s=N(o);{let e=A(()=>[`context-box__color-scheme-selector-button transition-colors`,{"context-box__color-scheme-selector-button--active":Z.data.selectedColorScheme===`light`}]);W(s,()=>jk,(t,n)=>{n(t,{value:`light`,closeOnSelect:!0,get class(){return L(e)},onSelect:()=>a(`light`),children:(e,t)=>{var n=TN(),r=P(n);gb(r,{name:`lightMode`});var i=F(r,2),a=N(i,!0);E(i),I(()=>V(a,Z.t.lightMode)),B(e,n)},$$slots:{default:!0}})})}var c=F(s,2);W(c,()=>Nk,(e,t)=>{t(e,{class:`context-box__color-scheme-selector-separator`,"aria-hidden":`true`})});var l=F(c,2);{let e=A(()=>[`context-box__color-scheme-selector-button transition-colors`,{"context-box__color-scheme-selector-button--active":Z.data.selectedColorScheme===`dark`}]);W(l,()=>jk,(t,n)=>{n(t,{value:`dark`,closeOnSelect:!0,get class(){return L(e)},onSelect:()=>a(`dark`),children:(e,t)=>{var n=EN(),r=P(n);gb(r,{name:`darkMode`});var i=F(r,2),a=N(i,!0);E(i),I(()=>V(a,Z.t.darkMode)),B(e,n)},$$slots:{default:!0}})})}E(o),B(e,r)},$$slots:{default:!0}})}),B(e,t)};U(d,e=>{Z.data.has2ColorSchemes&&e(f)}),B(e,o)},$$slots:{default:!0}}),O()}q(AN,{},[],[],{mode:`open`});var jN=R(`<span class="btn__label"> </span>`),MN=R(`<div><button class="btn btn--tertiary btn--square"><!> <!></button></div>`);function NN(e,t){D(t,!0);let n=A(()=>Z.t),r=K(t,`class`,7);var i={get class(){return r()},set class(e){r(e),k()}},a=MN(),o=N(a),s=N(o);gb(s,{name:`newConversation`});var c=F(s,2),l=e=>{var t=jN(),r=N(t,!0);E(t),I(()=>V(r,L(n).newChat)),B(e,t)};return U(c,e=>{L(n).newChat&&e(l)}),E(o),_a(o,(e,t)=>vb?.(e,t),()=>({text:L(n).newChat,position:`bottom-left`,delay:600})),E(a),I(()=>{Da(a,1,xa([`new-conversation`,r()])),G(o,`aria-label`,L(n).newChat)}),ai(`click`,o,()=>ub.onNewConversation()),fa(1,a,()=>TA,()=>({duration:300,y:30})),fa(2,a,()=>TA,()=>({y:15,duration:150,easing:vA})),B(e,a),O(i)}oi([`click`]),q(NN,{class:{}},[],[],{mode:`open`});var PN=R(`<div><div><!></div></div>`);function FN(e,t){D(t,!0);let n=K(t,`class`,7),r=K(t,`children`,7),i=j(void 0);var a={get class(){return n()},set class(e){n(e),k()},get children(){return r()},set children(e){r(e),k()}},o=PN();let s;var c=N(o);return H(N(c),()=>r()??w),E(c),E(o),I(()=>{Da(o,1,xa([`animated-height`,n()])),s=ka(o,``,s,{height:L(i)?`${L(i)}px`:`auto`})}),ao(c,`clientHeight`,e=>M(i,e)),B(e,o),O(a)}q(FN,{class:{},children:{}},[],[],{mode:`open`});var IN=R(`<span class="reference__number transition-colors"> </span>`),LN=R(`<span class="reference__description transition-colors line-clamp line-clamp--6"> </span>`),RN=R(`<span class="reference__breadcrumb transition-colors"> </span>`),zN=R(`<div class="reference__footer"><span class="reference__domain transition-colors"><span class="truncate"> </span></span> <!></div>`),BN=R(`<a target="_blank" rel="noopener noreferrer" class="reference transition-colors"><!> <span class="reference__body transition-colors"><span class="reference__header"><span class="reference__title line-clamp line-clamp--2 h4"> </span> <!></span> <!> <!></span></a>`);function VN(e,t){D(t,!0);let n=K(t,`reference`,7),r=A(()=>`${n().display.listItem.title}. ${n().display.card.description}. ${Z.t.ariaReferenceSource} ${n().display.listItem.badge}${n().display.listItem.breadcrumbs?` / `+n().display.listItem.breadcrumbs.join(` / `):``}`);var i={get reference(){return n()},set reference(e){n(e),k()}},a=BN(),o=N(a),s=e=>{var t=IN(),r=N(t,!0);E(t),I(()=>V(r,n().referenceIndex.used)),B(e,t)};U(o,e=>{n().referenceIndex.used&&e(s)});var c=F(o,2),l=N(c),u=N(l),d=N(u,!0);E(u),gb(F(u,2),{name:`externalLink`,class:`reference__icon transition-colors`}),E(l);var f=F(l,2),p=e=>{var t=LN(),r=N(t,!0);E(t),I(()=>V(r,n().display.card.description)),B(e,t)};U(f,e=>{n().display.card.description&&e(p)});var m=F(f,2),h=e=>{var t=zN(),r=N(t),i=N(r),a=N(i,!0);E(i),E(r);var o=F(r,2),s=e=>{var t=z();Xi(P(t),17,()=>n().display.listItem.breadcrumbs,Ki,(e,t)=>{var n=RN(),r=N(n,!0);E(n),I(()=>V(r,L(t))),B(e,n)}),B(e,t)};U(o,e=>{n().display.listItem.breadcrumbs&&e(s)}),E(t),I(()=>V(a,n().display.listItem.badge)),B(e,t)};return U(m,e=>{n().display.listItem.badge&&e(h)}),E(c),E(a),I(()=>{G(a,`href`,n().url),G(a,`aria-label`,L(r)),V(d,n().display.listItem.title)}),B(e,a),O(i)}q(VN,{reference:{}},[],[],{mode:`open`});function HN(e,{delay:t=0,duration:n=500,resetTop:r=!0}){let i=+getComputedStyle(e).opacity;return e.style.position=`absolute`,r&&(e.style.top=`0px`),{delay:t,duration:n,css:e=>`opacity: ${e*i};`}}var UN=R(`<div><!></div>`),WN=R(`<div class="references__toggle-title"> </div> <!>`,1),GN=R(`<div><div class="references__items"></div></div>`),KN=R(`<div><!></div>`),qN=R(`<!> <!>`,1),JN=R(`<div><!></div>`),YN=R(`<div><div class="references__items"></div> <!></div>`),XN=R(`<div><div class="references__container"><div class="references__transition"><!></div></div></div>`);function ZN(e,t){D(t,!0);let n=K(t,`class`,7),r=A(()=>Z.data.history.filter(e=>e.type===`bot`).find(e=>e.id===Z.data.currentReferencesAsideId)?.references),i=A(()=>Z.data.currentReferencesAsideId),a=j(void 0),o=j(!1),s=j(void 0);$n(()=>{L(i)&&M(o,!1),M(a,L(i),!0)}),$n(()=>{L(o)&&setTimeout(()=>{Z.data.chatConfig.inlineLayout===!1&&L(s)?.scrollIntoView({behavior:`smooth`})},200)});let c={delay:200,duration:500,easing:yA,y:50};var l={get class(){return n()},set class(e){n(e),k()}},u=XN(),d=N(u),f=N(d);return Gi(N(f),()=>Z.data.currentReferencesAsideId,e=>{var t=YN(),l=N(t);Xi(l,21,()=>L(r)?.used,Ki,(e,t)=>{var n=UN();VN(N(n),{get reference(){return L(t)}}),E(n),fa(1,n,()=>TA,()=>({...c,delay:0})),B(e,n)}),E(l);var u=F(l,2),d=e=>{var t=JN();FN(N(t),{children:(e,t)=>{var i=z();W(P(i),()=>oE,(e,t)=>{t(e,{get class(){return`references__further ${n()??``}`},get open(){return L(o)},set open(e){M(o,e,!0)},children:(e,t)=>{var n=qN(),i=P(n);W(i,()=>uE,(e,t)=>{t(e,{class:`references__toggle transition-colors`,children:(e,t)=>{var n=WN(),r=P(n),i=N(r,!0);E(r),gb(F(r,2),{name:`chevronDown`,class:`references__toggle-icon`}),I(()=>V(i,Z.t.referencesFurtherTitle)),B(e,n)},$$slots:{default:!0}})});var a=F(i,2);{let e=(e,t)=>{let n=()=>t?.().props,i=()=>t?.().open;var a=KN();Ja(a,()=>({...n(),class:`references__container`}));var o=N(a),l=e=>{var t=GN(),n=N(t);Xi(n,21,()=>L(r)?.unused,Ki,(e,t)=>{VN(e,{get reference(){return L(t)}})}),E(n),E(t),fa(1,t,()=>TA,()=>({...c,delay:0})),fa(2,t,()=>wA,()=>({duration:100})),B(e,t)};U(o,e=>{i()&&e(l)}),E(a),so(a,e=>M(s,e),()=>L(s)),B(e,a)};W(a,()=>cE,(t,n)=>{n(t,{forceMount:!0,child:e,$$slots:{child:!0}})})}B(e,n)},$$slots:{default:!0}})}),B(e,i)},$$slots:{default:!0}}),E(t),fa(1,t,()=>TA,()=>c),B(e,t)};U(u,e=>{L(r)?.unused&&L(r).unused.length>0&&e(d)}),E(t),fa(2,t,()=>HN,()=>({duration:200,delay:L(i)?0:200})),fa(1,t,()=>TA,()=>L(a)?c:{duration:0,y:0}),B(e,t)}),E(f),E(d),E(u),I(()=>Da(u,1,xa([`references`,n()]))),B(e,u),O(l)}q(ZN,{class:{}},[],[],{mode:`open`});var QN=R(`<button class="predefined-question transition-colors"><!> </button>`);function $N(e,t){D(t,!0);let n=K(t,`onSubmit`,7),r=K(t,`predefinedQuestion`,7),i=K(t,`index`,7);var a={get onSubmit(){return n()},set onSubmit(e){n(e),k()},get predefinedQuestion(){return r()},set predefinedQuestion(e){r(e),k()},get index(){return i()},set index(e){i(e),k()}},o=QN(),s=N(o);gb(s,{name:`predefinedQuestion`,class:`predefined-question__icon transition-colors`});var c=F(s,1,!0);return E(o),_a(o,(e,t)=>db?.(e,t),()=>`predefinedQuestion`),I(()=>{G(o,`data-index`,i()),V(c,r().label??r().question)}),ai(`click`,o,()=>n()(r().question,r().id,r().switchQuestionId)),B(e,o),O(a)}oi([`click`]),q($N,{onSubmit:{},predefinedQuestion:{},index:{}},[],[],{mode:`open`});var eP=R(`<li><!></li>`),tP=R(`<section><h2 class="sr-only"> </h2> <ul></ul></section>`);function nP(e,t){D(t,!0);let n=K(t,`class`,7),r=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`class`]);var i={get class(){return n()},set class(e){n(e),k()}},a=tP();Ja(a,()=>({"aria-label":Z.t.ariaPredefinedQuestionsRegion,class:n(),...r}));var o=N(a),s=N(o,!0);E(o);var c=F(o,2);let l;return Xi(c,21,()=>Z.data.predefinedQuestions,Ki,(e,t,n)=>{var r=eP();$N(N(r),{get predefinedQuestion(){return L(t)},get onSubmit(){return ub.onStartConversation},index:n}),E(r),B(e,r)}),E(c),E(a),I(()=>{V(s,Z.t.ariaPredefinedQuestions),l=Da(c,1,`predefined-questions`,null,l,{"predefined-questions--pii-padding":Z.data.questionHasPii})}),B(e,a),O(i)}q(nP,{class:{}},[],[],{mode:`open`});var rP=R(`<div class="introduction-disclaimer text-container fly-in"></div>`),iP=R(`<section><!> <!> <!> <!></section>`);function aP(e,t){D(t,!0);let n=A(()=>Z.t),r=j(!1);$n(()=>{M(r,!0)});let i=A(()=>Z.data.predefinedQuestions&&Z.data.predefinedQuestions.length),a=A(()=>L(i)&&Z.data.chatConfig.forcePredefinedQuestions);var o=iP();let s;var c=N(o);tN(c,{class:`start-page__introduction fly-in`});var l=F(c,2),u=e=>{{let t=A(()=>rl(L(n).introductionTitle||``));VM(e,{get onSubmit(){return ub.onStartConversation},class:`start-page__chat-input fly-in`,style:`--fly-in-id: 1;`,get ariaLabel(){return L(t)}})}};U(l,e=>{L(a)||e(u)});var d=F(l,2),f=e=>{{let t=A(()=>L(a)?1:2);nP(e,{class:`start-page__predefined-questions fly-in`,get style(){return`--fly-in-id: ${L(t)??``};`}})}};U(d,e=>{L(i)&&e(f)});var p=F(d,2),m=e=>{var t=rP();na(t,()=>L(n).introductionDisclaimer,!0),E(t),I(()=>ka(t,`--fly-in-id: ${L(a)?2:3};`)),B(e,t)};U(p,e=>{L(n).introductionDisclaimer&&e(m)}),E(o),I(()=>s=Da(o,1,`start-page container`,null,s,{mounted:L(r)})),B(e,o),O()}q(aP,{},[],[],{mode:`open`});var oP=RegExp(`([\\p{Ll}\\d])(\\p{Lu})`,`gu`),sP=RegExp(`(\\p{Lu})([\\p{Lu}][\\p{Ll}])`,`gu`),cP=RegExp(`(\\d)(\\p{Ll})`,`gu`),lP=RegExp(`(\\p{L})(\\d)`,`gu`),uP=/[^\p{L}\d]+/giu,dP=`$1\0$2`,fP=``;function pP(e,t){let n=e.trim();n=n.replace(oP,dP).replace(sP,dP),t?.separateNumbers&&(n=n.replace(cP,dP).replace(lP,dP)),n=n.replace(uP,`\0`);let r=0,i=n.length;for(;n.charAt(r)===`\0`;)r++;if(r===i)return[];for(;n.charAt(i-1)===`\0`;)i--;return n.slice(r,i).split(/\0/g)}function mP(e,t){return kP(e,t?.prefixCharacters)+pP(e,t).map(TP(t?.locale)).join(t?.delimiter??` `)}function hP(e,t){let n=kP(e,t?.prefixCharacters),r=TP(t?.locale),i=EP(t?.locale),a=t?.mergeAmbiguousCharacters?DP(r,i):OP(r,i);return n+pP(e,t).map((e,t)=>t===0?r(e):a(e,t)).join(t?.delimiter??``)}function gP(e,t){let n=kP(e,t?.prefixCharacters),r=TP(t?.locale),i=EP(t?.locale),a=t?.mergeAmbiguousCharacters?DP(r,i):OP(r,i);return n+pP(e,t).map(a).join(t?.delimiter??``)}function _P(e,t){let n=kP(e,t?.prefixCharacters),r=TP(t?.locale),i=EP(t?.locale);return n+pP(e,t).map(DP(r,i)).join(t?.delimiter??` `)}function vP(e,t){return kP(e,t?.prefixCharacters)+pP(e,t).map(EP(t?.locale)).join(t?.delimiter??`_`)}function yP(e,t){return mP(e,{delimiter:`.`,...t})}function bP(e,t){return mP(e,{delimiter:`-`,...t})}function xP(e,t){return mP(e,{delimiter:`/`,...t})}function SP(e,t){let n=kP(e,t?.prefixCharacters),r=TP(t?.locale),i=DP(r,EP(t?.locale));return n+pP(e,t).map((e,t)=>t===0?i(e):r(e)).join(t?.delimiter??` `)}function CP(e,t){return mP(e,{delimiter:`_`,...t})}function wP(e,t){return _P(e,{delimiter:`-`,...t})}function TP(e){return e===!1?e=>e.toLowerCase():t=>t.toLocaleLowerCase(e)}function EP(e){return e===!1?e=>e.toUpperCase():t=>t.toLocaleUpperCase(e)}function DP(e,t){return n=>`${t(n[0])}${e(n.slice(1))}`}function OP(e,t){return(n,r)=>{let i=n[0];return(r>0&&i>=`0`&&i<=`9`?`_`+i:t(i))+e(n.slice(1))}}function kP(e,t=fP){let n=``;for(let r=0;r<e.length;r++){let i=e.charAt(r);if(t.includes(i))n+=i;else break}return n}function AP(e,t){let n=``;for(let r of e)n+=Math.random()>.5?r.toLocaleUpperCase(t):r.toLocaleLowerCase(t);return n}function jP(e,t){let n=``;for(let r of e){let e=r.toLocaleLowerCase(t);n+=r===e?r.toLocaleUpperCase(t):e}return n}var MP=/\b(?:an?d?|a[st]|because|but|by|en|for|i[fn]|neither|nor|o[fnr]|only|over|per|so|some|tha[tn]|the|to|up|upon|vs?\.?|versus|via|when|with|without|yet)\b/i,NP=/[^\s:–—-]+|./g,PP=/\s/,FP=/.(?=[A-Z]|\..)/,IP=/[A-Za-z0-9\u00C0-\u00FF]/;function LP(e){for(var t=``,n;(n=NP.exec(e))!==null;){var r=n[0],i=n.index;if(!FP.test(r)&&(!MP.test(r)||i===0||i+r.length===e.length)&&(e.charAt(i+r.length)!==`:`||PP.test(e.charAt(i+r.length+1)))){t+=r.replace(IP,function(e){return e.toUpperCase()});continue}t+=r}return t}var RP=hP,zP=_P,BP=vP,VP=yP,HP=mP,UP=gP,WP=xP,GP=SP,KP=CP,qP=wP,JP=bP,YP=AP,XP=jP,ZP=LP,QP=e=>e.toUpperCase(),$P=(e,t)=>e.toLocaleUpperCase(t),eF=e=>e.toLowerCase(),tF=(e,t)=>e.toLocaleLowerCase(t),nF=e=>e.charAt(0).toLowerCase()+e.slice(1),rF=e=>e.charAt(0).toUpperCase()+e.slice(1),iF=e=>e===e.toUpperCase(),aF=e=>e===e.toLowerCase(),oF=class{};oF.camel=RP,oF.capital=zP,oF.constant=BP,oF.dot=VP,oF.kebab=JP,oF.lower=eF,oF.lowerFirst=nF,oF.localeLower=tF,oF.localeUpper=$P,oF.no=HP,oF.pascal=UP,oF.path=WP,oF.sentence=GP,oF.snake=KP,oF.sponge=YP,oF.swap=XP,oF.title=ZP,oF.train=qP,oF.upper=QP,oF.upperFirst=rF,oF.isUpper=iF,oF.isLower=aF;var sF=640,cF=1024,lF=null,uF=()=>{if(lF)return lF;if(!globalThis.document)return 16;let e=globalThis.document.querySelector(`:root`);return lF=Number(getComputedStyle(e).fontSize.slice(0,-2)),lF},dF=({minRem:e,maxRem:t})=>{let n=uF(),r=sF/n,i=cF/n,a=(t-e)/(i-r);return`clamp( ${e}rem, ${-r*a+e}rem + ${a*100}cqw, ${t}rem )`},fF=e=>typeof e==`string`?e:typeof e==`number`?String(e):typeof e==`object`?e.minRem===e.maxRem?`${e.minRem}rem`:dF(e):``,pF=(e,t,n,r=!1)=>{let i=``;return n.forEach(n=>{let a=t[n];r&&!a&&n===`borderWidth`&&(a=`0px`),r&&!a&&n===`borderColor`&&(a=`transparent`),a&&(i+=`--${JP(e)}-${JP(n)}:${fF(a)}; `)}),i},mF=(e,t)=>Object.entries(t).map(([t,n])=>`--${e}-${JP(t)}:${fF(n)}`).join(`; `)+`; `,hF=(e,t)=>{let n=``;return n+=pF(e,t,[`background`,`borderWidth`,`borderColor`,`boxShadow`,`borderRadius`,`color`],!0),t.hover&&(n+=pF(`${e}-hover`,t.hover,[`background`,`borderWidth`,`borderColor`,`boxShadow`,`color`])),t.focus&&(n+=pF(`${e}-focus`,t.focus,[`background`,`borderWidth`,`borderColor`,`boxShadow`,`color`])),t.custom&&(n+=mF(e,t.custom)),n},gF=(e,t)=>Object.entries(t).map(([t,n])=>`--color-${e}-${t}:${n}`).join(`; `)+`; `,_F=e=>`--font-family: ${e?.family||`inherit`};`,vF=(e,t={})=>`${t.root??`.chat-app`} {${_F(e.font)} ${Object.entries(e.colors).map(([e,t])=>gF(e,t)).join(``)} ${mF(`base`,e.base)} ${Object.entries(e.components).map(([e,t])=>hF(JP(e),t)).join(``)}};`;function yF(e,t){D(t,!0);let n=K(t,`css`,7),r=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`css`]),i=e=>{$n(()=>{n()&&(e.innerHTML=n())})};var a={get css(){return n()},set css(e){n(e),k()}},o=z(),s=P(o),c=e=>{var t=z();ma(P(t),()=>`style`,!1,(e,t)=>{_a(e,e=>i?.(e)),Ja(e,()=>({...r}))}),B(e,t)};return U(s,e=>{n()&&e(c)}),B(e,o),O(a)}q(yF,{css:{}},[],[],{mode:`open`});var bF=`@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;tab-size:4;font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent;font-family:ui-sans-serif,system-ui,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;line-height:1.5}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-feature-settings:normal;font-variation-settings:normal;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab, red, red)){::placeholder{color:color-mix(in oklab, currentcolor 50%, transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){appearance:button}::file-selector-button{appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}.chat-app{--spacer-1:.0625rem;--spacer-2:.125rem;--spacer-3:.1875rem;--spacer-4:.25rem;--spacer-5:.3125rem;--spacer-6:.375rem;--spacer-8:.5rem;--spacer-10:.625rem;--spacer-12:.75rem;--spacer-16:1rem;--spacer-20:1.25rem;--spacer-24:1.5rem;--spacer-28:1.75rem;--spacer-32:2rem;--spacer-40:2.5rem;--spacer-48:3rem;--spacer-56:3.5rem;--spacer-64:4rem;--spacer-72:4.5rem;--spacer-80:5rem;--spacer-120:7.5rem;--spacer-r-8:clamp(.375rem, .3182rem + .2841cqw, .5rem);--spacer-r-12:clamp(.625rem, .5682rem + .2841cqw, .75rem);--spacer-r-16:clamp(.75rem, .6364rem + .5682cqw, 1rem);--spacer-r-20:clamp(.875rem, .7045rem + .8523cqw, 1.25rem);--spacer-r-24:clamp(1rem, .7727rem + 1.1364cqw, 1.5rem);--spacer-r-28:clamp(1.125rem, .8409rem + 1.4205cqw, 1.75rem);--spacer-r-32:clamp(1.25rem, .9091rem + 1.7045cqw, 2rem);--spacer-r-40:clamp(1.5rem, 1.0455rem + 2.2727cqw, 2.5rem);--spacer-r-48:clamp(1.625rem, 1rem + 3.125cqw, 3rem);--spacer-r-56:clamp(1.75rem, .9545rem + 3.9773cqw, 3.5rem);--spacer-r-64:clamp(2rem, 1.0909rem + 4.5455cqw, 4rem);--spacer-r-80:clamp(3rem, 2.0909rem + 4.5455cqw, 5rem);--spacer-r-96:clamp(3.5rem, 2.3636rem + 5.6818cqw, 6rem);--spacer-r-120:clamp(4rem, 2.4091rem + 7.9545cqw, 7.5rem);--default-transition-duration:.2s;--default-transition-timing-function:ease-in-out;--z-index-flyout:10000;--z-index-dialog:600;--z-index-loader:500;--z-index-reference-number:400;--z-index-footer:300;--z-index-header:200;--z-index-tooltip:100;--z-index-tooltip-hover:101;--z-index-local-overlay:10;--z-index-below:-10;--ease-out-quart:cubic-bezier(.165, .84, .44, 1);--ease-in-quart:cubic-bezier(.895, .03, .685, .22);--ease-in-out-quart:cubic-bezier(.77, 0, .175, 1);--fly-in-id:0;--btn-padding-x:var(--spacer-r-20);--btn-padding-y:var(--spacer-r-8);--btn-icon-size:var(--spacer-24);--btn-submit-size:2.5em;--last-bot-message-min-height:0}.chat-app :where(h1,.h1,h2,.h2,h3,.h3,h4,.h4,h5,.h5,h6,.h6){font-weight:var(--base-font-weight-title);line-height:var(--base-line-height-tight)}.chat-app :where(b,strong){font-weight:var(--base-font-weight-bold)}.chat-app :where(button){cursor:pointer}.chat-app :where(input[type=text],input[type=email],input[type=search],input[type=password],textarea,select){width:100%;padding:var(--input-padding);border-width:var(--input-border-width);border-radius:var(--input-border-radius);border-color:var(--input-border-color);background:var(--input-background);box-shadow:var(--input-box-shadow,none);color:var(--input-color)}.chat-app :where(input[type=text],input[type=email],input[type=search],input[type=password],textarea,select)::placeholder{color:var(--input-placeholder-color);opacity:var(--input-placeholder-opacity)}.chat-app :where(input[type=radio],input[type=checkbox]){margin:0}.chat-app :where(:focus-visible){border-radius:var(--btn-primary-border-radius);outline-color:var(--body-focus-color);outline-style:var(--body-focus-style);outline-width:var(--body-focus-width);outline-offset:var(--body-focus-offset)}.chat-app ::selection{background:var(--body-selection-background);color:var(--body-selection-color)}.chat-app ::-webkit-scrollbar{width:8px;height:8px}.chat-app ::-webkit-scrollbar-track{background:0 0}.chat-app ::-webkit-scrollbar-thumb{background-color:#0000004d;border-radius:4px;transition:background-color .2s}.chat-app ::-webkit-scrollbar-thumb:hover{background-color:#00000080}.chat-app *{scrollbar-color:#0000004d transparent;scrollbar-width:thin}.chat-app ::-webkit-scrollbar-thumb{visibility:hidden}.chat-app :hover::-webkit-scrollbar-thumb{visibility:visible}.chat-app :active::-webkit-scrollbar-thumb{visibility:visible}.chat-app :focus::-webkit-scrollbar-thumb{visibility:visible}.svg{width:var(--spacer-r-24);height:auto}.svg svg{width:100%;height:auto;display:block;overflow:visible}.toast{width:100%;padding:var(--spacer-r-20);align-items:center;gap:var(--spacer-16);border-width:var(--toast-border-width,1px);border-radius:var(--toast-border-radius);border-color:var(--toast-border-color,transparent);background:var(--toast-background);box-shadow:var(--toast-box-shadow);color:var(--toast-color);display:flex}.toast[data-type=success] svg{color:var(--toast-icon-success-color)}.toast[data-type=error] svg{color:var(--toast-icon-error-color)}.toast[data-type=warning] svg{color:var(--toast-icon-warning-color)}.toast[data-type=info] svg{color:var(--toast-icon-info-color)}.toast svg{width:var(--spacer-24)!important;height:var(--spacer-24)!important}ol[data-sonner-toaster=true]{border:var(--spacer-16) solid transparent;max-width:600px;width:100%!important}}@layer utilities{.chat-app :where(.expand-interaction){position:relative}.chat-app :where(.expand-interaction):after{content:"";background-color:#0000;position:absolute;inset:0}.chat-app :where(.sr-only){clip:rect(0, 0, 0, 0);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.chat-app :where(.transition-colors){transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color,box-shadow;transition-timing-function:var(--default-transition-timing-function)}.chat-app :where(.transition){transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter;transition-timing-function:var(--default-transition-timing-function)}.chat-app :where(.skip-link){width:0;height:0;color:var(--anchor-color);font-weight:700;font-size:var(--base-font-size-xs);position:absolute;overflow:hidden}.chat-app :where(.skip-link):focus-visible{width:auto;height:auto;position:static}.chat-app :where(.fly-in){--fly-in-id:0;--fly-in-duration:.4s;--fly-out-duration:.2s;--fly-in-delay:.3s;--fly-in-delay-additional:.1s;--fly-in-y:var(--spacer-r-64);transform:translateY(var(--fly-in-y));opacity:0;transition-delay:0s,1s;transition-duration:var(--fly-out-duration);transition-property:opacity,transform;transition-timing-function:ease, var(--ease-out-quart)}.chat-app :where(.mounted .fly-in){opacity:1;transition-delay:calc(var(--fly-in-delay) + var(--fly-in-id) * var(--fly-in-delay-additional));transition-duration:var(--fly-in-duration);transform:translateY(0)}.chat-app :where(.truncate){text-overflow:ellipsis;white-space:nowrap;display:inline-block;overflow:hidden}.chat-app :where(.line-clamp){-webkit-line-clamp:1;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.chat-app :where(.line-clamp--2){-webkit-line-clamp:2}.chat-app :where(.line-clamp--6){-webkit-line-clamp:6}.chat-app :where(.container){width:100%;max-width:var(--container-max-width,1024px);padding-right:var(--spacer-16);padding-left:var(--spacer-16);margin:0 auto}@container chat-container (width>=640px){.chat-app :where(.container){padding-right:var(--spacer-32);padding-left:var(--spacer-32)}}@container chat-container (width>=768px){.chat-app :where(.container){padding-right:var(--spacer-48);padding-left:var(--spacer-48)}}.chat-app :where(h1){font-size:var(--base-font-size-h1)}.chat-app :where(h2){font-size:var(--base-font-size-h2)}.chat-app :where(h3){font-size:var(--base-font-size-h3)}.chat-app :where(h4,h5,h6){font-size:var(--body-font-size)}.chat-app :where(.h1){font-size:var(--base-font-size-h1)}.chat-app :where(.h2){font-size:var(--base-font-size-h2)}.chat-app :where(.h3){font-size:var(--base-font-size-h3)}.chat-app :where(.h4,.h5,.h6){font-size:var(--body-font-size)}.chat-app :where(.text-container)>:where(p,ul,ol,img,table){margin-bottom:var(--spacer-r-24);display:block}.chat-app :where(.text-container)>:where(div){margin:var(--spacer-r-40) 0}.chat-app :where(.text-container)>:where(h1,.h1){margin-bottom:var(--spacer-r-28)}.chat-app :where(.text-container)>:where(h2,.h2,h3,.h3,h4,.h4,h5,.h5,h6,.h6){margin-bottom:var(--spacer-r-20)}.chat-app :where(.text-container)>:where(h1,.h1,h2,.h2,h3,.h3,h4,.h4,h5,.h5,h6,.h6){margin-top:var(--spacer-r-40)}.chat-app :where(.text-container)>:where(ul:not(.no-list-styling),ol:not(.no-list-styling))>:where(li){margin-bottom:var(--spacer-12)}.chat-app :where(.text-container)>:where(ul:not(.no-list-styling),ol:not(.no-list-styling))>:where(li):last-child{margin-bottom:0}.chat-app :where(.text-container)>:where(ol){padding-left:1.5em;list-style-type:decimal;list-style-position:outside}.chat-app :where(.text-container)>:where(ul:not(.no-list-styling))>:where(li){padding-left:1em;position:relative}.chat-app :where(.text-container)>:where(ul:not(.no-list-styling))>:where(li):before{content:"•";font-size:.9em;position:absolute;top:0;left:0}.chat-app :where(.text-container)>:where(hr){height:1px;margin:var(--spacer-r-40) 0;background-color:var(--color-grey-700);background-color:var(--hr-color);border:none}.chat-app :where(.text-container) :where(a:not(.button,.no-link-styling,.reference)){color:var(--anchor-color);font-weight:var(--anchor-font-weight,var(--base-font-weight-normal));-webkit-text-decoration:var(--anchor-text-decoration,underline);text-decoration:var(--anchor-text-decoration,underline);text-underline-offset:var(--anchor-text-underline-offset,.15em);transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color;transition-timing-function:var(--default-transition-timing-function)}.chat-app :where(.text-container) :where(a:not(.button,.no-link-styling,.reference)):hover{color:var(--anchor-hover-color)}.chat-app :where(.text-container) :where(table){border-collapse:collapse;border-spacing:0;-webkit-overflow-scrolling:touch;width:100%;display:block;overflow-x:auto}.chat-app :where(.text-container) :where(th){width:1000px;padding:var(--spacer-12) var(--spacer-16) var(--spacer-12) 0;border-bottom:1px solid var(--color-grey-300);line-height:var(--base-line-height-tight);text-align:left;vertical-align:bottom}.chat-app :where(.text-container) :where(td){padding:var(--spacer-12) var(--spacer-16) var(--spacer-12) 0;border-bottom:1px solid var(--color-grey-300);vertical-align:top}.chat-app :where(.text-container) :where(tr:last-child td){border-bottom:none}.chat-app :where(.text-container) :where(:first-child){margin-top:0}.chat-app :where(.text-container) :where(:last-child){margin-bottom:0}.chat-app :where(.animated-height){transition:height .5s var(--ease-in-out-quart)}.chat-app :where(.display-contents){display:contents}.chat-app :where(.absolute){position:absolute!important}}@layer components{.btn{min-height:calc(var(--btn-padding-y) * 2 + var(--btn-icon-size));padding:var(--btn-padding-y) var(--btn-padding-x);align-items:center;gap:var(--spacer-r-8);font-size:var(--base-font-size-sm);line-height:var(--base-line-height-tight);text-align:left;transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color,text-decoration-color,box-shadow,transform,translate,opacity;transition-timing-function:var(--default-transition-timing-function);border-style:solid;flex-wrap:nowrap;text-decoration:none;display:flex;position:relative}.btn>:where(.svg){width:var(--btn-icon-size)}.btn:disabled{cursor:not-allowed;opacity:.5;pointer-events:none}.btn--primary{border-width:var(--btn-primary-border-width);border-radius:var(--btn-primary-border-radius);border-color:var(--btn-primary-border-color);background:var(--btn-primary-background);box-shadow:var(--btn-primary-box-shadow);color:var(--btn-primary-color);font-weight:var(--btn-primary-font-weight,700)}.btn--primary:hover{border-width:var(--btn-primary-hover-border-width,var(--btn-primary-border-width));border-color:var(--btn-primary-hover-border-color,var(--btn-primary-border-color));background:var(--btn-primary-hover-background,var(--btn-primary-background));box-shadow:var(--btn-primary-hover-box-shadow,var(--btn-primary-box-shadow));color:var(--btn-primary-hover-color,var(--btn-primary-color))}.btn--secondary{border-width:var(--btn-secondary-border-width);border-radius:var(--btn-secondary-border-radius,var(--btn-primary-border-radius));border-color:var(--btn-secondary-border-color);background:var(--btn-secondary-background);box-shadow:var(--btn-secondary-box-shadow);color:var(--btn-secondary-color);font-weight:var(--btn-secondary-font-weight,700)}.btn--secondary:hover{border-width:var(--btn-secondary-hover-border-width,var(--btn-secondary-border-width));border-color:var(--btn-secondary-hover-border-color,var(--btn-secondary-border-color));background:var(--btn-secondary-hover-background,var(--btn-secondary-background));box-shadow:var(--btn-secondary-hover-box-shadow,var(--btn-secondary-box-shadow));color:var(--btn-secondary-hover-color,var(--btn-secondary-color))}.btn--tertiary{border-width:var(--btn-tertiary-border-width);border-radius:var(--btn-tertiary-border-radius,var(--btn-primary-border-radius));border-color:var(--btn-tertiary-border-color);background:var(--btn-tertiary-background);box-shadow:var(--btn-tertiary-box-shadow);color:var(--btn-tertiary-color);font-weight:var(--btn-tertiary-font-weight,700)}.btn--tertiary:hover{border-width:var(--btn-tertiary-hover-border-width,var(--btn-tertiary-border-width));border-color:var(--btn-tertiary-hover-border-color,var(--btn-tertiary-border-color));background:var(--btn-tertiary-hover-background,var(--btn-tertiary-background));box-shadow:var(--btn-tertiary-hover-box-shadow,var(--btn-tertiary-box-shadow));color:var(--btn-tertiary-hover-color,var(--btn-tertiary-color))}.btn--square{--btn-padding-x:var(--btn-padding-y)}.btn--square:after{z-index:var(--z-index-local-overlay);content:"";background:0 0;position:absolute;inset:-.5em}.btn--square>:where(.svg){width:var(--btn-icon-size)}.btn--square>:where(.btn__label){padding-right:calc(var(--btn-padding-x) * 1.25);display:none}@container chat-container (width>=640px){.btn--square>:where(.btn__label){display:block}}.form__caption{margin-bottom:var(--spacer-32)}.form__fields{gap:var(--spacer-16);flex-direction:column;width:100%;display:flex}.form__item{gap:var(--spacer-5);flex-direction:column;width:100%;display:flex}.form__label{color:var(--label-color,inherit);font-weight:var(--label-font-weight,inherit);font-size:var(--base-font-size-sm)}.form__options{margin-top:var(--spacer-r-8);flex-direction:column;display:flex}.form__option{align-items:baseline;gap:var(--spacer-r-12);cursor:pointer;display:inline-flex}.form__option .form__option-input{clip:rect(0 0 0 0);white-space:nowrap;clip-path:inset(50%);border:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.form__option:has(.form__option-input:focus-visible) :where(.radio,.checkbox){outline-color:var(--body-focus-color);outline-style:var(--body-focus-style);outline-width:var(--body-focus-width);outline-offset:var(--body-focus-offset)}.form__select{width:100%;position:relative}.form__select select{appearance:none;padding-right:var(--spacer-56)}.form__select-arrow{top:50%;right:var(--spacer-r-20);width:var(--spacer-r-24);height:var(--spacer-r-24);color:var(--anchor-color);pointer-events:none;position:absolute;transform:translateY(-50%)}.form__footer{margin-top:var(--spacer-40)}.chat-app{display:contents}.chat-app__container{height:100%;display:flex;overflow:hidden;transform:translateZ(0);container:chat-container/inline-size}.chat-app__container>:where(*){color:var(--body-color);font-style:normal;font-weight:var(--base-font-weight-normal);font-size:var(--base-font-size-body);line-height:var(--base-line-height-default);font-family:var(--font-family);font-optical-sizing:auto}.chat-app__container.chat-app__container--inline-layout-contained{height:90svh;scroll-margin-top:10svh}@media (width>=768px){.chat-app__container.chat-app__container--inline-layout-contained{height:100svh;scroll-margin-top:0}}.chat-app__main{overscroll-behavior-x:none;overscroll-behavior-y:contain;background:var(--body-background);scrollbar-gutter:stable;touch-action:pan-y;flex-direction:column;width:100%;height:100%;display:flex;overflow:hidden auto;container:chat-inner-container/inline-size}.chat-app__container--inline-layout .chat-app__main{overscroll-behavior-y:auto}.chat-app__loader-container{z-index:var(--z-index-loader);justify-content:center;align-items:center;width:100%;height:100%;display:flex;position:relative}.chat-app__portals{display:contents}.chat-app__header{z-index:var(--z-index-header);background:var(--body-background);position:sticky;top:0}.chat-app__header--unsticked{position:relative}.chat-app__header-content{--btn-padding-x:var(--btn-padding-y);column-gap:var(--spacer-r-12);min-height:calc(var(--btn-padding-y) * 2 + var(--btn-icon-size) + var(--spacer-10) * 2);margin-right:calc(var(--btn-padding-x) * -1);margin-left:calc(var(--btn-padding-x) * -1);padding-top:var(--spacer-10);padding-bottom:var(--spacer-10);flex-wrap:wrap;justify-content:flex-end;align-items:center;display:flex;position:relative}.chat-app__header-content>:where(*){z-index:0;pointer-events:auto;position:relative}.chat-app__header-content:after{right:var(--btn-padding-x);bottom:0;left:var(--btn-padding-x);content:"";border-bottom:1px solid #0000;transition:border-color .1s ease-in-out;position:absolute}.chat-app__header-content.has-border:after{border-color:var(--base-line-color)}.chat-app__header-new-conversation{margin-right:auto;position:relative}@container chat-container (width>=640px){.chat-app__header-new-conversation .tooltip{display:none}}.chat-app__header--with-logo :where(.chat-app__header-content){margin-left:0}.chat-app__header--with-logo :where(.chat-app__header-new-conversation){margin-right:unset;margin-left:auto}.chat-app__header-logo{margin-right:auto}.chat-app__header-logo :where(svg){width:auto;height:var(--spacer-28)}.chat-app__body{flex-direction:column;flex-grow:1;width:100%;display:flex;position:relative}.chat-app__page-transition{flex-direction:column;flex-grow:1;width:100%;height:100%;display:flex}.chat-app__aside{--duration-in:.65s;--duration-out:.5s;visibility:hidden;width:0;transition-delay:0s, var(--duration-out);transition-duration:var(--duration-out), 0s;transition-property:width,visibility;transition-timing-function:var(--ease-in-out-quart), linear;flex-grow:1;position:relative;top:0;bottom:0}.chat-app__aside.open{visibility:visible;width:var(--aside-width);transition-delay:0s;transition-duration:var(--duration-in), 0s;transition-timing-function:var(--ease-out-quart), linear}.chat-app__aside .tooltip{--background-color:var(--btn-secondary-hover-background)}.chat-app__aside-container{width:var(--aside-width);overscroll-behavior:contain;border-left-width:var(--aside-border-width);border-color:var(--aside-border-color);background:var(--aside-background);scrollbar-gutter:stable;height:100%;position:relative;overflow-y:auto}.chat-app__container--inline-layout .chat-app__aside-container{overscroll-behavior-y:auto}.chat-app__aside-header,.chat-app__sheet-header{z-index:var(--z-index-header);flex-wrap:no-wrap;padding:var(--spacer-12) var(--spacer-12) var(--spacer-12) var(--spacer-24);justify-content:space-between;align-items:center;gap:var(--spacer-24);border-bottom-width:var(--aside-header-border-width);border-color:var(--aside-header-border-color);background:var(--aside-background);color:var(--aside-header-color);display:flex;position:sticky;top:0}.chat-app__sheet-close{position:relative}.chat-app__sheet-overlay{z-index:var(--z-index-dialog);background:var(--aside-background-overlay);position:fixed;inset:0}.chat-app__sheet-content{z-index:var(--z-index-flyout);width:100%;max-width:var(--aside-width);overscroll-behavior:contain;border-left-width:var(--aside-border-width);border-color:var(--aside-border-color);background:var(--aside-background);scrollbar-gutter:stable;height:100%;position:fixed;top:0;right:0;overflow-y:auto}.chat-app__container--inline-layout .chat-app__sheet-content{overscroll-behavior-y:auto}:is(.chat-app__aside-close,.chat-app__sheet-close) :where(.btn){background-color:#0000}.chat-app__aside-title,.chat-app__sheet-title{font-size:var(--base-font-size-sm)}.chat-app__close-button{z-index:var(--z-index-flyout)}.chat-input{--chat-input-padding:calc(.5em + var(--chat-input-border-width));--chat-input-settings-transition-duration:.2s;--chat-input-disabling-transition-duration:.2s}@container chat-container (width>=640px){.chat-input{--chat-input-padding:calc(.75em + var(--chat-input-border-width))}}.chat-input{z-index:var(--z-index-local-overlay);position:relative}.chat-input__textarea{box-sizing:border-box;width:100%;max-height:6lh;padding:1em var(--spacer-64) 1em calc(var(--spacer-r-24) - var(--chat-input-border-width));color:var(--chat-input-color);resize:none;transition:padding var(--chat-input-settings-transition-duration) var(--default-transition-timing-function);background:0 0;border:0 solid #0000;grid-area:textarea;display:block}.chat-input__textarea:has(+.chat-input__buttons .chat-input__mic-button){padding-right:calc(2.5em + var(--spacer-64))}.chat-input__grid--has-settings .chat-input__textarea{padding-left:var(--spacer-8)}.chat-input__grid--settings-is-open .chat-input__textarea{padding-right:var(--spacer-r-16);padding-left:var(--spacer-r-16)}@container chat-container (width>=640px){.chat-input__textarea{padding:1.25em var(--spacer-80) 1.25em calc(var(--spacer-r-28) - var(--chat-input-border-width))}.chat-input__grid--has-settings .chat-input__textarea{padding-left:var(--spacer-8)}.chat-input__grid--settings-is-open .chat-input__textarea{padding-right:var(--spacer-r-28);padding-left:var(--spacer-r-28)}}.chat-input__textarea:focus,.chat-input__textarea:focus-visible{outline-color:#0000}.chat-input__grid{--disabled-translateY:var(--spacer-20);border-width:var(--chat-input-border-width);border-radius:var(--chat-input-border-radius);border-style:solid;border-color:var(--chat-input-border-color);background:var(--chat-input-background);box-shadow:var(--chat-input-box-shadow);transition:grid-template-rows var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), grid-template-columns var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), background var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), box-shadow var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), border-color var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), outline-color var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), border-radius var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), color var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), opacity var(--chat-input-disabling-transition-duration) var(--default-transition-timing-function), transform var(--chat-input-disabling-transition-duration) var(--default-transition-timing-function);display:flex}.chat-input__grid:has(.chat-input__textarea:focus-visible){border-width:var(--chat-input-focus-border-width,var(--chat-input-border-width));border-radius:var(--chat-input-focus-border-radius,var(--chat-input-border-radius));border-color:var(--chat-input-focus-border-color,var(--chat-input-border-color));background:var(--chat-input-focus-background,var(--chat-input-background));box-shadow:var(--chat-input-focus-box-shadow,var(--chat-input-box-shadow));color:var(--chat-input-focus-color,var(--chat-input-color));outline-color:#0000}.chat-input__grid:hover{background:var(--chat-input-hover-background,var(--chat-input-background));box-shadow:var(--chat-input-hover-box-shadow,var(--chat-input-box-shadow))}.chat-input--disabled .chat-input__grid{transform:translateY(var(--disabled-translateY));opacity:0}.chat-input__grid--has-settings{--chat-input-settings-height:0px;grid-template-rows:1fr var(--chat-input-settings-height);grid-template-columns:var(--btn-submit-size) 1fr;grid-template-areas:"toggle textarea"".settings";width:100%;display:grid}@container chat-container (width>=640px){.chat-input__grid--has-settings{grid-template-columns:calc(var(--btn-submit-size) + var(--spacer-r-12)) 1fr}}.chat-input__grid--settings-is-open{grid-template-columns:0 1fr}.chat-input__submit-button,.chat-input__abort-button{--margin:.5em}.chat-input__open-settings-button{margin-left:var(--spacer-r-12)}.chat-input__buttons{right:var(--chat-input-padding);bottom:var(--chat-input-padding);pointer-events:none;align-items:center;gap:.5em;display:flex;position:absolute}.chat-input__buttons>*{pointer-events:auto}.chat-input__submit-button{width:var(--btn-submit-size);height:var(--btn-submit-size);border-width:var(--chat-input-submit-border-width,0px);border-radius:var(--chat-input-submit-border-radius);border-color:var(--chat-input-submit-border-color);background:var(--chat-input-submit-background);box-shadow:var(--chat-input-submit-box-shadow);color:var(--chat-input-submit-color);cursor:pointer;justify-content:center;align-items:center;transition-property:opacity,background-color,transform;transition-duration:.2s,.2s,.35s;transition-timing-function:ease;display:flex}.chat-input__submit-button:hover{border-width:var(--chat-input-submit-hover-border-width,var(--chat-input-submit-border-width));border-radius:var(--chat-input-submit-hover-border-radius,var(--chat-input-submit-border-radius));border-color:var(--chat-input-submit-hover-border-color,var(--chat-input-submit-border-color));background:var(--chat-input-submit-hover-background,var(--chat-input-submit-background));box-shadow:var(--chat-input-submit-hover-box-shadow,var(--chat-input-submit-box-shadow));color:var(--chat-input-submit-hover-color,var(--chat-input-submit-color))}.chat-input__submit-button path{stroke:currentColor;stroke-width:var(--chat-input-submit-stroke-width,1.5px)}@container chat-container (width>=640px){.chat-input__submit-button{--margin:.75em}}.chat-input__submit-button--deactivated{transform:scale(var(--chat-input-submit-deactivated-scale,.8));border-color:var(--chat-input-submit-deactivated-border-color,var(--chat-input-submit-border-color));background:var(--chat-input-submit-deactivated-background,var(--chat-input-submit-background));color:var(--chat-input-submit-deactivated-color,var(--chat-input-submit-color));cursor:not-allowed;opacity:var(--chat-input-submit-deactivated-opacity,.5)}.chat-input__submit-button--deactivated:hover{border-color:var(--chat-input-submit-deactivated-border-color,var(--chat-input-submit-border-color));background:var(--chat-input-submit-deactivated-background,var(--chat-input-submit-background));color:var(--chat-input-submit-deactivated-color,var(--chat-input-submit-color))}.chat-input__submit-icon,.chat-input__abort-icon{width:var(--spacer-20);height:var(--spacer-20);pointer-events:none}.chat-input__notification-wrapper{border-radius:var(--chat-input-notification-border-radius);position:relative;overflow:hidden}.chat-input__notification-animation-element{padding-bottom:var(--spacer-2)}.chat-input__notification{padding:var(--spacer-8);gap:var(--spacer-8);border-width:var(--chat-input-notification-border-width);border-radius:var(--chat-input-notification-border-radius);border-color:var(--chat-input-notification-border-color);background:var(--chat-input-notification-background);box-shadow:var(--chat-input-notification-box-shadow);color:var(--chat-input-notification-color);display:flex}.chat-input__notification-label{font-weight:700;font-size:var(--base-font-size-xs);padding-top:.175em;line-height:1.35}@container chat-inner-container (width>=640px){.chat-input__notification-label{font-size:var(--base-font-size-sm);padding-top:.125em}}.chat-input__notification-icon{width:var(--spacer-20);height:var(--spacer-20);flex-shrink:0}@container chat-inner-container (width>=640px){.chat-input__notification-icon{width:var(--spacer-24);height:var(--spacer-24)}}.chat-input__mic-button{border-radius:var(--chat-input-submit-border-radius);cursor:pointer;--mic-base-color:var(--color-grey-500);--mic-accent-color:var(--color-accent-500);background:0 0;border:none;justify-content:center;align-items:center;width:2.5em;height:2.5em;transition-property:background-color,color;transition-duration:.2s;transition-timing-function:ease;display:flex}.chat-input__mic-button:hover{background-color:var(--color-grey-100);--mic-base-color:var(--color-grey-700);--mic-accent-color:var(--color-accent-600)}.chat-input__mic-button--listening{background-color:var(--chat-input-notification-background);box-shadow:var(--chat-input-submit-box-shadow);--mic-base-color:#fff6;--mic-accent-color:white}.chat-input__mic-button--listening:hover{background-color:var(--color-highlight-600)}.chat-input__mic-button--error{color:var(--color-highlight-600)}.chat-input__settings{width:100%;padding:var(--chat-input-padding) var(--spacer-80) var(--chat-input-padding) var(--spacer-r-12);gap:var(--spacer-8);pointer-events:none;grid-area:settings;display:flex;position:absolute;bottom:0;left:0;overflow:hidden}@container chat-container (width>=640px){.chat-input__settings{padding-left:var(--spacer-r-20)}}.chat-input__grid--settings-is-open .chat-input__settings{pointer-events:auto;overflow:visible}.chat-input__settings-button{min-width:0;height:100%;padding-right:var(--spacer-4);padding-left:var(--spacer-4);transform:translate(calc(var(--spacer-48) * -1), 150%);border-radius:var(--chat-input-submit-border-radius);outline-offset:0;font-size:var(--base-font-size-xs);opacity:0;transition:transform var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), background var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), box-shadow var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), border-color var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), border-radius var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), color var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), opacity var(--chat-input-settings-transition-duration) calc(var(--chat-input-settings-transition-duration) / 3) var(--default-transition-timing-function);flex-shrink:1;flex-basis:auto;gap:3px}@container chat-inner-container (width>=768px){.chat-input__settings-button{padding-right:var(--spacer-12);padding-left:var(--spacer-8)}}.chat-input__settings-button:disabled{transform:translate(calc(var(--spacer-48) * 1), 150%);opacity:0}.chat-input__grid--settings-is-open .chat-input__settings-button{transform:translateX(calc(var(--spacer-4) * -1));opacity:1}.chat-input__settings-button[data-has-error=true]{border-color:var(--chat-input-notification-border-color)!important;background:var(--chat-input-notification-background)!important;color:var(--chat-input-notification-color)!important}@container chat-inner-container (width>=640px){.chat-input__settings-button .tooltip{display:none}}.chat-input__toggle-area{grid-area:toggle;justify-content:center;place-self:center;align-items:center;width:100%;height:100%;display:flex}.chat-input__grid--settings-is-open .chat-input__toggle-area{overflow:hidden}.chat-input__settings-toggle-button{width:var(--btn-submit-size);height:var(--btn-submit-size);margin-left:var(--spacer-r-8);border-radius:var(--chat-input-submit-border-radius);outline-offset:0;opacity:1;transition:transform var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), opacity var(--chat-input-settings-transition-duration) calc(var(--chat-input-settings-transition-duration) / 3) var(--default-transition-timing-function)}.chat-input__grid--settings-is-open .chat-input__settings-toggle-button{opacity:0;transform:translate(-100%)}.chat-input__settings-toggle-button .svg{flex-shrink:0}.chat-input__settings-button-icon:not(.svg--settingsClose){flex-shrink:0;display:block}@container chat-inner-container (width>=640px){.chat-input__settings-button-icon:not(.svg--settingsClose){display:none}}@container chat-inner-container (width>=768px){.chat-input__settings-button-icon:not(.svg--settingsClose){display:block}}.chat-input__settings-button-label{display:none}@container chat-inner-container (width>=640px){.chat-input__settings-button-label{text-overflow:ellipsis;white-space:nowrap;max-width:20ch;display:block;overflow:hidden}}@container chat-inner-container (width>=1024px){.chat-input__settings-button-label{max-width:40ch}}.chat-input__settings-button-label-name{display:none}@container chat-inner-container (width>=1024px){.chat-input__settings-button-label-name{display:inline}}.chat-input__settings-button-chevron{width:var(--spacer-10);height:var(--spacer-10);transition:transform .2s var(--default-transition-timing-function);flex-shrink:0}[data-state=open]>.chat-input__settings-button-chevron{transform:rotate(180deg)}.checkbox{--size:1em;width:var(--size);height:var(--size);border-width:var(--checkbox-border-width);border-radius:var(--checkbox-border-radius);border-color:var(--checkbox-border-color);background:var(--checkbox-background);box-shadow:var(--checkbox-box-shadow);color:var(--checkbox-color);transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color,text-decoration-color,box-shadow,transform,translate,opacity;transition-timing-function:var(--default-transition-timing-function);flex-shrink:0;justify-content:center;align-items:center;display:inline-flex;position:relative;top:.1em}.checkbox[data-checked=true]{border-color:var(--checkbox-checked-border-color);background:var(--checkbox-checked-background);color:var(--checkbox-checked-color)}.checkbox__icon{width:100%;height:100%;color:var(--color-background);opacity:1;transition:opacity .2s}.checkbox[data-checked=false] .checkbox__icon{opacity:0}.classification-feedback{margin-bottom:var(--spacer-16);gap:var(--spacer-16);border-width:var(--message-user-border-width);border-radius:var(--message-user-border-radius);border-color:var(--message-user-border-color);color:var(--message-user-color);flex-direction:column;display:flex}.classification-feedback__item{gap:var(--spacer-4);border:none;flex-direction:column;margin:0;padding:0;display:flex}.classification-feedback__label{margin-bottom:var(--spacer-8)}.classification-feedback__option{padding-left:var(--spacer-16);align-items:center;gap:var(--spacer-12);display:flex}.classification-feedback__option:has(input:checked){background:var(--btn-secondary-hover-background);color:var(--btn-secondary-hover-color)}.classification-feedback__option:has(input:focus-visible){border-radius:var(--spacer-8);outline-color:var(--body-focus-color);outline-style:solid;outline-width:var(--spacer-3)}.classification-feedback__option:has(input:focus-visible) input{outline:none}.radio{--size:1em;width:var(--size);height:var(--size);border-width:var(--radio-border-width);border-color:var(--radio-border-color);background:var(--radio-background);box-shadow:var(--radio-box-shadow);color:var(--radio-color);transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color,text-decoration-color,box-shadow,transform,translate,opacity;transition-timing-function:var(--default-transition-timing-function);border-radius:50%;flex-shrink:0;justify-content:center;align-items:center;display:inline-flex;position:relative;top:.1em}.radio[data-checked=true]{border-color:var(--radio-checked-border-color);background:var(--radio-checked-background);color:var(--radio-checked-color)}.radio__indicator{--size:50%;--scale:0;width:var(--size);height:var(--size);transform:scale(var(--scale)) translate(-50%, -50%);opacity:0;background:currentColor;border-radius:50%;transition:opacity .2s,transform .2s;position:absolute;top:50%;left:50%}.radio[data-checked=true] .radio__indicator{--scale:1;opacity:1}.context-box{z-index:var(--z-index-flyout);position:relative}.context-box__content{--context-box-side-padding:var(--spacer-r-12);z-index:var(--z-index-local-overlay);width:calc(100cqw - var(--spacer-24));border-width:var(--context-box-border-width);border-radius:var(--context-box-border-radius);border-style:solid;border-color:var(--context-box-border-color);background:var(--context-box-background);max-width:300px;box-shadow:var(--context-box-box-shadow);color:var(--context-box-color);font-size:var(--base-font-size-sm)}.context-box__content:focus-visible{outline:none}.context-box__menu{padding:var(--context-box-side-padding);gap:var(--spacer-1);flex-direction:column;display:flex}.context-box__menu--scrollable{max-height:38vh;padding-right:var(--spacer-r-20);grid-template-columns:repeat(1,minmax(280px,10cqw));display:grid;overflow-y:auto}@container chat-inner-container (width>=480px){.context-box__menu--two-cols{column-gap:var(--spacer-r-20);grid-template-columns:repeat(2,minmax(180px,42cqw));display:grid}}@container chat-inner-container (width>=768px){.context-box__menu--three-cols{grid-template-columns:repeat(3,minmax(160px,25cqw))}}.context-box__menu-item{width:100%;padding:var(--spacer-4) var(--spacer-8);align-items:center;gap:var(--spacer-8);border-radius:var(--context-box-menu-item-border-radius);background:var(--context-box-menu-item-background);color:var(--context-box-menu-item-color);cursor:pointer;display:flex;position:relative}.context-box__menu-item:hover{background:var(--context-box-menu-item-hover-background);color:var(--context-box-menu-item-hover-color)}.context-box__menu-item:focus{z-index:var(--z-index-local-overlay)}.context-box__menu-item.active{background:var(--context-box-menu-item-active-background);color:var(--context-box-menu-item-active-color)}.context-box__menu-item--option{align-items:baseline}.context-box__menu-item__icon{width:var(--spacer-20);height:var(--spacer-20);color:currentColor}.context-box__title{padding:calc(var(--context-box-side-padding) * 1.5) var(--context-box-side-padding) 0 var(--context-box-side-padding);color:var(--context-box-title-color);font-weight:var(--context-box-title-font-weight);font-size:var(--base-font-size-xs)}.context-box__header{min-width:200px;padding:var(--context-box-side-padding);padding-left:calc(var(--context-box-side-padding) + var(--spacer-8));justify-content:space-between;align-items:center;gap:var(--spacer-r-12);border-bottom:1px solid var(--context-box-separator-color);font-weight:var(--context-box-title-font-weight);font-size:var(--base-font-size-xs);text-wrap:balance;display:flex}.context-box__close-button{--btn-padding-y:var(--spacer-4);--btn-padding-x:var(--spacer-4);flex-shrink:0}.context-box__footer{--btn-padding-x-smaller:calc(var(--btn-padding-x) * .75);padding:calc(var(--context-box-side-padding) * .5) calc(var(--context-box-side-padding) + var(--spacer-8) - var(--btn-padding-x-smaller));border-top:1px solid var(--context-box-separator-color);flex-wrap:wrap;display:flex}.context-box__footer-item{padding-right:var(--btn-padding-x-smaller);padding-left:var(--btn-padding-x-smaller);font-size:var(--base-font-size-xs);cursor:pointer}.context-box__separator{border-top:1px solid var(--context-box-separator-color)}.context-box__language-translation{opacity:.5}.context-box__color-scheme-selector{flex-direction:row;align-items:stretch;display:flex}.context-box__color-scheme-selector-button{width:100%;margin:var(--context-box-side-padding);padding:var(--spacer-4) var(--spacer-8);justify-content:center;align-items:center;gap:var(--spacer-8);border-radius:var(--context-box-menu-item-border-radius);background:var(--context-box-menu-item-background);color:var(--context-box-menu-item-color);cursor:pointer;display:flex}.context-box__color-scheme-selector-button:hover{background:var(--context-box-menu-item-hover-background);color:var(--context-box-menu-item-hover-color)}.context-box__color-scheme-selector-separator{border-top:0;border-left:1px solid var(--context-box-separator-color);width:1px;height:auto;display:block}.context-box__color-scheme-selector-button--active{background:var(--context-box-menu-item-active-background);color:var(--context-box-menu-item-active-color)}.context-box__notification[data-type=error]{color:var(--context-box-error-color)}.context-box__popover-close{z-index:var(--z-index-local-overlay);top:var(--spacer-4);right:var(--spacer-4);clip:rect(0 0 0 0);width:1px;height:1px;padding:var(--spacer-4);border-radius:var(--context-box-menu-item-border-radius);background:var(--context-box-background);color:var(--context-box-color);clip-path:inset(50%);cursor:pointer;border:none;position:absolute;overflow:hidden}.context-box__popover-close:focus-visible{clip:auto;clip-path:none;width:auto;height:auto;overflow:visible}.context-box__content--info{width:calc(100cqw - var(--spacer-32));max-width:600px;max-height:60cqh;padding:var(--spacer-r-32);position:relative;overflow:hidden scroll}.context-box__content--info :where(.text-container){flex-direction:column;align-items:flex-start;display:flex}[data-bits-floating-content-wrapper]{padding-right:1em}.context-box--dropdown{max-width:min(var(--container-max-width,1024px), 90cqw)}.context-box--dropdown :where(.context-box__content){width:auto;max-width:100%}.consent-page{padding-top:var(--spacer-r-40);padding-bottom:var(--spacer-r-40);justify-content:center;align-items:stretch;gap:var(--spacer-r-48);flex-direction:column;flex-grow:1;display:flex}.consent-page__introduction{text-align:center}.consent-page__disclaimer{font-size:var(--base-font-size-sm);text-align:center;text-wrap:balance}.consent-page__actions{justify-content:center;gap:var(--spacer-r-16);flex-wrap:wrap;display:flex}.chat-page{padding-top:var(--spacer-r-80);flex-direction:column;flex-grow:1;display:flex;position:relative}.chat-page__survey-portal:not(:empty){z-index:calc(var(--z-index-header) - 1);position:sticky;top:4rem}.chat-page__body{flex-direction:column;flex-grow:1;display:flex}.chat-page__messages{gap:var(--spacer-r-40);flex-direction:column;flex-grow:1;display:flex}.chat-page__footer{z-index:var(--z-index-footer);flex-direction:column;justify-content:flex-end;display:flex;position:sticky;bottom:0}.chat-page__footer--unsticked{position:relative}.chat-page__footer-content{padding-bottom:var(--spacer-r-8);gap:var(--spacer-r-8);border-width:var(--chat-footer-border-width);border-top-right-radius:var(--chat-footer-border-radius);border-top-left-radius:var(--chat-footer-border-radius);border-style:solid;border-color:var(--chat-footer-border-color);background:var(--chat-footer-background);box-shadow:var(--chat-footer-box-shadow);color:var(--chat-footer-color);flex-direction:column;display:flex;position:relative}.chat-page__footer-text{font-size:var(--base-font-size-xs);text-align:center;text-wrap:balance}.chat-page__footer-text :where(a){text-underline-offset:.15em;text-decoration:underline}.chat-page__buttons{padding-top:var(--spacer-80);padding-bottom:var(--spacer-40);align-self:center}.chat-page__give-feedback--disabled{opacity:0}.chat-page__scroll-to-bottom{opacity:1;position:absolute;top:0;left:50%;transform:translate(-50%,-150%)}.chat-page__scroll-to-bottom--hidden{transform:translate(-50%);opacity:0!important}.dialog-overlay{z-index:var(--z-index-dialog);background:var(--dialog-background-overlay);position:fixed;inset:0}.dialog-content{z-index:var(--z-index-dialog);width:calc(100% - var(--spacer-32));border-width:var(--dialog-border-width);border-radius:var(--dialog-border-radius);border-color:var(--dialog-border-color);background:var(--dialog-background);max-width:600px;max-height:90vh;box-shadow:var(--dialog-box-shadow,none);flex-direction:column;display:flex;position:fixed;top:50%;left:50%;overflow:clip;transform:translate(-50%,-50%)}.dialog-header{padding:var(--spacer-r-24);border-bottom-width:1px;border-bottom-color:var(--dialog-header-border-bottom-color,var(--dialog-border-color));font-weight:var(--dialog-header-font-weight,inherit);font-size:var(--dialog-header-font-size,inherit);justify-content:space-between;align-items:center;display:flex}.dialog-title{padding:0}.dialog-close{color:var(--anchor-color);justify-self:flex-end;margin-left:auto}.dialog-close:hover{color:var(--anchor-hover-color,var(--dialog-color))}.dialog-description{min-height:0;padding:var(--spacer-r-24);flex:1;overflow-y:auto}.dialog-footer{padding:var(--spacer-r-24);border-top-width:1px;border-top-color:var(--dialog-header-border-bottom-color,var(--dialog-border-color));background:var(--dialog-background);flex-shrink:0}.dialog-footer__actions{justify-content:flex-end;gap:var(--spacer-r-12);display:flex}:where(.flyout){z-index:var(--z-index-flyout);pointer-events:none;width:570px;max-width:100cqw;height:960px;max-height:100cqh;padding:10px;display:block;position:fixed;bottom:0;right:0}.flyout__backdrop{background-color:color-mix(in srgb, var(--flyout-backdrop-color,transparent) calc(var(--flyout-backdrop-opacity) * 100%), transparent);position:fixed;inset:0}.flyout__body{pointer-events:none;place-content:end flex-end;place-items:end;width:100%;height:100%;display:block;position:relative}.flyout__body:has(.flyout__content){pointer-events:auto}.flyout__content{width:100%;height:100%;display:block}.flyout__open-button{z-index:var(--z-index-local-overlay);pointer-events:auto;position:absolute;bottom:0;right:0}.flyout__content{filter:drop-shadow(0 0 8px #0003);border-radius:4px;overflow:clip}.flyout--defaults{right:var(--spacer-r-16);bottom:var(--spacer-r-16);width:200px;height:200px;display:block;position:fixed}.introduction{justify-content:center;align-items:center;gap:var(--spacer-r-16);flex-direction:column;display:flex}.introduction__avatar{width:var(--spacer-r-80);height:var(--spacer-r-80)}.introduction__title{font-size:var(--base-font-size-h3);text-align:center;text-wrap:balance}.introduction-disclaimer{margin-top:var(--spacer-r-32);font-size:var(--base-font-size-sm)}.message{min-height:0;transition:min-height 0 1.1s;display:flex}.message:last-child{min-height:var(--last-bot-message-min-height)}.message--bot{justify-content:flex-start;width:100%}.message--user:first-child+.message--bot{min-height:0}.message--bot :where(.message__content){width:100%}.message--user{justify-content:flex-end}.message--user :where(.message__content){padding:var(--spacer-8) var(--spacer-16);border-width:var(--message-user-border-width);border-radius:var(--message-user-border-radius);border-color:var(--message-user-border-color);background:var(--message-user-background);box-shadow:var(--message-user-box-shadow);color:var(--message-user-color)}.message--no-padding{padding:0 var(--spacer-16)}.open-button{--open-button-avatar-height:var(--spacer-r-80);--open-button-avatar-width:var(--spacer-r-80);--open-button-duration:.4s;--open-button-delay:.3s;--open-button-ease:ease-in-out;cursor:pointer;flex-direction:row;align-items:flex-end;transition:opacity .15s ease-out;display:flex}.open-button--expanded{opacity:0;pointer-events:none}.open-button__text{margin-right:calc(var(--open-button-avatar-width) * -.5);padding-top:var(--spacer-r-12);padding-right:0;padding-bottom:var(--spacer-r-12);border-width:var(--open-button-border-width);border-radius:var(--open-button-border-radius);border-color:var(--open-button-border-color);background:var(--open-button-background);color:var(--open-button-color);text-align:left;transition:transform var(--open-button-duration) var(--open-button-ease), padding-right var(--open-button-duration) var(--open-button-delay) var(--open-button-ease);flex-direction:column;justify-content:center;align-items:flex-start;padding-left:0;display:flex;position:absolute;bottom:50%;right:100%;overflow:hidden;transform:translateY(50%);box-shadow:0 4px 6px -1px #0000001a,0 2px 4px -2px #0000001a}.open-button:is(:hover,.open-button--programmatic-expand) .open-button__text{background:var(--open-button-hover-background,var(--open-button-background));color:var(--open-button-hover-color,var(--open-button-color));opacity:1;transition:transform var(--open-button-duration) var(--open-button-delay) var(--open-button-ease);transform:translateY(0)}.open-button__title{max-width:240px;padding:0 calc(var(--open-button-avatar-width) * .5 + var(--spacer-r-12)) 0 var(--spacer-r-12);white-space:pre;font-weight:700}.open-button__mask{width:0;height:0;transition:width var(--open-button-duration) var(--open-button-delay) var(--open-button-ease), height var(--open-button-duration) var(--open-button-ease);overflow:hidden}.open-button:is(:hover,.open-button--programmatic-expand) .open-button__mask{transition:width var(--open-button-duration) var(--open-button-ease), height var(--open-button-duration) var(--open-button-delay) var(--open-button-ease)}.open-button__description{width:50cqw;max-width:260px;padding:0 calc(var(--open-button-avatar-width) * .5 + var(--spacer-r-12)) 0 var(--spacer-r-12);text-wrap:balance;position:relative}.open-button__avatar{z-index:var(--z-index-local-overlay);width:var(--open-button-avatar-width);height:var(--open-button-avatar-height);border-radius:var(--spacer-r-80);filter:drop-shadow(0 4px 6px #00000026);transition:transform .2s var(--open-button-ease);position:relative;overflow:clip}.open-button:is(:hover,.open-button--programmatic-expand) .open-button__avatar{transform:scale(1.05)}.open-button__link-icon{width:var(--spacer-r-80);height:var(--spacer-r-80);padding:var(--spacer-r-20);color:var(--open-button-color);display:none;position:absolute;right:0}:where(.open-button--standalone){right:var(--spacer-r-16);bottom:var(--spacer-r-16);position:fixed}@media (prefers-reduced-motion:reduce){.open-button__text,.open-button__mask,.open-button:hover .open-button__text,.open-button:hover .open-button__mask{transition:none!important}.open-button__avatar,.open-button:hover .open-button__avatar{filter:none!important;transition:none!important}}.open-button--hide-title-when-collapsed .open-button__text{visibility:hidden;opacity:0;transition:transform var(--open-button-duration) var(--open-button-ease), padding-right var(--open-button-duration) var(--open-button-delay) var(--open-button-ease), opacity var(--open-button-duration) var(--open-button-delay) var(--open-button-ease), visibility 0s linear calc(var(--open-button-duration) + var(--open-button-delay))}.open-button--hide-title-when-collapsed:is(:hover,.open-button--programmatic-expand) .open-button__text{visibility:visible;background:var(--open-button-hover-background,var(--open-button-background));color:var(--open-button-hover-color,var(--open-button-color));opacity:1;transition:transform var(--open-button-duration) var(--open-button-delay) var(--open-button-ease), opacity var(--open-button-duration) var(--open-button-ease), visibility 0s linear 0s;transform:translateY(0)}.predefined-question{width:100%;height:100%;padding:var(--spacer-r-20);gap:var(--spacer-r-12);border-width:var(--card-border-width);border-radius:var(--card-border-radius);border-color:var(--card-border-color);background:var(--card-background);box-shadow:var(--card-box-shadow,none);color:var(--card-color);line-height:var(--base-line-height-snug);text-align:left;cursor:pointer;flex-direction:column;display:flex;position:relative}.predefined-question:hover{border-width:var(--card-hover-border-width,var(--card-border-width));border-radius:var(--card-hover-border-radius,var(--card-border-radius));border-color:var(--card-hover-border-color,var(--card-border-color));background:var(--card-hover-background,var(--card-background));box-shadow:var(--card-hover-box-shadow,var(--card-box-shadow), none);color:var(--card-hover-color,var(--card-color))}.predefined-question:hover :where(.predefined-question__icon){color:var(--card-icon-hover-color)}.predefined-question:focus{z-index:var(--z-index-local-overlay)}@container chat-container (width>=640px){.predefined-question{padding:var(--spacer-r-24)}}.predefined-question__icon{color:var(--card-icon-color)}.predefined-questions{gap:var(--spacer-r-12);width:100%;display:grid}@container chat-container (width>=640px){.predefined-questions{grid-template-columns:repeat(3,1fr)}.predefined-questions:has(>li:only-child){grid-template-columns:1fr}.predefined-questions:has(>li:nth-child(2):last-child){grid-template-columns:repeat(2,1fr)}}.predefined-questions--pii-padding{transform:translateY(var(--spacer-56))}.reference-number{display:inline-block;position:relative}.reference-number__trigger{box-sizing:border-box;min-width:1.5em;height:1.5em;padding:var(--reference-number-trigger-padding);border-width:var(--reference-number-trigger-border-width);border-radius:var(--reference-number-trigger-border-radius);border-color:var(--reference-number-trigger-border-color);background:var(--reference-number-trigger-background);box-shadow:var(--reference-number-trigger-box-shadow);color:var(--reference-number-trigger-color);font-weight:var(--base-font-weight-bold);font-size:var(--base-font-size-xs);text-align:center;cursor:pointer;margin:0 .1em;line-height:1;text-decoration:none;display:inline-block;position:relative;top:-.1em}.reference-number__trigger:hover{background:var(--reference-number-trigger-hover-background);color:var(--reference-number-trigger-hover-color)}.reference-number__trigger:after{z-index:var(--z-index-local-overlay);content:"";background:0 0;position:absolute;inset:-.5em}.reference-number__content-wrapper{z-index:var(--z-index-reference-number);width:var(--reference-number-content-width);max-width:var(--reference-number-content-max-width);position:absolute}.reference-number__content{padding:var(--spacer-r-20);border-width:var(--reference-number-content-border-width);border-radius:var(--reference-number-content-border-radius);border-style:solid;border-color:var(--reference-number-content-border-color);background:var(--reference-number-content-background);box-shadow:var(--reference-number-content-box-shadow);display:block}.reference-number__content:hover{border-width:var(--reference-number-content-hover-border-width,var(--reference-number-content-border-width));border-color:var(--reference-number-content-hover-border-color,var(--reference-number-content-border-color));background:var(--reference-number-content-hover-background,var(--reference-number-content-background));color:var(--reference-number-content-hover-color,var(--reference-number-content-color));cursor:pointer}.reference-number__content:after{z-index:var(--z-index-local-overlay);content:"";background:0 0;position:absolute;inset:-.5em}.reference{padding:var(--spacer-12);gap:var(--spacer-12);border-width:var(--reference-border-width);border-radius:var(--reference-border-radius);border-color:var(--reference-border-color);background:var(--reference-background);box-shadow:var(--reference-box-shadow);color:var(--reference-color);cursor:pointer;display:flex}.reference:hover{border-width:var(--reference-hover-border-width,var(--reference-border-width));border-color:var(--reference-hover-border-color,var(--reference-border-color));background:var(--reference-hover-background,var(--reference-background));box-shadow:var(--reference-hover-box-shadow,var(--reference-box-shadow), none);color:var(--reference-hover-color,var(--reference-color))}.reference__number{min-width:1.5em;height:1.5em;margin-top:var(--spacer-1);padding:var(--reference-number-padding);border-width:var(--reference-number-border-width);border-radius:var(--reference-number-border-radius);border-color:var(--reference-number-border-color);background:var(--reference-number-background);box-shadow:var(--reference-number-box-shadow);color:var(--reference-number-color);font-weight:700;font-weight:var(--base-font-weight-bold);font-size:var(--base-font-size-xs);text-align:center;flex-shrink:0;line-height:1;display:block}@container chat-container (width>=640px){.reference__number{margin-top:calc(var(--spacer-1) * -1)}}a:hover .reference__number{border-width:var(--reference-number-hover-border-width,var(--reference-number-border-width));border-radius:var(--reference-number-hover-border-radius,var(--reference-number-border-radius));border-color:var(--reference-number-hover-border-color,var(--reference-number-border-color));background:var(--reference-number-hover-background,var(--reference-number-background));box-shadow:var(--reference-number-hover-box-shadow,var(--reference-number-box-shadow));color:var(--reference-number-hover-color,var(--reference-number-color))}.reference__header{justify-content:space-between;align-items:flex-start;gap:var(--spacer-12);width:100%;display:flex}.reference__title{font-size:var(--reference-font-size,var(--base-font-size-sm))}.reference__body{flex-direction:column;flex-grow:1;min-width:0;display:flex}.reference__icon{width:var(--spacer-20);color:var(--anchor-color);flex-shrink:0;position:relative}@media (hover:hover){.reference__icon{transform:translate(calc(var(--spacer-8) * -1), var(--spacer-8));opacity:0;transition:transform .2s ease-in-out,opacity .2s linear}}a:hover .reference__icon{opacity:1;transform:translate(0)}.reference__description{margin-top:var(--spacer-2);color:var(--reference-description-color);font-size:var(--base-font-size-sm)}a:hover .reference__description{color:var(--reference-description-hover-color)}.reference__footer{--footer-gap:var(--spacer-5);column-gap:var(--footer-gap);margin-top:var(--spacer-6);font-size:var(--base-font-size-xs);flex-wrap:wrap;display:flex}.reference__domain{max-width:100%;padding:var(--reference-domain-padding);border-width:var(--reference-domain-border-width);border-radius:var(--reference-domain-border-radius);border-color:var(--reference-domain-border-color);background:var(--reference-domain-background);box-shadow:var(--reference-domain-box-shadow);color:var(--reference-domain-color);font-weight:700;display:inline-flex}a:hover .reference__domain{border-width:var(--reference-domain-hover-border-width,var(--reference-domain-border-width));border-color:var(--reference-domain-hover-border-color,var(--reference-domain-border-color));background:var(--reference-domain-hover-background,var(--reference-domain-background));box-shadow:var(--reference-domain-hover-box-shadow,var(--reference-domain-box-shadow));color:var(--reference-domain-hover-color,var(--reference-domain-color))}.reference__breadcrumb{color:var(--reference-domain-color)}.reference__breadcrumb:before{padding-right:var(--footer-gap);content:"/";position:relative;top:-1px}a:hover .reference__breadcrumb{color:var(--reference-domain-hover-color,var(--reference-domain-color))}.references__container{--padding:var(--spacer-10);padding:var(--padding);flex-direction:column;display:flex}.references__transition{position:relative}.references__items{width:100%}.references__items :focus-within{z-index:var(--z-index-local-overlay);position:relative}.references__further{margin-top:var(--padding);margin-right:calc(var(--padding) * -1);margin-left:calc(var(--padding) * -1);border-top:1px solid var(--base-line-color)}.references__further :where(.references__container){scroll-margin-top:140px}.references__further :where(.reference){padding-left:var(--spacer-16)}.references__toggle{width:100%;padding:var(--spacer-20) var(--spacer-20) var(--spacer-20) var(--spacer-24);justify-content:space-between;align-items:center;gap:var(--spacer-8);border-width:var(--references-toggle-border-width);border-radius:var(--references-toggle-border-radius);border-color:var(--references-toggle-border-color);background:var(--references-toggle-background);box-shadow:var(--references-toggle-box-shadow);color:var(--references-toggle-color);font-weight:var(--references-toggle-font-weight,var(--base-font-weight-bold));font-size:var(--references-toggle-font-size,var(--base-font-size-sm));display:flex}.references__toggle:hover{border-color:var(--references-toggle-hover-border-color);background:var(--references-toggle-hover-background);box-shadow:var(--references-toggle-hover-box-shadow);color:var(--references-toggle-hover-color)}.references__toggle[data-state=open] :where(.references__toggle-icon){transform:rotate(180deg)}.references__toggle-icon{width:var(--spacer-24);transition:transform .2s}.jsonld-references{margin-top:var(--spacer-r-20);gap:var(--spacer-r-20);display:grid}@keyframes jsonld-fly-in{0%{transform:translateY(var(--jsonld-item-y,30px));opacity:0}to{opacity:1;transform:none}}.jsonld-references__item{min-width:0;animation:jsonld-fly-in var(--jsonld-item-duration,.3s) cubic-bezier(.165, .84, .44, 1) both;animation-delay:var(--jsonld-item-delay,0s);display:flex}.jsonld-references__item--preloading{visibility:hidden;pointer-events:none;width:400px;animation:none;position:absolute;left:-9999px}.jsonld-card{padding:var(--spacer-r-24);gap:var(--spacer-r-16);border-style:solid;flex-direction:column;flex:1;display:flex}.jsonld-card--map{--jsonld-card-radius:var(--message-json-ld-map-border-radius);border-width:var(--message-json-ld-map-border-width);border-radius:var(--message-json-ld-map-border-radius);border-color:var(--message-json-ld-map-border-color);background:var(--message-json-ld-map-background);box-shadow:var(--message-json-ld-map-box-shadow);color:var(--message-json-ld-map-color)}.jsonld-card--event{--jsonld-card-radius:var(--message-json-ld-event-border-radius);border-width:var(--message-json-ld-event-border-width);border-radius:var(--message-json-ld-event-border-radius);border-color:var(--message-json-ld-event-border-color);background:var(--message-json-ld-event-background);box-shadow:var(--message-json-ld-event-box-shadow);color:var(--message-json-ld-event-color)}.jsonld-card--cta{--jsonld-card-radius:var(--message-json-ld-cta-border-radius);border-width:var(--message-json-ld-cta-border-width);border-radius:var(--message-json-ld-cta-border-radius);border-color:var(--message-json-ld-cta-border-color);background:var(--message-json-ld-cta-background);box-shadow:var(--message-json-ld-cta-box-shadow);color:var(--message-json-ld-cta-color)}.jsonld-card__header{align-items:flex-start;min-width:0;display:flex}.jsonld-card__title{min-width:0;font-size:var(--base-font-size-h3);line-height:var(--base-line-height-tight);word-break:break-word;margin:0}.jsonld-card__meta{column-gap:var(--spacer-8);row-gap:var(--spacer-4);font-size:var(--base-font-size-sm);grid-template-columns:max-content 1fr;align-items:baseline;margin:0;display:grid}.jsonld-card__meta-label{padding-right:var(--spacer-12);font-weight:var(--base-font-weight-bold);font-size:var(--base-font-size-xs);line-height:var(--base-line-height-snug);letter-spacing:.04em;text-transform:uppercase}.jsonld-card__meta-value{line-height:var(--base-line-height-snug);white-space:pre-line;margin:0}.jsonld-card__event-date{gap:var(--spacer-2);flex-direction:column;display:flex}.jsonld-card__event-time{opacity:.7}.jsonld-card__description{margin-bottom:var(--spacer-6);font-size:var(--base-font-size-sm);line-height:var(--base-line-height-default);opacity:.9}.jsonld-card__address{font-size:var(--base-font-size-sm);line-height:var(--base-line-height-snug);white-space:pre-line;margin:0}.jsonld-card__cta{border-width:var(--btn-primary-border-width);border-radius:var(--btn-primary-border-radius);border-color:var(--btn-primary-border-color);background:var(--btn-primary-background);box-shadow:var(--btn-primary-box-shadow);color:var(--btn-primary-color);font-weight:var(--btn-primary-font-weight,700);align-self:flex-start;text-decoration:none}.jsonld-card__cta:hover{border-width:var(--btn-primary-hover-border-width,var(--btn-primary-border-width));border-color:var(--btn-primary-hover-border-color,var(--btn-primary-border-color));background:var(--btn-primary-hover-background,var(--btn-primary-background));box-shadow:var(--btn-primary-hover-box-shadow,var(--btn-primary-box-shadow));color:var(--btn-primary-hover-color,var(--btn-primary-color))}.jsonld-card__cta-icon{width:var(--spacer-16);height:var(--spacer-16);flex-shrink:0}.jsonld-card__actions{align-items:center;gap:var(--spacer-12);flex-wrap:wrap;display:flex}.jsonld-card__link{align-items:center;gap:var(--spacer-6);color:var(--anchor-color,currentColor);font-weight:var(--base-font-weight-bold);font-size:var(--base-font-size-sm);display:inline-flex}.jsonld-card__link:hover{text-decoration:underline}.jsonld-card__map-frame{aspect-ratio:16/9;border:1px solid color-mix(in srgb, currentColor 10%, transparent);border-radius:calc(var(--jsonld-card-radius) * .7);background:color-mix(in srgb, currentColor 6%, transparent);width:100%;position:relative;overflow:hidden}.jsonld-card__map-canvas,.jsonld-card__map-frame .maplibregl-map{width:100%;height:100%;position:absolute;inset:0}.jsonld-card__map-frame .maplibregl-ctrl-attrib,.jsonld-card__map-frame .maplibregl-ctrl-attrib-inner{display:none}.maplibregl-canvas{border-radius:0}.selected-topic{z-index:-10;position:relative}.selected-topic__animation-container--hidden{transform:translateY(-100%)}.selected-topic__container{align-items:stretch;gap:var(--selected-topic-separator-width);border:var(--selected-topic-border-width) solid var(--selected-topic-border-color);border-radius:var(--selected-topic-border-radius) var(--selected-topic-border-radius) 0 0;background-color:var(--selected-topic-border-color);width:fit-content;font-size:var(--base-font-size-xs);flex-wrap:wrap;margin-inline:auto;display:flex;overflow:hidden}.selected-topic__label,.selected-topic__btn{padding:var(--selected-topic-padding);background-color:var(--selected-topic-background);font-weight:var(--base-font-weight-bold);text-align:center;flex-grow:1}.selected-topic__label{justify-content:center;align-items:center;gap:var(--selected-topic-label-gap);color:var(--selected-topic-color);font-size:var(--base-font-size-xs);line-height:var(--base-line-height-default);display:flex}.selected-topic__label-complement{display:none}@container chat-container (width>=640px){.selected-topic__label-complement{display:block}}.selected-topic__btn{color:var(--selected-topic-btn-color);transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color,text-decoration-color,box-shadow,transform,translate,opacity;transition-timing-function:var(--default-transition-timing-function)}.selected-topic__btn:hover{color:var(--selected-topic-btn-hover-color)}.start-page{padding-top:var(--spacer-r-40);padding-bottom:var(--spacer-r-40);flex-direction:column;flex-grow:1;justify-content:center;align-items:stretch;display:flex}.start-page__introduction{margin-bottom:var(--spacer-r-48)}.start-page__chat-input{width:100%;margin-bottom:var(--spacer-r-32)}.tooltip-container{z-index:var(--z-index-tooltip);position:relative}.tooltip-container:hover{z-index:var(--z-index-tooltip-hover)}.tooltip{--background-color:var(--tooltip-background);z-index:var(--z-index-tooltip);padding:var(--spacer-3) var(--spacer-8);border-radius:var(--tooltip-border-radius);background:var(--background-color);color:var(--tooltip-color);font-weight:var(--base-font-weight-normal);font-size:var(--base-font-size-xs);white-space:nowrap;opacity:1;transition:opacity .15s cubic-bezier(.33,1,.68,1),transform .15s cubic-bezier(.33,1,.68,1);position:absolute;transform:translateY(0)}.tooltip:after{content:"";border-style:solid;border-width:5px;position:absolute}.tooltip-top:after{bottom:-10px;left:calc(50% + var(--tooltip-arrow-offset,0px));border-color:var(--background-color) transparent transparent transparent;transform:translate(-50%)}.tooltip-bottom:after{top:-10px;left:calc(50% + var(--tooltip-arrow-offset,0px));border-color:transparent transparent var(--background-color) transparent;transform:translate(-50%)}.tooltip-left:after{border-color:transparent var(--background-color) transparent transparent;top:50%;right:-10px;transform:translateY(-50%)}.tooltip-right:after{border-color:transparent transparent transparent var(--background-color);top:50%;left:-10px;transform:translateY(-50%)}.tooltip-bottom-right:after{border-color:transparent transparent var(--background-color) transparent;top:-10px;left:80%;transform:translate(-50%)}.tooltip-bottom-left:after{border-color:transparent transparent var(--background-color) transparent;top:-10px;left:20px;transform:translate(-50%)}.tooltip-hidden{opacity:0;pointer-events:none;transform:translateY(1rem)}.context-box.open .tooltip{display:none}.mic-icon{justify-content:center;align-items:center;height:1.5rem;display:flex;position:relative}.mic-icon .svg{width:inherit}.audio-level-mic-svg{width:1.5rem;height:1.5rem}.embed-combobox{--embed-combobox-side-offset:10px;align-items:start;gap:var(--spacer-r-32);flex-direction:column;display:flex}.embed-combobox__container{transition:opacity .3s linear}.embed-combobox__container--hidden{opacity:0;height:0}.embed-combobox__combobox{border:var(--input-border-width) solid var(--input-border-color);border-radius:var(--input-border-radius);background:var(--input-background);align-items:stretch;width:100%;min-width:min(14rem,100%);max-width:500px;display:inline-flex;position:relative}.embed-combobox__combobox:has(:focus-visible:not([data-disabled])){border-radius:var(--btn-primary-border-radius);outline-color:var(--body-focus-color);outline-style:solid;outline-width:var(--spacer-3);outline-offset:var(--spacer-2)}.embed-combobox__no-result{margin-top:var(--spacer-r-12);margin-bottom:var(--spacer-12);padding:var(--spacer-4) var(--spacer-8)}[data-combobox-input]{width:100%;min-width:0;padding:var(--input-padding);padding-right:var(--spacer-r-64);color:var(--input-color);background:0 0;outline:none}[data-combobox-input]::placeholder{color:var(--input-placeholder-color)}[data-combobox-trigger]{z-index:var(--z-index-local-overlay);aspect-ratio:1;border:0;justify-content:center;align-items:center;display:flex;position:absolute;top:0;bottom:0;right:0}[data-combobox-trigger] :where(.btn){border-radius:calc(var(--btn-tertiary-border-radius) * .75)}[data-combobox-trigger][data-state=open],[data-combobox-trigger]:hover,[data-combobox-trigger]:focus-visible{outline:none}:is([data-combobox-trigger][data-state=open],[data-combobox-trigger]:hover,[data-combobox-trigger]:focus-visible) :where(.btn){background:var(--btn-tertiary-hover-background);color:var(--btn-tertiary-hover-color)}[data-combobox-trigger][data-disabled],[data-combobox-input][data-disabled]{cursor:not-allowed;opacity:.5}[data-combobox-content]{z-index:var(--z-index-flyout);width:var(--bits-combobox-anchor-width);min-width:var(--bits-combobox-anchor-width);max-height:min(21rem, var(--bits-combobox-content-available-height));padding:0 var(--spacer-r-12);border-width:var(--context-box-border-width);border-radius:var(--context-box-border-radius);border-style:solid;border-color:var(--context-box-border-color);background:var(--context-box-background);box-shadow:var(--context-box-box-shadow);font-size:var(--base-font-size-sm);-webkit-user-select:none;user-select:none;position:relative;overflow:hidden}[data-combobox-viewport]{flex-direction:column;gap:1px;display:flex}[data-bits-floating-content-wrapper]{padding:0}[data-combobox-item]{padding:var(--spacer-4) var(--spacer-8);align-items:center;gap:.5rem;gap:var(--spacer-8);border-radius:var(--context-box-menu-item-border-radius);background:var(--context-box-menu-item-background);color:var(--context-box-menu-item-color);cursor:pointer;-webkit-user-select:none;user-select:none;grid-template-columns:1fr auto;transition:background .2s ease-in-out,color .2s ease-in-out;display:grid}[data-combobox-item]:first-of-type{margin-top:var(--spacer-r-12)}[data-combobox-item]:last-of-type{margin-bottom:var(--spacer-r-12)}[data-combobox-item][data-highlighted]{background:var(--context-box-menu-item-hover-background);color:var(--context-box-menu-item-hover-color)}[data-combobox-item][data-selected]{background:var(--context-box-menu-item-active-background);color:var(--context-box-menu-item-active-color)}[data-combobox-item][data-disabled]{cursor:not-allowed;opacity:.5}[data-combobox-scroll-up-button],[data-combobox-scroll-down-button]{z-index:var(--z-index-local-overlay);padding:var(--spacer-4);background:linear-gradient(to bottom, var(--context-box-background), transparent);color:var(--context-box-menu-item-color);cursor:pointer;place-items:center;display:grid;position:absolute;top:0;left:0;right:0}:is([data-combobox-scroll-up-button],[data-combobox-scroll-down-button]):hover{background:var(--context-box-menu-item-hover-background);color:var(--context-box-menu-item-hover-color)}[data-combobox-scroll-down-button]{background:linear-gradient(to top, var(--context-box-background), transparent);top:auto;bottom:0}[data-combobox-scroll-down-button]:hover{background:var(--context-box-menu-item-hover-background)}.embed-buttons{align-items:start;gap:var(--spacer-r-16);flex-direction:column;display:flex}.embed-buttons__buttons{gap:var(--spacer-r-12);flex-wrap:wrap;display:flex}}@value container-xs, container-sm, container-md, container-lg, container-inner-xs, container-inner-sm, container-inner-md, container-inner-lg from "./viewports.css";.message__bot-layout{gap:var(--spacer-r-16);width:100%;display:flex}.message__bot-avatar{top:var(--spacer-80);width:var(--spacer-24);height:var(--spacer-24);margin-top:calc(var(--spacer-1) * -1);margin-bottom:var(--spacer-20);flex-shrink:0;display:none;position:sticky;overflow:clip}@container chat-container (width>=480px){.message__bot-avatar{display:block}}@container chat-container (width>=640px){.message__bot-avatar{width:var(--spacer-32);height:var(--spacer-32);margin-top:calc(var(--spacer-3) * -1);margin-bottom:var(--spacer-16)}}.svg--avatar--hide{visibility:hidden;height:0;margin-top:0;margin-bottom:0;padding-top:0;padding-bottom:0}.message__content,.message__bot-body,.message__bot-options{min-width:0}.message__bot-body{width:100%}.message__bot-options{z-index:var(--z-index-local-overlay);column-gap:var(--spacer-20);row-gap:var(--spacer-8);margin-top:var(--spacer-24);padding-top:var(--spacer-12);border-top-width:var(--message-options-border-width);border-color:var(--message-options-border-color);flex-wrap:wrap;justify-content:space-between;align-items:center;display:flex}@container chat-container (width>=640px){.message__bot-options{margin-top:var(--spacer-32);margin-bottom:var(--spacer-20)}}.message__bot-options:has(>:only-child){justify-content:flex-end}.message__bot-references{--btn-padding-x:var(--btn-padding-y);column-gap:var(--spacer-8);margin-left:calc(var(--btn-padding-x) * -1);flex-wrap:wrap;flex-grow:1;align-items:center;display:flex}.message__bot-references :where(.btn__label){display:flex}.message__bot-actions{--btn-padding-x:var(--btn-padding-y);margin-right:calc(var(--btn-padding-x) * -1);display:flex;position:relative}@container chat-container (width>=640px){.message__bot-actions{gap:var(--spacer-8)}}.message__bot-loading{width:var(--spacer-16);height:var(--spacer-16);margin:0 var(--spacer-2);display:inline-block}`;function xF(e,{delay:t=0,duration:n=200,easing:r=e=>e,baseScale:i=0,transformOrigin:a=`bottom right`,scaleDirection:o=`scale`}={}){if(window.matchMedia(`(prefers-reduced-motion: reduce)`).matches)return{delay:0,duration:0,css:()=>`opacity: 1; transform: ${o}(1); transform-origin: ${a};`};let s=getComputedStyle(e),c=+s.opacity,l=s.transform.match(/scale[XY]?\(([0-9.]+)\)/),u=l?+l[1]:1,d=1-i;return{delay:t,duration:n,css:e=>{let t=r(e),n=t*u*d+i;return`opacity: ${t*c}; transform: ${o}(${n}); transform-origin: ${a};`}}}var SF=R(`<div class="loader-container svelte-6xtyn8"><svg width="40" height="40" viewBox="0 0 24 24"><circle cx="4" cy="12" r="3"><animate id="spinner_qFRN" begin="0;spinner_OcgL.end+0.25s" attributeName="cy" calcMode="spline" dur="0.6s" values="12;6;12" keySplines=".33,.66,.66,1;.33,0,.66,.33"></animate></circle><circle cx="12" cy="12" r="3"><animate begin="spinner_qFRN.begin+0.1s" attributeName="cy" calcMode="spline" dur="0.6s" values="12;6;12" keySplines=".33,.66,.66,1;.33,0,.66,.33"></animate></circle><circle cx="20" cy="12" r="3"><animate id="spinner_OcgL" begin="spinner_qFRN.begin+0.2s" attributeName="cy" calcMode="spline" dur="0.6s" values="12;6;12" keySplines=".33,.66,.66,1;.33,0,.66,.33"></animate></circle></svg></div>`),CF={hash:`svelte-6xtyn8`,code:`.loader-container.svelte-6xtyn8 {display:flex;z-index:var(--z-index-loader);position:absolute;top:0;right:0;bottom:0;left:0;align-items:center;justify-content:center;background-color:#fff;}`};function wF(e,t){D(t,!0),ga(e,CF);let n=K(t,`color`,7),r=K(t,`background`,7);var i={get color(){return n()},set color(e){n(e),k()},get background(){return r()},set background(e){r(e),k()}},a=SF(),o=N(a);return E(a),I(()=>{ka(a,r()?`background: ${r()};`:``),G(o,`fill`,n()??`rgba(127, 127, 127, 0.3)`)}),B(e,a),O(i)}q(wF,{color:{},background:{}},[],[],{mode:`open`});var TF=`@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;tab-size:4;font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent;font-family:ui-sans-serif,system-ui,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;line-height:1.5}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-feature-settings:normal;font-variation-settings:normal;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab, red, red)){::placeholder{color:color-mix(in oklab, currentcolor 50%, transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){appearance:button}::file-selector-button{appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}.chat-app{--spacer-1:.0625rem;--spacer-2:.125rem;--spacer-3:.1875rem;--spacer-4:.25rem;--spacer-5:.3125rem;--spacer-6:.375rem;--spacer-8:.5rem;--spacer-10:.625rem;--spacer-12:.75rem;--spacer-16:1rem;--spacer-20:1.25rem;--spacer-24:1.5rem;--spacer-28:1.75rem;--spacer-32:2rem;--spacer-40:2.5rem;--spacer-48:3rem;--spacer-56:3.5rem;--spacer-64:4rem;--spacer-72:4.5rem;--spacer-80:5rem;--spacer-120:7.5rem;--spacer-r-8:clamp(.375rem, .3182rem + .2841cqw, .5rem);--spacer-r-12:clamp(.625rem, .5682rem + .2841cqw, .75rem);--spacer-r-16:clamp(.75rem, .6364rem + .5682cqw, 1rem);--spacer-r-20:clamp(.875rem, .7045rem + .8523cqw, 1.25rem);--spacer-r-24:clamp(1rem, .7727rem + 1.1364cqw, 1.5rem);--spacer-r-28:clamp(1.125rem, .8409rem + 1.4205cqw, 1.75rem);--spacer-r-32:clamp(1.25rem, .9091rem + 1.7045cqw, 2rem);--spacer-r-40:clamp(1.5rem, 1.0455rem + 2.2727cqw, 2.5rem);--spacer-r-48:clamp(1.625rem, 1rem + 3.125cqw, 3rem);--spacer-r-56:clamp(1.75rem, .9545rem + 3.9773cqw, 3.5rem);--spacer-r-64:clamp(2rem, 1.0909rem + 4.5455cqw, 4rem);--spacer-r-80:clamp(3rem, 2.0909rem + 4.5455cqw, 5rem);--spacer-r-96:clamp(3.5rem, 2.3636rem + 5.6818cqw, 6rem);--spacer-r-120:clamp(4rem, 2.4091rem + 7.9545cqw, 7.5rem);--default-transition-duration:.2s;--default-transition-timing-function:ease-in-out;--z-index-flyout:10000;--z-index-dialog:600;--z-index-loader:500;--z-index-reference-number:400;--z-index-footer:300;--z-index-header:200;--z-index-tooltip:100;--z-index-tooltip-hover:101;--z-index-local-overlay:10;--z-index-below:-10;--ease-out-quart:cubic-bezier(.165, .84, .44, 1);--ease-in-quart:cubic-bezier(.895, .03, .685, .22);--ease-in-out-quart:cubic-bezier(.77, 0, .175, 1);--fly-in-id:0;--btn-padding-x:var(--spacer-r-20);--btn-padding-y:var(--spacer-r-8);--btn-icon-size:var(--spacer-24);--btn-submit-size:2.5em;--last-bot-message-min-height:0}.chat-app :where(h1,.h1,h2,.h2,h3,.h3,h4,.h4,h5,.h5,h6,.h6){font-weight:var(--base-font-weight-title);line-height:var(--base-line-height-tight)}.chat-app :where(b,strong){font-weight:var(--base-font-weight-bold)}.chat-app :where(button){cursor:pointer}.chat-app :where(input[type=text],input[type=email],input[type=search],input[type=password],textarea,select){width:100%;padding:var(--input-padding);border-width:var(--input-border-width);border-radius:var(--input-border-radius);border-color:var(--input-border-color);background:var(--input-background);box-shadow:var(--input-box-shadow,none);color:var(--input-color)}.chat-app :where(input[type=text],input[type=email],input[type=search],input[type=password],textarea,select)::placeholder{color:var(--input-placeholder-color);opacity:var(--input-placeholder-opacity)}.chat-app :where(input[type=radio],input[type=checkbox]){margin:0}.chat-app :where(:focus-visible){border-radius:var(--btn-primary-border-radius);outline-color:var(--body-focus-color);outline-style:var(--body-focus-style);outline-width:var(--body-focus-width);outline-offset:var(--body-focus-offset)}.chat-app ::selection{background:var(--body-selection-background);color:var(--body-selection-color)}.chat-app ::-webkit-scrollbar{width:8px;height:8px}.chat-app ::-webkit-scrollbar-track{background:0 0}.chat-app ::-webkit-scrollbar-thumb{background-color:#0000004d;border-radius:4px;transition:background-color .2s}.chat-app ::-webkit-scrollbar-thumb:hover{background-color:#00000080}.chat-app *{scrollbar-color:#0000004d transparent;scrollbar-width:thin}.chat-app ::-webkit-scrollbar-thumb{visibility:hidden}.chat-app :hover::-webkit-scrollbar-thumb{visibility:visible}.chat-app :active::-webkit-scrollbar-thumb{visibility:visible}.chat-app :focus::-webkit-scrollbar-thumb{visibility:visible}.svg{width:var(--spacer-r-24);height:auto}.svg svg{width:100%;height:auto;display:block;overflow:visible}}@layer utilities{.chat-app :where(.expand-interaction){position:relative}.chat-app :where(.expand-interaction):after{content:"";background-color:#0000;position:absolute;inset:0}.chat-app :where(.sr-only){clip:rect(0, 0, 0, 0);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.chat-app :where(.transition-colors){transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color,box-shadow;transition-timing-function:var(--default-transition-timing-function)}.chat-app :where(.transition){transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter;transition-timing-function:var(--default-transition-timing-function)}.chat-app :where(.skip-link){width:0;height:0;color:var(--anchor-color);font-weight:700;font-size:var(--base-font-size-xs);position:absolute;overflow:hidden}.chat-app :where(.skip-link):focus-visible{width:auto;height:auto;position:static}.chat-app :where(.fly-in){--fly-in-id:0;--fly-in-duration:.4s;--fly-out-duration:.2s;--fly-in-delay:.3s;--fly-in-delay-additional:.1s;--fly-in-y:var(--spacer-r-64);transform:translateY(var(--fly-in-y));opacity:0;transition-delay:0s,1s;transition-duration:var(--fly-out-duration);transition-property:opacity,transform;transition-timing-function:ease, var(--ease-out-quart)}.chat-app :where(.mounted .fly-in){opacity:1;transition-delay:calc(var(--fly-in-delay) + var(--fly-in-id) * var(--fly-in-delay-additional));transition-duration:var(--fly-in-duration);transform:translateY(0)}.chat-app :where(.truncate){text-overflow:ellipsis;white-space:nowrap;display:inline-block;overflow:hidden}.chat-app :where(.line-clamp){-webkit-line-clamp:1;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.chat-app :where(.line-clamp--2){-webkit-line-clamp:2}.chat-app :where(.line-clamp--6){-webkit-line-clamp:6}.chat-app :where(.container){width:100%;max-width:var(--container-max-width,1024px);padding-right:var(--spacer-16);padding-left:var(--spacer-16);margin:0 auto}@container chat-container (width>=640px){.chat-app :where(.container){padding-right:var(--spacer-32);padding-left:var(--spacer-32)}}@container chat-container (width>=768px){.chat-app :where(.container){padding-right:var(--spacer-48);padding-left:var(--spacer-48)}}.chat-app :where(h1){font-size:var(--base-font-size-h1)}.chat-app :where(h2){font-size:var(--base-font-size-h2)}.chat-app :where(h3){font-size:var(--base-font-size-h3)}.chat-app :where(h4,h5,h6){font-size:var(--body-font-size)}.chat-app :where(.h1){font-size:var(--base-font-size-h1)}.chat-app :where(.h2){font-size:var(--base-font-size-h2)}.chat-app :where(.h3){font-size:var(--base-font-size-h3)}.chat-app :where(.h4,.h5,.h6){font-size:var(--body-font-size)}.chat-app :where(.text-container)>:where(p,ul,ol,img,table){margin-bottom:var(--spacer-r-24);display:block}.chat-app :where(.text-container)>:where(div){margin:var(--spacer-r-40) 0}.chat-app :where(.text-container)>:where(h1,.h1){margin-bottom:var(--spacer-r-28)}.chat-app :where(.text-container)>:where(h2,.h2,h3,.h3,h4,.h4,h5,.h5,h6,.h6){margin-bottom:var(--spacer-r-20)}.chat-app :where(.text-container)>:where(h1,.h1,h2,.h2,h3,.h3,h4,.h4,h5,.h5,h6,.h6){margin-top:var(--spacer-r-40)}.chat-app :where(.text-container)>:where(ul:not(.no-list-styling),ol:not(.no-list-styling))>:where(li){margin-bottom:var(--spacer-12)}.chat-app :where(.text-container)>:where(ul:not(.no-list-styling),ol:not(.no-list-styling))>:where(li):last-child{margin-bottom:0}.chat-app :where(.text-container)>:where(ol){padding-left:1.5em;list-style-type:decimal;list-style-position:outside}.chat-app :where(.text-container)>:where(ul:not(.no-list-styling))>:where(li){padding-left:1em;position:relative}.chat-app :where(.text-container)>:where(ul:not(.no-list-styling))>:where(li):before{content:"•";font-size:.9em;position:absolute;top:0;left:0}.chat-app :where(.text-container)>:where(hr){height:1px;margin:var(--spacer-r-40) 0;background-color:var(--color-grey-700);background-color:var(--hr-color);border:none}.chat-app :where(.text-container) :where(a:not(.button,.no-link-styling,.reference)){color:var(--anchor-color);font-weight:var(--anchor-font-weight,var(--base-font-weight-normal));-webkit-text-decoration:var(--anchor-text-decoration,underline);text-decoration:var(--anchor-text-decoration,underline);text-underline-offset:var(--anchor-text-underline-offset,.15em);transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color;transition-timing-function:var(--default-transition-timing-function)}.chat-app :where(.text-container) :where(a:not(.button,.no-link-styling,.reference)):hover{color:var(--anchor-hover-color)}.chat-app :where(.text-container) :where(table){border-collapse:collapse;border-spacing:0;-webkit-overflow-scrolling:touch;width:100%;display:block;overflow-x:auto}.chat-app :where(.text-container) :where(th){width:1000px;padding:var(--spacer-12) var(--spacer-16) var(--spacer-12) 0;border-bottom:1px solid var(--color-grey-300);line-height:var(--base-line-height-tight);text-align:left;vertical-align:bottom}.chat-app :where(.text-container) :where(td){padding:var(--spacer-12) var(--spacer-16) var(--spacer-12) 0;border-bottom:1px solid var(--color-grey-300);vertical-align:top}.chat-app :where(.text-container) :where(tr:last-child td){border-bottom:none}.chat-app :where(.text-container) :where(:first-child){margin-top:0}.chat-app :where(.text-container) :where(:last-child){margin-bottom:0}.chat-app :where(.animated-height){transition:height .5s var(--ease-in-out-quart)}.chat-app :where(.display-contents){display:contents}.chat-app :where(.absolute){position:absolute!important}}@layer components{.chat-app{display:contents}.chat-app__container{height:100%;display:flex;overflow:hidden;transform:translateZ(0);container:chat-container/inline-size}.chat-app__container>:where(*){color:var(--body-color);font-style:normal;font-weight:var(--base-font-weight-normal);font-size:var(--base-font-size-body);line-height:var(--base-line-height-default);font-family:var(--font-family);font-optical-sizing:auto}.chat-app__container.chat-app__container--inline-layout-contained{height:90svh;scroll-margin-top:10svh}@media (width>=768px){.chat-app__container.chat-app__container--inline-layout-contained{height:100svh;scroll-margin-top:0}}.chat-app__main{overscroll-behavior-x:none;overscroll-behavior-y:contain;background:var(--body-background);scrollbar-gutter:stable;touch-action:pan-y;flex-direction:column;width:100%;height:100%;display:flex;overflow:hidden auto;container:chat-inner-container/inline-size}.chat-app__container--inline-layout .chat-app__main{overscroll-behavior-y:auto}.chat-app__loader-container{z-index:var(--z-index-loader);justify-content:center;align-items:center;width:100%;height:100%;display:flex;position:relative}.chat-app__portals{display:contents}.chat-app__header{z-index:var(--z-index-header);background:var(--body-background);position:sticky;top:0}.chat-app__header--unsticked{position:relative}.chat-app__header-content{--btn-padding-x:var(--btn-padding-y);column-gap:var(--spacer-r-12);min-height:calc(var(--btn-padding-y) * 2 + var(--btn-icon-size) + var(--spacer-10) * 2);margin-right:calc(var(--btn-padding-x) * -1);margin-left:calc(var(--btn-padding-x) * -1);padding-top:var(--spacer-10);padding-bottom:var(--spacer-10);flex-wrap:wrap;justify-content:flex-end;align-items:center;display:flex;position:relative}.chat-app__header-content>:where(*){z-index:0;pointer-events:auto;position:relative}.chat-app__header-content:after{right:var(--btn-padding-x);bottom:0;left:var(--btn-padding-x);content:"";border-bottom:1px solid #0000;transition:border-color .1s ease-in-out;position:absolute}.chat-app__header-content.has-border:after{border-color:var(--base-line-color)}.chat-app__header-new-conversation{margin-right:auto;position:relative}@container chat-container (width>=640px){.chat-app__header-new-conversation .tooltip{display:none}}.chat-app__header--with-logo :where(.chat-app__header-content){margin-left:0}.chat-app__header--with-logo :where(.chat-app__header-new-conversation){margin-right:unset;margin-left:auto}.chat-app__header-logo{margin-right:auto}.chat-app__header-logo :where(svg){width:auto;height:var(--spacer-28)}.chat-app__body{flex-direction:column;flex-grow:1;width:100%;display:flex;position:relative}.chat-app__page-transition{flex-direction:column;flex-grow:1;width:100%;height:100%;display:flex}.chat-app__aside{--duration-in:.65s;--duration-out:.5s;visibility:hidden;width:0;transition-delay:0s, var(--duration-out);transition-duration:var(--duration-out), 0s;transition-property:width,visibility;transition-timing-function:var(--ease-in-out-quart), linear;flex-grow:1;position:relative;top:0;bottom:0}.chat-app__aside.open{visibility:visible;width:var(--aside-width);transition-delay:0s;transition-duration:var(--duration-in), 0s;transition-timing-function:var(--ease-out-quart), linear}.chat-app__aside .tooltip{--background-color:var(--btn-secondary-hover-background)}.chat-app__aside-container{width:var(--aside-width);overscroll-behavior:contain;border-left-width:var(--aside-border-width);border-color:var(--aside-border-color);background:var(--aside-background);scrollbar-gutter:stable;height:100%;position:relative;overflow-y:auto}.chat-app__container--inline-layout .chat-app__aside-container{overscroll-behavior-y:auto}.chat-app__aside-header,.chat-app__sheet-header{z-index:var(--z-index-header);flex-wrap:no-wrap;padding:var(--spacer-12) var(--spacer-12) var(--spacer-12) var(--spacer-24);justify-content:space-between;align-items:center;gap:var(--spacer-24);border-bottom-width:var(--aside-header-border-width);border-color:var(--aside-header-border-color);background:var(--aside-background);color:var(--aside-header-color);display:flex;position:sticky;top:0}.chat-app__sheet-close{position:relative}.chat-app__sheet-overlay{z-index:var(--z-index-dialog);background:var(--aside-background-overlay);position:fixed;inset:0}.chat-app__sheet-content{z-index:var(--z-index-flyout);width:100%;max-width:var(--aside-width);overscroll-behavior:contain;border-left-width:var(--aside-border-width);border-color:var(--aside-border-color);background:var(--aside-background);scrollbar-gutter:stable;height:100%;position:fixed;top:0;right:0;overflow-y:auto}.chat-app__container--inline-layout .chat-app__sheet-content{overscroll-behavior-y:auto}:is(.chat-app__aside-close,.chat-app__sheet-close) :where(.btn){background-color:#0000}.chat-app__aside-title,.chat-app__sheet-title{font-size:var(--base-font-size-sm)}.chat-app__close-button{z-index:var(--z-index-flyout)}.open-button{--open-button-avatar-height:var(--spacer-r-80);--open-button-avatar-width:var(--spacer-r-80);--open-button-duration:.4s;--open-button-delay:.3s;--open-button-ease:ease-in-out;cursor:pointer;flex-direction:row;align-items:flex-end;transition:opacity .15s ease-out;display:flex}.open-button--expanded{opacity:0;pointer-events:none}.open-button__text{margin-right:calc(var(--open-button-avatar-width) * -.5);padding-top:var(--spacer-r-12);padding-right:0;padding-bottom:var(--spacer-r-12);border-width:var(--open-button-border-width);border-radius:var(--open-button-border-radius);border-color:var(--open-button-border-color);background:var(--open-button-background);color:var(--open-button-color);text-align:left;transition:transform var(--open-button-duration) var(--open-button-ease), padding-right var(--open-button-duration) var(--open-button-delay) var(--open-button-ease);flex-direction:column;justify-content:center;align-items:flex-start;padding-left:0;display:flex;position:absolute;bottom:50%;right:100%;overflow:hidden;transform:translateY(50%);box-shadow:0 4px 6px -1px #0000001a,0 2px 4px -2px #0000001a}.open-button:is(:hover,.open-button--programmatic-expand) .open-button__text{background:var(--open-button-hover-background,var(--open-button-background));color:var(--open-button-hover-color,var(--open-button-color));opacity:1;transition:transform var(--open-button-duration) var(--open-button-delay) var(--open-button-ease);transform:translateY(0)}.open-button__title{max-width:240px;padding:0 calc(var(--open-button-avatar-width) * .5 + var(--spacer-r-12)) 0 var(--spacer-r-12);white-space:pre;font-weight:700}.open-button__mask{width:0;height:0;transition:width var(--open-button-duration) var(--open-button-delay) var(--open-button-ease), height var(--open-button-duration) var(--open-button-ease);overflow:hidden}.open-button:is(:hover,.open-button--programmatic-expand) .open-button__mask{transition:width var(--open-button-duration) var(--open-button-ease), height var(--open-button-duration) var(--open-button-delay) var(--open-button-ease)}.open-button__description{width:50cqw;max-width:260px;padding:0 calc(var(--open-button-avatar-width) * .5 + var(--spacer-r-12)) 0 var(--spacer-r-12);text-wrap:balance;position:relative}.open-button__avatar{z-index:var(--z-index-local-overlay);width:var(--open-button-avatar-width);height:var(--open-button-avatar-height);border-radius:var(--spacer-r-80);filter:drop-shadow(0 4px 6px #00000026);transition:transform .2s var(--open-button-ease);position:relative;overflow:clip}.open-button:is(:hover,.open-button--programmatic-expand) .open-button__avatar{transform:scale(1.05)}.open-button__link-icon{width:var(--spacer-r-80);height:var(--spacer-r-80);padding:var(--spacer-r-20);color:var(--open-button-color);display:none;position:absolute;right:0}:where(.open-button--standalone){right:var(--spacer-r-16);bottom:var(--spacer-r-16);position:fixed}@media (prefers-reduced-motion:reduce){.open-button__text,.open-button__mask,.open-button:hover .open-button__text,.open-button:hover .open-button__mask{transition:none!important}.open-button__avatar,.open-button:hover .open-button__avatar{filter:none!important;transition:none!important}}.open-button--hide-title-when-collapsed .open-button__text{visibility:hidden;opacity:0;transition:transform var(--open-button-duration) var(--open-button-ease), padding-right var(--open-button-duration) var(--open-button-delay) var(--open-button-ease), opacity var(--open-button-duration) var(--open-button-delay) var(--open-button-ease), visibility 0s linear calc(var(--open-button-duration) + var(--open-button-delay))}.open-button--hide-title-when-collapsed:is(:hover,.open-button--programmatic-expand) .open-button__text{visibility:visible;background:var(--open-button-hover-background,var(--open-button-background));color:var(--open-button-hover-color,var(--open-button-color));opacity:1;transition:transform var(--open-button-duration) var(--open-button-delay) var(--open-button-ease), opacity var(--open-button-duration) var(--open-button-ease), visibility 0s linear 0s;transform:translateY(0)}}@value container-xs, container-sm, container-md, container-lg, container-inner-xs, container-inner-sm, container-inner-md, container-inner-lg from "./viewports.css";`,EF=typeof window<`u`?window:{screen:{},navigator:{}},DF=(EF.matchMedia||(function(){return{matches:!1}})).bind(EF),OF={get passive(){return!0}},kF=function(){};EF.addEventListener&&EF.addEventListener(`p`,kF,OF),EF.removeEventListener&&EF.removeEventListener(`p`,kF,!1),`PointerEvent`in EF;var AF=`ontouchstart`in EF,jF=`TouchEvent`in EF,MF=AF||jF&&DF(`(any-pointer: coarse)`).matches,NF=(EF.navigator.maxTouchPoints||0)>0||MF,PF=EF.navigator.userAgent||``,FF=DF(`(pointer: coarse)`).matches&&/iPad|Macintosh/.test(PF)&&Math.min(EF.screen.width||0,EF.screen.height||0)>=768,IF=(DF(`(pointer: coarse)`).matches||!DF(`(pointer: fine)`).matches&&AF)&&!/Windows.*Firefox/.test(PF),LF=DF(`(any-pointer: fine)`).matches||DF(`(any-hover: hover)`).matches||FF||!AF,RF=NF&&(LF||!IF)?`hybrid`:NF?`touchOnly`:`mouseOnly`,zF=RF===`mouseOnly`?`mouse`:RF===`touchOnly`||IF?`touch`:`mouse`,BF=R(`<div class="open-button__title"></div>`),VF=R(`<div class="open-button__mask"><div class="open-button__description"></div></div>`),HF=R(`<div class="open-button__text"><!> <!></div>`),UF=R(`<div class="sr-only"> </div>`),WF=R(`<!> <div class="svg svg--avatar open-button__avatar" aria-hidden="true"></div>`,1),GF=R(`<link rel="stylesheet"/>`),KF=R(`<!> <!>`,1),qF=R(`<!> <!> <!> <main class="chat-app"><!></main>`,1);function JF(e,t){D(t,!0);let n=(e,n)=>{let r=()=>n?.().chatConfig,i=()=>n?.().language,a=()=>n?.().colorScheme,c=A(()=>{let{openButtonTitle:e,openButtonDescription:t}=r().translations[i()];return{openButtonTitle:e,openButtonDescription:t}}),l=A(()=>r().fullTheme[a()].tokens.svgs),u=A(()=>r().fullTheme[a()]?.tokens.components.openButton?.custom),d=A(()=>!!L(u)?.hideTitleWhenCollapsed);{let n=A(()=>r().buttonHref?void 0:s()?`true`:`false`),i=A(()=>r().buttonHref?void 0:`true`),a=A(()=>r().buttonHref?void 0:o()),u=A(()=>[`open-button`,t.buttonClass,Z.data.flyoutIsOpen?`open-button--expanded`:void 0,L(d)?`open-button--hide-title-when-collapsed`:void 0]);GA(e,{get href(){return r().buttonHref},onclick:de,onmouseenter:le,onmouseleave:ue,use:w,get"aria-expanded"(){return L(n)},get"aria-haspopup"(){return L(i)},get"aria-controls"(){return L(a)},get style(){return t.buttonStyle},get className(){return L(u)},get isStandalone(){return L(f)},children:(e,t)=>{var n=WF(),r=P(n),i=e=>{var t=HF(),n=N(t),r=e=>{var t=BF();na(t,()=>L(c).openButtonTitle,!0),E(t),B(e,t)};U(n,e=>{L(c).openButtonTitle&&e(r)});var i=F(n,2),a=e=>{var t=VF(),n=N(t);na(n,()=>L(c).openButtonDescription,!0),E(n),so(n,e=>M(v,e),()=>L(v)),E(t),so(t,e=>M(_,e),()=>L(_)),B(e,t)};U(i,e=>{L(c).openButtonDescription&&zF===`mouse`&&e(a)}),E(t),B(e,t)},a=e=>{var t=UF(),n=N(t,!0);E(t),I(()=>V(n,Z.t.ariaOpenChat)),B(e,t)};U(r,e=>{L(c).openButtonTitle||L(c).openButtonDescription?e(i):e(a,-1)});var o=F(r,2);na(o,()=>L(l).avatar,!0),E(o),B(e,n)},$$slots:{default:!0}})}},r=j(`light`),i=K(t,`host`,7),a=K(t,`onError`,7),o=K(t,`flyoutId`,7),s=K(t,`flyoutIsOpen`,7),c=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`host`,`onError`,`flyoutId`,`flyoutIsOpen`]),l=async e=>{let t=await(await fetch(`${e}/chatconfig`)).json();return Gg.parse(t)},u=async({forceTheme:e,lang:t,apiUrl:n})=>{let r=L_(window.CHAT_CONFIG_OVERRIDE?window.CHAT_CONFIG_OVERRIDE:await l(n)),i;i=t?V_(t,r.supportedLanguages):W_(r.supportedLanguages);let a=Py(Object.keys(r.fullTheme));return{chatConfig:r,language:i,colorScheme:a}},d=(e,t)=>{if(e==null)return t;if(typeof e==`string`){let t=e.trim().toLowerCase();return!(t===``||t===`0`||t===`false`||t===`no`)}return typeof e==`number`?e!==0:typeof e==`boolean`?e:t},f=A(()=>!!i()),p=j(!1),m=j(!1),h=j(!1),g=j(void 0),_=j(void 0),v=j(void 0),y=A(()=>L(v)?.offsetWidth??0),b=A(()=>L(v)?.offsetHeight??0),x=j(void 0),S=j(!1),C,ee=j(!0);function te(){return L(x)?(clearTimeout(L(x)),M(x,void 0),!0):!1}async function ne(e){M(r,e.colorScheme,!0),C?.(),te(),M(S,!1);let n=e.chatConfig.fullTheme[L(r)]?.tokens.components.openButton?.custom??{},i=n.autoExpandScrollThreshold,a=Number(n.autoCollapseDelay??0),o=Number.isNaN(a)?0:Math.max(0,a),c=d(n.autoExpandOnce,!1),l=(()=>{if(i==null)return 100;if(typeof i==`string`){if(i.trim().toLowerCase()===`none`)return 0;let e=Number(i);return Number.isNaN(e)?100:e}let e=Number(i);return Number.isNaN(e)?100:e})();if(Number.isNaN(l)||l<=0)return;let u=`liipgpt-auto-expand-${t.apiUrl}`,f=!1;if(typeof window<`u`)try{f=window.localStorage.getItem(u)===`true`}catch(e){console.warn(`LiipGPT: unable to read auto-expand flag`,e)}M(h,f,!0);let p=()=>{if(!(window.scrollY/window.innerHeight*100>=l)){M(ee,!0);return}if(!(L(m)||s())&&!(c&&(f||L(h)))&&L(ee)){if(M(ee,!1),M(m,!0),M(h,!0),se(),c&&typeof window<`u`)try{window.localStorage.setItem(u,`true`)}catch(e){console.warn(`LiipGPT: unable to persist auto-expand flag`,e)}M(x,setTimeout(()=>{L(S)||(ce(),M(m,!1)),M(x,void 0)},o),!0)}};window.addEventListener(`scroll`,p,{passive:!0}),l===0&&(await qr(),p()),C=()=>{window.removeEventListener(`scroll`,p)}}function re(){te(),M(m,!1),M(S,!1)}function w(e){M(g,e,!0)}function ie(){C?.(),te()}Li(ie);function ae(){!L(v)||!L(_)||(L(_).style.width=`${L(y)}px`,L(_).style.height=`${L(b)}px`)}function oe(){L(_)&&(L(_).style.width=`0`,L(_).style.height=`0`)}function se(){L(g)&&(L(g).classList.add(`open-button--programmatic-expand`),ae())}function ce(){L(g)&&(L(g).classList.remove(`open-button--programmatic-expand`),oe())}function le(){te()&&M(S,!0),ae()}function ue(){te(),L(S)&&(M(m,!1),M(S,!1),L(g)?.classList.remove(`open-button--programmatic-expand`)),L(p)||oe()}function de(e){re(),t.onclick?.(e)}let fe=A(()=>u(c).then(async e=>(await ne(e),e)).catch(e=>a()(e)));var pe={get host(){return i()},set host(e){i(e),k()},get onError(){return a()},set onError(e){a(e),k()},get flyoutId(){return o()},set flyoutId(e){o(e),k()},get flyoutIsOpen(){return s()},set flyoutIsOpen(e){s(e),k()}},me=z();return ii(`beforeunload`,An,ie),ha(`1k415fq`,e=>{var t=z(),n=P(t),r=e=>{var t=z();Ui(P(t),()=>L(fe),null,(e,t)=>{let n=A(()=>L(t).chatConfig.fullTheme[L(t).colorScheme]);var r=KF(),i=P(r);Xi(i,17,()=>L(n).fontURLs??[],Ki,(e,t)=>{var n=GF();I(()=>G(n,`href`,L(t))),B(e,n)}),yF(F(i,2),{id:`font-css`,get css(){return L(n).fontCSS}}),B(e,r)}),B(e,t)};U(n,e=>{L(f)&&e(r)}),B(e,t)}),Ui(P(me),()=>L(fe),e=>{},(e,t)=>{let i=A(()=>L(t).chatConfig.fullTheme[L(r)]);var a=z(),o=P(a),s=e=>{var r=qF(),a=P(r);{let e=A(()=>vF(L(i).tokens));yF(a,{id:`theme-css`,get css(){return L(e)}})}var o=F(a,2);yF(o,{id:`app-css`,get css(){return TF}});var s=F(o,2);yF(s,{id:`custom-css`,get css(){return L(i).customCSS}});var c=F(s,2);n(N(c),()=>L(t)),E(c),B(e,r)},c=e=>{n(e,()=>L(t))};U(o,e=>{L(f)?e(s):e(c,-1)}),B(e,a)}),B(e,me),O(pe)}q(JF,{host:{},onError:{},flyoutId:{},flyoutIsOpen:{}},[],[],{mode:`open`});var YF=R(`<div class="flyout__backdrop"></div>`),XF=R(`<div class="flyout__content"><!></div>`),ZF=R(`<div><!> <div class="flyout__body"><!> <div><!></div></div></div>`),QF=R(`<!> <div class="chat-app__container"><div class="chat-app__loader-container"><!></div></div>`,1);function $F(e,t){D(t,!0);let n=K(t,`children`,7),r=K(t,`loaderColor`,7),i=K(t,`loaderBackground`,7),a=K(t,`flyout`,7),o=K(t,`flyoutClass`,7),s=K(t,`flyoutStyle`,7),c=K(t,`onCloseChat`,7),l=K(t,`onError`,7),u=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`children`,`loaderColor`,`loaderBackground`,`flyout`,`flyoutClass`,`flyoutStyle`,`onCloseChat`,`onError`]),d=A(()=>Z.theme?.components?.flyout?.custom??{}),f=A(()=>({enabled:Z.data?.chatConfig?.enableBackdrop??!1,delayIn:Number(L(d).backdropDelayIn??0),durationIn:Number(L(d).backdropDurationIn??200),delayOut:Number(L(d).backdropDelayOut??0),durationOut:Number(L(d).backdropDurationOut??200),baseScaleIn:Number(L(d).backdropBaseScaleIn??1),baseScaleOut:Number(L(d).backdropBaseScaleOut??1),transformOrigin:String(L(d).backdropTransformOrigin??`center`),scaleDirection:String(L(d).backdropScaleDirection??`scale`)})),p=A(()=>({in:{delay:L(f).delayIn,duration:L(f).durationIn,baseScale:L(f).baseScaleIn,transformOrigin:L(f).transformOrigin,scaleDirection:L(f).scaleDirection},out:{delay:L(f).delayOut,duration:L(f).durationOut,baseScale:L(f).baseScaleOut,transformOrigin:L(f).transformOrigin,scaleDirection:L(f).scaleDirection}})),m,h=e=>{$n(()=>{let t=e=>{m=e};return e.addEventListener(`click`,t),()=>{e.removeEventListener(`click`,t),m=void 0}})},g=`flyout`,_=j(void 0),v=A(()=>Z.data.flyoutIsOpen),y=j(!1),b=A(()=>Z.initialized),x=A(()=>Z.data.hasOpenedOverlays);$n(()=>{!Z.data.flyoutIsOpen&&L(y)&&(L(_)?.querySelector(`button`))?.focus({preventScroll:!0}),M(y,L(v),!0)}),$n(()=>{if(L(b)&&L(v)){let e=e=>{e.key===`Escape`&&(L(x)||c()())};return document.addEventListener(`keydown`,e),()=>{document.removeEventListener(`keydown`,e)}}});var S={get children(){return n()},set children(e){n(e),k()},get loaderColor(){return r()},set loaderColor(e){r(e),k()},get loaderBackground(){return i()},set loaderBackground(e){i(e),k()},get flyout(){return a()},set flyout(e){a(e),k()},get flyoutClass(){return o()},set flyoutClass(e){o(e),k()},get flyoutStyle(){return s()},set flyoutStyle(e){s(e),k()},get onCloseChat(){return c()},set onCloseChat(e){c(e),k()},get onError(){return l()},set onError(e){l(e),k()}},C=z();ii(`click`,An,e=>{e!==m&&a()&&c()()});var ee=P(C),te=e=>{var t=z(),r=P(t),i=e=>{},a=e=>{var t=ZF(),r=N(t),i=e=>{var t=YF();fa(1,t,()=>xF,()=>({...L(p).in,easing:bA})),fa(2,t,()=>xF,()=>({...L(p).out,easing:bA})),B(e,t)};U(r,e=>{Z.data.flyoutIsOpen&&L(f).enabled&&e(i)});var a=F(r,2);G(a,`id`,g);var c=N(a),d=e=>{var t=XF();H(N(t),n),E(t),fa(1,t,()=>xF,()=>({delay:0,duration:500,easing:bA,baseScale:.3})),fa(2,t,()=>xF,()=>({delay:100,duration:300,easing:bA,baseScale:.7})),B(e,t)};U(c,e=>{Z.data.flyoutIsOpen&&e(d)});var m=F(c,2);JF(N(m),mo({get onError(){return l()},onclick:e=>{e.stopPropagation(),ub.openFlyout()},flyoutId:g,get flyoutIsOpen(){return L(v)},buttonClass:`flyout__open-button`},()=>u)),E(m),so(m,e=>M(_,e),()=>L(_)),E(a),_a(a,e=>h?.(e)),E(t),I(()=>{ka(t,s()),Da(t,1,xa([`flyout`,o()]))}),B(e,t)};U(r,e=>{Z.initialized?e(a,-1):e(i)}),B(e,t)},ne=e=>{var a=z(),o=P(a),s=e=>{var n=QF(),a=P(n);yF(a,{id:`app-css`,get css(){return bF}});var o=F(a,2),s=N(o);ra(N(s),t,`loader`,{},e=>{wF(e,{get background(){return i()},get color(){return r()}})}),E(s),E(o),fa(2,o,()=>HN,()=>({duration:200,delay:300})),B(e,n)},c=e=>{var t=z();H(P(t),n),B(e,t)};U(o,e=>{Z.initialized?e(c,-1):e(s)}),B(e,a)};return U(ee,e=>{a()?e(te):e(ne,-1)}),B(e,C),O(S)}q($F,{children:{},loaderColor:{},loaderBackground:{},flyout:{},flyoutClass:{},flyoutStyle:{},onCloseChat:{},onError:{}},[`loader`],[],{mode:`open`});var eI=R(`<button type="button"> </button>`),tI=R(`<div class="dialog-footer__actions"></div>`);function nI(e,t){D(t,!1);function n(e){let t=ub[e];typeof t==`function`&&t()}co();{let t=e=>{var t=z();na(P(t),()=>Z.data.openedPopup?.title),B(e,t)},r=e=>{var t=z();na(P(t),()=>Z.data.openedPopup?.content),B(e,t)},i=e=>{var t=z(),r=P(t),i=e=>{var t=tI();Xi(t,5,()=>Z.data.openedPopup.actions,Ki,(e,t)=>{let r=()=>L(t).action,i=()=>L(t).label,a=()=>L(t).type;var o=eI(),s=N(o,!0);E(o),I(()=>{Da(o,1,`btn btn--${a()??`secondary`??``}`),V(s,i())}),ai(`click`,o,()=>n(r())),B(e,o)}),E(t),B(e,t)};U(r,e=>{Z.data.openedPopup?.actions?.length&&e(i)}),B(e,t)},a=dn(()=>Z.data.openedPopup!==void 0);Uj(e,{get open(){return L(a)},get onClose(){return ub.closePopup},title:t,content:r,footer:i,$$slots:{title:!0,content:!0,footer:!0}})}O()}oi([`click`]),q(nI,{},[],[],{mode:`open`});var rI=R(`<span class="reference__description line-clamp line-clamp--6"> </span>`),iI=R(`<span class="reference__breadcrumb transition-colors"> </span>`),aI=R(`<span class="reference__footer"><span class="reference__domain transition-colors"><span class="truncate"> </span></span> <!></span>`),oI=R(`<div class="reference-number__content-wrapper" role="tooltip" aria-hidden="true"><a class="reference-number__content transition-colors no-link-styling" target="_blank" rel="noopener noreferrer" tabindex="-1" aria-hidden="true"><span class="reference__header"><h3 class="reference__title line-clamp line-clamp--2 h4"> </h3> <!></span> <!> <!></a></div>`),sI=R(`<div class="reference-number"><a target="_blank" rel="noopener noreferrer" class="reference-number__trigger transition-colors no-link-styling"> </a> <!></div>`);function cI(e,t){D(t,!0);let n=A(()=>Z.t),r=K(t,`usedNumber`,7),i=K(t,`source`,7),a=j(!1),o,s=j(void 0),c=j(void 0),l=A(i),u=A(()=>L(l).display.card.title),d=A(()=>L(l).display.card.description),f=A(()=>L(l).display.card.badge),p=A(()=>L(l).display.card.breadcrumbs),m={duration:Number(Z.theme.components.referenceNumberContent.custom?.transitionDuration)||200,delay:Number(Z.theme.components.referenceNumberContent.custom?.transitionDelay)||0,y:Number(Z.theme.components.referenceNumberContent.custom?.transitionY)||10},h=async()=>{if(!L(s)||!L(c))return;let{x:e,y:t}=await cO(L(s),L(c),{placement:`top`,middleware:[tO(8),rO(),nO({padding:8})]});Object.assign(L(c).style,{left:`${e}px`,top:`${t}px`})},g=()=>{o&&=(clearTimeout(o),void 0)},_=()=>{g(),o=setTimeout(()=>{M(a,!1)},100)},v=`tooltip-${e_()}`,y=e=>{e.key===`Escape`&&M(a,!1)},b=()=>{g(),M(a,!0)};$n(()=>{L(a)?document.addEventListener(`keydown`,y):document.removeEventListener(`keydown`,y)}),$n(()=>{L(a)&&h()});var x={get usedNumber(){return r()},set usedNumber(e){r(e),k()},get source(){return i()},set source(e){i(e),k()}},S=sI(),C=N(S),ee=N(C,!0);E(C),so(C,e=>M(s,e),()=>L(s));var te=F(C,2),ne=e=>{var t=oI(),n=N(t),r=N(n),i=N(r),a=N(i,!0);E(i),gb(F(i,2),{name:`externalLink`,class:`reference__icon transition-colors`}),E(r);var o=F(r,2),s=e=>{var t=rI(),n=N(t,!0);E(t),I(()=>V(n,L(d))),B(e,t)};U(o,e=>{L(d)&&e(s)});var h=F(o,2),g=e=>{var t=aI(),n=N(t),r=N(n),i=N(r,!0);E(r),E(n);var a=F(n,2),o=e=>{var t=z();Xi(P(t),17,()=>L(p),Ki,(e,t)=>{var n=iI(),r=N(n,!0);E(n),I(()=>V(r,L(t))),B(e,n)}),B(e,t)};U(a,e=>{L(p)&&e(o)}),E(t),I(()=>V(i,L(f))),B(e,t)};U(h,e=>{L(f)&&e(g)}),E(n),E(t),so(t,e=>M(c,e),()=>L(c)),I(()=>{G(t,`id`,v),G(n,`href`,L(l).url),V(a,L(u))}),ii(`mouseenter`,t,b),ii(`mouseleave`,t,_),fa(3,t,()=>TA,()=>m),B(e,t)};return U(te,e=>{L(a)&&e(ne)}),E(S),I(()=>{G(C,`href`,L(l).url),G(C,`aria-describedby`,L(a)?v:void 0),G(C,`aria-label`,`${L(n).referenceLink??``}: ${L(u)??``}`),G(C,`data-state`,L(a)?`open`:`closed`),V(ee,r())}),ii(`mouseenter`,C,b),ii(`mouseleave`,C,_),ii(`focus`,C,()=>M(a,!0)),ii(`blur`,C,()=>M(a,!1)),B(e,S),O(x)}customElements.define(`liipgpt-reference-number`,q(cI,{source:{attribute:`data-source`,type:`Object`},refNumber:{attribute:`data-all-index`,type:`String`},usedNumber:{attribute:`data-used-index`,type:`String`}},[],[]));var lI=`main-navigation`,uI=e=>{e.preventDefault(),Z.targets.chatAppMainNavigation&&(Z.targets.chatAppMainNavigation.scrollIntoView({behavior:`smooth`,block:`start`}),Z.targets.chatAppMainNavigation.focus())},dI=R(`<link rel="stylesheet"/>`),fI=R(`<link rel="stylesheet"/>`),pI=R(`<!> <!> <!>`,1),mI=R(`<link rel="stylesheet"/>`),hI=R(`<!> <!> <!> <!>`,1),gI=R(`<h1 class="sr-only"> </h1>`),_I=R(`<h2 class="sr-only absolute"> </h2>`),vI=R(`<div class="chat-app__header-logo"></div>`),yI=R(`<!> <!> <!>`,1),bI=R(`<!> <!> <!> <!>`,1),xI=R(`<div class="chat-app__page-transition"><!></div>`),SI=R(`<div><div class="chat-app__main"><div class="chat-app__portals"></div> <!> <div><div class="container"><!> <!> <div id="chat-app-header-portal"></div></div></div> <div class="chat-app__body"><!> <!></div></div> <!> <!></div>`),CI=R(`<div><!> <!></div>`);function wI(e,t){D(t,!0);let n=K(t,`host`,7),r=K(t,`onError`,7),i=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`host`,`onError`]);$n(()=>{let e={forceTheme:t.forceTheme,apiUrl:t.apiUrl,apiKey:t.apiKey,speechRecognitionApiKey:t.speechRecognitionApiKey,lang:t.lang,features:t.features,loaderBackground:t.loaderBackground,loaderColor:t.loaderColor,flyout:t.flyout,flyoutStyle:t.flyoutStyle,flyoutClass:t.flyoutClass,chatClass:t.chatClass,inlineLayout:t.inlineLayout,forceChatPage:t.forceChatPage,hidePredefinedQuestions:t.hidePredefinedQuestions,autofirePredefinedQuestionId:t.autofirePredefinedQuestionId,additionalStartParameters:t.additionalStartParameters,question:t.question,mode:t.mode,source:t.source,cache:t.cache};Xr(()=>ub.init(e).catch(e=>r()(e)))});let a=A(()=>Z.data.route.name),o=()=>{ub.closeFlyout(),n().dispatchEvent(new CustomEvent(`closechat`))};$n(()=>{Z.initialized&&Z.data?.chatConfig&&n().dispatchEvent(new CustomEvent(`configloaded`,{detail:Z.data.chatConfig}))});let s=j(void 0),c=j(null),l=k_.fineGrained?.light?.tokens?.components?.aside?.custom?.containerWidthForMobileLayout,u=j(!1),d=A(()=>L(c)?Z.data.props?.flyout||L(c)<=l:null),f=j(void 0),p=j(!1),m=j(0);$n(()=>{if(L(f)&&L(f).firstElementChild instanceof HTMLElement){let e=getComputedStyle(L(f).firstElementChild);M(m,parseFloat(e.paddingTop)||0,!0)}}),$n(()=>{let e=!1,t=()=>{e||(e=!0,requestAnimationFrame(()=>{L(s)&&(e=!1,Z.targets.scrollContainer?.scrollTop===0&&y(),M(p,L(s).scrollTop>=L(m)+1))}))};return t(),L(s)?.addEventListener(`scroll`,t,{passive:!0}),()=>L(s)?.removeEventListener(`scroll`,t)});let h=()=>{ub.closeReferencesAside()};$n(()=>{Z.initialized&&Z.data.currentReferencesAsideId?M(u,!0):M(u,!1)});let g=j(void 0),_,v=j(!1),y=()=>{M(v,!1),_?.disconnect(),_=new IntersectionObserver(([e])=>{e.isIntersecting?(M(v,!0),_.disconnect()):M(v,!1)},{root:Z.targets.scrollContainer,rootMargin:`-15% 0px 0px 0px`}),L(g)&&_.observe(L(g))};Ii(()=>{if(L(g))return y(),window.addEventListener(`resize`,y),()=>{_?.disconnect(),window.removeEventListener(`resize`,y)}});let b=A(()=>Z.initialized);$n(()=>{L(b)&&L(d)!==null&&Xr(()=>ub.setAsideMobile(L(d)))});let x=j(void 0),S=A(()=>Z.data?.chatConfig?.inlineLayout&&!Z.data.props.flyout);$n(()=>{let e=0,t=()=>{e=window.visualViewport?.height??window.innerHeight},n=new ResizeObserver(()=>{let t=window.innerWidth<768?.9:1;L(x)&&L(x).offsetHeight>e*t&&(Z.data.isInlineLayoutContained=!0,requestAnimationFrame(()=>{L(x)?.offsetHeight,window.dispatchEvent(new Event(`resize`))}))}),r=[`mouseup`,`click`],i=!1;Ay()||r.push(`keydown`);let a=()=>{i||(i=!0,L(x)?.scrollIntoView({behavior:`smooth`}),setTimeout(()=>{i=!1},300))};return L(S)&&L(x)&&(t(),window.visualViewport?.addEventListener(`resize`,t),window.addEventListener(`resize`,t),n.observe(L(x)),r.forEach(e=>{L(x).addEventListener(e,a,!0)})),()=>{L(x)&&r.forEach(e=>{L(x).removeEventListener(e,a,!0)}),n.disconnect(),window.visualViewport?.removeEventListener(`resize`,t),window.removeEventListener(`resize`,t)}});let C=A(()=>Z.data.props?.flyout);return $n(()=>{L(b)&&L(C)&&(n().setAttribute(`role`,`region`),Xr(()=>{n().setAttribute(`aria-label`,Z.t.ariaFlyoutRegion)}))}),ha(`3hann0`,e=>{var t=z(),n=P(t),r=e=>{var t=pI(),n=P(t);Xi(n,17,()=>Z.themeBase.fontURLs??[],Ki,(e,t)=>{var n=dI();I(()=>G(n,`href`,L(t))),B(e,n)});var r=F(n,2);Xi(r,17,()=>Z.data.additionalStylesheets,Ki,(e,t)=>{var n=fI();I(()=>G(n,`href`,L(t))),B(e,n)}),yF(F(r,2),{id:`font-css`,get css(){return Z.themeBase.fontCSS}}),B(e,t)};U(n,e=>{Z.initialized&&e(r)}),B(e,t)}),XT(e,{get defaultPortalTo(){return L(s)},children:(e,n)=>{var l=CI();let m;var _=N(l),y=e=>{var t=hI(),n=P(t);{let e=A(()=>vF(Z.theme));yF(n,{id:`theme-css`,get css(){return L(e)}})}var r=F(n,2);yF(r,{id:`app-css`,get css(){return bF}});var i=F(r,2);yF(i,{id:`custom-css`,get css(){return Z.themeBase.customCSS}}),Xi(F(i,2),17,()=>Z.data.additionalStylesheets,Ki,(e,t)=>{var n=mI();I(()=>G(n,`href`,L(t))),B(e,n)}),B(e,t)};U(_,e=>{Z.initialized&&e(y)}),$F(F(_,2),mo({onCloseChat:o,get onError(){return r()}},()=>i,{children:(e,t)=>{var n=SI(),r=N(n),i=N(r);_a(i,(e,t)=>fb?.(e,t),()=>`portals`);var l=F(i,2);mb(l,{});var m=F(l,2),_=N(m),y=N(_),b=e=>{var t=gI(),n=N(t,!0);E(t),I(()=>V(n,Z.t.ariaPageTitle)),B(e,t)};U(y,e=>{!L(C)&&!L(S)&&e(b)});var ee=F(y,2);ma(ee,()=>Z.hasMainNavigationContent?`nav`:`div`,!1,(e,t)=>{_a(e,(e,t)=>fb?.(e,t),()=>`chatAppMainNavigation`),Ja(e,()=>({class:`chat-app__header-content`,"aria-label":Z.hasMainNavigationContent?Z.ariaMainNavigationRegion:void 0,tabindex:Z.hasMainNavigationContent?-1:void 0,id:lI,[Pa]:{"has-border":L(p)}}));var n=bI(),r=P(n),i=e=>{var t=_I(),n=N(t,!0);E(t),I(()=>V(n,Z.t.ariaMainNavigation)),B(e,t)};U(r,e=>{Z.hasMainNavigationContent&&e(i)});var s=F(r,2),c=e=>{var t=vI();na(t,()=>Z.theme.svgs.headerLogo,!0),E(t),B(e,t)};U(s,e=>{Z.theme.svgs.headerLogo&&e(c)});var l=F(s,2),u=e=>{NN(e,{class:`chat-app__header-new-conversation`})};U(l,e=>{L(a)===`chat-page`&&!Z.data.chatConfig.forceChatPage&&e(u)});var d=F(l,2),f=e=>{var t=yI(),n=P(t),r=e=>{{let t=A(()=>Z.t.aboutThisChat||``);fN(e,{get content(){return L(t)}})}};U(n,e=>{Z.data.chatConfig.showContextInfo&&e(r)});var i=F(n,2),a=e=>{AN(e,{})};U(i,e=>{Z.data.chatConfig.showContextMenu&&e(a)});var s=F(i,2),c=e=>{Ij(e,{onclick:o})};U(s,e=>{(Z.data.chatConfig.showCloseChatButton||Z.data.props.flyout)&&e(c)}),B(e,t)};U(d,e=>{Z.initialized&&e(f)}),B(t,n)}),_a(F(ee,2),(e,t)=>fb?.(e,t),()=>`chatAppHeaderPortal`),E(_),E(m),so(m,e=>M(g,e),()=>L(g)),_a(m,(e,t)=>fb?.(e,t),()=>`chatAppHeader`);var te=F(m,2),ne=N(te);nI(ne,{}),Gi(F(ne,2),()=>L(a),e=>{var t=xI(),n=N(t),r=e=>{aN(e,{})},i=e=>{aP(e,{})},o=e=>{$M(e,{})};U(n,e=>{L(a)===`consent-page`?e(r):L(a)===`start-page`?e(i,1):L(a)===`chat-page`&&e(o,2)}),E(t),so(t,e=>M(f,e),()=>L(f)),fa(1,t,()=>wA,()=>({duration:300,delay:250})),fa(2,t,()=>HN,()=>({duration:150})),B(e,t)}),E(te),E(r),so(r,e=>M(s,e),()=>L(s)),_a(r,(e,t)=>fb?.(e,t),()=>`scrollContainer`);var re=F(r,2),w=e=>{Pj(e,{get isOpen(){return L(u)},get isMobile(){return L(d)},get showReferencesByDefault(){return Z.data.chatConfig.showReferencesByDefault},onClose:h,get title(){return Z.t.referencesTitle},children:(e,t)=>{ZN(e,{})},$$slots:{default:!0}})};U(re,e=>{L(d)!==null&&e(w)}),_y(F(re,2),{position:`top-center`,get containerAriaLabel(){return Z.t.ariaNotifications}}),E(n),ir(()=>ao(n,`clientWidth`,e=>M(c,e))),so(n,e=>M(x,e),()=>L(x)),_a(n,(e,t)=>fb?.(e,t),()=>`chatAppContainer`),I(()=>{Da(n,1,xa([`chat-app__container`,{"chat-app__container--inline-layout":L(S),"chat-app__container--inline-layout-contained":Z.data.isInlineLayoutContained}])),Da(m,1,xa([`chat-app__header`,{"chat-app__header--unsticked":L(v),"chat-app__header--with-logo":Z.theme.svgs.headerLogo}]))}),B(e,n)},$$slots:{default:!0}})),E(l),I(()=>{Da(l,1,xa([`chat-app`,t.chatClass])),G(l,`role`,!L(C)&&!L(S)?`main`:void 0),m=ka(l,``,m,{"color-scheme":Z.colorScheme||`light`})}),B(e,l)},$$slots:{default:!0}}),O({get host(){return n()},set host(e){n(e),k()},get onError(){return r()},set onError(e){r(e),k()}})}q(wI,{host:{},onError:{}},[],[],{mode:`open`});var TI=R(`<div class="chat-app__container"><div class="error-message svelte-14mj70v">Server is unreachable, please try later... <button class="error-message__retry-button svelte-14mj70v">Retry</button></div></div>`),EI=R(` <!>`,1),DI={hash:`svelte-14mj70v`,code:`
|
|
583
|
+
}}.embed-alva-score__separator.svelte-16h2wiv {display:block;align-self:flex-end;width:4.8rem;margin-top:-0.3rem;padding-bottom:0.5rem;border-top-width:var(--message-options-border-width);border-color:var(--message-options-border-color);}`};function GA(e,t){D(t,!0),ga(e,WA);let n=j(void 0);tr(()=>{Xr(()=>{M(n,kA.getContext(),!0),kA.currentContext.experimentState===`in-progress`&&kA.updateContext(e=>({...e,nextLevel:MA(),nextShowCount:e.nextShowCount+1}))})});let r={low:`Tief`,medium:`Mittel`,high:`Hoch`};var i=UA(),a=P(i),o=e=>{var t=z(),i=P(t),a=e=>{var t=z(),i=P(t),a=e=>{var t=VA(),i=F(N(t));E(t),I(()=>V(i,` Antwortsicherheit: ${r[L(n).nextLevel]??L(n).nextLevel??``}`)),B(e,t)},o=e=>{var t=HA(),i=F(N(t));E(t),I(()=>V(i,` Antwortunsicherheit: ${r[L(n).nextLevel]??L(n).nextLevel??``}`)),B(e,t)};U(i,e=>{L(n).assignedGroup===`certainty`?e(a):L(n).assignedGroup===`uncertainty`&&e(o,1)}),B(e,t)};U(i,e=>{L(n).nextShowCount<=2&&e(a)}),B(e,t)};U(a,e=>{kA.currentContext.isDesktop&&L(n).experimentState===`in-progress`&&e(o)}),OA(F(a,2),{belowScore:!0}),B(e,i),O()}q(GA,{},[],[],{mode:`open`});function KA(e,t){D(t,!0);let n=K(t,`href`,7),r=K(t,`target`,7),i=K(t,`onclick`,7),a=K(t,`className`,23,()=>[]),o=K(t,`isStandalone`,7,!1),s=K(t,`children`,7),c=K(t,`type`,7,`button`),l=K(t,`use`,7),u=K(t,`class`,7),d=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`href`,`target`,`onclick`,`className`,`isStandalone`,`children`,`type`,`use`,`class`]),f=A(()=>n()?`a`:`button`),p=A(()=>[...Array.isArray(a())?a():a()?[a()]:[],...u()?[u()]:[]]),m=()=>({}),h=A(()=>l()??m);var g={get href(){return n()},set href(e){n(e),k()},get target(){return r()},set target(e){r(e),k()},get onclick(){return i()},set onclick(e){i(e),k()},get className(){return a()},set className(e=[]){a(e),k()},get isStandalone(){return o()},set isStandalone(e=!1){o(e),k()},get children(){return s()},set children(e){s(e),k()},get type(){return c()},set type(e=`button`){c(e),k()},get use(){return l()},set use(e){l(e),k()},get class(){return u()},set class(e){u(e),k()}},_=z();return ma(P(_),()=>L(f),!1,(e,t)=>{_a(e,e=>L(h)?.(e)),Ja(e,()=>({...d,onclick:n()?void 0:i(),type:n()?void 0:c(),href:n(),role:n()?`link`:`button`,target:n()?r():void 0,class:L(p),[Pa]:{"open-button--standalone":o()}}));var a=z();H(P(a),s),B(t,a)}),B(e,_),O(g)}q(KA,{href:{},target:{},onclick:{},className:{},isStandalone:{},children:{},type:{},use:{},class:{}},[],[],{mode:`open`});function qA(e,t){D(t,!0);let n=K(t,`html`,7),r=K(t,`oncomplete`,7),i=j(``),a=null;Ii(()=>{if(!n()){M(i,``),r()?.();return}let e=y_(n());if(e.length<=1){M(i,n(),!0),r()?.();return}let t=0,o=()=>{if(a=null,t>=e.length)return;M(i,L(i)+e[t]);let n=b_(e[t]);t++,t<e.length?a=setTimeout(o,n):r()?.()};return o(),()=>{a!==null&&(clearTimeout(a),a=null)}});var o={get html(){return n()},set html(e){n(e),k()},get oncomplete(){return r()},set oncomplete(e){r(e),k()}},s=z();return na(P(s),()=>L(i)),B(e,s),O(o)}q(qA,{html:{},oncomplete:{}},[],[],{mode:`open`});var JA=R(`<p class="embed-buttons__caption"><!></p>`),YA=R(`<span class="btn__label"></span> <!>`,1),XA=R(`<div class="embed-buttons"><!> <div class="embed-buttons__buttons"></div></div>`);function ZA(e,t){D(t,!0);let n=K(t,`data`,7);var r={get data(){return n()},set data(e){n(e),k()}},i=XA(),a=N(i),o=e=>{var t=JA();qA(N(t),{get html(){return n().caption}}),E(t),B(e,t)};U(a,e=>{n().caption&&e(o)});var s=F(a,2);return Xi(s,21,()=>n().buttons,Ki,(e,t)=>{{let n=A(()=>[`btn`,`btn--${L(t).variant??`primary`}`]);KA(e,{get href(){return L(t).href},get target(){return L(t).target},get className(){return L(n)},children:(e,n)=>{var r=YA(),i=P(r);na(i,()=>L(t).label,!0),E(i);var a=F(i,2),o=e=>{_b(e,{get name(){return L(t).icon}})};U(a,e=>{L(t).icon&&e(o)}),B(e,r)},$$slots:{default:!0}})}}),E(s),E(i),B(e,i),O(r)}q(ZA,{data:{}},[],[],{mode:`open`});var QA=R(`<p class="embed-combobox__caption"><!></p>`),$A=R(`<p class="embed-combobox__no-result"> </p>`),ej=R(`<div><div><!> <!> <!></div></div>`),tj=R(`<span class="btn btn--tertiary btn--square"><!> <span class="sr-only"> </span></span>`),nj=R(`<!> <!> <!>`,1),rj=R(`<div role="region"><h2 class="sr-only"> </h2> <div class="embed-combobox__combobox"><!></div></div>`),ij=R(`<div class="embed-combobox"><!> <!></div>`);function aj(e,t){D(t,!0);let n=K(t,`data`,7),r=K(t,`hideChatInput`,7),i=A(()=>Z.t),a=j(``),o=j(!1),s=j(!1),c=j(null),l=j(null),u=j(null),d=j(!1),f=PT(),p=j(10);$n(()=>{if(!L(l))return;let e=getComputedStyle(L(l)).getPropertyValue(`--embed-combobox-side-offset`).trim(),t=parseFloat(e);Number.isNaN(t)||M(p,t,!0)});let m=e=>e===0?150:180,h=e=>G_(e,Z.data.language,Z.data.chatConfig.supportedLanguages),g=A(()=>n().caption?h(n().caption):``),_=A(()=>h(n().placeholder)),v=A(()=>n().values.map(e=>({value:e.value,label:h(e.label),metadata:e.metadata}))),y=A(()=>L(a)===``?L(v):L(v).filter(e=>e.label.toLowerCase().includes(L(a).toLowerCase()))),b=e=>{let t=L(v).find(t=>t.value===e);t&&(Z.data.chatInputValue=t.label,db.onSubmit(!1,{[n().selectorKey??`componentValue`]:t.value,...t.metadata?{scopeMetadata:t.metadata}:{}}),n().removeComponentAfterValueSelection&&M(s,!0))},x=()=>{M(d,!0),r()&&!Ay()?setTimeout(()=>{L(c)?.focus()},300):L(g)&&db.setAriaLiveStatusMessage(L(u)?.textContent??``)};var S={get data(){return n()},set data(e){n(e),k()},get hideChatInput(){return r()},set hideChatInput(e){r(e),k()}},C=ij(),ee=N(C),te=e=>{var t=QA();qA(N(t),{get html(){return L(g)},oncomplete:x}),E(t),so(t,e=>M(u,e),()=>L(u)),I(()=>G(t,`id`,f)),B(e,t)};U(ee,e=>{L(g)&&e(te)});var ne=F(ee,2),re=e=>{var t=rj(),n=N(t),r=N(n,!0);E(n);var l=F(n,2);W(N(l),()=>XO,(e,t)=>{t(e,{type:`single`,onOpenChange:e=>{e||M(a,``)},onValueChange:b,get open(){return L(o)},set open(e){M(o,e,!0)},children:(e,t)=>{var n=nj(),r=P(n);{let e=A(()=>L(g)?f:void 0);W(r,()=>tk,(t,n)=>{n(t,{get placeholder(){return L(_)},get"aria-describedby"(){return L(e)},onclick:()=>M(o,!0),oninput:e=>M(a,e.currentTarget.value,!0),get ref(){return L(c)},set ref(e){M(c,e,!0)}})})}var s=F(r,2);W(s,()=>kC,(e,t)=>{t(e,{get to(){return Z.targets.portals},children:(e,t)=>{var n=z(),r=P(n);{let e=(e,t)=>{let n=()=>t?.().wrapperProps,r=()=>t?.().props,a=()=>t?.().open;var o=z(),s=P(o),c=e=>{var t=ej();Ja(t,()=>({...n()}));var a=N(t);Ja(a,()=>({...r()}));var o=N(a);W(o,()=>wk,(e,t)=>{t(e,{delay:m,children:(e,t)=>{_b(e,{name:`chevronUp`})},$$slots:{default:!0}})});var s=F(o,2);W(s,()=>vk,(e,t)=>{t(e,{children:(e,t)=>{var n=z();Xi(P(n),19,()=>L(y),(e,t)=>t+e.value,(e,t)=>{var n=z();W(P(n),()=>hk,(e,n)=>{n(e,{get value(){return L(t).value},get label(){return L(t).label},children:(e,n)=>{Ze();var r=hi();I(()=>V(r,L(t).label)),B(e,r)},$$slots:{default:!0}})}),B(e,n)},e=>{var t=$A(),n=N(t,!0);E(t),I(()=>V(n,L(i).noResultsFound)),B(e,t)}),B(e,n)},$$slots:{default:!0}})}),W(F(s,2),()=>xk,(e,t)=>{t(e,{delay:m,children:(e,t)=>{_b(e,{name:`chevronDown`})},$$slots:{default:!0}})}),E(a),E(t),fa(1,a,()=>EA,()=>({duration:300,easing:bA,y:40})),fa(2,a,()=>EA,()=>({duration:150,easing:yA,y:20})),B(e,t)};U(s,e=>{a()&&e(c)}),B(e,o)};W(r,()=>dk,(t,n)=>{n(t,{get sideOffset(){return L(p)},forceMount:!0,strategy:`absolute`,side:`bottom`,avoidCollisions:!1,child:e,$$slots:{child:!0}})})}B(e,n)},$$slots:{default:!0}})}),W(F(s,2),()=>rk,(e,t)=>{t(e,{children:(e,t)=>{var n=tj(),r=N(n);_b(r,{name:`chevronTopDown`});var a=F(r,2),o=N(a,!0);E(a),E(n),I(()=>V(o,L(i).openMenu)),B(e,n)},$$slots:{default:!0}})}),B(e,n)},$$slots:{default:!0}})}),E(l),E(t),I(()=>{Da(t,1,xa([`embed-combobox__container`,{"embed-combobox__container--hidden":L(s)}])),t.inert=L(s)?!0:void 0,G(t,`aria-hidden`,L(s)?`true`:void 0),G(t,`aria-label`,L(_)),V(r,L(_))}),fa(1,t,()=>EA,()=>({duration:400,easing:bA,y:30,delay:100})),B(e,t)};return U(ne,e=>{Z.targets.portals&&(!L(g)||L(d))&&e(re)}),E(C),so(C,e=>M(l,e),()=>L(l)),B(e,C),O(S)}q(aj,{data:{},hideChatInput:{}},[],[],{mode:`open`});var oj={buttons:ZA,combobox:aj,"alva-init":BA,"alva-score-survey":GA},sj=e=>{let t=oj[e];if(!t){console.error(`No embed component found with name "${e}"`);return}return t};function cj(e,t){D(t,!0);let n=K(t,`componentName`,7),r=K(t,`data`,7),i=K(t,`hideChatInput`,7),a=A(()=>sj(n())),o=j(!1);Ii(()=>{requestAnimationFrame(()=>M(o,!0))});var s={get componentName(){return n()},set componentName(e){n(e),k()},get data(){return r()},set data(e){r(e),k()},get hideChatInput(){return i()},set hideChatInput(e){i(e),k()}},c=z(),l=P(c),u=e=>{var t=z();W(P(t),()=>L(a),(e,t)=>{t(e,{get data(){return r()},get hideChatInput(){return i()}})}),B(e,t)};return U(l,e=>{L(a)&&L(o)&&e(u)}),B(e,c),O(s)}q(cj,{componentName:{},data:{},hideChatInput:{}},[],[],{mode:`open`});var lj=R(`<div aria-hidden="true"><!></div>`);function uj(e,t){D(t,!0);let n=K(t,`class`,7),r=K(t,`isLarge`,7),i=K(t,`hide`,7,!1);var a={get class(){return n()},set class(e){n(e),k()},get isLarge(){return r()},set isLarge(e){r(e),k()},get hide(){return i()},set hide(e=!1){i(e),k()}},o=lj();let s;var c=N(o),l=e=>{var t=z();na(P(t),()=>Z.theme.svgs.avatarLarge||Z.theme.svgs.avatar),B(e,t)},u=e=>{var t=z();na(P(t),()=>Z.theme.svgs.avatar),B(e,t)};return U(c,e=>{r()?e(l):e(u,-1)}),E(o),_a(o,(e,t)=>fb?.(e,t),()=>r()?`avatarLarge`:`avatar`),I(()=>s=Da(o,1,`svg svg--avatar ${n()??``}`,null,s,{"svg--avatar--hide":i()})),B(e,o),O(a)}q(uj,{class:{},isLarge:{},hide:{}},[],[],{mode:`open`});var dj=`data-references-toggle-button`,fj=R(` <!>`,1),pj=R(`<span class="btn__label"> </span>`),mj=R(`<button><!> <!></button>`),hj=R(`<span class="btn__label"> </span>`),gj=R(`<button class="btn btn--tertiary btn--square" aria-haspopup="dialog"><!> <!></button>`),_j=R(`<div class="message__bot-references"><!> <!></div>`),vj=R(`<div class="message__bot-actions"><!> <!> <!> <!></div>`),yj=R(`<!> <!>`,1),bj=R(`<div class="message__bot-layout"><!> <div class="message__bot-body"><div class="text-container"><!> <!></div> <!> <!></div></div>`),xj=R(`<div class="message__bot-layout"><!> <div class="message__bot-body"><!></div></div>`),Sj=R(`<section><div class="message__content"><!></div></section>`);function Cj(e,t){D(t,!0);let n=A(()=>Z.t),r=K(t,`message`,7),i=K(t,`index`,7),a=K(t,`onmessageupdate`,7),o=K(t,`onbotmessageinit`,7),s=K(t,`onaskQuestion`,7),c=K(t,`isLast`,7,!1),l={duration:Number(Z.theme.components.message.custom?.transitionDuration)||300,delay:Number(Z.theme.components.message.custom?.transitionDelay)||0,y:Number(Z.theme.components.message.custom?.transitionY)||30,ease:bA};Xr(()=>r().type===`bot`||r().type===`component`)&&(l.delay+=Number(Z.theme.components.message.custom?.transitionBotLoadingDelay)||300);let u={duration:Number(Z.theme.components.messageOptions.custom?.transitionDuration)||300,delay:Number(Z.theme.components.messageOptions.custom?.transitionDelay)||0,y:Number(Z.theme.components.messageOptions.custom?.transitionY)||30,ease:bA},d=A(()=>r().type===`bot`?r().references.all.filter(Vb).length:0),f=A(()=>({...u,delay:u.delay+L(d)*u.duration}));$n(()=>{r()?.type===`bot`&&r().state!==`done`&&a()()}),Xr(()=>{r()?.type===`bot`&&o()()});let p=A(()=>Z.data.history.slice(0,i()+1).filter(e=>e.type===`bot`||e.type===`component`).length),m=A(()=>r().type===`bot`||r().type===`component`?L(n).ariaAnswerFromBot.replace(`{n}`,String(L(p))):`${L(n).ariaQuestionFromYou} ${(r().message?.length??0)>20?r().message.slice(0,20)+`...`:r().message}`),h=A(()=>Z.data.currentReferencesAsideId===r().id?L(n).referencesHide:L(n).referencesDisplay),g=A(()=>Z.data.chatConfig.answerForm),_=A(()=>L(g)?G_(L(g).triggerLabel,Z.data.language,Z.data.chatConfig.supportedLanguages):``),v=A(()=>r().type===`bot`&&(!!r().references?.used.length||!r().noFeedback||!!L(g)));var y={get message(){return r()},set message(e){r(e),k()},get index(){return i()},set index(e){i(e),k()},get onmessageupdate(){return a()},set onmessageupdate(e){a(e),k()},get onbotmessageinit(){return o()},set onbotmessageinit(e){o(e),k()},get onaskQuestion(){return s()},set onaskQuestion(e){s(e),k()},get isLast(){return c()},set isLast(e=!1){c(e),k()}},b=Sj();let x;var S=N(b),C=N(S),ee=e=>{var t=bj(),i=N(t);uj(i,{class:`message__bot-avatar`});var a=F(i,2),o=N(a),l=N(o);na(l,()=>r().message.html);var u=F(l,2),d=e=>{var t=fj(),r=P(t);_b(F(r),{name:`messageLoading`,class:`message__bot-loading`}),I(()=>V(r,`${L(n).messageBotLoading??``} `)),B(e,t)};U(u,e=>{r().state===`loading`&&e(d)}),E(o);var p=F(o,2),m=e=>{{let t=A(()=>r().state===`done`);Wb(e,{get references(){return r().references.all},get ready(){return L(t)}})}};U(p,e=>{r().references&&r().references.all.length>0&&e(m)});var y=F(p,2),b=e=>{var t=z();ma(P(t),()=>c()?`nav`:`div`,!1,(e,t)=>{Ja(e,()=>({"aria-label":c()?Z.t.ariaLastAnswerNavigation:void 0,class:`message__bot-options`})),fa(3,e,()=>EA,()=>L(f));var i=yj(),a=P(i),o=e=>{var t=_j(),i=N(t),a=e=>{var t=mj(),n=()=>db.toggleReferencesAside(r().id);Ja(t,()=>({class:`btn btn--tertiary btn--square`,onclick:n,"aria-expanded":Z.data.currentReferencesAsideId===r().id,"aria-controls":Dj,[dj]:!0}));var i=N(t);_b(i,{name:`listUnordered`});var a=F(i,2),o=e=>{var t=pj(),n=N(t,!0);E(t),I(()=>V(n,L(h))),B(e,t)};U(a,e=>{L(h)&&e(o)}),E(t),B(e,t)};U(i,e=>{r().references&&r().references.used.length&&e(a)});var o=F(i,2),s=e=>{var t=gj(),i=N(t);_b(i,{name:`forward`});var a=F(i,2),o=e=>{var t=hj(),n=N(t,!0);E(t),I(()=>V(n,L(_))),B(e,t)};U(a,e=>{L(_)&&e(o)}),E(t),I(()=>{G(t,`aria-expanded`,Z.data.answerFormMessageId===r().id),G(t,`aria-label`,L(n).ariaAnswerForm)}),ai(`click`,t,()=>db.openAnswerForm(r().id)),B(e,t)};U(o,e=>{L(g)&&e(s)}),E(t),B(e,t)};U(a,e=>{(r().references&&r().references.used.length||L(g))&&e(o)});var l=F(a,2),u=e=>{var t=vj(),i=N(t),a=e=>{xb(e,{icon:`retry`,get label(){return L(n).ariaAskQuestionAgain},get tooltip(){return L(n).askQuestionAgain},get onclick(){return s()},class:`message__bot-action btn btn--tertiary btn--square`})};U(i,e=>{Z.data.chatConfig.askQuestionAgain&&e(a)});var o=F(i,2);xb(o,{icon:`voteUp`,get label(){return L(n).ariaAnswerGood},get tooltip(){return L(n).answerGood},onclick:()=>db.thumbs(r().id,`up`),class:`message__bot-action btn btn--tertiary btn--square`});var c=F(o,2);xb(c,{icon:`voteDown`,get label(){return L(n).ariaAnswerBad},get tooltip(){return L(n).answerBad},onclick:()=>db.thumbs(r().id,`down`),class:`message__bot-action btn btn--tertiary btn--square`});var l=F(c,2),u=e=>{xb(e,{icon:`message`,get label(){return L(n).ariaGiveFeedback},"aria-haspopup":`dialog`,get"aria-expanded"(){return Z.data.conversationFeedbackIsOpen},get tooltip(){return L(n).giveFeedback},onclick:()=>db.openMessageFeedback(r().id),class:`message__bot-action btn btn--tertiary btn--square`})};U(l,e=>{(Z.data.chatConfig.showTextFeedback||Z.data.chatConfig.classification)&&e(u)}),E(t),B(e,t)};U(l,e=>{r().noFeedback||e(u)}),B(t,i)}),B(e,t)};U(y,e=>{r().state===`done`&&L(v)&&e(b)}),E(a),E(t),B(e,t)},te=e=>{var t=xj(),n=N(t);uj(n,{class:`message__bot-avatar`,get hide(){return r().hideAvatar}});var i=F(n,2);cj(N(i),{get componentName(){return r().componentName},get data(){return r().data},get hideChatInput(){return r().hideChatInput}}),E(i),E(t),B(e,t)},ne=e=>{var t=hi();I(()=>V(t,r().message)),B(e,t)};return U(C,e=>{r().type===`bot`?e(ee):r().type===`component`?e(te,1):r().type===`user`&&e(ne,2)}),E(S),E(b),_a(b,(e,t)=>pb?.(e,t),()=>r().type===`user`?`chatPageLastUserMessage`:void 0),I(()=>{x=Da(b,1,`message container`,null,x,{"message--bot":r().type===`bot`||r().type===`component`,"message--user":r().type===`user`,"message--no-padding":r().type===`component`&&r().noSectionPadding}),G(b,`aria-label`,L(m))}),fa(3,b,()=>EA,()=>l),B(e,b),O(y)}oi([`click`]),q(Cj,{message:{},index:{},onmessageupdate:{},onbotmessageinit:{},onaskQuestion:{},isLast:{}},[],[],{mode:`open`});var wj=e=>Array.from(e.querySelectorAll(`a[href], button, input:not([type="hidden"]), textarea, select, details,[tabindex]:not([tabindex="-1"])`)).filter(e=>!e.hasAttribute(`disabled`)&&!e.getAttribute(`aria-hidden`)),Tj=e=>{let t=e.getRootNode();return`activeElement`in t?t.activeElement:document.activeElement};function Ej(e,t){let{firstFocusableOnMount:n=!0,resetFocusOnDestroy:r=!0,avoidFocusLoop:i=!1}=t||{},a=Tj(e),o=wj(e),s,c=new MutationObserver(()=>{o=wj(e)}),l=t=>{o&&e.dataset.disabled!==`true`&&t.key===`Tab`&&(t.shiftKey?Tj(e)===o[0]&&(t.preventDefault(),o[o.length-1].focus()):Tj(e)===o[o.length-1]&&(t.preventDefault(),o[0].focus()))};return o&&o.length>0&&!i&&(n&&(s=o[0],requestAnimationFrame(()=>{s?.focus({preventScroll:!0})})),e.addEventListener(`keydown`,l),c.observe(e,{childList:!0,subtree:!0,attributes:!0,attributeFilter:[`disabled`,`aria-hidden`,`tabindex`]})),{destroy(){o&&o.length>0&&!i&&(o=null,s=null,e.removeEventListener(`keydown`,l),c.disconnect(),r&&a&&requestAnimationFrame(()=>{a.focus({preventScroll:!0})}))}}}var Dj=`aside`,Oj=R(`<div></div>`),kj=R(`<h2 class="chat-app__sheet-title"> </h2>`),Aj=R(`<span class="btn btn--tertiary btn--square"><span class="sr-only"> </span> <!></span>`),jj=R(`<div><div class="chat-app__sheet-header"><!> <!></div> <!></div>`),Mj=R(`<!> <!>`,1),Nj=R(`<h2 class="chat-app__aside-title"> </h2>`),Pj=R(`<div><div class="chat-app__aside-container"><div class="chat-app__aside-header"><!> <div class="chat-app__aside-close"><button class="btn btn--tertiary btn--square"><span class="sr-only"> </span> <!></button></div></div> <!></div></div>`);function Fj(e,t){D(t,!0);let n=K(t,`title`,7),r=K(t,`isOpen`,7),i=K(t,`isMobile`,7),a=K(t,`showReferencesByDefault`,7),o=K(t,`onClose`,7),s=K(t,`children`,7),c=j(void 0),l=null,u=e=>{e.key===`Escape`&&o()()};$n(()=>{if(!i())if(r()){if(a()||document.addEventListener(`keydown`,u),L(c)&&(l=Tj(L(c)),!a()||l?.hasAttribute(`data-references-toggle-button`))){let e=wj(L(c));e[0].setAttribute(vb,`true`),e[0].focus({preventScroll:!0})}}else document.removeEventListener(`keydown`,u),l?.hasAttribute(`data-references-toggle-button`)?l.focus({preventScroll:!0}):Z.targets.chatInput?.focus({preventScroll:!0})});var d={get title(){return n()},set title(e){n(e),k()},get isOpen(){return r()},set isOpen(e){r(e),k()},get isMobile(){return i()},set isMobile(e){i(e),k()},get showReferencesByDefault(){return a()},set showReferencesByDefault(e){a(e),k()},get onClose(){return o()},set onClose(e){o(e),k()},get children(){return s()},set children(e){s(e),k()}},f=z(),p=P(f),m=e=>{var t=z(),i=P(t),a=e=>{var t=z();W(P(t),()=>tA,(e,t)=>{t(e,{onOpenChange:e=>{e||o()()},get open(){return r()},set open(e){r(e)},children:(e,t)=>{var r=z();W(P(r),()=>kC,(e,t)=>{t(e,{get to(){return Z.targets.portals},children:(e,t)=>{var r=Mj(),i=P(r);{let e=(e,t)=>{let n=()=>t?.().props,r=()=>t?.().open;var i=z(),a=P(i),o=e=>{var t=Oj();Ja(t,()=>({class:`chat-app__sheet-overlay`,...n()})),fa(1,t,()=>TA,()=>({duration:200})),fa(2,t,()=>TA,()=>({duration:200,delay:150})),B(e,t)};U(a,e=>{r()&&e(o)}),B(e,i)};W(i,()=>JT,(t,n)=>{n(t,{forceMount:!0,child:e,$$slots:{child:!0}})})}var a=F(i,2);{let e=(e,t)=>{let r=()=>t?.().props,i=()=>t?.().open;var a=z(),o=P(a),c=e=>{var t=jj();Ja(t,()=>({...r()}));var i=N(t),a=N(i),o=e=>{var t=z();W(P(t),()=>bC,(e,t)=>{t(e,{children:(e,t)=>{var r=kj(),i=N(r,!0);E(r),I(()=>V(i,n())),B(e,r)},$$slots:{default:!0}})}),B(e,t)};U(a,e=>{n()&&e(o)}),W(F(a,2),()=>rA,(e,t)=>{t(e,{class:`chat-app__sheet-close`,children:(e,t)=>{var n=Aj(),r=N(n),i=N(r,!0);E(r),_b(F(r,2),{name:`dismiss`}),E(n),I(()=>V(i,Z.t.close)),B(e,n)},$$slots:{default:!0}})}),E(i),H(F(i,2),()=>s()??w),E(t),_a(t,e=>Ej?.(e)),fa(1,t,()=>EA,()=>({x:`100%`,opacity:1,duration:650,easing:bA})),fa(2,t,()=>EA,()=>({x:`100%`,opacity:1,duration:500,easing:vA})),B(e,t)};U(o,e=>{i()&&e(c)}),B(e,a)},t=A(()=>!Z.data.chatConfig.inlineLayout&&!Z.data.props.flyout);W(a,()=>oA,(n,r)=>{r(n,{class:`chat-app__sheet-content`,trapFocus:!1,forceMount:!0,get preventScroll(){return L(t)},child:e,$$slots:{child:!0}})})}B(e,r)},$$slots:{default:!0}})}),B(e,r)},$$slots:{default:!0}})}),B(e,t)};U(i,e=>{Z.targets.portals&&e(a)}),B(e,t)},h=e=>{var t=Pj();let i;G(t,`id`,Dj);var l=N(t),u=N(l),d=N(u),f=e=>{var t=Nj(),r=N(t,!0);E(t),I(()=>V(r,n())),B(e,t)};U(d,e=>{n()&&e(f)});var p=F(d,2),m=N(p),h=N(m),g=N(h,!0);E(h),_b(F(h,2),{name:`dismiss`}),E(m),_a(m,(e,t)=>yb?.(e,t),()=>({text:Z.t.close,position:`bottom-right`,delay:0})),E(p),E(u),H(F(u,2),()=>s()??w),E(l),E(t),_a(t,(e,t)=>Ej?.(e,t),()=>({firstFocusableOnMount:!1,resetFocusOnDestroy:!1,avoidFocusLoop:a()})),so(t,e=>M(c,e),()=>L(c)),I(()=>{i=Da(t,1,`chat-app__aside`,null,i,{open:r()}),G(t,`role`,a()?`complementary`:`dialog`),G(t,`aria-modal`,a()?`false`:`true`),G(t,`aria-label`,Z.t.ariaReferencesRegion),G(t,`aria-hidden`,!r()),V(g,Z.t.close)}),ai(`click`,m,function(...e){o()?.apply(this,e)}),B(e,t)};return U(p,e=>{i()?e(m):e(h,-1)}),B(e,f),O(d)}oi([`click`]),q(Fj,{title:{},isOpen:{},isMobile:{},showReferencesByDefault:{},onClose:{},children:{}},[],[],{mode:`open`});var Ij=R(`<div class="chat-app__close-button"><button class="btn btn--tertiary btn--square"><span class="sr-only"> </span> <!></button></div>`);function Lj(e,t){D(t,!0);let n=A(()=>Z.t),r=K(t,`onclick`,7);var i={get onclick(){return r()},set onclick(e){r(e),k()}},a=Ij(),o=N(a),s=N(o),c=N(s,!0);return E(s),_b(F(s,2),{name:`dismiss`}),E(o),_a(o,(e,t)=>yb?.(e,t),()=>({text:L(n).closeChat,position:`bottom-right`,delay:600})),E(a),I(()=>{G(o,`aria-label`,L(n).closeChat),V(c,L(n).closeChat)}),ai(`click`,o,function(...e){r()?.apply(this,e)}),B(e,a),O(i)}oi([`click`]),q(Lj,{onclick:{}},[],[],{mode:`open`});var Rj=R(`<div></div>`),zj=R(`<div><!></div>`),Bj=R(`<span class="sr-only"> </span> <!>`,1),Vj=R(`<div class="dialog-footer"><!></div>`),Hj=R(`<div><div class="dialog-header"><!> <!></div> <!> <!></div>`),Uj=R(`<!> <!>`,1);function Wj(e,t){D(t,!0);let n=K(t,`open`,7),r=K(t,`content`,7),i=K(t,`title`,7),a=K(t,`footer`,7),o=K(t,`onClose`,7),s=j(void 0),c=j(void 0),l={duration:Number(Z.theme.components.dialog.custom?.transitionDuration)||200,delay:Number(Z.theme.components.dialog.custom?.transitionDelay)||0,y:Number(Z.theme.components.dialog.custom?.transitionY)||10},u=e=>{e||o()()};$n(()=>{if(n()&&L(s)&&L(c)&&L(c).textContent){let e=rl(L(c).textContent.trim());L(s).setAttribute(`aria-label`,e),L(s).removeAttribute(`aria-labelledby`),wj(L(s))[0].focus({preventScroll:!0})}});var d={get open(){return n()},set open(e){n(e),k()},get content(){return r()},set content(e){r(e),k()},get title(){return i()},set title(e){i(e),k()},get footer(){return a()},set footer(e){a(e),k()},get onClose(){return o()},set onClose(e){o(e),k()}},f=z(),p=P(f),m=e=>{var t=z();W(P(t),()=>tA,(e,t)=>{t(e,{get open(){return n()},onOpenChange:u,children:(e,t)=>{var n=z();W(P(n),()=>kC,(e,t)=>{t(e,{get to(){return Z.targets.portals},children:(e,t)=>{var n=Uj(),o=P(n);{let e=(e,t)=>{let n=()=>t?.().props,r=()=>t?.().open;var i=z(),a=P(i),o=e=>{var t=Rj();Ja(t,()=>({...n(),class:`dialog-overlay`})),fa(3,t,()=>TA,()=>l),B(e,t)};U(a,e=>{r()&&e(o)}),B(e,i)};W(o,()=>JT,(t,n)=>{n(t,{forceMount:!0,child:e,$$slots:{child:!0}})})}var u=F(o,2);{let e=(e,t)=>{let n=()=>t?.().props,o=()=>t?.().open;var u=z(),d=P(u),f=e=>{var t=Hj();Ja(t,()=>({...n(),class:`dialog-content`}));var o=N(t),u=N(o);W(u,()=>bC,(e,t)=>{t(e,{class:`dialog-title h4`,children:(e,t)=>{var n=zj();H(N(n),()=>i()??w),E(n),so(n,e=>M(c,e),()=>L(c)),B(e,n)},$$slots:{default:!0}})}),W(F(u,2),()=>rA,(e,t)=>{t(e,{class:`dialog-close`,children:(e,t)=>{var n=Bj(),r=P(n),i=N(r,!0);E(r),_b(F(r,2),{name:`dismiss`}),I(()=>V(i,Z.t.close)),B(e,n)},$$slots:{default:!0}})}),E(o);var d=F(o,2);W(d,()=>XT,(e,t)=>{t(e,{class:`dialog-description text-container`,children:(e,t)=>{var n=z();H(P(n),r),B(e,n)},$$slots:{default:!0}})});var f=F(d,2),p=e=>{var t=Vj();H(N(t),a),E(t),B(e,t)};U(f,e=>{a()&&e(p)}),E(t),_a(t,(e,t)=>Ej?.(e,t),()=>({firstFocusableOnMount:!1})),so(t,e=>M(s,e),()=>L(s)),fa(3,t,()=>EA,()=>l),B(e,t)};U(d,e=>{o()&&e(f)}),B(e,u)},t=A(()=>!Z.data.chatConfig.inlineLayout&&!Z.data.props.flyout);W(u,()=>oA,(n,r)=>{r(n,{trapFocus:!1,forceMount:!0,get preventScroll(){return L(t)},child:e,$$slots:{child:!0}})})}B(e,n)},$$slots:{default:!0}})}),B(e,n)},$$slots:{default:!0}})}),B(e,t)};return U(p,e=>{Z.targets.portals&&e(m)}),B(e,f),O(d)}q(Wj,{open:{},content:{},title:{},footer:{},onClose:{}},[],[],{mode:`open`});var Gj=R(`<div><!></div>`);function Kj(e,t){D(t,!0);let n=K(t,`checked`,7,!1),r=K(t,`class`,7,``);var i={get checked(){return n()},set checked(e=!1){n(e),k()},get class(){return r()},set class(e=``){r(e),k()}},a=Gj();return _b(N(a),{name:`checkbox`,class:`checkbox__icon`}),E(a),I(()=>{Da(a,1,`checkbox ${r()??``}`),G(a,`data-checked`,n())}),B(e,a),O(i)}q(Kj,{checked:{},class:{}},[],[],{mode:`open`});var qj=R(`<div><div class="radio__indicator"></div></div>`);function Jj(e,t){D(t,!0);let n=K(t,`checked`,7,!1),r=K(t,`class`,7,``);var i={get checked(){return n()},set checked(e=!1){n(e),k()},get class(){return r()},set class(e=``){r(e),k()}},a=qj();return I(()=>{Da(a,1,`radio ${r()??``}`),G(a,`data-checked`,n())}),B(e,a),O(i)}q(Jj,{checked:{},class:{}},[],[],{mode:`open`});var Yj=R(`<p class="form__caption"></p>`),Xj=R(`<input class="form__option-input" type="radio"/> <!>`,1),Zj=R(`<input class="form__option-input" type="checkbox"/> <!>`,1),Qj=R(`<label class="form__option"><!> <span> </span></label>`),$j=R(`<fieldset class="form__fieldset"><legend class="form__label"> </legend> <div class="form__options"></div></fieldset>`),eM=R(`<textarea class="input"></textarea>`),tM=R(`<option disabled=""> </option>`),nM=R(`<option> </option>`),rM=R(`<div class="form__select"><select class="input"><!><!></select> <!></div>`),iM=R(`<input class="input"/>`),aM=R(`<div class="form__item"><label class="form__label"> </label> <!></div>`),oM=R(`<form class="form"><!> <!> <div class="form__fields"></div> <div class="form__footer"><button type="submit" class="btn btn--primary"> </button></div></form>`);function sM(e,t){D(t,!0);let n=K(t,`open`,7),r=K(t,`onClose`,7),i=K(t,`dialogTitle`,7),a=K(t,`caption`,7),o=K(t,`fields`,7),s=K(t,`submitLabel`,7),c=K(t,`submitEnabled`,7),l=K(t,`onSubmit`,7),u=K(t,`values`,15),d=K(t,`header`,7),f=`form-dialog-${e_()}`,p=e=>`${f}-${e}`,m=e=>(u()[e]??``).split(`,`).map(e=>e.trim()).filter(Boolean),h=(e,t)=>m(e).includes(t),g=(e,t,n)=>{let r=m(e);u(u()[e]=(n?[...r,t]:r.filter(e=>e!==t)).join(`, `),!0)};return Wj(e,{get open(){return n()},get onClose(){return r()},title:e=>{var t=z();na(P(t),i),B(e,t)},content:e=>{var t=oM(),n=N(t);H(n,()=>d()??w);var r=F(n,2),i=e=>{var t=Yj();na(t,a,!0),E(t),B(e,t)};U(r,e=>{a()&&e(i)});var f=F(r,2);Xi(f,21,o,e=>e.name,(e,t)=>{var n=z(),r=P(n),i=e=>{var n=$j(),r=N(n),i=N(r,!0);E(r);var a=F(r,2);Xi(a,21,()=>L(t).options??[],e=>e.value,(e,n)=>{var r=Qj(),i=N(r),a=e=>{var r=Xj(),i=P(r);Ua(i);var a=F(i,2);{let e=A(()=>u()[L(t).name]===L(n).value);Jj(a,{get checked(){return L(e)}})}I(e=>{G(i,`name`,e),Wa(i,L(n).value),Ga(i,u()[L(t).name]===L(n).value)},[()=>p(L(t).name)]),ai(`change`,i,()=>u(u()[L(t).name]=L(n).value,!0)),B(e,r)},o=e=>{var r=Zj(),i=P(r);Ua(i);var a=F(i,2);{let e=A(()=>h(L(t).name,L(n).value));Kj(a,{get checked(){return L(e)}})}I(e=>{Wa(i,L(n).value),Ga(i,e)},[()=>h(L(t).name,L(n).value)]),ai(`change`,i,e=>g(L(t).name,L(n).value,e.currentTarget.checked)),B(e,r)};U(i,e=>{L(t).type===`radio`?e(a):e(o,-1)});var s=F(i,2),c=N(s,!0);E(s),E(r),I(()=>V(c,L(n).label)),B(e,r)}),E(a),E(n),I(()=>V(i,L(t).label)),B(e,n)},a=e=>{var n=aM(),r=N(n),i=N(r,!0);E(r);var a=F(r,2),o=e=>{var n=eM();Un(n),I(e=>{G(n,`id`,e),G(n,`placeholder`,L(t).placeholder),n.required=L(t).required},[()=>p(L(t).name)]),Qa(n,()=>u()[L(t).name],e=>u(u()[L(t).name]=e,!0)),B(e,n)},s=e=>{var n=rM(),r=N(n),i=N(r),a=e=>{var n=tM(),r=N(n,!0);E(n),n.value=n.__value=``,I(()=>V(r,L(t).placeholder)),B(e,n)};U(i,e=>{L(t).placeholder&&e(a)}),Xi(F(i),17,()=>L(t).options??[],e=>e.value,(e,t)=>{var n=nM(),r=N(n,!0);E(n);var i={};I(()=>{V(r,L(t).label),i!==(i=L(t).value)&&(n.value=(n.__value=L(t).value)??``)}),B(e,n)}),E(r),_b(F(r,2),{name:`chevronDown`,class:`form__select-arrow`}),E(n),I(e=>{G(r,`id`,e),r.required=L(t).required},[()=>p(L(t).name)]),Ma(r,()=>u()[L(t).name],e=>u(u()[L(t).name]=e,!0)),B(e,n)},c=e=>{var n=iM();Ua(n),I(e=>{G(n,`type`,L(t).type),G(n,`id`,e),G(n,`placeholder`,L(t).placeholder),n.required=L(t).required},[()=>p(L(t).name)]),Qa(n,()=>u()[L(t).name],e=>u(u()[L(t).name]=e,!0)),B(e,n)};U(a,e=>{L(t).type===`textarea`?e(o):L(t).type===`select`?e(s,1):e(c,-1)}),E(n),I(e=>{G(r,`for`,e),V(i,L(t).label)},[()=>p(L(t).name)]),B(e,n)};U(r,e=>{L(t).type===`checkbox`||L(t).type===`radio`?e(i):e(a,-1)}),B(e,n)}),E(f);var m=F(f,2),_=N(m),v=N(_,!0);E(_),E(m),E(t),I(()=>{_.disabled=!c(),V(v,s())}),ii(`submit`,t,async e=>{e.preventDefault(),await l()()}),B(e,t)},$$slots:{title:!0,content:!0}}),O({get open(){return n()},set open(e){n(e),k()},get onClose(){return r()},set onClose(e){r(e),k()},get dialogTitle(){return i()},set dialogTitle(e){i(e),k()},get caption(){return a()},set caption(e){a(e),k()},get fields(){return o()},set fields(e){o(e),k()},get submitLabel(){return s()},set submitLabel(e){s(e),k()},get submitEnabled(){return c()},set submitEnabled(e){c(e),k()},get onSubmit(){return l()},set onSubmit(e){l(e),k()},get values(){return u()},set values(e){u(e),k()},get header(){return d()},set header(e){d(e),k()}})}oi([`change`]),q(sM,{open:{},onClose:{},dialogTitle:{},caption:{},fields:{},submitLabel:{},submitEnabled:{},onSubmit:{},values:{},header:{}},[],[],{mode:`open`});function cM(e,t){D(t,!0);let n=A(()=>Z.data.chatConfig.answerForm),r=e=>G_(e,Z.data.language,Z.data.chatConfig.supportedLanguages),i=A(()=>L(n)?r(L(n).title??L(n).triggerLabel):``),a=A(()=>L(n)?.caption?r(L(n).caption):void 0),o=A(()=>L(n)?r(L(n).submitLabel):``),s=A(()=>L(n)?.fields.map(e=>({type:e.type,name:e.name,label:r(e.label),placeholder:e.placeholder?r(e.placeholder):void 0,required:e.required,options:e.options?.map(e=>({value:e.value,label:r(e.label)}))}))??[]),c=()=>Object.fromEntries((L(n)?.fields??[]).map(e=>[e.name,``])),l=j(Dn(c())),u=A(()=>(L(n)?.fields??[]).every(e=>!e.required||(L(l)[e.name]??``).trim()!==``));var d=z(),f=P(d),p=e=>{{let t=A(()=>!!Z.data.answerFormMessageId);sM(e,{get open(){return L(t)},get onClose(){return db.closeAnswerForm},get dialogTitle(){return L(i)},get caption(){return L(a)},get fields(){return L(s)},get submitLabel(){return L(o)},get submitEnabled(){return L(u)},onSubmit:async()=>{await db.submitAnswerForm(L(l)),M(l,c(),!0),db.closeAnswerForm()},get values(){return L(l)},set values(e){M(l,e,!0)}})}};U(f,e=>{L(n)&&e(p)}),B(e,d),O()}q(cM,{},[],[],{mode:`open`});var lM=R(`<button type="button" class="selected-topic__btn"> </button>`),uM=R(`<div class="selected-topic__container"><h2 class="selected-topic__label"><!> <span class="selected-topic__label-complement"> </span> <span> </span></h2> <!></div>`),dM=R(`<section class="selected-topic"><div><div><!></div></div></section>`);function fM(e,t){D(t,!0);let n=A(()=>Z.t),r=A(()=>Z.data.selectedTopic),i=j(0);var a=dM();let o;var s=N(a),c=N(s),l=N(c),u=e=>{var t=uM(),i=N(t),a=N(i);_b(a,{name:`topic`});var o=F(a,2),s=N(o);E(o);var c=F(o,2),l=N(c,!0);E(c),E(i);var u=F(i,2),d=e=>{var t=lM(),r=N(t,!0);E(t),I(()=>V(r,L(n).changeTopic)),ai(`click`,t,()=>db.onChangeTopic()),B(e,t)};U(u,e=>{L(r).locked||e(d)}),E(t),I(()=>{V(s,`${L(n).selectedTopic??``}:`),V(l,L(r).label)}),fa(1,t,()=>EA,()=>({duration:500,easing:bA,y:50})),fa(2,t,()=>EA,()=>({duration:250,easing:yA,y:50})),B(e,t)};U(l,e=>{L(r)&&e(u)}),E(c),E(s),E(a),I(()=>{G(a,`aria-label`,L(n).ariaChangeTopic),o=ka(a,``,o,{height:L(r)?`${L(i)}px`:`0px`}),Da(c,1,xa([`selected-topic__animation-container`,{"selected-topic__animation-container--hidden":!L(r)}]))}),ao(s,`clientHeight`,e=>M(i,e)),B(e,a),O()}oi([`click`]),q(fM,{},[],[],{mode:`open`});var pM=R(`<button><!> <div class="chat-input__settings-button-label"> </div> <!></button>`),mM=R(`<span class="context-box__notification" data-type="error"> </span>`),hM=R(`<!> <!>`,1),gM=R(`<!> <!>`,1),_M=R(`<!> <!>`,1),vM=R(`<div><div><div class="context-box__content"><div class="context-box__header"><span class="sr-only"> </span> <span> <!></span> <button type="button" class="context-box__close-button btn btn--tertiary btn--square"><!></button></div> <div><!></div> <!></div></div></div>`),yM=R(`<!> <!>`,1),bM=R(`<div><div></div> <!></div>`);function xM(e,t){D(t,!0);let n=K(t,`settingName`,7),r=K(t,`iconName`,7),i=K(t,`currentValues`,7),a=K(t,`possibleValues`,7),o=K(t,`disabled`,7),s=A(()=>Z.selectorTranslations[n()]??{name:n(),placeholder:``,values:{}}),c=A(()=>()=>i().length===0?`${L(s).placeholder}`:i().length===1?`1 ${L(s).name}`:`${i().length} ${L(s).namePlural||L(s).name}`),l=A(()=>Z.selectorsWithErrors.includes(n())),u={duration:Number(Z.theme.components.contextBox.custom?.transitionDuration)||200,delay:Number(Z.theme.components.contextBox.custom?.transitionDelay)||0,y:Number(Z.theme.components.contextBox.custom?.transitionY)||10},d=j(!1);$n(()=>{L(d)&&setTimeout(()=>{M(d,!1)},200)});let f=()=>{M(d,!0),db.setSelectorValue(n(),a()),db.setAriaLiveStatusMessage(Z.t.ariaAllSelected)},p=async()=>{M(d,!0),db.setSelectorValue(n(),[]),await qr().then(()=>{let e=Z.t.ariaAllUnselected;L(l)&&(e+=`. ${Z.t.chooseAtLeastOneOption}`),db.setAriaLiveStatusMessage(e)})},m=()=>{M(d,!0);let e=db.resetSelectorToDefaults(n());db.setAriaLiveStatusMessage(`${Z.t.ariaAllReseted}: ${e.join(`, `)}`)},h=j(void 0),g=j(!1);var _={get settingName(){return n()},set settingName(e){n(e),k()},get iconName(){return r()},set iconName(e){r(e),k()},get currentValues(){return i()},set currentValues(e){i(e),k()},get possibleValues(){return a()},set possibleValues(e){a(e),k()},get disabled(){return o()},set disabled(e){o(e),k()}},v=bM(),y=N(v);return so(y,e=>M(h,e),()=>L(h)),W(F(y,2),()=>sA,(e,t)=>{t(e,{get open(){return L(g)},set open(e){M(g,e,!0)},children:(e,t)=>{var _=yM(),v=P(_);{let e=(e,t)=>{let n=()=>t?.().props;var i=pM();Ja(i,()=>({type:`button`,class:`chat-input__settings-button btn btn--tertiary`,"data-has-error":L(l),...n(),disabled:o(),"aria-hidden":o(),tabindex:o()?-1:void 0}));var a=N(i);_b(a,{get name(){return r()},class:`chat-input__settings-button-icon`});var s=F(a,2),u=N(s,!0);E(s),_b(F(s,2),{name:`chevronDownSmall`,class:`chat-input__settings-button-chevron`}),E(i),I(e=>V(u,e),[()=>L(c)()]),B(e,i)};W(v,()=>fA,(t,n)=>{n(t,{child:e,$$slots:{child:!0}})})}W(F(v,2),()=>kC,(e,t)=>{t(e,{get to(){return L(h)},children:(e,t)=>{var r=z(),o=P(r);{let e=(e,t)=>{let r=()=>t?.().wrapperProps,o=()=>t?.().props,c=()=>t?.().open;var h=z(),_=P(h),v=e=>{var t=vM();Ja(t,()=>({...r()}));var c=N(t);Ja(c,()=>({...o()}));var h=N(c),_=N(h),v=N(_),y=N(v,!0);E(v);var b=F(v,2),x=N(b),S=F(x),C=e=>{var t=mM(),n=N(t,!0);E(t),I(()=>V(n,Z.t.chooseAtLeastOneOption)),B(e,t)};U(S,e=>{L(l)&&e(C)}),E(b);var ee=F(b,2);_b(N(ee),{name:`menuClose`}),E(ee),E(_);var te=F(_,2);let ne;W(N(te),()=>Bk,(e,t)=>{t(e,{get value(){return i()},onValueChange:e=>{db.setSelectorValue(n(),e)},class:`display-contents`,children:(e,t)=>{var n=z();Xi(P(n),17,a,Ki,(e,t)=>{let n=A(PT),r=A(()=>L(s).values?.[L(t)]||L(t));var i=z(),a=P(i);{let e=(e,t)=>{let i=()=>t?.().checked;var a=hM(),o=P(a);Kj(o,{get checked(){return i()}}),W(F(o,2),()=>gA,(e,t)=>{t(e,{get for(){return L(n)},children:(e,t)=>{Ze();var n=hi();I(()=>V(n,L(r))),B(e,n)},$$slots:{default:!0}})}),B(e,a)};W(a,()=>Rk,(i,a)=>{a(i,{get value(){return L(t)},class:`context-box__menu-item context-box__menu-item--option`,get id(){return L(n)},closeOnSelect:!1,onCheckedChange:async e=>{L(d)||await qr().then(()=>{let t=e?Z.t.ariaSelected:Z.t.ariaUnselected,n=`${L(r)}, ${t}`;L(l)&&(n+=`. ${Z.t.chooseAtLeastOneOption}`),db.setAriaLiveStatusMessage(n)})},children:e,$$slots:{default:!0}})})}B(e,i)}),B(e,n)},$$slots:{default:!0}})}),E(te),W(F(te,2),()=>Ok,(e,t)=>{t(e,{class:`context-box__footer`,children:(e,t)=>{var n=_M(),r=P(n),i=e=>{var t=gM(),n=P(t);W(n,()=>Ek,(e,t)=>{t(e,{onclick:f,closeOnSelect:!1,class:`context-box__footer-item btn btn--tertiary`,children:(e,t)=>{Ze();var n=hi();I(()=>V(n,Z.t.selectAll)),B(e,n)},$$slots:{default:!0}})}),W(F(n,2),()=>Ek,(e,t)=>{t(e,{onclick:p,closeOnSelect:!1,class:`context-box__footer-item btn btn--tertiary`,children:(e,t)=>{Ze();var n=hi();I(()=>V(n,Z.t.selectNone)),B(e,n)},$$slots:{default:!0}})}),B(e,t)};U(r,e=>{a().length>5&&e(i)}),W(F(r,2),()=>Ek,(e,t)=>{t(e,{onclick:m,closeOnSelect:!1,class:`context-box__footer-item btn btn--tertiary`,children:(e,t)=>{Ze();var n=hi();I(()=>V(n,Z.t.resetToDefaults)),B(e,n)},$$slots:{default:!0}})}),B(e,n)},$$slots:{default:!0}})}),E(h),E(c),E(t),I(()=>{V(y,Z.t.ariaCloseWithEsc),V(x,`${(L(s).intro||L(s).name)??``} `),G(ee,`aria-label`,Z.t.close),ne=Da(te,1,`context-box__menu context-box__menu--scrollable`,null,ne,{"context-box__menu--two-cols":a().length>8,"context-box__menu--three-cols":a().length>16})}),ai(`click`,ee,()=>M(g,!1)),fa(3,c,()=>EA,()=>u),B(e,t)};U(_,e=>{c()&&e(v)}),B(e,h)};W(o,()=>uA,(t,n)=>{n(t,{class:`context-box context-box--dropdown`,align:`start`,sideOffset:8,forceMount:!0,strategy:`absolute`,preventScroll:!1,child:e,$$slots:{child:!0}})})}B(e,r)},$$slots:{default:!0}})}),B(e,_)},$$slots:{default:!0}})}),E(v),B(e,v),O(_)}oi([`click`]),q(xM,{settingName:{},iconName:{},currentValues:{},possibleValues:{},disabled:{}},[],[],{mode:`open`});var SM=R(`<button><!> <div class="chat-input__settings-button-label"><span class="chat-input__settings-button-label-name"> </span> </div> <!></button>`),CM=R(`<!> <!>`,1),wM=R(`<!> <!>`,1),TM=R(`<!> <!>`,1),EM=R(`<div><div><div class="context-box__content"><div class="context-box__header"><span class="sr-only"> </span> <span> </span> <button type="button" class="context-box__close-button btn btn--tertiary btn--square"><!></button></div> <div><!></div> <!></div></div></div>`),DM=R(`<!> <!>`,1),OM=R(`<div><div></div> <!></div>`);function kM(e,t){D(t,!0);let n=K(t,`settingName`,7),r=K(t,`iconName`,7),i=K(t,`currentValue`,7),a=K(t,`possibleValues`,7),o=K(t,`allowEmpty`,7),s=K(t,`disabled`,7),c=A(()=>Z.selectorTranslations[n()]??{name:n(),placeholder:``,values:{}}),l=A(()=>i()?L(c).values?.[i()]||i():L(c).placeholder),u=A(()=>Z.selectorsWithErrors.includes(n())),d={duration:Number(Z.theme.components.contextBox.custom?.transitionDuration)||200,delay:Number(Z.theme.components.contextBox.custom?.transitionDelay)||0,y:Number(Z.theme.components.contextBox.custom?.transitionY)||10},f=()=>{db.resetSelectorToDefaults(n())},p=j(void 0),m=j(!1);var h={get settingName(){return n()},set settingName(e){n(e),k()},get iconName(){return r()},set iconName(e){r(e),k()},get currentValue(){return i()},set currentValue(e){i(e),k()},get possibleValues(){return a()},set possibleValues(e){a(e),k()},get allowEmpty(){return o()},set allowEmpty(e){o(e),k()},get disabled(){return s()},set disabled(e){s(e),k()}},g=OM(),_=N(g);return so(_,e=>M(p,e),()=>L(p)),W(F(_,2),()=>sA,(e,t)=>{t(e,{get open(){return L(m)},set open(e){M(m,e,!0)},children:(e,t)=>{var h=DM(),g=P(h);{let e=(e,t)=>{let n=()=>t?.().props;var i=SM();Ja(i,()=>({type:`button`,class:`chat-input__settings-button btn btn--tertiary`,"data-has-error":L(u),...n(),disabled:s(),"aria-hidden":s(),tabindex:s()?-1:void 0}));var a=N(i);_b(a,{get name(){return r()},class:`chat-input__settings-button-icon`});var o=F(a,2),d=N(o),f=N(d);E(d);var p=F(d);E(o),_b(F(o,2),{name:`chevronDownSmall`,class:`chat-input__settings-button-chevron`}),E(i),I(()=>{V(f,`${L(c).name??``}:`),V(p,` ${L(l)??``}`)}),B(e,i)};W(g,()=>fA,(t,n)=>{n(t,{child:e,$$slots:{child:!0}})})}W(F(g,2),()=>kC,(e,t)=>{t(e,{get to(){return L(p)},children:(e,t)=>{var r=z(),s=P(r);{let e=(e,t)=>{let r=()=>t?.().wrapperProps,s=()=>t?.().props,l=()=>t?.().open;var u=z(),p=P(u),h=e=>{var t=EM();Ja(t,()=>({...r()}));var l=N(t);Ja(l,()=>({...s()}));var u=N(l),p=N(u),h=N(p),g=N(h,!0);E(h);var _=F(h,2),v=N(_,!0);E(_);var y=F(_,2);_b(N(y),{name:`menuClose`}),E(y),E(p);var b=F(p,2);let x;var S=N(b);{let e=A(()=>i()||``);W(S,()=>Ik,(t,r)=>{r(t,{get value(){return L(e)},onValueChange:e=>{e?db.setSelectorValue(n(),[e]):db.setSelectorValue(n(),[])},children:(e,t)=>{var n=TM(),r=P(n),i=e=>{let t=A(PT);var n=z(),r=P(n);{let e=(e,n)=>{let r=()=>n?.().checked;var i=CM(),a=P(i);Jj(a,{get checked(){return r()}}),W(F(a,2),()=>gA,(e,n)=>{n(e,{get for(){return L(t)},children:(e,t)=>{Ze();var n=hi();I(()=>V(n,L(c).placeholder)),B(e,n)},$$slots:{default:!0}})}),B(e,i)};W(r,()=>Mk,(n,r)=>{r(n,{value:``,class:`context-box__menu-item context-box__menu-item--option`,get id(){return L(t)},children:e,$$slots:{default:!0}})})}B(e,n)};U(r,e=>{o()&&e(i)}),Xi(F(r,2),17,a,Ki,(e,t)=>{let n=A(PT);var r=z(),i=P(r);{let e=(e,r)=>{let i=()=>r?.().checked;var a=wM(),o=P(a);Jj(o,{get checked(){return i()}}),W(F(o,2),()=>gA,(e,r)=>{r(e,{get for(){return L(n)},children:(e,n)=>{Ze();var r=hi();I(()=>V(r,L(c).values?.[L(t)]||L(t))),B(e,r)},$$slots:{default:!0}})}),B(e,a)};W(i,()=>Mk,(r,i)=>{i(r,{get value(){return L(t)},class:`context-box__menu-item context-box__menu-item--option`,get id(){return L(n)},children:e,$$slots:{default:!0}})})}B(e,r)}),B(e,n)},$$slots:{default:!0}})})}E(b),W(F(b,2),()=>Ok,(e,t)=>{t(e,{class:`context-box__footer`,children:(e,t)=>{var n=z();W(P(n),()=>Ek,(e,t)=>{t(e,{onclick:f,closeOnSelect:!1,class:`context-box__footer-item btn btn--tertiary`,children:(e,t)=>{Ze();var n=hi();I(()=>V(n,Z.t.resetToDefaults)),B(e,n)},$$slots:{default:!0}})}),B(e,n)},$$slots:{default:!0}})}),E(u),E(l),E(t),I(()=>{V(g,Z.t.ariaCloseWithEsc),V(v,L(c).intro||L(c).name),G(y,`aria-label`,Z.t.close),x=Da(b,1,`context-box__menu context-box__menu--scrollable`,null,x,{"context-box__menu--two-cols":a().length>8,"context-box__menu--three-cols":a().length>16})}),ai(`click`,y,()=>M(m,!1)),fa(3,l,()=>EA,()=>d),B(e,t)};U(p,e=>{l()&&e(h)}),B(e,u)};W(s,()=>uA,(t,n)=>{n(t,{class:`context-box context-box--dropdown`,align:`start`,sideOffset:8,forceMount:!0,strategy:`absolute`,preventScroll:!1,child:e,$$slots:{child:!0}})})}B(e,r)},$$slots:{default:!0}})}),B(e,h)},$$slots:{default:!0}})}),E(g),B(e,g),O(h)}oi([`click`]),q(kM,{settingName:{},iconName:{},currentValue:{},possibleValues:{},allowEmpty:{},disabled:{}},[],[],{mode:`open`});function AM(e,t){D(t,!0);let n=K(t,`chatSettingConfig`,7),r=K(t,`settingsIsOpen`,7);var i={get chatSettingConfig(){return n()},set chatSettingConfig(e){n(e),k()},get settingsIsOpen(){return r()},set settingsIsOpen(e){r(e),k()}},a=z(),o=P(a),s=e=>{{let t=A(()=>n().iconName||n().settingName),i=A(()=>!r());kM(e,{get settingName(){return n().settingName},get iconName(){return L(t)},get currentValue(){return Z.data.selectorValues[n().settingName][0]},get possibleValues(){return n().values},get allowEmpty(){return n().allowEmpty},get disabled(){return L(i)}})}},c=e=>{{let t=A(()=>n().iconName||n().settingName),i=A(()=>!r());xM(e,{get settingName(){return n().settingName},get iconName(){return L(t)},get currentValues(){return Z.data.selectorValues[n().settingName]},get possibleValues(){return n().values},get disabled(){return L(i)}})}};return U(o,e=>{n().type===`single-select`?e(s):n().type===`multi-select`&&e(c,1)}),B(e,a),O(i)}q(AM,{chatSettingConfig:{},settingsIsOpen:{}},[],[],{mode:`open`});function jM(e,t){D(t,!0);let n=K(t,`settingsIsOpen`,7);var r={get settingsIsOpen(){return n()},set settingsIsOpen(e){n(e),k()}},i=z();return Xi(P(i),17,()=>Z.data.chatConfig.selectorsConfig,Ki,(e,t)=>{AM(e,{get settingsIsOpen(){return n()},get chatSettingConfig(){return L(t)}})}),B(e,i),O(r)}q(jM,{settingsIsOpen:{}},[],[],{mode:`open`});var MM=mi(`<svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" aria-hidden="true"><defs><linearGradient x1="0" y1="1" x2="0" y2="0"><stop></stop><stop></stop></linearGradient><mask maskUnits="userSpaceOnUse" x="0" y="0" width="24" height="24"><g stroke="white" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" fill="none"><path d="M12 1a3 3 0 0 0-3 3v8a3 3 0 0 0 6 0V4a3 3 0 0 0-3-3z"></path><path d="M19 10v2a7 7 0 0 1-14 0v-2"></path><path d="M12 19v4"></path><path d="M8 23h8"></path></g></mask></defs><rect width="24" height="24"></rect></svg>`);function NM(e,t){D(t,!0);let n=K(t,`level`,7),r=K(t,`class`,7,``),i=K(t,`baseColor`,7,`var(--mic-base-color)`),a=K(t,`accentColor`,7,`var(--mic-accent-color)`),o=Math.random().toString(36).substring(2),s=`audio-level-gradient-${o}`,c=`audio-level-mask-${o}`;var l={get level(){return n()},set level(e){n(e),k()},get class(){return r()},set class(e=``){r(e),k()},get baseColor(){return i()},set baseColor(e=`var(--mic-base-color)`){i(e),k()},get accentColor(){return a()},set accentColor(e=`var(--mic-accent-color)`){a(e),k()}},u=MM(),d=N(u),f=N(d),p=N(f),m=F(p);E(f);var h=F(f);E(d);var g=F(d);return E(u),I(()=>{Da(u,0,`audio-level-mic-svg ${r()??``}`),G(f,`id`,s),G(p,`offset`,n()/100),G(p,`stop-color`,a()),G(m,`offset`,n()/100),G(m,`stop-color`,i()),G(h,`id`,c),G(g,`fill`,`url(#${s})`),G(g,`mask`,`url(#${c})`)}),B(e,u),O(l)}q(NM,{level:{},class:{},baseColor:{},accentColor:{}},[],[],{mode:`open`});var PM=R(`<button type="button"><div class="mic-icon" aria-hidden="true"><!></div></button>`);function FM(e,t){D(t,!0);let n=typeof window<`u`,r=A(()=>Z.t),i=K(t,`class`,7),a=A(()=>!!Z.currentAudioRecorder),o=A(()=>n&&jy.isSupported()),s=A(()=>Z.currentAudioVolume||0),c=j(!1),l=async()=>{try{L(a)?db.onStopSpeechRecognition():await db.onStartSpeechRecognition(),M(c,!1)}catch(e){console.error(`Speech recognition error:`,e),M(c,!0)}};$n(()=>()=>{L(a)&&db.onStopSpeechRecognition()});var u={get class(){return i()},set class(e){i(e),k()}},d=z(),f=P(d),p=e=>{var t=PM();let n;var o=N(t);NM(N(o),{get level(){return L(s)}}),E(o),E(t),I(()=>{G(t,`aria-label`,L(a)?L(r).chatInputStopListening:L(r).chatInputStartListening),n=Da(t,1,`chat-input__mic-button transition-colors ${i()??``}`,null,n,{"chat-input__mic-button--listening":L(a),"chat-input__mic-button--error":L(c)})}),ai(`click`,t,l),B(e,t)};return U(f,e=>{L(o)&&e(p)}),B(e,d),O(u)}oi([`click`]),q(FM,{class:{}},[],[],{mode:`open`});var IM=R(`<div class="chat-input__notification" data-type="error" aria-live="assertive"><!> <span class="chat-input__notification-label"> </span></div>`),LM=R(`<button><!></button>`),RM=R(`<button type="button" class="chat-input__settings-button btn btn--tertiary"><!> <div class="chat-input__settings-button-label"> </div></button>`),zM=R(`<!> <!>`,1),BM=R(`<nav><h2 class="sr-only"> </h2> <div class="chat-input__toggle-area"><!></div> <div class="chat-input__settings"><!></div></nav>`),VM=R(`<form><!> <div class="animated-height chat-input__notification-wrapper" role="presentation"><div class="chat-input__notification-animation-element"><!></div></div> <div role="region"><h2 class="sr-only"> </h2> <textarea name="chat-input-value" class="chat-input__textarea"></textarea> <!> <div class="chat-input__buttons"><!> <button type="submit"><span class="sr-only"> </span> <!></button></div></div></form>`);function HM(e,t){D(t,!0);let n=A(()=>Z.t),r=K(t,`class`,7),i=K(t,`ariaLabel`,7),a=K(t,`onSubmit`,7),o=K(t,`avoidFocusOnMount`,7),s=K(t,`disabledInput`,7),c=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`class`,`ariaLabel`,`onSubmit`,`avoidFocusOnMount`,`disabledInput`]),l=A(()=>Z.data.chatInputValue),u=A(()=>Z.data.selectedTopic),d=A(()=>L(l).trim().length>(Z.data.chatConfig.questionLengthLimit||600)),f=A(()=>L(l).trim()&&!L(d)&&!Z.data.questionHasPii),p=A(()=>Z.data.currentConversationState===`answering`||Z.data.currentConversationState===`searching`),m=A(()=>!L(f)&&!L(p)),h=j(void 0),g,_=A(()=>Z.data?.chatConfig?.allowAudioInput??!0),v=A(()=>!!Z.currentAudioRecorder),y=A(()=>Z.isTranscribing),b=j(0),x=j(void 0),S=j(void 0),C=j(Dn(Z.data.selectorsIsOpen)),ee=j(Dn(Z.data.selectorsIsOpen)),te=A(()=>Z.data.chatConfig.selectorsConfig.length>0),ne=A(()=>Z.data.chatConfig.showExpandedSelectors),re=j(void 0),w,ie=A(()=>{let e=``;return Z.data.questionHasPii?e=Z.piiTranslations[Z.data.questionHasPii]:L(d)&&(e=L(n).messageTooLong?.replace(`{questionLengthLimit}`,(Z.data.chatConfig.questionLengthLimit||600).toString())?.replace(`{questionLength}`,L(l).trim().length.toString())),e}),ae=A(()=>()=>L(y)?L(n).messageBotLoading:L(v)&&L(n).chatInputPlaceholderListening?L(n).chatInputPlaceholderListening:L(u)?.placeholder?L(u).placeholder:L(n).chatInputPlaceholder),oe=()=>{L(p)?db.abort():L(f)&&(a()(L(l)),pe(),Ay()&&L(h)?.blur())},se=e=>{e.preventDefault(),oe()},ce=e=>{e.key===`Enter`&&!e.shiftKey&&(e.preventDefault(),oe())},le=e=>{e.composedPath()[0].matches(`button, a, textarea, input`)||setTimeout(()=>{L(h)?.blur()},100)},ue=()=>{Ay()&&window.addEventListener(`pointerdown`,le)},de=()=>{Ay()&&window.removeEventListener(`pointerdown`,le)},fe=e=>{if(!e.value){e.value=e.placeholder;let t=Math.ceil(e.scrollHeight);return e.value=``,t}return e.scrollHeight},pe=()=>{qr().then(()=>{if(L(h)){L(h).style.height=`auto`;let e=fe(L(h));L(h).style.height=`${e}px`}})};$n(()=>{L(l)&&pe()});let me=e=>{pe(),db.onInput(e.currentTarget.value),w&&clearTimeout(w),w=setTimeout(()=>{L(ie)&&db.setAriaLiveStatusMessage(L(ie))},1e3)},he=()=>{M(C,!1),qr().then(()=>L(x)?.focus())};$n(()=>{if(L(h))return g=new ResizeObserver(()=>{pe()}),g.observe(L(h)),()=>{g.disconnect()}}),$n(()=>{let e=new URLSearchParams(window.location.search),t=e.get(`prefill`);t&&(M(l,t),e.delete(`prefill`),history.replaceState(null,``,`${location.pathname}?${e.toString()}${window.location.hash}`))}),Ii(()=>{!Ay()&&!o()&&setTimeout(()=>{L(h)?.focus()},100)}),$n(()=>{let e=L(C)&&!L(ee);M(ee,L(C),!0),e&&(L(x)?.setAttribute(vb,`true`),Z.data.chatConfig.showExpandedSelectors||qr().then(()=>L(S)?.focus({preventScroll:!0})))});function ge(){L(h)?.focus()}var _e={focus:ge,get class(){return r()},set class(e){r(e),k()},get ariaLabel(){return i()},set ariaLabel(e){i(e),k()},get onSubmit(){return a()},set onSubmit(e){a(e),k()},get avoidFocusOnMount(){return o()},set avoidFocusOnMount(e){o(e),k()},get disabledInput(){return s()},set disabledInput(e){s(e),k()}},ve=VM();ii(`resize`,An,pe),Ja(ve,()=>({name:`chat-input`,onsubmit:se,class:[`chat-input`,{"chat-input--disabled":s()},r()],...c,inert:s()?!0:void 0}));var ye=N(ve);fM(ye,{});var be=F(ye,2);let xe;var Se=N(be),Ce=N(Se),we=e=>{var t=IM(),n=N(t);_b(n,{name:`warning`,class:`chat-input__notification-icon`});var r=F(n,2),i=N(r,!0);E(r),E(t),I(()=>V(i,L(ie))),fa(2,t,()=>TA,()=>({duration:100,delay:1e3})),B(e,t)};U(Ce,e=>{L(ie)&&e(we)}),E(Se),E(be);var Te=F(be,2);let Ee;var De=N(Te),Oe=N(De,!0);E(De);var ke=F(De,2);Un(ke),G(ke,`rows`,1),so(ke,e=>M(h,e),()=>L(h)),_a(ke,(e,t)=>fb?.(e,t),()=>`chatInput`),_a(ke,(e,t)=>pb?.(e,t),()=>`chatInput`);var Ae=F(ke,2),je=e=>{var t=z(),r=P(t);{let e=e=>{var t=BM(),r=N(t),i=N(r,!0);E(r);var a=F(r,2),o=N(a);{let e=(e,t)=>{let r=()=>t?.().props;var i=LM();Ja(i,()=>({class:`chat-input__settings-toggle-button btn btn--tertiary btn--square`,...r(),disabled:L(C),"aria-hidden":L(C),"aria-label":L(n).showSettings,tabindex:L(C)?-1:void 0})),_b(N(i),{name:`settings`}),E(i),_a(i,(e,t)=>yb?.(e,t),()=>({text:L(C)?``:L(n).showSettings,position:`top`,delay:0})),so(i,e=>M(x,e),()=>L(x)),B(e,i)};W(o,()=>dE,(t,n)=>{n(t,{child:e,$$slots:{child:!0}})})}E(a);var s=F(a,2);W(N(s),()=>lE,(e,t)=>{t(e,{class:`display-contents`,forceMount:!0,children:(e,t)=>{var r=zM(),i=P(r),a=e=>{var t=RM(),r=N(t);_b(r,{name:`settingsClose`,class:`chat-input__settings-button-icon`});var i=F(r,2),a=N(i,!0);E(i),E(t),so(t,e=>M(S,e),()=>L(S)),I(()=>{G(t,`aria-label`,L(n).hideSettings),G(t,`aria-hidden`,!L(C)),t.disabled=!L(C),G(t,`tabindex`,L(C)?void 0:-1),V(a,L(n).hideSettings)}),ai(`click`,t,he),B(e,t)};U(i,e=>{L(ne)||e(a)}),jM(F(i,2),{get settingsIsOpen(){return L(C)}}),B(e,r)},$$slots:{default:!0}})}),E(s),E(t),I(()=>{G(t,`aria-label`,L(n).ariaSettingsRegion),V(i,L(n).ariaSettings)}),ao(s,`clientHeight`,e=>M(b,e)),B(e,t)};W(r,()=>sE,(t,n)=>{n(t,{get open(){return L(C)},set open(e){M(C,e,!0)},child:e,$$slots:{child:!0}})})}B(e,t)};U(Ae,e=>{L(te)&&e(je)});var Me=F(Ae,2),Ne=N(Me),Pe=e=>{FM(e,{})};U(Ne,e=>{L(_)&&e(Pe)});var Fe=F(Ne,2);let Ie;var Le=N(Fe),Re=N(Le,!0);E(Le);var ze=F(Le,2),Be=e=>{_b(e,{name:`abort`,class:`chat-input__submit-icon`})},Ve=e=>{_b(e,{name:`submit`,class:`chat-input__submit-icon`})};return U(ze,e=>{L(p)?e(Be):e(Ve,-1)}),E(Fe),E(Me),E(Te),E(ve),I(e=>{xe=ka(be,``,xe,{height:L(ie)?`${L(re)}px`:`0px`}),Ee=Da(Te,1,`chat-input__grid`,null,Ee,{"chat-input__grid--has-settings":L(te),"chat-input__grid--settings-is-open":L(C)}),ka(Te,`--chat-input-settings-height: ${L(C)?L(b):0}px`),G(Te,`aria-label`,L(n).ariaAskQuestionRegion),V(Oe,L(n).ariaAskQuestion),Wa(ke,L(l)),G(ke,`aria-label`,i()),G(ke,`placeholder`,e),Fe.disabled=L(m),Ie=Da(Fe,1,`chat-input__submit-button transition-colors`,null,Ie,{"chat-input__submit-button--deactivated":L(m)}),V(Re,L(p)?L(n).chatInputAbort:L(n).chatInputSubmit)},[()=>L(ae)()]),ao(Se,`clientHeight`,e=>M(re,e)),ai(`input`,ke,me),ai(`focusin`,ke,ue),ai(`focusout`,ke,de),ii(`keypress`,ke,ce),B(e,ve),O(_e)}oi([`input`,`focusin`,`focusout`,`click`]),q(HM,{class:{},ariaLabel:{},onSubmit:{},avoidFocusOnMount:{},disabledInput:{}},[],[`focus`],{mode:`open`});var UM=R(`<label class="classification-feedback__option btn btn--secondary"><input type="radio" name="quality"/> </label>`),WM=R(`<fieldset class="classification-feedback__item"><legend class="classification-feedback__label"> </legend> <!></fieldset>`),GM=R(`<label class="classification-feedback__option btn btn--secondary"><input type="radio" name="impact"/> </label>`),KM=R(`<fieldset class="classification-feedback__item"><legend class="classification-feedback__label"> </legend> <!></fieldset>`),qM=R(`<div class="classification-feedback"><div class="classification-feedback__title"> </div> <!> <!></div>`);function JM(e,t){D(t,!0);let n=[],r=[],i=A(()=>Z.t),a=K(t,`impact`,15),o=K(t,`quality`,15),s=K(t,`classificationConfig`,7);var c={get impact(){return a()},set impact(e){a(e),k()},get quality(){return o()},set quality(e){o(e),k()},get classificationConfig(){return s()},set classificationConfig(e){s(e),k()}},l=z(),u=P(l),d=e=>{var t=qM(),c=N(t),l=N(c,!0);E(c);var u=F(c,2),d=e=>{var t=WM(),r=N(t),i=N(r,!0);E(r),Xi(F(r,2),17,()=>s().quality.options,Ki,(e,t)=>{var r=UM(),i=N(r);Ua(i);var a,s=F(i);E(r),I(()=>{a!==(a=L(t).value)&&(i.value=(i.__value=L(t).value)??``),V(s,` ${L(t).label??``}`)}),eo(n,[],i,()=>(L(t).value,o()),o),B(e,r)}),E(t),I(()=>V(i,s().quality.label)),B(e,t)};U(u,e=>{s().quality&&s().quality.options.length!==0&&e(d)});var f=F(u,2),p=e=>{var t=KM(),n=N(t),i=N(n,!0);E(n),Xi(F(n,2),17,()=>s().impact.options,Ki,(e,t)=>{var n=GM(),i=N(n);Ua(i);var o,s=F(i);E(n),I(()=>{o!==(o=L(t).value)&&(i.value=(i.__value=L(t).value)??``),V(s,` ${L(t).label??``}`)}),eo(r,[],i,()=>(L(t).value,a()),a),B(e,n)}),E(t),I(()=>V(i,s().impact.label)),B(e,t)};U(f,e=>{s().impact&&s().impact.options.length!==0&&e(p)}),E(t),I(()=>V(l,L(i).classificationTitle)),B(e,t)};return U(u,e=>{s()&&(s().quality||s().impact)&&e(d)}),B(e,l),O(c)}q(JM,{impact:{},quality:{},classificationConfig:{}},[],[],{mode:`open`});function YM(e,t){D(t,!0);let n=A(()=>Z.t),r=j(void 0),i=j(void 0),a=j(Dn({message:``,email:``})),o=A(()=>[{type:`textarea`,name:`message`,label:L(n).feedbackFormMessage,placeholder:L(n).feedbackFormMessagePlaceholder},...Z.data.chatConfig.showOverallFeedbackEmail?[{type:`email`,name:`email`,label:L(n).feedbackFormEmail,placeholder:L(n).feedbackFormEmailPlaceholder}]:[]]),s=A(()=>L(r)!==void 0||L(i)!==void 0||L(a).message!==``);{let t=e=>{JM(e,{get classificationConfig(){return Z.data.chatConfig.classification},get impact(){return L(r)},set impact(e){M(r,e,!0)},get quality(){return L(i)},set quality(e){M(i,e,!0)}})},c=A(()=>!!Z.data.conversationFeedbackId||Z.data.conversationFeedbackIsOpen);sM(e,{get open(){return L(c)},get onClose(){return db.closeFeedback},get dialogTitle(){return L(n).feedbackFormTitle},get fields(){return L(o)},get submitEnabled(){return L(s)},get submitLabel(){return L(n).send},onSubmit:async()=>{Z.data.chatConfig.classification?await db.submitFeedback({email:L(a).email,message:L(a).message,classification:{impact:L(r),quality:L(i)}}):await db.submitFeedback({email:L(a).email,message:L(a).message}),M(r,void 0),M(i,void 0),M(a,{message:``,email:``},!0),db.closeFeedback()},get values(){return L(a)},set values(e){M(a,e,!0)},header:t,$$slots:{header:!0}})}O()}q(YM,{},[],[],{mode:`open`});var XM=R(`<div><button class="btn btn--primary" aria-haspopup="dialog"> </button></div>`),ZM=R(`<a class="skip-link"> </a>`),QM=R(`<div class="chat-page__footer-text"></div>`),$M=R(`<section class="chat-page"><!> <!> <div class="chat-page__survey-portal"><div class="container"></div></div> <div class="chat-page__body"><h2 class="sr-only"></h2> <div class="chat-page__messages"></div> <div class="chat-page__buttons"><!></div></div> <div><div class="container"><div class="chat-page__footer-content"><button aria-hidden="true"><span class="sr-only"> </span> <!></button> <!> <!> <!></div></div></div></section>`);function eN(e,t){D(t,!0);let n=A(()=>Z.t),r=j(!1),i=j(void 0),a=j(void 0),o=j(void 0),s=j(void 0),c=j(void 0),l,u=A(()=>Z.data.history.findLast(e=>e.type===`bot`)),d=A(()=>Z.data.history.findLast(e=>e.type===`bot`||e.type===`component`)),f=A(()=>L(d)?.type===`component`&&!!L(d).hideChatInput),p=A(()=>!!L(u)?.noFeedback),m=e=>{l&&Kb(l,l.scrollHeight-l.clientHeight,e,`scrollTop`,vA)},h=()=>{l&&M(r,!(l.scrollHeight-l.scrollTop-l.clientHeight<90))},g,_=j(!1),v=()=>{M(_,!1),g?.disconnect(),g=new IntersectionObserver(([e])=>{e.isIntersecting?(M(_,!0),g.disconnect()):M(_,!1)},{root:Z.targets.scrollContainer,rootMargin:`0px 0px -30% 0px`}),L(s)&&g.observe(L(s))};Ii(()=>(v(),window.addEventListener(`resize`,v),()=>{g?.disconnect(),window.removeEventListener(`resize`,v)}));let y=()=>{h()},b=e=>{if(e.altKey&&e.code===`KeyR`){if(Z.data.chatConfig.forceChatPage)return;e.preventDefault();let t=Z.data.history.findLast(e=>e.type===`user`)?.message;db.goto({name:`start-page`,prefill:t})}},x=()=>{setTimeout(()=>{let{chatAppContainer:e,chatAppHeader:t,chatPageMessages:n,chatPageLastUserMessage:r}=Z.targets;if(!(Z.data.chatConfig.inlineLayout&&!Z.data.props.flyout&&!Z.data.isInlineLayoutContained)&&e&&t&&L(s)&&n&&L(a)&&L(o)&&r){let i=e.clientHeight-t.offsetHeight-L(s).offsetHeight-L(o).offsetHeight-r.offsetHeight-parseInt(getComputedStyle(n).gap)*2;i>0?(L(a).style.setProperty(`--last-bot-message-min-height`,`${i}px`),m(1e3)):r.scrollIntoView({behavior:`smooth`})}},150)},S=()=>{db.onSubmit(!0)};$n(()=>{L(i)&&(l=L(i).closest(`.chat-app__main`))}),$n(()=>{if(l)return l.addEventListener(`scroll`,h),()=>{l.removeEventListener(`scroll`,h)}}),$n(()=>{!L(f)&&!Ay()&&qr().then(()=>L(c)?.focus())});let C=e=>{let t=Z.data.history[e-1];t&&t.type===`user`&&(db.updateChatInput(t.message),L(c)?.focus())};var ee=$M();ii(`resize`,An,y),ii(`keypress`,An,b);var te=N(ee);YM(te,{});var ne=F(te,2);cM(ne,{});var re=F(ne,2);_a(N(re),(e,t)=>pb?.(e,t),()=>`surveyPortal`),E(re);var w=F(re,2),ie=N(w);na(ie,()=>L(n).ariaChatHistory,!0),E(ie);var ae=F(ie,2);Xi(ae,23,()=>Z.data.history,e=>e?.id??e?.time,(e,t,n)=>{{let r=A(()=>L(n)===Z.data.history.length-1);Cj(e,{get message(){return L(t)},get index(){return L(n)},onmessageupdate:h,onbotmessageinit:x,onaskQuestion:()=>{C(L(n))},get isLast(){return L(r)}})}}),E(ae),so(ae,e=>M(a,e),()=>L(a)),_a(ae,(e,t)=>pb?.(e,t),()=>`chatPageMessages`);var oe=F(ae,2),se=N(oe),ce=e=>{var t=XM(),r=N(t),i=N(r,!0);E(r),E(t),I(()=>{Da(t,1,xa([`chat-page__give-feedback`,{"chat-page__give-feedback--disabled":L(p)}])),t.inert=L(p)?!0:void 0,G(r,`aria-expanded`,Z.data.conversationFeedbackIsOpen),V(i,L(n).giveFeedback)}),ai(`click`,r,()=>db.openConversationFeedback()),B(e,t)};U(se,e=>{Z.data.chatConfig.showOverallFeedbackButton&&e(ce)}),E(oe),so(oe,e=>M(o,e),()=>L(o)),E(w);var le=F(w,2),ue=N(le),de=N(ue),fe=N(de);let pe;G(fe,`tabindex`,-1);var me=N(fe),he=N(me,!0);E(me),_b(F(me,2),{name:`chevronDown`}),E(fe);var ge=F(fe,2);so(HM(ge,{onSubmit:S,class:`chat-page__chat-input`,get disabledInput(){return L(f)}}),e=>M(c,e,!0),()=>L(c));var _e=F(ge,2),ve=e=>{var t=ZM(),r=N(t,!0);E(t),I(()=>{G(t,`href`,`#${uI}`),V(r,L(n).ariaGotoMainNavigation)}),ai(`click`,t,function(...e){dI?.apply(this,e)}),B(e,t)};U(_e,e=>{Z.hasMainNavigationContent&&e(ve)});var ye=F(_e,2),be=e=>{var t=QM();na(t,()=>L(n).chatFooterText,!0),E(t),B(e,t)};U(ye,e=>{L(n).chatFooterText!==void 0&&e(be)}),E(de),E(ue),E(le),so(le,e=>M(s,e),()=>L(s)),E(ee),so(ee,e=>M(i,e),()=>L(i)),I(()=>{Da(le,1,xa([`chat-page__footer`,{"chat-page__footer--unsticked":L(_)}])),pe=Da(fe,1,`chat-page__scroll-to-bottom btn btn--secondary btn--square`,null,pe,{"chat-page__scroll-to-bottom--hidden":!L(r)}),fe.disabled=!L(r),V(he,L(n).scrollToBottom)}),ai(`click`,fe,()=>{m(500)}),B(e,ee),O()}oi([`click`]),q(eN,{},[],[],{mode:`open`});var tN=R(`<div><!> <h2 class="introduction__title"></h2></div>`);function nN(e,t){D(t,!0);let n=A(()=>Z.t),r=K(t,`class`,7);var i={get class(){return r()},set class(e){r(e),k()}},a=tN(),o=N(a);uj(o,{class:`introduction__avatar`,isLarge:!0});var s=F(o,2);return na(s,()=>L(n).introductionTitle,!0),E(s),E(a),I(()=>Da(a,1,`introduction ${r()??``}`)),B(e,a),O(i)}q(nN,{class:{}},[],[],{mode:`open`});var rN=R(`<div class="consent-page__disclaimer text-container fly-in" style="--fly-in-id: 1;"></div>`),iN=R(`<button class="btn btn--secondary" type="button"> </button>`),aN=R(`<section><!> <!> <div class="consent-page__actions fly-in" style="--fly-in-id: 2;"><!> <button class="btn btn--primary" type="button"> </button></div></section>`);function oN(e,t){D(t,!0);let n=A(()=>Z.t),r=A(()=>L(n).popups?.find(e=>e.actions?.some(e=>e.action===`acceptTerms`))),i=j(!1);$n(()=>{M(i,!0)});var a=aN();let o;var s=N(a);nN(s,{class:`consent-page__introduction fly-in`});var c=F(s,2),l=e=>{var t=rN();na(t,()=>L(n).termsInvitationToConsent,!0),E(t),B(e,t)};U(c,e=>{L(n).termsInvitationToConsent&&e(l)});var u=F(c,2),d=N(u),f=e=>{var t=iN(),i=N(t,!0);E(t),I(()=>V(i,L(n).termsReadButton)),ai(`click`,t,()=>window.location.hash=L(r).hash),B(e,t)};U(d,e=>{L(r)&&e(f)});var p=F(d,2),m=N(p,!0);E(p),E(u),E(a),I(()=>{o=Da(a,1,`consent-page container`,null,o,{mounted:L(i)}),V(m,L(n).termsAcceptButton)}),ai(`click`,p,()=>db.acceptTerms()),B(e,a),O()}oi([`click`]),q(oN,{},[],[],{mode:`open`});var sN=R(`<button><span class="sr-only"> </span> <!></button>`),cN=R(`<div><div><button type="button" class="context-box__popover-close"><!> <span class="sr-only"> </span></button> <!></div></div>`),lN=R(`<!> <!>`,1),uN=R(`<div><!></div>`);function dN(e,t){D(t,!0);let n={duration:Number(Z.theme.components.contextBox.custom?.transitionDuration)||200,delay:Number(Z.theme.components.contextBox.custom?.transitionDelay)||0,y:Number(Z.theme.components.contextBox.custom?.transitionY)||10},r=K(t,`openLabel`,7),i=K(t,`closeLabel`,7),a=K(t,`openIcon`,7),o=K(t,`closeIcon`,7),s=K(t,`ariaLabel`,7),c=K(t,`children`,7),l=K(t,`class`,7),u=K(t,`contentClass`,7),d=K(t,`portal`,7),f=j(!1),p=j(void 0);$n(()=>{L(f)?(L(p)?.setAttribute(vb,`true`),Xr(()=>db.setOpenOverlay(!0))):Xr(()=>db.setOpenOverlay(!1))});var m={get openLabel(){return r()},set openLabel(e){r(e),k()},get closeLabel(){return i()},set closeLabel(e){i(e),k()},get openIcon(){return a()},set openIcon(e){a(e),k()},get closeIcon(){return o()},set closeIcon(e){o(e),k()},get ariaLabel(){return s()},set ariaLabel(e){s(e),k()},get children(){return c()},set children(e){c(e),k()},get class(){return l()},set class(e){l(e),k()},get contentClass(){return u()},set contentClass(e){u(e),k()},get portal(){return d()},set portal(e){d(e),k()}},h=uN();return W(N(h),()=>_A,(e,t)=>{t(e,{get open(){return L(f)},set open(e){M(f,e,!0)},children:(e,t)=>{var l=lN(),m=P(l);{let e=(e,t)=>{let n=()=>t?.().props;var s=sN();Ja(s,()=>({class:`context-box__trigger btn btn--tertiary btn--square`,...n(),"aria-controls":d()?.id}));var c=N(s),l=N(c,!0);E(c);var u=F(c,2);{let e=A(()=>L(f)?o():a());_b(u,{get name(){return L(e)}})}E(s),_a(s,(e,t)=>yb?.(e,t),()=>({text:L(f)?i():r(),position:`bottom-right`,delay:0})),so(s,e=>M(p,e),()=>L(p)),I(()=>V(l,L(f)?i():r())),B(e,s)};W(m,()=>eA,(t,n)=>{n(t,{child:e,$$slots:{child:!0}})})}var h=F(m,2);{let e=A(()=>d()||Z.targets.portals);W(h,()=>kC,(t,r)=>{r(t,{get to(){return L(e)},children:(e,t)=>{var r=z(),a=P(r);{let e=(e,t)=>{let r=()=>t?.().wrapperProps,a=()=>t?.().props,l=()=>t?.().open;var u=z(),d=P(u),p=e=>{var t=cN();Ja(t,()=>({...r()}));var l=N(t);Ja(l,()=>({...a(),role:`dialog`,"aria-label":s()}));var u=N(l),d=N(u);_b(d,{get name(){return o()}});var p=F(d,2),m=N(p,!0);E(p),E(u),H(F(u,2),c),E(l),_a(l,e=>Ej?.(e)),E(t),I(()=>V(m,i())),ai(`click`,u,()=>M(f,!1)),fa(3,l,()=>EA,()=>n),B(e,t)};U(d,e=>{l()&&e(p)}),B(e,u)},t=A(()=>[`context-box__content`,u()]);W(a,()=>Qk,(n,r)=>{r(n,{get class(){return L(t)},sideOffset:8,alignOffset:-11,align:`end`,side:`bottom`,strategy:`absolute`,onOpenAutoFocus:e=>e.preventDefault(),onCloseAutoFocus:()=>L(p)?.focus(),forceMount:!0,child:e,$$slots:{child:!0}})})}B(e,r)},$$slots:{default:!0}})})}B(e,l)},$$slots:{default:!0}})}),E(h),I(()=>Da(h,1,xa([`context-box`,l()]))),B(e,h),O(m)}oi([`click`]),q(dN,{openLabel:{},closeLabel:{},openIcon:{},closeIcon:{},ariaLabel:{},children:{},class:{},contentClass:{},portal:{}},[],[],{mode:`open`});var fN=R(`<div class="text-container" aria-live="polite"><span class="sr-only"> </span> <!></div>`);function pN(e,t){D(t,!0);let n=A(()=>Z.t),r=K(t,`content`,7);return dN(e,{get openLabel(){return L(n).openInfo},get closeLabel(){return L(n).close},openIcon:`info`,closeIcon:`menuClose`,contentClass:`context-box__content--info`,get portal(){return Z.targets.chatAppHeaderPortal},get ariaLabel(){return L(n).ariaInfoTitle},children:(e,t)=>{var i=fN(),a=N(i),o=N(a,!0);E(a),na(F(a,2),r),E(i),I(()=>V(o,L(n).ariaCloseWithEsc)),B(e,i)},$$slots:{default:!0}}),O({get content(){return r()},set content(e){r(e),k()}})}q(pN,{content:{}},[],[],{mode:`open`});var mN=R(`<button><span class="sr-only"> </span> <!></button>`),hN=R(`<div><div><!></div></div>`),gN=R(`<!> <!>`,1),_N=R(`<div><!></div>`);function vN(e,t){D(t,!0);let n={duration:Number(Z.theme.components.contextBox.custom?.transitionDuration)||200,delay:Number(Z.theme.components.contextBox.custom?.transitionDelay)||0,y:Number(Z.theme.components.contextBox.custom?.transitionY)||10},r=K(t,`openLabel`,7),i=K(t,`closeLabel`,7),a=K(t,`openIcon`,7),o=K(t,`closeIcon`,7),s=K(t,`disableAutoFocusOnOpen`,7,!1),c=K(t,`children`,7),l=K(t,`class`,7),u=K(t,`contentClass`,7),d=K(t,`portal`,7),f=j(!1),p=j(void 0);$n(()=>{L(f)?(L(p)?.setAttribute(vb,`true`),Xr(()=>db.setOpenOverlay(!0))):Xr(()=>db.setOpenOverlay(!1))});var m={get openLabel(){return r()},set openLabel(e){r(e),k()},get closeLabel(){return i()},set closeLabel(e){i(e),k()},get openIcon(){return a()},set openIcon(e){a(e),k()},get closeIcon(){return o()},set closeIcon(e){o(e),k()},get disableAutoFocusOnOpen(){return s()},set disableAutoFocusOnOpen(e=!1){s(e),k()},get children(){return c()},set children(e){c(e),k()},get class(){return l()},set class(e){l(e),k()},get contentClass(){return u()},set contentClass(e){u(e),k()},get portal(){return d()},set portal(e){d(e),k()}},h=_N();return W(N(h),()=>sA,(e,t)=>{t(e,{get open(){return L(f)},set open(e){M(f,e,!0)},children:(e,t)=>{var l=gN(),m=P(l);{let e=(e,t)=>{let n=()=>t?.().props;var s=mN();Ja(s,()=>({class:`context-box__trigger btn btn--tertiary btn--square`,...n(),"aria-controls":d()?.id}));var c=N(s),l=N(c,!0);E(c);var u=F(c,2);{let e=A(()=>L(f)?o():a());_b(u,{get name(){return L(e)}})}E(s),_a(s,(e,t)=>yb?.(e,t),()=>({text:L(f)?i():r(),position:`bottom-right`,delay:0})),so(s,e=>M(p,e),()=>L(p)),I(()=>V(l,L(f)?i():r())),B(e,s)};W(m,()=>fA,(t,n)=>{n(t,{child:e,$$slots:{child:!0}})})}var h=F(m,2);{let e=A(()=>d()||Z.targets.portals);W(h,()=>kC,(t,r)=>{r(t,{get to(){return L(e)},children:(e,t)=>{var r=z(),i=P(r);{let e=(e,t)=>{let r=()=>t?.().wrapperProps,i=()=>t?.().props,a=()=>t?.().open;var o=z(),s=P(o),l=e=>{var t=hN();Ja(t,()=>({...r()}));var a=N(t);Ja(a,()=>({...i()})),H(N(a),c),E(a),E(t),fa(3,a,()=>EA,()=>n),B(e,t)};U(s,e=>{a()&&e(l)}),B(e,o)},t=A(()=>[`context-box__content`,u()]);W(i,()=>uA,(n,r)=>{r(n,{get class(){return L(t)},sideOffset:8,alignOffset:-11,align:`end`,side:`bottom`,strategy:`absolute`,onOpenAutoFocus:e=>{s()&&e.preventDefault()},forceMount:!0,child:e,$$slots:{child:!0}})})}B(e,r)},$$slots:{default:!0}})})}B(e,l)},$$slots:{default:!0}})}),E(h),I(()=>Da(h,1,xa([`context-box`,l()]))),B(e,h),O(m)}q(vN,{openLabel:{},closeLabel:{},openIcon:{},closeIcon:{},disableAutoFocusOnOpen:{},children:{},class:{},contentClass:{},portal:{}},[],[],{mode:`open`});var yN=e=>e.charAt(0).toUpperCase()+e.slice(1),bN=R(`<span class="sr-only"> </span>`),xN=R(`<!> <span> <!></span>`,1),SN=R(`<div class="context-box__menu"></div>`),CN=R(`<!> <span> </span>`,1),wN=R(`<!> <div class="context-box__menu"></div>`,1),TN=R(`<!> <!>`,1),EN=R(`<!> <span> </span>`,1),DN=R(`<!> <span> </span>`,1),ON=R(`<!> <div class="context-box__color-scheme-selector"><!> <!> <!></div>`,1),kN=R(`<!> <!>`,1),AN=R(`<!> <!> <!>`,1);function jN(e,t){D(t,!0);let n=A(()=>Z.t),r=e=>{db.onLanguageChange(e)},i=e=>`Intl`in globalThis&&Intl.DisplayNames?yN(new Intl.DisplayNames([e],{type:`language`}).of(e)??e.toUpperCase()):e.toUpperCase(),a=e=>{Z.data.selectedColorScheme===e?db.setColorScheme(`system`):db.setColorScheme(e)};vN(e,{get openLabel(){return L(n).openMenu},get closeLabel(){return L(n).closeMenu},openIcon:`menu`,closeIcon:`menuClose`,contentClass:`context-box__content--menu`,get portal(){return Z.targets.chatAppHeaderPortal},children:(e,t)=>{var o=AN(),s=P(o),c=e=>{var t=SN();Xi(t,21,()=>Z.menu,Ki,(e,t)=>{var r=z();W(P(r),()=>Ek,(e,r)=>{r(e,{class:`context-box__menu-item transition-colors`,onSelect:()=>window.open(L(t).url,L(t).target,`noopener,noreferrer`),closeOnSelect:!0,children:(e,r)=>{var i=xN(),a=P(i);_b(a,{get name(){return L(t).icon},class:`context-box__menu-item__icon`});var o=F(a,2),s=N(o,!0),c=F(s),l=e=>{var t=bN(),r=N(t);E(t),I(()=>V(r,`, ${L(n).ariaOpensInNewTab??``}`)),B(e,t)};U(c,e=>{L(t).target===`_blank`&&e(l)}),E(o),I(()=>V(s,L(t).label)),B(e,i)},$$slots:{default:!0}})}),B(e,r)}),E(t),B(e,t)};U(s,e=>{Z.menu.length>0&&e(c)});var l=F(s,2),u=e=>{var t=TN(),a=P(t),o=e=>{var t=z();W(P(t),()=>Pk,(e,t)=>{t(e,{class:`context-box__separator`,"aria-hidden":`true`})}),B(e,t)};U(a,e=>{Z.menu.length>0&&e(o)}),W(F(a,2),()=>Ik,(e,t)=>{t(e,{children:(e,t)=>{var a=wN(),o=P(a);W(o,()=>Ak,(e,t)=>{t(e,{class:`context-box__title`,"aria-hidden":`true`,children:(e,t)=>{Ze();var r=hi();I(()=>V(r,L(n).selectLanguage)),B(e,r)},$$slots:{default:!0}})});var s=F(o,2);Xi(s,21,()=>Z.data.chatConfig.supportedLanguages,Ki,(e,t)=>{var n=z(),a=P(n);{let e=A(()=>[`context-box__menu-item transition-colors`,{active:Z.data.language===L(t)}]);W(a,()=>Mk,(n,a)=>{a(n,{get value(){return L(t)},closeOnSelect:!0,get class(){return L(e)},onSelect:()=>r(L(t)),children:(e,n)=>{var r=CN(),a=P(r);_b(a,{name:`internalLink`,class:`context-box__menu-item__icon`});var o=F(a,2),s=N(o,!0);E(o),I(e=>V(s,e),[()=>i(L(t))]),B(e,r)},$$slots:{default:!0}})})}B(e,n)}),E(s),B(e,a)},$$slots:{default:!0}})}),B(e,t)};U(l,e=>{Z.data.chatConfig.supportedLanguages.length>0&&e(u)});var d=F(l,2),f=e=>{var t=kN(),r=P(t);W(r,()=>Pk,(e,t)=>{t(e,{class:`context-box__separator`,"aria-hidden":`true`})}),W(F(r,2),()=>Ik,(e,t)=>{t(e,{children:(e,t)=>{var r=ON(),i=P(r);W(i,()=>Ak,(e,t)=>{t(e,{class:`context-box__title sr-only`,"aria-hidden":`true`,children:(e,t)=>{Ze();var r=hi();I(()=>V(r,L(n).selectColorTheme)),B(e,r)},$$slots:{default:!0}})});var o=F(i,2),s=N(o);{let e=A(()=>[`context-box__color-scheme-selector-button transition-colors`,{"context-box__color-scheme-selector-button--active":Z.data.selectedColorScheme===`light`}]);W(s,()=>Mk,(t,n)=>{n(t,{value:`light`,closeOnSelect:!0,get class(){return L(e)},onSelect:()=>a(`light`),children:(e,t)=>{var n=EN(),r=P(n);_b(r,{name:`lightMode`});var i=F(r,2),a=N(i,!0);E(i),I(()=>V(a,Z.t.lightMode)),B(e,n)},$$slots:{default:!0}})})}var c=F(s,2);W(c,()=>Pk,(e,t)=>{t(e,{class:`context-box__color-scheme-selector-separator`,"aria-hidden":`true`})});var l=F(c,2);{let e=A(()=>[`context-box__color-scheme-selector-button transition-colors`,{"context-box__color-scheme-selector-button--active":Z.data.selectedColorScheme===`dark`}]);W(l,()=>Mk,(t,n)=>{n(t,{value:`dark`,closeOnSelect:!0,get class(){return L(e)},onSelect:()=>a(`dark`),children:(e,t)=>{var n=DN(),r=P(n);_b(r,{name:`darkMode`});var i=F(r,2),a=N(i,!0);E(i),I(()=>V(a,Z.t.darkMode)),B(e,n)},$$slots:{default:!0}})})}E(o),B(e,r)},$$slots:{default:!0}})}),B(e,t)};U(d,e=>{Z.data.has2ColorSchemes&&e(f)}),B(e,o)},$$slots:{default:!0}}),O()}q(jN,{},[],[],{mode:`open`});var MN=R(`<span class="btn__label"> </span>`),NN=R(`<div><button class="btn btn--tertiary btn--square"><!> <!></button></div>`);function PN(e,t){D(t,!0);let n=A(()=>Z.t),r=K(t,`class`,7);var i={get class(){return r()},set class(e){r(e),k()}},a=NN(),o=N(a),s=N(o);_b(s,{name:`newConversation`});var c=F(s,2),l=e=>{var t=MN(),r=N(t,!0);E(t),I(()=>V(r,L(n).newChat)),B(e,t)};return U(c,e=>{L(n).newChat&&e(l)}),E(o),_a(o,(e,t)=>yb?.(e,t),()=>({text:L(n).newChat,position:`bottom-left`,delay:600})),E(a),I(()=>{Da(a,1,xa([`new-conversation`,r()])),G(o,`aria-label`,L(n).newChat)}),ai(`click`,o,()=>db.onNewConversation()),fa(1,a,()=>EA,()=>({duration:300,y:30})),fa(2,a,()=>EA,()=>({y:15,duration:150,easing:yA})),B(e,a),O(i)}oi([`click`]),q(PN,{class:{}},[],[],{mode:`open`});var FN=R(`<div><div><!></div></div>`);function IN(e,t){D(t,!0);let n=K(t,`class`,7),r=K(t,`children`,7),i=j(void 0);var a={get class(){return n()},set class(e){n(e),k()},get children(){return r()},set children(e){r(e),k()}},o=FN();let s;var c=N(o);return H(N(c),()=>r()??w),E(c),E(o),I(()=>{Da(o,1,xa([`animated-height`,n()])),s=ka(o,``,s,{height:L(i)?`${L(i)}px`:`auto`})}),ao(c,`clientHeight`,e=>M(i,e)),B(e,o),O(a)}q(IN,{class:{},children:{}},[],[],{mode:`open`});var LN=R(`<span class="reference__number transition-colors"> </span>`),RN=R(`<span class="reference__description transition-colors line-clamp line-clamp--6"> </span>`),zN=R(`<span class="reference__breadcrumb transition-colors"> </span>`),BN=R(`<div class="reference__footer"><span class="reference__domain transition-colors"><span class="truncate"> </span></span> <!></div>`),VN=R(`<a target="_blank" rel="noopener noreferrer" class="reference transition-colors"><!> <span class="reference__body transition-colors"><span class="reference__header"><span class="reference__title line-clamp line-clamp--2 h4"> </span> <!></span> <!> <!></span></a>`);function HN(e,t){D(t,!0);let n=K(t,`reference`,7),r=A(()=>`${n().display.listItem.title}. ${n().display.card.description}. ${Z.t.ariaReferenceSource} ${n().display.listItem.badge}${n().display.listItem.breadcrumbs?` / `+n().display.listItem.breadcrumbs.join(` / `):``}`);var i={get reference(){return n()},set reference(e){n(e),k()}},a=VN(),o=N(a),s=e=>{var t=LN(),r=N(t,!0);E(t),I(()=>V(r,n().referenceIndex.used)),B(e,t)};U(o,e=>{n().referenceIndex.used&&e(s)});var c=F(o,2),l=N(c),u=N(l),d=N(u,!0);E(u),_b(F(u,2),{name:`externalLink`,class:`reference__icon transition-colors`}),E(l);var f=F(l,2),p=e=>{var t=RN(),r=N(t,!0);E(t),I(()=>V(r,n().display.card.description)),B(e,t)};U(f,e=>{n().display.card.description&&e(p)});var m=F(f,2),h=e=>{var t=BN(),r=N(t),i=N(r),a=N(i,!0);E(i),E(r);var o=F(r,2),s=e=>{var t=z();Xi(P(t),17,()=>n().display.listItem.breadcrumbs,Ki,(e,t)=>{var n=zN(),r=N(n,!0);E(n),I(()=>V(r,L(t))),B(e,n)}),B(e,t)};U(o,e=>{n().display.listItem.breadcrumbs&&e(s)}),E(t),I(()=>V(a,n().display.listItem.badge)),B(e,t)};return U(m,e=>{n().display.listItem.badge&&e(h)}),E(c),E(a),I(()=>{G(a,`href`,n().url),G(a,`aria-label`,L(r)),V(d,n().display.listItem.title)}),B(e,a),O(i)}q(HN,{reference:{}},[],[],{mode:`open`});function UN(e,{delay:t=0,duration:n=500,resetTop:r=!0}){let i=+getComputedStyle(e).opacity;return e.style.position=`absolute`,r&&(e.style.top=`0px`),{delay:t,duration:n,css:e=>`opacity: ${e*i};`}}var WN=R(`<div><!></div>`),GN=R(`<div class="references__toggle-title"> </div> <!>`,1),KN=R(`<div><div class="references__items"></div></div>`),qN=R(`<div><!></div>`),JN=R(`<!> <!>`,1),YN=R(`<div><!></div>`),XN=R(`<div><div class="references__items"></div> <!></div>`),ZN=R(`<div><div class="references__container"><div class="references__transition"><!></div></div></div>`);function QN(e,t){D(t,!0);let n=K(t,`class`,7),r=A(()=>Z.data.history.filter(e=>e.type===`bot`).find(e=>e.id===Z.data.currentReferencesAsideId)?.references),i=A(()=>Z.data.currentReferencesAsideId),a=j(void 0),o=j(!1),s=j(void 0);$n(()=>{L(i)&&M(o,!1),M(a,L(i),!0)}),$n(()=>{L(o)&&setTimeout(()=>{Z.data.chatConfig.inlineLayout===!1&&L(s)?.scrollIntoView({behavior:`smooth`})},200)});let c={delay:200,duration:500,easing:bA,y:50};var l={get class(){return n()},set class(e){n(e),k()}},u=ZN(),d=N(u),f=N(d);return Gi(N(f),()=>Z.data.currentReferencesAsideId,e=>{var t=XN(),l=N(t);Xi(l,21,()=>L(r)?.used,Ki,(e,t)=>{var n=WN();HN(N(n),{get reference(){return L(t)}}),E(n),fa(1,n,()=>EA,()=>({...c,delay:0})),B(e,n)}),E(l);var u=F(l,2),d=e=>{var t=YN();IN(N(t),{children:(e,t)=>{var i=z();W(P(i),()=>sE,(e,t)=>{t(e,{get class(){return`references__further ${n()??``}`},get open(){return L(o)},set open(e){M(o,e,!0)},children:(e,t)=>{var n=JN(),i=P(n);W(i,()=>dE,(e,t)=>{t(e,{class:`references__toggle transition-colors`,children:(e,t)=>{var n=GN(),r=P(n),i=N(r,!0);E(r),_b(F(r,2),{name:`chevronDown`,class:`references__toggle-icon`}),I(()=>V(i,Z.t.referencesFurtherTitle)),B(e,n)},$$slots:{default:!0}})});var a=F(i,2);{let e=(e,t)=>{let n=()=>t?.().props,i=()=>t?.().open;var a=qN();Ja(a,()=>({...n(),class:`references__container`}));var o=N(a),l=e=>{var t=KN(),n=N(t);Xi(n,21,()=>L(r)?.unused,Ki,(e,t)=>{HN(e,{get reference(){return L(t)}})}),E(n),E(t),fa(1,t,()=>EA,()=>({...c,delay:0})),fa(2,t,()=>TA,()=>({duration:100})),B(e,t)};U(o,e=>{i()&&e(l)}),E(a),so(a,e=>M(s,e),()=>L(s)),B(e,a)};W(a,()=>lE,(t,n)=>{n(t,{forceMount:!0,child:e,$$slots:{child:!0}})})}B(e,n)},$$slots:{default:!0}})}),B(e,i)},$$slots:{default:!0}}),E(t),fa(1,t,()=>EA,()=>c),B(e,t)};U(u,e=>{L(r)?.unused&&L(r).unused.length>0&&e(d)}),E(t),fa(2,t,()=>UN,()=>({duration:200,delay:L(i)?0:200})),fa(1,t,()=>EA,()=>L(a)?c:{duration:0,y:0}),B(e,t)}),E(f),E(d),E(u),I(()=>Da(u,1,xa([`references`,n()]))),B(e,u),O(l)}q(QN,{class:{}},[],[],{mode:`open`});var $N=R(`<button class="predefined-question transition-colors"><!> </button>`);function eP(e,t){D(t,!0);let n=K(t,`onSubmit`,7),r=K(t,`predefinedQuestion`,7),i=K(t,`index`,7);var a={get onSubmit(){return n()},set onSubmit(e){n(e),k()},get predefinedQuestion(){return r()},set predefinedQuestion(e){r(e),k()},get index(){return i()},set index(e){i(e),k()}},o=$N(),s=N(o);_b(s,{name:`predefinedQuestion`,class:`predefined-question__icon transition-colors`});var c=F(s,1,!0);return E(o),_a(o,(e,t)=>fb?.(e,t),()=>`predefinedQuestion`),I(()=>{G(o,`data-index`,i()),V(c,r().label??r().question)}),ai(`click`,o,()=>n()(r().question,r().id,r().switchQuestionId)),B(e,o),O(a)}oi([`click`]),q(eP,{onSubmit:{},predefinedQuestion:{},index:{}},[],[],{mode:`open`});var tP=R(`<li><!></li>`),nP=R(`<section><h2 class="sr-only"> </h2> <ul></ul></section>`);function rP(e,t){D(t,!0);let n=K(t,`class`,7),r=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`class`]);var i={get class(){return n()},set class(e){n(e),k()}},a=nP();Ja(a,()=>({"aria-label":Z.t.ariaPredefinedQuestionsRegion,class:n(),...r}));var o=N(a),s=N(o,!0);E(o);var c=F(o,2);let l;return Xi(c,21,()=>Z.data.predefinedQuestions,Ki,(e,t,n)=>{var r=tP();eP(N(r),{get predefinedQuestion(){return L(t)},get onSubmit(){return db.onStartConversation},index:n}),E(r),B(e,r)}),E(c),E(a),I(()=>{V(s,Z.t.ariaPredefinedQuestions),l=Da(c,1,`predefined-questions`,null,l,{"predefined-questions--pii-padding":Z.data.questionHasPii})}),B(e,a),O(i)}q(rP,{class:{}},[],[],{mode:`open`});var iP=R(`<div class="introduction-disclaimer text-container fly-in"></div>`),aP=R(`<section><!> <!> <!> <!></section>`);function oP(e,t){D(t,!0);let n=A(()=>Z.t),r=j(!1);$n(()=>{M(r,!0)});let i=A(()=>Z.data.predefinedQuestions&&Z.data.predefinedQuestions.length),a=A(()=>L(i)&&Z.data.chatConfig.forcePredefinedQuestions);var o=aP();let s;var c=N(o);nN(c,{class:`start-page__introduction fly-in`});var l=F(c,2),u=e=>{{let t=A(()=>rl(L(n).introductionTitle||``));HM(e,{get onSubmit(){return db.onStartConversation},class:`start-page__chat-input fly-in`,style:`--fly-in-id: 1;`,get ariaLabel(){return L(t)}})}};U(l,e=>{L(a)||e(u)});var d=F(l,2),f=e=>{{let t=A(()=>L(a)?1:2);rP(e,{class:`start-page__predefined-questions fly-in`,get style(){return`--fly-in-id: ${L(t)??``};`}})}};U(d,e=>{L(i)&&e(f)});var p=F(d,2),m=e=>{var t=iP();na(t,()=>L(n).introductionDisclaimer,!0),E(t),I(()=>ka(t,`--fly-in-id: ${L(a)?2:3};`)),B(e,t)};U(p,e=>{L(n).introductionDisclaimer&&e(m)}),E(o),I(()=>s=Da(o,1,`start-page container`,null,s,{mounted:L(r)})),B(e,o),O()}q(oP,{},[],[],{mode:`open`});var sP=RegExp(`([\\p{Ll}\\d])(\\p{Lu})`,`gu`),cP=RegExp(`(\\p{Lu})([\\p{Lu}][\\p{Ll}])`,`gu`),lP=RegExp(`(\\d)(\\p{Ll})`,`gu`),uP=RegExp(`(\\p{L})(\\d)`,`gu`),dP=/[^\p{L}\d]+/giu,fP=`$1\0$2`,pP=``;function mP(e,t){let n=e.trim();n=n.replace(sP,fP).replace(cP,fP),t?.separateNumbers&&(n=n.replace(lP,fP).replace(uP,fP)),n=n.replace(dP,`\0`);let r=0,i=n.length;for(;n.charAt(r)===`\0`;)r++;if(r===i)return[];for(;n.charAt(i-1)===`\0`;)i--;return n.slice(r,i).split(/\0/g)}function hP(e,t){return AP(e,t?.prefixCharacters)+mP(e,t).map(EP(t?.locale)).join(t?.delimiter??` `)}function gP(e,t){let n=AP(e,t?.prefixCharacters),r=EP(t?.locale),i=DP(t?.locale),a=t?.mergeAmbiguousCharacters?OP(r,i):kP(r,i);return n+mP(e,t).map((e,t)=>t===0?r(e):a(e,t)).join(t?.delimiter??``)}function _P(e,t){let n=AP(e,t?.prefixCharacters),r=EP(t?.locale),i=DP(t?.locale),a=t?.mergeAmbiguousCharacters?OP(r,i):kP(r,i);return n+mP(e,t).map(a).join(t?.delimiter??``)}function vP(e,t){let n=AP(e,t?.prefixCharacters),r=EP(t?.locale),i=DP(t?.locale);return n+mP(e,t).map(OP(r,i)).join(t?.delimiter??` `)}function yP(e,t){return AP(e,t?.prefixCharacters)+mP(e,t).map(DP(t?.locale)).join(t?.delimiter??`_`)}function bP(e,t){return hP(e,{delimiter:`.`,...t})}function xP(e,t){return hP(e,{delimiter:`-`,...t})}function SP(e,t){return hP(e,{delimiter:`/`,...t})}function CP(e,t){let n=AP(e,t?.prefixCharacters),r=EP(t?.locale),i=OP(r,DP(t?.locale));return n+mP(e,t).map((e,t)=>t===0?i(e):r(e)).join(t?.delimiter??` `)}function wP(e,t){return hP(e,{delimiter:`_`,...t})}function TP(e,t){return vP(e,{delimiter:`-`,...t})}function EP(e){return e===!1?e=>e.toLowerCase():t=>t.toLocaleLowerCase(e)}function DP(e){return e===!1?e=>e.toUpperCase():t=>t.toLocaleUpperCase(e)}function OP(e,t){return n=>`${t(n[0])}${e(n.slice(1))}`}function kP(e,t){return(n,r)=>{let i=n[0];return(r>0&&i>=`0`&&i<=`9`?`_`+i:t(i))+e(n.slice(1))}}function AP(e,t=pP){let n=``;for(let r=0;r<e.length;r++){let i=e.charAt(r);if(t.includes(i))n+=i;else break}return n}function jP(e,t){let n=``;for(let r of e)n+=Math.random()>.5?r.toLocaleUpperCase(t):r.toLocaleLowerCase(t);return n}function MP(e,t){let n=``;for(let r of e){let e=r.toLocaleLowerCase(t);n+=r===e?r.toLocaleUpperCase(t):e}return n}var NP=/\b(?:an?d?|a[st]|because|but|by|en|for|i[fn]|neither|nor|o[fnr]|only|over|per|so|some|tha[tn]|the|to|up|upon|vs?\.?|versus|via|when|with|without|yet)\b/i,PP=/[^\s:–—-]+|./g,FP=/\s/,IP=/.(?=[A-Z]|\..)/,LP=/[A-Za-z0-9\u00C0-\u00FF]/;function RP(e){for(var t=``,n;(n=PP.exec(e))!==null;){var r=n[0],i=n.index;if(!IP.test(r)&&(!NP.test(r)||i===0||i+r.length===e.length)&&(e.charAt(i+r.length)!==`:`||FP.test(e.charAt(i+r.length+1)))){t+=r.replace(LP,function(e){return e.toUpperCase()});continue}t+=r}return t}var zP=gP,BP=vP,VP=yP,HP=bP,UP=hP,WP=_P,GP=SP,KP=CP,qP=wP,JP=TP,YP=xP,XP=jP,ZP=MP,QP=RP,$P=e=>e.toUpperCase(),eF=(e,t)=>e.toLocaleUpperCase(t),tF=e=>e.toLowerCase(),nF=(e,t)=>e.toLocaleLowerCase(t),rF=e=>e.charAt(0).toLowerCase()+e.slice(1),iF=e=>e.charAt(0).toUpperCase()+e.slice(1),aF=e=>e===e.toUpperCase(),oF=e=>e===e.toLowerCase(),sF=class{};sF.camel=zP,sF.capital=BP,sF.constant=VP,sF.dot=HP,sF.kebab=YP,sF.lower=tF,sF.lowerFirst=rF,sF.localeLower=nF,sF.localeUpper=eF,sF.no=UP,sF.pascal=WP,sF.path=GP,sF.sentence=KP,sF.snake=qP,sF.sponge=XP,sF.swap=ZP,sF.title=QP,sF.train=JP,sF.upper=$P,sF.upperFirst=iF,sF.isUpper=aF,sF.isLower=oF;var cF=640,lF=1024,uF=null,dF=()=>{if(uF)return uF;if(!globalThis.document)return 16;let e=globalThis.document.querySelector(`:root`);return uF=Number(getComputedStyle(e).fontSize.slice(0,-2)),uF},fF=({minRem:e,maxRem:t})=>{let n=dF(),r=cF/n,i=lF/n,a=(t-e)/(i-r);return`clamp( ${e}rem, ${-r*a+e}rem + ${a*100}cqw, ${t}rem )`},pF=e=>typeof e==`string`?e:typeof e==`number`?String(e):typeof e==`object`?e.minRem===e.maxRem?`${e.minRem}rem`:fF(e):``,mF=(e,t,n,r=!1)=>{let i=``;return n.forEach(n=>{let a=t[n];r&&!a&&n===`borderWidth`&&(a=`0px`),r&&!a&&n===`borderColor`&&(a=`transparent`),a&&(i+=`--${YP(e)}-${YP(n)}:${pF(a)}; `)}),i},hF=(e,t)=>Object.entries(t).map(([t,n])=>`--${e}-${YP(t)}:${pF(n)}`).join(`; `)+`; `,gF=(e,t)=>{let n=``;return n+=mF(e,t,[`background`,`borderWidth`,`borderColor`,`boxShadow`,`borderRadius`,`color`],!0),t.hover&&(n+=mF(`${e}-hover`,t.hover,[`background`,`borderWidth`,`borderColor`,`boxShadow`,`color`])),t.focus&&(n+=mF(`${e}-focus`,t.focus,[`background`,`borderWidth`,`borderColor`,`boxShadow`,`color`])),t.custom&&(n+=hF(e,t.custom)),n},_F=(e,t)=>Object.entries(t).map(([t,n])=>`--color-${e}-${t}:${n}`).join(`; `)+`; `,vF=e=>`--font-family: ${e?.family||`inherit`};`,yF=(e,t={})=>`${t.root??`.chat-app`} {${vF(e.font)} ${Object.entries(e.colors).map(([e,t])=>_F(e,t)).join(``)} ${hF(`base`,e.base)} ${Object.entries(e.components).map(([e,t])=>gF(YP(e),t)).join(``)}};`;function bF(e,t){D(t,!0);let n=K(t,`css`,7),r=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`css`]),i=e=>{$n(()=>{n()&&(e.innerHTML=n())})};var a={get css(){return n()},set css(e){n(e),k()}},o=z(),s=P(o),c=e=>{var t=z();ma(P(t),()=>`style`,!1,(e,t)=>{_a(e,e=>i?.(e)),Ja(e,()=>({...r}))}),B(e,t)};return U(s,e=>{n()&&e(c)}),B(e,o),O(a)}q(bF,{css:{}},[],[],{mode:`open`});var xF=`@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;tab-size:4;font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent;font-family:ui-sans-serif,system-ui,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;line-height:1.5}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-feature-settings:normal;font-variation-settings:normal;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab, red, red)){::placeholder{color:color-mix(in oklab, currentcolor 50%, transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){appearance:button}::file-selector-button{appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}.chat-app{--spacer-1:.0625rem;--spacer-2:.125rem;--spacer-3:.1875rem;--spacer-4:.25rem;--spacer-5:.3125rem;--spacer-6:.375rem;--spacer-8:.5rem;--spacer-10:.625rem;--spacer-12:.75rem;--spacer-16:1rem;--spacer-20:1.25rem;--spacer-24:1.5rem;--spacer-28:1.75rem;--spacer-32:2rem;--spacer-40:2.5rem;--spacer-48:3rem;--spacer-56:3.5rem;--spacer-64:4rem;--spacer-72:4.5rem;--spacer-80:5rem;--spacer-120:7.5rem;--spacer-r-8:clamp(.375rem, .3182rem + .2841cqw, .5rem);--spacer-r-12:clamp(.625rem, .5682rem + .2841cqw, .75rem);--spacer-r-16:clamp(.75rem, .6364rem + .5682cqw, 1rem);--spacer-r-20:clamp(.875rem, .7045rem + .8523cqw, 1.25rem);--spacer-r-24:clamp(1rem, .7727rem + 1.1364cqw, 1.5rem);--spacer-r-28:clamp(1.125rem, .8409rem + 1.4205cqw, 1.75rem);--spacer-r-32:clamp(1.25rem, .9091rem + 1.7045cqw, 2rem);--spacer-r-40:clamp(1.5rem, 1.0455rem + 2.2727cqw, 2.5rem);--spacer-r-48:clamp(1.625rem, 1rem + 3.125cqw, 3rem);--spacer-r-56:clamp(1.75rem, .9545rem + 3.9773cqw, 3.5rem);--spacer-r-64:clamp(2rem, 1.0909rem + 4.5455cqw, 4rem);--spacer-r-80:clamp(3rem, 2.0909rem + 4.5455cqw, 5rem);--spacer-r-96:clamp(3.5rem, 2.3636rem + 5.6818cqw, 6rem);--spacer-r-120:clamp(4rem, 2.4091rem + 7.9545cqw, 7.5rem);--default-transition-duration:.2s;--default-transition-timing-function:ease-in-out;--z-index-flyout:10000;--z-index-dialog:600;--z-index-loader:500;--z-index-reference-number:400;--z-index-footer:300;--z-index-header:200;--z-index-tooltip:100;--z-index-tooltip-hover:101;--z-index-local-overlay:10;--z-index-below:-10;--ease-out-quart:cubic-bezier(.165, .84, .44, 1);--ease-in-quart:cubic-bezier(.895, .03, .685, .22);--ease-in-out-quart:cubic-bezier(.77, 0, .175, 1);--fly-in-id:0;--btn-padding-x:var(--spacer-r-20);--btn-padding-y:var(--spacer-r-8);--btn-icon-size:var(--spacer-24);--btn-submit-size:2.5em;--last-bot-message-min-height:0}.chat-app :where(h1,.h1,h2,.h2,h3,.h3,h4,.h4,h5,.h5,h6,.h6){font-weight:var(--base-font-weight-title);line-height:var(--base-line-height-tight)}.chat-app :where(b,strong){font-weight:var(--base-font-weight-bold)}.chat-app :where(button){cursor:pointer}.chat-app :where(input[type=text],input[type=email],input[type=search],input[type=password],textarea,select){width:100%;padding:var(--input-padding);border-width:var(--input-border-width);border-radius:var(--input-border-radius);border-color:var(--input-border-color);background:var(--input-background);box-shadow:var(--input-box-shadow,none);color:var(--input-color)}.chat-app :where(input[type=text],input[type=email],input[type=search],input[type=password],textarea,select)::placeholder{color:var(--input-placeholder-color);opacity:var(--input-placeholder-opacity)}.chat-app :where(input[type=radio],input[type=checkbox]){margin:0}.chat-app :where(:focus-visible){border-radius:var(--btn-primary-border-radius);outline-color:var(--body-focus-color);outline-style:var(--body-focus-style);outline-width:var(--body-focus-width);outline-offset:var(--body-focus-offset)}.chat-app ::selection{background:var(--body-selection-background);color:var(--body-selection-color)}.chat-app ::-webkit-scrollbar{width:8px;height:8px}.chat-app ::-webkit-scrollbar-track{background:0 0}.chat-app ::-webkit-scrollbar-thumb{background-color:#0000004d;border-radius:4px;transition:background-color .2s}.chat-app ::-webkit-scrollbar-thumb:hover{background-color:#00000080}.chat-app *{scrollbar-color:#0000004d transparent;scrollbar-width:thin}.chat-app ::-webkit-scrollbar-thumb{visibility:hidden}.chat-app :hover::-webkit-scrollbar-thumb{visibility:visible}.chat-app :active::-webkit-scrollbar-thumb{visibility:visible}.chat-app :focus::-webkit-scrollbar-thumb{visibility:visible}.svg{width:var(--spacer-r-24);height:auto}.svg svg{width:100%;height:auto;display:block;overflow:visible}.toast{width:100%;padding:var(--spacer-r-20);align-items:center;gap:var(--spacer-16);border-width:var(--toast-border-width,1px);border-radius:var(--toast-border-radius);border-color:var(--toast-border-color,transparent);background:var(--toast-background);box-shadow:var(--toast-box-shadow);color:var(--toast-color);display:flex}.toast[data-type=success] svg{color:var(--toast-icon-success-color)}.toast[data-type=error] svg{color:var(--toast-icon-error-color)}.toast[data-type=warning] svg{color:var(--toast-icon-warning-color)}.toast[data-type=info] svg{color:var(--toast-icon-info-color)}.toast svg{width:var(--spacer-24)!important;height:var(--spacer-24)!important}ol[data-sonner-toaster=true]{border:var(--spacer-16) solid transparent;max-width:600px;width:100%!important}}@layer utilities{.chat-app :where(.expand-interaction){position:relative}.chat-app :where(.expand-interaction):after{content:"";background-color:#0000;position:absolute;inset:0}.chat-app :where(.sr-only){clip:rect(0, 0, 0, 0);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.chat-app :where(.transition-colors){transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color,box-shadow;transition-timing-function:var(--default-transition-timing-function)}.chat-app :where(.transition){transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter;transition-timing-function:var(--default-transition-timing-function)}.chat-app :where(.skip-link){width:0;height:0;color:var(--anchor-color);font-weight:700;font-size:var(--base-font-size-xs);position:absolute;overflow:hidden}.chat-app :where(.skip-link):focus-visible{width:auto;height:auto;position:static}.chat-app :where(.fly-in){--fly-in-id:0;--fly-in-duration:.4s;--fly-out-duration:.2s;--fly-in-delay:.3s;--fly-in-delay-additional:.1s;--fly-in-y:var(--spacer-r-64);transform:translateY(var(--fly-in-y));opacity:0;transition-delay:0s,1s;transition-duration:var(--fly-out-duration);transition-property:opacity,transform;transition-timing-function:ease, var(--ease-out-quart)}.chat-app :where(.mounted .fly-in){opacity:1;transition-delay:calc(var(--fly-in-delay) + var(--fly-in-id) * var(--fly-in-delay-additional));transition-duration:var(--fly-in-duration);transform:translateY(0)}.chat-app :where(.truncate){text-overflow:ellipsis;white-space:nowrap;display:inline-block;overflow:hidden}.chat-app :where(.line-clamp){-webkit-line-clamp:1;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.chat-app :where(.line-clamp--2){-webkit-line-clamp:2}.chat-app :where(.line-clamp--6){-webkit-line-clamp:6}.chat-app :where(.container){width:100%;max-width:var(--container-max-width,1024px);padding-right:var(--spacer-16);padding-left:var(--spacer-16);margin:0 auto}@container chat-container (width>=640px){.chat-app :where(.container){padding-right:var(--spacer-32);padding-left:var(--spacer-32)}}@container chat-container (width>=768px){.chat-app :where(.container){padding-right:var(--spacer-48);padding-left:var(--spacer-48)}}.chat-app :where(h1){font-size:var(--base-font-size-h1)}.chat-app :where(h2){font-size:var(--base-font-size-h2)}.chat-app :where(h3){font-size:var(--base-font-size-h3)}.chat-app :where(h4,h5,h6){font-size:var(--body-font-size)}.chat-app :where(.h1){font-size:var(--base-font-size-h1)}.chat-app :where(.h2){font-size:var(--base-font-size-h2)}.chat-app :where(.h3){font-size:var(--base-font-size-h3)}.chat-app :where(.h4,.h5,.h6){font-size:var(--body-font-size)}.chat-app :where(.text-container)>:where(p,ul,ol,img,table){margin-bottom:var(--spacer-r-24);display:block}.chat-app :where(.text-container)>:where(div){margin:var(--spacer-r-40) 0}.chat-app :where(.text-container)>:where(h1,.h1){margin-bottom:var(--spacer-r-28)}.chat-app :where(.text-container)>:where(h2,.h2,h3,.h3,h4,.h4,h5,.h5,h6,.h6){margin-bottom:var(--spacer-r-20)}.chat-app :where(.text-container)>:where(h1,.h1,h2,.h2,h3,.h3,h4,.h4,h5,.h5,h6,.h6){margin-top:var(--spacer-r-40)}.chat-app :where(.text-container)>:where(ul:not(.no-list-styling),ol:not(.no-list-styling))>:where(li){margin-bottom:var(--spacer-12)}.chat-app :where(.text-container)>:where(ul:not(.no-list-styling),ol:not(.no-list-styling))>:where(li):last-child{margin-bottom:0}.chat-app :where(.text-container)>:where(ol){padding-left:1.5em;list-style-type:decimal;list-style-position:outside}.chat-app :where(.text-container)>:where(ul:not(.no-list-styling))>:where(li){padding-left:1em;position:relative}.chat-app :where(.text-container)>:where(ul:not(.no-list-styling))>:where(li):before{content:"•";font-size:.9em;position:absolute;top:0;left:0}.chat-app :where(.text-container)>:where(hr){height:1px;margin:var(--spacer-r-40) 0;background-color:var(--color-grey-700);background-color:var(--hr-color);border:none}.chat-app :where(.text-container) :where(a:not(.button,.no-link-styling,.reference)){color:var(--anchor-color);font-weight:var(--anchor-font-weight,var(--base-font-weight-normal));-webkit-text-decoration:var(--anchor-text-decoration,underline);text-decoration:var(--anchor-text-decoration,underline);text-underline-offset:var(--anchor-text-underline-offset,.15em);transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color;transition-timing-function:var(--default-transition-timing-function)}.chat-app :where(.text-container) :where(a:not(.button,.no-link-styling,.reference)):hover{color:var(--anchor-hover-color)}.chat-app :where(.text-container) :where(table){border-collapse:collapse;border-spacing:0;-webkit-overflow-scrolling:touch;width:100%;display:block;overflow-x:auto}.chat-app :where(.text-container) :where(th){width:1000px;padding:var(--spacer-12) var(--spacer-16) var(--spacer-12) 0;border-bottom:1px solid var(--color-grey-300);line-height:var(--base-line-height-tight);text-align:left;vertical-align:bottom}.chat-app :where(.text-container) :where(td){padding:var(--spacer-12) var(--spacer-16) var(--spacer-12) 0;border-bottom:1px solid var(--color-grey-300);vertical-align:top}.chat-app :where(.text-container) :where(tr:last-child td){border-bottom:none}.chat-app :where(.text-container) :where(:first-child){margin-top:0}.chat-app :where(.text-container) :where(:last-child){margin-bottom:0}.chat-app :where(.animated-height){transition:height .5s var(--ease-in-out-quart)}.chat-app :where(.display-contents){display:contents}.chat-app :where(.absolute){position:absolute!important}}@layer components{.btn{min-height:calc(var(--btn-padding-y) * 2 + var(--btn-icon-size));padding:var(--btn-padding-y) var(--btn-padding-x);align-items:center;gap:var(--spacer-r-8);font-size:var(--base-font-size-sm);line-height:var(--base-line-height-tight);text-align:left;transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color,text-decoration-color,box-shadow,transform,translate,opacity;transition-timing-function:var(--default-transition-timing-function);border-style:solid;flex-wrap:nowrap;text-decoration:none;display:flex;position:relative}.btn>:where(.svg){width:var(--btn-icon-size)}.btn:disabled{cursor:not-allowed;opacity:.5;pointer-events:none}.btn--primary{border-width:var(--btn-primary-border-width);border-radius:var(--btn-primary-border-radius);border-color:var(--btn-primary-border-color);background:var(--btn-primary-background);box-shadow:var(--btn-primary-box-shadow);color:var(--btn-primary-color);font-weight:var(--btn-primary-font-weight,700)}.btn--primary:hover{border-width:var(--btn-primary-hover-border-width,var(--btn-primary-border-width));border-color:var(--btn-primary-hover-border-color,var(--btn-primary-border-color));background:var(--btn-primary-hover-background,var(--btn-primary-background));box-shadow:var(--btn-primary-hover-box-shadow,var(--btn-primary-box-shadow));color:var(--btn-primary-hover-color,var(--btn-primary-color))}.btn--secondary{border-width:var(--btn-secondary-border-width);border-radius:var(--btn-secondary-border-radius,var(--btn-primary-border-radius));border-color:var(--btn-secondary-border-color);background:var(--btn-secondary-background);box-shadow:var(--btn-secondary-box-shadow);color:var(--btn-secondary-color);font-weight:var(--btn-secondary-font-weight,700)}.btn--secondary:hover{border-width:var(--btn-secondary-hover-border-width,var(--btn-secondary-border-width));border-color:var(--btn-secondary-hover-border-color,var(--btn-secondary-border-color));background:var(--btn-secondary-hover-background,var(--btn-secondary-background));box-shadow:var(--btn-secondary-hover-box-shadow,var(--btn-secondary-box-shadow));color:var(--btn-secondary-hover-color,var(--btn-secondary-color))}.btn--tertiary{border-width:var(--btn-tertiary-border-width);border-radius:var(--btn-tertiary-border-radius,var(--btn-primary-border-radius));border-color:var(--btn-tertiary-border-color);background:var(--btn-tertiary-background);box-shadow:var(--btn-tertiary-box-shadow);color:var(--btn-tertiary-color);font-weight:var(--btn-tertiary-font-weight,700)}.btn--tertiary:hover{border-width:var(--btn-tertiary-hover-border-width,var(--btn-tertiary-border-width));border-color:var(--btn-tertiary-hover-border-color,var(--btn-tertiary-border-color));background:var(--btn-tertiary-hover-background,var(--btn-tertiary-background));box-shadow:var(--btn-tertiary-hover-box-shadow,var(--btn-tertiary-box-shadow));color:var(--btn-tertiary-hover-color,var(--btn-tertiary-color))}.btn--square{--btn-padding-x:var(--btn-padding-y)}.btn--square:after{z-index:var(--z-index-local-overlay);content:"";background:0 0;position:absolute;inset:-.5em}.btn--square>:where(.svg){width:var(--btn-icon-size)}.btn--square>:where(.btn__label){padding-right:calc(var(--btn-padding-x) * 1.25);display:none}@container chat-container (width>=640px){.btn--square>:where(.btn__label){display:block}}.form__caption{margin-bottom:var(--spacer-32)}.form__fields{gap:var(--spacer-16);flex-direction:column;width:100%;display:flex}.form__item{gap:var(--spacer-5);flex-direction:column;width:100%;display:flex}.form__label{color:var(--label-color,inherit);font-weight:var(--label-font-weight,inherit);font-size:var(--base-font-size-sm)}.form__options{margin-top:var(--spacer-r-8);flex-direction:column;display:flex}.form__option{align-items:baseline;gap:var(--spacer-r-12);cursor:pointer;display:inline-flex}.form__option .form__option-input{clip:rect(0 0 0 0);white-space:nowrap;clip-path:inset(50%);border:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.form__option:has(.form__option-input:focus-visible) :where(.radio,.checkbox){outline-color:var(--body-focus-color);outline-style:var(--body-focus-style);outline-width:var(--body-focus-width);outline-offset:var(--body-focus-offset)}.form__select{width:100%;position:relative}.form__select select{appearance:none;padding-right:var(--spacer-56)}.form__select-arrow{top:50%;right:var(--spacer-r-20);width:var(--spacer-r-24);height:var(--spacer-r-24);color:var(--anchor-color);pointer-events:none;position:absolute;transform:translateY(-50%)}.form__footer{margin-top:var(--spacer-40)}.chat-app{display:contents}.chat-app__container{height:100%;display:flex;overflow:hidden;transform:translateZ(0);container:chat-container/inline-size}.chat-app__container>:where(*){color:var(--body-color);font-style:normal;font-weight:var(--base-font-weight-normal);font-size:var(--base-font-size-body);line-height:var(--base-line-height-default);font-family:var(--font-family);font-optical-sizing:auto}.chat-app__container.chat-app__container--inline-layout-contained{height:90svh;scroll-margin-top:10svh}@media (width>=768px){.chat-app__container.chat-app__container--inline-layout-contained{height:100svh;scroll-margin-top:0}}.chat-app__main{overscroll-behavior-x:none;overscroll-behavior-y:contain;background:var(--body-background);scrollbar-gutter:stable;touch-action:pan-y;flex-direction:column;width:100%;height:100%;display:flex;overflow:hidden auto;container:chat-inner-container/inline-size}.chat-app__container--inline-layout .chat-app__main{overscroll-behavior-y:auto}.chat-app__loader-container{z-index:var(--z-index-loader);justify-content:center;align-items:center;width:100%;height:100%;display:flex;position:relative}.chat-app__portals{display:contents}.chat-app__header{z-index:var(--z-index-header);background:var(--body-background);position:sticky;top:0}.chat-app__header--unsticked{position:relative}.chat-app__header-content{--btn-padding-x:var(--btn-padding-y);column-gap:var(--spacer-r-12);min-height:calc(var(--btn-padding-y) * 2 + var(--btn-icon-size) + var(--spacer-10) * 2);margin-right:calc(var(--btn-padding-x) * -1);margin-left:calc(var(--btn-padding-x) * -1);padding-top:var(--spacer-10);padding-bottom:var(--spacer-10);flex-wrap:wrap;justify-content:flex-end;align-items:center;display:flex;position:relative}.chat-app__header-content>:where(*){z-index:0;pointer-events:auto;position:relative}.chat-app__header-content:after{right:var(--btn-padding-x);bottom:0;left:var(--btn-padding-x);content:"";border-bottom:1px solid #0000;transition:border-color .1s ease-in-out;position:absolute}.chat-app__header-content.has-border:after{border-color:var(--base-line-color)}.chat-app__header-new-conversation{margin-right:auto;position:relative}@container chat-container (width>=640px){.chat-app__header-new-conversation .tooltip{display:none}}.chat-app__header--with-logo :where(.chat-app__header-content){margin-left:0}.chat-app__header--with-logo :where(.chat-app__header-new-conversation){margin-right:unset;margin-left:auto}.chat-app__header-logo{margin-right:auto}.chat-app__header-logo :where(svg){width:auto;height:var(--spacer-28)}.chat-app__body{flex-direction:column;flex-grow:1;width:100%;display:flex;position:relative}.chat-app__page-transition{flex-direction:column;flex-grow:1;width:100%;height:100%;display:flex}.chat-app__aside{--duration-in:.65s;--duration-out:.5s;visibility:hidden;width:0;transition-delay:0s, var(--duration-out);transition-duration:var(--duration-out), 0s;transition-property:width,visibility;transition-timing-function:var(--ease-in-out-quart), linear;flex-grow:1;position:relative;top:0;bottom:0}.chat-app__aside.open{visibility:visible;width:var(--aside-width);transition-delay:0s;transition-duration:var(--duration-in), 0s;transition-timing-function:var(--ease-out-quart), linear}.chat-app__aside .tooltip{--background-color:var(--btn-secondary-hover-background)}.chat-app__aside-container{width:var(--aside-width);overscroll-behavior:contain;border-left-width:var(--aside-border-width);border-color:var(--aside-border-color);background:var(--aside-background);scrollbar-gutter:stable;height:100%;position:relative;overflow-y:auto}.chat-app__container--inline-layout .chat-app__aside-container{overscroll-behavior-y:auto}.chat-app__aside-header,.chat-app__sheet-header{z-index:var(--z-index-header);flex-wrap:no-wrap;padding:var(--spacer-12) var(--spacer-12) var(--spacer-12) var(--spacer-24);justify-content:space-between;align-items:center;gap:var(--spacer-24);border-bottom-width:var(--aside-header-border-width);border-color:var(--aside-header-border-color);background:var(--aside-background);color:var(--aside-header-color);display:flex;position:sticky;top:0}.chat-app__sheet-close{position:relative}.chat-app__sheet-overlay{z-index:var(--z-index-dialog);background:var(--aside-background-overlay);position:fixed;inset:0}.chat-app__sheet-content{z-index:var(--z-index-flyout);width:100%;max-width:var(--aside-width);overscroll-behavior:contain;border-left-width:var(--aside-border-width);border-color:var(--aside-border-color);background:var(--aside-background);scrollbar-gutter:stable;height:100%;position:fixed;top:0;right:0;overflow-y:auto}.chat-app__container--inline-layout .chat-app__sheet-content{overscroll-behavior-y:auto}:is(.chat-app__aside-close,.chat-app__sheet-close) :where(.btn){background-color:#0000}.chat-app__aside-title,.chat-app__sheet-title{font-size:var(--base-font-size-sm)}.chat-app__close-button{z-index:var(--z-index-flyout)}.chat-input{--chat-input-padding:calc(.5em + var(--chat-input-border-width));--chat-input-settings-transition-duration:.2s;--chat-input-disabling-transition-duration:.2s}@container chat-container (width>=640px){.chat-input{--chat-input-padding:calc(.75em + var(--chat-input-border-width))}}.chat-input{z-index:var(--z-index-local-overlay);position:relative}.chat-input__textarea{box-sizing:border-box;width:100%;max-height:6lh;padding:1em var(--spacer-64) 1em calc(var(--spacer-r-24) - var(--chat-input-border-width));color:var(--chat-input-color);resize:none;transition:padding var(--chat-input-settings-transition-duration) var(--default-transition-timing-function);background:0 0;border:0 solid #0000;grid-area:textarea;display:block}.chat-input__textarea:has(+.chat-input__buttons .chat-input__mic-button){padding-right:calc(2.5em + var(--spacer-64))}.chat-input__grid--has-settings .chat-input__textarea{padding-left:var(--spacer-8)}.chat-input__grid--settings-is-open .chat-input__textarea{padding-right:var(--spacer-r-16);padding-left:var(--spacer-r-16)}@container chat-container (width>=640px){.chat-input__textarea{padding:1.25em var(--spacer-80) 1.25em calc(var(--spacer-r-28) - var(--chat-input-border-width))}.chat-input__grid--has-settings .chat-input__textarea{padding-left:var(--spacer-8)}.chat-input__grid--settings-is-open .chat-input__textarea{padding-right:var(--spacer-r-28);padding-left:var(--spacer-r-28)}}.chat-input__textarea:focus,.chat-input__textarea:focus-visible{outline-color:#0000}.chat-input__grid{--disabled-translateY:var(--spacer-20);border-width:var(--chat-input-border-width);border-radius:var(--chat-input-border-radius);border-style:solid;border-color:var(--chat-input-border-color);background:var(--chat-input-background);box-shadow:var(--chat-input-box-shadow);transition:grid-template-rows var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), grid-template-columns var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), background var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), box-shadow var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), border-color var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), outline-color var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), border-radius var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), color var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), opacity var(--chat-input-disabling-transition-duration) var(--default-transition-timing-function), transform var(--chat-input-disabling-transition-duration) var(--default-transition-timing-function);display:flex}.chat-input__grid:has(.chat-input__textarea:focus-visible){border-width:var(--chat-input-focus-border-width,var(--chat-input-border-width));border-radius:var(--chat-input-focus-border-radius,var(--chat-input-border-radius));border-color:var(--chat-input-focus-border-color,var(--chat-input-border-color));background:var(--chat-input-focus-background,var(--chat-input-background));box-shadow:var(--chat-input-focus-box-shadow,var(--chat-input-box-shadow));color:var(--chat-input-focus-color,var(--chat-input-color));outline-color:#0000}.chat-input__grid:hover{background:var(--chat-input-hover-background,var(--chat-input-background));box-shadow:var(--chat-input-hover-box-shadow,var(--chat-input-box-shadow))}.chat-input--disabled .chat-input__grid{transform:translateY(var(--disabled-translateY));opacity:0}.chat-input__grid--has-settings{--chat-input-settings-height:0px;grid-template-rows:1fr var(--chat-input-settings-height);grid-template-columns:var(--btn-submit-size) 1fr;grid-template-areas:"toggle textarea"".settings";width:100%;display:grid}@container chat-container (width>=640px){.chat-input__grid--has-settings{grid-template-columns:calc(var(--btn-submit-size) + var(--spacer-r-12)) 1fr}}.chat-input__grid--settings-is-open{grid-template-columns:0 1fr}.chat-input__submit-button,.chat-input__abort-button{--margin:.5em}.chat-input__open-settings-button{margin-left:var(--spacer-r-12)}.chat-input__buttons{right:var(--chat-input-padding);bottom:var(--chat-input-padding);pointer-events:none;align-items:center;gap:.5em;display:flex;position:absolute}.chat-input__buttons>*{pointer-events:auto}.chat-input__submit-button{width:var(--btn-submit-size);height:var(--btn-submit-size);border-width:var(--chat-input-submit-border-width,0px);border-radius:var(--chat-input-submit-border-radius);border-color:var(--chat-input-submit-border-color);background:var(--chat-input-submit-background);box-shadow:var(--chat-input-submit-box-shadow);color:var(--chat-input-submit-color);cursor:pointer;justify-content:center;align-items:center;transition-property:opacity,background-color,transform;transition-duration:.2s,.2s,.35s;transition-timing-function:ease;display:flex}.chat-input__submit-button:hover{border-width:var(--chat-input-submit-hover-border-width,var(--chat-input-submit-border-width));border-radius:var(--chat-input-submit-hover-border-radius,var(--chat-input-submit-border-radius));border-color:var(--chat-input-submit-hover-border-color,var(--chat-input-submit-border-color));background:var(--chat-input-submit-hover-background,var(--chat-input-submit-background));box-shadow:var(--chat-input-submit-hover-box-shadow,var(--chat-input-submit-box-shadow));color:var(--chat-input-submit-hover-color,var(--chat-input-submit-color))}.chat-input__submit-button path{stroke:currentColor;stroke-width:var(--chat-input-submit-stroke-width,1.5px)}@container chat-container (width>=640px){.chat-input__submit-button{--margin:.75em}}.chat-input__submit-button--deactivated{transform:scale(var(--chat-input-submit-deactivated-scale,.8));border-color:var(--chat-input-submit-deactivated-border-color,var(--chat-input-submit-border-color));background:var(--chat-input-submit-deactivated-background,var(--chat-input-submit-background));color:var(--chat-input-submit-deactivated-color,var(--chat-input-submit-color));cursor:not-allowed;opacity:var(--chat-input-submit-deactivated-opacity,.5)}.chat-input__submit-button--deactivated:hover{border-color:var(--chat-input-submit-deactivated-border-color,var(--chat-input-submit-border-color));background:var(--chat-input-submit-deactivated-background,var(--chat-input-submit-background));color:var(--chat-input-submit-deactivated-color,var(--chat-input-submit-color))}.chat-input__submit-icon,.chat-input__abort-icon{width:var(--spacer-20);height:var(--spacer-20);pointer-events:none}.chat-input__notification-wrapper{border-radius:var(--chat-input-notification-border-radius);position:relative;overflow:hidden}.chat-input__notification-animation-element{padding-bottom:var(--spacer-2)}.chat-input__notification{padding:var(--spacer-8);gap:var(--spacer-8);border-width:var(--chat-input-notification-border-width);border-radius:var(--chat-input-notification-border-radius);border-color:var(--chat-input-notification-border-color);background:var(--chat-input-notification-background);box-shadow:var(--chat-input-notification-box-shadow);color:var(--chat-input-notification-color);display:flex}.chat-input__notification-label{font-weight:700;font-size:var(--base-font-size-xs);padding-top:.175em;line-height:1.35}@container chat-inner-container (width>=640px){.chat-input__notification-label{font-size:var(--base-font-size-sm);padding-top:.125em}}.chat-input__notification-icon{width:var(--spacer-20);height:var(--spacer-20);flex-shrink:0}@container chat-inner-container (width>=640px){.chat-input__notification-icon{width:var(--spacer-24);height:var(--spacer-24)}}.chat-input__mic-button{border-radius:var(--chat-input-submit-border-radius);cursor:pointer;--mic-base-color:var(--color-grey-500);--mic-accent-color:var(--color-accent-500);background:0 0;border:none;justify-content:center;align-items:center;width:2.5em;height:2.5em;transition-property:background-color,color;transition-duration:.2s;transition-timing-function:ease;display:flex}.chat-input__mic-button:hover{background-color:var(--color-grey-100);--mic-base-color:var(--color-grey-700);--mic-accent-color:var(--color-accent-600)}.chat-input__mic-button--listening{background-color:var(--chat-input-notification-background);box-shadow:var(--chat-input-submit-box-shadow);--mic-base-color:#fff6;--mic-accent-color:white}.chat-input__mic-button--listening:hover{background-color:var(--color-highlight-600)}.chat-input__mic-button--error{color:var(--color-highlight-600)}.chat-input__settings{width:100%;padding:var(--chat-input-padding) var(--spacer-80) var(--chat-input-padding) var(--spacer-r-12);gap:var(--spacer-8);pointer-events:none;grid-area:settings;display:flex;position:absolute;bottom:0;left:0;overflow:hidden}@container chat-container (width>=640px){.chat-input__settings{padding-left:var(--spacer-r-20)}}.chat-input__grid--settings-is-open .chat-input__settings{pointer-events:auto;overflow:visible}.chat-input__settings-button{min-width:0;height:100%;padding-right:var(--spacer-4);padding-left:var(--spacer-4);transform:translate(calc(var(--spacer-48) * -1), 150%);border-radius:var(--chat-input-submit-border-radius);outline-offset:0;font-size:var(--base-font-size-xs);opacity:0;transition:transform var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), background var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), box-shadow var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), border-color var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), border-radius var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), color var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), opacity var(--chat-input-settings-transition-duration) calc(var(--chat-input-settings-transition-duration) / 3) var(--default-transition-timing-function);flex-shrink:1;flex-basis:auto;gap:3px}@container chat-inner-container (width>=768px){.chat-input__settings-button{padding-right:var(--spacer-12);padding-left:var(--spacer-8)}}.chat-input__settings-button:disabled{transform:translate(calc(var(--spacer-48) * 1), 150%);opacity:0}.chat-input__grid--settings-is-open .chat-input__settings-button{transform:translateX(calc(var(--spacer-4) * -1));opacity:1}.chat-input__settings-button[data-has-error=true]{border-color:var(--chat-input-notification-border-color)!important;background:var(--chat-input-notification-background)!important;color:var(--chat-input-notification-color)!important}@container chat-inner-container (width>=640px){.chat-input__settings-button .tooltip{display:none}}.chat-input__toggle-area{grid-area:toggle;justify-content:center;place-self:center;align-items:center;width:100%;height:100%;display:flex}.chat-input__grid--settings-is-open .chat-input__toggle-area{overflow:hidden}.chat-input__settings-toggle-button{width:var(--btn-submit-size);height:var(--btn-submit-size);margin-left:var(--spacer-r-8);border-radius:var(--chat-input-submit-border-radius);outline-offset:0;opacity:1;transition:transform var(--chat-input-settings-transition-duration) var(--default-transition-timing-function), opacity var(--chat-input-settings-transition-duration) calc(var(--chat-input-settings-transition-duration) / 3) var(--default-transition-timing-function)}.chat-input__grid--settings-is-open .chat-input__settings-toggle-button{opacity:0;transform:translate(-100%)}.chat-input__settings-toggle-button .svg{flex-shrink:0}.chat-input__settings-button-icon:not(.svg--settingsClose){flex-shrink:0;display:block}@container chat-inner-container (width>=640px){.chat-input__settings-button-icon:not(.svg--settingsClose){display:none}}@container chat-inner-container (width>=768px){.chat-input__settings-button-icon:not(.svg--settingsClose){display:block}}.chat-input__settings-button-label{display:none}@container chat-inner-container (width>=640px){.chat-input__settings-button-label{text-overflow:ellipsis;white-space:nowrap;max-width:20ch;display:block;overflow:hidden}}@container chat-inner-container (width>=1024px){.chat-input__settings-button-label{max-width:40ch}}.chat-input__settings-button-label-name{display:none}@container chat-inner-container (width>=1024px){.chat-input__settings-button-label-name{display:inline}}.chat-input__settings-button-chevron{width:var(--spacer-10);height:var(--spacer-10);transition:transform .2s var(--default-transition-timing-function);flex-shrink:0}[data-state=open]>.chat-input__settings-button-chevron{transform:rotate(180deg)}.checkbox{--size:1em;width:var(--size);height:var(--size);border-width:var(--checkbox-border-width);border-radius:var(--checkbox-border-radius);border-color:var(--checkbox-border-color);background:var(--checkbox-background);box-shadow:var(--checkbox-box-shadow);color:var(--checkbox-color);transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color,text-decoration-color,box-shadow,transform,translate,opacity;transition-timing-function:var(--default-transition-timing-function);flex-shrink:0;justify-content:center;align-items:center;display:inline-flex;position:relative;top:.1em}.checkbox[data-checked=true]{border-color:var(--checkbox-checked-border-color);background:var(--checkbox-checked-background);color:var(--checkbox-checked-color)}.checkbox__icon{width:100%;height:100%;color:var(--color-background);opacity:1;transition:opacity .2s}.checkbox[data-checked=false] .checkbox__icon{opacity:0}.classification-feedback{margin-bottom:var(--spacer-16);gap:var(--spacer-16);border-width:var(--message-user-border-width);border-radius:var(--message-user-border-radius);border-color:var(--message-user-border-color);color:var(--message-user-color);flex-direction:column;display:flex}.classification-feedback__item{gap:var(--spacer-4);border:none;flex-direction:column;margin:0;padding:0;display:flex}.classification-feedback__label{margin-bottom:var(--spacer-8)}.classification-feedback__option{padding-left:var(--spacer-16);align-items:center;gap:var(--spacer-12);display:flex}.classification-feedback__option:has(input:checked){background:var(--btn-secondary-hover-background);color:var(--btn-secondary-hover-color)}.classification-feedback__option:has(input:focus-visible){border-radius:var(--spacer-8);outline-color:var(--body-focus-color);outline-style:solid;outline-width:var(--spacer-3)}.classification-feedback__option:has(input:focus-visible) input{outline:none}.radio{--size:1em;width:var(--size);height:var(--size);border-width:var(--radio-border-width);border-color:var(--radio-border-color);background:var(--radio-background);box-shadow:var(--radio-box-shadow);color:var(--radio-color);transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color,text-decoration-color,box-shadow,transform,translate,opacity;transition-timing-function:var(--default-transition-timing-function);border-radius:50%;flex-shrink:0;justify-content:center;align-items:center;display:inline-flex;position:relative;top:.1em}.radio[data-checked=true]{border-color:var(--radio-checked-border-color);background:var(--radio-checked-background);color:var(--radio-checked-color)}.radio__indicator{--size:50%;--scale:0;width:var(--size);height:var(--size);transform:scale(var(--scale)) translate(-50%, -50%);opacity:0;background:currentColor;border-radius:50%;transition:opacity .2s,transform .2s;position:absolute;top:50%;left:50%}.radio[data-checked=true] .radio__indicator{--scale:1;opacity:1}.context-box{z-index:var(--z-index-flyout);position:relative}.context-box__content{--context-box-side-padding:var(--spacer-r-12);z-index:var(--z-index-local-overlay);width:calc(100cqw - var(--spacer-24));border-width:var(--context-box-border-width);border-radius:var(--context-box-border-radius);border-style:solid;border-color:var(--context-box-border-color);background:var(--context-box-background);max-width:300px;box-shadow:var(--context-box-box-shadow);color:var(--context-box-color);font-size:var(--base-font-size-sm)}.context-box__content:focus-visible{outline:none}.context-box__menu{padding:var(--context-box-side-padding);gap:var(--spacer-1);flex-direction:column;display:flex}.context-box__menu--scrollable{max-height:38vh;padding-right:var(--spacer-r-20);grid-template-columns:repeat(1,minmax(280px,10cqw));display:grid;overflow-y:auto}@container chat-inner-container (width>=480px){.context-box__menu--two-cols{column-gap:var(--spacer-r-20);grid-template-columns:repeat(2,minmax(180px,42cqw));display:grid}}@container chat-inner-container (width>=768px){.context-box__menu--three-cols{grid-template-columns:repeat(3,minmax(160px,25cqw))}}.context-box__menu-item{width:100%;padding:var(--spacer-4) var(--spacer-8);align-items:center;gap:var(--spacer-8);border-radius:var(--context-box-menu-item-border-radius);background:var(--context-box-menu-item-background);color:var(--context-box-menu-item-color);cursor:pointer;display:flex;position:relative}.context-box__menu-item:hover{background:var(--context-box-menu-item-hover-background);color:var(--context-box-menu-item-hover-color)}.context-box__menu-item:focus{z-index:var(--z-index-local-overlay)}.context-box__menu-item.active{background:var(--context-box-menu-item-active-background);color:var(--context-box-menu-item-active-color)}.context-box__menu-item--option{align-items:baseline}.context-box__menu-item__icon{width:var(--spacer-20);height:var(--spacer-20);color:currentColor}.context-box__title{padding:calc(var(--context-box-side-padding) * 1.5) var(--context-box-side-padding) 0 var(--context-box-side-padding);color:var(--context-box-title-color);font-weight:var(--context-box-title-font-weight);font-size:var(--base-font-size-xs)}.context-box__header{min-width:200px;padding:var(--context-box-side-padding);padding-left:calc(var(--context-box-side-padding) + var(--spacer-8));justify-content:space-between;align-items:center;gap:var(--spacer-r-12);border-bottom:1px solid var(--context-box-separator-color);font-weight:var(--context-box-title-font-weight);font-size:var(--base-font-size-xs);text-wrap:balance;display:flex}.context-box__close-button{--btn-padding-y:var(--spacer-4);--btn-padding-x:var(--spacer-4);flex-shrink:0}.context-box__footer{--btn-padding-x-smaller:calc(var(--btn-padding-x) * .75);padding:calc(var(--context-box-side-padding) * .5) calc(var(--context-box-side-padding) + var(--spacer-8) - var(--btn-padding-x-smaller));border-top:1px solid var(--context-box-separator-color);flex-wrap:wrap;display:flex}.context-box__footer-item{padding-right:var(--btn-padding-x-smaller);padding-left:var(--btn-padding-x-smaller);font-size:var(--base-font-size-xs);cursor:pointer}.context-box__separator{border-top:1px solid var(--context-box-separator-color)}.context-box__language-translation{opacity:.5}.context-box__color-scheme-selector{flex-direction:row;align-items:stretch;display:flex}.context-box__color-scheme-selector-button{width:100%;margin:var(--context-box-side-padding);padding:var(--spacer-4) var(--spacer-8);justify-content:center;align-items:center;gap:var(--spacer-8);border-radius:var(--context-box-menu-item-border-radius);background:var(--context-box-menu-item-background);color:var(--context-box-menu-item-color);cursor:pointer;display:flex}.context-box__color-scheme-selector-button:hover{background:var(--context-box-menu-item-hover-background);color:var(--context-box-menu-item-hover-color)}.context-box__color-scheme-selector-separator{border-top:0;border-left:1px solid var(--context-box-separator-color);width:1px;height:auto;display:block}.context-box__color-scheme-selector-button--active{background:var(--context-box-menu-item-active-background);color:var(--context-box-menu-item-active-color)}.context-box__notification[data-type=error]{color:var(--context-box-error-color)}.context-box__popover-close{z-index:var(--z-index-local-overlay);top:var(--spacer-4);right:var(--spacer-4);clip:rect(0 0 0 0);width:1px;height:1px;padding:var(--spacer-4);border-radius:var(--context-box-menu-item-border-radius);background:var(--context-box-background);color:var(--context-box-color);clip-path:inset(50%);cursor:pointer;border:none;position:absolute;overflow:hidden}.context-box__popover-close:focus-visible{clip:auto;clip-path:none;width:auto;height:auto;overflow:visible}.context-box__content--info{width:calc(100cqw - var(--spacer-32));max-width:600px;max-height:60cqh;padding:var(--spacer-r-32);position:relative;overflow:hidden scroll}.context-box__content--info :where(.text-container){flex-direction:column;align-items:flex-start;display:flex}[data-bits-floating-content-wrapper]{padding-right:1em}.context-box--dropdown{max-width:min(var(--container-max-width,1024px), 90cqw)}.context-box--dropdown :where(.context-box__content){width:auto;max-width:100%}.consent-page{padding-top:var(--spacer-r-40);padding-bottom:var(--spacer-r-40);justify-content:center;align-items:stretch;gap:var(--spacer-r-48);flex-direction:column;flex-grow:1;display:flex}.consent-page__introduction{text-align:center}.consent-page__disclaimer{font-size:var(--base-font-size-sm);text-align:center;text-wrap:balance}.consent-page__actions{justify-content:center;gap:var(--spacer-r-16);flex-wrap:wrap;display:flex}.chat-page{padding-top:var(--spacer-r-80);flex-direction:column;flex-grow:1;display:flex;position:relative}.chat-page__survey-portal:not(:empty){z-index:calc(var(--z-index-header) - 1);position:sticky;top:4rem}.chat-page__body{flex-direction:column;flex-grow:1;display:flex}.chat-page__messages{gap:var(--spacer-r-40);flex-direction:column;flex-grow:1;display:flex}.chat-page__footer{z-index:var(--z-index-footer);flex-direction:column;justify-content:flex-end;display:flex;position:sticky;bottom:0}.chat-page__footer--unsticked{position:relative}.chat-page__footer-content{padding-bottom:var(--spacer-r-8);gap:var(--spacer-r-8);border-width:var(--chat-footer-border-width);border-top-right-radius:var(--chat-footer-border-radius);border-top-left-radius:var(--chat-footer-border-radius);border-style:solid;border-color:var(--chat-footer-border-color);background:var(--chat-footer-background);box-shadow:var(--chat-footer-box-shadow);color:var(--chat-footer-color);flex-direction:column;display:flex;position:relative}.chat-page__footer-text{font-size:var(--base-font-size-xs);text-align:center;text-wrap:balance}.chat-page__footer-text :where(a){text-underline-offset:.15em;text-decoration:underline}.chat-page__buttons{padding-top:var(--spacer-80);padding-bottom:var(--spacer-40);align-self:center}.chat-page__give-feedback--disabled{opacity:0}.chat-page__scroll-to-bottom{opacity:1;position:absolute;top:0;left:50%;transform:translate(-50%,-150%)}.chat-page__scroll-to-bottom--hidden{transform:translate(-50%);opacity:0!important}.dialog-overlay{z-index:var(--z-index-dialog);background:var(--dialog-background-overlay);position:fixed;inset:0}.dialog-content{z-index:var(--z-index-dialog);width:calc(100% - var(--spacer-32));border-width:var(--dialog-border-width);border-radius:var(--dialog-border-radius);border-color:var(--dialog-border-color);background:var(--dialog-background);max-width:600px;max-height:90vh;box-shadow:var(--dialog-box-shadow,none);flex-direction:column;display:flex;position:fixed;top:50%;left:50%;overflow:clip;transform:translate(-50%,-50%)}.dialog-header{padding:var(--spacer-r-24);border-bottom-width:1px;border-bottom-color:var(--dialog-header-border-bottom-color,var(--dialog-border-color));font-weight:var(--dialog-header-font-weight,inherit);font-size:var(--dialog-header-font-size,inherit);justify-content:space-between;align-items:center;display:flex}.dialog-title{padding:0}.dialog-close{color:var(--anchor-color);justify-self:flex-end;margin-left:auto}.dialog-close:hover{color:var(--anchor-hover-color,var(--dialog-color))}.dialog-description{min-height:0;padding:var(--spacer-r-24);flex:1;overflow-y:auto}.dialog-footer{padding:var(--spacer-r-24);border-top-width:1px;border-top-color:var(--dialog-header-border-bottom-color,var(--dialog-border-color));background:var(--dialog-background);flex-shrink:0}.dialog-footer__actions{justify-content:flex-end;gap:var(--spacer-r-12);display:flex}:where(.flyout){z-index:var(--z-index-flyout);pointer-events:none;width:570px;max-width:100cqw;height:960px;max-height:100cqh;padding:10px;display:block;position:fixed;bottom:0;right:0}.flyout__backdrop{background-color:color-mix(in srgb, var(--flyout-backdrop-color,transparent) calc(var(--flyout-backdrop-opacity) * 100%), transparent);position:fixed;inset:0}.flyout__body{pointer-events:none;place-content:end flex-end;place-items:end;width:100%;height:100%;display:block;position:relative}.flyout__body:has(.flyout__content){pointer-events:auto}.flyout__content{width:100%;height:100%;display:block}.flyout__open-button{z-index:var(--z-index-local-overlay);pointer-events:auto;position:absolute;bottom:0;right:0}.flyout__content{filter:drop-shadow(0 0 8px #0003);border-radius:4px;overflow:clip}.flyout--defaults{right:var(--spacer-r-16);bottom:var(--spacer-r-16);width:200px;height:200px;display:block;position:fixed}.introduction{justify-content:center;align-items:center;gap:var(--spacer-r-16);flex-direction:column;display:flex}.introduction__avatar{width:var(--spacer-r-80);height:var(--spacer-r-80)}.introduction__title{font-size:var(--base-font-size-h3);text-align:center;text-wrap:balance}.introduction-disclaimer{margin-top:var(--spacer-r-32);font-size:var(--base-font-size-sm)}.message{min-height:0;transition:min-height 0 1.1s;display:flex}.message:last-child{min-height:var(--last-bot-message-min-height)}.message--bot{justify-content:flex-start;width:100%}.message--user:first-child+.message--bot{min-height:0}.message--bot :where(.message__content){width:100%}.message--user{justify-content:flex-end}.message--user :where(.message__content){padding:var(--spacer-8) var(--spacer-16);border-width:var(--message-user-border-width);border-radius:var(--message-user-border-radius);border-color:var(--message-user-border-color);background:var(--message-user-background);box-shadow:var(--message-user-box-shadow);color:var(--message-user-color)}.message--no-padding{padding:0 var(--spacer-16)}.open-button{--open-button-avatar-height:var(--spacer-r-80);--open-button-avatar-width:var(--spacer-r-80);--open-button-duration:.4s;--open-button-delay:.3s;--open-button-ease:ease-in-out;cursor:pointer;flex-direction:row;align-items:flex-end;transition:opacity .15s ease-out;display:flex}.open-button--expanded{opacity:0;pointer-events:none}.open-button__text{margin-right:calc(var(--open-button-avatar-width) * -.5);padding-top:var(--spacer-r-12);padding-right:0;padding-bottom:var(--spacer-r-12);border-width:var(--open-button-border-width);border-radius:var(--open-button-border-radius);border-color:var(--open-button-border-color);background:var(--open-button-background);color:var(--open-button-color);text-align:left;transition:transform var(--open-button-duration) var(--open-button-ease), padding-right var(--open-button-duration) var(--open-button-delay) var(--open-button-ease);flex-direction:column;justify-content:center;align-items:flex-start;padding-left:0;display:flex;position:absolute;bottom:50%;right:100%;overflow:hidden;transform:translateY(50%);box-shadow:0 4px 6px -1px #0000001a,0 2px 4px -2px #0000001a}.open-button:is(:hover,.open-button--programmatic-expand) .open-button__text{background:var(--open-button-hover-background,var(--open-button-background));color:var(--open-button-hover-color,var(--open-button-color));opacity:1;transition:transform var(--open-button-duration) var(--open-button-delay) var(--open-button-ease);transform:translateY(0)}.open-button__title{max-width:240px;padding:0 calc(var(--open-button-avatar-width) * .5 + var(--spacer-r-12)) 0 var(--spacer-r-12);white-space:pre;font-weight:700}.open-button__mask{width:0;height:0;transition:width var(--open-button-duration) var(--open-button-delay) var(--open-button-ease), height var(--open-button-duration) var(--open-button-ease);overflow:hidden}.open-button:is(:hover,.open-button--programmatic-expand) .open-button__mask{transition:width var(--open-button-duration) var(--open-button-ease), height var(--open-button-duration) var(--open-button-delay) var(--open-button-ease)}.open-button__description{width:50cqw;max-width:260px;padding:0 calc(var(--open-button-avatar-width) * .5 + var(--spacer-r-12)) 0 var(--spacer-r-12);text-wrap:balance;position:relative}.open-button__avatar{z-index:var(--z-index-local-overlay);width:var(--open-button-avatar-width);height:var(--open-button-avatar-height);border-radius:var(--spacer-r-80);filter:drop-shadow(0 4px 6px #00000026);transition:transform .2s var(--open-button-ease);position:relative;overflow:clip}.open-button:is(:hover,.open-button--programmatic-expand) .open-button__avatar{transform:scale(1.05)}.open-button__link-icon{width:var(--spacer-r-80);height:var(--spacer-r-80);padding:var(--spacer-r-20);color:var(--open-button-color);display:none;position:absolute;right:0}:where(.open-button--standalone){right:var(--spacer-r-16);bottom:var(--spacer-r-16);position:fixed}@media (prefers-reduced-motion:reduce){.open-button__text,.open-button__mask,.open-button:hover .open-button__text,.open-button:hover .open-button__mask{transition:none!important}.open-button__avatar,.open-button:hover .open-button__avatar{filter:none!important;transition:none!important}}.open-button--hide-title-when-collapsed .open-button__text{visibility:hidden;opacity:0;transition:transform var(--open-button-duration) var(--open-button-ease), padding-right var(--open-button-duration) var(--open-button-delay) var(--open-button-ease), opacity var(--open-button-duration) var(--open-button-delay) var(--open-button-ease), visibility 0s linear calc(var(--open-button-duration) + var(--open-button-delay))}.open-button--hide-title-when-collapsed:is(:hover,.open-button--programmatic-expand) .open-button__text{visibility:visible;background:var(--open-button-hover-background,var(--open-button-background));color:var(--open-button-hover-color,var(--open-button-color));opacity:1;transition:transform var(--open-button-duration) var(--open-button-delay) var(--open-button-ease), opacity var(--open-button-duration) var(--open-button-ease), visibility 0s linear 0s;transform:translateY(0)}.predefined-question{width:100%;height:100%;padding:var(--spacer-r-20);gap:var(--spacer-r-12);border-width:var(--card-border-width);border-radius:var(--card-border-radius);border-color:var(--card-border-color);background:var(--card-background);box-shadow:var(--card-box-shadow,none);color:var(--card-color);line-height:var(--base-line-height-snug);text-align:left;cursor:pointer;flex-direction:column;display:flex;position:relative}.predefined-question:hover{border-width:var(--card-hover-border-width,var(--card-border-width));border-radius:var(--card-hover-border-radius,var(--card-border-radius));border-color:var(--card-hover-border-color,var(--card-border-color));background:var(--card-hover-background,var(--card-background));box-shadow:var(--card-hover-box-shadow,var(--card-box-shadow), none);color:var(--card-hover-color,var(--card-color))}.predefined-question:hover :where(.predefined-question__icon){color:var(--card-icon-hover-color)}.predefined-question:focus{z-index:var(--z-index-local-overlay)}@container chat-container (width>=640px){.predefined-question{padding:var(--spacer-r-24)}}.predefined-question__icon{color:var(--card-icon-color)}.predefined-questions{gap:var(--spacer-r-12);width:100%;display:grid}@container chat-container (width>=640px){.predefined-questions{grid-template-columns:repeat(3,1fr)}.predefined-questions:has(>li:only-child){grid-template-columns:1fr}.predefined-questions:has(>li:nth-child(2):last-child){grid-template-columns:repeat(2,1fr)}}.predefined-questions--pii-padding{transform:translateY(var(--spacer-56))}.reference-number{display:inline-block;position:relative}.reference-number__trigger{box-sizing:border-box;min-width:1.5em;height:1.5em;padding:var(--reference-number-trigger-padding);border-width:var(--reference-number-trigger-border-width);border-radius:var(--reference-number-trigger-border-radius);border-color:var(--reference-number-trigger-border-color);background:var(--reference-number-trigger-background);box-shadow:var(--reference-number-trigger-box-shadow);color:var(--reference-number-trigger-color);font-weight:var(--base-font-weight-bold);font-size:var(--base-font-size-xs);text-align:center;cursor:pointer;margin:0 .1em;line-height:1;text-decoration:none;display:inline-block;position:relative;top:-.1em}.reference-number__trigger:hover{background:var(--reference-number-trigger-hover-background);color:var(--reference-number-trigger-hover-color)}.reference-number__trigger:after{z-index:var(--z-index-local-overlay);content:"";background:0 0;position:absolute;inset:-.5em}.reference-number__content-wrapper{z-index:var(--z-index-reference-number);width:var(--reference-number-content-width);max-width:var(--reference-number-content-max-width);position:absolute}.reference-number__content{padding:var(--spacer-r-20);border-width:var(--reference-number-content-border-width);border-radius:var(--reference-number-content-border-radius);border-style:solid;border-color:var(--reference-number-content-border-color);background:var(--reference-number-content-background);box-shadow:var(--reference-number-content-box-shadow);display:block}.reference-number__content:hover{border-width:var(--reference-number-content-hover-border-width,var(--reference-number-content-border-width));border-color:var(--reference-number-content-hover-border-color,var(--reference-number-content-border-color));background:var(--reference-number-content-hover-background,var(--reference-number-content-background));color:var(--reference-number-content-hover-color,var(--reference-number-content-color));cursor:pointer}.reference-number__content:after{z-index:var(--z-index-local-overlay);content:"";background:0 0;position:absolute;inset:-.5em}.reference{padding:var(--spacer-12);gap:var(--spacer-12);border-width:var(--reference-border-width);border-radius:var(--reference-border-radius);border-color:var(--reference-border-color);background:var(--reference-background);box-shadow:var(--reference-box-shadow);color:var(--reference-color);cursor:pointer;display:flex}.reference:hover{border-width:var(--reference-hover-border-width,var(--reference-border-width));border-color:var(--reference-hover-border-color,var(--reference-border-color));background:var(--reference-hover-background,var(--reference-background));box-shadow:var(--reference-hover-box-shadow,var(--reference-box-shadow), none);color:var(--reference-hover-color,var(--reference-color))}.reference__number{min-width:1.5em;height:1.5em;margin-top:var(--spacer-1);padding:var(--reference-number-padding);border-width:var(--reference-number-border-width);border-radius:var(--reference-number-border-radius);border-color:var(--reference-number-border-color);background:var(--reference-number-background);box-shadow:var(--reference-number-box-shadow);color:var(--reference-number-color);font-weight:700;font-weight:var(--base-font-weight-bold);font-size:var(--base-font-size-xs);text-align:center;flex-shrink:0;line-height:1;display:block}@container chat-container (width>=640px){.reference__number{margin-top:calc(var(--spacer-1) * -1)}}a:hover .reference__number{border-width:var(--reference-number-hover-border-width,var(--reference-number-border-width));border-radius:var(--reference-number-hover-border-radius,var(--reference-number-border-radius));border-color:var(--reference-number-hover-border-color,var(--reference-number-border-color));background:var(--reference-number-hover-background,var(--reference-number-background));box-shadow:var(--reference-number-hover-box-shadow,var(--reference-number-box-shadow));color:var(--reference-number-hover-color,var(--reference-number-color))}.reference__header{justify-content:space-between;align-items:flex-start;gap:var(--spacer-12);width:100%;display:flex}.reference__title{font-size:var(--reference-font-size,var(--base-font-size-sm))}.reference__body{flex-direction:column;flex-grow:1;min-width:0;display:flex}.reference__icon{width:var(--spacer-20);color:var(--anchor-color);flex-shrink:0;position:relative}@media (hover:hover){.reference__icon{transform:translate(calc(var(--spacer-8) * -1), var(--spacer-8));opacity:0;transition:transform .2s ease-in-out,opacity .2s linear}}a:hover .reference__icon{opacity:1;transform:translate(0)}.reference__description{margin-top:var(--spacer-2);color:var(--reference-description-color);font-size:var(--base-font-size-sm)}a:hover .reference__description{color:var(--reference-description-hover-color)}.reference__footer{--footer-gap:var(--spacer-5);column-gap:var(--footer-gap);margin-top:var(--spacer-6);font-size:var(--base-font-size-xs);flex-wrap:wrap;display:flex}.reference__domain{max-width:100%;padding:var(--reference-domain-padding);border-width:var(--reference-domain-border-width);border-radius:var(--reference-domain-border-radius);border-color:var(--reference-domain-border-color);background:var(--reference-domain-background);box-shadow:var(--reference-domain-box-shadow);color:var(--reference-domain-color);font-weight:700;display:inline-flex}a:hover .reference__domain{border-width:var(--reference-domain-hover-border-width,var(--reference-domain-border-width));border-color:var(--reference-domain-hover-border-color,var(--reference-domain-border-color));background:var(--reference-domain-hover-background,var(--reference-domain-background));box-shadow:var(--reference-domain-hover-box-shadow,var(--reference-domain-box-shadow));color:var(--reference-domain-hover-color,var(--reference-domain-color))}.reference__breadcrumb{color:var(--reference-domain-color)}.reference__breadcrumb:before{padding-right:var(--footer-gap);content:"/";position:relative;top:-1px}a:hover .reference__breadcrumb{color:var(--reference-domain-hover-color,var(--reference-domain-color))}.references__container{--padding:var(--spacer-10);padding:var(--padding);flex-direction:column;display:flex}.references__transition{position:relative}.references__items{width:100%}.references__items :focus-within{z-index:var(--z-index-local-overlay);position:relative}.references__further{margin-top:var(--padding);margin-right:calc(var(--padding) * -1);margin-left:calc(var(--padding) * -1);border-top:1px solid var(--base-line-color)}.references__further :where(.references__container){scroll-margin-top:140px}.references__further :where(.reference){padding-left:var(--spacer-16)}.references__toggle{width:100%;padding:var(--spacer-20) var(--spacer-20) var(--spacer-20) var(--spacer-24);justify-content:space-between;align-items:center;gap:var(--spacer-8);border-width:var(--references-toggle-border-width);border-radius:var(--references-toggle-border-radius);border-color:var(--references-toggle-border-color);background:var(--references-toggle-background);box-shadow:var(--references-toggle-box-shadow);color:var(--references-toggle-color);font-weight:var(--references-toggle-font-weight,var(--base-font-weight-bold));font-size:var(--references-toggle-font-size,var(--base-font-size-sm));display:flex}.references__toggle:hover{border-color:var(--references-toggle-hover-border-color);background:var(--references-toggle-hover-background);box-shadow:var(--references-toggle-hover-box-shadow);color:var(--references-toggle-hover-color)}.references__toggle[data-state=open] :where(.references__toggle-icon){transform:rotate(180deg)}.references__toggle-icon{width:var(--spacer-24);transition:transform .2s}.jsonld-references{margin-top:var(--spacer-r-20);gap:var(--spacer-r-20);display:grid}@keyframes jsonld-fly-in{0%{transform:translateY(var(--jsonld-item-y,30px));opacity:0}to{opacity:1;transform:none}}.jsonld-references__item{min-width:0;animation:jsonld-fly-in var(--jsonld-item-duration,.3s) cubic-bezier(.165, .84, .44, 1) both;animation-delay:var(--jsonld-item-delay,0s);display:flex}.jsonld-references__item--preloading{visibility:hidden;pointer-events:none;width:400px;animation:none;position:absolute;left:-9999px}.jsonld-card{padding:var(--spacer-r-24);gap:var(--spacer-r-16);border-style:solid;flex-direction:column;flex:1;display:flex}.jsonld-card--map{--jsonld-card-radius:var(--message-json-ld-map-border-radius);border-width:var(--message-json-ld-map-border-width);border-radius:var(--message-json-ld-map-border-radius);border-color:var(--message-json-ld-map-border-color);background:var(--message-json-ld-map-background);box-shadow:var(--message-json-ld-map-box-shadow);color:var(--message-json-ld-map-color)}.jsonld-card--event{--jsonld-card-radius:var(--message-json-ld-event-border-radius);border-width:var(--message-json-ld-event-border-width);border-radius:var(--message-json-ld-event-border-radius);border-color:var(--message-json-ld-event-border-color);background:var(--message-json-ld-event-background);box-shadow:var(--message-json-ld-event-box-shadow);color:var(--message-json-ld-event-color)}.jsonld-card--cta{--jsonld-card-radius:var(--message-json-ld-cta-border-radius);border-width:var(--message-json-ld-cta-border-width);border-radius:var(--message-json-ld-cta-border-radius);border-color:var(--message-json-ld-cta-border-color);background:var(--message-json-ld-cta-background);box-shadow:var(--message-json-ld-cta-box-shadow);color:var(--message-json-ld-cta-color)}.jsonld-card__header{align-items:flex-start;min-width:0;display:flex}.jsonld-card__title{min-width:0;font-size:var(--base-font-size-h3);line-height:var(--base-line-height-tight);word-break:break-word;margin:0}.jsonld-card__meta{column-gap:var(--spacer-8);row-gap:var(--spacer-4);font-size:var(--base-font-size-sm);grid-template-columns:max-content 1fr;align-items:baseline;margin:0;display:grid}.jsonld-card__meta-label{padding-right:var(--spacer-12);font-weight:var(--base-font-weight-bold);font-size:var(--base-font-size-xs);line-height:var(--base-line-height-snug);letter-spacing:.04em;text-transform:uppercase}.jsonld-card__meta-value{line-height:var(--base-line-height-snug);white-space:pre-line;margin:0}.jsonld-card__event-date{gap:var(--spacer-2);flex-direction:column;display:flex}.jsonld-card__event-time{opacity:.7}.jsonld-card__description{margin-bottom:var(--spacer-6);font-size:var(--base-font-size-sm);line-height:var(--base-line-height-default);opacity:.9}.jsonld-card__address{font-size:var(--base-font-size-sm);line-height:var(--base-line-height-snug);white-space:pre-line;margin:0}.jsonld-card__cta{border-width:var(--btn-primary-border-width);border-radius:var(--btn-primary-border-radius);border-color:var(--btn-primary-border-color);background:var(--btn-primary-background);box-shadow:var(--btn-primary-box-shadow);color:var(--btn-primary-color);font-weight:var(--btn-primary-font-weight,700);align-self:flex-start;text-decoration:none}.jsonld-card__cta:hover{border-width:var(--btn-primary-hover-border-width,var(--btn-primary-border-width));border-color:var(--btn-primary-hover-border-color,var(--btn-primary-border-color));background:var(--btn-primary-hover-background,var(--btn-primary-background));box-shadow:var(--btn-primary-hover-box-shadow,var(--btn-primary-box-shadow));color:var(--btn-primary-hover-color,var(--btn-primary-color))}.jsonld-card__cta-icon{width:var(--spacer-16);height:var(--spacer-16);flex-shrink:0}.jsonld-card__actions{align-items:center;gap:var(--spacer-12);flex-wrap:wrap;display:flex}.jsonld-card__link{align-items:center;gap:var(--spacer-6);color:var(--anchor-color,currentColor);font-weight:var(--base-font-weight-bold);font-size:var(--base-font-size-sm);display:inline-flex}.jsonld-card__link:hover{text-decoration:underline}.jsonld-card__map-frame{aspect-ratio:16/9;border:1px solid color-mix(in srgb, currentColor 10%, transparent);border-radius:calc(var(--jsonld-card-radius) * .7);background:color-mix(in srgb, currentColor 6%, transparent);width:100%;position:relative;overflow:hidden}.jsonld-card__map-canvas,.jsonld-card__map-frame .maplibregl-map{width:100%;height:100%;position:absolute;inset:0}.jsonld-card__map-frame .maplibregl-ctrl-attrib,.jsonld-card__map-frame .maplibregl-ctrl-attrib-inner{display:none}.maplibregl-canvas{border-radius:0}.selected-topic{z-index:-10;position:relative}.selected-topic__animation-container--hidden{transform:translateY(-100%)}.selected-topic__container{align-items:stretch;gap:var(--selected-topic-separator-width);border:var(--selected-topic-border-width) solid var(--selected-topic-border-color);border-radius:var(--selected-topic-border-radius) var(--selected-topic-border-radius) 0 0;background-color:var(--selected-topic-border-color);width:fit-content;font-size:var(--base-font-size-xs);flex-wrap:wrap;margin-inline:auto;display:flex;overflow:hidden}.selected-topic__label,.selected-topic__btn{padding:var(--selected-topic-padding);background-color:var(--selected-topic-background);font-weight:var(--base-font-weight-bold);text-align:center;flex-grow:1}.selected-topic__label{justify-content:center;align-items:center;gap:var(--selected-topic-label-gap);color:var(--selected-topic-color);font-size:var(--base-font-size-xs);line-height:var(--base-line-height-default);display:flex}.selected-topic__label-complement{display:none}@container chat-container (width>=640px){.selected-topic__label-complement{display:block}}.selected-topic__btn{color:var(--selected-topic-btn-color);transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color,text-decoration-color,box-shadow,transform,translate,opacity;transition-timing-function:var(--default-transition-timing-function)}.selected-topic__btn:hover{color:var(--selected-topic-btn-hover-color)}.start-page{padding-top:var(--spacer-r-40);padding-bottom:var(--spacer-r-40);flex-direction:column;flex-grow:1;justify-content:center;align-items:stretch;display:flex}.start-page__introduction{margin-bottom:var(--spacer-r-48)}.start-page__chat-input{width:100%;margin-bottom:var(--spacer-r-32)}.tooltip-container{z-index:var(--z-index-tooltip);position:relative}.tooltip-container:hover{z-index:var(--z-index-tooltip-hover)}.tooltip{--background-color:var(--tooltip-background);z-index:var(--z-index-tooltip);padding:var(--spacer-3) var(--spacer-8);border-radius:var(--tooltip-border-radius);background:var(--background-color);color:var(--tooltip-color);font-weight:var(--base-font-weight-normal);font-size:var(--base-font-size-xs);white-space:nowrap;opacity:1;transition:opacity .15s cubic-bezier(.33,1,.68,1),transform .15s cubic-bezier(.33,1,.68,1);position:absolute;transform:translateY(0)}.tooltip:after{content:"";border-style:solid;border-width:5px;position:absolute}.tooltip-top:after{bottom:-10px;left:calc(50% + var(--tooltip-arrow-offset,0px));border-color:var(--background-color) transparent transparent transparent;transform:translate(-50%)}.tooltip-bottom:after{top:-10px;left:calc(50% + var(--tooltip-arrow-offset,0px));border-color:transparent transparent var(--background-color) transparent;transform:translate(-50%)}.tooltip-left:after{border-color:transparent var(--background-color) transparent transparent;top:50%;right:-10px;transform:translateY(-50%)}.tooltip-right:after{border-color:transparent transparent transparent var(--background-color);top:50%;left:-10px;transform:translateY(-50%)}.tooltip-bottom-right:after{border-color:transparent transparent var(--background-color) transparent;top:-10px;left:80%;transform:translate(-50%)}.tooltip-bottom-left:after{border-color:transparent transparent var(--background-color) transparent;top:-10px;left:20px;transform:translate(-50%)}.tooltip-hidden{opacity:0;pointer-events:none;transform:translateY(1rem)}.context-box.open .tooltip{display:none}.mic-icon{justify-content:center;align-items:center;height:1.5rem;display:flex;position:relative}.mic-icon .svg{width:inherit}.audio-level-mic-svg{width:1.5rem;height:1.5rem}.embed-combobox{--embed-combobox-side-offset:10px;align-items:start;gap:var(--spacer-r-32);flex-direction:column;display:flex}.embed-combobox__container{transition:opacity .3s linear}.embed-combobox__container--hidden{opacity:0;height:0}.embed-combobox__combobox{border:var(--input-border-width) solid var(--input-border-color);border-radius:var(--input-border-radius);background:var(--input-background);align-items:stretch;width:100%;min-width:min(14rem,100%);max-width:500px;display:inline-flex;position:relative}.embed-combobox__combobox:has(:focus-visible:not([data-disabled])){border-radius:var(--btn-primary-border-radius);outline-color:var(--body-focus-color);outline-style:solid;outline-width:var(--spacer-3);outline-offset:var(--spacer-2)}.embed-combobox__no-result{margin-top:var(--spacer-r-12);margin-bottom:var(--spacer-12);padding:var(--spacer-4) var(--spacer-8)}[data-combobox-input]{width:100%;min-width:0;padding:var(--input-padding);padding-right:var(--spacer-r-64);color:var(--input-color);background:0 0;outline:none}[data-combobox-input]::placeholder{color:var(--input-placeholder-color)}[data-combobox-trigger]{z-index:var(--z-index-local-overlay);aspect-ratio:1;border:0;justify-content:center;align-items:center;display:flex;position:absolute;top:0;bottom:0;right:0}[data-combobox-trigger] :where(.btn){border-radius:calc(var(--btn-tertiary-border-radius) * .75)}[data-combobox-trigger][data-state=open],[data-combobox-trigger]:hover,[data-combobox-trigger]:focus-visible{outline:none}:is([data-combobox-trigger][data-state=open],[data-combobox-trigger]:hover,[data-combobox-trigger]:focus-visible) :where(.btn){background:var(--btn-tertiary-hover-background);color:var(--btn-tertiary-hover-color)}[data-combobox-trigger][data-disabled],[data-combobox-input][data-disabled]{cursor:not-allowed;opacity:.5}[data-combobox-content]{z-index:var(--z-index-flyout);width:var(--bits-combobox-anchor-width);min-width:var(--bits-combobox-anchor-width);max-height:min(21rem, var(--bits-combobox-content-available-height));padding:0 var(--spacer-r-12);border-width:var(--context-box-border-width);border-radius:var(--context-box-border-radius);border-style:solid;border-color:var(--context-box-border-color);background:var(--context-box-background);box-shadow:var(--context-box-box-shadow);font-size:var(--base-font-size-sm);-webkit-user-select:none;user-select:none;position:relative;overflow:hidden}[data-combobox-viewport]{flex-direction:column;gap:1px;display:flex}[data-bits-floating-content-wrapper]{padding:0}[data-combobox-item]{padding:var(--spacer-4) var(--spacer-8);align-items:center;gap:.5rem;gap:var(--spacer-8);border-radius:var(--context-box-menu-item-border-radius);background:var(--context-box-menu-item-background);color:var(--context-box-menu-item-color);cursor:pointer;-webkit-user-select:none;user-select:none;grid-template-columns:1fr auto;transition:background .2s ease-in-out,color .2s ease-in-out;display:grid}[data-combobox-item]:first-of-type{margin-top:var(--spacer-r-12)}[data-combobox-item]:last-of-type{margin-bottom:var(--spacer-r-12)}[data-combobox-item][data-highlighted]{background:var(--context-box-menu-item-hover-background);color:var(--context-box-menu-item-hover-color)}[data-combobox-item][data-selected]{background:var(--context-box-menu-item-active-background);color:var(--context-box-menu-item-active-color)}[data-combobox-item][data-disabled]{cursor:not-allowed;opacity:.5}[data-combobox-scroll-up-button],[data-combobox-scroll-down-button]{z-index:var(--z-index-local-overlay);padding:var(--spacer-4);background:linear-gradient(to bottom, var(--context-box-background), transparent);color:var(--context-box-menu-item-color);cursor:pointer;place-items:center;display:grid;position:absolute;top:0;left:0;right:0}:is([data-combobox-scroll-up-button],[data-combobox-scroll-down-button]):hover{background:var(--context-box-menu-item-hover-background);color:var(--context-box-menu-item-hover-color)}[data-combobox-scroll-down-button]{background:linear-gradient(to top, var(--context-box-background), transparent);top:auto;bottom:0}[data-combobox-scroll-down-button]:hover{background:var(--context-box-menu-item-hover-background)}.embed-buttons{align-items:start;gap:var(--spacer-r-16);flex-direction:column;display:flex}.embed-buttons__buttons{gap:var(--spacer-r-12);flex-wrap:wrap;display:flex}}@value container-xs, container-sm, container-md, container-lg, container-inner-xs, container-inner-sm, container-inner-md, container-inner-lg from "./viewports.css";.message__bot-layout{gap:var(--spacer-r-16);width:100%;display:flex}.message__bot-avatar{top:var(--spacer-80);width:var(--spacer-24);height:var(--spacer-24);margin-top:calc(var(--spacer-1) * -1);margin-bottom:var(--spacer-20);flex-shrink:0;display:none;position:sticky;overflow:clip}@container chat-container (width>=480px){.message__bot-avatar{display:block}}@container chat-container (width>=640px){.message__bot-avatar{width:var(--spacer-32);height:var(--spacer-32);margin-top:calc(var(--spacer-3) * -1);margin-bottom:var(--spacer-16)}}.svg--avatar--hide{visibility:hidden;height:0;margin-top:0;margin-bottom:0;padding-top:0;padding-bottom:0}.message__content,.message__bot-body,.message__bot-options{min-width:0}.message__bot-body{width:100%}.message__bot-options{z-index:var(--z-index-local-overlay);column-gap:var(--spacer-20);row-gap:var(--spacer-8);margin-top:var(--spacer-24);padding-top:var(--spacer-12);border-top-width:var(--message-options-border-width);border-color:var(--message-options-border-color);flex-wrap:wrap;justify-content:space-between;align-items:center;display:flex}@container chat-container (width>=640px){.message__bot-options{margin-top:var(--spacer-32);margin-bottom:var(--spacer-20)}}.message__bot-options:has(>:only-child){justify-content:flex-end}.message__bot-references{--btn-padding-x:var(--btn-padding-y);column-gap:var(--spacer-8);margin-left:calc(var(--btn-padding-x) * -1);flex-wrap:wrap;flex-grow:1;align-items:center;display:flex}.message__bot-references :where(.btn__label){display:flex}.message__bot-actions{--btn-padding-x:var(--btn-padding-y);margin-right:calc(var(--btn-padding-x) * -1);display:flex;position:relative}@container chat-container (width>=640px){.message__bot-actions{gap:var(--spacer-8)}}.message__bot-loading{width:var(--spacer-16);height:var(--spacer-16);margin:0 var(--spacer-2);display:inline-block}`;function SF(e,{delay:t=0,duration:n=200,easing:r=e=>e,baseScale:i=0,transformOrigin:a=`bottom right`,scaleDirection:o=`scale`}={}){if(window.matchMedia(`(prefers-reduced-motion: reduce)`).matches)return{delay:0,duration:0,css:()=>`opacity: 1; transform: ${o}(1); transform-origin: ${a};`};let s=getComputedStyle(e),c=+s.opacity,l=s.transform.match(/scale[XY]?\(([0-9.]+)\)/),u=l?+l[1]:1,d=1-i;return{delay:t,duration:n,css:e=>{let t=r(e),n=t*u*d+i;return`opacity: ${t*c}; transform: ${o}(${n}); transform-origin: ${a};`}}}var CF=R(`<div class="loader-container svelte-6xtyn8"><svg width="40" height="40" viewBox="0 0 24 24"><circle cx="4" cy="12" r="3"><animate id="spinner_qFRN" begin="0;spinner_OcgL.end+0.25s" attributeName="cy" calcMode="spline" dur="0.6s" values="12;6;12" keySplines=".33,.66,.66,1;.33,0,.66,.33"></animate></circle><circle cx="12" cy="12" r="3"><animate begin="spinner_qFRN.begin+0.1s" attributeName="cy" calcMode="spline" dur="0.6s" values="12;6;12" keySplines=".33,.66,.66,1;.33,0,.66,.33"></animate></circle><circle cx="20" cy="12" r="3"><animate id="spinner_OcgL" begin="spinner_qFRN.begin+0.2s" attributeName="cy" calcMode="spline" dur="0.6s" values="12;6;12" keySplines=".33,.66,.66,1;.33,0,.66,.33"></animate></circle></svg></div>`),wF={hash:`svelte-6xtyn8`,code:`.loader-container.svelte-6xtyn8 {display:flex;z-index:var(--z-index-loader);position:absolute;top:0;right:0;bottom:0;left:0;align-items:center;justify-content:center;background-color:#fff;}`};function TF(e,t){D(t,!0),ga(e,wF);let n=K(t,`color`,7),r=K(t,`background`,7);var i={get color(){return n()},set color(e){n(e),k()},get background(){return r()},set background(e){r(e),k()}},a=CF(),o=N(a);return E(a),I(()=>{ka(a,r()?`background: ${r()};`:``),G(o,`fill`,n()??`rgba(127, 127, 127, 0.3)`)}),B(e,a),O(i)}q(TF,{color:{},background:{}},[],[],{mode:`open`});var EF=`@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;tab-size:4;font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent;font-family:ui-sans-serif,system-ui,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;line-height:1.5}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-feature-settings:normal;font-variation-settings:normal;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab, red, red)){::placeholder{color:color-mix(in oklab, currentcolor 50%, transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){appearance:button}::file-selector-button{appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}.chat-app{--spacer-1:.0625rem;--spacer-2:.125rem;--spacer-3:.1875rem;--spacer-4:.25rem;--spacer-5:.3125rem;--spacer-6:.375rem;--spacer-8:.5rem;--spacer-10:.625rem;--spacer-12:.75rem;--spacer-16:1rem;--spacer-20:1.25rem;--spacer-24:1.5rem;--spacer-28:1.75rem;--spacer-32:2rem;--spacer-40:2.5rem;--spacer-48:3rem;--spacer-56:3.5rem;--spacer-64:4rem;--spacer-72:4.5rem;--spacer-80:5rem;--spacer-120:7.5rem;--spacer-r-8:clamp(.375rem, .3182rem + .2841cqw, .5rem);--spacer-r-12:clamp(.625rem, .5682rem + .2841cqw, .75rem);--spacer-r-16:clamp(.75rem, .6364rem + .5682cqw, 1rem);--spacer-r-20:clamp(.875rem, .7045rem + .8523cqw, 1.25rem);--spacer-r-24:clamp(1rem, .7727rem + 1.1364cqw, 1.5rem);--spacer-r-28:clamp(1.125rem, .8409rem + 1.4205cqw, 1.75rem);--spacer-r-32:clamp(1.25rem, .9091rem + 1.7045cqw, 2rem);--spacer-r-40:clamp(1.5rem, 1.0455rem + 2.2727cqw, 2.5rem);--spacer-r-48:clamp(1.625rem, 1rem + 3.125cqw, 3rem);--spacer-r-56:clamp(1.75rem, .9545rem + 3.9773cqw, 3.5rem);--spacer-r-64:clamp(2rem, 1.0909rem + 4.5455cqw, 4rem);--spacer-r-80:clamp(3rem, 2.0909rem + 4.5455cqw, 5rem);--spacer-r-96:clamp(3.5rem, 2.3636rem + 5.6818cqw, 6rem);--spacer-r-120:clamp(4rem, 2.4091rem + 7.9545cqw, 7.5rem);--default-transition-duration:.2s;--default-transition-timing-function:ease-in-out;--z-index-flyout:10000;--z-index-dialog:600;--z-index-loader:500;--z-index-reference-number:400;--z-index-footer:300;--z-index-header:200;--z-index-tooltip:100;--z-index-tooltip-hover:101;--z-index-local-overlay:10;--z-index-below:-10;--ease-out-quart:cubic-bezier(.165, .84, .44, 1);--ease-in-quart:cubic-bezier(.895, .03, .685, .22);--ease-in-out-quart:cubic-bezier(.77, 0, .175, 1);--fly-in-id:0;--btn-padding-x:var(--spacer-r-20);--btn-padding-y:var(--spacer-r-8);--btn-icon-size:var(--spacer-24);--btn-submit-size:2.5em;--last-bot-message-min-height:0}.chat-app :where(h1,.h1,h2,.h2,h3,.h3,h4,.h4,h5,.h5,h6,.h6){font-weight:var(--base-font-weight-title);line-height:var(--base-line-height-tight)}.chat-app :where(b,strong){font-weight:var(--base-font-weight-bold)}.chat-app :where(button){cursor:pointer}.chat-app :where(input[type=text],input[type=email],input[type=search],input[type=password],textarea,select){width:100%;padding:var(--input-padding);border-width:var(--input-border-width);border-radius:var(--input-border-radius);border-color:var(--input-border-color);background:var(--input-background);box-shadow:var(--input-box-shadow,none);color:var(--input-color)}.chat-app :where(input[type=text],input[type=email],input[type=search],input[type=password],textarea,select)::placeholder{color:var(--input-placeholder-color);opacity:var(--input-placeholder-opacity)}.chat-app :where(input[type=radio],input[type=checkbox]){margin:0}.chat-app :where(:focus-visible){border-radius:var(--btn-primary-border-radius);outline-color:var(--body-focus-color);outline-style:var(--body-focus-style);outline-width:var(--body-focus-width);outline-offset:var(--body-focus-offset)}.chat-app ::selection{background:var(--body-selection-background);color:var(--body-selection-color)}.chat-app ::-webkit-scrollbar{width:8px;height:8px}.chat-app ::-webkit-scrollbar-track{background:0 0}.chat-app ::-webkit-scrollbar-thumb{background-color:#0000004d;border-radius:4px;transition:background-color .2s}.chat-app ::-webkit-scrollbar-thumb:hover{background-color:#00000080}.chat-app *{scrollbar-color:#0000004d transparent;scrollbar-width:thin}.chat-app ::-webkit-scrollbar-thumb{visibility:hidden}.chat-app :hover::-webkit-scrollbar-thumb{visibility:visible}.chat-app :active::-webkit-scrollbar-thumb{visibility:visible}.chat-app :focus::-webkit-scrollbar-thumb{visibility:visible}.svg{width:var(--spacer-r-24);height:auto}.svg svg{width:100%;height:auto;display:block;overflow:visible}}@layer utilities{.chat-app :where(.expand-interaction){position:relative}.chat-app :where(.expand-interaction):after{content:"";background-color:#0000;position:absolute;inset:0}.chat-app :where(.sr-only){clip:rect(0, 0, 0, 0);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.chat-app :where(.transition-colors){transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color,box-shadow;transition-timing-function:var(--default-transition-timing-function)}.chat-app :where(.transition){transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter;transition-timing-function:var(--default-transition-timing-function)}.chat-app :where(.skip-link){width:0;height:0;color:var(--anchor-color);font-weight:700;font-size:var(--base-font-size-xs);position:absolute;overflow:hidden}.chat-app :where(.skip-link):focus-visible{width:auto;height:auto;position:static}.chat-app :where(.fly-in){--fly-in-id:0;--fly-in-duration:.4s;--fly-out-duration:.2s;--fly-in-delay:.3s;--fly-in-delay-additional:.1s;--fly-in-y:var(--spacer-r-64);transform:translateY(var(--fly-in-y));opacity:0;transition-delay:0s,1s;transition-duration:var(--fly-out-duration);transition-property:opacity,transform;transition-timing-function:ease, var(--ease-out-quart)}.chat-app :where(.mounted .fly-in){opacity:1;transition-delay:calc(var(--fly-in-delay) + var(--fly-in-id) * var(--fly-in-delay-additional));transition-duration:var(--fly-in-duration);transform:translateY(0)}.chat-app :where(.truncate){text-overflow:ellipsis;white-space:nowrap;display:inline-block;overflow:hidden}.chat-app :where(.line-clamp){-webkit-line-clamp:1;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.chat-app :where(.line-clamp--2){-webkit-line-clamp:2}.chat-app :where(.line-clamp--6){-webkit-line-clamp:6}.chat-app :where(.container){width:100%;max-width:var(--container-max-width,1024px);padding-right:var(--spacer-16);padding-left:var(--spacer-16);margin:0 auto}@container chat-container (width>=640px){.chat-app :where(.container){padding-right:var(--spacer-32);padding-left:var(--spacer-32)}}@container chat-container (width>=768px){.chat-app :where(.container){padding-right:var(--spacer-48);padding-left:var(--spacer-48)}}.chat-app :where(h1){font-size:var(--base-font-size-h1)}.chat-app :where(h2){font-size:var(--base-font-size-h2)}.chat-app :where(h3){font-size:var(--base-font-size-h3)}.chat-app :where(h4,h5,h6){font-size:var(--body-font-size)}.chat-app :where(.h1){font-size:var(--base-font-size-h1)}.chat-app :where(.h2){font-size:var(--base-font-size-h2)}.chat-app :where(.h3){font-size:var(--base-font-size-h3)}.chat-app :where(.h4,.h5,.h6){font-size:var(--body-font-size)}.chat-app :where(.text-container)>:where(p,ul,ol,img,table){margin-bottom:var(--spacer-r-24);display:block}.chat-app :where(.text-container)>:where(div){margin:var(--spacer-r-40) 0}.chat-app :where(.text-container)>:where(h1,.h1){margin-bottom:var(--spacer-r-28)}.chat-app :where(.text-container)>:where(h2,.h2,h3,.h3,h4,.h4,h5,.h5,h6,.h6){margin-bottom:var(--spacer-r-20)}.chat-app :where(.text-container)>:where(h1,.h1,h2,.h2,h3,.h3,h4,.h4,h5,.h5,h6,.h6){margin-top:var(--spacer-r-40)}.chat-app :where(.text-container)>:where(ul:not(.no-list-styling),ol:not(.no-list-styling))>:where(li){margin-bottom:var(--spacer-12)}.chat-app :where(.text-container)>:where(ul:not(.no-list-styling),ol:not(.no-list-styling))>:where(li):last-child{margin-bottom:0}.chat-app :where(.text-container)>:where(ol){padding-left:1.5em;list-style-type:decimal;list-style-position:outside}.chat-app :where(.text-container)>:where(ul:not(.no-list-styling))>:where(li){padding-left:1em;position:relative}.chat-app :where(.text-container)>:where(ul:not(.no-list-styling))>:where(li):before{content:"•";font-size:.9em;position:absolute;top:0;left:0}.chat-app :where(.text-container)>:where(hr){height:1px;margin:var(--spacer-r-40) 0;background-color:var(--color-grey-700);background-color:var(--hr-color);border:none}.chat-app :where(.text-container) :where(a:not(.button,.no-link-styling,.reference)){color:var(--anchor-color);font-weight:var(--anchor-font-weight,var(--base-font-weight-normal));-webkit-text-decoration:var(--anchor-text-decoration,underline);text-decoration:var(--anchor-text-decoration,underline);text-underline-offset:var(--anchor-text-underline-offset,.15em);transition-duration:var(--default-transition-duration);transition-property:color,background-color,border-color;transition-timing-function:var(--default-transition-timing-function)}.chat-app :where(.text-container) :where(a:not(.button,.no-link-styling,.reference)):hover{color:var(--anchor-hover-color)}.chat-app :where(.text-container) :where(table){border-collapse:collapse;border-spacing:0;-webkit-overflow-scrolling:touch;width:100%;display:block;overflow-x:auto}.chat-app :where(.text-container) :where(th){width:1000px;padding:var(--spacer-12) var(--spacer-16) var(--spacer-12) 0;border-bottom:1px solid var(--color-grey-300);line-height:var(--base-line-height-tight);text-align:left;vertical-align:bottom}.chat-app :where(.text-container) :where(td){padding:var(--spacer-12) var(--spacer-16) var(--spacer-12) 0;border-bottom:1px solid var(--color-grey-300);vertical-align:top}.chat-app :where(.text-container) :where(tr:last-child td){border-bottom:none}.chat-app :where(.text-container) :where(:first-child){margin-top:0}.chat-app :where(.text-container) :where(:last-child){margin-bottom:0}.chat-app :where(.animated-height){transition:height .5s var(--ease-in-out-quart)}.chat-app :where(.display-contents){display:contents}.chat-app :where(.absolute){position:absolute!important}}@layer components{.chat-app{display:contents}.chat-app__container{height:100%;display:flex;overflow:hidden;transform:translateZ(0);container:chat-container/inline-size}.chat-app__container>:where(*){color:var(--body-color);font-style:normal;font-weight:var(--base-font-weight-normal);font-size:var(--base-font-size-body);line-height:var(--base-line-height-default);font-family:var(--font-family);font-optical-sizing:auto}.chat-app__container.chat-app__container--inline-layout-contained{height:90svh;scroll-margin-top:10svh}@media (width>=768px){.chat-app__container.chat-app__container--inline-layout-contained{height:100svh;scroll-margin-top:0}}.chat-app__main{overscroll-behavior-x:none;overscroll-behavior-y:contain;background:var(--body-background);scrollbar-gutter:stable;touch-action:pan-y;flex-direction:column;width:100%;height:100%;display:flex;overflow:hidden auto;container:chat-inner-container/inline-size}.chat-app__container--inline-layout .chat-app__main{overscroll-behavior-y:auto}.chat-app__loader-container{z-index:var(--z-index-loader);justify-content:center;align-items:center;width:100%;height:100%;display:flex;position:relative}.chat-app__portals{display:contents}.chat-app__header{z-index:var(--z-index-header);background:var(--body-background);position:sticky;top:0}.chat-app__header--unsticked{position:relative}.chat-app__header-content{--btn-padding-x:var(--btn-padding-y);column-gap:var(--spacer-r-12);min-height:calc(var(--btn-padding-y) * 2 + var(--btn-icon-size) + var(--spacer-10) * 2);margin-right:calc(var(--btn-padding-x) * -1);margin-left:calc(var(--btn-padding-x) * -1);padding-top:var(--spacer-10);padding-bottom:var(--spacer-10);flex-wrap:wrap;justify-content:flex-end;align-items:center;display:flex;position:relative}.chat-app__header-content>:where(*){z-index:0;pointer-events:auto;position:relative}.chat-app__header-content:after{right:var(--btn-padding-x);bottom:0;left:var(--btn-padding-x);content:"";border-bottom:1px solid #0000;transition:border-color .1s ease-in-out;position:absolute}.chat-app__header-content.has-border:after{border-color:var(--base-line-color)}.chat-app__header-new-conversation{margin-right:auto;position:relative}@container chat-container (width>=640px){.chat-app__header-new-conversation .tooltip{display:none}}.chat-app__header--with-logo :where(.chat-app__header-content){margin-left:0}.chat-app__header--with-logo :where(.chat-app__header-new-conversation){margin-right:unset;margin-left:auto}.chat-app__header-logo{margin-right:auto}.chat-app__header-logo :where(svg){width:auto;height:var(--spacer-28)}.chat-app__body{flex-direction:column;flex-grow:1;width:100%;display:flex;position:relative}.chat-app__page-transition{flex-direction:column;flex-grow:1;width:100%;height:100%;display:flex}.chat-app__aside{--duration-in:.65s;--duration-out:.5s;visibility:hidden;width:0;transition-delay:0s, var(--duration-out);transition-duration:var(--duration-out), 0s;transition-property:width,visibility;transition-timing-function:var(--ease-in-out-quart), linear;flex-grow:1;position:relative;top:0;bottom:0}.chat-app__aside.open{visibility:visible;width:var(--aside-width);transition-delay:0s;transition-duration:var(--duration-in), 0s;transition-timing-function:var(--ease-out-quart), linear}.chat-app__aside .tooltip{--background-color:var(--btn-secondary-hover-background)}.chat-app__aside-container{width:var(--aside-width);overscroll-behavior:contain;border-left-width:var(--aside-border-width);border-color:var(--aside-border-color);background:var(--aside-background);scrollbar-gutter:stable;height:100%;position:relative;overflow-y:auto}.chat-app__container--inline-layout .chat-app__aside-container{overscroll-behavior-y:auto}.chat-app__aside-header,.chat-app__sheet-header{z-index:var(--z-index-header);flex-wrap:no-wrap;padding:var(--spacer-12) var(--spacer-12) var(--spacer-12) var(--spacer-24);justify-content:space-between;align-items:center;gap:var(--spacer-24);border-bottom-width:var(--aside-header-border-width);border-color:var(--aside-header-border-color);background:var(--aside-background);color:var(--aside-header-color);display:flex;position:sticky;top:0}.chat-app__sheet-close{position:relative}.chat-app__sheet-overlay{z-index:var(--z-index-dialog);background:var(--aside-background-overlay);position:fixed;inset:0}.chat-app__sheet-content{z-index:var(--z-index-flyout);width:100%;max-width:var(--aside-width);overscroll-behavior:contain;border-left-width:var(--aside-border-width);border-color:var(--aside-border-color);background:var(--aside-background);scrollbar-gutter:stable;height:100%;position:fixed;top:0;right:0;overflow-y:auto}.chat-app__container--inline-layout .chat-app__sheet-content{overscroll-behavior-y:auto}:is(.chat-app__aside-close,.chat-app__sheet-close) :where(.btn){background-color:#0000}.chat-app__aside-title,.chat-app__sheet-title{font-size:var(--base-font-size-sm)}.chat-app__close-button{z-index:var(--z-index-flyout)}.open-button{--open-button-avatar-height:var(--spacer-r-80);--open-button-avatar-width:var(--spacer-r-80);--open-button-duration:.4s;--open-button-delay:.3s;--open-button-ease:ease-in-out;cursor:pointer;flex-direction:row;align-items:flex-end;transition:opacity .15s ease-out;display:flex}.open-button--expanded{opacity:0;pointer-events:none}.open-button__text{margin-right:calc(var(--open-button-avatar-width) * -.5);padding-top:var(--spacer-r-12);padding-right:0;padding-bottom:var(--spacer-r-12);border-width:var(--open-button-border-width);border-radius:var(--open-button-border-radius);border-color:var(--open-button-border-color);background:var(--open-button-background);color:var(--open-button-color);text-align:left;transition:transform var(--open-button-duration) var(--open-button-ease), padding-right var(--open-button-duration) var(--open-button-delay) var(--open-button-ease);flex-direction:column;justify-content:center;align-items:flex-start;padding-left:0;display:flex;position:absolute;bottom:50%;right:100%;overflow:hidden;transform:translateY(50%);box-shadow:0 4px 6px -1px #0000001a,0 2px 4px -2px #0000001a}.open-button:is(:hover,.open-button--programmatic-expand) .open-button__text{background:var(--open-button-hover-background,var(--open-button-background));color:var(--open-button-hover-color,var(--open-button-color));opacity:1;transition:transform var(--open-button-duration) var(--open-button-delay) var(--open-button-ease);transform:translateY(0)}.open-button__title{max-width:240px;padding:0 calc(var(--open-button-avatar-width) * .5 + var(--spacer-r-12)) 0 var(--spacer-r-12);white-space:pre;font-weight:700}.open-button__mask{width:0;height:0;transition:width var(--open-button-duration) var(--open-button-delay) var(--open-button-ease), height var(--open-button-duration) var(--open-button-ease);overflow:hidden}.open-button:is(:hover,.open-button--programmatic-expand) .open-button__mask{transition:width var(--open-button-duration) var(--open-button-ease), height var(--open-button-duration) var(--open-button-delay) var(--open-button-ease)}.open-button__description{width:50cqw;max-width:260px;padding:0 calc(var(--open-button-avatar-width) * .5 + var(--spacer-r-12)) 0 var(--spacer-r-12);text-wrap:balance;position:relative}.open-button__avatar{z-index:var(--z-index-local-overlay);width:var(--open-button-avatar-width);height:var(--open-button-avatar-height);border-radius:var(--spacer-r-80);filter:drop-shadow(0 4px 6px #00000026);transition:transform .2s var(--open-button-ease);position:relative;overflow:clip}.open-button:is(:hover,.open-button--programmatic-expand) .open-button__avatar{transform:scale(1.05)}.open-button__link-icon{width:var(--spacer-r-80);height:var(--spacer-r-80);padding:var(--spacer-r-20);color:var(--open-button-color);display:none;position:absolute;right:0}:where(.open-button--standalone){right:var(--spacer-r-16);bottom:var(--spacer-r-16);position:fixed}@media (prefers-reduced-motion:reduce){.open-button__text,.open-button__mask,.open-button:hover .open-button__text,.open-button:hover .open-button__mask{transition:none!important}.open-button__avatar,.open-button:hover .open-button__avatar{filter:none!important;transition:none!important}}.open-button--hide-title-when-collapsed .open-button__text{visibility:hidden;opacity:0;transition:transform var(--open-button-duration) var(--open-button-ease), padding-right var(--open-button-duration) var(--open-button-delay) var(--open-button-ease), opacity var(--open-button-duration) var(--open-button-delay) var(--open-button-ease), visibility 0s linear calc(var(--open-button-duration) + var(--open-button-delay))}.open-button--hide-title-when-collapsed:is(:hover,.open-button--programmatic-expand) .open-button__text{visibility:visible;background:var(--open-button-hover-background,var(--open-button-background));color:var(--open-button-hover-color,var(--open-button-color));opacity:1;transition:transform var(--open-button-duration) var(--open-button-delay) var(--open-button-ease), opacity var(--open-button-duration) var(--open-button-ease), visibility 0s linear 0s;transform:translateY(0)}}@value container-xs, container-sm, container-md, container-lg, container-inner-xs, container-inner-sm, container-inner-md, container-inner-lg from "./viewports.css";`,DF=typeof window<`u`?window:{screen:{},navigator:{}},OF=(DF.matchMedia||(function(){return{matches:!1}})).bind(DF),kF={get passive(){return!0}},AF=function(){};DF.addEventListener&&DF.addEventListener(`p`,AF,kF),DF.removeEventListener&&DF.removeEventListener(`p`,AF,!1),`PointerEvent`in DF;var jF=`ontouchstart`in DF,MF=`TouchEvent`in DF,NF=jF||MF&&OF(`(any-pointer: coarse)`).matches,PF=(DF.navigator.maxTouchPoints||0)>0||NF,FF=DF.navigator.userAgent||``,IF=OF(`(pointer: coarse)`).matches&&/iPad|Macintosh/.test(FF)&&Math.min(DF.screen.width||0,DF.screen.height||0)>=768,LF=(OF(`(pointer: coarse)`).matches||!OF(`(pointer: fine)`).matches&&jF)&&!/Windows.*Firefox/.test(FF),RF=OF(`(any-pointer: fine)`).matches||OF(`(any-hover: hover)`).matches||IF||!jF,zF=PF&&(RF||!LF)?`hybrid`:PF?`touchOnly`:`mouseOnly`,BF=zF===`mouseOnly`?`mouse`:zF===`touchOnly`||LF?`touch`:`mouse`,VF=R(`<div class="open-button__title"></div>`),HF=R(`<div class="open-button__mask"><div class="open-button__description"></div></div>`),UF=R(`<div class="open-button__text"><!> <!></div>`),WF=R(`<div class="sr-only"> </div>`),GF=R(`<!> <div class="svg svg--avatar open-button__avatar" aria-hidden="true"></div>`,1),KF=R(`<link rel="stylesheet"/>`),qF=R(`<!> <!>`,1),JF=R(`<!> <!> <!> <main class="chat-app"><!></main>`,1);function YF(e,t){D(t,!0);let n=(e,n)=>{let r=()=>n?.().chatConfig,i=()=>n?.().language,a=()=>n?.().colorScheme,c=A(()=>{let{openButtonTitle:e,openButtonDescription:t}=r().translations[i()];return{openButtonTitle:e,openButtonDescription:t}}),l=A(()=>r().fullTheme[a()].tokens.svgs),u=A(()=>r().fullTheme[a()]?.tokens.components.openButton?.custom),d=A(()=>!!L(u)?.hideTitleWhenCollapsed);{let n=A(()=>r().buttonHref?void 0:s()?`true`:`false`),i=A(()=>r().buttonHref?void 0:`true`),a=A(()=>r().buttonHref?void 0:o()),u=A(()=>[`open-button`,t.buttonClass,Z.data.flyoutIsOpen?`open-button--expanded`:void 0,L(d)?`open-button--hide-title-when-collapsed`:void 0]);KA(e,{get href(){return r().buttonHref},onclick:de,onmouseenter:le,onmouseleave:ue,use:w,get"aria-expanded"(){return L(n)},get"aria-haspopup"(){return L(i)},get"aria-controls"(){return L(a)},get style(){return t.buttonStyle},get className(){return L(u)},get isStandalone(){return L(f)},children:(e,t)=>{var n=GF(),r=P(n),i=e=>{var t=UF(),n=N(t),r=e=>{var t=VF();na(t,()=>L(c).openButtonTitle,!0),E(t),B(e,t)};U(n,e=>{L(c).openButtonTitle&&e(r)});var i=F(n,2),a=e=>{var t=HF(),n=N(t);na(n,()=>L(c).openButtonDescription,!0),E(n),so(n,e=>M(v,e),()=>L(v)),E(t),so(t,e=>M(_,e),()=>L(_)),B(e,t)};U(i,e=>{L(c).openButtonDescription&&BF===`mouse`&&e(a)}),E(t),B(e,t)},a=e=>{var t=WF(),n=N(t,!0);E(t),I(()=>V(n,Z.t.ariaOpenChat)),B(e,t)};U(r,e=>{L(c).openButtonTitle||L(c).openButtonDescription?e(i):e(a,-1)});var o=F(r,2);na(o,()=>L(l).avatar,!0),E(o),B(e,n)},$$slots:{default:!0}})}},r=j(`light`),i=K(t,`host`,7),a=K(t,`onError`,7),o=K(t,`flyoutId`,7),s=K(t,`flyoutIsOpen`,7),c=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`host`,`onError`,`flyoutId`,`flyoutIsOpen`]),l=async e=>{let t=await(await fetch(`${e}/chatconfig`)).json();return Gg.parse(t)},u=async({forceTheme:e,lang:t,apiUrl:n})=>{let r=L_(window.CHAT_CONFIG_OVERRIDE?window.CHAT_CONFIG_OVERRIDE:await l(n)),i;i=t?V_(t,r.supportedLanguages):W_(r.supportedLanguages);let a=Fy(Object.keys(r.fullTheme));return{chatConfig:r,language:i,colorScheme:a}},d=(e,t)=>{if(e==null)return t;if(typeof e==`string`){let t=e.trim().toLowerCase();return!(t===``||t===`0`||t===`false`||t===`no`)}return typeof e==`number`?e!==0:typeof e==`boolean`?e:t},f=A(()=>!!i()),p=j(!1),m=j(!1),h=j(!1),g=j(void 0),_=j(void 0),v=j(void 0),y=A(()=>L(v)?.offsetWidth??0),b=A(()=>L(v)?.offsetHeight??0),x=j(void 0),S=j(!1),C,ee=j(!0);function te(){return L(x)?(clearTimeout(L(x)),M(x,void 0),!0):!1}async function ne(e){M(r,e.colorScheme,!0),C?.(),te(),M(S,!1);let n=e.chatConfig.fullTheme[L(r)]?.tokens.components.openButton?.custom??{},i=n.autoExpandScrollThreshold,a=Number(n.autoCollapseDelay??0),o=Number.isNaN(a)?0:Math.max(0,a),c=d(n.autoExpandOnce,!1),l=(()=>{if(i==null)return 100;if(typeof i==`string`){if(i.trim().toLowerCase()===`none`)return 0;let e=Number(i);return Number.isNaN(e)?100:e}let e=Number(i);return Number.isNaN(e)?100:e})();if(Number.isNaN(l)||l<=0)return;let u=`liipgpt-auto-expand-${t.apiUrl}`,f=!1;if(typeof window<`u`)try{f=window.localStorage.getItem(u)===`true`}catch(e){console.warn(`LiipGPT: unable to read auto-expand flag`,e)}M(h,f,!0);let p=()=>{if(!(window.scrollY/window.innerHeight*100>=l)){M(ee,!0);return}if(!(L(m)||s())&&!(c&&(f||L(h)))&&L(ee)){if(M(ee,!1),M(m,!0),M(h,!0),se(),c&&typeof window<`u`)try{window.localStorage.setItem(u,`true`)}catch(e){console.warn(`LiipGPT: unable to persist auto-expand flag`,e)}M(x,setTimeout(()=>{L(S)||(ce(),M(m,!1)),M(x,void 0)},o),!0)}};window.addEventListener(`scroll`,p,{passive:!0}),l===0&&(await qr(),p()),C=()=>{window.removeEventListener(`scroll`,p)}}function re(){te(),M(m,!1),M(S,!1)}function w(e){M(g,e,!0)}function ie(){C?.(),te()}Li(ie);function ae(){!L(v)||!L(_)||(L(_).style.width=`${L(y)}px`,L(_).style.height=`${L(b)}px`)}function oe(){L(_)&&(L(_).style.width=`0`,L(_).style.height=`0`)}function se(){L(g)&&(L(g).classList.add(`open-button--programmatic-expand`),ae())}function ce(){L(g)&&(L(g).classList.remove(`open-button--programmatic-expand`),oe())}function le(){te()&&M(S,!0),ae()}function ue(){te(),L(S)&&(M(m,!1),M(S,!1),L(g)?.classList.remove(`open-button--programmatic-expand`)),L(p)||oe()}function de(e){re(),t.onclick?.(e)}let fe=A(()=>u(c).then(async e=>(await ne(e),e)).catch(e=>a()(e)));var pe={get host(){return i()},set host(e){i(e),k()},get onError(){return a()},set onError(e){a(e),k()},get flyoutId(){return o()},set flyoutId(e){o(e),k()},get flyoutIsOpen(){return s()},set flyoutIsOpen(e){s(e),k()}},me=z();return ii(`beforeunload`,An,ie),ha(`1k415fq`,e=>{var t=z(),n=P(t),r=e=>{var t=z();Ui(P(t),()=>L(fe),null,(e,t)=>{let n=A(()=>L(t).chatConfig.fullTheme[L(t).colorScheme]);var r=qF(),i=P(r);Xi(i,17,()=>L(n).fontURLs??[],Ki,(e,t)=>{var n=KF();I(()=>G(n,`href`,L(t))),B(e,n)}),bF(F(i,2),{id:`font-css`,get css(){return L(n).fontCSS}}),B(e,r)}),B(e,t)};U(n,e=>{L(f)&&e(r)}),B(e,t)}),Ui(P(me),()=>L(fe),e=>{},(e,t)=>{let i=A(()=>L(t).chatConfig.fullTheme[L(r)]);var a=z(),o=P(a),s=e=>{var r=JF(),a=P(r);{let e=A(()=>yF(L(i).tokens));bF(a,{id:`theme-css`,get css(){return L(e)}})}var o=F(a,2);bF(o,{id:`app-css`,get css(){return EF}});var s=F(o,2);bF(s,{id:`custom-css`,get css(){return L(i).customCSS}});var c=F(s,2);n(N(c),()=>L(t)),E(c),B(e,r)},c=e=>{n(e,()=>L(t))};U(o,e=>{L(f)?e(s):e(c,-1)}),B(e,a)}),B(e,me),O(pe)}q(YF,{host:{},onError:{},flyoutId:{},flyoutIsOpen:{}},[],[],{mode:`open`});var XF=R(`<div class="flyout__backdrop"></div>`),ZF=R(`<div class="flyout__content"><!></div>`),QF=R(`<div><!> <div class="flyout__body"><!> <div><!></div></div></div>`),$F=R(`<!> <div class="chat-app__container"><div class="chat-app__loader-container"><!></div></div>`,1);function eI(e,t){D(t,!0);let n=K(t,`children`,7),r=K(t,`loaderColor`,7),i=K(t,`loaderBackground`,7),a=K(t,`flyout`,7),o=K(t,`flyoutClass`,7),s=K(t,`flyoutStyle`,7),c=K(t,`onCloseChat`,7),l=K(t,`onError`,7),u=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`children`,`loaderColor`,`loaderBackground`,`flyout`,`flyoutClass`,`flyoutStyle`,`onCloseChat`,`onError`]),d=A(()=>Z.theme?.components?.flyout?.custom??{}),f=A(()=>({enabled:Z.data?.chatConfig?.enableBackdrop??!1,delayIn:Number(L(d).backdropDelayIn??0),durationIn:Number(L(d).backdropDurationIn??200),delayOut:Number(L(d).backdropDelayOut??0),durationOut:Number(L(d).backdropDurationOut??200),baseScaleIn:Number(L(d).backdropBaseScaleIn??1),baseScaleOut:Number(L(d).backdropBaseScaleOut??1),transformOrigin:String(L(d).backdropTransformOrigin??`center`),scaleDirection:String(L(d).backdropScaleDirection??`scale`)})),p=A(()=>({in:{delay:L(f).delayIn,duration:L(f).durationIn,baseScale:L(f).baseScaleIn,transformOrigin:L(f).transformOrigin,scaleDirection:L(f).scaleDirection},out:{delay:L(f).delayOut,duration:L(f).durationOut,baseScale:L(f).baseScaleOut,transformOrigin:L(f).transformOrigin,scaleDirection:L(f).scaleDirection}})),m,h=e=>{$n(()=>{let t=e=>{m=e};return e.addEventListener(`click`,t),()=>{e.removeEventListener(`click`,t),m=void 0}})},g=`flyout`,_=j(void 0),v=A(()=>Z.data.flyoutIsOpen),y=j(!1),b=A(()=>Z.initialized),x=A(()=>Z.data.hasOpenedOverlays);$n(()=>{!Z.data.flyoutIsOpen&&L(y)&&(L(_)?.querySelector(`button`))?.focus({preventScroll:!0}),M(y,L(v),!0)}),$n(()=>{if(L(b)&&L(v)){let e=e=>{e.key===`Escape`&&(L(x)||c()())};return document.addEventListener(`keydown`,e),()=>{document.removeEventListener(`keydown`,e)}}});var S={get children(){return n()},set children(e){n(e),k()},get loaderColor(){return r()},set loaderColor(e){r(e),k()},get loaderBackground(){return i()},set loaderBackground(e){i(e),k()},get flyout(){return a()},set flyout(e){a(e),k()},get flyoutClass(){return o()},set flyoutClass(e){o(e),k()},get flyoutStyle(){return s()},set flyoutStyle(e){s(e),k()},get onCloseChat(){return c()},set onCloseChat(e){c(e),k()},get onError(){return l()},set onError(e){l(e),k()}},C=z();ii(`click`,An,e=>{e!==m&&a()&&c()()});var ee=P(C),te=e=>{var t=z(),r=P(t),i=e=>{},a=e=>{var t=QF(),r=N(t),i=e=>{var t=XF();fa(1,t,()=>SF,()=>({...L(p).in,easing:xA})),fa(2,t,()=>SF,()=>({...L(p).out,easing:xA})),B(e,t)};U(r,e=>{Z.data.flyoutIsOpen&&L(f).enabled&&e(i)});var a=F(r,2);G(a,`id`,g);var c=N(a),d=e=>{var t=ZF();H(N(t),n),E(t),fa(1,t,()=>SF,()=>({delay:0,duration:500,easing:xA,baseScale:.3})),fa(2,t,()=>SF,()=>({delay:100,duration:300,easing:xA,baseScale:.7})),B(e,t)};U(c,e=>{Z.data.flyoutIsOpen&&e(d)});var m=F(c,2);YF(N(m),mo({get onError(){return l()},onclick:e=>{e.stopPropagation(),db.openFlyout()},flyoutId:g,get flyoutIsOpen(){return L(v)},buttonClass:`flyout__open-button`},()=>u)),E(m),so(m,e=>M(_,e),()=>L(_)),E(a),_a(a,e=>h?.(e)),E(t),I(()=>{ka(t,s()),Da(t,1,xa([`flyout`,o()]))}),B(e,t)};U(r,e=>{Z.initialized?e(a,-1):e(i)}),B(e,t)},ne=e=>{var a=z(),o=P(a),s=e=>{var n=$F(),a=P(n);bF(a,{id:`app-css`,get css(){return xF}});var o=F(a,2),s=N(o);ra(N(s),t,`loader`,{},e=>{TF(e,{get background(){return i()},get color(){return r()}})}),E(s),E(o),fa(2,o,()=>UN,()=>({duration:200,delay:300})),B(e,n)},c=e=>{var t=z();H(P(t),n),B(e,t)};U(o,e=>{Z.initialized?e(c,-1):e(s)}),B(e,a)};return U(ee,e=>{a()?e(te):e(ne,-1)}),B(e,C),O(S)}q(eI,{children:{},loaderColor:{},loaderBackground:{},flyout:{},flyoutClass:{},flyoutStyle:{},onCloseChat:{},onError:{}},[`loader`],[],{mode:`open`});var tI=R(`<button type="button"> </button>`),nI=R(`<div class="dialog-footer__actions"></div>`);function rI(e,t){D(t,!1);function n(e){let t=db[e];typeof t==`function`&&t()}co();{let t=e=>{var t=z();na(P(t),()=>Z.data.openedPopup?.title),B(e,t)},r=e=>{var t=z();na(P(t),()=>Z.data.openedPopup?.content),B(e,t)},i=e=>{var t=z(),r=P(t),i=e=>{var t=nI();Xi(t,5,()=>Z.data.openedPopup.actions,Ki,(e,t)=>{let r=()=>L(t).action,i=()=>L(t).label,a=()=>L(t).type;var o=tI(),s=N(o,!0);E(o),I(()=>{Da(o,1,`btn btn--${a()??`secondary`??``}`),V(s,i())}),ai(`click`,o,()=>n(r())),B(e,o)}),E(t),B(e,t)};U(r,e=>{Z.data.openedPopup?.actions?.length&&e(i)}),B(e,t)},a=dn(()=>Z.data.openedPopup!==void 0);Wj(e,{get open(){return L(a)},get onClose(){return db.closePopup},title:t,content:r,footer:i,$$slots:{title:!0,content:!0,footer:!0}})}O()}oi([`click`]),q(rI,{},[],[],{mode:`open`});var iI=R(`<span class="reference__description line-clamp line-clamp--6"> </span>`),aI=R(`<span class="reference__breadcrumb transition-colors"> </span>`),oI=R(`<span class="reference__footer"><span class="reference__domain transition-colors"><span class="truncate"> </span></span> <!></span>`),sI=R(`<div class="reference-number__content-wrapper" role="tooltip" aria-hidden="true"><a class="reference-number__content transition-colors no-link-styling" target="_blank" rel="noopener noreferrer" tabindex="-1" aria-hidden="true"><span class="reference__header"><h3 class="reference__title line-clamp line-clamp--2 h4"> </h3> <!></span> <!> <!></a></div>`),cI=R(`<div class="reference-number"><a target="_blank" rel="noopener noreferrer" class="reference-number__trigger transition-colors no-link-styling"> </a> <!></div>`);function lI(e,t){D(t,!0);let n=A(()=>Z.t),r=K(t,`usedNumber`,7),i=K(t,`source`,7),a=j(!1),o,s=j(void 0),c=j(void 0),l=A(i),u=A(()=>L(l).display.card.title),d=A(()=>L(l).display.card.description),f=A(()=>L(l).display.card.badge),p=A(()=>L(l).display.card.breadcrumbs),m={duration:Number(Z.theme.components.referenceNumberContent.custom?.transitionDuration)||200,delay:Number(Z.theme.components.referenceNumberContent.custom?.transitionDelay)||0,y:Number(Z.theme.components.referenceNumberContent.custom?.transitionY)||10},h=async()=>{if(!L(s)||!L(c))return;let{x:e,y:t}=await lO(L(s),L(c),{placement:`top`,middleware:[nO(8),iO(),rO({padding:8})]});Object.assign(L(c).style,{left:`${e}px`,top:`${t}px`})},g=()=>{o&&=(clearTimeout(o),void 0)},_=()=>{g(),o=setTimeout(()=>{M(a,!1)},100)},v=`tooltip-${e_()}`,y=e=>{e.key===`Escape`&&M(a,!1)},b=()=>{g(),M(a,!0)};$n(()=>{L(a)?document.addEventListener(`keydown`,y):document.removeEventListener(`keydown`,y)}),$n(()=>{L(a)&&h()});var x={get usedNumber(){return r()},set usedNumber(e){r(e),k()},get source(){return i()},set source(e){i(e),k()}},S=cI(),C=N(S),ee=N(C,!0);E(C),so(C,e=>M(s,e),()=>L(s));var te=F(C,2),ne=e=>{var t=sI(),n=N(t),r=N(n),i=N(r),a=N(i,!0);E(i),_b(F(i,2),{name:`externalLink`,class:`reference__icon transition-colors`}),E(r);var o=F(r,2),s=e=>{var t=iI(),n=N(t,!0);E(t),I(()=>V(n,L(d))),B(e,t)};U(o,e=>{L(d)&&e(s)});var h=F(o,2),g=e=>{var t=oI(),n=N(t),r=N(n),i=N(r,!0);E(r),E(n);var a=F(n,2),o=e=>{var t=z();Xi(P(t),17,()=>L(p),Ki,(e,t)=>{var n=aI(),r=N(n,!0);E(n),I(()=>V(r,L(t))),B(e,n)}),B(e,t)};U(a,e=>{L(p)&&e(o)}),E(t),I(()=>V(i,L(f))),B(e,t)};U(h,e=>{L(f)&&e(g)}),E(n),E(t),so(t,e=>M(c,e),()=>L(c)),I(()=>{G(t,`id`,v),G(n,`href`,L(l).url),V(a,L(u))}),ii(`mouseenter`,t,b),ii(`mouseleave`,t,_),fa(3,t,()=>EA,()=>m),B(e,t)};return U(te,e=>{L(a)&&e(ne)}),E(S),I(()=>{G(C,`href`,L(l).url),G(C,`aria-describedby`,L(a)?v:void 0),G(C,`aria-label`,`${L(n).referenceLink??``}: ${L(u)??``}`),G(C,`data-state`,L(a)?`open`:`closed`),V(ee,r())}),ii(`mouseenter`,C,b),ii(`mouseleave`,C,_),ii(`focus`,C,()=>M(a,!0)),ii(`blur`,C,()=>M(a,!1)),B(e,S),O(x)}customElements.define(`liipgpt-reference-number`,q(lI,{source:{attribute:`data-source`,type:`Object`},refNumber:{attribute:`data-all-index`,type:`String`},usedNumber:{attribute:`data-used-index`,type:`String`}},[],[]));var uI=`main-navigation`,dI=e=>{e.preventDefault(),Z.targets.chatAppMainNavigation&&(Z.targets.chatAppMainNavigation.scrollIntoView({behavior:`smooth`,block:`start`}),Z.targets.chatAppMainNavigation.focus())},fI=R(`<link rel="stylesheet"/>`),pI=R(`<link rel="stylesheet"/>`),mI=R(`<!> <!> <!>`,1),hI=R(`<link rel="stylesheet"/>`),gI=R(`<!> <!> <!> <!>`,1),_I=R(`<h1 class="sr-only"> </h1>`),vI=R(`<h2 class="sr-only absolute"> </h2>`),yI=R(`<div class="chat-app__header-logo"></div>`),bI=R(`<!> <!> <!>`,1),xI=R(`<!> <!> <!> <!>`,1),SI=R(`<div class="chat-app__page-transition"><!></div>`),CI=R(`<div><div class="chat-app__main"><div class="chat-app__portals"></div> <!> <div><div class="container"><!> <!> <div id="chat-app-header-portal"></div></div></div> <div class="chat-app__body"><!> <!></div></div> <!> <!></div>`),wI=R(`<div><!> <!></div>`);function TI(e,t){D(t,!0);let n=K(t,`host`,7),r=K(t,`onError`,7),i=fo(t,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`host`,`onError`]);$n(()=>{let e={forceTheme:t.forceTheme,apiUrl:t.apiUrl,apiKey:t.apiKey,speechRecognitionApiKey:t.speechRecognitionApiKey,lang:t.lang,features:t.features,loaderBackground:t.loaderBackground,loaderColor:t.loaderColor,flyout:t.flyout,flyoutStyle:t.flyoutStyle,flyoutClass:t.flyoutClass,chatClass:t.chatClass,inlineLayout:t.inlineLayout,forceChatPage:t.forceChatPage,hidePredefinedQuestions:t.hidePredefinedQuestions,autofirePredefinedQuestionId:t.autofirePredefinedQuestionId,additionalStartParameters:t.additionalStartParameters,question:t.question,mode:t.mode,source:t.source,cache:t.cache};Xr(()=>db.init(e).catch(e=>r()(e)))});let a=A(()=>Z.data.route.name),o=()=>{db.closeFlyout(),n().dispatchEvent(new CustomEvent(`closechat`))};$n(()=>{Z.initialized&&Z.data?.chatConfig&&n().dispatchEvent(new CustomEvent(`configloaded`,{detail:Z.data.chatConfig}))});let s=j(void 0),c=j(null),l=k_.fineGrained?.light?.tokens?.components?.aside?.custom?.containerWidthForMobileLayout,u=j(!1),d=A(()=>L(c)?Z.data.props?.flyout||L(c)<=l:null),f=j(void 0),p=j(!1),m=j(0);$n(()=>{if(L(f)&&L(f).firstElementChild instanceof HTMLElement){let e=getComputedStyle(L(f).firstElementChild);M(m,parseFloat(e.paddingTop)||0,!0)}}),$n(()=>{let e=!1,t=()=>{e||(e=!0,requestAnimationFrame(()=>{L(s)&&(e=!1,Z.targets.scrollContainer?.scrollTop===0&&y(),M(p,L(s).scrollTop>=L(m)+1))}))};return t(),L(s)?.addEventListener(`scroll`,t,{passive:!0}),()=>L(s)?.removeEventListener(`scroll`,t)});let h=()=>{db.closeReferencesAside()};$n(()=>{Z.initialized&&Z.data.currentReferencesAsideId?M(u,!0):M(u,!1)});let g=j(void 0),_,v=j(!1),y=()=>{M(v,!1),_?.disconnect(),_=new IntersectionObserver(([e])=>{e.isIntersecting?(M(v,!0),_.disconnect()):M(v,!1)},{root:Z.targets.scrollContainer,rootMargin:`-15% 0px 0px 0px`}),L(g)&&_.observe(L(g))};Ii(()=>{if(L(g))return y(),window.addEventListener(`resize`,y),()=>{_?.disconnect(),window.removeEventListener(`resize`,y)}});let b=A(()=>Z.initialized);$n(()=>{L(b)&&L(d)!==null&&Xr(()=>db.setAsideMobile(L(d)))});let x=j(void 0),S=A(()=>Z.data?.chatConfig?.inlineLayout&&!Z.data.props.flyout);$n(()=>{let e=0,t=()=>{e=window.visualViewport?.height??window.innerHeight},n=new ResizeObserver(()=>{let t=window.innerWidth<768?.9:1;L(x)&&L(x).offsetHeight>e*t&&(Z.data.isInlineLayoutContained=!0,requestAnimationFrame(()=>{L(x)?.offsetHeight,window.dispatchEvent(new Event(`resize`))}))}),r=[`mouseup`,`click`],i=!1;Ay()||r.push(`keydown`);let a=()=>{i||(i=!0,L(x)?.scrollIntoView({behavior:`smooth`}),setTimeout(()=>{i=!1},300))};return L(S)&&L(x)&&(t(),window.visualViewport?.addEventListener(`resize`,t),window.addEventListener(`resize`,t),n.observe(L(x)),r.forEach(e=>{L(x).addEventListener(e,a,!0)})),()=>{L(x)&&r.forEach(e=>{L(x).removeEventListener(e,a,!0)}),n.disconnect(),window.visualViewport?.removeEventListener(`resize`,t),window.removeEventListener(`resize`,t)}});let C=A(()=>Z.data.props?.flyout);return $n(()=>{L(b)&&L(C)&&(n().setAttribute(`role`,`region`),Xr(()=>{n().setAttribute(`aria-label`,Z.t.ariaFlyoutRegion)}))}),ha(`3hann0`,e=>{var t=z(),n=P(t),r=e=>{var t=mI(),n=P(t);Xi(n,17,()=>Z.themeBase.fontURLs??[],Ki,(e,t)=>{var n=fI();I(()=>G(n,`href`,L(t))),B(e,n)});var r=F(n,2);Xi(r,17,()=>Z.data.additionalStylesheets,Ki,(e,t)=>{var n=pI();I(()=>G(n,`href`,L(t))),B(e,n)}),bF(F(r,2),{id:`font-css`,get css(){return Z.themeBase.fontCSS}}),B(e,t)};U(n,e=>{Z.initialized&&e(r)}),B(e,t)}),ZT(e,{get defaultPortalTo(){return L(s)},children:(e,n)=>{var l=wI();let m;var _=N(l),y=e=>{var t=gI(),n=P(t);{let e=A(()=>yF(Z.theme));bF(n,{id:`theme-css`,get css(){return L(e)}})}var r=F(n,2);bF(r,{id:`app-css`,get css(){return xF}});var i=F(r,2);bF(i,{id:`custom-css`,get css(){return Z.themeBase.customCSS}}),Xi(F(i,2),17,()=>Z.data.additionalStylesheets,Ki,(e,t)=>{var n=hI();I(()=>G(n,`href`,L(t))),B(e,n)}),B(e,t)};U(_,e=>{Z.initialized&&e(y)}),eI(F(_,2),mo({onCloseChat:o,get onError(){return r()}},()=>i,{children:(e,t)=>{var n=CI(),r=N(n),i=N(r);_a(i,(e,t)=>pb?.(e,t),()=>`portals`);var l=F(i,2);hb(l,{});var m=F(l,2),_=N(m),y=N(_),b=e=>{var t=_I(),n=N(t,!0);E(t),I(()=>V(n,Z.t.ariaPageTitle)),B(e,t)};U(y,e=>{!L(C)&&!L(S)&&e(b)});var ee=F(y,2);ma(ee,()=>Z.hasMainNavigationContent?`nav`:`div`,!1,(e,t)=>{_a(e,(e,t)=>pb?.(e,t),()=>`chatAppMainNavigation`),Ja(e,()=>({class:`chat-app__header-content`,"aria-label":Z.hasMainNavigationContent?Z.ariaMainNavigationRegion:void 0,tabindex:Z.hasMainNavigationContent?-1:void 0,id:uI,[Pa]:{"has-border":L(p)}}));var n=xI(),r=P(n),i=e=>{var t=vI(),n=N(t,!0);E(t),I(()=>V(n,Z.t.ariaMainNavigation)),B(e,t)};U(r,e=>{Z.hasMainNavigationContent&&e(i)});var s=F(r,2),c=e=>{var t=yI();na(t,()=>Z.theme.svgs.headerLogo,!0),E(t),B(e,t)};U(s,e=>{Z.theme.svgs.headerLogo&&e(c)});var l=F(s,2),u=e=>{PN(e,{class:`chat-app__header-new-conversation`})};U(l,e=>{L(a)===`chat-page`&&!Z.data.chatConfig.forceChatPage&&e(u)});var d=F(l,2),f=e=>{var t=bI(),n=P(t),r=e=>{{let t=A(()=>Z.t.aboutThisChat||``);pN(e,{get content(){return L(t)}})}};U(n,e=>{Z.data.chatConfig.showContextInfo&&e(r)});var i=F(n,2),a=e=>{jN(e,{})};U(i,e=>{Z.data.chatConfig.showContextMenu&&e(a)});var s=F(i,2),c=e=>{Lj(e,{onclick:o})};U(s,e=>{(Z.data.chatConfig.showCloseChatButton||Z.data.props.flyout)&&e(c)}),B(e,t)};U(d,e=>{Z.initialized&&e(f)}),B(t,n)}),_a(F(ee,2),(e,t)=>pb?.(e,t),()=>`chatAppHeaderPortal`),E(_),E(m),so(m,e=>M(g,e),()=>L(g)),_a(m,(e,t)=>pb?.(e,t),()=>`chatAppHeader`);var te=F(m,2),ne=N(te);rI(ne,{}),Gi(F(ne,2),()=>L(a),e=>{var t=SI(),n=N(t),r=e=>{oN(e,{})},i=e=>{oP(e,{})},o=e=>{eN(e,{})};U(n,e=>{L(a)===`consent-page`?e(r):L(a)===`start-page`?e(i,1):L(a)===`chat-page`&&e(o,2)}),E(t),so(t,e=>M(f,e),()=>L(f)),fa(1,t,()=>TA,()=>({duration:300,delay:250})),fa(2,t,()=>UN,()=>({duration:150})),B(e,t)}),E(te),E(r),so(r,e=>M(s,e),()=>L(s)),_a(r,(e,t)=>pb?.(e,t),()=>`scrollContainer`);var re=F(r,2),w=e=>{Fj(e,{get isOpen(){return L(u)},get isMobile(){return L(d)},get showReferencesByDefault(){return Z.data.chatConfig.showReferencesByDefault},onClose:h,get title(){return Z.t.referencesTitle},children:(e,t)=>{QN(e,{})},$$slots:{default:!0}})};U(re,e=>{L(d)!==null&&e(w)}),_y(F(re,2),{position:`top-center`,get containerAriaLabel(){return Z.t.ariaNotifications}}),E(n),ir(()=>ao(n,`clientWidth`,e=>M(c,e))),so(n,e=>M(x,e),()=>L(x)),_a(n,(e,t)=>pb?.(e,t),()=>`chatAppContainer`),I(()=>{Da(n,1,xa([`chat-app__container`,{"chat-app__container--inline-layout":L(S),"chat-app__container--inline-layout-contained":Z.data.isInlineLayoutContained}])),Da(m,1,xa([`chat-app__header`,{"chat-app__header--unsticked":L(v),"chat-app__header--with-logo":Z.theme.svgs.headerLogo}]))}),B(e,n)},$$slots:{default:!0}})),E(l),I(()=>{Da(l,1,xa([`chat-app`,t.chatClass])),G(l,`role`,!L(C)&&!L(S)?`main`:void 0),m=ka(l,``,m,{"color-scheme":Z.colorScheme||`light`})}),B(e,l)},$$slots:{default:!0}}),O({get host(){return n()},set host(e){n(e),k()},get onError(){return r()},set onError(e){r(e),k()}})}q(TI,{host:{},onError:{}},[],[],{mode:`open`});var EI=R(`<div class="chat-app__container"><div class="error-message svelte-14mj70v">Server is unreachable, please try later... <button class="error-message__retry-button svelte-14mj70v">Retry</button></div></div>`),DI=R(` <!>`,1),OI={hash:`svelte-14mj70v`,code:`
|
|
584
584
|
/* These styles are inline, because at this point theme loading has failed. */.error-message.svelte-14mj70v {display:table;z-index:1000;width:auto;margin:2rem auto;padding:2rem;border-radius:2px;background:white;color:oklch(27.8% 0.033 256.848);font-family:-apple-system,
|
|
585
585
|
BlinkMacSystemFont,
|
|
586
586
|
avenir next,
|
|
@@ -593,5 +593,5 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
593
593
|
roboto,
|
|
594
594
|
noto,
|
|
595
595
|
arial,
|
|
596
|
-
sans-serif;}.error-message__retry-button.svelte-14mj70v {border:none;outline:none;background:none;font-size:1rem;text-decoration:underline;&:active {outline:none;}}`};function
|
|
597
|
-
`,t())??``]),B(e,r)},r=K(t,`body`,7),i=K(t,`silent`,7),a=j(void 0),o=e=>{M(a,{error:e},!0)};var s={get body(){return r()},set body(e){r(e),k()},get silent(){return i()},set silent(e){i(e),k()}},c=z();return nn(P(c),{get failed(){return n}},e=>{var t=z(),i=P(t),s=e=>{n(e,()=>L(a).error,()=>()=>{M(a,void 0)})},c=e=>{var t=z();H(P(t),r,()=>o),B(e,t)};U(i,e=>{L(a)?e(s):e(c,-1)}),B(e,t)}),B(e,c),O(s)}oi([`click`]),q(
|
|
596
|
+
sans-serif;}.error-message__retry-button.svelte-14mj70v {border:none;outline:none;background:none;font-size:1rem;text-decoration:underline;&:active {outline:none;}}`};function kI(e,t){D(t,!0),ga(e,OI);let n=(e,t=w,n=w)=>{Ze();var r=DI(),a=P(r),o=F(a),s=e=>{},c=e=>{var t=EI(),r=N(t),i=F(N(r));E(r),E(t),ai(`click`,i,()=>n()()),B(e,t)};U(o,e=>{i()?e(s):e(c,-1)}),I(e=>V(a,`${e??``} `),[()=>console.error(`Panic, uncaught error:
|
|
597
|
+
`,t())??``]),B(e,r)},r=K(t,`body`,7),i=K(t,`silent`,7),a=j(void 0),o=e=>{M(a,{error:e},!0)};var s={get body(){return r()},set body(e){r(e),k()},get silent(){return i()},set silent(e){i(e),k()}},c=z();return nn(P(c),{get failed(){return n}},e=>{var t=z(),i=P(t),s=e=>{n(e,()=>L(a).error,()=>()=>{M(a,void 0)})},c=e=>{var t=z();H(P(t),r,()=>o),B(e,t)};U(i,e=>{L(a)?e(s):e(c,-1)}),B(e,t)}),B(e,c),O(s)}oi([`click`]),q(kI,{body:{},silent:{}},[],[],{mode:`open`});function AI(e,t){D(t,!0);let n=K(t,`forceTheme`,7),r=K(t,`apiUrl`,7),i=K(t,`apiKey`,7),a=K(t,`speechRecognitionApiKey`,7),o=K(t,`lang`,7),s=K(t,`features`,7),c=K(t,`loaderBackground`,7),l=K(t,`loaderColor`,7),u=K(t,`flyout`,7),d=K(t,`flyoutStyle`,7),f=K(t,`flyoutClass`,7),p=K(t,`chatClass`,7),m=K(t,`inlineLayout`,7),h=K(t,`forceChatPage`,7),g=K(t,`hidePredefinedQuestions`,7),_=K(t,`autofirePredefinedQuestionId`,7),v=K(t,`additionalStartParameters`,7),y=K(t,`question`,7),b=K(t,`mode`,7),x=K(t,`source`,7),S=K(t,`cache`,7),C=A(()=>({forceTheme:n(),apiUrl:r(),apiKey:i(),speechRecognitionApiKey:a(),lang:o(),features:s(),loaderBackground:c(),loaderColor:l(),flyout:u(),flyoutStyle:d(),flyoutClass:f(),chatClass:p(),inlineLayout:m(),forceChatPage:h(),hidePredefinedQuestions:g(),autofirePredefinedQuestionId:_(),additionalStartParameters:v(),question:y(),mode:b(),source:x(),cache:S()}));var ee={get forceTheme(){return n()},set forceTheme(e){n(e),k()},get apiUrl(){return r()},set apiUrl(e){r(e),k()},get apiKey(){return i()},set apiKey(e){i(e),k()},get speechRecognitionApiKey(){return a()},set speechRecognitionApiKey(e){a(e),k()},get lang(){return o()},set lang(e){o(e),k()},get features(){return s()},set features(e){s(e),k()},get loaderBackground(){return c()},set loaderBackground(e){c(e),k()},get loaderColor(){return l()},set loaderColor(e){l(e),k()},get flyout(){return u()},set flyout(e){u(e),k()},get flyoutStyle(){return d()},set flyoutStyle(e){d(e),k()},get flyoutClass(){return f()},set flyoutClass(e){f(e),k()},get chatClass(){return p()},set chatClass(e){p(e),k()},get inlineLayout(){return m()},set inlineLayout(e){m(e),k()},get forceChatPage(){return h()},set forceChatPage(e){h(e),k()},get hidePredefinedQuestions(){return g()},set hidePredefinedQuestions(e){g(e),k()},get autofirePredefinedQuestionId(){return _()},set autofirePredefinedQuestionId(e){_(e),k()},get additionalStartParameters(){return v()},set additionalStartParameters(e){v(e),k()},get question(){return y()},set question(e){y(e),k()},get mode(){return b()},set mode(e){b(e),k()},get source(){return x()},set source(e){x(e),k()},get cache(){return S()},set cache(e){S(e),k()}};{let n=(e,n=w)=>{TI(e,mo({host:t.$$host,get onError(){return n()}},()=>L(C)))},r=A(()=>L(C).flyout??!1);kI(e,{get silent(){return L(r)},body:n,$$slots:{body:!0}})}return O(ee)}customElements.define(`liipgpt-chat`,q(AI,{forceTheme:{attribute:`force-theme`,type:`String`},apiUrl:{attribute:`api-url`,type:`String`},apiKey:{attribute:`api-key`,type:`String`},speechRecognitionApiKey:{attribute:`speech-recognition-api-key`,type:`String`},lang:{attribute:`lang`,type:`String`},features:{attribute:`features`,type:`String`},loaderBackground:{attribute:`loader-background`,type:`String`},loaderColor:{attribute:`loader-color`,type:`String`},flyout:{attribute:`flyout`,type:`Boolean`},flyoutStyle:{attribute:`flyout-style`,type:`String`},flyoutClass:{attribute:`flyout-class`,type:`String`},chatClass:{attribute:`chat-class`,type:`String`},inlineLayout:{attribute:`inline-layout`,type:`Boolean`},forceChatPage:{attribute:`force-chat-page`,type:`Boolean`},hidePredefinedQuestions:{attribute:`hide-predefined-questions`,type:`Boolean`},autofirePredefinedQuestionId:{attribute:`autofire-predefined-question-id`,type:`String`},additionalStartParameters:{attribute:`additional-start-parameters`,type:`String`},question:{attribute:`question`,type:`String`},mode:{attribute:`mode`,type:`String`},source:{attribute:`source`,type:`String`},cache:{attribute:`cache`,type:`Boolean`}},[],[],{mode:`open`}));export{AI as LiipGPTChat};
|