var Bi=Object.defineProperty;var Ki=(e,t)=>{for(var i in t)Bi(e,i,{get:t[i],enumerable:!0})};(function(){"use strict";var e=(m,b)=>{let D=S=>{for(let T=0,{length:M}=S;T{S.attributeChangedCallback(T,M,S.getAttribute(T))};return(S,T)=>{let{observedAttributes:M}=S.constructor;return M&&m(T).then(()=>{new b(D).observe(S,{attributes:!0,attributeOldValue:!0,attributeFilter:M});for(let G=0,{length:w}=M;Gr in m,{filter:h}=[];var p=m=>{let b=new c,D=(w,P)=>{let k;if(P)for(let H,O=(z=>z.matches||z.webkitMatchesSelector||z.msMatchesSelector)(w),A=0,{length:J}=S;A{m.handle(w,P,H)}))},K=(w,P=!0)=>{for(let k=0,{length:H}=w;k{let O=(z,rt,st,at,lt,ht)=>{for(let tt of z)(ht||n in tt)&&(lt?st.has(tt)||(st.add(tt),at.delete(tt),w(tt,lt)):at.has(tt)||(at.add(tt),st.delete(tt),w(tt,lt)),ht||O(tt[n](rt),rt,st,at,lt,!0))},A=new k(z=>{if(H.length){let rt=H.join(","),st=new Set,at=new Set;for(let{addedNodes:lt,removedNodes:ht}of z)O(ht,rt,st,at,!1,!1),O(lt,rt,st,at,!0,!1)}}),{observe:J}=A;return(A.observe=z=>J.call(A,z,{subtree:!0,childList:!0}))(P),A})(D,T,l,S),{attachShadow:G}=s.prototype;return G&&(s.prototype.attachShadow=function(w){let P=G.call(this,w);return M.observe(P),P}),S.length&&K(T[r](S)),{drop:w=>{for(let P=0,{length:k}=w;P{let w=M.takeRecords();for(let P=0,{length:k}=w;P{let b=a(m),D=[],K=new Y,{length:S}=b;for(let T=0;T{for(let T=0;T{let z=K.get(J);if(A&&!z.isPrototypeOf(O)){let st=I(O);w=d(O,z);try{new z.constructor}finally{w=null,st()}}let rt=(A?"":"dis")+"connectedCallback";rt in z&&O[rt]()},{parse:G}=p({query:T,handle:M}),w=null,P=O=>{if(!D.has(O)){let A,J=new Promise(z=>{A=z});D.set(O,{$:J,_:A})}return D.get(O).$},k=e(P,C);self.customElements={define:(O,A)=>{if(S.has(O))throw new V(`the name "${O}" has already been used with this registry`);b.set(A,O),K.set(O,A.prototype),S.set(O,A),T.push(O),P(O).then(()=>{G(v.querySelectorAll(O))}),D.get(O)._(A)},get:O=>S.get(O),whenDefined:P},_(H.prototype=W.prototype,"constructor",{value:H}),self.HTMLElement=H,v.createElement=function(O,A){let J=A&&A.is,z=J?S.get(J):S.get(O);return z?new z:m.call(v,O)},"isConnected"in et.prototype||_(et.prototype,"isConnected",{configurable:!0,get(){return!(this.ownerDocument.compareDocumentPosition(this)&this.DOCUMENT_POSITION_DISCONNECTED)}})}else if(E=!self.customElements.get("extends-li"),E)try{let m=function(){return self.Reflect.construct(HTMLLIElement,[],m)};m.prototype=HTMLLIElement.prototype;let b="extends-li";self.customElements.define("extends-li",m,{extends:"li"}),E=v.createElement("li",{is:b}).outerHTML.indexOf(b)<0;let{get:D,whenDefined:K}=self.customElements;self.customElements.whenDefined=function(S){return K.call(this,S).then(T=>T||D.call(this,S))}}catch{}if(E){let We=function(y){let L=M.get(y);rt(L.querySelectorAll(this),y.isConnected)},m=self.customElements,{createElement:b}=v,{define:D,get:K,upgrade:S}=m,{construct:T}=x||{construct(y){return y.call(this)}},M=new $,G=new Y,w=new N,P=new N,k=new N,H=new N,O=[],A=[],J=y=>H.get(y)||K.call(m,y),z=(y,L,U)=>{let R=k.get(U);if(L&&!R.isPrototypeOf(y)){let ge=I(y);tt=d(y,R);try{new R.constructor}finally{tt=null,ge()}}let Z=(L?"":"dis")+"connectedCallback";Z in R&&y[Z]()},{parse:rt}=p({query:A,handle:z}),{parse:st}=p({query:O,handle(y,L){M.has(y)&&(L?G.add(y):G.delete(y),A.length&&We.call(A,y))}}),{attachShadow:at}=B.prototype;at&&(B.prototype.attachShadow=function(y){let L=at.call(this,y);return M.set(this,L),L});let lt=y=>{if(!P.has(y)){let L,U=new Promise(R=>{L=R});P.set(y,{$:U,_:L})}return P.get(y).$},ht=e(lt,C),tt=null;f(self).filter(y=>/^HTML.*Element$/.test(y)).forEach(y=>{let L=self[y];function U(){let{constructor:R}=this;if(!w.has(R))throw new it("Illegal constructor");let{is:Z,tag:ge}=w.get(R);if(Z){if(tt)return ht(tt,Z);let Ve=b.call(v,ge);return Ve.setAttribute("is",Z),ht(d(Ve,R.prototype),Z)}return T.call(this,L,[],R)}d(U,L),_(U.prototype=L.prototype,"constructor",{value:U}),_(self,y,{value:U})}),v.createElement=function(y,L){let U=L&&L.is;if(U){let Z=H.get(U);if(Z&&w.get(Z).tag===y)return new Z}let R=b.call(v,y);return U&&R.setAttribute("is",U),R},m.get=J,m.whenDefined=lt,m.upgrade=function(y){let L=y.getAttribute("is");if(L){let U=H.get(L);if(U)return void ht(d(y,U.prototype),L)}S.call(m,y)},m.define=function(y,L,U){if(J(y))throw new V(`'${y}' has already been defined as a custom element`);let R,Z=U&&U.extends;w.set(L,Z?{is:y,tag:Z}:{is:"",tag:y}),Z?(R=`${Z}[is="${y}"]`,k.set(R,L.prototype),H.set(y,L),A.push(R)):(D.apply(m,arguments),O.push(R=y)),lt(y).then(()=>{Z?(rt(v.querySelectorAll(R)),G.forEach(We,[R])):st(v.querySelectorAll(R))}),P.get(y)._(L)}}})();var Ut=null,Be,Ke,Ue,qe=65,ve,At,He=new Set,$e=1111;Ui();function Ui(){if(!document.createElement("link").relList.supports("prefetch"))return;let t="instantVaryAccept"in document.body.dataset||"Shopify"in window,i=navigator.userAgent.indexOf("Chrome/");if(i>-1&&(Ut=parseInt(navigator.userAgent.substring(i+7))),t&&Ut&&Ut<110)return;let n="instantMousedownShortcut"in document.body.dataset;Be="instantAllowQueryString"in document.body.dataset,Ke="instantAllowExternalLinks"in document.body.dataset,Ue="instantWhitelist"in document.body.dataset;let r={capture:!0,passive:!0},o=!1,s=!1,l=!1;if("instantIntensity"in document.body.dataset){let u=document.body.dataset.instantIntensity;if(u.startsWith("mousedown"))o=!0,u=="mousedown-only"&&(s=!0);else if(u.startsWith("viewport")){let c=navigator.connection&&navigator.connection.saveData,g=navigator.connection&&navigator.connection.effectiveType&&navigator.connection.effectiveType.includes("2g");!c&&!g&&(u=="viewport"?document.documentElement.clientWidth*document.documentElement.clientHeight<45e4&&(l=!0):u=="viewport-all"&&(l=!0))}else{let c=parseInt(u);isNaN(c)||(qe=c)}}if(s||document.addEventListener("touchstart",qi,r),o?n||document.addEventListener("mousedown",Gi,r):document.addEventListener("mouseover",$i,r),n&&document.addEventListener("mousedown",Xi,r),l){let u=window.requestIdleCallback;u||(u=c=>{c()}),u(function(){let g=new IntersectionObserver(h=>{h.forEach(p=>{if(p.isIntersecting){let v=p.target;g.unobserve(v),$t(v.href)}})});document.querySelectorAll("a").forEach(h=>{qt(h)&&g.observe(h)})},{timeout:1500})}}function qi(e){ve=performance.now();let t=e.target.closest("a");qt(t)&&$t(t.href,"high")}function $i(e){if(performance.now()-ve<$e||!("closest"in e.target))return;let t=e.target.closest("a");qt(t)&&(t.addEventListener("mouseout",Zi,{passive:!0}),At=setTimeout(()=>{$t(t.href,"high"),At=void 0},qe))}function Gi(e){let t=e.target.closest("a");qt(t)&&$t(t.href,"high")}function Zi(e){e.relatedTarget&&e.target.closest("a")==e.relatedTarget.closest("a")||At&&(clearTimeout(At),At=void 0)}function Xi(e){if(performance.now()-ve<$e)return;let t=e.target.closest("a");if(e.which>1||e.metaKey||e.ctrlKey||!t)return;t.addEventListener("click",function(n){n.detail!=1337&&n.preventDefault()},{capture:!0,passive:!1,once:!0});let i=new MouseEvent("click",{view:window,bubbles:!0,cancelable:!1,detail:1337});t.dispatchEvent(i)}function qt(e){if(!(!e||!e.href)&&!(Ue&&!("instant"in e.dataset))&&!(e.origin!=location.origin&&(!(Ke||"instant"in e.dataset)||!Ut))&&["http:","https:"].includes(e.protocol)&&!(e.protocol=="http:"&&location.protocol=="https:")&&!(!Be&&e.search&&!("instant"in e.dataset))&&!(e.hash&&e.pathname+e.search==location.pathname+location.search)&&!("noInstant"in e.dataset))return!0}function $t(e,t="auto"){if(He.has(e))return;let i=document.createElement("link");i.rel="prefetch",i.href=e,i.fetchPriority=t,i.as="document",document.head.appendChild(i),He.add(e)}var be={};Ki(be,{createFocusTrap:()=>wn});var Ze=["input:not([inert])","select:not([inert])","textarea:not([inert])","a[href]:not([inert])","button:not([inert])","[tabindex]:not(slot):not([inert])","audio[controls]:not([inert])","video[controls]:not([inert])",'[contenteditable]:not([contenteditable="false"]):not([inert])',"details>summary:first-of-type:not([inert])","details:not([inert])"],Gt=Ze.join(","),Xe=typeof Element>"u",wt=Xe?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,Zt=!Xe&&Element.prototype.getRootNode?function(e){var t;return e==null||(t=e.getRootNode)===null||t===void 0?void 0:t.call(e)}:function(e){return e?.ownerDocument},Xt=function e(t,i){var n;i===void 0&&(i=!0);var r=t==null||(n=t.getAttribute)===null||n===void 0?void 0:n.call(t,"inert"),o=r===""||r==="true",s=o||i&&t&&e(t.parentNode);return s},Yi=function(t){var i,n=t==null||(i=t.getAttribute)===null||i===void 0?void 0:i.call(t,"contenteditable");return n===""||n==="true"},Ye=function(t,i,n){if(Xt(t))return[];var r=Array.prototype.slice.apply(t.querySelectorAll(Gt));return i&&wt.call(t,Gt)&&r.unshift(t),r=r.filter(n),r},Qe=function e(t,i,n){for(var r=[],o=Array.from(t);o.length;){var s=o.shift();if(!Xt(s,!1))if(s.tagName==="SLOT"){var l=s.assignedElements(),u=l.length?l:s.children,c=e(u,!0,n);n.flatten?r.push.apply(r,c):r.push({scopeParent:s,candidates:c})}else{var g=wt.call(s,Gt);g&&n.filter(s)&&(i||!t.includes(s))&&r.push(s);var h=s.shadowRoot||typeof n.getShadowRoot=="function"&&n.getShadowRoot(s),p=!Xt(h,!1)&&(!n.shadowRootFilter||n.shadowRootFilter(s));if(h&&p){var v=e(h===!0?s.children:h.children,!0,n);n.flatten?r.push.apply(r,v):r.push({scopeParent:s,candidates:v})}else o.unshift.apply(o,s.children)}}return r},Je=function(t,i){return t.tabIndex<0&&(i||/^(AUDIO|VIDEO|DETAILS)$/.test(t.tagName)||Yi(t))&&isNaN(parseInt(t.getAttribute("tabindex"),10))?0:t.tabIndex},Qi=function(t,i){return t.tabIndex===i.tabIndex?t.documentOrder-i.documentOrder:t.tabIndex-i.tabIndex},ti=function(t){return t.tagName==="INPUT"},Ji=function(t){return ti(t)&&t.type==="hidden"},tn=function(t){var i=t.tagName==="DETAILS"&&Array.prototype.slice.apply(t.children).some(function(n){return n.tagName==="SUMMARY"});return i},en=function(t,i){for(var n=0;nsummary:first-of-type"),s=o?t.parentElement:t;if(wt.call(s,"details:not([open]) *"))return!0;if(!n||n==="full"||n==="legacy-full"){if(typeof r=="function"){for(var l=t;t;){var u=t.parentElement,c=Zt(t);if(u&&!u.shadowRoot&&r(u)===!0)return Ge(t);t.assignedSlot?t=t.assignedSlot:!u&&c!==t.ownerDocument?t=c.host:t=u}t=l}if(on(t))return!t.getClientRects().length;if(n!=="legacy-full")return!0}else if(n==="non-zero-area")return Ge(t);return!1},ln=function(t){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(t.tagName))for(var i=t.parentElement;i;){if(i.tagName==="FIELDSET"&&i.disabled){for(var n=0;n=0)},un=function e(t){var i=[],n=[];return t.forEach(function(r,o){var s=!!r.scopeParent,l=s?r.scopeParent:r,u=Je(l,s),c=s?e(r.candidates):l;u===0?s?i.push.apply(i,c):i.push(l):n.push({documentOrder:o,tabIndex:u,item:r,isScope:s,content:c})}),n.sort(Qi).reduce(function(r,o){return o.isScope?r.push.apply(r,o.content):r.push(o.content),r},[]).concat(i)},ei=function(t,i){i=i||{};var n;return i.getShadowRoot?n=Qe([t],i.includeContainer,{filter:ye.bind(null,i),flatten:!1,getShadowRoot:i.getShadowRoot,shadowRootFilter:cn}):n=Ye(t,i.includeContainer,ye.bind(null,i)),un(n)},ii=function(t,i){i=i||{};var n;return i.getShadowRoot?n=Qe([t],i.includeContainer,{filter:Yt.bind(null,i),flatten:!0,getShadowRoot:i.getShadowRoot}):n=Ye(t,i.includeContainer,Yt.bind(null,i)),n},It=function(t,i){if(i=i||{},!t)throw new Error("No node provided");return wt.call(t,Gt)===!1?!1:ye(i,t)},fn=Ze.concat("iframe").join(","),Qt=function(t,i){if(i=i||{},!t)throw new Error("No node provided");return wt.call(t,fn)===!1?!1:Yt(i,t)};function ni(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable})),i.push.apply(i,n)}return i}function ri(e){for(var t=1;t0){var n=t[t.length-1];n!==i&&n.pause()}var r=t.indexOf(i);r===-1||t.splice(r,1),t.push(i)},deactivateTrap:function(t,i){var n=t.indexOf(i);n!==-1&&t.splice(n,1),t.length>0&&t[t.length-1].unpause()}},mn=function(t){return t.tagName&&t.tagName.toLowerCase()==="input"&&typeof t.select=="function"},gn=function(t){return t.key==="Escape"||t.key==="Esc"||t.keyCode===27},Pt=function(t){return t.key==="Tab"||t.keyCode===9},vn=function(t){return Pt(t)&&!t.shiftKey},yn=function(t){return Pt(t)&&t.shiftKey},oi=function(t){return setTimeout(t,0)},ai=function(t,i){var n=-1;return t.every(function(r,o){return i(r)?(n=o,!1):!0}),n},Dt=function(t){for(var i=arguments.length,n=new Array(i>1?i-1:0),r=1;r1?d-1:0),I=1;I=0)a=n.activeElement;else{var f=s.tabbableGroups[0],d=f&&f.firstTabbableNode;a=d||g("fallbackFocus")}if(!a)throw new Error("Your focus-trap needs to have at least one focusable element");return a},p=function(){if(s.containerGroups=s.containers.map(function(a){var f=ei(a,o.tabbableOptions),d=ii(a,o.tabbableOptions);return{container:a,tabbableNodes:f,focusableNodes:d,firstTabbableNode:f.length>0?f[0]:null,lastTabbableNode:f.length>0?f[f.length-1]:null,nextTabbableNode:function(I){var m=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,b=d.findIndex(function(D){return D===I});if(!(b<0))return m?d.slice(b+1).find(function(D){return It(D,o.tabbableOptions)}):d.slice(0,b).reverse().find(function(D){return It(D,o.tabbableOptions)})}}}),s.tabbableGroups=s.containerGroups.filter(function(a){return a.tabbableNodes.length>0}),s.tabbableGroups.length<=0&&!g("fallbackFocus"))throw new Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times")},v=function _(a){if(a!==!1&&a!==n.activeElement){if(!a||!a.focus){_(h());return}a.focus({preventScroll:!!o.preventScroll}),s.mostRecentlyFocusedNode=a,mn(a)&&a.select()}},N=function(a){var f=g("setReturnFocus",a);return f||(f===!1?!1:a)},C=function(a){var f=Jt(a);if(!(c(f,a)>=0)){if(Dt(o.clickOutsideDeactivates,a)){l.deactivate({returnFocus:o.returnFocusOnDeactivate});return}Dt(o.allowOutsideClick,a)||a.preventDefault()}},F=function(a){var f=Jt(a),d=c(f,a)>=0;d||f instanceof Document?d&&(s.mostRecentlyFocusedNode=f):(a.stopImmediatePropagation(),v(s.mostRecentlyFocusedNode||h()))},Y=function(a){var f=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,d=Jt(a);p();var E=null;if(s.tabbableGroups.length>0){var I=c(d,a),m=I>=0?s.containerGroups[I]:void 0;if(I<0)f?E=s.tabbableGroups[s.tabbableGroups.length-1].lastTabbableNode:E=s.tabbableGroups[0].firstTabbableNode;else if(f){var b=ai(s.tabbableGroups,function(G){var w=G.firstTabbableNode;return d===w});if(b<0&&(m.container===d||Qt(d,o.tabbableOptions)&&!It(d,o.tabbableOptions)&&!m.nextTabbableNode(d,!1))&&(b=I),b>=0){var D=b===0?s.tabbableGroups.length-1:b-1,K=s.tabbableGroups[D];E=K.lastTabbableNode}else Pt(a)||(E=m.nextTabbableNode(d,!1))}else{var S=ai(s.tabbableGroups,function(G){var w=G.lastTabbableNode;return d===w});if(S<0&&(m.container===d||Qt(d,o.tabbableOptions)&&!It(d,o.tabbableOptions)&&!m.nextTabbableNode(d))&&(S=I),S>=0){var T=S===s.tabbableGroups.length-1?0:S+1,M=s.tabbableGroups[T];E=M.firstTabbableNode}else Pt(a)||(E=m.nextTabbableNode(d))}}else E=g("fallbackFocus");E&&(Pt(a)&&a.preventDefault(),v(E))},$=function(a){if(gn(a)&&Dt(o.escapeDeactivates,a)!==!1){a.preventDefault(),l.deactivate();return}(o.isKeyForward(a)||o.isKeyBackward(a))&&Y(a,o.isKeyBackward(a))},B=function(a){var f=Jt(a);c(f,a)>=0||Dt(o.clickOutsideDeactivates,a)||Dt(o.allowOutsideClick,a)||(a.preventDefault(),a.stopImmediatePropagation())},W=function(){if(s.active)return si.activateTrap(r,l),s.delayInitialFocusTimer=o.delayInitialFocus?oi(function(){v(h())}):v(h()),n.addEventListener("focusin",F,!0),n.addEventListener("mousedown",C,{capture:!0,passive:!1}),n.addEventListener("touchstart",C,{capture:!0,passive:!1}),n.addEventListener("click",B,{capture:!0,passive:!1}),n.addEventListener("keydown",$,{capture:!0,passive:!1}),l},et=function(){if(s.active)return n.removeEventListener("focusin",F,!0),n.removeEventListener("mousedown",C,!0),n.removeEventListener("touchstart",C,!0),n.removeEventListener("click",B,!0),n.removeEventListener("keydown",$,!0),l},V=function(a){var f=a.some(function(d){var E=Array.from(d.removedNodes);return E.some(function(I){return I===s.mostRecentlyFocusedNode})});f&&v(h())},it=typeof window<"u"&&"MutationObserver"in window?new MutationObserver(V):void 0,x=function(){it&&(it.disconnect(),s.active&&!s.paused&&s.containers.map(function(a){it.observe(a,{subtree:!0,childList:!0})}))};return l={get active(){return s.active},get paused(){return s.paused},activate:function(a){if(s.active)return this;var f=u(a,"onActivate"),d=u(a,"onPostActivate"),E=u(a,"checkCanFocusTrap");E||p(),s.active=!0,s.paused=!1,s.nodeFocusedBeforeActivation=n.activeElement,f?.();var I=function(){E&&p(),W(),x(),d?.()};return E?(E(s.containers.concat()).then(I,I),this):(I(),this)},deactivate:function(a){if(!s.active)return this;var f=ri({onDeactivate:o.onDeactivate,onPostDeactivate:o.onPostDeactivate,checkCanReturnFocus:o.checkCanReturnFocus},a);clearTimeout(s.delayInitialFocusTimer),s.delayInitialFocusTimer=void 0,et(),s.active=!1,s.paused=!1,x(),si.deactivateTrap(r,l);var d=u(f,"onDeactivate"),E=u(f,"onPostDeactivate"),I=u(f,"checkCanReturnFocus"),m=u(f,"returnFocus","returnFocusOnDeactivate");d?.();var b=function(){oi(function(){m&&v(N(s.nodeFocusedBeforeActivation)),E?.()})};return m&&I?(I(N(s.nodeFocusedBeforeActivation)).then(b,b),this):(b(),this)},pause:function(a){if(s.paused||!s.active)return this;var f=u(a,"onPause"),d=u(a,"onPostPause");return s.paused=!0,f?.(),et(),x(),d?.(),this},unpause:function(a){if(!s.paused||!s.active)return this;var f=u(a,"onUnpause"),d=u(a,"onPostUnpause");return s.paused=!1,f?.(),p(),W(),x(),d?.(),this},updateContainerElements:function(a){var f=[].concat(a).filter(Boolean);return s.containers=f.map(function(d){return typeof d=="string"?n.querySelector(d):d}),s.active&&p(),x(),this}},l.updateContainerElements(t),l};function we(e,t){e.indexOf(t)===-1&&e.push(t)}function Ee(e,t){let i=e.indexOf(t);i>-1&&e.splice(i,1)}var Lt=(e,t,i)=>Math.min(Math.max(i,e),t);var j={duration:.3,delay:0,endDelay:0,repeat:0,easing:"ease"};var Q=e=>typeof e=="number";var ct=e=>Array.isArray(e)&&!Q(e[0]);var li=(e,t,i)=>{let n=t-e;return((i-e)%n+n)%n+e};function Ft(e,t){return ct(e)?e[li(0,e.length,t)]:e}var Et=(e,t,i)=>-i*e+i*t+e;var Nt=()=>{},X=e=>e;var ot=(e,t,i)=>t-e===0?1:(i-e)/(t-e);function Tt(e,t){let i=e[e.length-1];for(let n=1;n<=t;n++){let r=ot(0,t,n);e.push(Et(i,1,r))}}function xt(e){let t=[0];return Tt(t,e-1),t}function Ct(e,t=xt(e.length),i=X){let n=e.length,r=n-t.length;return r>0&&Tt(t,r),o=>{let s=0;for(;sArray.isArray(e)&&Q(e[0]);var pt=e=>typeof e=="object"&&!!e.createAnimation;var q=e=>typeof e=="function";var ut=e=>typeof e=="string";var mt={ms:e=>e*1e3,s:e=>e/1e3};function xe(e,t){return t?e*(1e3/t):0}var ci=(e,t,i)=>(((1-3*i+3*t)*e+(3*i-6*t))*e+3*t)*e,En=1e-7,xn=12;function Sn(e,t,i,n,r){let o,s,l=0;do s=t+(i-t)/2,o=ci(s,n,r)-e,o>0?i=s:t=s;while(Math.abs(o)>En&&++lSn(o,0,1,e,i);return o=>o===0||o===1?o:ci(r(o),t,n)}var Se=(e,t="end")=>i=>{i=t==="end"?Math.min(i,.999):Math.max(i,.001);let n=i*e,r=t==="end"?Math.floor(n):Math.ceil(n);return Lt(0,1,r/e)};var ui={ease:St(.25,.1,.25,1),"ease-in":St(.42,0,1,1),"ease-in-out":St(.42,0,.58,1),"ease-out":St(0,0,.58,1)},On=/\((.*?)\)/;function _t(e){if(q(e))return e;if(Mt(e))return St(...e);if(ui[e])return ui[e];if(e.startsWith("steps")){let t=On.exec(e);if(t){let i=t[1].split(",");return Se(parseFloat(i[0]),i[1].trim())}}return X}var ft=class{constructor(t,i=[0,1],{easing:n,duration:r=j.duration,delay:o=j.delay,endDelay:s=j.endDelay,repeat:l=j.repeat,offset:u,direction:c="normal"}={}){if(this.startTime=null,this.rate=1,this.t=0,this.cancelTimestamp=null,this.easing=X,this.duration=0,this.totalDuration=0,this.repeat=0,this.playState="idle",this.finished=new Promise((h,p)=>{this.resolve=h,this.reject=p}),n=n||j.easing,pt(n)){let h=n.createAnimation(i);n=h.easing,i=h.keyframes||i,r=h.duration||r}this.repeat=l,this.easing=ct(n)?X:_t(n),this.updateDuration(r);let g=Ct(i,u,ct(n)?n.map(_t):X);this.tick=h=>{var p;o=o;let v=0;this.pauseTime!==void 0?v=this.pauseTime:v=(h-this.startTime)*this.rate,this.t=v,v/=1e3,v=Math.max(v-o,0),this.playState==="finished"&&this.pauseTime===void 0&&(v=this.totalDuration);let N=v/this.duration,C=Math.floor(N),F=N%1;!F&&N>=1&&(F=1),F===1&&C--;let Y=C%2;(c==="reverse"||c==="alternate"&&Y||c==="alternate-reverse"&&!Y)&&(F=1-F);let $=v>=this.totalDuration?1:Math.min(F,1),B=g(this.easing($));t(B),this.pauseTime===void 0&&(this.playState==="finished"||v>=this.totalDuration+s)?(this.playState="finished",(p=this.resolve)===null||p===void 0||p.call(this,B)):this.playState!=="idle"&&(this.frameRequestId=requestAnimationFrame(this.tick))},this.play()}play(){let t=performance.now();this.playState="running",this.pauseTime!==void 0?this.startTime=t-this.pauseTime:this.startTime||(this.startTime=t),this.cancelTimestamp=this.startTime,this.pauseTime=void 0,this.frameRequestId=requestAnimationFrame(this.tick)}pause(){this.playState="paused",this.pauseTime=this.t}finish(){this.playState="finished",this.tick(0)}stop(){var t;this.playState="idle",this.frameRequestId!==void 0&&cancelAnimationFrame(this.frameRequestId),(t=this.reject)===null||t===void 0||t.call(this,!1)}cancel(){this.stop(),this.tick(this.cancelTimestamp)}reverse(){this.rate*=-1}commitStyles(){}updateDuration(t){this.duration=t,this.totalDuration=t*(this.repeat+1)}get currentTime(){return this.t}set currentTime(t){this.pauseTime!==void 0||this.rate===0?this.pauseTime=t:this.startTime=performance.now()-t/this.rate}get playbackRate(){return this.rate}set playbackRate(t){this.rate=t}};var Rt=function(){};var kt=class{setAnimation(t){this.animation=t,t?.finished.then(()=>this.clearAnimation()).catch(()=>{})}clearAnimation(){this.animation=this.generator=void 0}};var Oe=new WeakMap;function te(e){return Oe.has(e)||Oe.set(e,{transforms:[],values:new Map}),Oe.get(e)}function fi(e,t){return e.has(t)||e.set(t,new kt),e.get(t)}var Tn=["","X","Y","Z"],_n=["translate","scale","rotate","skew"],zt={x:"translateX",y:"translateY",z:"translateZ"},di={syntax:"",initialValue:"0deg",toDefaultUnit:e=>e+"deg"},An={translate:{syntax:"",initialValue:"0px",toDefaultUnit:e=>e+"px"},rotate:di,scale:{syntax:"",initialValue:1,toDefaultUnit:X},skew:di},gt=new Map,ie=e=>`--motion-${e}`,ee=["x","y","z"];_n.forEach(e=>{Tn.forEach(t=>{ee.push(e+t),gt.set(ie(e+t),An[e])})});var In=(e,t)=>ee.indexOf(e)-ee.indexOf(t),Dn=new Set(ee),ne=e=>Dn.has(e),hi=(e,t)=>{zt[t]&&(t=zt[t]);let{transforms:i}=te(e);we(i,t),e.style.transform=Pn(i)},Pn=e=>e.sort(In).reduce(Ln,"").trim(),Ln=(e,t)=>`${e} ${t}(var(${ie(t)}))`;var jt=e=>e.startsWith("--"),pi=new Set;function mi(e){if(!pi.has(e)){pi.add(e);try{let{syntax:t,initialValue:i}=gt.has(e)?gt.get(e):{};CSS.registerProperty({name:e,inherits:!1,syntax:t,initialValue:i})}catch{}}}var Te=(e,t)=>document.createElement("div").animate(e,t),gi={cssRegisterProperty:()=>typeof CSS<"u"&&Object.hasOwnProperty.call(CSS,"registerProperty"),waapi:()=>Object.hasOwnProperty.call(Element.prototype,"animate"),partialKeyframes:()=>{try{Te({opacity:[1]})}catch{return!1}return!0},finished:()=>!!Te({opacity:[0,1]},{duration:.001}).finished,linearEasing:()=>{try{Te({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0}},_e={},vt={};for(let e in gi)vt[e]=()=>(_e[e]===void 0&&(_e[e]=gi[e]()),_e[e]);var Fn=.015,Nn=(e,t)=>{let i="",n=Math.round(t/Fn);for(let r=0;rq(e)?vt.linearEasing()?`linear(${Nn(e,t)})`:j.easing:Mt(e)?Cn(e):e,Cn=([e,t,i,n])=>`cubic-bezier(${e}, ${t}, ${i}, ${n})`;function vi(e,t){for(let i=0;iArray.isArray(e)?e:[e];function Wt(e){return zt[e]&&(e=zt[e]),ne(e)?ie(e):e}var Vt={get:(e,t)=>{t=Wt(t);let i=jt(t)?e.style.getPropertyValue(t):getComputedStyle(e)[t];if(!i&&i!==0){let n=gt.get(t);n&&(i=n.initialValue)}return i},set:(e,t,i)=>{t=Wt(t),jt(t)?e.style.setProperty(t,i):e.style[t]=i}};function se(e,t=!0){if(!(!e||e.playState==="finished"))try{e.stop?e.stop():(t&&e.commitStyles(),e.cancel())}catch{}}function yi(e,t){var i;let n=t?.toDefaultUnit||X,r=e[e.length-1];if(ut(r)){let o=((i=r.match(/(-?[\d.]+)([a-z%]*)/))===null||i===void 0?void 0:i[2])||"";o&&(n=s=>s+o)}return n}function Mn(){return window.__MOTION_DEV_TOOLS_RECORD}function oe(e,t,i,n={},r){let o=Mn(),s=n.record!==!1&&o,l,{duration:u=j.duration,delay:c=j.delay,endDelay:g=j.endDelay,repeat:h=j.repeat,easing:p=j.easing,persist:v=!1,direction:N,offset:C,allowWebkitAcceleration:F=!1}=n,Y=te(e),$=ne(t),B=vt.waapi();$&&hi(e,t);let W=Wt(t),et=fi(Y.values,W),V=gt.get(W);return se(et.animation,!(pt(p)&&et.generator)&&n.record!==!1),()=>{let it=()=>{var a,f;return(f=(a=Vt.get(e,W))!==null&&a!==void 0?a:V?.initialValue)!==null&&f!==void 0?f:0},x=vi(re(i),it),_=yi(x,V);if(pt(p)){let a=p.createAnimation(x,t!=="opacity",it,W,et);p=a.easing,x=a.keyframes||x,u=a.duration||u}if(jt(W)&&(vt.cssRegisterProperty()?mi(W):B=!1),$&&!vt.linearEasing()&&(q(p)||ct(p)&&p.some(q))&&(B=!1),B){V&&(x=x.map(d=>Q(d)?V.toDefaultUnit(d):d)),x.length===1&&(!vt.partialKeyframes()||s)&&x.unshift(it());let a={delay:mt.ms(c),duration:mt.ms(u),endDelay:mt.ms(g),easing:ct(p)?void 0:Ae(p,u),direction:N,iterations:h+1,fill:"both"};l=e.animate({[W]:x,offset:C,easing:ct(p)?p.map(d=>Ae(d,u)):void 0},a),l.finished||(l.finished=new Promise((d,E)=>{l.onfinish=d,l.oncancel=E}));let f=x[x.length-1];l.finished.then(()=>{v||(Vt.set(e,W,f),l.cancel())}).catch(Nt),F||(l.playbackRate=1.000001)}else if(r&&$)x=x.map(a=>typeof a=="string"?parseFloat(a):a),x.length===1&&x.unshift(parseFloat(it())),l=new r(a=>{Vt.set(e,W,_?_(a):a)},x,Object.assign(Object.assign({},n),{duration:u,easing:p}));else{let a=x[x.length-1];Vt.set(e,W,V&&Q(a)?V.toDefaultUnit(a):a)}return s&&o(e,t,x,{duration:u,delay:c,easing:p,repeat:h,offset:C},"motion-one"),et.setAnimation(l),l}}var ae=(e,t)=>e[t]?Object.assign(Object.assign({},e),e[t]):Object.assign({},e);function yt(e,t){var i;return typeof e=="string"?t?((i=t[e])!==null&&i!==void 0||(t[e]=document.querySelectorAll(e)),e=t[e]):e=document.querySelectorAll(e):e instanceof Element&&(e=[e]),Array.from(e||[])}var Rn=e=>e(),Ot=(e,t,i=j.duration)=>new Proxy({animations:e.map(Rn).filter(Boolean),duration:i,options:t},zn),kn=e=>e.animations[0],zn={get:(e,t)=>{let i=kn(e);switch(t){case"duration":return e.duration;case"currentTime":return mt.s(i?.[t]||0);case"playbackRate":case"playState":return i?.[t];case"finished":return e.finished||(e.finished=Promise.all(e.animations.map(jn)).catch(Nt)),e.finished;case"stop":return()=>{e.animations.forEach(n=>se(n))};case"forEachNative":return n=>{e.animations.forEach(r=>n(r,e))};default:return typeof i?.[t]>"u"?void 0:()=>e.animations.forEach(n=>n[t]())}},set:(e,t,i)=>{switch(t){case"currentTime":i=mt.ms(i);case"currentTime":case"playbackRate":for(let n=0;ne.finished;function bi(e=.1,{start:t=0,from:i=0,easing:n}={}){return(r,o)=>{let s=Q(i)?i:Wn(i,o),l=Math.abs(s-r),u=e*l;if(n){let c=o*e;u=_t(n)(u/c)*c}return t+u}}function Wn(e,t){if(e==="first")return 0;{let i=t-1;return e==="last"?i:i/2}}function le(e,t,i){return q(e)?e(t,i):e}function wi(e){return function(i,n,r={}){i=yt(i);let o=i.length;Rt(!!o,"No valid element provided."),Rt(!!n,"No keyframes defined.");let s=[];for(let l=0;lt&&r.atoe(...o,ft)).filter(Boolean);return Ot(r,t,(i=n[0])===null||i===void 0?void 0:i[3].duration)}function Hn(e,t={}){var{defaultOptions:i={}}=t,n=ce(t,["defaultOptions"]);let r=[],o=new Map,s={},l=new Map,u=0,c=0,g=0;for(let h=0;h1,"spring must be provided 2 keyframes within timeline()");let D=f.createAnimation(x,V!=="opacity",()=>0,V);f=D.easing,x=D.keyframes||x,a=D.duration||a}let d=le(C.delay,B,$)||0,E=c+d,I=E+a,{offset:m=xt(x.length)}=_;m.length===1&&m[0]===0&&(m[1]=1);let b=m.length-x.length;b>0&&Tt(m,b),x.length===1&&x.unshift(null),Ei(it,x,f,m,E,I),F=Math.max(d+a,F),g=Math.max(I,g)}}u=c,c+=F}return o.forEach((h,p)=>{for(let v in h){let N=h[v];N.sort(xi);let C=[],F=[],Y=[];for(let $=0;$"u")return()=>{};let o=yt(e),s=new WeakMap,l=c=>{c.forEach(g=>{let h=s.get(g.target);if(g.isIntersecting!==!!h)if(g.isIntersecting){let p=t(g);q(p)?s.set(g.target,p):u.unobserve(g.target)}else h&&(h(g),s.delete(g.target))})},u=new IntersectionObserver(l,{root:i,rootMargin:n,threshold:typeof r=="number"?r:Un[r]});return o.forEach(c=>u.observe(c)),()=>u.disconnect()}var ue=new WeakMap,bt;function qn(e,t){if(t){let{inlineSize:i,blockSize:n}=t[0];return{width:i,height:n}}else return e instanceof SVGElement&&"getBBox"in e?e.getBBox():{width:e.offsetWidth,height:e.offsetHeight}}function $n({target:e,contentRect:t,borderBoxSize:i}){var n;(n=ue.get(e))===null||n===void 0||n.forEach(r=>{r({target:e,contentSize:t,get size(){return qn(e,i)}})})}function Gn(e){e.forEach($n)}function Zn(){typeof ResizeObserver>"u"||(bt=new ResizeObserver(Gn))}function Ti(e,t){bt||Zn();let i=yt(e);return i.forEach(n=>{let r=ue.get(n);r||(r=new Set,ue.set(n,r)),r.add(t),bt?.observe(n)}),()=>{i.forEach(n=>{let r=ue.get(n);r?.delete(t),r?.size||bt?.unobserve(n)})}}var fe=new Set,Ht;function Xn(){Ht=()=>{let e={width:window.innerWidth,height:window.innerHeight},t={target:window,size:e,contentSize:e};fe.forEach(i=>i(t))},window.addEventListener("resize",Ht)}function _i(e){return fe.add(e),Ht||Xn(),()=>{fe.delete(e),!fe.size&&Ht&&(Ht=void 0)}}function Ai(e,t){return q(e)?_i(e):Ti(e,t)}var Yn=50,Ii=()=>({current:0,offset:[],progress:0,scrollLength:0,targetOffset:0,targetLength:0,containerLength:0,velocity:0}),Pi=()=>({time:0,x:Ii(),y:Ii()}),Qn={x:{length:"Width",position:"Left"},y:{length:"Height",position:"Top"}};function Di(e,t,i,n){let r=i[t],{length:o,position:s}=Qn[t],l=r.current,u=i.time;r.current=e["scroll"+s],r.scrollLength=e["scroll"+o]-e["client"+o],r.offset.length=0,r.offset[0]=0,r.offset[1]=r.scrollLength,r.progress=ot(0,r.scrollLength,r.current);let c=n-u;r.velocity=c>Yn?0:xe(r.current-l,c)}function Li(e,t,i){Di(e,"x",t,i),Di(e,"y",t,i),t.time=i}function Fi(e,t){let i={x:0,y:0},n=e;for(;n&&n!==t;)if(n instanceof HTMLElement)i.x+=n.offsetLeft,i.y+=n.offsetTop,n=n.offsetParent;else if(n instanceof SVGGraphicsElement&&"getBBox"in n){let{top:r,left:o}=n.getBBox();for(i.x+=o,i.y+=r;n&&n.tagName!=="svg";)n=n.parentNode}return i}var de={Enter:[[0,1],[1,1]],Exit:[[0,0],[1,0]],Any:[[1,0],[0,1]],All:[[0,0],[1,1]]};var he={start:0,center:.5,end:1};function Pe(e,t,i=0){let n=0;if(he[e]!==void 0&&(e=he[e]),ut(e)){let r=parseFloat(e);e.endsWith("px")?n=r:e.endsWith("%")?e=r/100:e.endsWith("vw")?n=r/100*document.documentElement.clientWidth:e.endsWith("vh")?n=r/100*document.documentElement.clientHeight:e=r}return Q(e)&&(n=t*e),i+n}var Jn=[0,0];function Ni(e,t,i,n){let r=Array.isArray(e)?e:Jn,o=0,s=0;return Q(e)?r=[e,e]:ut(e)&&(e=e.trim(),e.includes(" ")?r=e.split(" "):r=[e,he[e]?e:"0"]),o=Pe(r[0],i,n),s=Pe(r[1],t),o-s}var tr={x:0,y:0};function Ci(e,t,i){let{offset:n=de.All}=i,{target:r=e,axis:o="y"}=i,s=o==="y"?"height":"width",l=r!==e?Fi(r,e):tr,u=r===e?{width:e.scrollWidth,height:e.scrollHeight}:{width:r.clientWidth,height:r.clientHeight},c={width:e.clientWidth,height:e.clientHeight};t[o].offset.length=0;let g=!t[o].interpolate,h=n.length;for(let p=0;per(e,n.target,i),update:o=>{Li(e,i,o),(n.offset||n.target)&&Ci(e,i,n)},notify:q(t)?()=>t(i):ir(t,i[r])}}function ir(e,t){return e.pause(),e.forEachNative((i,{easing:n})=>{var r,o;if(i.updateDuration)n||(i.easing=X),i.updateDuration(1);else{let s={duration:1e3};n||(s.easing="linear"),(o=(r=i.effect)===null||r===void 0?void 0:r.updateTiming)===null||o===void 0||o.call(r,s)}}),()=>{e.currentTime=t.progress}}var Bt=new WeakMap,Ri=new WeakMap,Le=new WeakMap,ki=e=>e===document.documentElement?window:e;function zi(e,t={}){var{container:i=document.documentElement}=t,n=ce(t,["container"]);let r=Le.get(i);r||(r=new Set,Le.set(i,r));let o=Pi(),s=Mi(i,e,o,n);if(r.add(s),!Bt.has(i)){let c=()=>{let h=performance.now();for(let p of r)p.measure();for(let p of r)p.update(h);for(let p of r)p.notify()};Bt.set(i,c);let g=ki(i);window.addEventListener("resize",c,{passive:!0}),i!==document.documentElement&&Ri.set(i,Ai(i,c)),g.addEventListener("scroll",c,{passive:!0})}let l=Bt.get(i),u=requestAnimationFrame(l);return()=>{var c;typeof e!="function"&&e.stop(),cancelAnimationFrame(u);let g=Le.get(i);if(!g||(g.delete(s),g.size))return;let h=Bt.get(i);Bt.delete(i),h&&(ki(i).removeEventListener("scroll",h),(c=Ri.get(i))===null||c===void 0||c(),window.removeEventListener("resize",h))}}function nr(e,t={}){return Ot([()=>{let i=new ft(e,[0,1],t);return i.finished.catch(()=>{}),i}],t,t.duration)}function ji(e,t,i){return(q(e)?nr:Ie)(e,t,i)}function dt(e){this.listenerMap=[{},{}],e&&this.root(e),this.handle=dt.prototype.handle.bind(this),this._removedListeners=[]}dt.prototype.root=function(e){let t=this.listenerMap,i;if(this.rootElement){for(i in t[1])t[1].hasOwnProperty(i)&&this.rootElement.removeEventListener(i,this.handle,!0);for(i in t[0])t[0].hasOwnProperty(i)&&this.rootElement.removeEventListener(i,this.handle,!1)}if(!e||!e.addEventListener)return this.rootElement&&delete this.rootElement,this;this.rootElement=e;for(i in t[1])t[1].hasOwnProperty(i)&&this.rootElement.addEventListener(i,this.handle,!0);for(i in t[0])t[0].hasOwnProperty(i)&&this.rootElement.addEventListener(i,this.handle,!1);return this};dt.prototype.captureForType=function(e){return["blur","error","focus","load","resize","scroll"].indexOf(e)!==-1};dt.prototype.on=function(e,t,i,n){let r,o,s,l;if(!e)throw new TypeError("Invalid event type: "+e);if(typeof t=="function"&&(n=i,i=t,t=null),n===void 0&&(n=this.captureForType(e)),typeof i!="function")throw new TypeError("Handler must be a type of Function");return r=this.rootElement,o=this.listenerMap[n?1:0],o[e]||(r&&r.addEventListener(e,this.handle,n),o[e]=[]),t?/^[a-z]+$/i.test(t)?(l=t,s=rr):/^#[a-z0-9\-_]+$/i.test(t)?(l=t.slice(1),s=or):(l=t,s=Element.prototype.matches):(l=null,s=sr.bind(this)),o[e].push({selector:t,handler:i,matcher:s,matcherParam:l}),this};dt.prototype.off=function(e,t,i,n){let r,o,s,l,u;if(typeof t=="function"&&(n=i,i=t,t=null),n===void 0)return this.off(e,t,i,!0),this.off(e,t,i,!1),this;if(s=this.listenerMap[n?1:0],!e){for(u in s)s.hasOwnProperty(u)&&this.off(u,t,i);return this}if(l=s[e],!l||!l.length)return this;for(r=l.length-1;r>=0;r--)o=l[r],(!t||t===o.selector)&&(!i||i===o.handler)&&(this._removedListeners.push(o),l.splice(r,1));return l.length||(delete s[e],this.rootElement&&this.rootElement.removeEventListener(e,this.handle,n)),this};dt.prototype.handle=function(e){let t,i,n=e.type,r,o,s,l,u=[],c,g="ftLabsDelegateIgnore";if(e[g]===!0)return;switch(c=e.target,c.nodeType===3&&(c=c.parentNode),c.correspondingUseElement&&(c=c.correspondingUseElement),r=this.rootElement,o=e.eventPhase||(e.target!==e.currentTarget?3:2),o){case 1:u=this.listenerMap[1][n];break;case 2:this.listenerMap[0]&&this.listenerMap[0][n]&&(u=u.concat(this.listenerMap[0][n])),this.listenerMap[1]&&this.listenerMap[1][n]&&(u=u.concat(this.listenerMap[1][n]));break;case 3:u=this.listenerMap[0][n];break}let h=[];for(i=u.length;c&&i;){for(t=0;t-1&&c.hasAttribute("disabled")?h=[]:s.matcher.call(c,s.matcherParam,c)&&h.push([e,c,s]);if(c===r||(i=u.length,c=c.parentElement||c.parentNode,c instanceof HTMLDocument))break}let p;for(t=0;t-1)&&(l=this.fire.apply(this,h[t]),l===!1)){h[t][0][g]=!0,h[t][0].preventDefault(),p=!1;break}return p};dt.prototype.fire=function(e,t,i){return i.handler.call(t,e,t)};function rr(e,t){return e.toLowerCase()===t.tagName.toLowerCase()}function sr(e,t){return this.rootElement===window?t===document||t===document.documentElement||t===window:this.rootElement===t}function or(e,t){return e===t.id}dt.prototype.destroy=function(){this.off(),this.root()};var ar=dt;function Kt(e,t,i){let n=document.createElement(t);return e&&(n.className=e),i&&i.appendChild(n),n}function lr(e,t,i){let n=`translate3d(${e}px,${t||0}px,0)`;return i!==void 0&&(n+=` scale3d(${i},${i},1)`),n}function Fe(e,t,i){e.style.width=typeof t=="number"?`${t}px`:t,e.style.height=typeof i=="number"?`${i}px`:i}var nt={IDLE:"idle",LOADING:"loading",LOADED:"loaded",ERROR:"error"};function cr(e){return"button"in e&&e.button===1||e.ctrlKey||e.metaKey||e.altKey||e.shiftKey}function me(e,t,i=document){let n=[];if(e instanceof Element)n=[e];else if(e instanceof NodeList||Array.isArray(e))n=Array.from(e);else{let r=typeof e=="string"?e:t;r&&(n=Array.from(i.querySelectorAll(r)))}return n}function ur(e){return typeof e=="function"&&e.prototype&&e.prototype.goTo}function Wi(){return!!(navigator.vendor&&navigator.vendor.match(/apple/i))}var Ne=class{constructor(t,i){this.type=t,this.defaultPrevented=!1,i&&Object.assign(this,i)}preventDefault(){this.defaultPrevented=!0}},Ce=class{constructor(){this._listeners={},this._filters={},this.pswp=void 0,this.options=void 0}addFilter(t,i,n=100){this._filters[t]||(this._filters[t]=[]),this._filters[t]?.push({fn:i,priority:n}),this._filters[t]?.sort((r,o)=>r.priority-o.priority),this.pswp?.addFilter(t,i,n)}removeFilter(t,i){this._filters[t]&&(this._filters[t]=this._filters[t].filter(n=>n.fn!==i)),this.pswp&&this.pswp.removeFilter(t,i)}applyFilters(t,...i){return this._filters[t]?.forEach(n=>{i[0]=n.fn.apply(this,i)}),i[0]}on(t,i){this._listeners[t]||(this._listeners[t]=[]),this._listeners[t]?.push(i),this.pswp?.on(t,i)}off(t,i){this._listeners[t]&&(this._listeners[t]=this._listeners[t].filter(n=>i!==n)),this.pswp?.off(t,i)}dispatch(t,i){if(this.pswp)return this.pswp.dispatch(t,i);let n=new Ne(t,i);return this._listeners[t]?.forEach(r=>{r.call(this,n)}),n}},Me=class{constructor(t,i){if(this.element=Kt("pswp__img pswp__img--placeholder",t?"img":"div",i),t){let n=this.element;n.decoding="async",n.alt="",n.src=t,n.setAttribute("role","presentation")}this.element.setAttribute("aria-hidden","true")}setDisplayedSize(t,i){this.element&&(this.element.tagName==="IMG"?(Fe(this.element,250,"auto"),this.element.style.transformOrigin="0 0",this.element.style.transform=lr(0,0,t/250)):Fe(this.element,t,i))}destroy(){this.element?.parentNode&&this.element.remove(),this.element=null}},Re=class{constructor(t,i,n){this.instance=i,this.data=t,this.index=n,this.element=void 0,this.placeholder=void 0,this.slide=void 0,this.displayedImageWidth=0,this.displayedImageHeight=0,this.width=Number(this.data.w)||Number(this.data.width)||0,this.height=Number(this.data.h)||Number(this.data.height)||0,this.isAttached=!1,this.hasSlide=!1,this.isDecoding=!1,this.state=nt.IDLE,this.data.type?this.type=this.data.type:this.data.src?this.type="image":this.type="html",this.instance.dispatch("contentInit",{content:this})}removePlaceholder(){this.placeholder&&!this.keepPlaceholder()&&setTimeout(()=>{this.placeholder&&(this.placeholder.destroy(),this.placeholder=void 0)},1e3)}load(t,i){if(this.slide&&this.usePlaceholder())if(this.placeholder){let n=this.placeholder.element;n&&!n.parentElement&&this.slide.container.prepend(n)}else{let n=this.instance.applyFilters("placeholderSrc",this.data.msrc&&this.slide.isFirstSlide?this.data.msrc:!1,this);this.placeholder=new Me(n,this.slide.container)}this.element&&!i||this.instance.dispatch("contentLoad",{content:this,isLazy:t}).defaultPrevented||(this.isImageContent()?(this.element=Kt("pswp__img","img"),this.displayedImageWidth&&this.loadImage(t)):(this.element=Kt("pswp__content","div"),this.element.innerHTML=this.data.html||""),i&&this.slide&&this.slide.updateContentSize(!0))}loadImage(t){if(!this.isImageContent()||!this.element||this.instance.dispatch("contentLoadImage",{content:this,isLazy:t}).defaultPrevented)return;let i=this.element;this.updateSrcsetSizes(),this.data.srcset&&(i.srcset=this.data.srcset),i.src=this.data.src??"",i.alt=this.data.alt??"",this.state=nt.LOADING,i.complete?this.onLoaded():(i.onload=()=>{this.onLoaded()},i.onerror=()=>{this.onError()})}setSlide(t){this.slide=t,this.hasSlide=!0,this.instance=t.pswp}onLoaded(){this.state=nt.LOADED,this.slide&&this.element&&(this.instance.dispatch("loadComplete",{slide:this.slide,content:this}),this.slide.isActive&&this.slide.heavyAppended&&!this.element.parentNode&&(this.append(),this.slide.updateContentSize(!0)),(this.state===nt.LOADED||this.state===nt.ERROR)&&this.removePlaceholder())}onError(){this.state=nt.ERROR,this.slide&&(this.displayError(),this.instance.dispatch("loadComplete",{slide:this.slide,isError:!0,content:this}),this.instance.dispatch("loadError",{slide:this.slide,content:this}))}isLoading(){return this.instance.applyFilters("isContentLoading",this.state===nt.LOADING,this)}isError(){return this.state===nt.ERROR}isImageContent(){return this.type==="image"}setDisplayedSize(t,i){if(this.element&&(this.placeholder&&this.placeholder.setDisplayedSize(t,i),!this.instance.dispatch("contentResize",{content:this,width:t,height:i}).defaultPrevented&&(Fe(this.element,t,i),this.isImageContent()&&!this.isError()))){let n=!this.displayedImageWidth&&t;this.displayedImageWidth=t,this.displayedImageHeight=i,n?this.loadImage(!1):this.updateSrcsetSizes(),this.slide&&this.instance.dispatch("imageSizeChange",{slide:this.slide,width:t,height:i,content:this})}}isZoomable(){return this.instance.applyFilters("isContentZoomable",this.isImageContent()&&this.state!==nt.ERROR,this)}updateSrcsetSizes(){if(!this.isImageContent()||!this.element||!this.data.srcset)return;let t=this.element,i=this.instance.applyFilters("srcsetSizesWidth",this.displayedImageWidth,this);(!t.dataset.largestUsedSize||i>parseInt(t.dataset.largestUsedSize,10))&&(t.sizes=i+"px",t.dataset.largestUsedSize=String(i))}usePlaceholder(){return this.instance.applyFilters("useContentPlaceholder",this.isImageContent(),this)}lazyLoad(){this.instance.dispatch("contentLazyLoad",{content:this}).defaultPrevented||this.load(!0)}keepPlaceholder(){return this.instance.applyFilters("isKeepingPlaceholder",this.isLoading(),this)}destroy(){this.hasSlide=!1,this.slide=void 0,!this.instance.dispatch("contentDestroy",{content:this}).defaultPrevented&&(this.remove(),this.placeholder&&(this.placeholder.destroy(),this.placeholder=void 0),this.isImageContent()&&this.element&&(this.element.onload=null,this.element.onerror=null,this.element=void 0))}displayError(){if(this.slide){let t=Kt("pswp__error-msg","div");t.innerText=this.instance.options?.errorMsg??"",t=this.instance.applyFilters("contentErrorElement",t,this),this.element=Kt("pswp__content pswp__error-msg-container","div"),this.element.appendChild(t),this.slide.container.innerText="",this.slide.container.appendChild(this.element),this.slide.updateContentSize(!0),this.removePlaceholder()}}append(){if(this.isAttached||!this.element)return;if(this.isAttached=!0,this.state===nt.ERROR){this.displayError();return}if(this.instance.dispatch("contentAppend",{content:this}).defaultPrevented)return;let t="decode"in this.element;this.isImageContent()?t&&this.slide&&(!this.slide.isActive||Wi())?(this.isDecoding=!0,this.element.decode().catch(()=>{}).finally(()=>{this.isDecoding=!1,this.appendImage()})):this.appendImage():this.slide&&!this.element.parentNode&&this.slide.container.appendChild(this.element)}activate(){this.instance.dispatch("contentActivate",{content:this}).defaultPrevented||!this.slide||(this.isImageContent()&&this.isDecoding&&!Wi()?this.appendImage():this.isError()&&this.load(!1,!0),this.slide.holderElement&&this.slide.holderElement.setAttribute("aria-hidden","false"))}deactivate(){this.instance.dispatch("contentDeactivate",{content:this}),this.slide&&this.slide.holderElement&&this.slide.holderElement.setAttribute("aria-hidden","true")}remove(){this.isAttached=!1,!this.instance.dispatch("contentRemove",{content:this}).defaultPrevented&&(this.element&&this.element.parentNode&&this.element.remove(),this.placeholder&&this.placeholder.element&&this.placeholder.element.remove())}appendImage(){this.isAttached&&(this.instance.dispatch("contentAppendImage",{content:this}).defaultPrevented||(this.slide&&this.element&&!this.element.parentNode&&this.slide.container.appendChild(this.element),(this.state===nt.LOADED||this.state===nt.ERROR)&&this.removePlaceholder()))}};function fr(e,t){if(e.getViewportSizeFn){let i=e.getViewportSizeFn(e,t);if(i)return i}return{x:document.documentElement.clientWidth,y:window.innerHeight}}function pe(e,t,i,n,r){let o=0;if(t.paddingFn)o=t.paddingFn(i,n,r)[e];else if(t.padding)o=t.padding[e];else{let s="padding"+e[0].toUpperCase()+e.slice(1);t[s]&&(o=t[s])}return Number(o)||0}function dr(e,t,i,n){return{x:t.x-pe("left",e,t,i,n)-pe("right",e,t,i,n),y:t.y-pe("top",e,t,i,n)-pe("bottom",e,t,i,n)}}var Vi=4e3,ke=class{constructor(t,i,n,r){this.pswp=r,this.options=t,this.itemData=i,this.index=n,this.panAreaSize=null,this.elementSize=null,this.fit=1,this.fill=1,this.vFill=1,this.initial=1,this.secondary=1,this.max=1,this.min=1}update(t,i,n){let r={x:t,y:i};this.elementSize=r,this.panAreaSize=n;let o=n.x/r.x,s=n.y/r.y;this.fit=Math.min(1,os?o:s),this.vFill=Math.min(1,s),this.initial=this._getInitial(),this.secondary=this._getSecondary(),this.max=Math.max(this.initial,this.secondary,this._getMax()),this.min=Math.min(this.fit,this.initial,this.secondary),this.pswp&&this.pswp.dispatch("zoomLevelsUpdate",{zoomLevels:this,slideData:this.itemData})}_parseZoomLevelOption(t){let i=t+"ZoomLevel",n=this.options[i];if(n)return typeof n=="function"?n(this):n==="fill"?this.fill:n==="fit"?this.fit:Number(n)}_getSecondary(){let t=this._parseZoomLevelOption("secondary");return t||(t=Math.min(1,this.fit*3),this.elementSize&&t*this.elementSize.x>Vi&&(t=Vi/this.elementSize.x),t)}_getInitial(){return this._parseZoomLevelOption("initial")||this.fit}_getMax(){return this._parseZoomLevelOption("max")||Math.max(1,this.fit*4)}};function Hi(e,t,i){let n=t.createContentFromData(e,i),r,{options:o}=t;if(o){r=new ke(o,e,-1);let s;t.pswp?s=t.pswp.viewportSize:s=fr(o,t);let l=dr(o,s,e,i);r.update(n.width,n.height,l)}return n.lazyLoad(),r&&n.setDisplayedSize(Math.ceil(n.width*r.initial),Math.ceil(n.height*r.initial)),n}function hr(e,t){let i=t.getItemData(e);if(!t.dispatch("lazyLoadSlide",{index:e,itemData:i}).defaultPrevented)return Hi(i,t,e)}var ze=class extends Ce{getNumItems(){let t=0,i=this.options?.dataSource;i&&"length"in i?t=i.length:i&&"gallery"in i&&(i.items||(i.items=this._getGalleryDOMElements(i.gallery)),i.items&&(t=i.items.length));let n=this.dispatch("numItems",{dataSource:i,numItems:t});return this.applyFilters("numItems",n.numItems,i)}createContentFromData(t,i){return new Re(t,this,i)}getItemData(t){let i=this.options?.dataSource,n={};Array.isArray(i)?n=i[t]:i&&"gallery"in i&&(i.items||(i.items=this._getGalleryDOMElements(i.gallery)),n=i.items[t]);let r=n;r instanceof Element&&(r=this._domElementToItemData(r));let o=this.dispatch("itemData",{itemData:r||{},index:t});return this.applyFilters("itemData",o.itemData,t)}_getGalleryDOMElements(t){return this.options?.children||this.options?.childSelector?me(this.options.children,this.options.childSelector,t)||[]:[t]}_domElementToItemData(t){let i={element:t},n=t.tagName==="A"?t:t.querySelector("a");if(n){i.src=n.dataset.pswpSrc||n.href,n.dataset.pswpSrcset&&(i.srcset=n.dataset.pswpSrcset),i.width=n.dataset.pswpWidth?parseInt(n.dataset.pswpWidth,10):0,i.height=n.dataset.pswpHeight?parseInt(n.dataset.pswpHeight,10):0,i.w=i.width,i.h=i.height,n.dataset.pswpType&&(i.type=n.dataset.pswpType);let r=t.querySelector("img");r&&(i.msrc=r.currentSrc||r.src,i.alt=r.getAttribute("alt")??""),(n.dataset.pswpCropped||n.dataset.cropped)&&(i.thumbCropped=!0)}return this.applyFilters("domItemData",i,t,n)}lazyLoadData(t,i){return Hi(t,this,i)}},je=class extends ze{constructor(t){super(),this.options=t||{},this._uid=0,this.shouldOpen=!1,this._preloadedContent=void 0,this.onThumbnailsClick=this.onThumbnailsClick.bind(this)}init(){me(this.options.gallery,this.options.gallerySelector).forEach(t=>{t.addEventListener("click",this.onThumbnailsClick,!1)})}onThumbnailsClick(t){if(cr(t)||window.pswp||window.navigator.onLine===!1)return;let i={x:t.clientX,y:t.clientY};!i.x&&!i.y&&(i=null);let n=this.getClickedIndex(t);n=this.applyFilters("clickedIndex",n,t,this);let r={gallery:t.currentTarget};n>=0&&(t.preventDefault(),this.loadAndOpen(n,r,i))}getClickedIndex(t){if(this.options.getClickedIndexFn)return this.options.getClickedIndexFn.call(this,t);let i=t.target,r=me(this.options.children,this.options.childSelector,t.currentTarget).findIndex(o=>o===i||o.contains(i));return r!==-1?r:this.options.children||this.options.childSelector?-1:0}loadAndOpen(t,i,n){return window.pswp?!1:(this.options.index=t,this.options.initialPointerPos=n,this.shouldOpen=!0,this.preload(t,i),!0)}preload(t,i){let{options:n}=this;i&&(n.dataSource=i);let r=[],o=typeof n.pswpModule;if(ur(n.pswpModule))r.push(Promise.resolve(n.pswpModule));else{if(o==="string")throw new Error("pswpModule as string is no longer supported");if(o==="function")r.push(n.pswpModule());else throw new Error("pswpModule is not valid")}typeof n.openPromise=="function"&&r.push(n.openPromise()),n.preloadFirstSlide!==!1&&t>=0&&(this._preloadedContent=hr(t,this));let s=++this._uid;Promise.all(r).then(l=>{if(this.shouldOpen){let u=l[0];this._openPhotoswipe(u,s)}})}_openPhotoswipe(t,i){if(i!==this._uid&&this.shouldOpen||(this.shouldOpen=!1,window.pswp))return;let n=typeof t=="object"?new t.default(this.options):new t(this.options);this.pswp=n,window.pswp=n,Object.keys(this._listeners).forEach(r=>{this._listeners[r]?.forEach(o=>{n.on(r,o)})}),Object.keys(this._filters).forEach(r=>{this._filters[r]?.forEach(o=>{n.addFilter(r,o.fn,o.priority)})}),this._preloadedContent&&(n.contentLoader.addToCache(this._preloadedContent),this._preloadedContent=void 0),n.on("destroy",()=>{this.pswp=void 0,delete window.pswp}),n.init()}destroy(){this.pswp?.destroy(),this.shouldOpen=!1,this._listeners={},me(this.options.gallery,this.options.gallerySelector).forEach(t=>{t.removeEventListener("click",this.onThumbnailsClick,!1)})}};(function(){let e=!1;if(document.createElement("i").addEventListener("click",()=>{},{get signal(){e=!0}}),e||!window.AbortController)return;let t=EventTarget.prototype.addEventListener;EventTarget.prototype.addEventListener=function(i,n,r){if(r&&r.signal){if(r.signal.aborted)return;r.signal.addEventListener("abort",()=>this.removeEventListener(i,n,{...r}))}return t.call(this,i,n,r)}})();export{ar as Delegate,be as FocusTrap,je as PhotoSwipeLightbox,de as ScrollOffset,ji as animate,Oi as inView,zi as scroll,bi as stagger,Si as timeline}; /*! Bundled license information: @ungap/custom-elements/es.js: (*! (c) Andrea Giammarchi - ISC *) instant.page/instantpage.js: (*! instant.page v5.2.0 - (C) 2019-2023 Alexandre Dieulot - https://instant.page/license *) tabbable/dist/index.esm.js: (*! * tabbable 6.1.2 * @license MIT, https://github.com/focus-trap/tabbable/blob/master/LICENSE *) focus-trap/dist/focus-trap.esm.js: (*! * focus-trap 7.4.3 * @license MIT, https://github.com/focus-trap/focus-trap/blob/master/LICENSE *) photoswipe/dist/photoswipe-lightbox.esm.js: (*! * PhotoSwipe Lightbox 5.3.7 - https://photoswipe.com * (c) 2023 Dmytro Semenov *) */